Skip to content
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] RuntimeError on hitting Enter after inserting a value when multiple #18253

Closed
1 of 2 tasks
Joostluijben opened this issue Nov 7, 2019 · 1 comment
Closed
1 of 2 tasks
Labels
duplicate This issue or pull request already exists

Comments

@Joostluijben
Copy link

Joostluijben commented Nov 7, 2019

When hitting enter after adding a value to a multiple select field, the element causes a RunTimeError

  • The issue is present in the latest release.
  • I have searched the issues of this repository and believe that this is not a duplicate.

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.
bug

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

  1. In one of the select elements, select a value
  2. Hit enter
  3. The app should crash

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 🌎

Tech Version
Material-UI v4.5.2
React 16.9.0
Browser Firefox 70.0.1
TypeScript 3.3.0
Material-UI/lab 4.0.0-alpha.31
@oliviertassinari oliviertassinari added the duplicate This issue or pull request already exists label Nov 7, 2019
@oliviertassinari
Copy link
Member

This is a duplicate of #18221. Thank you for the report. The issue will be solved in the next release: v4.0.0-alpha.32.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants