mirror of
https://github.com/kingomarnajjar/innovationdrive.git
synced 2026-07-26 06:37:28 +10:00
40 lines
No EOL
1.1 KiB
JavaScript
40 lines
No EOL
1.1 KiB
JavaScript
import React from 'react';
|
|
import { Button, Modal, ModalHeader, ModalBody, ModalFooter } from 'reactstrap';
|
|
import EmailForm from './Form';
|
|
|
|
class ModalExample extends React.Component {
|
|
constructor(props) {
|
|
super(props);
|
|
this.state = {
|
|
modal: false
|
|
};
|
|
|
|
this.toggle = this.toggle.bind(this);
|
|
}
|
|
|
|
toggle() {
|
|
this.setState({
|
|
modal: !this.state.modal
|
|
});
|
|
}
|
|
|
|
render() {
|
|
return (
|
|
<div>
|
|
<Button color="primary" onClick={this.toggle}>{this.props.buttonLabel}Make idea a reality!</Button>
|
|
<Modal isOpen={this.state.modal} toggle={this.toggle} className={this.props.className}>
|
|
{/* <ModalHeader toggle={this.toggle}>Free Video Consultation</ModalHeader> */}
|
|
<ModalBody>
|
|
<EmailForm />
|
|
</ModalBody>
|
|
<ModalFooter>
|
|
{/* <Button color="primary" onClick={this.toggle}>Do Something</Button>{' '} */}
|
|
{/* <Button color="secondary" onClick={this.toggle}>Cancel</Button> */}
|
|
</ModalFooter>
|
|
</Modal>
|
|
</div>
|
|
);
|
|
}
|
|
}
|
|
|
|
export default ModalExample; |