- Implementation
- Toolbar Props
- Toolbar.Select Props
Common Examples
Toolbar Components
The Anvil2 toolbar is made up a mainToolbar component and a few sub-components that can be used together to build simple or complex bars.Toolbar: The parent component to configure toolbars.Toolbar.Button: Used to create simple actions that need to be triggered via a button such as opening up a dialog.Toolbar.ButtonToggle: Used to create simple actions that rely on a boolean response such as text font styles for a rich text editor.Toolbar.ButtonLink: Used to create links to other sources such as download links.Toolbar.Select: Used to create a single select drop down for items such as heading size selection for a rich text editor.
React Accessibility
- Keyboard interaction and aria guideline to follow WCAG Toolbar pattern.
- For controls that have the option to be icon only in view, aria-labels are required.
- The
Toolbarcomponent has a required prop ofassociatedContentto properly populate anaria-labelfor the component itself. Toolbar.Selecthas anaccessibleLabelprop to properly link the list of select items to the trigger.