Skip to content

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

:art: fix https://github.com/siyuan-note/siyuan/issues/11713

Vanessa51ec3ec69cc8
diff --git a/app/src/protyle/hint/extend.ts b/app/src/protyle/hint/extend.ts
index 2d8109189e..085bb1b126 100644
--- a/app/src/protyle/hint/extend.ts
+++ b/app/src/protyle/hint/extend.ts
@@ -357,6 +357,7 @@ export const hintRef = (key: string, protyle: IProtyle, source: THintSource): IH
id: nodeElement ? nodeElement.getAttribute("data-node-id") : protyle.block.parentID,
beforeLen: Math.floor((Math.max(protyle.element.clientWidth / 2, 320) - 58) / 28.8),
rootID: source === "av" ? "" : protyle.block.rootID,
+ isDatabase: source === "av",
isSquareBrackets: ["[[", "【【"].includes(protyle.hint.splitChar)
}, (response) => {
const dataList: IHintData[] = [];
@@ -403,6 +404,7 @@ export const hintEmbed = (key: string, protyle: IProtyle): IHintData[] => {
const nodeElement = hasClosestBlock(getEditorRange(protyle.wysiwyg.element).startContainer);
fetchPost("/api/search/searchRefBlock", {
k: key,
+ isDatabase: false,
beforeLen: Math.floor((Math.max(protyle.element.clientWidth / 2, 320) - 58) / 28.8),
id: nodeElement ? nodeElement.getAttribute("data-node-id") : protyle.block.parentID,
rootID: protyle.block.rootID,
diff --git a/app/src/protyle/hint/index.ts b/app/src/protyle/hint/index.ts
index e7ebffa3ce..2edbe514b9 100644
--- a/app/src/protyle/hint/index.ts
+++ b/app/src/protyle/hint/index.ts
@@ -321,6 +321,7 @@ ${unicode2Emoji(emoji.unicode)}</button>`;
id: nodeElement ? nodeElement.getAttribute("data-node-id") : protyle.block.parentID,
beforeLen: Math.floor((Math.max(protyle.element.clientWidth / 2, 320) - 58) / 28.8),
rootID: source === "av" ? "" : protyle.block.rootID,
+ isDatabase: source === "av",
}, (response) => {
let searchHTML = "";
if (response.data.newDoc) {