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/14226

Vanessa6e8c42e521f1
diff --git a/app/src/protyle/breadcrumb/index.ts b/app/src/protyle/breadcrumb/index.ts
index 126654e0c7..98dc0b1db3 100644
--- a/app/src/protyle/breadcrumb/index.ts
+++ b/app/src/protyle/breadcrumb/index.ts
@@ -171,7 +171,7 @@ ${padHTML}
target = target.parentElement;
}
});
- /// if !MOBILE
+ /// #if !MOBILE
element.addEventListener("mouseleave", () => {
protyle.wysiwyg.element.querySelectorAll(".protyle-wysiwyg--hl").forEach(item => {
item.classList.remove("protyle-wysiwyg--hl");
diff --git a/app/src/protyle/ui/initUI.ts b/app/src/protyle/ui/initUI.ts
index b6f5fb534f..91d53860ef 100644
--- a/app/src/protyle/ui/initUI.ts
+++ b/app/src/protyle/ui/initUI.ts
@@ -14,6 +14,7 @@ import {transaction} from "../wysiwyg/transaction";
import {focusByRange} from "../util/selection";
/// #if !MOBILE
import {moveResize} from "../../dialog/moveResize";
+/// #endif
import {
hasClosestBlock,
hasClosestByAttribute,
@@ -21,7 +22,6 @@ import {
hasClosestByTag,
isInEmbedBlock
} from "../util/hasClosest";
-/// #endif
export const initUI = (protyle: IProtyle) => {
protyle.contentElement = document.createElement("div");
@@ -171,7 +171,6 @@ export const initUI = (protyle: IProtyle) => {
}
}
});
- /// if !MOBILE
let overAttr = false;
protyle.element.addEventListener("mouseover", (event: KeyboardEvent & { target: HTMLElement }) => {
// attr
@@ -237,6 +236,7 @@ export const initUI = (protyle: IProtyle) => {
}
// 面包屑
+ /// if !MOBILE
if (protyle.selectElement.classList.contains("fn__none")) {
const svgElement = hasClosestByAttribute(event.target, "data-node-id", null);
if (svgElement && svgElement.parentElement.classList.contains("protyle-breadcrumb__bar")) {
@@ -249,8 +249,8 @@ export const initUI = (protyle: IProtyle) => {
}
}
}
+ /// #endif
});
- /// endif
};
export const addLoading = (protyle: IProtyle, msg?: string) => {