Join our Discord community
Visualization

kbd

Keyboard shortcut display component for React and Next.js applications. Built with TypeScript support, Tailwind CSS styling, and shadcn/ui design featuring ARIA labels, custom separators, and modifier key support.

Powered by

Loading component...

Installation

npx shadcn@latest add https://www.shadcn.io/registry/kbd.json
npx shadcn@latest add https://www.shadcn.io/registry/kbd.json
pnpm dlx shadcn@latest add https://www.shadcn.io/registry/kbd.json
bunx shadcn@latest add https://www.shadcn.io/registry/kbd.json

Features

  • Keyboard shortcuts - Visual key combination display with compound component design using React composition
  • ARIA intellisense - Modifier key labels with accessibility support using ts-key-enum integration
  • Custom separators - Configurable key dividers for different display styles using TypeScript props
  • Monospace styling - Consistent key appearance with font controls for Next.js applications
  • Flexible theming - Complete styling control with className props using Tailwind CSS utilities
  • Key combinations - Support for single keys and complex shortcuts using shadcn/ui patterns
  • Open source - Free keyboard component with accessibility and customization features

Examples

In Text

Loading component...

With Custom Separator

Loading component...

Use Cases

  • Documentation - Keyboard shortcut references in help sections
  • Application menus - Hotkey displays in navigation and commands
  • Tutorial interfaces - Interactive guides with keyboard instructions
  • Accessibility aids - Screen reader friendly shortcut indicators

Implementation

Built with ts-key-enum for modifier key support. Uses compound pattern for flexible composition. Supports custom separators and monospace styling. ARIA-compliant for accessibility.