Button

Displays a button or a component that looks like a button.

Preview

Installation

npm install @sickui/core

Usage

import { Button } from "@sickui/core"

export default function Example() {
  return <Button>Button</Button>
}

Examples

Default

<Button>Button</Button>

Variants

<Button variant="default">Default</Button>
<Button variant="destructive">Destructive</Button>
<Button variant="outline">Outline</Button>
<Button variant="secondary">Secondary</Button>
<Button variant="ghost">Ghost</Button>
<Button variant="link">Link</Button>

Sizes

<Button size="sm">Small</Button>
<Button size="default">Default</Button>
<Button size="lg">Large</Button>

Props

PropTypeDefaultDescription
variant"default" | "destructive" | "outline" | "secondary" | "ghost" | "link""default"The variant of the button
size"default" | "sm" | "lg" | "icon""default"The size of the button
asChildbooleanfalseChange the default rendered element for the one passed as a child