mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
Make DOMParser correctly return innerHTML
This commit is contained in:
parent
4daede2995
commit
74961ff118
2 changed files with 1 additions and 3 deletions
|
@ -42,6 +42,6 @@ export class Codable extends HTMLTextAreaElement {
|
|||
this.codeMirror = undefined;
|
||||
|
||||
const doc = parser.parseFromString(this.value, "text/html");
|
||||
return doc.documentElement.textContent!;
|
||||
return doc.documentElement.innerHTML;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -128,9 +128,7 @@ export class EditingArea extends HTMLDivElement {
|
|||
|
||||
toggleHtmlEdit(): void {
|
||||
const output = this.codable.toggle(this.fieldHTML);
|
||||
console.log("succ output", output, this.ord);
|
||||
if (output) {
|
||||
console.log("writo");
|
||||
this.fieldHTML = output;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue