Button

Button is an interactive component that allows users to perform actions such as submitting forms and toggling modals.

Usage

import { Button, ButtonGroup } from "@yamada-ui/react"
<Button />
<ButtonGroup.Root>
  <ButtonGroup.Item />
</ButtonGroup.Root>

Change Variant

Change Size

Change Color Scheme

Change Shape

To rounded corners, set fullRounded to true.

Disable

To disable, set disabled to true.

Add Icon

To add an icon, set a ReactNode to startIcon or endIcon.

Use Loading Animation

To use a loading animation, set loading to true. If you want to change the text during loading, use loadingMessage.

Grouping

Props

Accessibility

The Button follows the WAI-ARIA - Button Pattern for accessibility.

Keyboard Navigation

KeyDescriptionState
Space, EnterWhen element has focus, activates it.-

ARIA Roles and Attributes

ComponentRole and AttributeUsage
Buttonrole="button"Indicates that it is a button.
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd
2nd