-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Pressing enter for selection of a dropdown value directly submits form #862
Comments
Having the same issue.... will look into it later. |
Hi @knifesk, Reference: https://github.com/gregurco/ui-select/commit/673369ce8b906fa2da610e887a9611f90a15351e |
Yes I know.. but when you're pressing enter key in the search field the form should not be sent.. your solution removes the possibility of submitting the form with the enter key... even if you are in another field, because the form has no default action and can only submitted by mouse or tabbing to the button and pressing enter. |
Hey guys this pr solve this issue #868 |
You're awesome! Thanks for testing it and creating the tests for it |
Same bug as #808? |
In part.. this bug does not contemplate ESC key, only fixes the behaviour with ENTER key... @loverajoel, in the condition you can compare if the key is KEY.ESC, also, to fix that issue too.. if (key === KEY.ENTER || key === KEY.ESC) { that should do the trick |
@loverajoel is @knifesk's comment about |
I am working with ui-select, and whenever I press enter to select some searched results, the result is selected and the form directly goes on to submit. I cant figure it out, what is the problem.
Here is the HTML I'm using
The text was updated successfully, but these errors were encountered: