From 3a964561f04c07b73a5d7bdfddf80a2cf355ff83 Mon Sep 17 00:00:00 2001 From: kwicxy Date: Thu, 29 May 2025 22:57:50 +0800 Subject: [PATCH 01/33] style: minor code style changes --- dashboard/src/config.ts | 4 ++-- dashboard/src/layouts/full/FullLayout.vue | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/dashboard/src/config.ts b/dashboard/src/config.ts index 9f70123a7..f52812ad8 100644 --- a/dashboard/src/config.ts +++ b/dashboard/src/config.ts @@ -8,10 +8,10 @@ export type ConfigProps = { }; function checkUITheme() { + /* 检查localStorage有无记忆的主题选项,如有则使用,否则使用默认值 */ const theme = localStorage.getItem("uiTheme"); - console.log('memorized theme: ', theme); if (!theme || !(['PurpleTheme', 'PurpleThemeDark'].includes(theme))) { - localStorage.setItem("uiTheme", "PurpleTheme"); + localStorage.setItem("uiTheme", "PurpleTheme"); // todo: 这部分可以根据vuetify.ts的默认主题动态调整 return 'PurpleTheme'; } else return theme; } diff --git a/dashboard/src/layouts/full/FullLayout.vue b/dashboard/src/layouts/full/FullLayout.vue index 0380b350e..a0754cafd 100644 --- a/dashboard/src/layouts/full/FullLayout.vue +++ b/dashboard/src/layouts/full/FullLayout.vue @@ -2,14 +2,13 @@ import { RouterView } from 'vue-router'; import VerticalSidebarVue from './vertical-sidebar/VerticalSidebar.vue'; import VerticalHeaderVue from './vertical-header/VerticalHeader.vue'; -import { useCustomizerStore } from '../../stores/customizer'; +import { useCustomizerStore } from '@/stores/customizer'; const customizer = useCustomizerStore();