Describe the bug
Library doesn't support code or which property to make hotkey language agnostic. It compare event key by value due to works with only one keyboard layout.
To Reproduce
Imagine you have keyboard with 2 layouts: native language and english (i.e. French and English).
Steps to reproduce the behavior:
- Bind event
import { bindKey } from '@rwh/keystrokes'
bindKey('H', {
onPressed: () => {
...
},
onReleased: () => {
...
},
});
- Press H button in English layout. It works
- Change active keybord layout to French. Press physically same button. It doesn't work what is obviously is not clear for any user.
Expected behavior
Library should work with code property (physical id of the button) and not with a key (it contains value, changable thing), otherwise library would be used only for few countries where people use english as a native language.
Describe the bug
Library doesn't support
codeorwhichproperty to make hotkey language agnostic. It compare event key by value due to works with only one keyboard layout.To Reproduce
Imagine you have keyboard with 2 layouts: native language and english (i.e. French and English).
Steps to reproduce the behavior:
Expected behavior
Library should work with
codeproperty (physical id of the button) and not with akey(it contains value, changable thing), otherwise library would be used only for few countries where people use english as a native language.