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/5565
Vanessa2b91919103eb
diff --git a/app/src/editor/util.ts b/app/src/editor/util.tsindex ca18929549..0dbf3532dd 100644--- a/app/src/editor/util.ts+++ b/app/src/editor/util.ts@@ -204,6 +204,8 @@ const switchEditor = (editor: Editor, options: IOpenFileOptions, allModels: IModsize: Constants.SIZE_GET,}, getResponse => {onGet(getResponse, editor.editor.protyle, options.action);+ // 大纲点击折叠标题下的内容时,需更新反链面板+ updateBacklinkGraph(allModels, editor.editor.protyle);});} else {if (options.action.includes(Constants.CB_GET_HL)) {diff --git a/app/src/layout/dock/Outline.ts b/app/src/layout/dock/Outline.tsindex 12b2afb5f7..fbdbed8bc8 100644--- a/app/src/layout/dock/Outline.ts+++ b/app/src/layout/dock/Outline.ts@@ -94,27 +94,13 @@ export class Outline extends Model {element: options.tab.panelElement.lastElementChild as HTMLElement,data: null,click: (element: HTMLElement) => {- const models = getAllModels();- models.editor.find(item => {- if (this.blockId === item.editor.protyle.block.rootID && !item.element.classList.contains("fn__none")) {- const id = element.getAttribute("data-node-id");- const targetElement = item.editor.protyle.wysiwyg.element.querySelector(`[data-node-id="${id}"]`);- if (targetElement) {- targetElement.scrollIntoView();- focusBlock(targetElement);- pushBack(item.editor.protyle, undefined, targetElement);- } else {- fetchPost("/api/block/checkBlockFold", {id}, (foldResponse) => {- openFileById({- id,- hasContext: !foldResponse.data,- action: foldResponse.data ? [Constants.CB_GET_FOCUS, Constants.CB_GET_ALL] : [Constants.CB_GET_FOCUS, Constants.CB_GET_SETID],- });- updateBacklinkGraph(models, item.editor.protyle);- });- }- return true;- }+ const id = element.getAttribute("data-node-id");+ fetchPost("/api/block/checkBlockFold", {id}, (foldResponse) => {+ openFileById({+ id,+ hasContext: !foldResponse.data,+ action: foldResponse.data ? [Constants.CB_GET_FOCUS, Constants.CB_GET_ALL] : [Constants.CB_GET_FOCUS, Constants.CB_GET_SETID],+ });});}});