Kbd
Theme-aware, responsive kbd component.
Usage
Components are auto-discovered. Use the component directly in any .wrn view:
<Kbd
size="default"
color="primary"
label="⌘ K"
/>Legacy mount name: data-component="Kbd".
Props and attributes
| Prop | Type | Requirement | Default |
|---|---|---|---|
size | string | Optional | "default" |
color | string | Optional | "primary" |
label | string | Optional | "⌘ K" |
class | string | Optional | "" |
Slots
default
Events
This component does not declare a custom event.
Source contract
Installed source: components/Kbd.wrn
component Kbd {
props {
size = "default"
color = "primary"
label = "⌘ K"
class = ""
}
view {
<kbd class="wire-next wire-next--color-{color} wire-next--size-{size} wire-next--kbd {class}">
<slot>{label}</slot>
</kbd>
}
}