Contact done
This commit is contained in:
@@ -327,7 +327,21 @@ const invalidContact = ({type, action}, component) => {
|
||||
})
|
||||
}
|
||||
|
||||
const submitContact = ({type, action}, component) => {
|
||||
const submitContactStart = ({type, action}, component) => {
|
||||
component.setState({
|
||||
contact: {
|
||||
sending: true
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
const submitContactEnd = ({type, action}, component) => {
|
||||
component.setState({
|
||||
contactFormOpen: false,
|
||||
contact: {
|
||||
sending: false,
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
const handlers = {
|
||||
@@ -355,7 +369,8 @@ const handlers = {
|
||||
OPEN_CONTACT: openContact,
|
||||
CLOSE_CONTACT: closeContact,
|
||||
UPDATE_CONTACT_INFO: updateContactInfo,
|
||||
SUBMIT_CONTACT: submitContact,
|
||||
SUBMIT_CONTACT_START: submitContactStart,
|
||||
SUBMIT_CONTACT_END: submitContactEnd,
|
||||
INVALID_CONTACT: invalidContact
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user