Dialog
Overlays & Feedback
macOS system modal alert dialog with translucent backdrop blur.
Installation
$npx shadcn-macos@latest add dialog
Examples
Props
<Dialog />| Prop | Type | Default | Description |
|---|---|---|---|
| open* | boolean | — | Controls whether the dialog modal is visible. |
| onOpenChange* | (open: boolean) => void | — | Callback invoked when modal is opened or dismissed. |
| title* | string | — | Headline dialog message. |
| description | string | — | Explanatory context under the title. |
| confirmText | string | "OK" | Text for the primary confirm button. |
| cancelText | string | "Cancel" | Text for the secondary cancel button. |
| destructive | boolean | false | Whether the confirm button uses destructive red styling. |
| onConfirm | () => void | — | Callback invoked when confirm button is clicked. |
| onCancel | () => void | — | Callback invoked when cancel button is clicked. |