Skip to content

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

:art: https://github.com/siyuan-note/siyuan/issues/6135

Vanessafe7f53c266f4
diff --git a/app/src/protyle/gutter/index.ts b/app/src/protyle/gutter/index.ts
index 5ff4809e41..45021a629e 100644
--- a/app/src/protyle/gutter/index.ts
+++ b/app/src/protyle/gutter/index.ts
@@ -1242,6 +1242,11 @@ export class Gutter {
fetchPost("/api/block/getHeadingDeleteTransaction", {
id,
}, (response) => {
+ response.data.doOperations.forEach((operation: IOperation) => {
+ protyle.wysiwyg.element.querySelectorAll(`[data-node-id="${operation.id}"]`).forEach((itemElement: HTMLElement) => {
+ itemElement.remove();
+ });
+ });
transaction(protyle, response.data.doOperations, response.data.undoOperations);
});
});
@@ -1254,6 +1259,11 @@ export class Gutter {
fetchPost("/api/block/getHeadingDeleteTransaction", {
id,
}, (response) => {
+ response.data.doOperations.forEach((operation: IOperation) => {
+ protyle.wysiwyg.element.querySelectorAll(`[data-node-id="${operation.id}"]`).forEach((itemElement: HTMLElement) => {
+ itemElement.remove();
+ });
+ });
transaction(protyle, response.data.doOperations, response.data.undoOperations);
});
}