Floating Toolbar State
Observable UI state of a NutrientFloatingToolbar: which edge it is docked against and whether a drag is in flight. Create it with rememberFloatingToolbarState so the docked edge survives configuration changes and process death.
Note this is deliberately not part of ToolbarCoordinator — the coordinator owns the host-agnostic toolbar model (items, visibility, actions); where a floating rendering of it sits on screen is a per-composable presentation concern, like scroll position.
Constructors
Properties
The R.id of the item shown while collapsed — the last item the user tapped from the expanded menu. null (or an id no longer in the item list) falls back to the first selected item, then the first item.
The edges the toolbar may dock against. Dragging only ever snaps to one of these.
The edge the toolbar is currently docked against.
true while the user is actively dragging the toolbar.
Whether the toolbar shows its full item row. Only consulted when the rendering composable is collapsible (see NutrientFloatingToolbar's collapsible parameter): collapsed (false), the pill shrinks to a single button showing the active item, and tapping it expands the full menu again.
Whether the toolbar currently lays its items out vertically (edge is Start/End).
While a drag is in flight, the edge of the dock zone currently under the pill — the pill previews this edge's orientation live, flipping horizontal↔vertical as the drag crosses zone boundaries. null while not dragging.
Functions
Docks the toolbar against edge programmatically. Must be one of allowedEdges.