mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
fix: apply theme on init
This commit is contained in:
1 parent
29197dcfb9
commit
b4947999df
3 files changed
+27
-14
No files matched your search
@@ -141,7 +141,9 @@ export class ThemeStore {
|
||||
});
|
||||
|
||||
// auto-apply colors to dom from active theme
|
||||
reaction(() => this.activeTheme, this.onChange);
|
||||
reaction(() => this.activeTheme, this.onChange, {
|
||||
fireImmediately: true,
|
||||
});
|
||||
|
||||
// apply theme from configuration
|
||||
import("./config.store").then(({ configStore }) => {
|
||||
@@ -184,6 +186,7 @@ export class ThemeStore {
|
||||
try {
|
||||
await this.load(themeId);
|
||||
this.activeThemeId = themeId;
|
||||
console.log('THEME', themeId, this.themes.get(themeId))
|
||||
} catch (err) {
|
||||
if (themeId !== this.defaultTheme.name) {
|
||||
this.setTheme(); // fallback to default theme
|
||||
|
||||
Reference in new issue
Block a user