fix: apply system theme dynamically (#4010)

Remove appearance comparison
This commit is contained in:
RoccoSmit
2024-10-12 00:05:52 +11:00
committed by GitHub
parent 43d13a3edc
commit 35cf975e76

View File

@@ -34,10 +34,8 @@ const App = () => {
useEffect(() => {
const darkMediaQuery = window.matchMedia("(prefers-color-scheme: dark)");
const handleColorSchemeChange = (e: MediaQueryListEvent) => {
if (commonContext.appearance === "system") {
const mode = e.matches ? "dark" : "light";
setMode(mode);
}
const mode = e.matches ? "dark" : "light";
setMode(mode);
};
try {