Hierarchie
Primary für die Hauptaktion, Secondary und Outlined für Nebenaktionen, Link für Tertiäres.
Aktionen
Primary actions and commands. One primary button per area; use outlined or link for secondary actions. Supports HTMX shorthands (get, post, target, swap, confirm ...).
Primary für die Hauptaktion, Secondary und Outlined für Nebenaktionen, Link für Tertiäres.
Danger für destruktive Aktionen, Success und Warning für bestätigende oder heikle Schritte.
SM 28, MD 36, LG 44 px; Icons links, rechts oder beidseitig.
Laden blockiert weitere Klicks und behält die Breite, deaktiviert ist nicht fokussierbar.
Inverted-Varianten auf Navy-Flächen; HTMX-Kurzformen post/target/confirm direkt am Button.
| Option | Standard | Werte | Beschreibung |
|---|---|---|---|
variant | 'primary' | Visual hierarchy. Inverted variants are for navy/dark surfaces. | |
size | 'md' | Height: sm 28, md 36, lg 44 px. | |
icon | '' | – | Leading Carbon icon. |
icon_right | '' | – | Trailing Carbon icon. |
label | '' | – | Text when the default slot is empty. |
block | False | – | Stretch to the container width. |
href | '' | – | Render a link with button styling instead of a <button>. |
type | 'button' | Native button type. | |
disabled | False | – | Disable the control (links get aria-disabled). |
loading | False | – | Show a spinner, keep the width and block clicks. |
Zusätzliche Attribute (z. B. class, aria-*, data-*) und HTMX-Kurzformen (get, post, get_url, post_url, target, swap, trigger, confirm) werden an das Element „root“ durchgereicht.