Resizable panelsPro
Trade space between panes by dragging or with the keyboard: rubber-band limits, squeezed content fades, collapsible panes leave a restore tab.
oxyn add resizable-panelsThe preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.
Rendered from Rust at build time · goes live when visible
When to use
- Trade space between files, editor and agent panes; the same model drives the app shell’s resizable sidebar that snaps to icons.
When not to use
- An assistant docked beside a page: use AI side panel instead.
- The app frame: use App shell instead.
- An app sidebar: use Sidebar instead.
Installation
Resizable panels is part of Oxyn Pro; the preview is free. Pro items install with the oxyn CLI once your licence is signed in; until then Pro members copy the code from this page.
oxyn add resizable-panelsUsage
The preview is free. Pro opens the code of every Pro component, screen and template.
Examples
Ide
Files, editor and agent panes.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Two
Two panes with a grip handle.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Vertical
Stacked editor and terminal (Oxyn plus).
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Readout
Shares shown in each pane header.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
API reference
ResizablePanels
| Prop | Type | Default | Description |
|---|---|---|---|
panesrequired | Vec<PaneView> | — | Panes. |
label | String | "Panels" | Group label. |
height | f32 | 320.0 | Height px. |
vertical | bool | Default::default() | Stack vertically. |
handle | String | "line" | `line` · `grip`. |
readout | bool | Default::default() | Show each pane's share. |
on_layout_change | EventHandler<Vec<f32>> | — | Layout settled (percent shares). |
Read from the Rust signature and doc comments.
Keyboard interactions
| Key | Action |
|---|---|
| ← → | Move the divider 16 px (Shift: 64 px) |
| HomeorEnd | To a limit |
| Enter | Collapse or restore the neighbour |
| Escape | Cancel a drag |
| Double-click | Reset the layout |
Accessibility
- Dividers are focusable separators with aria-valuenow, min, max and valuetext.
- Collapsed panes are inert; the group is labelled.
From the spec
Each divider is a focusable separator with aria-orientation, aria-controls, aria-valuenow/min/max in percent and aria-valuetext (“Files 25 %”, or “Files hidden, press Enter to show”). Collapsed panes are inert.
Motion & interaction
Dividers follow the pointer 1:1 (pointer capture) and clamp; a pane pushed well past its minimum snaps shut and leaves a small restore tab that pops in. Content fades as a pane is squeezed below its minimum.
Timing
| Transition | Duration | Easing | Reduced motion |
|---|---|---|---|
| Line hover | 120 ms | linear | instant |
| Restore tab | 260 ms | pop | fade |
| Squeeze fade | 120 ms | linear | instant |
Responsive behaviour
- Needs a definite height; panes do not stack on mobile (switch to tabs).
- Pointer capture with touch-action none for touch, pen and mouse.
Edge cases (spec)
Needs a definite height. Container resizes scale the panes. Keyboard limits never collapse (Home / End clamp). Panes do not stack on mobile; switch to tabs.
Notes for AI
- Import
ResizablePanels,PaneViewfromoxyn_dioxusand includePRIMITIVES_CSSplus the token stylesheet once. - A GPUI version exists:
ResizableElinoxyn_gpui. - Props to set first:
panes. - Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.