fix: Vorübergehend nur Dark Mode erlaubt wegen localStorage Problem
This commit is contained in:
parent
4a1f3f14da
commit
fb0e719616
@ -65,7 +65,7 @@ export class BaseTableComponent<TModel, TApiService extends ApiService<TModel>>
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
theme: GuiTheme = localStorage.getItem('theme') === 'dark' ? GuiTheme.DARK : GuiTheme.FABRIC;
|
theme: GuiTheme = GuiTheme.DARK;
|
||||||
|
|
||||||
private themeSubscription: Subscription = new Subscription();
|
private themeSubscription: Subscription = new Subscription();
|
||||||
|
|
||||||
|
|||||||
@ -22,7 +22,6 @@ export class LoginComponent {
|
|||||||
IsPwdHidden: boolean = true;
|
IsPwdHidden: boolean = true;
|
||||||
|
|
||||||
constructor(private authService: AuthenticationService, @Inject(MAT_DIALOG_DATA) public data: any) {
|
constructor(private authService: AuthenticationService, @Inject(MAT_DIALOG_DATA) public data: any) {
|
||||||
//localStorage.getItem('theme') === 'dark'
|
|
||||||
if (typeof (this.afterLogin) == typeof (data.afterLogin))
|
if (typeof (this.afterLogin) == typeof (data.afterLogin))
|
||||||
this.afterLogin = data.afterLogin;
|
this.afterLogin = data.afterLogin;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -26,7 +26,7 @@ export class NavMenuComponent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
get isDarkTheme(): boolean {
|
get isDarkTheme(): boolean {
|
||||||
return localStorage.getItem('theme') === 'dark'
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
collapse() {
|
collapse() {
|
||||||
|
|||||||
@ -17,7 +17,6 @@ export class ColorModeService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
setTheme(theme: Theme) {
|
setTheme(theme: Theme) {
|
||||||
localStorage.setItem('theme', theme)
|
|
||||||
this.updateTheme();
|
this.updateTheme();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -76,7 +75,7 @@ export const ParseTheme: (value: string) => Theme | undefined = (value: string)
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function GetLocalTheme(): Theme {
|
export function GetLocalTheme(): Theme {
|
||||||
let sTheme: string | null = localStorage.getItem('theme');
|
let sTheme: string | null = 'dark';
|
||||||
|
|
||||||
if (sTheme === null)
|
if (sTheme === null)
|
||||||
return Theme.Dark;
|
return Theme.Dark;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user