import { Dialog, TransitionChild, Transition, DialogTitle, Description, DialogPanel, CloseButton, } from "@headlessui/react"; import { XMarkIcon } from "@heroicons/react/24/outline"; import { type ReactNode, Fragment } from "react"; import { Button } from "../Button"; type ModalProps = { show: boolean; onClose: () => void; afterLeave?: (() => void) | undefined; children: ReactNode; title: string; description?: string; }; export const Modal = ({ show, onClose, afterLeave, children, title, description, }: ModalProps) => (
{title} {description && ( {description} )} {children}
Close
);