[Bug]: Select behaviour with duplicate values
Describe the bug
I have a use case where users select a state abbreviation and that maps to specific fine print that needs to be used for that state. Many times the states have similar fine print but some have very specific fine print. Users also don't need to know the specific fine print to be using, just the state who's fine print they want to use.
Affected component/components
Select
How to reproduce
Create a select component with multiple keys that have the same value.
Selecting one of those keys selects all of the keys with the same value.
Codesandbox/StackBlitz link
No response
Logs
No response
System Info
"@radix-ui/react-select": "^2.0.0",
Before submitting
- [X] I've made research efforts and searched the documentation
- [X] I've searched for existing issues
i dont understand it can you explain a little bit
It looks like duplicate of #2010 for me.
Yup it's a duplicate of that one. Same issue.
But that ticket is closed so I opened a new one since it hasn't been fixed yet.
Sure, as a said in the other issue, I believe the way the radix handle this is right, and is the expected behavior.
I really believe the better way to handle that is on your side, just making the values unique. It not mean that you need to make labels uniques.
Just map duplicated values to unique ones, and after user finish of filling it, map it again to original value that you want.
If it's no clear enough, let me know, so I can create an example of it.