Calm motion: animations on this site only fade, with no movement
Contact picker
Search people and pick one or more, with recent contacts
Picks the people for a new chat, a share, or a meeting. For one person in a form field, use the combobox.
Basic
Citra Dewi
contactsis a list of people. Each person has anidand aname, and an optionaldetailandavatar. The detail shows under the name, such as an email or a role.recentis a list of ids. While the search is empty, these people show first under "Recent", and everybody shows under "All people" by name.- The search looks at the name and the detail. If nobody matches, a status line says so.
v-modelis the list of chosen ids. Withmultiple(on by default), each person has a check box. Without it, each person has a radio button.- The chosen people show as chips on top. The ✕ on a chip removes the person.
- Change the words with
labelsor a label pack:title,search,recent,all,none,chosen, andremove.
Usage
ts
import { BlessContactPicker } from "blessing-ui";API
Props
| Name | Type | Default | Description |
|---|---|---|---|
contacts* | BlessContact[] | — | |
recent | string[] | [] | ids of recent contacts, shown first while the search is empty |
multiple | boolean | true | pick more than one |
labels | Partial<{ title: string; search: string; recent: string; all: string; none: string; chosen: string; remove: string; }> | — | |
modelValue | string[] | [] | the ids of the chosen contacts |
Events
| Name | Payload | Description |
|---|---|---|
update:modelValue | [value: string[]] |