Sheet
A side panel with coherent structure and spacing, from any edge.
Base UI reference ↗Installation
Run it from the root of a project already set up with zunoui init.
npx zunoui@latest add sheetDependencies
What add sheet installs alongside the component. The CLI skips any you already have in a compatible version.
ZUNO registry
@zuno/utils@zuno/drawer
npm
@base-ui/[email protected]
Examples
2 examples · 1 componentEdit form
A form in a right-side sheet; the footer stays at the bottom.
Any edge
side picks the edge and the dismiss swipe.
API reference
Keeps the props, events and refs of the matching Base UI primitive, plus ZUNO's styles.
| Prop | Type | Default |
|---|---|---|
sideEdge it enters from; the matching swipe dismisses it. Physical, so it does not flip in RTL. | "right" | "left" | "top" | "bottom" | "right" |
SheetRoot; open, defaultOpen, onOpenChange and modal. | — | — |
SheetTrigger / SheetCloseOpen and close; use render to reuse Button. | button | — |
SheetContentPortaled panel (3/4 width up to 24rem on the sides); showClose (true) adds the corner button. | div | — |
SheetHeader / SheetFooterTitle block and actions; the footer sticks to the bottom. | div | — |
SheetTitle / SheetDescriptionLabel and describe the dialog. | h2 / p | — |
States
The states that apply to this component and their visual treatment.
| State | Treatment |
|---|---|
| Closed | Only the trigger. |
| Open | Slides in from side over a dimmed backdrop. |
| Swiping | Follows the gesture toward its edge. |
| Dismissed | Slides out; focus returns to the trigger. |
Accessibility
A modal dialog built on Drawer: focus moves in, is trapped and returns to the trigger; the title labels it.
Escape, the backdrop and the close button dismiss it; the swipe is an extra, never the only way.
Use Dialog for short confirmations and Sheet for longer tasks that keep the page context visible.
The slide stops with reduced motion.