From 29e68846718bc1978599be0345ceb7736e2419f8 Mon Sep 17 00:00:00 2001 From: automated-signal <37887102+automated-signal@users.noreply.github.com> Date: Wed, 18 Oct 2023 11:35:27 -0700 Subject: [PATCH] Focus keyboard shortcut for edit message Co-authored-by: Josh Perez --- ts/hooks/useKeyboardShortcuts.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ts/hooks/useKeyboardShortcuts.tsx b/ts/hooks/useKeyboardShortcuts.tsx index 4f77c5dcc..24e57c07b 100644 --- a/ts/hooks/useKeyboardShortcuts.tsx +++ b/ts/hooks/useKeyboardShortcuts.tsx @@ -270,6 +270,11 @@ export function useEditLastMessageSent( const key = KeyboardLayout.lookup(ev); + const { shiftKey } = ev; + if (shiftKey || isCtrlOrAlt(ev)) { + return false; + } + if (key === 'ArrowUp') { const value = maybeEditMessage(); if (value) {