minor change to theme service
This commit is contained in:
1 parent
009617f7af
commit
e8f3f47c0b
1 file changed
+3
-3
@@ -16,11 +16,11 @@ export class ThemeService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private loadTheme(): void {
|
private loadTheme(): void {
|
||||||
if (!localStorage.getItem('theme')) {
|
if (localStorage.getItem('theme')) {
|
||||||
this.theme = this.getSystemTheme();
|
|
||||||
} else {
|
|
||||||
this.theme =
|
this.theme =
|
||||||
(localStorage.getItem('theme') as 'light' | 'dark') || 'light';
|
(localStorage.getItem('theme') as 'light' | 'dark') || 'light';
|
||||||
|
} else {
|
||||||
|
this.theme = this.getSystemTheme();
|
||||||
}
|
}
|
||||||
this.applyTheme();
|
this.applyTheme();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user