Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: fix https://github.com/siyuan-note/siyuan/issues/10188

Vanessa7d57bd07e7ca
diff --git a/app/src/protyle/wysiwyg/keydown.ts b/app/src/protyle/wysiwyg/keydown.ts
index b3ab2c8156..27708c3c58 100644
--- a/app/src/protyle/wysiwyg/keydown.ts
+++ b/app/src/protyle/wysiwyg/keydown.ts
@@ -1375,7 +1375,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
event.preventDefault();
event.stopPropagation();
const selectsElement: HTMLElement[] = Array.from(protyle.wysiwyg.element.querySelectorAll(".protyle-wysiwyg--select"));
- if (selectsElement.length < 2) {
+ if (selectsElement.length < 2 || selectsElement[0]?.classList.contains("li")) {
return;
}
turnsIntoOneTransaction({
@@ -1390,7 +1390,7 @@ export const keydown = (protyle: IProtyle, editorElement: HTMLElement) => {
event.preventDefault();
event.stopPropagation();
const selectsElement: HTMLElement[] = Array.from(protyle.wysiwyg.element.querySelectorAll(".protyle-wysiwyg--select"));
- if (selectsElement.length < 2) {
+ if (selectsElement.length < 2 || selectsElement[0]?.classList.contains("li")) {
return;
}
turnsIntoOneTransaction({