Button

Actions

Triggers actions or navigation. Supports five visual variants, three sizes, loading and disabled states.

Preview

Props API

PropTypeDefaultDescription
labelstring"Click me"Button text content (maps to default slot)
variantselect"primary" | "secondary" | "ghost" | "destructive" | "outline""primary"Visual style variant
sizeselect"sm" | "md" | "lg""md"Button size
disabledbooleanfalseDisables the button and prevents interaction
loadingbooleanfalseShows a spinner; implies disabled
fullWidthbooleanfalseStretches the button to fill its container

Usage

Use "primary" for the single main call-to-action per section. "secondary" and "ghost" work for supporting actions. Reserve "destructive" strictly for irreversible operations like permanent deletion. Never use more than one "primary" button in the same visual group.

Accessibility

  • Uses a native <button> element for full keyboard and screen reader support.

  • Disabled state sets aria-disabled="true" and prevents pointer events.

  • Loading state sets aria-busy="true" and provides a visually hidden loading label.

  • Focus ring uses a 2px outline with 2px offset — visible in all themes.