Neobrutalism UI LogoNeobrutal UI

Dialog

A window overlaid on either the primary window or another dialog window, rendering the content underneath inert.

Installation

npx neobrutal add dialog

Usage

import {
Dialog,
DialogContent,
DialogDescription,
DialogHeader,
DialogTitle,
DialogTrigger,
} from "@/components/ui/dialog"
<Dialog>
<DialogTrigger render={<Button variant="neutral" />}>
Open Dialog
</DialogTrigger>
<DialogContent>
<DialogHeader>
<DialogTitle>Are you absolutely sure?</DialogTitle>
<DialogDescription>
This action cannot be undone. This will permanently delete your account
and remove your data from our servers.
</DialogDescription>
</DialogHeader>
</DialogContent>
</Dialog>

Props

Dialog

PropTypeDefaultDescription
openboolean-The controlled open state of the dialog.
defaultOpenboolean-The default open state when uncontrolled.
onOpenChange(open: boolean) => void-Event handler called when the open state changes.
modalboolean-The modality of the dialog. When set to true, interaction with outside elements will be disabled.