mirror of
https://0xacab.org/sutty/sutty
synced 2025-02-20 12:21:50 +00:00
editor: tagName no es un setter!
This commit is contained in:
parent
73ee9e4d15
commit
e87991af48
1 changed files with 4 additions and 1 deletions
|
@ -265,7 +265,10 @@ const cleanContent = (contentEl) => {
|
|||
if (elementIsParentBlock(child)) {
|
||||
cleanContent(child)
|
||||
} else if (!elementIsBlock(child)) {
|
||||
child.tagName = "P"
|
||||
const el = document.createElement("p")
|
||||
moveChildren(child, el, null)
|
||||
contentEl.insertBefore(el, child)
|
||||
child.parentNode.removeChild(child)
|
||||
}
|
||||
} else if (child.nodeType === Node.TEXT_NODE) {
|
||||
const el = document.createElement("p")
|
||||
|
|
Loading…
Reference in a new issue