[Autocomplete] RuntimeError on hitting Enter after inserting a value when multiple #18253
Closed
1 of 2 tasks
Labels
duplicate
This issue or pull request already exists
When hitting enter after adding a value to a multiple select field, the element causes a RunTimeError
Current Behavior 😯
The Autocomplete element causes a runtime error when adding a value to a multiple select field and afterward hitting enter. I think the onChange is triggered and because there's no value to change it gives an undefined error.
Expected Behavior 🤔
The element shouldn't respond to the enter key when there's no input
Steps to Reproduce 🕹
Steps:
Live example: https://codesandbox.io/s/kyp0d
Context 🔦
My company uses this for auto completion of some values. When the users hits enter after entering a value they might think the app doesn't work.
Your Environment 🌎
The text was updated successfully, but these errors were encountered: