Skip to content

Commit 3632818

Browse files
fix(hotkeys): add ? to supported punctuation keys
Adds to PunctuationKey type and PUNCTUATION_KEYS constant, enabling for help shortcuts. Fixes #19
1 parent 4744399 commit 3632818

3 files changed

Lines changed: 7 additions & 0 deletions

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@tanstack/hotkeys': patch
3+
---
4+
5+
Add `?` to supported punctuation keys for `Mod+?` help shortcut

packages/hotkeys/src/constants.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,7 @@ export const EDITING_KEYS = new Set<EditingKey>([
290290
*/
291291
export const PUNCTUATION_KEYS = new Set<PunctuationKey>([
292292
'/',
293+
'?',
293294
'[',
294295
']',
295296
'\\',

packages/hotkeys/src/hotkey.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ export type EditingKey =
116116
*/
117117
export type PunctuationKey =
118118
| '/'
119+
| '?'
119120
| '['
120121
| ']'
121122
| '\\'

0 commit comments

Comments
 (0)