Index: gc_lang/fr/webext/content_scripts/panel_gc.js ================================================================== --- gc_lang/fr/webext/content_scripts/panel_gc.js +++ gc_lang/fr/webext/content_scripts/panel_gc.js @@ -1017,18 +1017,21 @@ } } write () { if (this.xNode !== null) { - let sText = ""; if (this.bTextArea) { this.xNode.value = this.getText(); } else { this.eraseNodeContent(); this.dParagraph.forEach((val, key) => { this.xNode.appendChild(document.createTextNode(val.normalize("NFC"))); this.xNode.appendChild(document.createElement("br")); }); + const xEvent = new CustomEvent("grammalecteNodeContentUpdated", { + detail: { text: [...this.dParagraph.values()].join("\n").normalize("NFC") } + }); + this.xNode.dispatchEvent(xEvent); } } } }