Keyboard Key
x-bladewind::kbd renders a semantic <kbd>
element styled as a physical key, for documenting a shortcut in help text, a menu item, or command
documentation.
Press Esc to close.
<p>Press <x-bladewind::kbd>Esc</x-bladewind::kbd> to close.</p>
Key combinations
Pass keys as an array (or JSON string) to render a combo: each key in its own
pill, joined by "+". When keys is given, it takes priority over the default slot.
Open the command palette with Ctrl K
<x-bladewind::kbd :keys="['Ctrl', 'K']" />
Sizes
Set size to tiny, small (default), or regular.
<x-bladewind::kbd size="tiny">Tab</x-bladewind::kbd>
<x-bladewind::kbd size="small">Tab</x-bladewind::kbd>
<x-bladewind::kbd size="regular">Tab</x-bladewind::kbd>
Full List Of Attributes
| Option | Default | Available Values |
|---|---|---|
| keys | (none) | Array or JSON string of key labels for a combo. Takes priority over the default slot. |
| size | small | tiny | small | regular |
| class | (blank) | Additional CSS classes for the key (or the combo's wrapper, when using keys). |
Kbd with all attributes defined
<x-bladewind::kbd
:keys="['Ctrl', 'K']"
size="regular"
class="ml-2" />
resources > views > components > bladewind > kbd.blade.php