keep selector support for sub-element

This commit is contained in:
Gabe Yuan
2024-01-12 16:04:34 +08:00
parent e87f7f3abe
commit c9d72323f1
3 changed files with 11 additions and 6 deletions

View File

@@ -99,8 +99,8 @@ function brFixer(node, tag = "p") {
html += `</${tag}>${child.outerHTML}<${tag} class="kiss-p">`;
} else if (child.outerHTML) {
html += child.outerHTML;
} else if (child.nodeValue) {
html += child.nodeValue;
} else if (child.textContent) {
html += child.textContent;
}
if (index === node.childNodes.length - 1) {