Installation
Usage
Component Code
Examples
- Default
- Outline
- Secondary
- Ghost
- Destructive
- With Icon
- Icon
- Sizes
The default button variant.
Variants
The Button component supports the following variants:default- Primary button styledestructive- For destructive actionsoutline- Outlined button with transparent backgroundsecondary- Secondary, less prominent styleghost- Minimal styling, visible on hoverlink- Styled as a link
Sizes
Available sizes:xs- Extra small (h-6)sm- Small (h-8)default- Default (h-9)lg- Large (h-10)icon- Square icon button (size-9)icon-xs- Extra small icon (size-6)icon-sm- Small icon (size-8)icon-lg- Large icon (size-10)
API Reference
Button
| Prop | Type | Default |
|---|---|---|
variant | "default" | "outline" | "ghost" | "destructive" | "secondary" | "link" | "default" |
size | "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | "default" |
asChild | boolean | false |
className | string | - |