A `Modal` pre-wired with a message and confirm/cancel actions, for "are you sure?" moments such as confirming a delete.
Examples of v0.2.10 are shown as code; only the latest version runs live. Open the live examples →
Basic Confirm Dialog
1const BasicConfirmDialog = () => {2 const [open, setOpen] = useState(false);34 return (5 <>6 <button type="button" onClick={() => setOpen(true)}>7 Delete page8 </button>9 <ConfirmDialog10 open={open}11 onOpenChange={setOpen}12 title="Delete page"13 message='Are you sure you want to delete "About Us"? This cannot be undone.'14 confirmLabel="Delete"15 variant="danger"16 onConfirm={() => console.log("confirmed delete")}17 />18 </>19 );20};2122render(<BasicConfirmDialog />);