-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rethinking how ComboBox handles values. #25
Comments
As far as I can see, other libraries went with a |
So I think i've thought of an approach that i'm happy with. Essentially what will happen is that "value" (the currently selected item) and the "search value" (the contents of the
|
implemented as of 537b1cd (1.4.1). technically a breaking change, but this is an undocumented component |
Currently, our ComboBox component usage looks something like this:
"Selection" occurs when the
name
of the item matches thevalue
passed in (or thevalue
set by the developer). This has some advantages and disadvantages. The main advantage is that matching based on name means that we can bind thevalue
of the input in searchable mode and use the same input for matching selection. This has some drawbacks, though. Items cannot be assigned a separate value from their name. Names must be unique for the ComboBox to behave as expected, and it can overall be a mess using a readable case system. This will need a bit of thinking on my part on how we should handle this. This would techncially be a breaking change under semver, but I consider undocumented components as in the 0.x stage.The text was updated successfully, but these errors were encountered: