Assign Picker, animated React component
An assignee pill with a multi-select menu. Tick people and each avatar flies from its row into the pill, which grows to hold them and stacks them with a count past three; the label reads one name, two names or a number.
- Pro
- Inputs & Controls
- Spring
Play with it
Move the controls and watch it change. Copy code gives you a snippet with only the props you changed.
Props
| Prop | Type | Default | What it does |
|---|---|---|---|
| people | AssignPerson[] | five sample people | People in the menu: { id, name, role, colors: [from, to] }. Avatars are gradient circles with initials. |
| defaultValue | string[] | [] | Ids selected on first render. |
| onChange | (ids: string[]) => void | undefined | Called with the selected ids, in the order they were picked. |
| autoplay | boolean | false | Opens the menu, ticks four people, closes and clears, on a loop until the user clicks. |