diff options
| author | Jacob Richman <[email protected]> | 2025-07-25 17:36:42 -0700 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-07-26 00:36:42 +0000 |
| commit | ad2ef080aae2e21bf04ad8e922719ceaa81f1e5f (patch) | |
| tree | 204911c95219d4cdf0bdaa3db827124ff900f078 /packages/cli/src/ui/themes/theme-manager.ts | |
| parent | b089845f1c34e5475bcae9cc8eb42fba8be9adc4 (diff) | |
Fix so legacy custom themes still load. (#4757)
Co-authored-by: matt korwel <[email protected]>
Diffstat (limited to 'packages/cli/src/ui/themes/theme-manager.ts')
| -rw-r--r-- | packages/cli/src/ui/themes/theme-manager.ts | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/packages/cli/src/ui/themes/theme-manager.ts b/packages/cli/src/ui/themes/theme-manager.ts index bc5949ad..e30c1cce 100644 --- a/packages/cli/src/ui/themes/theme-manager.ts +++ b/packages/cli/src/ui/themes/theme-manager.ts @@ -75,8 +75,18 @@ class ThemeManager { )) { const validation = validateCustomTheme(customThemeConfig); if (validation.isValid) { + if (validation.warning) { + console.warn(`Theme "${name}": ${validation.warning}`); + } + const themeWithDefaults: CustomTheme = { + ...DEFAULT_THEME.colors, + ...customThemeConfig, + name: customThemeConfig.name || name, + type: 'custom', + }; + try { - const theme = createCustomTheme(customThemeConfig); + const theme = createCustomTheme(themeWithDefaults); this.customThemes.set(name, theme); } catch (error) { console.warn(`Failed to load custom theme "${name}":`, error); |
