Button

Documentation and examples for the Button component.

Preview

Properties

PropTypeDefaultDescription
variant"primary" | "outline" | "secondary" | "danger" | "ghost""primary"The visual style of the button.
size"sm" | "md" | "lg""md"The visual size of the button.
onClick() => void-Function called when clicked.
refstring-The reference for the button.

Usage

Follow these steps to add and use Button.

1

Create next app (skip if you already have setup a next app)

terminal
npx create-next-app@latest --yes
2

Install

terminal
npx modui-uikit@latest add button
3

Implement

typescript
import { Button } from '@/components/ui/button'
  
  export default function Example() {
    return (
      <Button variant="outline" size="sm">
        Click Me
      </Button>
    )
  }