Overlays
Drawer
Presents an edge-anchored gesture-driven sheet with smooth touch dragging and snap points.
Usage
Anatomy
The parts and how they nest, taken from the preview above.
Examples
Production workspace
Review the latest activity without leaving the workspace.
Inset variant
Panels from all four edges.
Straight variant
Square corners with a bare footer.
Scrollable content
A fixed header and footer around a scrolling panel.
Nested drawers and menus
Actions, disabled items, checkbox and radio selection, and nested navigation.
Snap points
Drag between three sequential bottom snap points.
Disabled
An unavailable drawer trigger.
Recommendations
| Guidance | Practice |
|---|---|
| Do | Use a clear title and an explicit close control. Keep scrolling content separate from the main action. |
Usage boundaries
| Guidance | Boundary |
|---|---|
| Scope | Dragging must not be the only dismissal path. Use a page for tasks that require sustained reference to other content. |
API reference
Public props from @mizen-labs/ui. Use exported prop types for the complete TypeScript contract.
| Prop | Type | Default | Description |
|---|---|---|---|
| | — | Root state, position, swipe direction, snap points, and native open callbacks. |
| | — | Creates a handle for detached triggers. |
| | — | Opens the drawer; supports render composition. |
| | — | Portal, backdrop, viewport, and popup; supports position, variants, showBar, showCloseButton, and portalProps. |
| | — | Title and description layout; allowSelection defaults to false. |
| | — | Action area; variant defaults to default, allowSelection to true. |
| | — | Accessible drawer title. |
| | — | Muted accessible description. |
| | — | Body; scrollable, scrollFade, and allowSelection default to true. |
| | — | Container for drawer action items. |
| | — | Button action; supports disabled, render, and destructive variant. Wrap in DrawerClose to dismiss. |
| | — | Divider between action groups. |
| | — | Container for related actions. |
| | — | Muted group heading. |
| | — | Opens a nested drawer with a trailing chevron. |
| | — | Native checkbox row; supports controlled state, disabled, and switch variant. |
| | — | Native radio selection group. |
| | — | Native radio row; requires a string value. |
| | — | Dismisses the drawer and restores focus. |
| | — | Native Base UI portal. |
| | — | Styled backdrop. |
| | — | Styled positioning viewport; accepts position and variant. |
| | — | Edge gesture target; accepts position. |
| | — | Drag indicator; accepts position and render. |
| | — | Native swipe-protected content wrapper. |
| | — | Base UI Drawer namespace. |
| | "bottom" | Anchors the drawer to the specified edge of the viewport. |
| | derived from position | Direction of pointer swipe gestures used to dismiss or reposition the drawer. |
| | — | Snap points defining intermediate heights or positions for drawer expansion. |
| | "default" | Visual presentation variant controlling border radius and inset spacing. |
| | false | Renders an aria-hidden visual affordance grab handle bar on the drawer popup edge. |
| | false | Renders an accessible close button inside the drawer popup. |
| | true | Wraps drawer panel content in a managed scroll area. |
| | true | Enables text selection within the drawer panel while preserving swiping outside it. |