Skip to main content
The Button component is a primitive button element with built-in variant support and theme-aware styling.

Import

Usage

Props

string
default:"'primary'"
Button variant from theme.buttons. The component uses the primary variant by default.
ThemeUIStyleObject
Theme-aware styles to customize the button appearance.
boolean
Disable the button.
'button' | 'submit' | 'reset'
HTML button type attribute.
(event: React.MouseEvent) => void
Click event handler.

Inherited Props

Button extends Box and accepts:
  • All standard HTML button attributes
  • Box spacing props (m, p, mx, my, px, py, etc.)
  • Box color props (color, bg, opacity)

Default Styles

The Button component includes these base styles:

Examples

Basic Button

Button Variants

Custom Styling

Responsive Button

Full Width Button

Icon Button

Loading State