authorgravatar for ishansachu1@gmail.comIshan <ishansachu1@gmail.com> 2026-04-11 08:43:58+05:30
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-04-10 20:13:58-07:00
log5467d11980e2b41e4cf5c8d1c5fe972532da3a74
tree72bc6875023b86be9e0177107ae666a9d57c3231
parent1f4a3f65bf5e17298dde3aa6a4e8e4e5530a9e1d
signature Signed by PGP key B5690EEEBB952194

fix(web): prevent number-key shortcuts from hijacking input in focused editor (#1810)


1 files changed, 4 insertions(+), 1 deletions(-)

apps/web/src/components/chat/ComposerPendingUserInputPanel.tsx+4-1
...@@ -100,7 +100,10 @@ const ComposerPendingUserInputCard = memo(function ComposerPendingUserInputCard(...@@ -100,7 +100,10 @@ const ComposerPendingUserInputCard = memo(function ComposerPendingUserInputCard(
100 if (target instanceof HTMLInputElement || target instanceof HTMLTextAreaElement) {100 if (target instanceof HTMLInputElement || target instanceof HTMLTextAreaElement) {
101 return;101 return;
102 }102 }
103 if (target instanceof HTMLElement && target.isContentEditable) {103 if (
104 target instanceof HTMLElement &&
105 target.closest('[contenteditable]:not([contenteditable="false"])')
106 ) {
104 return;107 return;
105 }108 }
106 const digit = Number.parseInt(event.key, 10);109 const digit = Number.parseInt(event.key, 10);