Start here
  • InstallationAdd Nelumbo to a shadcn project
  • ThemingBrand accent, neutrals, dynamic color
  • Biology componentsSequences, maps, plates and trees
  • katalyx.bio

    Resizable

    Panels the person can resize by dragging a handle or with the arrow keys: an editor beside its preview, a sidebar, a mail list over a reading pane. There is no divider line. The panels are tonal surfaces with a few pixels of background between them, and the handle is a small grip that grows and turns primary when you reach for it.

    Install

    npx shadcn@latest add @nelumbo/resizable

    Horizontal

    Drag the grip, or Tab to it and use the arrow keys (Home and End go to the limits). withHandle keeps the grip visible; without it the gap is quiet until you hover or focus it.

    Sidebar

    30%

    Content

    70%

    Without a visible grip

    Leave out withHandle for a quieter layout. The grip fades in under the pointer and on keyboard focus.

    One

    Two

    Three

    Vertical

    Header

    Body

    Nested

    A mail layout: folders on the left, the list over a reading pane on the right. A panel that only holds another group is transparent, so the gaps stay consistent.

    • Maya Kowalski
    • Kenji Watanabe
    • Léa Martin
    • Omar Haddad

    Review moved to Thursday

    From Maya Kowalski

    The prototype needs one more pass before we show it. Can everyone confirm Thursday at 10?

    Today, 9:41

    Usage

    import { ResizableHandle, ResizablePanel, ResizablePanelGroup } from "@/components/ui/resizable"​// shadcn's API<ResizablePanelGroup direction="horizontal" className="h-48">  <ResizablePanel defaultSize={30}>Sidebar</ResizablePanel>  <ResizableHandle withHandle />  <ResizablePanel>Content</ResizablePanel></ResizablePanelGroup>​// A panel that only holds another group<ResizablePanel className="overflow-hidden bg-transparent">  <ResizablePanelGroup direction="vertical">…</ResizablePanelGroup></ResizablePanel>

    Props

    PropTypeDefaultreact-resizable-panels' own props (direction, onLayout, autoSaveId, minSize, collapsible …) work as is
    ResizablePanelGroup direction"horizontal" | "vertical"Required
    ResizablePanel defaultSize / minSize / maxSizenumber (percent)Sizes are percentages of the group
    ResizablePanel classNamestringrounded-2xl tonal surfaceOverride for transparent or custom panels
    ResizableHandle withHandlebooleanfalseShow the grip all the time. Otherwise it appears on hover and focus
    ResizableHandle aria-labelstringNames the separator for screen readers
    KeyboardArrow keys resize, Home and End go to the limits, Enter collapses a collapsible panel