Merge pull request #20351 from calixteman/avoid_null

[Editor] Avoid to have a null button in the DOM when there's no comment manager
This commit is contained in:
Tim van der Meij 2025-10-09 20:57:20 +02:00 committed by GitHub
commit 0fedfc9ceb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1177,6 +1177,9 @@ class AnnotationEditor {
}
addStandaloneCommentButton() {
if (!this._uiManager.hasCommentManager()) {
return;
}
if (this.#commentStandaloneButton) {
if (this._uiManager.isEditingMode()) {
this.#commentStandaloneButton.classList.remove("hidden");