App Switcher

The control at the top of a sidebar that names the current space and switches to another: a mark, a name, a plan stamp and a two-arrow glyph, opening a menu of the other spaces.

tsx
import {
  AppSwitcher,
  AppSwitcherMenu,
  AppSwitcherItem,
  AppSwitcherFooter,
} from "@pestoui/core"

With a menu

Pass an AppSwitcherMenu as the child and the trigger becomes a dropdown. active marks the current space with a tick; AppSwitcherFooter holds actions below a separator.

Sizes, and no menu

Three sizes. With no children the switcher is a plain button — it does not claim a menu it cannot open.

Props

PropTypeDefaultDescription
labelReactNode—On AppSwitcher and AppSwitcherItem. Required. The space's name; truncates.
markReactNode—On AppSwitcher and AppSwitcherItem. Leading identity chip. Sized and clipped by its frame, so it needs no dimensions of its own.
planstring—On AppSwitcher and AppSwitcherItem. A short plan stamp, rendered as a quiet badge.
size"sm" | "default" | "lg""default"On AppSwitcher. Padding, radius, mark size and text size.
srLabelstring—On AppSwitcher. Announced ahead of the name, for callers who want the action spelled out.
childrenReactNode—On AppSwitcher. An AppSwitcherMenu. Omit it and the trigger is a plain button.
AppSwitcherMenu labelReactNode—On AppSwitcherMenu. Visible heading above the list.
align / sideOffset"start" | "center" | "end" / number"start" / 6On AppSwitcherMenu. Placement against the trigger.
activebooleanfalseOn AppSwitcherItem. Marks the current space.

Pesto UI · 117 documented components