Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@ManiruzzamanAkash
Created February 9, 2021 05:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ManiruzzamanAkash/a26750f4794ed1e00b79351d7d932125 to your computer and use it in GitHub Desktop.
Save ManiruzzamanAkash/a26750f4794ed1e00b79351d7d932125 to your computer and use it in GitHub Desktop.
SimpleModal Component
import React from "react";
import { Modal } from "react-bootstrap";
const SimpleModal = (props) => {
const { show, handleClose, size, modalTitle } = props;
return (
<Modal onClose={handleClose} size={size} show={show} onHide={handleClose}>
<Modal.Header closeButton>
<Modal.Title>{modalTitle}</Modal.Title>
<p className="btn-modal-close" onClick={() => handleClose()}>
<i className="fa fa-times text-danger"></i>
</p>
</Modal.Header>
<Modal.Body>{props.children}</Modal.Body>
</Modal>
);
};
export default SimpleModal;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment