Skip to main contentSkip to search
Clay
  • Get Started
    • How to Use Clay
    • How to Read This Documentation
    • Composition Philosophy
    • Migrating From v2.x
    • Using Clay in JSPs
  • Components
    • Alert
    • Application Bar
    • Aspect Ratio
    • Autocomplete
    • Badge
    • Breadcrumb
    • Button Group
    • Buttons
    • Card
    • Chart
    • Color Picker
    • Data Provider
    • Date Picker
    • DropDown
    • Empty State
    • Form
      • Checkbox
      • Dual List Box
      • Input
      • Radio Group
      • Select
      • Select Box
      • Toggle Switch
    • Forms Hierarchy
    • Heading
    • Icon
    • Label
    • Layout
    • Link
    • List
    • Loading Indicator
    • Localized Input
    • Management Toolbar
    • Modal
    • Multi Select
    • Multi Step Nav
    • Nav
    • Navigation Bar
    • OverlayMask
    • Pagination
    • Pagination Bar
    • Panel
    • Picker
    • Popover
    • Progress Bar
    • Provider
    • Sidebar
    • Slider
    • Sticker
    • Table
    • Tabs
    • Text
    • Timelines
    • Time Picker
    • Toolbar
    • Tooltip
    • TreeView
    • Upper Toolbar
    • VerticalBar
    • Vertical Navigation
  • Contributing
  • CSS Framework
    • Paver
    • SCSS
    • Color
    • Grid
    • Content
      • Typography
      • C Kbd
    • Utilities
      • Accessibility
      • Autofit
      • Border
      • C Focus Inset
      • C Inner
      • Color Utilities
      • C Spacing Utilities
      • Display
      • Flex
      • Float
      • Inline Item
      • Overflow
      • Position
      • Shadow
      • Text
      • Vertical Align
      • Visibility
      • Width and Height
    • Playground
  • Examples
K
  • Docs
  • Sass API
  • Blog
  • Storybook
  • Codesandbox
  • Github
  • Use this menu to toggle between Atlas and Base Themes.

Buttons

yarn add @clayui/button

Buttons communicate an action to happen on user interaction.

  • Examples
  • Markup
  • API

Stable3.83.0View in LexiconCHANGELOGstorybook demos

  • Button
  • Button.Group
  • ButtonWithIcon

Button

PropertyDescription
alert
boolean
Flag to indicate if button is used within an alert component.
borderless
boolean
Flag to indicate if the button should be borderless.
block
boolean
Renders the button as a block element.
displayType
| null | 'primary' | 'secondary' | 'link' | 'success' | 'warning' | 'danger' | 'info' | 'unstyled'
Determines the button variant to use.

The default value is 'primary'
monospaced
boolean
Flag to indicate if button should be monospaced.
outline
boolean
Flag to indicate if the button should use the outline variant.
rounded
boolean
Flag to indicate if the button should be shaped like a pill.
size
'xs' | 'sm'
Determines the size of a button.
smallDeprecated
boolean
Indicates button should be a small variant. @deprecated since v3.72.0 - use size instead.
type


The default value is 'button'

Button.Group

PropertyDescription
spaced
boolean
Flag to indicate the spacing between the buttons.
vertical
boolean
Flag to indicate if buttons are stacked vertically.
role


The default value is 'group'

ButtonWithIcon

PropertyDescription
spritemap
string
Path to the location of the spritemap resource.
symbol
string
The id of the icon in the spritemap.
monospaced


The default value is true

How can this be improved? Create an issue!