Check target of keyEvent instead of activeElement for text editability

This commit is contained in:
jacobcolbert
2019-11-19 01:58:01 -05:00
parent ac53d3ea2b
commit 17bff8affb

View File

@@ -364,9 +364,9 @@
} }
// Ignore keydown event if typing in an input box // Ignore keydown event if typing in an input box
if (document.activeElement.nodeName === 'INPUT' if (event.target.nodeName === 'INPUT'
|| document.activeElement.nodeName === 'TEXTAREA' || event.target.nodeName === 'TEXTAREA'
|| document.activeElement.isContentEditable) { || event.target.isContentEditable) {
return false; return false;
} }