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

Vanessa06f3e9743682
diff --git a/app/src/protyle/ui/initUI.ts b/app/src/protyle/ui/initUI.ts
index 76b202d9a1..2ffb05148b 100644
--- a/app/src/protyle/ui/initUI.ts
+++ b/app/src/protyle/ui/initUI.ts
@@ -203,10 +203,12 @@ export const initUI = (protyle: IProtyle) => {
}
});
let overAttr = false;
- /// #if !MOBILE
- protyle.element.addEventListener("mouseover", (event: KeyboardEvent & {
+ protyle.element.addEventListener(isMobile() ? "pointerover" : "mouseover", (event: PointerEvent & {
target: HTMLElement
}) => {
+ if (isMobile() && event.pointerType !== "mouse") {
+ return;
+ }
if (hasClosestByClassName(event.target, "protyle-db-attr")) {
return;
}
@@ -290,7 +292,6 @@ export const initUI = (protyle: IProtyle) => {
}
}
});
- /// #endif
};
export const addLoading = (protyle: IProtyle, msg?: string) => {