@redrob-labs/ui v1.8.0 · Redrob Group Design System 2026

AppShell

Frames · src/components/AppShell/AppShell.tsx

The product frame: sidebar, the work, an optional rail.

The lockup goes through Mark rather than a bare img, so it follows the theme. A bare img here is how the first screen lost its wordmark in dark.

product is validated against the eight real products and dropped otherwise. The component knows only the attribute; the colours are the product-<p>-wash tokens. An unrecognised name would set an attribute that matches no token and silently render no wash, so it is rejected instead.

main holds the page heading, not just the body, so the skip link lands on the one h1 rather than above it. tabIndex={-1} is what lets focus actually arrive.

The folded state is remembered per browser when uncontrolled, and every localStorage call is wrapped because a private window throws.

Import

import { AppShell } from '@redrob-labs/ui';

Rendered

The design system's own preview case, run against this package's build. The parity gate compares this rendering to the reference bundle's.

Props

PropTypeNotes
product string Product name, e.g. Cowork. Sets the product wash at the top of the sidebar.
surface 'raised' | 'flat' flat joins the shell-owned regions (sidebar, work, rail, foot) into one continuous surface, so a downstream app that wants a flat workspace no longer has to override several DS surface classes. Defaults to raised, the inset frame with a sunken sidebar (unchanged from 1.6.0). Flat sets data-surface="flat" and reads --rr-shell-surface (default --surface-base) for the ground and --rr-shell-nav-active for the nav hover/current state -- set either on any ancestor to retint without a class override.
mark string
markDark string
symbol string The symbol alone, shown when the sidebar is folded.
nav AppShellNavItem[]
navLabel string
aside React.ReactNode Extra content at the bottom of the sidebar.
asideFolded React.ReactNode What stays at the bottom of the sidebar when it is folded (or the window is narrower than 900px), in place of aside - typically the account as an avatar-only button that opens the same menu. Without it the aside is hidden while folded, as before, and anything only it held is out of reach.
theme React.ReactNode
title React.ReactNode
meta React.ReactNode A line under the title: what this screen is showing.
actions React.ReactNode
foot React.ReactNode
rail React.ReactNode A right-hand panel about the current run.
railLabel string
measure boolean false lets the work area run full width instead of holding a reading measure.
collapsible boolean
collapsed boolean
defaultCollapsed boolean
collapseLabel string
expandLabel string
skipLabel React.ReactNode
windowInset { top?: number; end?: number; endHeight?: number } Space the desktop window's own controls take over the page, for a frameless window. top is reserved above the sidebar brand (the macOS traffic lights of titleBarStyle: 'hiddenInset'); end is the width and endHeight (default 40) the height of the strip at the top-right corner (the Windows caption buttons of titleBarOverlay), kept clear in the header, or in the rail when there is one. Pixels. Omit in a browser.
dragRegion boolean Makes the brand row and the header drag the window, for a frameless desktop window. Controls inside them stay clickable. Ignored by browsers, which have no app-region.
className string
children React.ReactNode
onCollapsedChange (collapsed: boolean) => void
onNavigate (href: string, event: React.MouseEvent<HTMLAnchorElement>) => void Called when a nav link is followed with a plain click, for an app with a client-side router. Call event.preventDefault() and route to href yourself; leave it alone and the browser navigates. A click with a modifier key or another button is never passed here, so "open in new tab" keeps working.

Exported types

AppShellNavItem