Overlays & feedback
Keyboard shortcuts
The “press ? for help” sheet — a searchable, grouped reference of every shortcut in the app, rendered as real keycaps. It completes the Command Palette: the palette runs commands, this teaches the keys.
npx shadcn@latest add @orbit/keyboard-shortcutsOverview
Click the trigger, press ? anywhere (it's ignored while you're typing in a field), or wire your own button — all three open the same sheet. It ships with the default Orbit shortcut set; pass shortcuts to replace it.
Open the sheet, then type in its search to filter the groups.
or press ? anywhere on this page
The sheet
A read-only cheat-sheet: grouped sections flow into columns, every chord renders as keycap chips, and the search filters by description or key — try “assign” or “g”. On Windows/Linux, ⌘ caps display as Ctrl.
Keyboard shortcuts
Capabilities
It’s a reference, not a menu — find a key fast and get back to work.
Filter by what you want to do (“assign”) or by a key. The grouped columns collapse to just the matches.
Each shortcut renders as styled ⌘ / ⇧ / letter caps with “+” joins and “or” alternates, so the chord is unmistakable.
General, Navigation, Create, Task actions, Selection and Views flow in a multi-column layout that fills the dialog.
? brings it up over the app, Esc dismisses. It never steals focus from what you were doing underneath.
Your own shortcuts
shortcuts takes any ShortcutGroup[] — each item is a label, a keys chord (one keycap per entry), and an optional alt chord shown after “or”. The title is swappable too.
Player shortcuts
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| shortcuts | ShortcutGroup[] | DEFAULT_SHORTCUTS | Grouped shortcut data: { label, items: ShortcutItem[] }. The spec's Orbit set is exported as DEFAULT_SHORTCUTS. |
| open | boolean | — | Controlled open state. Pair with onOpenChange. |
| defaultOpen | boolean | false | Initial open state when uncontrolled. |
| onOpenChange | (open: boolean) => void | — | Called when the sheet opens or closes (trigger, ?, Esc, scrim, ×). |
| hotkey | boolean | true | Global ? opens the sheet — ignored while typing in inputs. Turn off to bind your own. |
| title | string | "Keyboard shortcuts" | Dialog heading, shown before the search field. |
| placeholder | string | "Search shortcuts…" | Search input placeholder. |
| inline | boolean | false | Render the sheet in the page flow instead of a ? dialog — for docs and embeds. |
| children | ReactNode | — | Trigger slot — e.g. <KeyboardShortcutsTrigger />. Ignored when inline. |
| className | string | — | Class applied to the 720px sheet. |
| Prop | Type | Default | Description |
|---|---|---|---|
| ShortcutItem.label | string | — | What the shortcut does — e.g. “Open command palette”. Searched. |
| ShortcutItem.keys | string[] | — | The chord, one keycap per entry — e.g. ["⌘", "K"]. Searched. ⌘ displays as Ctrl on non-Apple platforms. |
| ShortcutItem.alt | string[] | — | Alternate chord, shown after “or” — e.g. J or K. |
| ShortcutGroup.label | string | — | Section header — e.g. “Navigation”. Groups with no matches disappear while filtering. |
| KeyboardShortcutsTrigger.label | string | "Keyboard shortcuts" | Label of the “? Keyboard shortcuts” trigger button. |
| Keycap.label | string | — | Exported keycap chip — 22px, mono, heavier bottom border — for building your own key hints. |
Usage
Open it with ? and close with Esc. To run a command by name rather than recall a key, the Command Palette is the companion.
Mirror the real bindings
Every key here must actually work in the app. A cheat-sheet that lies is worse than none.
Make it the only way in
Shortcuts accelerate; they don’t replace. Every action needs a clickable path too, for discoverability and a11y.
Group by task
Organize by what people are trying to do — Create, Navigate — not alphabetically by key. Intent is how they search.
Overload one key
Avoid the same key meaning different things in the same context. Predictability is the whole value of a shortcut.
Keyboard & accessibility
The overlay is a Base UI Dialog — role=dialog with aria-modal, a focus trap that lands on the search field, and focus restore on close. The ? hotkey never fires while an input, textarea, select, or contenteditable has focus, and keycaps render as semantic <kbd> elements.