Dialog
Installation
import { Dialog } from "@o/pipeline/experimental/components/dialog";
Usage
Pass skipEntranceAnimation on Dialog.Root when opening via a keyboard shortcut — not when the user clicks a trigger. See CommandMenu.
Implementation
Anatomy
Our Dialog component is built upon the Base UI Dialog component, with additional components:
Dialog.RootDialog.Trigger- primitive button that opens the dialog. Fully customizable via therenderprop.Dialog.PortalDialog.BackdropDialog.ViewportDialog.PopupDialog.HeaderDialog.HeaderClose
Dialog.BodyDialog.Title- obligatory, but can be set tovisuallyHiddenDialog.Description- optional, can be set tovisuallyHidden
Dialog.FooterDialog.FooterAction- can contain more than one action
Dialog.Close- primitive close action thatDialog.HeaderCloseextends upon. Fully customizable via therenderprop.
Layout
Dialog’s core layout is fixed and non-customizable; the Dialog.Header, Dialog.Body, and Dialog.Footer will always render in the same order.
Additionally, Dialog.Header and Dialog.Footer’s contents will ensure Dialog.HeaderClose and Dialog.FooterAction are always rendered in the same position, regardless of additional content.