An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:art: 改进 划选
Vanessad033e9a7be69
diff --git a/app/src/protyle/wysiwyg/index.ts b/app/src/protyle/wysiwyg/index.tsindex 8297b1c2a2..83b0c5ab85 100644--- a/app/src/protyle/wysiwyg/index.ts+++ b/app/src/protyle/wysiwyg/index.ts@@ -571,15 +571,16 @@ export class WYSIWYG {if (firstElement.classList.contains("protyle-wysiwyg") || firstElement.classList.contains("list") || firstElement.classList.contains("sb") || firstElement.classList.contains("bq")) {firstElement = document.elementFromPoint(newLeft - 1, newTop + 16);}- if (!firstElement || firstElement.classList.contains("protyle-wysiwyg")) {+ if (!firstElement) {return;}- if (moveEvent.clientY > y && !startFirstElement) {- startFirstElement = firstElement;- }- const firstBlockElement = hasClosestBlock(firstElement);- if (!firstBlockElement) {- return;+ let firstBlockElement = hasClosestBlock(firstElement);+ if (moveEvent.clientY > y) {+ if (!startFirstElement) {+ startFirstElement = firstElement;+ }+ } else if (!firstBlockElement) {+ firstBlockElement = protyle.wysiwyg.element.firstElementChild as HTMLElement;}let selectElements: Element[] = [];let currentElement: Element | boolean = firstBlockElement;