adding modal

This commit is contained in:
Priyatham Sai Chand 2021-04-19 23:35:04 +05:30
parent 508cbf5d63
commit e736aa99fb
1 changed files with 25 additions and 0 deletions

View File

@ -0,0 +1,25 @@
import {Modal, Button} from 'react-bootstrap';
import React, {useState} from 'react';
export const CustomModal = (props) => {
const handleClose = () => props.setShow(false);
const handleShow = () => props.setShow(true);
return (
<>
<Modal show={props.show} onHide={handleClose}>
<Modal.Header closeButton>
<Modal.Title>{props.title}</Modal.Title>
</Modal.Header>
<Modal.Body>{props.desc}</Modal.Body>
<Modal.Footer>
<Button variant="secondary" onClick={handleClose}>
Log In
</Button>
</Modal.Footer>
</Modal>
</>
);
}