react-component / react-component/select
Issues with deselecting in a select component where multiple items can be selected
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 938
- Forks
- 482
- Avg merge
- 15h 8m
- Merged PRs (30d)
- 2
Description

What is the reason that the items don't get correctly deselected? The state gets updated which is highlighted by the updates in the dropdown but the items in the input field stay there when they get deselected. As you see in the gif above even the placeholder text comes back behind the items when they are deselected.
I cannot reproduce this outside of my project.
It should work like in the codesandbox below since I used exactly the same code and ant version in my project. All other ant components work fine. I also tried using rc-select instead of its antd variant or using only the example code in my project which is shown in the gif above.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with index.js in the linked CodeSandbox and compare the multi-select behavior with rc-select and the antd variant. Reproduce the deselection case and verify that deselected items disappear from the input and the placeholder returns without stale items.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100