--- title: Buttons sidebar_position: 1 sidebar_custom_props: icon: TbSquareRoundedPlusFilled --- import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; import { SandpackEditor} from '@site/src/ui/SandpackEditor' import buttonCode from '!!raw-loader!@site/src/ui/input/button/buttonCode.js' import buttonGroupCode from '!!raw-loader!@site/src/ui/input/button/buttonGroupCode.js' import floatingButtonCode from '!!raw-loader!@site/src/ui/input/button/floatingButtonCode.js' import floatingButtonGroupCode from '!!raw-loader!@site/src/ui/input/button/floatingButtonGroupCode.js' import floatingIconButtonCode from '!!raw-loader!@site/src/ui/input/button/floatingIconButtonCode.js' import floatingIconButtonGroupCode from '!!raw-loader!@site/src/ui/input/button/floatingIconButtonGroupCode.js' import lightButtonCode from '!!raw-loader!@site/src/ui/input/button/lightButtonCode.js' import lightIconButtonCode from '!!raw-loader!@site/src/ui/input/button/lightIconButtonCode.js' import mainButtonCode from '!!raw-loader!@site/src/ui/input/button/mainButtonCode.js' import roundedIconButtonCode from '!!raw-loader!@site/src/ui/input/button/roundedIconButtonCode.js' A list of buttons and button groups used throughout the app. ## Button
Props Type Description Default
className string Optional class name for additional styling
Icon `React.ComponentType` An optional icon component that's displayed within the button
title string The text content of the button
fullWidth boolean Defines whether the button should span the whole width of its container `false`
variant string The visual style variant of the button. Options include `primary`, `secondary`, and `tertiary` primary
size string The size of the button. Has two options: `small` and `medium` medium
position string The position of the button in relation to its siblings. Options include: `standalone`, `left`, `right`, and `middle` standalone
accent string The accent color of the button. Options include: `default`, `blue`, and `danger` default
soon boolean Indicates if the button is marked as "soon" (such as for upcoming features) `false`
disabled boolean Specifies whether button is disabled or not `false`
focus boolean Determines if the button has focus `false`
onClick function A callback function that triggers when the user clicks on the button
## Button Group
Props Type Description
variant string The visual style variant of the buttons within the group. Options include `primary`, `secondary`, and `tertiary`
size string The size of the buttons within the group. Has two options: `medium` and `small`
accent string The accent color of the buttons within the group. Options include `default`, `blue` and `danger`
className string Optional class name for additional styling
children ReactNode An array of React elements representing the individual buttons within the group
## Floating Button
Props Type Description Default
className string Optional name for additional styling
Icon `React.ComponentType` An optional icon component that's displayed within the button
title string The text content of the button
size string The size of the button. Has two options: `small` and `medium` small
position string The position of the button in relation to its sublings. Options include: `standalone`, `left`, `middle`, `right`
applyShadow boolean Determines whether to apply shadow to a button `true`
applyBlur boolean Determines whether to apply a blur effect to the button `true`
disabled boolean Determines whether the button is disabled `false`
focus boolean Indicates if the button has focus `false`
## Floating Button Group
Props Type Description Default
size string The size of the button. Has two options: `small` and `medium` small
children ReactNode An array of React elements representing the individual buttons within the group
## Floating Icon Button
Props Type Description Default
className string Optional name for additional styling
Icon `React.ComponentType` An optional icon component that's displayed within the button
size string The size of the button. Has two options: `small` and `medium` small
position string The position of the button in relation to its siblings. Options include: `standalone`, `left`, `right`, and `middle` standalone
applyShadow boolean Determines whether to apply shadow to a button `true`
applyBlur boolean Determines whether to apply a blur effect to the button `true`
disabled boolean Determines whether the button is disabled `false`
focus boolean Indicates if the button has focus `false`
onClick function A callback function that triggers when the user clicks on the button
isActive boolean Determines if the button is in an active state
## Floating Icon Button Group
Props Type Description
className string Optional name for additional styling
size string The size of the button. Has two options: `small` and `medium`
iconButtons array An array of objects, each representing an icon button in the group. Each object should include the icon component you want to display in the button, the function you want to call when a user clicks on the button, and whether the button should be active or not.
## Light Button
Props Type Description Default
className string Optional name for additional styling
icon `React.ReactNode` The icon you want to display in the button
title string The text content of the button
accent string The accent color of the button. Options include: `secondary` and `tertiary` secondary
active boolean Determines if the button is in an active state `false`
disabled boolean Determines whether the button is disabled `false`
focus boolean Indicates if the button has focus `false`
onClick function A callback function that triggers when the user clicks on the button
## Light Icon Button
Props Type Description Default
className string Optional name for additional styling
testId string Test identifier for the button
Icon `React.ComponentType` An optional icon component that's displayed within the button
title string The text content of the button
size string The size of the button. Has two options: `small` and `medium` small
accent string The accent color of the button. Options include: `secondary` and `tertiary` secondary
active boolean Determines if the button is in an active state `false`
disabled boolean Determines whether the button is disabled `false`
focus boolean Indicates if the button has focus `false`
onClick function A callback function that triggers when the user clicks on the button
## Main Button
Props Type Description Default
title string The text content of the button
fullWidth boolean efines whether the button should span the whole width of its container `false`
variant string The visual style variant of the button. Options include `primary` and `secondary` primary
soon boolean Indicates if the button is marked as "soon" (such as for upcoming features) `false`
Icon `React.ComponentType` An optional icon component that's displayed within the button
React `button` props `React.ComponentProps<'button'>` Additional props from React's `button` element
## Rounded Icon Button
Props Type Description
Icon `React.ComponentType` An optional icon component that's displayed within the button
React `button` props `React.ButtonHTMLAttributes` Additional props from React's `button` element