@igo2/auth 17.0.0-next.3 → 17.0.0-next.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.
Files changed (54) hide show
  1. package/environment/environment.interface.d.ts +2 -2
  2. package/esm2022/environment/environment.interface.mjs +1 -1
  3. package/esm2022/form/auth-form.module.mjs +2 -24
  4. package/esm2022/form/public_api.mjs +1 -3
  5. package/esm2022/form/shared/index.mjs +1 -3
  6. package/esm2022/lib/auth.provider.mjs +22 -0
  7. package/esm2022/lib/shared/admin.guard.mjs +1 -1
  8. package/esm2022/lib/shared/auth-storage.interface.mjs +2 -0
  9. package/esm2022/lib/shared/auth-storage.service.mjs +100 -0
  10. package/esm2022/lib/shared/auth.guard.mjs +1 -1
  11. package/esm2022/lib/shared/auth.interceptor.mjs +1 -1
  12. package/esm2022/lib/shared/auth.interface.mjs +5 -2
  13. package/esm2022/lib/shared/auth.service.mjs +1 -1
  14. package/esm2022/lib/shared/index.mjs +3 -1
  15. package/esm2022/lib/shared/logged.guard.mjs +1 -1
  16. package/esm2022/lib/shared/profils.guard.mjs +1 -1
  17. package/esm2022/lib/shared/token.service.mjs +1 -1
  18. package/esm2022/microsoft/auth-microsoft.provider.mjs +43 -30
  19. package/esm2022/monitoring/auth-monitoring/auth-monitoring.provider.mjs +24 -0
  20. package/esm2022/monitoring/auth-monitoring/auth-monitoring.service.mjs +54 -0
  21. package/esm2022/monitoring/igo2-auth-monitoring.mjs +5 -0
  22. package/esm2022/monitoring/public_api.mjs +3 -0
  23. package/esm2022/public_api.mjs +3 -12
  24. package/fesm2022/igo2-auth-form.mjs +9 -120
  25. package/fesm2022/igo2-auth-form.mjs.map +1 -1
  26. package/fesm2022/igo2-auth-microsoft.mjs +44 -31
  27. package/fesm2022/igo2-auth-microsoft.mjs.map +1 -1
  28. package/fesm2022/igo2-auth-monitoring.mjs +81 -0
  29. package/fesm2022/igo2-auth-monitoring.mjs.map +1 -0
  30. package/fesm2022/igo2-auth.mjs +207 -162
  31. package/fesm2022/igo2-auth.mjs.map +1 -1
  32. package/form/auth-form.module.d.ts +0 -2
  33. package/form/public_api.d.ts +0 -2
  34. package/form/shared/index.d.ts +0 -2
  35. package/form/src/auth-form/auth-intern.theme.scss +19 -0
  36. package/form/src/auth-form.theme.scss +9 -0
  37. package/lib/auth.provider.d.ts +3 -0
  38. package/{form → lib}/shared/auth-storage.service.d.ts +2 -1
  39. package/lib/shared/auth.interface.d.ts +8 -0
  40. package/lib/shared/index.d.ts +2 -0
  41. package/locale/en.auth.json +29 -29
  42. package/locale/fr.auth.json +33 -33
  43. package/microsoft/auth-microsoft.provider.d.ts +2 -23
  44. package/{lib → monitoring}/auth-monitoring/auth-monitoring.service.d.ts +1 -1
  45. package/monitoring/index.d.ts +5 -0
  46. package/monitoring/public_api.d.ts +2 -0
  47. package/package.json +9 -3
  48. package/public_api.d.ts +2 -11
  49. package/esm2022/form/shared/auth-storage.interface.mjs +0 -2
  50. package/esm2022/form/shared/auth-storage.service.mjs +0 -98
  51. package/esm2022/lib/auth-monitoring/auth-monitoring.provider.mjs +0 -24
  52. package/esm2022/lib/auth-monitoring/auth-monitoring.service.mjs +0 -54
  53. /package/{form → lib}/shared/auth-storage.interface.d.ts +0 -0
  54. /package/{lib → monitoring}/auth-monitoring/auth-monitoring.provider.d.ts +0 -0
@@ -1,19 +1,19 @@
1
1
  import * as i1 from '@angular/common/http';
2
- import { HttpHeaders } from '@angular/common/http';
2
+ import { HttpHeaders, HTTP_INTERCEPTORS } from '@angular/common/http';
3
3
  import * as i0 from '@angular/core';
4
- import { Injectable, Optional, Inject, Injector, APP_INITIALIZER } from '@angular/core';
5
- import * as i3 from '@angular/router';
4
+ import { Injectable, Optional, makeEnvironmentProviders } from '@angular/core';
5
+ import { BaseStorage, StorageScope, StorageService } from '@igo2/core/storage';
6
6
  import * as i2 from '@igo2/core/config';
7
7
  import { ConfigService } from '@igo2/core/config';
8
+ import { jwtDecode } from 'jwt-decode';
9
+ import * as i3 from '@angular/router';
8
10
  import * as i4 from '@igo2/core/language';
9
11
  import * as i5 from '@igo2/core/message';
10
12
  import { Base64 } from '@igo2/utils';
11
- import { BehaviorSubject, of, first, switchMap } from 'rxjs';
13
+ import { BehaviorSubject, of } from 'rxjs';
12
14
  import { tap, catchError, map } from 'rxjs/operators';
13
15
  import { globalCacheBusterNotifier } from 'ts-cacheable';
14
- import { jwtDecode } from 'jwt-decode';
15
16
  import { Md5 } from 'ts-md5';
16
- import { identifySentryUser, MONITORING_OPTIONS } from '@igo2/core/monitoring';
17
17
 
18
18
  class TokenService {
19
19
  injector;
@@ -216,129 +216,99 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImpor
216
216
  type: Optional
217
217
  }] }] });
218
218
 
219
- class LoggedGuard {
219
+ class AuthStorageService extends BaseStorage {
220
+ http;
220
221
  authService;
221
- config;
222
- router;
223
- constructor(authService, config, router) {
222
+ tokenService;
223
+ constructor(config, http, authService, tokenService) {
224
+ super(config);
225
+ this.http = http;
224
226
  this.authService = authService;
225
- this.config = config;
226
- this.router = router;
227
+ this.tokenService = tokenService;
228
+ this.authService.authenticate$.subscribe((isAuthenticated) => {
229
+ if (isAuthenticated && this.options.url) {
230
+ this.http
231
+ .get(this.options.url)
232
+ .subscribe((userIgo) => {
233
+ if (userIgo && userIgo.preference) {
234
+ for (const key of Object.keys(userIgo.preference)) {
235
+ const value = userIgo.preference[key];
236
+ super.set(key, value);
237
+ }
238
+ }
239
+ });
240
+ }
241
+ });
227
242
  }
228
- canActivate(route, state) {
229
- if (this.authService.logged) {
230
- return true;
243
+ set(key, value, scope = StorageScope.LOCAL) {
244
+ if (scope === StorageScope.LOCAL &&
245
+ this.authService.authenticated &&
246
+ this.options.url) {
247
+ const preference = {};
248
+ preference[key] = value;
249
+ this.http.patch(this.options.url, { preference }).subscribe();
231
250
  }
232
- this.authService.redirectUrl = state.url;
233
- const authConfig = this.config.getConfig('auth');
234
- if (authConfig?.loginRoute) {
235
- this.router.navigateByUrl(authConfig.loginRoute);
251
+ super.set(key, value, scope);
252
+ }
253
+ remove(key, scope = StorageScope.LOCAL) {
254
+ if (scope === StorageScope.LOCAL &&
255
+ this.authService.authenticated &&
256
+ this.options.url) {
257
+ const preference = {};
258
+ preference[key] = undefined;
259
+ this.http.patch(this.options.url, { preference }).subscribe();
236
260
  }
237
- return false;
238
- }
239
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: LoggedGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
240
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: LoggedGuard, providedIn: 'root' });
241
- }
242
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: LoggedGuard, decorators: [{
243
- type: Injectable,
244
- args: [{
245
- providedIn: 'root'
246
- }]
247
- }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
248
-
249
- class AuthGuard {
250
- authService;
251
- config;
252
- router;
253
- constructor(authService, config, router) {
254
- this.authService = authService;
255
- this.config = config;
256
- this.router = router;
257
- }
258
- canActivate(route, state) {
259
- if (this.authService.authenticated) {
260
- return true;
261
+ super.remove(key, scope);
262
+ }
263
+ clear(scope = StorageScope.LOCAL) {
264
+ if (scope === StorageScope.LOCAL &&
265
+ this.authService.authenticated &&
266
+ this.options.url) {
267
+ this.http
268
+ .patch(this.options.url, { preference: {} }, {
269
+ params: {
270
+ mergePreference: 'false'
271
+ }
272
+ })
273
+ .subscribe();
261
274
  }
262
- this.authService.redirectUrl = state.url;
263
- const authConfig = this.config.getConfig('auth');
264
- if (authConfig?.loginRoute) {
265
- this.router.navigateByUrl(authConfig.loginRoute);
275
+ let token;
276
+ if (scope === StorageScope.LOCAL) {
277
+ token = this.tokenService.get();
266
278
  }
267
- return false;
268
- }
269
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
270
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthGuard, providedIn: 'root' });
271
- }
272
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthGuard, decorators: [{
273
- type: Injectable,
274
- args: [{
275
- providedIn: 'root'
276
- }]
277
- }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
278
-
279
- class AdminGuard {
280
- authService;
281
- config;
282
- router;
283
- constructor(authService, config, router) {
284
- this.authService = authService;
285
- this.config = config;
286
- this.router = router;
287
- }
288
- canActivate(route, state) {
289
- if (this.authService.isAdmin) {
290
- return true;
279
+ super.clear(scope);
280
+ if (token) {
281
+ this.tokenService.set(token);
291
282
  }
292
- this.authService.redirectUrl = state.url;
293
- const authConfig = this.config.getConfig('auth');
294
- if (authConfig?.loginRoute) {
295
- this.router.navigateByUrl(authConfig.loginRoute);
283
+ if (scope === StorageScope.LOCAL &&
284
+ this.authService.authenticated &&
285
+ this.options.url) {
286
+ this.http
287
+ .get(this.options.url)
288
+ .subscribe((userIgo) => {
289
+ if (userIgo && userIgo.preference) {
290
+ for (const key of Object.keys(userIgo.preference)) {
291
+ const value = userIgo.preference[key];
292
+ super.set(key, value);
293
+ }
294
+ }
295
+ });
296
296
  }
297
- return false;
298
297
  }
299
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AdminGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
300
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AdminGuard, providedIn: 'root' });
298
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthStorageService, deps: [{ token: i2.ConfigService }, { token: i1.HttpClient }, { token: AuthService }, { token: TokenService }], target: i0.ɵɵFactoryTarget.Injectable });
299
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthStorageService, providedIn: 'root' });
301
300
  }
302
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AdminGuard, decorators: [{
301
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthStorageService, decorators: [{
303
302
  type: Injectable,
304
303
  args: [{
305
304
  providedIn: 'root'
306
305
  }]
307
- }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
306
+ }], ctorParameters: () => [{ type: i2.ConfigService }, { type: i1.HttpClient }, { type: AuthService }, { type: TokenService }] });
308
307
 
309
- class ProfilsGuard {
310
- authService;
311
- config;
312
- router;
313
- constructor(authService, config, router) {
314
- this.authService = authService;
315
- this.config = config;
316
- this.router = router;
317
- }
318
- canActivate(_route, state) {
319
- return this.authService.getProfils().pipe(map((profils) => {
320
- const authConfig = this.config.getConfig('auth');
321
- if (profils &&
322
- profils.profils &&
323
- profils.profils.some((v) => authConfig.profilsGuard.indexOf(v) !== -1)) {
324
- return true;
325
- }
326
- this.authService.redirectUrl = state.url;
327
- if (authConfig?.loginRoute) {
328
- this.router.navigateByUrl(authConfig.loginRoute);
329
- }
330
- return false;
331
- }));
332
- }
333
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: ProfilsGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
334
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: ProfilsGuard, providedIn: 'root' });
335
- }
336
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: ProfilsGuard, decorators: [{
337
- type: Injectable,
338
- args: [{
339
- providedIn: 'root'
340
- }]
341
- }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
308
+ var AuthFeatureKind;
309
+ (function (AuthFeatureKind) {
310
+ AuthFeatureKind[AuthFeatureKind["Microsoft"] = 0] = "Microsoft";
311
+ })(AuthFeatureKind || (AuthFeatureKind = {}));
342
312
 
343
313
  class AuthInterceptor {
344
314
  config;
@@ -493,71 +463,146 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImpor
493
463
  }]
494
464
  }], ctorParameters: () => [{ type: i2.ConfigService }, { type: TokenService }, { type: i1.HttpClient }] });
495
465
 
496
- class AuthMonitoringService {
497
- configService;
498
- monitoringOptions;
499
- injector;
500
- // The AuthService need to be lazy provided because this service is provided in the APP_INITIALIZER
466
+ class LoggedGuard {
501
467
  authService;
502
- constructor(configService, monitoringOptions, injector) {
503
- this.configService = configService;
504
- this.monitoringOptions = monitoringOptions;
505
- this.injector = injector;
506
- if (!this.monitoringOptions?.identifyUser) {
507
- return;
468
+ config;
469
+ router;
470
+ constructor(authService, config, router) {
471
+ this.authService = authService;
472
+ this.config = config;
473
+ this.router = router;
474
+ }
475
+ canActivate(route, state) {
476
+ if (this.authService.logged) {
477
+ return true;
508
478
  }
509
- this.configService.isLoaded$
510
- .pipe(first((isLoaded) => isLoaded), switchMap(() => {
511
- this.authService = this.injector.get(AuthService);
512
- return this.authService?.authenticate$;
513
- }))
514
- .subscribe((isAuthenticated) => {
515
- const user = isAuthenticated ? this.authService.user : null;
516
- this._identifyUser(user);
517
- });
479
+ this.authService.redirectUrl = state.url;
480
+ const authConfig = this.config.getConfig('auth');
481
+ if (authConfig?.loginRoute) {
482
+ this.router.navigateByUrl(authConfig.loginRoute);
483
+ }
484
+ return false;
518
485
  }
519
- _identifyUser(user) {
520
- switch (this.monitoringOptions.provider) {
521
- case 'sentry':
522
- identifySentryUser(user);
523
- break;
524
- default:
525
- break;
486
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: LoggedGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
487
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: LoggedGuard, providedIn: 'root' });
488
+ }
489
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: LoggedGuard, decorators: [{
490
+ type: Injectable,
491
+ args: [{
492
+ providedIn: 'root'
493
+ }]
494
+ }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
495
+
496
+ class AuthGuard {
497
+ authService;
498
+ config;
499
+ router;
500
+ constructor(authService, config, router) {
501
+ this.authService = authService;
502
+ this.config = config;
503
+ this.router = router;
504
+ }
505
+ canActivate(route, state) {
506
+ if (this.authService.authenticated) {
507
+ return true;
508
+ }
509
+ this.authService.redirectUrl = state.url;
510
+ const authConfig = this.config.getConfig('auth');
511
+ if (authConfig?.loginRoute) {
512
+ this.router.navigateByUrl(authConfig.loginRoute);
526
513
  }
514
+ return false;
527
515
  }
528
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthMonitoringService, deps: [{ token: i2.ConfigService }, { token: MONITORING_OPTIONS, optional: true }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
529
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthMonitoringService, providedIn: 'root' });
516
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
517
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthGuard, providedIn: 'root' });
530
518
  }
531
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthMonitoringService, decorators: [{
519
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AuthGuard, decorators: [{
532
520
  type: Injectable,
533
521
  args: [{
534
522
  providedIn: 'root'
535
523
  }]
536
- }], ctorParameters: () => [{ type: i2.ConfigService }, { type: undefined, decorators: [{
537
- type: Optional
538
- }, {
539
- type: Inject,
540
- args: [MONITORING_OPTIONS]
541
- }] }, { type: i0.Injector }] });
524
+ }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
542
525
 
543
- function provideAuthUserMonitoring(options) {
544
- if (!options) {
545
- return [];
526
+ class AdminGuard {
527
+ authService;
528
+ config;
529
+ router;
530
+ constructor(authService, config, router) {
531
+ this.authService = authService;
532
+ this.config = config;
533
+ this.router = router;
534
+ }
535
+ canActivate(route, state) {
536
+ if (this.authService.isAdmin) {
537
+ return true;
538
+ }
539
+ this.authService.redirectUrl = state.url;
540
+ const authConfig = this.config.getConfig('auth');
541
+ if (authConfig?.loginRoute) {
542
+ this.router.navigateByUrl(authConfig.loginRoute);
543
+ }
544
+ return false;
545
+ }
546
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AdminGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
547
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AdminGuard, providedIn: 'root' });
548
+ }
549
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: AdminGuard, decorators: [{
550
+ type: Injectable,
551
+ args: [{
552
+ providedIn: 'root'
553
+ }]
554
+ }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
555
+
556
+ class ProfilsGuard {
557
+ authService;
558
+ config;
559
+ router;
560
+ constructor(authService, config, router) {
561
+ this.authService = authService;
562
+ this.config = config;
563
+ this.router = router;
564
+ }
565
+ canActivate(_route, state) {
566
+ return this.authService.getProfils().pipe(map((profils) => {
567
+ const authConfig = this.config.getConfig('auth');
568
+ if (profils &&
569
+ profils.profils &&
570
+ profils.profils.some((v) => authConfig.profilsGuard.indexOf(v) !== -1)) {
571
+ return true;
572
+ }
573
+ this.authService.redirectUrl = state.url;
574
+ if (authConfig?.loginRoute) {
575
+ this.router.navigateByUrl(authConfig.loginRoute);
576
+ }
577
+ return false;
578
+ }));
546
579
  }
547
- return [
580
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: ProfilsGuard, deps: [{ token: AuthService }, { token: i2.ConfigService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable });
581
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: ProfilsGuard, providedIn: 'root' });
582
+ }
583
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.4", ngImport: i0, type: ProfilsGuard, decorators: [{
584
+ type: Injectable,
585
+ args: [{
586
+ providedIn: 'root'
587
+ }]
588
+ }], ctorParameters: () => [{ type: AuthService }, { type: i2.ConfigService }, { type: i3.Router }] });
589
+
590
+ function provideAuthentification(...features) {
591
+ const providers = [
548
592
  {
549
- provide: AuthMonitoringService,
550
- useClass: AuthMonitoringService,
551
- deps: [ConfigService, MONITORING_OPTIONS, Injector]
593
+ provide: HTTP_INTERCEPTORS,
594
+ useClass: AuthInterceptor,
595
+ multi: true
552
596
  },
553
- // Force instantiate Tracing service to avoid require it in any constructor.
554
597
  {
555
- provide: APP_INITIALIZER,
556
- useFactory: () => () => { },
557
- deps: [AuthMonitoringService],
558
- multi: true
598
+ provide: StorageService,
599
+ useClass: AuthStorageService
559
600
  }
560
601
  ];
602
+ for (const feature of features) {
603
+ providers.push(...feature.providers);
604
+ }
605
+ return makeEnvironmentProviders(providers);
561
606
  }
562
607
 
563
608
  /*
@@ -568,5 +613,5 @@ function provideAuthUserMonitoring(options) {
568
613
  * Generated bundle index. Do not edit.
569
614
  */
570
615
 
571
- export { AdminGuard, AuthGuard, AuthInterceptor, AuthMonitoringService, AuthService, LoggedGuard, ProfilsGuard, TokenService, provideAuthUserMonitoring };
616
+ export { AdminGuard, AuthFeatureKind, AuthGuard, AuthInterceptor, AuthService, AuthStorageService, LoggedGuard, ProfilsGuard, TokenService, provideAuthentification };
572
617
  //# sourceMappingURL=igo2-auth.mjs.map