Atelier UI

Search components…

Search components…

Icon Rail

A narrow icon-only sidebar rail with tooltips, a sliding active indicator and an expandable labels mode.

Edit in sandbox

Copy a prompt for your AI coding tool with the source, dependencies and usage

Props

IconRailProps

Also accepts all props of Omit<React.ComponentProps<"aside">, "children" | "onChange">

PropTypeDefaultDescription
items* requiredIconRailItem[]—Primary destinations, listed from the top
bottomItemsIconRailItem[][]Pinned to the bottom, e.g. settings and the account avatar
headerReact.ReactNode—Brand mark shown at the top
activeIdstring——
defaultActiveIdstring——
onActiveChange(id: string) => void——
expandedboolean—Whether labels are shown (controlled)
defaultExpandedbooleanfalse—
onExpandedChange(expanded: boolean) => void——
expandedWidthnumber224Width in px when expanded

Install

$ npx shadcn@latest add https://chromotion.dev/r/icon-rail.json

More like this