Vanessa 2025-06-23 10:21:37 +08:00
parent f44dc5406e
commit d7979f485b

View file

@ -562,12 +562,14 @@ export class WYSIWYG {
showMessage(window.siyuan.languages.crossKeepLazyLoad);
}
selectElements.forEach(item => {
item.classList.add("protyle-wysiwyg--select");
ids.push(item.getAttribute("data-node-id"));
// 清除选中的子块 https://ld246.com/article/1667826582251
item.querySelectorAll(".protyle-wysiwyg--select").forEach(subItem => {
subItem.classList.remove("protyle-wysiwyg--select");
});
if (!hasClosestByClassName(currentElement, "protyle-wysiwyg--select")) {
item.classList.add("protyle-wysiwyg--select");
ids.push(item.getAttribute("data-node-id"));
// 清除选中的子块 https://ld246.com/article/1667826582251
item.querySelectorAll(".protyle-wysiwyg--select").forEach(subItem => {
subItem.classList.remove("protyle-wysiwyg--select");
});
}
});
countBlockWord(ids);
if (toDown) {
@ -577,6 +579,7 @@ export class WYSIWYG {
}
}
}
event.preventDefault();
return;
}