Confirm Buttonconfirm-buttonA Button that confirms on a click, a second click or a press and hold. Supports inline undo and a pending state for an async onConfirm.
Confirm Dialogconfirm-dialogAn alert dialog with a ConfirmButton or TypeToConfirm as its confirm action, which closes only after an async onConfirm settles. Includes useConfirm, which returns an awaitable confirm() and a dialog element you render yourself.
Confirm Menu Itemconfirm-menu-itemA DropdownMenu or ContextMenu item that confirms on a click, a second click or a press and hold. The menu stays open while the item is armed, held, pending or showing Undo, and closes once the action commits.
Confirm Popoverconfirm-popoverA popover anchored to any trigger, with one line about the consequence and a ConfirmButton, for actions that need a sentence but not a dialog. It stays open while an async onConfirm is pending.
Confirm Switchconfirm-switchA Switch that moves right away and can be taken back: flipping it again during the undo window undoes it, and onConfirm(checked) runs when the window ends.
ConsequencesconsequencesA list of what a confirmation will remove, with counts and names that collapse to "and N more". Pass it to TypeToConfirm or ConfirmDialog through their consequences prop.
Tool Approvaltool-approvalApprove or deny an AI SDK tool call, or a batch of them, with a gesture that matches its risk: undo for low, click again for medium, hold for high and a typed phrase for critical. Pass addToolApprovalResponse from useChat as onRespond.
Type to Confirmtype-to-confirmAn inline form that calls onConfirm only after the exact phrase is typed and every acknowledgement is checked. Supports inline undo and a pending state for an async onConfirm.
UndoableundoableWraps a list item or table row. Removing it collapses the row in place to a label and an Undo button at the same height, then runs onConfirm when the undo window ends.
Unsaved Changesunsaved-changesuseUnsavedChanges asks before unsaved changes are lost: the browser's prompt on reload or close, an awaitable confirmLeave() for leaving a page, and Keep editing, Discard changes and an optional Save in a Dialog, Sheet or Drawer's footer before it closes.