← Inventory
ResizablePanelGroup
Container that lays out resizable panels along a single axis.
Wraps react-resizable-panels Group, exposing shadcn's direction prop
(mapped to the library's orientation). Compose with ResizablePanel
children separated by ResizableHandle.
Sidebar
Canvas
Usage
import { resizableAnatomy, ResizableDirection, ResizableHandle, ResizableHandleProps, ResizablePanel, ResizablePanelGroup, ResizablePanelGroupProps } from "@desk/ui/components/resizable";Best practices
Compose
ResizablePanelchildren separated byResizableHandle— a handle between panels is what makes them draggable.Set the axis with
direction(horizontal/vertical); it maps to the library'sorientation, which is intentionally not exposed.
Props
ResizableHandle
| Prop | Type | Default | Description |
|---|---|---|---|
| withHandle | boolean | undefined | false | Render a centered grip affordance on the divider. |
ResizablePanelGroup
| Prop | Type | Default | Description |
|---|---|---|---|
| direction | ResizableDirection | undefined | "horizontal" | Axis the panels split along. |
Also exports
- const
resizableAnatomy - type
ResizableDirection - interface
ResizableHandleProps - component
ResizablePanel - interface
ResizablePanelGroupProps
Anatomy
ResizablePanelGroup
resizable-panel-groupPanels split along an axis with a draggable divider
ResizablePanel
resizable-panelResizable region
ResizableHandle
resizable-handleDraggable divider between panels
Composition
Builds on