All components
Command
Keyboard shortcut groups that space and mute a row of key hints.
⌘K
Sizes
⌘Kxs
⌘Ksm
⌘Kmd
⌘Klg
Install
zsh — command
1bunx stylexblocks add commandUsage — Base UI
command.tsx
1234567891011121314import * as stylex from "@stylexjs/stylex";import { Command } from "#components/ui/base-ui/command.tsx";import { kbdSizes, kbdStyles, kbdVariants } from "@stylexblocks/ui/recipes/kbd.ts";
export function Example() { return ( // the size prop resolves through the StyleX recipe (exposed as // data-size); composition via the render prop <Command size="sm"> <kbd {...stylex.props(kbdStyles.base, kbdSizes.sm, kbdVariants.raised)}>⌘</kbd> <kbd {...stylex.props(kbdStyles.base, kbdSizes.sm, kbdVariants.raised)}>K</kbd> </Command> );}