diff --git a/web/editor.js b/web/editor.js index f7ffb094e..323c19e1a 100644 --- a/web/editor.js +++ b/web/editor.js @@ -207,15 +207,17 @@ function caretToEnd() { } function onBlur() { - if (document.activeElement === currentField) { - // anki window defocused; current field unchanged - return; - } if (currentField) { saveField("blur"); - currentField = null; + clearChangeTimer(); } - clearChangeTimer(); + + if (document.activeElement === currentField) { + // other widget or window focused; current field unchanged + return; + } + + currentField = null; disableButtons(); }