Merge remote-tracking branch 'origin/main'
This commit is contained in:
commit
af0c5c11c0
@ -4,7 +4,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"ng": "ng",
|
"ng": "ng",
|
||||||
"start": "ng serve",
|
"start": "ng serve",
|
||||||
"build": "ng build",
|
"build": "ng build --output-hashing none",
|
||||||
"watch": "ng build --watch --configuration development",
|
"watch": "ng build --watch --configuration development",
|
||||||
"test": "ng test"
|
"test": "ng test"
|
||||||
},
|
},
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import { Component, OnInit, Input } from '@angular/core';
|
import { Component, OnInit, Input } from '@angular/core';
|
||||||
|
import { GoSetStatus } from 'src/app/services/go';
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './loading-screen.component.html',
|
templateUrl: './loading-screen.component.html',
|
||||||
styleUrls: ['./loading-screen.component.scss']
|
styleUrls: ['./loading-screen.component.scss']
|
||||||
@ -14,6 +14,10 @@ export class LoadingScreenComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
|
document.addEventListener('GoSetStatus_Callback', (event:any) => {
|
||||||
|
this.SetStatus(event.detail)
|
||||||
|
console.log("Set loading screen status: " + event.detail)
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -12,10 +12,11 @@ export interface Go extends Window {
|
|||||||
export interface GoCallback extends Window {
|
export interface GoCallback extends Window {
|
||||||
SetVersion: (value: string) => void;
|
SetVersion: (value: string) => void;
|
||||||
GoChangeRoute: (value: string) => void;
|
GoChangeRoute: (value: string) => void;
|
||||||
|
GoSetStatus: (value: string) => void;
|
||||||
}
|
}
|
||||||
|
|
||||||
let { GoGetGames, GoRunGame, GoGetSessions, GoRunSession, GoWebViewInit } = window as unknown as Go;
|
let { GoGetGames, GoRunGame, GoGetSessions, GoRunSession, GoWebViewInit } = window as unknown as Go;
|
||||||
let { SetVersion, GoChangeRoute } = window as unknown as GoCallback;
|
let { SetVersion, GoChangeRoute, GoSetStatus } = window as unknown as GoCallback;
|
||||||
|
|
||||||
let w = window as unknown as GoCallback;
|
let w = window as unknown as GoCallback;
|
||||||
|
|
||||||
@ -37,4 +38,11 @@ let w = window as unknown as GoCallback;
|
|||||||
document.dispatchEvent(event);
|
document.dispatchEvent(event);
|
||||||
};
|
};
|
||||||
|
|
||||||
export { GoGetGames, GoGetSessions, SetVersion, GoRunGame, GoChangeRoute, GoWebViewInit, GoRunSession };
|
(<GoCallback>(<unknown>window)).GoSetStatus = function <T>(value: T): void {
|
||||||
|
const event = new CustomEvent<T>('GoSetStatus_Callback', {
|
||||||
|
detail: value,
|
||||||
|
});
|
||||||
|
document.dispatchEvent(event);
|
||||||
|
};
|
||||||
|
|
||||||
|
export { GoGetGames, GoGetSessions, SetVersion, GoRunGame, GoChangeRoute, GoSetStatus, GoWebViewInit, GoRunSession };
|
||||||
|
Loading…
Reference in New Issue
Block a user