diff --git a/packages/effects/layouts/src/widgets/preferences/blocks/theme/builtin.vue b/packages/effects/layouts/src/widgets/preferences/blocks/theme/builtin.vue index 27dfd28ae..d70bb2321 100644 --- a/packages/effects/layouts/src/widgets/preferences/blocks/theme/builtin.vue +++ b/packages/effects/layouts/src/widgets/preferences/blocks/theme/builtin.vue @@ -104,7 +104,7 @@ function selectColor() { watch( () => [modelValue.value, props.isDark] as [BuiltinThemeType, boolean], - ([themeType, isDark]) => { + ([themeType, isDark], [_, isDarkPrev]) => { const theme = builtinThemePresets.value.find( (item) => item.type === themeType, ); @@ -113,7 +113,9 @@ watch( ? theme.darkPrimaryColor || theme.primaryColor : theme.primaryColor; - themeColorPrimary.value = primaryColor || theme.color; + if (!(theme.type === 'custom' && isDark !== isDarkPrev)) { + themeColorPrimary.value = primaryColor || theme.color; + } } }, );