1
0
mirror of https://github.com/zclzone/vue-naive-admin.git synced 2025-04-30 22:29:01 +08:00

fix: 修复简约布局下不初始化主题色问题

This commit is contained in:
zclzone 2024-05-10 20:18:15 +08:00
parent cf3c4b9020
commit fd34922acc
2 changed files with 4 additions and 4 deletions

View File

@ -52,4 +52,8 @@ const tabStore = useTabStore()
const keepAliveNames = computed(() => {
return tabStore.tabs.filter((item) => item.keepAlive).map((item) => item.name)
})
watchEffect(() => {
appStore.setThemeColor(appStore.primaryColor, appStore.isDark)
})
</script>

View File

@ -18,8 +18,4 @@ import { useAppStore } from '@/store'
const appStore = useAppStore()
const primaryColors = Object.entries(getPresetColors()).map(([, value]) => value.primary)
watchEffect(() => {
appStore.setThemeColor(appStore.primaryColor, appStore.isDark)
})
</script>