diff --git a/web/src/App.vue b/web/src/App.vue index 5a2214e9f8..63cbbdd151 100644 --- a/web/src/App.vue +++ b/web/src/App.vue @@ -3,7 +3,7 @@ id="app" class="bg-gray-50 text-slate-700 !dark:text-slate-500 dark:bg-slate-800" > - + @@ -15,7 +15,7 @@ import Application from '@/components/application/index.vue' import { useAppStore } from '@/pinia' - useAppStore() + const appStore = useAppStore() defineOptions({ name: 'App' }) diff --git a/web/src/pinia/modules/app.js b/web/src/pinia/modules/app.js index 9eb9dea1f0..374e4ebed1 100644 --- a/web/src/pinia/modules/app.js +++ b/web/src/pinia/modules/app.js @@ -19,7 +19,8 @@ export const useAppStore = defineStore('app', () => { show_watermark: true, side_mode: 'normal', // 页面过渡动画配置 - transition_type: 'slide' + transition_type: 'slide', + global_size: 'default' }) const isDark = useDark({ @@ -99,6 +100,10 @@ export const useAppStore = defineStore('app', () => { config.transition_type = e } + const toggleGlobalSize = (e) => { + config.global_size = e + } + const baseCoinfg = { weakness: false, grey: false, @@ -111,7 +116,8 @@ export const useAppStore = defineStore('app', () => { show_watermark: true, side_mode: 'normal', // 页面过渡动画配置 - transition_type: 'slide' + transition_type: 'slide', + global_size: 'default' } const resetConfig = () => { @@ -150,6 +156,7 @@ export const useAppStore = defineStore('app', () => { toggleConfigWatermark, toggleSideMode, toggleTransition, - resetConfig + resetConfig, + toggleGlobalSize } }) diff --git a/web/src/view/layout/setting/components/layoutModeCard.vue b/web/src/view/layout/setting/components/layoutModeCard.vue index 5f1fd1b795..abe8fcc0f1 100644 --- a/web/src/view/layout/setting/components/layoutModeCard.vue +++ b/web/src/view/layout/setting/components/layoutModeCard.vue @@ -1,9 +1,9 @@