Button
Clicky clicky
Class Reference Styling Variants
Sizing Options
Button('XLarge', cls='btn btn-xl')
Button('Large', cls='btn btn-lg')
Button('Medium', cls='btn')
Button('Small', cls='btn btn-sm')
Button('Xsmall', cls='btn btn-xs')
Auto-import documentation coming soon...
ℹ️ Note: Responsive prefixes require DaisyUI config
Button('Responsive', cls='btn btn-xs sm:btn-sm md:btn-md lg:btn-lg xl:btn-xl')
Auto-import documentation coming soon...
Size classes can be combined with...
State Handling
A('Link', role='button', cls='btn'),
Button('Button', type='submit', cls='btn'),
Input(type='button', value='Input', cls='btn'),
Input(type='submit', value='Submit', cls='btn'),
Input(type='radio', aria_label='Radio', cls='btn'),
Input(type='checkbox', aria_label='Checkbox', cls='btn'),
Input(type='reset', value='Reset', cls='btn')
Auto-import documentation coming soon...
Use ARIA attributes for proper accessibility when
handling disabled states
Loading States
Class Reference
Class name | Type | Description |
---|---|---|
btn | Component | Base button |
btn-neutral | Color | Neutral color variant |
btn-primary | Color | Primary color variant |
btn-secondary | Color | Secondary color variant |
btn-accent | Color | Accent color variant |
btn-info | Color | Info color variant |
btn-success | Color | Success color variant |
btn-warning | Color | Warning color variant |
btn-error | Color | Error color variant |
btn-outline | Style | Outline style variant |
btn-ghost | Style | Ghost style variant |
btn-link | Style | Text link appearance |
btn-active | Behavior | Pressed state styling |
btn-disabled | Behavior | Disabled appearance |
btn-xs | Size | Extra small size |
btn-sm | Size | Small size |
btn-md | Size | Medium size (default) |
btn-lg | Size | Large size |
btn-wide | Modifier | Wider horizontal padding |
btn-block | Modifier | Full-width display |
btn-square | Modifier | 1:1 aspect ratio |
btn-circle | Modifier | Circular shape |
Do you have a question? ask the community
Do you see a bug? open an issue on GitHub
LLMs Context: Full Markdown | This Component