Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Combobox examples · Rich Content

Items with Status Indicators Combobox for React

A combobox of tasks with a status badge at the end of each row.

Framework
UI library

A task picker where each row ends with its status: Done, In Progress or To Do. The badge variants make the states easy to tell apart while scanning. Use it for tasks, tickets or orders, where the state matters when picking one.

Preview

Preview width

Installation

Sign in to get your install command
Free with an account. It carries your token, so the CLI installs everything in one go.

FAQ

How is a status turned into a badge?

A statusConfig map gives each status a label and a Badge variant: completed is Done with default, in-progress is In Progress with secondary, and todo is To Do with outline.

How is the badge placed?

ComboboxItem gets justify-between gap-2, so the task name sits at the start and the badge at the end, before the check.

Which tasks are listed?

Update documentation (Done), Fix login bug (In Progress), Add dark mode (To Do) and Optimize performance (In Progress).

What does the button show?

The picked task's name, or Select task... before a pick. No task found. shows when nothing matches.

Can I stop finished tasks from being picked?

Yes, disable them, as in With Disabled Items. The badge still shows why.