← All controls

Core / Controls

Command Button

Displays an action with a keyboard shortcut hint.

Live example

Activate to open workspace search.

Interactive preview using local sample data. Styling is intentionally left to the consuming project.

Usage

<CommandButton shortcut="⌘K">Search</CommandButton>

Adopt to your project

Keep this component semantically neutral. Use its documented props for behavior and className for project-specific spacing, width, typography, and visual treatment.

Accessibility

A shortcut is supplementary; the action must be discoverable without it.

API reference

Public attribute
children
shortcut
onClick
disabled

The preview above uses a safe local fixture. Confirm exact TypeScript props when adapting it to your application.

Installation

Full library
pnpm install:project /absolute/path/to/your-project

Planned guided selection
Controls → Command Button