From 7ca80fc086b94e656d3027b42473d25898c8eb3a Mon Sep 17 00:00:00 2001 From: Louis Lam Date: Thu, 12 Aug 2021 22:17:20 +0800 Subject: [PATCH] fix auto theme --- src/mixins/theme.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mixins/theme.js b/src/mixins/theme.js index 673a8caa6..5b4c831d7 100644 --- a/src/mixins/theme.js +++ b/src/mixins/theme.js @@ -2,7 +2,7 @@ export default { data() { return { - system: (window.matchMedia("(prefers-color-scheme: dark)")) ? "dark" : "light", + system: (window.matchMedia("(prefers-color-scheme: dark)").matches) ? "dark" : "light", userTheme: localStorage.theme, }; },