You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found out what is causing the issue. It seems Space and Enter key handlers simulate keyPress event even if these two keys can trigger native events. Here is the small program demonstrating which key triggers keyPress event in React. Sandbox
Space and Enter keys produce KeyPress event.
My suggestion is to fix it either in hasKeyPressEvent function (hasKeyPressEvent.js) or remove Space and Enter keys from translateToKey map (translateToKey.js). I prefer the second case.
Describe the bug
Here is the link to sandbox where this bug can be reproduced: [https://codesandbox.io/s/happy-johnson-su7vz]
Steps to reproduce:
How are you using react hotkeys components? (HotKeys, GlobalHotKeys, IgnoreKeys etc)
Expected behavior
Shift+Space combination should work properly.
Platform (please complete the following information):
Are you willing and able to create a PR request to fix this issue?
Yes.
Include the smallest log that includes your issue:
What Configuration options are you using?
Here is a small unit test demonstrating the issue (CombinationsInvolvingShiftKey.spec.js):
The text was updated successfully, but these errors were encountered: