An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作
TypeScript agentic-aiai-agentknowledge-baselocal-firstmarkdownmcpmindmapnote-takingself-hostedsiyuanworkspace
:zap: fix https://github.com/siyuan-note/siyuan/issues/7072
Vanessaef9c5450e8c5
diff --git a/app/src/protyle/index.ts b/app/src/protyle/index.tsindex 01263f06bd..e7ad5f9136 100644--- a/app/src/protyle/index.ts+++ b/app/src/protyle/index.ts@@ -170,7 +170,8 @@ export class Protyle {id: options.blockId,k: options.key || "",isBacklink: mergedOptions.action.includes(Constants.CB_GET_BACKLINK),- mode: (mergedOptions.action && mergedOptions.action.includes(Constants.CB_GET_CONTEXT)) ? 3 : 0, // 0: 仅当前 ID(默认值),1:向上 2:向下,3:上下都加载,4:加载最后+ // 0: 仅当前 ID(默认值),1:向上 2:向下,3:上下都加载,4:加载最后+ mode: (mergedOptions.action && mergedOptions.action.includes(Constants.CB_GET_CONTEXT)) ? 3 : 0,size: mergedOptions.action?.includes(Constants.CB_GET_ALL) ? Constants.SIZE_GET_MAX : window.siyuan.config.editor.dynamicLoadBlocks,}, getResponse => {onGet(getResponse, this.protyle, mergedOptions.action, options.scrollAttr);diff --git a/app/src/protyle/scroll/event.ts b/app/src/protyle/scroll/event.tsindex 10ae75e007..71f5836339 100644--- a/app/src/protyle/scroll/event.ts+++ b/app/src/protyle/scroll/event.ts@@ -67,7 +67,9 @@ export const scrollEvent = (protyle: IProtyle, element: HTMLElement) => {});}, Constants.TIMEOUT_BLOCKLOAD);}- if (protyle.wysiwyg.element.getAttribute("data-top") || protyle.block.showAll || protyle.scroll.lastScrollTop === element.scrollTop || protyle.scroll.lastScrollTop === -1) {+ if (protyle.wysiwyg.element.getAttribute("data-top") || protyle.block.showAll ||+ (protyle.scroll && protyle.scroll.element.classList.contains("fn__none")) || !protyle.scroll ||+ protyle.scroll.lastScrollTop === element.scrollTop || protyle.scroll.lastScrollTop === -1) {return;}if (protyle.scroll.lastScrollTop - element.scrollTop > 0) {