An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:bug: fix https://github.com/siyuan-note/siyuan/issues/6335
Vanessaf4c3be9bd035
diff --git a/app/src/protyle/wysiwyg/getBlock.ts b/app/src/protyle/wysiwyg/getBlock.tsindex 4a4b23a178..6386035636 100644--- a/app/src/protyle/wysiwyg/getBlock.ts+++ b/app/src/protyle/wysiwyg/getBlock.ts@@ -96,12 +96,14 @@ export const getTopEmptyElement = (element: Element) => {if (!topElement.parentElement.getAttribute("data-node-id")) {topElement = topElement.parentElement;} else {- const hasText = Array.from(topElement.parentElement.querySelectorAll('[contenteditable="true"]')).find(item => {+ let hasText = false+ Array.from(topElement.parentElement.querySelectorAll('[contenteditable="true"]')).find(item => {if (item.textContent.replace(Constants.ZWSP, "").replace("\n", "") !== "") {+ hasText = true;return true;}});- if (!hasText || topElement.previousElementSibling?.getAttribute("data-node-id") ||+ if (hasText || topElement.previousElementSibling?.getAttribute("data-node-id") ||topElement.nextElementSibling?.getAttribute("data-node-id")) {break;} else {