Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Combobox examples · Rich Content

Items with Metadata Combobox for React

A combobox of team members with an avatar, email and role on each row.

Framework
UI library

A member picker with three lines per row: the name, the email and the role, next to an avatar. The button shows only the name after a pick. Use it where people share names, or where the role or email helps pick the right person.

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 each row laid out?

ComboboxItem gets items-start gap-2 py-3. An Avatar at the default size sits beside a column with the name in font-medium and the email and role in muted text-xs.

Who is listed?

Hayden Bleasel (Design Engineer), shadcn (Engineer), Lee Robinson (VP of Product) and Guillermo Rauch (CEO), each with a vercel.com email.

What if a picture doesn't load?

AvatarFallback shows the first letter of the name.

What does the button show?

The picked member's name, or Select member... before a pick. No member found. shows when a search matches nobody.

What about long emails?

The list is as wide as the 300px button. Add truncate to the email line if addresses run long.