Click Event

Add onClick event to the button.


Button


Full Width


Button Group


Secondary Button


API


Button

import {Button} from '@uixkit.react/components/Button/index.tsx';
PropertyTypeDefaultDescription
hrefstring-Providing a href will render an element. Otherwise, it will be a element
statusdisabled | waiting-The state of the button
borderthin | medium | thick | white-The thickness and style of the border
backgroundprimary | secondary | hyperlink | hyperlink2 | transparent | fillwhite-background color
spacingbottom | left | right-To create space around buttons
cornerspill | rounded-Add rounded corners to button
sizefullwidth | tiny | small | medium | large-Set the size of button
iconPositionleft | right-Set the icon position
iconReactNode-Set the icon component of button
targetstring_selfThe target attribute specifies where to open the linked document
onClickfunction-Set the handler to handle click event

It accepts all props(include data-* attributes) which native buttons support.

ButtonGroup

import {ButtonGroup} from '@uixkit.react/components/Button/index.tsx';
PropertyTypeDefaultDescription
fullwidthbooleanfalseThe button group has an automatic set width of 100%
spacingbottom | left | right-To create space around group