diff --git a/src/display/editor/editor.js b/src/display/editor/editor.js index 084fa34f1..dc1e126d6 100644 --- a/src/display/editor/editor.js +++ b/src/display/editor/editor.js @@ -2167,7 +2167,7 @@ class AnnotationEditor { if (this.div?.contains(document.activeElement)) { // Don't use this.div.blur() because we don't know where the focus will // go. - this._uiManager.currentLayer.div.focus({ + this.currentLayer?.div.focus({ preventScroll: true, }); }