import Button from "../action/Button" import { FC, ReactNode } from "react" import IconClose from "../icon/IconClose" import { Tooltip } from "react-tooltip" interface Props { title: ReactNode show: boolean close: () => void children?: ReactNode } const Modal: FC = ({ title, show, close, children }) => { if (!show) { return <> } return (
{ e.preventDefault() e.stopPropagation() close() }} onTouchStartCapture={(e) => { e.preventDefault() e.stopPropagation() close() }} className={"absolute top-0 left-0 h-full w-full bg-black/50"} />

{title}

{children}
) } export default Modal