Skip to main content

Toolbar

Use cases:

  • As a container for grouping a set of controls

Example​

ButtonOption 1Second optionOption 3OneTwoThree

Declaration

<Toolbar></Toolbar>

Usage

import { Button, ListboxOption, Radio, RadioGroup, Select, Toolbar } from '@genesislcap/rapid-design-system/react';

export function MyComponent() {

const handleRadioFieldChanged = (event) => {
const target = event.target as HTMLInputElement;
console.log(target.value);
};

return (
<Toolbar>
<Button>Button</Button>
<Select>
<ListboxOption>Option 1</ListboxOption>
<ListboxOption>Second option</ListboxOption>
<ListboxOption>Option 3</ListboxOption>
</Select>
<RadioGroup>
<Radio checked="">One</Radio>
<Radio>Two</Radio>
<Radio>Three</Radio>
</RadioGroup>
</Toolbar>
);
}

API​

Property and attribute binding examples for Genesis Component syntax.

NameTypeDescriptionExample
orientationToolbarOrientationThe orientation of the toolbar, horizontal or vertical. Default: horizontal
<rapid-toolbar orientation="horizontal">

Properties​

This component doesn't have any properties which are not also controlled via attributes.

Slots​

SlotUse
startContent which can be provided before the slotted items
endContent which can be provided after the slotted items
labelThe toolbar label

Parts​

PartDescription
positioning-regionThe element containing the items, start and end slots

Events fired​

No events fired.

Events listened to​

This component doesn't listen to any events.