handle Chips and Chip Values
This commit is contained in:
43
client/src/common/YesNoModal.js
Normal file
43
client/src/common/YesNoModal.js
Normal file
@@ -0,0 +1,43 @@
|
||||
import React from 'react';
|
||||
import { Modal, Button, Row, Col } from 'react-materialize';
|
||||
|
||||
const YesNoModal = (props) => {
|
||||
const { title, body, yesAction, noAction, triggerNode } = props;
|
||||
return(
|
||||
<Modal
|
||||
actions={[
|
||||
<Row>
|
||||
<Col s={3}>
|
||||
<Button modal="confirm" node="button" waves="green" onClick={yesAction}>Yes</Button>
|
||||
</Col>
|
||||
<Col s={3}>
|
||||
<Button modal="close" node="button" waves="red" onClick={noAction}>No</Button>
|
||||
</Col>
|
||||
</Row>
|
||||
]}
|
||||
bottomSheet
|
||||
fixedFooter={false}
|
||||
header={title}
|
||||
id="Modal-0"
|
||||
open={false}
|
||||
options={{
|
||||
dismissible: true,
|
||||
endingTop: '10%',
|
||||
inDuration: 250,
|
||||
onCloseEnd: null,
|
||||
onCloseStart: null,
|
||||
onOpenEnd: null,
|
||||
onOpenStart: null,
|
||||
opacity: 0.5,
|
||||
outDuration: 250,
|
||||
preventScrolling: true,
|
||||
startingTop: '4%'
|
||||
}}
|
||||
trigger={triggerNode}
|
||||
>
|
||||
<p>{body}</p>
|
||||
</Modal>
|
||||
)
|
||||
}
|
||||
|
||||
export default YesNoModal;
|
||||
Reference in New Issue
Block a user