Variants (class names)
Sizes
States
API Reference
Props mirror Base UI React where applicable, adapted for Svelte 5. Native HTML attributes for the rendered element are also accepted unless noted.
Button
Extends HTML element attributes.
| Property | Type | Default | Description |
|---|---|---|---|
disabled | boolean | false | Whether the control ignores user interaction. |
focusableWhenDisabled | boolean | false | Whether the control remains focusable when disabled. |
render | string | — | HTML element tag to render. Defaults to `button`. |
type | 'button' | 'submit' | 'reset' | undefined | — | Defaults to `button`. Set `submit` explicitly for form submit buttons. |
children | Snippet<[{ disabled: boolean }]> | — | Content rendered inside the part. |
| Data attribute | Description |
|---|---|
data-disabled | Present when the part is disabled. |