0
Components
API reference

Drawer

A surface panel that slides in from any screen edge, with swipe gestures, snap points, nested stacking, and menu primitives.

Installation

Usage

Examples

Right Position

Inset

With Menu

Nested

Scrollable

API Reference

Drawer

Root component wrapping Base UI Drawer.Root and providing edge position context to its children.

PropTypeDefaultDescription
position"bottom" | "top" | "left" | "right""bottom"Edge from which the drawer slides in
swipeDirection"down" | "up" | "left" | "right"-Overrides the swipe direction inferred from position
openboolean-Controlled open state
defaultOpenbooleanfalseInitial uncontrolled open state
onOpenChange(open: boolean) => void-Called when the open state changes
...propsBase UI Drawer Root props-All other Drawer Root props are supported

DrawerPopup

The sliding surface rendered inside DrawerPortal, DrawerBackdrop, and DrawerViewport.

PropTypeDefaultDescription
position"bottom" | "top" | "left" | "right"-Overrides the position inherited from Drawer
variant"default" | "straight" | "inset""default"Surface geometry (inset floats with rounded corners on sm+)
showBarbooleanfalseRenders the drag handle bar along the leading edge
showCloseButtonbooleanfalseRenders a top-end close icon button
closePropsDrawer.Close.Props-Props forwarded to the built-in close button
portalPropsDrawer.Portal.Props-Props forwarded to the internal portal
...propsBase UI Drawer Popup props-All standard drawer popup props

DrawerHeader

Header region for DrawerTitle and DrawerDescription.

PropTypeDefaultDescription
allowSelectionbooleanfalseAllows text selection inside the header drag zone

DrawerPanel

Main body container, wrapped in a ScrollArea by default.

PropTypeDefaultDescription
scrollablebooleantrueWraps the content in a ScrollArea
scrollFadebooleanfalseAdds edge fade masks while scrolling
allowSelectionbooleantrueAllows text selection inside the panel

DrawerFooter

Action row anchored to the bottom of the drawer.

PropTypeDefaultDescription
variant"default" | "bare""default""default" uses a contrasting footer surface; "bare" blends into the popup
allowSelectionbooleantrueAllows text selection inside the footer

DrawerTrigger / DrawerClose / DrawerTitle / DrawerDescription / DrawerBar / DrawerSwipeArea

Standard triggers, headings, drag handle bar, and edge swipe-area primitives.

DrawerMenu Primitives

Composable touch-friendly menu items built for mobile and side drawers, all featuring spring corner morphing and ripple feedback:

  • DrawerMenu, DrawerMenuGroup, DrawerMenuGroupLabel, DrawerMenuSeparator
  • DrawerMenuItem (variant?: "default" | "destructive")
  • DrawerMenuTrigger (opens a nested Drawer with a trailing chevron)
  • DrawerMenuCheckboxItem (variant?: "default" | "switch")
  • DrawerMenuRadioGroup, DrawerMenuRadioItem

© taut ui — built with Base UI and Tailwind CSS v4.