Actions

Button

Trigger an operation, submit a form, or confirm a decision with a native button.

Basic usage

Button defaults to type="button". Use type="submit" to submit a form. Use an <a> link to navigate to a URL.

Variants

variant sets the visual emphasis. Use solid for the main action, outline or soft for alternatives, and ghost for quieter actions. link gives the button a link appearance.

Tones

tone conveys the intent of the action and follows the theme. For example, danger signals a destructive action.

Sizes

Default heights range from 24 px (xs) to 48 px (lg). With responsive, the button uses one smaller size below 640 px. xs keeps its original height. Use rounded for pill corners and fullWidth to fill the available width.

Icons

Use startIcon or endIcon to support a label. Give an icon-only button an accessible name with aria-label.

States

Use disabled for an unavailable action and loading while an operation runs. While loading, the button blocks activation, retains its width and accessible name, and exposes aria-busy. Use aria-pressed for a toggle action such as bookmarking. Hover, use Tab, or hold the button down to see hover, focus, and :active.

API

Button also accepts native HTML button attributes, events, and refs. Keyboard focus and Enter or Space activation follow native behavior.

PropValues and behaviorDefault
variantsolid, outline, soft, ghost, linksolid
toneprimary, neutral, info, success, warning, dangerprimary
sizexs, sm, md, lgmd
roundedbooleanfalse
fullWidthbooleanfalse
responsivebooleanfalse
iconOnlybooleanfalse
startIcon / endIconJSX.Element—
loadingbooleanfalse
disabledbooleanfalse
typebutton, submit, resetbutton
aria-labelstring—
aria-pressedtrue, false, mixed—