Usage

Props

NameTypeRequiredDefaultDescription
icon
ReactNode
false

The icon to display on the left side of the label. This should be an icon from @procore/core-icons.

since

10.19.0

selected
boolean
false

Set the current value of the toggle button

default

false

since

10.19.0

sizefalse

The toggle button size

since

10.19.0

selected

disabled (Off)

disabled (On)

Icon buttons

You can add a SVG Icon component as a prop to icon.

Using the icon prop

Using the icon prop will always place the icon on the left side of the button. Or in the center of the button, if no label appears.

size

Using the size prop will change the size of the toggle button.

block

The block boolean sets 100% width on the button. It will fill the width of the parent container.