mirror of
https://github.com/zclzone/vue-naive-admin.git
synced 2026-01-22 15:40:21 +08:00
fix: 修复简约布局下不初始化主题色问题
This commit is contained in:
@@ -52,4 +52,8 @@ const tabStore = useTabStore()
|
|||||||
const keepAliveNames = computed(() => {
|
const keepAliveNames = computed(() => {
|
||||||
return tabStore.tabs.filter((item) => item.keepAlive).map((item) => item.name)
|
return tabStore.tabs.filter((item) => item.keepAlive).map((item) => item.name)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
watchEffect(() => {
|
||||||
|
appStore.setThemeColor(appStore.primaryColor, appStore.isDark)
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -18,8 +18,4 @@ import { useAppStore } from '@/store'
|
|||||||
const appStore = useAppStore()
|
const appStore = useAppStore()
|
||||||
|
|
||||||
const primaryColors = Object.entries(getPresetColors()).map(([, value]) => value.primary)
|
const primaryColors = Object.entries(getPresetColors()).map(([, value]) => value.primary)
|
||||||
|
|
||||||
watchEffect(() => {
|
|
||||||
appStore.setThemeColor(appStore.primaryColor, appStore.isDark)
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user