# Button > Interactive button component with type-safe variants, sizes, and loading state. Source: https://shellui.dev/docs/v0.3/components/form/button The Button component provides a flexible, accessible button for Blazor applications with enum-based variants and sizes following shadcn/ui patterns. ## Installation ```bash shellui add button ``` ## Usage ### Basic ```razor ``` ### Variants ```razor ``` ### Sizes ```razor ``` ### Loading and Disabled ```razor ``` ### With Icon ```razor ``` ### Event Handling ```razor @code { private void HandleClick(MouseEventArgs args) { // Handle button click } } ``` ## API Reference | Parameter | Type | Default | Description | |-----------|------|---------|-------------| | `Variant` | `ButtonVariant` | `Default` | Visual style: `Default`, `Secondary`, `Destructive`, `Outline`, `Ghost`, `Link` | | `Size` | `ButtonSize` | `Default` | Button size: `Default`, `Sm`, `Lg`, `Icon` | | `Type` | `string` | `"button"` | HTML button type attribute | | `Class` | `string?` | `null` | Additional CSS classes | | `Disabled` | `bool` | `false` | Disables the button | | `IsLoading` | `bool` | `false` | Shows loading spinner and disables interaction | | `OnClick` | `EventCallback` | — | Click event callback | | `ChildContent` | `RenderFragment` | `null` | Button content | ## Accessibility - Uses native `