Overview
- Getting Started
- Loading States
- Forms
- Feature Flags
- Portal
- Show
- For
- Text
- Toggle
- Local Storage
Actions
- Button
- Icon Button
Communication
- Admonition
- Accordion
- Avatar
- Notifications
- Progress Indicators
- Tag
- Tooltip
Containment
- Confirm Modal
- Prompt Modal
- CTA Modal
- Modaldeprecated
- Dialog
- Table
Navigation
- Menu
- Tabs
Selection
- Drag & Drop
- Checkbox
- Date Picker
- Radio
- Rating
- Select
- Combobox
- Switch
Inputs
- Field
- Input
- Textarea
- Labeldeprecated
- Fieldset
- Field Messagedeprecated
- File Uploader
Hooks & Helpers
- split-props
- trap-focusdeprecated
- use-root-colors
- use-theme
- use-theme-context
- use-toggledeprecated
Icon Button
Icon buttons help people take minor actions with one tap
1import { IconButton } from '@cerberus/react'
Usage
Sizes
The IconButton
component comes in two sizes: sm
, lg
. You can set the size by using the size
prop.
As Child
The IconButton
component can be used as a child component. This is useful when you want to use the button styles on a different element.
Primitives
You can utilize the primitive components to customize the button.
Component | Description |
---|---|
IconButton | The context provider for the Button parts |
API
Props
The IconButton
component is an abstraction of the primitives and accepts the following props:
Name | Default | Description |
---|---|---|
palette | action | The color palette (any of the Cerberus palettes) of the button. |
usage | filled | The style treatment of the button. |
shape | sharp | The shape of the button. |
asChild | Render the Button as the child component. |
1import { IconButton } from '@cerberus/react'
Usage
Sizes
The IconButton
component comes in two sizes: sm
, lg
. You can set the size by using the size
prop.
As Child
The IconButton
component can be used as a child component. This is useful when you want to use the button styles on a different element.
Primitives
You can utilize the primitive components to customize the button.
Component | Description |
---|---|
IconButton | The context provider for the Button parts |
API
Props
The IconButton
component is an abstraction of the primitives and accepts the following props:
Name | Default | Description |
---|---|---|
palette | action | The color palette (any of the Cerberus palettes) of the button. |
usage | filled | The style treatment of the button. |
shape | sharp | The shape of the button. |
asChild | Render the Button as the child component. |
1import { IconButton } from '@cerberus/react'
Usage
Sizes
The IconButton
component comes in two sizes: sm
, lg
. You can set the size by using the size
prop.
As Child
The IconButton
component can be used as a child component. This is useful when you want to use the button styles on a different element.
Primitives
You can utilize the primitive components to customize the button.
Component | Description |
---|---|
IconButton | The context provider for the Button parts |
API
Props
The IconButton
component is an abstraction of the primitives and accepts the following props:
Name | Default | Description |
---|---|---|
palette | action | The color palette (any of the Cerberus palettes) of the button. |
usage | filled | The style treatment of the button. |
shape | sharp | The shape of the button. |
asChild | Render the Button as the child component. |
1import { IconButton } from '@cerberus/react'
Usage
Sizes
The IconButton
component comes in two sizes: sm
, lg
. You can set the size by using the size
prop.
As Child
The IconButton
component can be used as a child component. This is useful when you want to use the button styles on a different element.
Primitives
You can utilize the primitive components to customize the button.
Component | Description |
---|---|
IconButton | The context provider for the Button parts |
API
Props
The IconButton
component is an abstraction of the primitives and accepts the following props:
Name | Default | Description |
---|---|---|
palette | action | The color palette (any of the Cerberus palettes) of the button. |
usage | filled | The style treatment of the button. |
shape | sharp | The shape of the button. |
asChild | Render the Button as the child component. |