Connection lost banner (#1101)

* connection lost banner
if there is no connection to the home server

Signed-off-by: Timo K <toger5@hotmail.de>
This commit is contained in:
Timo
2023-06-19 15:36:03 +02:00
committed by GitHub
parent cabad628b4
commit 2ffe000bf5
7 changed files with 130 additions and 5 deletions

View File

@@ -45,6 +45,12 @@ class DependencyLoadStates {
export class Initializer {
private static internalInstance: Initializer;
private isInitialized = false;
public static isInitialized(): boolean {
return Initializer.internalInstance?.isInitialized;
}
public static initBeforeReact() {
// this maybe also needs to return a promise in the future,
// if we have to do async inits before showing the loading screen
@@ -223,6 +229,7 @@ export class Initializer {
if (this.loadStates.allDepsAreLoaded()) {
// resolve if there is no dependency that is not loaded
resolve();
this.isInitialized = true;
}
}
private initPromise: Promise<void> | null;