diff --git a/src/display/annotation_layer.js b/src/display/annotation_layer.js index 912349361..0fefe94be 100644 --- a/src/display/annotation_layer.js +++ b/src/display/annotation_layer.js @@ -2494,7 +2494,7 @@ class PopupElement { renderRichText( { html: this.#html || this.#contentsObj.str, - dir: this.#contentsObj.dir, + dir: this.#contentsObj?.dir, className: "popupContent", }, popup