Vanessa 2026-01-05 19:03:54 +08:00
parent 0711bbf64a
commit 5577d1b585
2 changed files with 17 additions and 57 deletions

View file

@ -1,14 +1,9 @@
const CONTAINER_BACKEND_SET = new Set(["docker", "ios", "android", "harmony"]);
const MOBILE_BACKEND_SET = new Set(["ios", "android", "harmony"]);
export const isKernelInContainer = (): boolean => {
return CONTAINER_BACKEND_SET.has(window.siyuan.config.system.container);
};
export const isKernelInMobile = (): boolean => {
return MOBILE_BACKEND_SET.has(window.siyuan.config.system.container);
};
export const isMobile = () => {
return document.getElementById("sidebar") ? true : false;
};
@ -22,7 +17,6 @@ export const getBackend = () => {
}
};
// "desktop" | "desktop-window" | "mobile" | "browser-desktop" | "browser-mobile"
export const getFrontend = () => {
/// #if MOBILE