Button

General

A versatile button component with multiple variants and sizes.

Preview

Usage

<Button variant="primary">Click me</Button>
<Button variant="outline">Cancel</Button>

Props

NameTypeDefaultDescription
variant'primary' | 'secondary' | 'outline' | 'ghost' | 'link''primary'The visual style of the button.
size'sm' | 'md' | 'lg' | 'icon''md'The size of the button.
disabledbooleanfalseWhether the button is disabled.
hrefstringundefinedIf provided, renders as an anchor tag.
type'button' | 'submit' | 'reset''button'The HTML button type.

Events

NameDescription
clickFired when the button is clicked.

Slots

NameDescription
defaultThe content of the button.