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: https://github.com/siyuan-note/siyuan/issues/10964
Vanessa4ccdd38de0f2
diff --git a/app/src/protyle/util/editorCommonEvent.ts b/app/src/protyle/util/editorCommonEvent.tsindex 0f22c20b6b..9e031618fa 100644--- a/app/src/protyle/util/editorCommonEvent.ts+++ b/app/src/protyle/util/editorCommonEvent.ts@@ -1083,14 +1083,18 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {const doOperations: IOperation[] = [];const undoOperations: IOperation[] = [];const undoPreviousId = blockElement.querySelector(`.av__row[data-id="${selectedIds[0]}"]`).previousElementSibling.getAttribute("data-id") || "";+ const targetGroupID = targetElement.parentElement.getAttribute("data-group-id");selectedIds.reverse().forEach(item => {if (previousID !== item && undoPreviousId !== previousID) {+ const groupID = blockElement.querySelector(`.av__row[data-id="${selectedIds[0]}"]`).parentElement.getAttribute("data-group-id");doOperations.push({action: "sortAttrViewRow",avID,previousID,id: item,blockID: blockElement.dataset.nodeId,+ groupID,+ targetGroupID,});undoOperations.push({action: "sortAttrViewRow",@@ -1098,6 +1102,8 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {previousID: undoPreviousId,id: item,blockID: blockElement.dataset.nodeId,+ groupID: targetGroupID,+ targetGroupID: groupID,});}});@@ -1144,14 +1150,18 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {const doOperations: IOperation[] = [];const undoOperations: IOperation[] = [];const undoPreviousId = blockElement.querySelector(`.av__gallery-item[data-id="${selectedIds[0]}"]`).previousElementSibling?.getAttribute("data-id") || "";+ const targetGroupID = targetElement.parentElement.getAttribute("data-group-id");selectedIds.reverse().forEach(item => {if (previousID !== item && undoPreviousId !== previousID) {+ const groupID = blockElement.querySelector(`.av__row[data-id="${selectedIds[0]}"]`).parentElement.getAttribute("data-group-id");doOperations.push({action: "sortAttrViewRow",avID,previousID,id: item,blockID: blockElement.dataset.nodeId,+ groupID,+ targetGroupID,});undoOperations.push({action: "sortAttrViewRow",@@ -1159,6 +1169,8 @@ export const dropEvent = (protyle: IProtyle, editorElement: HTMLElement) => {previousID: undoPreviousId,id: item,blockID: blockElement.dataset.nodeId,+ groupID: targetGroupID,+ targetGroupID: groupID,});}});diff --git a/app/src/types/index.d.ts b/app/src/types/index.d.tsindex f235780606..fdaaed48f4 100644--- a/app/src/types/index.d.ts+++ b/app/src/types/index.d.ts@@ -552,7 +552,8 @@ interface IOperation {blockIDs?: string[] // add/removeFlashcards 专享removeDest?: boolean // removeAttrViewCol 专享layout?: string // addAttrViewView 专享- groupID?: string // insertAttrViewBlock 专享+ groupID?: string // insertAttrViewBlock, sortAttrViewRow 专享+ targetGroupID?: string // sortAttrViewRow 专享}interface IOperationSrcs {