Skip to content
Theme

Button

A button. Pressing works the same with mouse, touch, keyboard and screen readers.

Examples

Variants
Sizes and states

Props

Button

A button. Pressing works with mouse, touch, keyboard and screen readers alike.

PropTypeDefaultDescription
variant?ButtonVariant"secondary"primary for the one main action, secondary for the rest, quiet in toolbars, danger to destroy.
size?"sm" | "md""md"
childrenReactNode—

Also takes 110 props it passes to the underlying React Aria component or element (events, ARIA attributes, state such as isDisabled), documented by React Aria.

Keyboard

KeyDoes
Enter or SpacePresses the button
TabMoves focus to the next control

Accessibility

  • A real button element; disabled buttons are announced as unavailable.
  • A pending button shows a spinner announced as status, and stays focusable.
  • Every variant has a border, so its edge survives forced-colours mode.