@osovitny/anatoly 3.17.73 → 3.17.74
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/core/core.module.mjs +4 -1
- package/esm2022/lib/core/guards/starter.guard.mjs +46 -0
- package/esm2022/lib/core/index.mjs +4 -2
- package/esm2022/lib/core/services/appcontext.service.mjs +7 -1
- package/esm2022/lib/core/services/starter.service.mjs +12 -17
- package/fesm2022/osovitny-anatoly.mjs +159 -120
- package/fesm2022/osovitny-anatoly.mjs.map +1 -1
- package/lib/core/guards/starter.guard.d.ts +13 -0
- package/lib/core/index.d.ts +2 -1
- package/lib/core/services/appcontext.service.d.ts +5 -2
- package/lib/core/services/starter.service.d.ts +7 -3
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ActivatedRouteSnapshot, CanActivate, CanActivateChild, RouterStateSnapshot } from '@angular/router';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { StarterService } from "../services/starter.service";
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export declare class StarterGuard implements CanActivate, CanActivateChild {
|
|
6
|
+
protected starter: StarterService;
|
|
7
|
+
constructor(starter: StarterService);
|
|
8
|
+
private ensureApplicationStarted;
|
|
9
|
+
canActivate(next: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean>;
|
|
10
|
+
canActivateChild(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean>;
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<StarterGuard, never>;
|
|
12
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<StarterGuard>;
|
|
13
|
+
}
|
package/lib/core/index.d.ts
CHANGED
|
@@ -5,8 +5,9 @@ export * from './converts/convert';
|
|
|
5
5
|
export * from './converts/dateConvert';
|
|
6
6
|
export * from './converts/xmlFormatter';
|
|
7
7
|
export * from './go/base-go.service';
|
|
8
|
-
export * from './guards/once-import.guard';
|
|
9
8
|
export * from './interceptors/httpInterceptor';
|
|
9
|
+
export * from './guards/once-import.guard';
|
|
10
|
+
export * from './guards/starter.guard';
|
|
10
11
|
export * from './localization/localize.pipe';
|
|
11
12
|
export * from './localization/localization.service';
|
|
12
13
|
export * from './localization/settings.module';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { HttpClient } from '@angular/common/http';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
2
3
|
import { ApiServiceBase } from '../../data/base/api.service';
|
|
3
4
|
import { LocalStorageService, SessionStorageService } from './web-storage.service';
|
|
4
5
|
import * as i0 from "@angular/core";
|
|
@@ -10,8 +11,8 @@ export declare class AppContextService extends ApiServiceBase {
|
|
|
10
11
|
private subscription;
|
|
11
12
|
private _updated;
|
|
12
13
|
private _userUpdated;
|
|
13
|
-
readonly updated$:
|
|
14
|
-
readonly userUpdated$:
|
|
14
|
+
readonly updated$: Observable<any>;
|
|
15
|
+
readonly userUpdated$: Observable<any>;
|
|
15
16
|
constructor(http: HttpClient, localStorage: LocalStorageService, sessionStorage: SessionStorageService);
|
|
16
17
|
private fireUpdated;
|
|
17
18
|
protected fireUserUpdated(): void;
|
|
@@ -21,6 +22,8 @@ export declare class AppContextService extends ApiServiceBase {
|
|
|
21
22
|
private getCurrentPrivate;
|
|
22
23
|
private updateCurrentIfExpired;
|
|
23
24
|
init(context?: any): void;
|
|
25
|
+
loadRequiredJsonFiles(): Observable<any>;
|
|
26
|
+
loadRequiredItems(): Observable<any>;
|
|
24
27
|
updateCurrent(success?: Function): void;
|
|
25
28
|
clearLocalStorage(): void;
|
|
26
29
|
clearSessionStorage(): void;
|
|
@@ -2,11 +2,15 @@ import { HttpClient } from '@angular/common/http';
|
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { ApiServiceBase } from '../../data/base/api.service';
|
|
4
4
|
import { LoggingService } from '../logging/logging.service';
|
|
5
|
-
|
|
5
|
+
import { AppContextService } from '../services/appcontext.service';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
export declare class StarterService extends ApiServiceBase {
|
|
6
8
|
protected http: HttpClient;
|
|
7
|
-
protected appContext:
|
|
9
|
+
protected appContext: AppContextService;
|
|
8
10
|
protected logger: LoggingService;
|
|
9
|
-
constructor(http: HttpClient, appContext:
|
|
11
|
+
constructor(http: HttpClient, appContext: AppContextService, logger: LoggingService);
|
|
10
12
|
private applicationStarting;
|
|
11
13
|
ensureApplicationStarted(): Observable<any>;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<StarterService, never>;
|
|
15
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<StarterService>;
|
|
12
16
|
}
|