Button
Displays a button or a component that looks like a button.
Variants
Sizes
With Icon
Props
| Prop | Type | Default | Description |
|---|
variant | 'default' | 'destructive' | 'success' | 'warning' | 'info' | 'outline' | 'secondary' | 'ghost' | 'link' | 'default' | The visual style variant of the button. |
size | 'default' | 'sm' | 'lg' | 'icon' | 'icon-sm' | 'icon-lg' | 'default' | The size of the button. |
as | string | 'button' | The element or component to render as. |
asChild | boolean | false | Render as child element, merging props onto the child. |
Slots
| Slot | Props | Description |
|---|
default | - | Button content (text, icons, etc.) |