Skip to content
Back

Sidebar NavPro

Grouped sidebar links with a sliding active indicator, collapsible groups and badges.

oxyn add sidebar-nav
Northline

Checkout redesign

Three flows to review before Thursday. The address step still drops 14% of mobile sessions.

AddressIn review · Marcus
PaymentReady · Emma
ReceiptDraft · Ava
The code is part of Oxyn Pro

The preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.

Get Pro

Rendered from Rust at build time · goes live when visible

When to use

  • Agent apps are no longer one chat column.
  • A coding agent window holds a thread list, a transcript, a diff, a terminal, a browser preview, a file tree and a status bar at once; the user moves between them dozens of times an hour and expects the layout to stay where they left it.
  • What we saw: drag-and-drop pane layout with chat, diff, browser, terminal, file, plan, tasks and subagent panes, pop-out to a window and minimize to a floating corner tile; a resizable 6-area layout (Verdent, note 03); split panes right or down, drag tabs between panes, resize dividers, layout remembered per workspace, single pane with a scrolling tab strip on phones, Cmd/Ctrl+B to swap chat and the secondary view (Hoplite, note 10); a sidebar resizable by dragging its right edge and collapsible from a top-left button (Hoplite, note 10); a rail that snaps to icon-only under ≈160 px with labels fading in ≈0.18 s [R046]; icon-anchored collapse where labels clip and icons don't move [R016]; "sidebar and side panel open/close animate without layout jumps" (Antigravity, note 08).
  • The user is trying to arrange the workspace once, move through it by keyboard, and never lose a panel.

When not to use

  • The prompt box for an agent, in six layouts: use Composer instead.
  • Grey shapes the size of what they stand in for, one sheen sweeping across all of them in step (or a staggered pulse), shown only after a short delay, then a crossfade into the content: use Skeleton instead.
  • A run as a line of checkpoints, like git for agents: use Checkpoint lanes instead.

Installation

Sidebar Nav 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.

Terminal
oxyn add sidebar-nav

Usage

Dioxus · rust
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

Examples

Default

A sliding active indicator and badges.

Northline

Checkout redesign

Three flows to review before Thursday. The address step still drops 14% of mobile sessions.

AddressIn review · Marcus
PaymentReady · Emma
ReceiptDraft · Ava
Code Pro
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

Compact

Compact rows.

Northline

Checkout redesign

Three flows to review before Thursday. The address step still drops 14% of mobile sessions.

AddressIn review · Marcus
PaymentReady · Emma
ReceiptDraft · Ava
Code Pro
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

Pinned

A pinned page active.

Northline

Checkout redesign

Three flows to review before Thursday. The address step still drops 14% of mobile sessions.

AddressIn review · Marcus
PaymentReady · Emma
ReceiptDraft · Ava
Code Pro
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

API reference

SidebarNav

PropTypeDefaultDescription
sectionsVec<NavSection>sample_sections()Sections.
activeString"home"Active id.
compactboolDefault::default()Compact density.
on_selectEventHandler<String>—Changed.

Read from the Rust signature and doc comments.

Keyboard interactions

KeyAction
TabMove between links
EnterOpen a link or toggle a group

Accessibility

  • Links carry aria-current; group headings expose aria-expanded.
From the spec
  • Resizer: role="separator", aria-orientation, aria-valuenow/min/max in px, aria-controls the panel, label "Resize file tree"; Enter toggles collapse and announces "File tree collapsed".
  • Docks: landmarks per §8; collapse buttons have aria-expanded.
  • Contrast: resizer line ≥ 3:1 against both neighbours when hovered or focused (1 px resting line may be subtle; it is not the only cue — the cursor and focus ring are).
  • Every drag has a keyboard path (resizer arrows, "Move tab to new split right" in the tab menu).
  • Live region: layout resets and pane pop-outs are announced politely; nothing is announced during drag.
  • Reduced motion: §6 last row.

Motion & interaction

  • Hover intent. The cursor changes immediately; the line thickens only after 300 ms so mouse travel across a resizer never flickers it.
  • Drag. Size follows the pointer 1:1, painted every frame; no easing while dragging. Content inside the resizing panel reflows live; heavy panels (diff, terminal grid) may freeze-scale their last frame during drag and reflow on release if a reflow costs > 8 ms (proposed).
  • Magnets. Within 8 px of a snap point the size jumps to it with a 1 px tick on the line and, on supported trackpads, a haptic tick (macOS only, opt-in).
  • Snap to rail ([R046], [R016]). Labels clip from the inline-end and fade over 180 ms while icons stay put (icon-anchored); expanding reverses with labels cascading 20 ms apart (cap 8).
  • Collapse / expand via shortcut. Width animates with spring.snap; the center's content does not slide — its scroll anchor holds (zero-jump rule) and only its width changes.
  • Overlay open. Dock slides in 16 px + fade with scrim fade; close reverses faster.
  • Tab drag to split. Ghost tab follows the pointer at 0.9 scale with 8 px shadow; the drop region fades in (120 ms) and morphs between halves with spring.snap; on release the new split opens from the drop edge.
  • Double-click reset. Size glides to default with spring.snap.
  • Restore. Never animated: the saved layout is the first frame (Hoplite's "Paint from your saved session" principle, note 10).
  • Corner tile minimize. Pane scales into the tile's position (dur.travel 240 ms); the tile keeps a live loader dot and a title; click restores along the reverse path.
Timing
TransitionDurationDelayEasing / springStaggerFrame rate
Resizer hover highlight120 ms in / 120 ms out300 msease.out—60 Hz
Drag follow0 (1:1)—none—display rate
Pixel readout tooltip120 ms fade400 ms stillease.out—60 Hz
Magnet tick80 ms line flash—ease.out—60 Hz
Snap to rail: labels out / in180 ms ([R046] ≈0.18 s)0ease.out20 ms, cap 8 (in only)60 Hz
Collapse / expand (shortcut)~220 ms settle0spring.snap—60 Hz
Overlay open / close200 ms / 160 ms; scrim 160 / 120 ms0ease.out / ease.in—60 Hz
Drop region in / morph120 ms / ~180 ms0ease.out / spring.snap—60 Hz
Split open on drop200 ms0spring.snap—60 Hz
Tab fly-back on cancel200 ms0ease.in-out—60 Hz
Corner-tile minimize / restore240 ms0ease.in-out—60 Hz
Layout persistdebounce 500 msafter release———
Breakpoint hysteresis48 px————
Reduced motionall size changes instant; labels and overlays use an 80 ms opacity crossfade; no ghost scaling (tab ghost is a flat outline); drag still follows 1:1 (it is direct manipulation)—linearnone—

Responsive behaviour

  • Fixed 240 px column.
Edge cases (spec)
  • Window too small for the saved layout (laptop after an external monitor): clamp fractions to minimums in dock priority center > bottom > left > right; collapse right first; never delete the saved layout — the clamped version is a view, the saved one is restored when space returns.
  • Multi-monitor / DPI change mid-drag: sizes are stored in logical px; a DPI change ends the drag.
  • Corrupt or future-version LayoutState: fall back to default + "Layout reset · Undo".
  • RTL: docks mirror (left dock becomes inline-start on the right); resize arrows invert so → always moves the resizer visually right; F6 order follows visual reading order.
  • Tiny sizes: rails at 48 px show 20 px icons with 16 px badges; below 600 px window width there are no side-by-side splits.
  • Dense IDE: 22 px tab strips, 6 px resizer hit area (still ≥ 8 px on touch-capable devices).
  • Touch: 12 px hit area, long-press 400 ms on a tab to start drag; overlay docks swipe closed.
  • Slow networks / remote panes: a pane whose content is remote shows its skeleton (skeletons.md) inside the restored frame; layout never waits on data.
  • Very fast agents opening many panes (diff, terminal, browser in 1 s): panes open into their dock's tab strip, not as new splits; an agent never creates a split without user permission (proposed).
  • Agent-opened pane while user types: the pane opens unfocused with a 1-pulse attention dot on its tab; focus stays with the user.

Notes for AI

  • Import SidebarNav from oxyn_dioxus and include STATUS_INDICATOR_CSS plus the token stylesheet once.
  • A GPUI version exists: SidebarNavEl in oxyn_gpui.
  • Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.

Guides

Oxyn · 74 free components · 264 Pro components · 96 screens · 20 blocks · Dioxus and GPUI