Button
To trigger an operation.
#
When To UseA button means an operation (or a series of operations). Clicking a button will trigger corresponding business logic.
#
Examples#
Basic#
Variant#
Rounded#
Icon#
Disabled#
Loading#
Sizes#
APIProperty | Description | Type | Default |
---|---|---|---|
variant | set different variant to display other colors of button | 'primary' 'primary-invert' 'danger' 'danger-invert' 'regular' 'normal' | |
size | the size of button | 'sm' | 'md' | 'lg' | 'md' |
loading | set the loading status of button | boolean | false |
rounded | set the button is rounded or not | boolean | false |
disabled | disabled state of button | boolean | false |
icon | set the icon of button, see: Icon component | IconType | |
onClick | set the handler to handle click event | (event: MouseEvent) => void |