jaywcjlove / react-hotkeys

React component to listen to keydown and keyup keyboard events, defining and dispatching keyboard shortcuts.
https://jaywcjlove.github.io/react-hotkeys/
411 stars 22 forks source link

Command key doesn't repeat as expected #29

Open stevenlundy opened 4 years ago

stevenlundy commented 4 years ago

When the command key is used as a modifier it doesn't seem to allow other shortcuts to fire until the command key has been lifted again.

See example: https://codepen.io/stevenlundyseesaw/pen/LYEdVBL?editors=0010 Command left and right should move the circle left and right without having to lift the command key If you change it to another modifier (alt, shift) it works as expected

stevenlundy commented 4 years ago

Here's an explanation of what's probably causing this. https://stackoverflow.com/questions/25438608/javascript-keyup-isnt-called-when-command-and-another-is-pressed