[Glitch] hotkeys: only match just() when no modifiers are held
Port f3786e08165e304efab23579832e5b5159ce33f8 to glitch-soc Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
parent
e53421b548
commit
2e6ed97416
@ -40,7 +40,11 @@ type KeyMatcher = (
|
||||
*/
|
||||
function just(keyName: string): KeyMatcher {
|
||||
return (event) => ({
|
||||
isMatch: normalizeKey(event.key) === keyName,
|
||||
isMatch:
|
||||
normalizeKey(event.key) === keyName &&
|
||||
!event.altKey &&
|
||||
!event.ctrlKey &&
|
||||
!event.metaKey,
|
||||
priority: hotkeyPriority.singleKey,
|
||||
});
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user