StatePicker
A category-grouped picker for a workflow state, built on Select.
A picker for a workflow state, built on Select, so it keeps Select's keyboard model, search and form support. States are grouped under a heading per category in lifecycle order (triage, backlog, unstarted, started, completed, canceled); inside a category they keep the order of the states you pass. Empty categories get no heading. Each row and the trigger draw a StateBadge.
trigger="label" (default) shows the glyph and name in the trigger. trigger="icon" shows only the glyph, for a compact table cell. Rename the group headings with categoryLabels, for translation or your own terms.
Installation
npm install @crisp-ui-kit/crispProps
StatePicker also accepts the Select props, except options, value, defaultValue, onValueChange and searchable, which it redefines below.
Prop
Type
states is a WorkflowState[], described on the StateBadge page. value and onValueChange work with the state's id.