npx shadcn@latest add https://ui.doras.to/r/sidebar.jsonContains all root functionality.
| Prop | Type | Default |
|---|---|---|
id* | string | - |
side | "left" | "right" | "left" |
variant | "default" | "floating" | "default" |
collapsible | boolean | true |
defaultOpen | boolean | true |
width | string | "16rem" |
collapsedWidth | string | "3.5rem" |
keyboardShortcut | string | - |
className | string | - |
rootClassName | string | - |
isCollapsed | boolean | - |
A sidebar positioned on the right side of the screen.
Modify and manage multiple sidebars without layout or overflow problems. Pass classNames to style individually including setting widths and heights, and manage what appears on one sidebar depending on the other easily