Skip to content

Kbd

A keycap for shortcut hints, such as the K in Cmd K.

0.4 kB gzipSource Registry JSON

Keys

⌘KEsc↵

Installation

npx shadcn@latest add https://sproutboat.com/ikada/r/kbd.json

The CLI writes components/ikada/kbd.tsx and merges the ikada theme into your CSS. Or take it from the package: import { Kbd } from "@sproutboat/ikada";

Usage

import { Kbd } from "@/components/ikada/kbd";

<Kbd>⌘</Kbd>
<Kbd>K</Kbd>
<Kbd>Esc</Kbd>
<Kbd>↵</Kbd>

Examples

Keys

A keycap for shortcut hints. Decorative text: the control it sits in carries aria-keyshortcuts.
⌘KEsc↵

In a hint

⌘Kto search sprouts

Props

No props interface of its own; see src/components/kbd.tsx.

Source: src/components/kbd.tsx