Resizable
BetaBeta — the props contract is close to final, but small breaking changes can still land.Accessible resizable panel groups and split layouts with keyboard support.
Examples
Hover handle
variant="hover" leaves the track transparent until the separator is hovered, focused, or dragged, then fades in a gradient line from --cui-resizable-handle-hover-background (--cui-resizable-handle-active-background while dragging) to transparent.
Floating panel
ResizableFloatingPanel floats one panel over its positioned parent, so the content behind stays full-bleed. Its width lives in --resizable-floating-width: drag the inner edge, use the arrow keys (Shift for bigger steps), Home and End for the limits, or double-click to restore defaultSize. Sizes are pixels; the panel never grows past its parent.
Composition
Split panels
- <ResizablePanelGroup>
- first panel
- <ResizablePanel />
- <ResizableHandle />
- second panel
- <ResizablePanel />
- first panel
Floating panel
- positioned parent
- <ResizableFloatingPanel>
- panel content
- <ResizableFloatingPanel>
Installation
The Control UI source installs this primitive from src/registry/sources/control-ui/ui/resizable.tsx.
Raw code
Primary installed source
Knobs
Typed custom properties the recipe paints with. Set one on the root — style, a utility class, or a skin — and every slot inherits it.
--cui-resizable-* · 10 knobsHow the cascade resolves--cui-resizable-group-background<color>var(--card)--cui-resizable-group-radius<length-percentage>var(--radius-panel)--cui-resizable-group-border-color<color>var(--border)--cui-resizable-group-border-width<length>var(--control-rim-width)--cui-resizable-handle-hover-background<color>oklch(from var(--foreground) l c h / 0.25)--cui-resizable-handle-active-background<color>oklch(from var(--foreground) l c h / 0.4)--cui-resizable-grip-radius<length-percentage>var(--radius-sm)--cui-resizable-grip-background<color>var(--card)--cui-resizable-grip-foreground<color>var(--muted-foreground)--cui-resizable-handle-background<color>transparent