Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork79.2k
Fix dropdown escape propagation#33479
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
LGTM |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Lines 489 to 492 in5cc53a0
if(!isActive||event.key===SPACE_KEY){ | |
Dropdown.clearMenus() | |
return | |
} |
This should not be changed as below? 🤔
if(isActive&&event.key===SPACE_KEY){Dropdown.clearMenus()return}
Uh oh!
There was an error while loading.Please reload this page.
alpadev commentedMar 30, 2021 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@rohit2sharma95 Not sure if this is even needed. This checks for keys that are dropdown commands. Lines 458 to 464 in5cc53a0
But the regex is missing the space key so I'm not sure if we even reach this block. Line 44 in5cc53a0
|
rohit2sharma95 commentedMar 30, 2021 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
And can not the |
alpadev commentedMar 30, 2021 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
I didn't mean to refactor too much in the scope of this issue but rather to just get rid of that Eslint warning. I agree that using a static method isn't ideal but the item selection functionality wasn't bound to the instance before and I made it the way If you want me to change it I should be able to do this tho. |
this reduces the complexity of the dataApiKeydownHandler to get rid of the eslint warning
requested by rohit2sharma95 -twbs#33479 (comment)
c019d3d
to3f658e5
CompareTill now is just a refactoring that I can follow, a minor fix and a valid test that succeeds . Sotill here I find itOK. I agree to refactor So if we can all agree on these, I would prefer to keep it as it is and if@alpadev has the courage to keep up with a following PR |
requested by rohit2sharma95 -twbs#33479 (comment)
Uh oh!
There was an error while loading.Please reload this page.
Closes#33465