fix light theme not detected on startup

This commit is contained in:
Victor Oliva
2025-03-29 20:59:09 +01:00
parent cde69b8fd2
commit a9657e08d4

View File

@@ -10,7 +10,7 @@ import { fromEvent, map } from "rxjs"
const getCurrentMedia = (): "light" | "dark" =>
window.matchMedia
? window.matchMedia("(prefers-color-scheme: dark)")
? window.matchMedia("(prefers-color-scheme: dark)").matches
? "dark"
: "light"
: "dark"