mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-04-18 08:21:34 +08:00
fix: linux theme sync (#5273)
This commit is contained in:
parent
ae319279ae
commit
413f29e22a
@ -53,10 +53,13 @@ export const useCustomTheme = () => {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (
|
const preferBrowserMatchMedia =
|
||||||
typeof window !== "undefined" &&
|
typeof window !== "undefined" &&
|
||||||
typeof window.matchMedia === "function"
|
typeof window.matchMedia === "function" &&
|
||||||
) {
|
// Skip Tauri flow when running purely in browser.
|
||||||
|
!("__TAURI__" in window);
|
||||||
|
|
||||||
|
if (preferBrowserMatchMedia) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user