Keyboard key and shortcut display component with a realistic keycap style.
Made by LéoInstallation
Usage
Props
Kbd
| Prop | Type | Default | Description |
|---|---|---|---|
size | "sm" | "md" | "lg" | "md" | Size of the key cap. |
children | ReactNode | — | The key label (text or symbol). |
className | string | — | Extra classes on the kbd element. |
Shortcut
| Prop | Type | Default | Description |
|---|---|---|---|
keys | string[] | — | Ordered list of keys in the shortcut. |
separator | ReactNode | "+" | Separator displayed between keys. |
size | "sm" | "md" | "lg" | "md" | Size passed to each Kbd. |
className | string | — | Extra classes on the wrapper span. |