Repository navigation
fix(shortcuts): match letters on macOS and non-Latin layouts, skip text fields - #386
Merged
antobinary merged 1 commit intoNov 18, 2026
Conversation
…xt fields The shortcuts compared the character typed with the configured letter. With Alt held, macOS types another character (Option+Shift+K types the Apple logo), and non-Latin layouts type their own letters, so the letter shortcuts never fired there. When the character typed is not a Latin letter, match the key's position instead. Text fields also keep their own Alt+Shift keys: Alt+Shift+Left in the search field used to seek the recording back.
germanocaumo
force-pushed
the
fix-shortcuts-physical-key
branch
from
November 17, 2026 17:54
d91a5c5 to
e6818a7
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Makes the Alt+Shift letter shortcuts (K fullscreen, L side section, M swap) work on macOS and on non-Latin keyboard layouts, and stops the shortcuts from firing while typing in a text field.
The handler compared
event.keywith the configured letter. With Alt held, macOS types another character (Option+Shift+K types the Apple logo, U+F8FF; Option+Shift+L typesÒ), and non-Latin layouts type their own letters (Дfor L on a Russian layout), so these shortcuts never fired there. When the character typed isn't a Latin letter, the key's position (event.code) is matched instead. Latin layouts keep matching the character, so on Dvorak or AZERTY the shortcut stays on the key labelled with that letter.Text fields now keep their own keys: Alt+Shift+Left in the search field (word selection on macOS) also sought the recording back 15 s.
Also part of #376, which bundles it with a redesign.
How to test
Keydown events as each layout delivers them, dispatched on the player:
key/codeL/KeyLÒ/KeyLД/KeyLKeyKArrowLeftsrc/utils/shortcuts.test.jsdispatches the keydown events of each case (macOS, Russian, Dvorak, named keys) and the text field case.Changelog
event.codewhen the typed character is not a Latin letter; shortcuts ignore keydown in text fields