Don’t drop initial character when searching in Combobox #1223
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.
In the Vue version of the combobox the input is synced when the combobox state changes. This is done because closing the combobox needs to reflect the current selected value. For example, pressing the
Escape
key after searching should revert to what the value was before the user started searching.However, doing this on open is problematic:
All three of these steps happen in the same render cycle. This causes the value that would've been written by the
input
event to be lost because the value is synced with the old value that is currently in state. This manifested as the first character causing the combobox to open but not adding (or replacing if there was a selection) characters in the input.