1 | |
A primary action — link or button — in four variants, four sizes, with an optional icon.
| Prop | Type | Default |
|---|---|---|
label
Button text. Also accepts a content block.
|
String | nil |
href
When present, renders an <a>; otherwise a <button>.
|
String | nil |
variant
One of VARIANTS: primary, secondary, muted, ghost.
|
String | "primary" |
size
One of SIZES: xs (28px, default), sm (32px), md (36px), lg (40px).
|
String | "xs" |
shape
One of SHAPES: square (8px radius) · rounded (pill).
|
String | "square" |
icon
Caller-selected Central icon name. Add the exact glyph in the consumer with `node script/icons-central.mjs add <name>`, then pass that name here. Button does not own a fixed icon fixture.
|
String | nil |
disabled
Disables the element (button attr / aria-disabled on links).
|
Boolean | false |
type
Button type attribute: "button", "submit", or "reset".
|
String | "button" |
**html_options
Any extra HTML attributes (data-*, aria-*, …).
|
Hash | — |