naive-ui/demo/documentation/components/button/enUS/index.md
2020-05-15 22:32:52 +08:00

1.3 KiB

Button

Button is used to trigger some actions.

Demos

basic
size
text
disabled
icon
events
shape
ghost
loading
group
debug

Props

Button Props

Name Type Default Description
color string null Only support #FFF, #FFFFFF, rgb(0, 0, 0) formatted colors.
size 'tiny' | 'small' | 'medium' | 'large' 'medium'
type 'default' | 'primary' | 'success' | 'info' | 'warning' | 'error' 'default'
text boolean false
block boolean false
ghost boolean false
disabled boolean false
circle boolean false
round boolean false
loading boolean false
keyboard boolean true Whether is supports keyboard operation.
icon-placement 'left' | 'right' 'left'
theme 'light' | 'dark' null

Button Group Props

Name Type Default Description
size 'tiny' | 'small' | 'medium' | 'large' null The buttons' size in button group. If set, the button's size prop inner group won't work.
vertical boolean false

Slots

Button Slots

Name Parameters Description
default ()
icon ()

Button Group Slots

Name Parameters Description
default ()

Events

Button Events

Name Parameters Description
click (e: MouseEvent)