diff --git a/src/display/editor/editor.js b/src/display/editor/editor.js index 69dee6f15..43a8f8d21 100644 --- a/src/display/editor/editor.js +++ b/src/display/editor/editor.js @@ -1581,7 +1581,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, }); }