hotkeys-js icon indicating copy to clipboard operation
hotkeys-js copied to clipboard

➷ A robust Javascript library for capturing keyboard input. It has no dependencies.

Results 152 hotkeys-js issues
Sort by recently updated
recently updated
newest added

当弹出输入法输入字符的时候keydown会收到一个keyCode为229的事件, 此时_downKeys数组会push这个keyCode,而这个事件并不会触发keyup,所以他一直在_downKeys内,之后所有的快捷键就都失效了。 [https://stackoverflow.com/questions/25043934/is-it-ok-to-ignore-keydown-events-with-keycode-229](https://stackoverflow.com/questions/25043934/is-it-ok-to-ignore-keydown-events-with-keycode-229) [http://lists.w3.org/Archives/Public/www-dom/2010JulSep/att-0182/keyCode-spec.html](http://lists.w3.org/Archives/Public/www-dom/2010JulSep/att-0182/keyCode-spec.html)

On my main page, i have 2 hotkeys defined: pageup, pagedown If I press 'pageup' and 'pagedown' it works properly. Then I open a modal window (using bootstrap), and on...

I use react . The question is : I have two modals,A and B. A modal defines shortcuts 'alt+t,alt+r', B's shortcuts are same to A. When A modal does something,...

Demo

## 第一个建议 我觉得将`keydown`事件的监听放在`document`上并不是非常合适。对于一个富文本编辑器,快捷键只想在特定的区域内生效。虽然`filter`可以实现,但是如若一个页面中,这种情况非常多,那么逻辑不都堆叠在`filter`函数中了? 最好有一个更棒的设计,可以例如像下面的思想: ```js import hotkeys from 'hotkeys-js' // 在特定一区域内生效 const hotkey1 = hotkeys.attach('#editor1') const hotkey2 = hotkeys.attach('#editor2') hotkey1('ctrl+s', function () { console.log('保存editor1中内容') }) hotkey2('ctrl+s', function () { console.log('保存editor2中内容')...

Hi guys, is possible use hotkeys with f11?

use hotkeys.js to call window.open, then the other hotkeys are not available, except the hotkey which call window open function.

I was investigating some issues with the library, and struggled to understand the intent behind the code. Yes, It's quite clear what code does, but intent of this code is...

i have created a global shortkeys handler. i require keys data in a certain way. for example { key: "alt+s+n", action: () => this.setState({ showShortKeys: true }) }, the issue...

Demo

hit tab focus on the input field, //This is the default event, it is correct.the hotkeys are available now! then hit tab again until focus on browser URL bar //This...

I have an HTML element handler from which I am stopping event from bubbling up. Depsite of that hotkeys stills catches up the event handling and executes its callback. `3.4.4`...