@osovitny/anatoly 3.20.3 → 3.20.5
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.
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, EventEmitter, Component, Output, Input, Inject, Pipe, provideAppInitializer, inject, NgModule, Directive, ChangeDetectionStrategy, ViewChild, ViewEncapsulation, HostListener, HostBinding, APP_INITIALIZER } from '@angular/core';
|
|
3
|
-
import { BehaviorSubject, forkJoin, Subject, filter, takeUntil, map as map$1, catchError, of, merge, timer, fromEvent, firstValueFrom } from 'rxjs';
|
|
3
|
+
import { BehaviorSubject, forkJoin, Subject, filter, takeUntil, map as map$1, catchError, of, merge, timer, fromEvent, firstValueFrom, lastValueFrom } from 'rxjs';
|
|
4
4
|
import { map, tap, mergeMap } from 'rxjs/operators';
|
|
5
5
|
import * as i1 from '@angular/common/http';
|
|
6
|
-
import { HttpResponse, HttpClient, HTTP_INTERCEPTORS, HttpClientModule } from '@angular/common/http';
|
|
6
|
+
import { HttpResponse, HttpClient, provideHttpClient, HTTP_INTERCEPTORS, HttpClientModule } from '@angular/common/http';
|
|
7
7
|
import * as i1$1 from '@angular/common';
|
|
8
8
|
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
9
9
|
import { format, formatDistance, formatDistanceToNow } from 'date-fns';
|
|
@@ -357,7 +357,7 @@ class AppContextService extends ApiServiceBase {
|
|
|
357
357
|
//standardJsonFilesLoaded
|
|
358
358
|
this._standardJsonFilesLoaded = new BehaviorSubject(null);
|
|
359
359
|
this.standardJsonFilesLoaded$ = this._standardJsonFilesLoaded.asObservable();
|
|
360
|
-
this.baseUrl = `${ApiUrl}/
|
|
360
|
+
this.baseUrl = `${ApiUrl}/app`;
|
|
361
361
|
}
|
|
362
362
|
//fires
|
|
363
363
|
fireUpdated(data) {
|
|
@@ -2729,7 +2729,7 @@ class StarterService extends ApiServiceBase {
|
|
|
2729
2729
|
//Logging
|
|
2730
2730
|
let stopwatch = new Stopwatch("@osovitny/anatoly. StarterService: getting AppContext from API");
|
|
2731
2731
|
stopwatch.start();
|
|
2732
|
-
this.baseUrl = `${ApiUrl}/
|
|
2732
|
+
this.baseUrl = `${ApiUrl}/app`;
|
|
2733
2733
|
return this.get('applicationStarting').pipe(map(data => {
|
|
2734
2734
|
//Logging
|
|
2735
2735
|
stopwatch.stop();
|
|
@@ -10251,6 +10251,34 @@ class SafeHtmlPipe {
|
|
|
10251
10251
|
</file>
|
|
10252
10252
|
*/
|
|
10253
10253
|
|
|
10254
|
+
class AppService extends ApiServiceBase {
|
|
10255
|
+
constructor(http) {
|
|
10256
|
+
super(http);
|
|
10257
|
+
this.http = http;
|
|
10258
|
+
this.baseUrl = `${ApiUrl}/app`;
|
|
10259
|
+
}
|
|
10260
|
+
loadAppInitializerSettings() {
|
|
10261
|
+
//Logging
|
|
10262
|
+
let stopwatch = new Stopwatch("@osovitny/anatoly. AppService: loadAppInitializerSettings");
|
|
10263
|
+
stopwatch.start();
|
|
10264
|
+
return this.get('loadAppInitializerSettings').pipe(map$1(data => {
|
|
10265
|
+
//Logging
|
|
10266
|
+
stopwatch.stop();
|
|
10267
|
+
stopwatch.printElapsedAsMilliseconds();
|
|
10268
|
+
console.log('loadAppInitializerSettings');
|
|
10269
|
+
console.log(data);
|
|
10270
|
+
}));
|
|
10271
|
+
}
|
|
10272
|
+
static { this.ɵfac = function AppService_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || AppService)(i0.ɵɵinject(i1.HttpClient)); }; }
|
|
10273
|
+
static { this.ɵprov = /*@__PURE__*/ i0.ɵɵdefineInjectable({ token: AppService, factory: AppService.ɵfac, providedIn: 'root' }); }
|
|
10274
|
+
}
|
|
10275
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AppService, [{
|
|
10276
|
+
type: Injectable,
|
|
10277
|
+
args: [{
|
|
10278
|
+
providedIn: 'root'
|
|
10279
|
+
}]
|
|
10280
|
+
}], () => [{ type: i1.HttpClient }], null); })();
|
|
10281
|
+
|
|
10254
10282
|
/*
|
|
10255
10283
|
<file>
|
|
10256
10284
|
Project:
|
|
@@ -10276,9 +10304,15 @@ class AnatolyCoreModule {
|
|
|
10276
10304
|
static { this.ɵfac = function AnatolyCoreModule_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || AnatolyCoreModule)(i0.ɵɵinject(i0.Injector)); }; }
|
|
10277
10305
|
static { this.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: AnatolyCoreModule }); }
|
|
10278
10306
|
static { this.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ providers: [
|
|
10307
|
+
provideHttpClient(),
|
|
10308
|
+
provideAppInitializer(() => {
|
|
10309
|
+
const appService = inject(AppService);
|
|
10310
|
+
return lastValueFrom(appService.loadAppInitializerSettings());
|
|
10311
|
+
}),
|
|
10279
10312
|
//Guards
|
|
10280
10313
|
StarterGuard,
|
|
10281
10314
|
//Services
|
|
10315
|
+
AppService,
|
|
10282
10316
|
BrowserService,
|
|
10283
10317
|
DigitalMarketingService,
|
|
10284
10318
|
GoogleAnalyticsService,
|
|
@@ -10315,9 +10349,15 @@ class AnatolyCoreModule {
|
|
|
10315
10349
|
LocalizationModule
|
|
10316
10350
|
],
|
|
10317
10351
|
providers: [
|
|
10352
|
+
provideHttpClient(),
|
|
10353
|
+
provideAppInitializer(() => {
|
|
10354
|
+
const appService = inject(AppService);
|
|
10355
|
+
return lastValueFrom(appService.loadAppInitializerSettings());
|
|
10356
|
+
}),
|
|
10318
10357
|
//Guards
|
|
10319
10358
|
StarterGuard,
|
|
10320
10359
|
//Services
|
|
10360
|
+
AppService,
|
|
10321
10361
|
BrowserService,
|
|
10322
10362
|
DigitalMarketingService,
|
|
10323
10363
|
GoogleAnalyticsService,
|