Dropdown Component
This class combines the configuration and rendering of a dropdown.
A dropdown consists of a toggle element as well as it's actual content in form of any fritz2-component. The toggle property can be used to specify a non-default toggle and the content property is used to specify the dropdown's content. A button with a standard menu-icon is used if no other toggle-element is specified.
The dropdown floats around the toggle-element and can be closed by simply clicking outside the dropdown. The opening an closing behavior can manually be controlled as well by specifying the visible property. It takes a flow of values to determine whether the dropdown should be visible or not.
The dropdown can be placed to the left, to the right, on top of, or below the toggle-element. Additionally it can either be aligned to the start or end of the placement's cross-axis. This can be specified via the respective placement and alignment properties. The default positioning is bottom start.
Example usage:
dropdown {
toggle {
// some layout
}
placement { bottom }
alignment { start }
content {
// some layout
}
}