Back to Button
Button

Loading

Static and interactive loading states.

API

PropTypeDefaultDescription
variant"solid" | "outline" | "soft" | "ghost" | "link" | "destructive"solidVisual style.
size"xs" | "sm" | "md" | "lg" | "icon" | "icon-sm" | "icon-lg"mdHeight, padding and icon scale.
fullWidthbooleanStretches the button to fill its container.
asChildbooleanfalseRender the child element instead of a <button>, via Slot.
loadingbooleanfalseShows a spinner, disables interaction, hides leadingIcon, sets aria-busy.
loadingLabelstringLoadingScreen-reader-only text announced while loading.
leadingIconReact.ReactNodeElement rendered before the label.
trailingIconReact.ReactNodeElement rendered after the label.
type"button" | "submit" | "reset"buttonNative button type. Defaults to "button" so buttons inside forms do not submit accidentally.
disabledbooleanNative disabled attribute.
classNamestringMerged with the generated variant classes via cn().
View full API on Button

More Button examples