mirror of
https://github.com/mizhexiaoxiao/vue-fastapi-admin.git
synced 2026-10-03 16:53:31 +00:00
add locale changer
This commit is contained in:
@@ -11,6 +11,7 @@ export const useAppStore = defineStore('app', {
|
||||
/** keepAlive路由的key,重新赋值可重置keepAlive */
|
||||
aliveKeys: {},
|
||||
isDark,
|
||||
locale: 'en'
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
@@ -45,5 +46,8 @@ export const useAppStore = defineStore('app', {
|
||||
toggleDark() {
|
||||
this.isDark = !this.isDark
|
||||
},
|
||||
setLocale(locale) {
|
||||
this.locale = locale
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user