-
Notifications
You must be signed in to change notification settings - Fork 159
[BUG] Hotkeys for some punctuation marks do not work, with or without useKey #1269
Copy link
Copy link
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
Based on the documentation, I would expect each of the following to work:
useHotkeys('<', () => {}, { useKey: true }, []);
useHotkeys('>', () => {}, { useKey: true }, []);
useHotkeys('+', () => {}, { useKey: true, delimiter: '_' }, []);however, only the first one does.
There are some other unexpected behaviors as well. Using a US layout keyboard:
shift+,does not trigger, with or withoutuseKey, when pressingshift+,or just,.shift+Commadoes work as expected.shift+.withuseKeytriggers only when pressing.without holdingshift.shift+Perioddoes work as expected.shift+.withoutuseKeynever triggers.shift+=withuseKeytriggers only when pressing=without holdingshift.shift+Equaldoes work as expected.-
shift+=withoutuseKeynever triggers.
To Reproduce
Create a hotkey that uses > or + (with the delimiter changed to be something else)
useHotkeys('>', () => {}, { useKey: true }, []);
useHotkeys('+', () => {}, { useKey: true, delimiter: '_' }, []);Please try and add a codesandbox or stackblitz to reproduce the bug:
https://codesandbox.io/p/sandbox/qwhrs6
Here is a codesandbox template that you can use to recreate a minimal example
https://codesandbox.io/p/sandbox/adoring-shape-bzvk53
Expected behavior
The hotkeys should trigger when shift+. or shift+= are pressed.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: Windows 11
- Browser: Edge version 137.0.3296.68, Firefox version 139.0.4
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working