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
[Autocomplete] Fix filtering when value is already selected #22935
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
montelius
changed the title
Issue22792
Autocomplete] Don't display whole options list in Autocomplete when input text is the same as selected value
Oct 8, 2020
montelius
changed the title
Autocomplete] Don't display whole options list in Autocomplete when input text is the same as selected value
[Autocomplete] Don't display whole options list in Autocomplete when input text is the same as selected value
Oct 8, 2020
oliviertassinari
added
bug 🐛
Something doesn't work
component: autocomplete
This is the name of the generic UI component, not the React module!
labels
Oct 8, 2020
oliviertassinari
force-pushed
the
issue22792
branch
from
October 9, 2020 09:44
f6048ad
to
469e0e4
Compare
oliviertassinari
changed the title
[Autocomplete] Don't display whole options list in Autocomplete when input text is the same as selected value
[Autocomplete] Fix filtering when value is already selected
Oct 9, 2020
oliviertassinari
approved these changes
Oct 9, 2020
oliviertassinari
force-pushed
the
issue22792
branch
from
October 9, 2020 09:53
469e0e4
to
b19cc20
Compare
@montelius I have pushed forward your initial solution. Thanks for demonstrating a working solution! If you see any issue with the revised approach, please let us know, we can work on a follow up pull request. At least, It seems that this first issue solve the reported problem :) |
@oliviertassinari I looks great, thanks for taking the time to polish! :) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug 🐛
Something doesn't work
component: autocomplete
This is the name of the generic UI component, not the React module!
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix #22792.
I've also added three tests, one of which doesn't work correctly (the 'should filter options when new input value matches option' case). Basically, I'm trying to simulate user key input into the textbox, but the key input doesn't seem to change the input text in the textbox. Could I get some help solving this?