Skip to content

Fix AutoCompleteInput value does not get updated when re-selecting the same option#11254

Open
smeng9 wants to merge 1 commit intomarmelab:masterfrom
smeng9:fix/autocomplete-input-reselection-update
Open

Fix AutoCompleteInput value does not get updated when re-selecting the same option#11254
smeng9 wants to merge 1 commit intomarmelab:masterfrom
smeng9:fix/autocomplete-input-reselection-update

Conversation

@smeng9
Copy link
Copy Markdown
Contributor

@smeng9 smeng9 commented May 8, 2026

Closes #11209

…option with filterSelectedOptions=false

When filterSelectedOptions is false, selecting an already-selected option
after partially deleting the input text left the input showing the partial
text until blur. MUI fires onInputChange with reason='reset' in this case
but the handler only updated filterValue on user-typing events or when the
new value differed from the selection. Added handling for reason='reset'
with event !== null (to skip MUI's programmatic useEffect resets) and
doesQueryMatchSelection (to skip create-option clicks).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@smeng9
Copy link
Copy Markdown
Contributor Author

smeng9 commented May 8, 2026

Before and after video comparisons

Untitled.mov

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AutocompleteInput: inconsistent input update behavior with filterSelectedOptions={false} compared to MUI

1 participant