| 1 | import { cn } from "@/lib/utils" |
| 2 | |
| 3 | function Kbd({ className |
| 4 | return ( |
| 5 | <kbd |
| 6 | data-slot="kbd" |
| 7 | className={cn( |
| 8 | "pointer-events-none inline-flex h-5 w-fit min-w-5 items-center justify-center gap-1 rounded-sm bg-muted px-1 font-sans text-xs font-medium text-muted-foreground select-none", |
| 9 | "[&_svg:not([class*='size-'])]:size-3", |
| 10 | "[[data-slot=tooltip-content]_&]:bg-background/20 [[data-slot=tooltip-content]_&]:text-background dark:[[data-slot=tooltip-content]_&]:bg-background/10", |
| 11 | className |
| 12 | )} |
| 13 | {...props} |
| 14 | /> |
| 15 | ) |
| 16 | } |
| 17 | |
| 18 | function KbdGroup({ className |
| 19 | return ( |
| 20 | <kbd |
| 21 | data-slot="kbd-group" |
| 22 | className={cn(" |
| 23 | {...props} |
| 24 | /> |
| 25 | ) |
| 26 | } |
| 27 | |
| 28 | export { Kbd, KbdGroup |