Dropdown
See React Bootstrap/Dropdowns for full documentation and props.
Dropdowns in react-bootstrap provide some level of accessibility but in most cases roles or ids will need to be specifically associated with the menu elements themselves.
Dropdowns can be created with a the Dropdown.Toggle component or a DropdownButton component.
With DropdownButton
The DropdownButton can be used to shorten the JSX required to create a dropdown with a toggle button.
With headers and dividers
With multiple columns
Columns can be created with layout options (flex, grid, etc.).
With non-interactive items
The Dropdown.ItemText component can be used to create non-interactive items.
With form inputs
With icons
With badges
With links
With helper text
With nested items
MultiLineDropdownItem
Analytics
The DropdownItem component is trackable through Kyber Analytics. This is the default analytics config.
export default {
value: 'DropdownItem',
actions: {
onClick: { type: 'DROPDOWNITEM_CLICK', payload: 'Click' },
},
};
Props
Dropdown
DropdownItem
DropdownItemContent
MultiLineDropdownItem
The MultiLineDropdownItem component is trackable through Kyber Analytics. This is the default analytics config.
export default {
value: 'MultiLineDropdownItem',
actions: {
onClick: { type: 'DROPDOWNITEM_CLICK', payload: 'Click' },
},
};