diff --git a/src/App.vue b/src/App.vue index 92ccab0..7990e42 100644 --- a/src/App.vue +++ b/src/App.vue @@ -15,12 +15,13 @@ const currentSize = computed(() => appStore.getCurrentSize) const greyMode = computed(() => appStore.getGreyMode) -const initDark = () => { +// 根据浏览器当前主题设置系统主题色 +const setDefaultTheme = () => { const isDarkTheme = isDark() appStore.setIsDark(isDarkTheme) } -initDark() +setDefaultTheme()