This commit is contained in:
Vanessa 2022-07-03 21:44:13 +08:00
parent b2c78cbceb
commit e35ab0db64

View file

@ -373,8 +373,10 @@ export class WYSIWYG {
parentElement = getContenteditableElement(nodeElement);
}
if (parentElement) {
// 引用文本剪切 https://ld246.com/article/1647689760545
// 表格多行剪切 https://ld246.com/article/1652603836350
Array.from(parentElement.children).forEach(item => {
if (item.textContent === "") {
if (item.textContent === "" && (item.nodeType === 1 && item.tagName !== "BR")) {
item.remove();
}
});