jaywcjlove / react-hotkeys

React component to listen to keydown and keyup keyboard events, defining and dispatching keyboard shortcuts.

Home Page:https://jaywcjlove.github.io/react-hotkeys/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Is possible only use modifier?

gleidsonh opened this issue · comments

Is possible to use just modifier? I want to use only alt key, but it's not working. With combination works fine. (alt+s)

<Hotkeys 
   keyName="alt" 
   onKeyDown={this.onKeyDown.bind(this)}
   onKeyUp={this.onKeyUp.bind(this)}
/>

Ping on this - I have a use case where I need the user to hold down the shift key to enable/disable specific functionality. Doesn't appear to be working when you only pass a modifier to keyName