From 377b4189ca85603db0b7f040949260ba7494c46f Mon Sep 17 00:00:00 2001 From: Sylvain Marroufin Date: Mon, 13 Mar 2023 14:11:52 +0100 Subject: [PATCH] fix(defineShortcuts): shift + alphabetic character handling (#140) --- src/runtime/composables/defineShortcuts.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runtime/composables/defineShortcuts.ts b/src/runtime/composables/defineShortcuts.ts index 2a6b3fbe..f954794e 100644 --- a/src/runtime/composables/defineShortcuts.ts +++ b/src/runtime/composables/defineShortcuts.ts @@ -32,7 +32,7 @@ export const defineShortcuts = (config: ShortcutsConfig) => { let shortcuts: Shortcut[] = [] const onKeyDown = (e: KeyboardEvent) => { - const alphabeticalKey = /^[a-z]{1}$/.test(e.key) + const alphabeticalKey = /^[a-z]{1}$/i.test(e.key) for (const shortcut of shortcuts) { if (e.key.toLowerCase() !== shortcut.key) { continue }