fix(web): prevent number-key shortcuts from hijacking input in focused editor (#1810)
This commit is contained in:
1 parent
1f4a3f65bf
commit
5467d11980
1 file changed
+4
-1
@@ -100,7 +100,10 @@ const ComposerPendingUserInputCard = memo(function ComposerPendingUserInputCard(
|
||||
if (target instanceof HTMLInputElement || target instanceof HTMLTextAreaElement) {
|
||||
return;
|
||||
}
|
||||
if (target instanceof HTMLElement && target.isContentEditable) {
|
||||
if (
|
||||
target instanceof HTMLElement &&
|
||||
target.closest('[contenteditable]:not([contenteditable="false"])')
|
||||
) {
|
||||
return;
|
||||
}
|
||||
const digit = Number.parseInt(event.key, 10);
|
||||
|
||||
Reference in new issue
Block a user