@igo2/core 17.0.0 → 17.0.1-next.2

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 (92) hide show
  1. package/activity/activity.service.d.ts +0 -1
  2. package/config/config-deprecated.d.ts +1 -3
  3. package/config/config.interface.d.ts +1 -3
  4. package/config/config.provider.d.ts +1 -3
  5. package/config/config.service.d.ts +1 -3
  6. package/esm2022/activity/activity.interceptor.mjs +3 -3
  7. package/esm2022/activity/activity.module.mjs +4 -4
  8. package/esm2022/activity/activity.service.mjs +5 -6
  9. package/esm2022/analytics/analytics.service.mjs +3 -3
  10. package/esm2022/config/config-deprecated.mjs +1 -1
  11. package/esm2022/config/config.interface.mjs +1 -1
  12. package/esm2022/config/config.module.mjs +4 -4
  13. package/esm2022/config/config.provider.mjs +2 -2
  14. package/esm2022/config/config.service.mjs +5 -5
  15. package/esm2022/config/version.mjs +3 -3
  16. package/esm2022/gesture/gesture.module.mjs +4 -4
  17. package/esm2022/gesture/gesture.provider.mjs +3 -3
  18. package/esm2022/language/language.module.mjs +4 -4
  19. package/esm2022/language/shared/language-mock.provider.mjs +2 -2
  20. package/esm2022/language/shared/language.loader.mjs +1 -1
  21. package/esm2022/language/shared/language.service.mjs +4 -4
  22. package/esm2022/lib/core.module.mjs +10 -14
  23. package/esm2022/media/media.service.mjs +3 -3
  24. package/esm2022/message/message.module.mjs +4 -4
  25. package/esm2022/message/shared/message.enum.mjs +2 -1
  26. package/esm2022/message/shared/message.interface.mjs +1 -1
  27. package/esm2022/message/shared/message.service.mjs +5 -5
  28. package/esm2022/monitoring/sentry/sentry.provider.mjs +2 -2
  29. package/esm2022/network/network.service.mjs +7 -5
  30. package/esm2022/regex/regex.interface.mjs +1 -1
  31. package/esm2022/regex/regex.service.mjs +3 -3
  32. package/esm2022/request/error.interceptor.mjs +3 -3
  33. package/esm2022/request/error.module.mjs +4 -4
  34. package/esm2022/request/logging.interceptor.mjs +5 -5
  35. package/esm2022/request/logging.module.mjs +4 -4
  36. package/esm2022/route/route.service.mjs +5 -5
  37. package/esm2022/storage/storage.mjs +3 -3
  38. package/esm2022/storage/storage.service.mjs +3 -3
  39. package/fesm2022/igo2-core-activity.mjs +11 -12
  40. package/fesm2022/igo2-core-activity.mjs.map +1 -1
  41. package/fesm2022/igo2-core-analytics.mjs +3 -3
  42. package/fesm2022/igo2-core-config.mjs +11 -11
  43. package/fesm2022/igo2-core-config.mjs.map +1 -1
  44. package/fesm2022/igo2-core-gesture.mjs +7 -7
  45. package/fesm2022/igo2-core-language.mjs +8 -8
  46. package/fesm2022/igo2-core-language.mjs.map +1 -1
  47. package/fesm2022/igo2-core-media.mjs +3 -3
  48. package/fesm2022/igo2-core-message.mjs +9 -8
  49. package/fesm2022/igo2-core-message.mjs.map +1 -1
  50. package/fesm2022/igo2-core-monitoring.mjs +1 -1
  51. package/fesm2022/igo2-core-monitoring.mjs.map +1 -1
  52. package/fesm2022/igo2-core-network.mjs +6 -4
  53. package/fesm2022/igo2-core-network.mjs.map +1 -1
  54. package/fesm2022/igo2-core-regex.mjs +3 -3
  55. package/fesm2022/igo2-core-request.mjs +15 -15
  56. package/fesm2022/igo2-core-request.mjs.map +1 -1
  57. package/fesm2022/igo2-core-route.mjs +4 -4
  58. package/fesm2022/igo2-core-route.mjs.map +1 -1
  59. package/fesm2022/igo2-core-storage.mjs +5 -5
  60. package/fesm2022/igo2-core-storage.mjs.map +1 -1
  61. package/fesm2022/igo2-core.mjs +9 -13
  62. package/fesm2022/igo2-core.mjs.map +1 -1
  63. package/language/shared/language-mock.provider.d.ts +2 -2
  64. package/lib/core.module.d.ts +5 -7
  65. package/message/shared/message.interface.d.ts +2 -2
  66. package/message/shared/message.service.d.ts +5 -5
  67. package/message/src/message.theming.scss +3 -3
  68. package/package.json +10 -10
  69. package/regex/regex.interface.d.ts +1 -3
  70. package/route/route.service.d.ts +1 -1
  71. package/src/theming/material-theme-override.scss +4 -4
  72. package/src/theming/prebuilt-themes/blue-theme.scss +4 -4
  73. package/src/theming/prebuilt-themes/bluedark-theme.scss +4 -4
  74. package/src/theming/prebuilt-themes/bluedq-theme.scss +4 -4
  75. package/src/theming/prebuilt-themes/bluegrey-theme.scss +4 -4
  76. package/src/theming/prebuilt-themes/dark-theme.scss +4 -4
  77. package/src/theming/prebuilt-themes/deeppurple-theme.scss +4 -4
  78. package/src/theming/prebuilt-themes/indigo-theme.scss +4 -4
  79. package/src/theming/prebuilt-themes/orange-theme.scss +4 -4
  80. package/src/theming/prebuilt-themes/teal-theme.scss +4 -4
  81. package/src/theming/typography.scss +13 -13
  82. package/src/theming/utils/_foreground.scss +1 -1
  83. package/theming/prebuilt-themes/blue-theme.css +209 -197
  84. package/theming/prebuilt-themes/bluedark-theme.css +209 -197
  85. package/theming/prebuilt-themes/bluedq-theme.css +209 -197
  86. package/theming/prebuilt-themes/bluegrey-theme.css +209 -197
  87. package/theming/prebuilt-themes/dark-theme.css +209 -197
  88. package/theming/prebuilt-themes/deeppurple-theme.css +209 -197
  89. package/theming/prebuilt-themes/indigo-theme.css +209 -197
  90. package/theming/prebuilt-themes/orange-theme.css +209 -197
  91. package/theming/prebuilt-themes/teal-theme.css +209 -197
  92. package/assets/icons/mdi.svg +0 -1
@@ -60,10 +60,10 @@ class ErrorInterceptor {
60
60
  progressBar: false
61
61
  });
62
62
  }
63
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: ErrorInterceptor, deps: [{ token: i1.MessageService }], target: i0.ɵɵFactoryTarget.Injectable });
64
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: ErrorInterceptor, providedIn: 'root' });
63
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ErrorInterceptor, deps: [{ token: i1.MessageService }], target: i0.ɵɵFactoryTarget.Injectable });
64
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ErrorInterceptor, providedIn: 'root' });
65
65
  }
66
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: ErrorInterceptor, decorators: [{
66
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: ErrorInterceptor, decorators: [{
67
67
  type: Injectable,
68
68
  args: [{
69
69
  providedIn: 'root'
@@ -88,11 +88,11 @@ class IgoErrorModule {
88
88
  throw new Error('IgoErrorModule is already loaded. Import it in the AppModule only');
89
89
  }
90
90
  }
91
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoErrorModule, deps: [{ token: IgoErrorModule, optional: true, skipSelf: true }], target: i0.ɵɵFactoryTarget.NgModule });
92
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.9", ngImport: i0, type: IgoErrorModule });
93
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoErrorModule });
91
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoErrorModule, deps: [{ token: IgoErrorModule, optional: true, skipSelf: true }], target: i0.ɵɵFactoryTarget.NgModule });
92
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.2", ngImport: i0, type: IgoErrorModule });
93
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoErrorModule });
94
94
  }
95
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoErrorModule, decorators: [{
95
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoErrorModule, decorators: [{
96
96
  type: NgModule,
97
97
  args: [{
98
98
  imports: [],
@@ -114,7 +114,7 @@ class LoggingInterceptor {
114
114
  // Succeeds when there is a response; ignore other events
115
115
  (event) => (ok = event instanceof HttpResponse ? 'succeeded' : ''),
116
116
  // Operation failed; error is an HttpErrorResponse
117
- (error) => (ok = 'failed')),
117
+ () => (ok = 'failed')),
118
118
  // Log when response observable either completes or errors
119
119
  finalize(() => {
120
120
  const elapsed = Date.now() - started;
@@ -123,10 +123,10 @@ class LoggingInterceptor {
123
123
  console.log(msg);
124
124
  }));
125
125
  }
126
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: LoggingInterceptor, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
127
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: LoggingInterceptor });
126
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: LoggingInterceptor, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
127
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: LoggingInterceptor });
128
128
  }
129
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: LoggingInterceptor, decorators: [{
129
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: LoggingInterceptor, decorators: [{
130
130
  type: Injectable
131
131
  }] });
132
132
 
@@ -143,11 +143,11 @@ class IgoLoggingModule {
143
143
  ]
144
144
  };
145
145
  }
146
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoLoggingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
147
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.9", ngImport: i0, type: IgoLoggingModule });
148
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoLoggingModule });
146
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoLoggingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
147
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.2", ngImport: i0, type: IgoLoggingModule });
148
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoLoggingModule });
149
149
  }
150
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoLoggingModule, decorators: [{
150
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoLoggingModule, decorators: [{
151
151
  type: NgModule,
152
152
  args: [{
153
153
  imports: [],
@@ -1 +1 @@
1
- {"version":3,"file":"igo2-core-request.mjs","sources":["../../../packages/core/request/src/error.interceptor.ts","../../../packages/core/request/src/error.module.ts","../../../packages/core/request/src/logging.interceptor.ts","../../../packages/core/request/src/logging.module.ts","../../../packages/core/request/src/igo2-core-request.ts"],"sourcesContent":["import {\n HttpErrorResponse,\n HttpEvent,\n HttpHandler,\n HttpInterceptor,\n HttpRequest\n} from '@angular/common/http';\nimport { Injectable } from '@angular/core';\n\nimport { MessageService } from '@igo2/core/message';\n\nimport { Observable, throwError } from 'rxjs';\nimport { catchError, finalize } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ErrorInterceptor implements HttpInterceptor {\n constructor(private messageService: MessageService) {}\n\n intercept(\n originalReq: HttpRequest<any>,\n next: HttpHandler\n ): Observable<HttpEvent<any>> {\n const interceptError = originalReq.headers.get('interceptError');\n const req = originalReq.clone({\n headers: originalReq.headers.delete('interceptError')\n });\n if (interceptError === 'false') {\n return next.handle(req);\n }\n const errorContainer = { httpError: undefined };\n return next.handle(req).pipe(\n catchError((error) => this.handleError(error, errorContainer)),\n finalize(() => {\n const httpError = errorContainer.httpError;\n if (!httpError) {\n return;\n }\n\n if (httpError.error.toDisplay) {\n this.handleCaughtError(httpError);\n } else if (!httpError.error.caught) {\n this.handleUncaughtError(httpError);\n }\n })\n );\n }\n\n private handleError(\n httpError: HttpErrorResponse,\n errorContainer: { httpError: HttpErrorResponse }\n ) {\n if (httpError instanceof HttpErrorResponse) {\n const errorObj = httpError.error === 'object' ? httpError.error : {};\n errorObj.message = httpError.error?.message || httpError.statusText;\n errorObj.caught = false;\n\n httpError = new HttpErrorResponse({\n error: errorObj,\n headers: httpError.headers,\n status: httpError.status,\n statusText: httpError.statusText,\n url: httpError.url\n });\n }\n\n errorContainer.httpError = httpError;\n return throwError(httpError);\n }\n\n private handleCaughtError(httpError: HttpErrorResponse) {\n httpError.error.caught = true;\n this.messageService.error(httpError.error.message, httpError.error.title, {\n progressBar: false\n });\n }\n\n private handleUncaughtError(httpError: HttpErrorResponse) {\n httpError.error.caught = true;\n this.messageService.error(\n 'igo.core.errors.uncaught.message',\n 'igo.core.errors.uncaught.title',\n {\n progressBar: false\n }\n );\n }\n}\n","import { HTTP_INTERCEPTORS } from '@angular/common/http';\nimport {\n ModuleWithProviders,\n NgModule,\n Optional,\n SkipSelf\n} from '@angular/core';\n\nimport { ErrorInterceptor } from './error.interceptor';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoErrorModule {\n static forRoot(): ModuleWithProviders<IgoErrorModule> {\n return {\n ngModule: IgoErrorModule,\n providers: [\n {\n provide: HTTP_INTERCEPTORS,\n useClass: ErrorInterceptor,\n multi: true\n }\n ]\n };\n }\n\n constructor(@Optional() @SkipSelf() parentModule: IgoErrorModule) {\n if (parentModule) {\n throw new Error(\n 'IgoErrorModule is already loaded. Import it in the AppModule only'\n );\n }\n }\n}\n","import {\n HttpEvent,\n HttpHandler,\n HttpInterceptor,\n HttpRequest,\n HttpResponse\n} from '@angular/common/http';\nimport { Injectable } from '@angular/core';\n\nimport { Observable } from 'rxjs';\nimport { finalize, tap } from 'rxjs/operators';\n\n@Injectable()\nexport class LoggingInterceptor implements HttpInterceptor {\n intercept(\n req: HttpRequest<any>,\n next: HttpHandler\n ): Observable<HttpEvent<any>> {\n const started = Date.now();\n let ok: string;\n\n // extend server response observable with logging\n return next.handle(req).pipe(\n tap(\n // Succeeds when there is a response; ignore other events\n (event) => (ok = event instanceof HttpResponse ? 'succeeded' : ''),\n // Operation failed; error is an HttpErrorResponse\n (error) => (ok = 'failed')\n ),\n // Log when response observable either completes or errors\n finalize(() => {\n const elapsed = Date.now() - started;\n const msg = `${req.method} \"${req.urlWithParams}\"\n ${ok} in ${elapsed} ms.`;\n\n console.log(msg);\n })\n );\n }\n}\n","import { HTTP_INTERCEPTORS } from '@angular/common/http';\nimport { ModuleWithProviders, NgModule } from '@angular/core';\n\nimport { LoggingInterceptor } from './logging.interceptor';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoLoggingModule {\n static forRoot(): ModuleWithProviders<IgoLoggingModule> {\n return {\n ngModule: IgoLoggingModule,\n providers: [\n {\n provide: HTTP_INTERCEPTORS,\n useClass: LoggingInterceptor,\n multi: true\n }\n ]\n };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;MAiBa,gBAAgB,CAAA;AACP,IAAA,cAAA,CAAA;AAApB,IAAA,WAAA,CAAoB,cAA8B,EAAA;QAA9B,IAAc,CAAA,cAAA,GAAd,cAAc,CAAgB;KAAI;IAEtD,SAAS,CACP,WAA6B,EAC7B,IAAiB,EAAA;QAEjB,MAAM,cAAc,GAAG,WAAW,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;AACjE,QAAA,MAAM,GAAG,GAAG,WAAW,CAAC,KAAK,CAAC;YAC5B,OAAO,EAAE,WAAW,CAAC,OAAO,CAAC,MAAM,CAAC,gBAAgB,CAAC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ources":["../../../packages/core/request/src/error.interceptor.ts","../../../packages/core/request/src/error.module.ts","../../../packages/core/request/src/logging.interceptor.ts","../../../packages/core/request/src/logging.module.ts","../../../packages/core/request/src/igo2-core-request.ts"],"sourcesContent":["import {\n HttpErrorResponse,\n HttpEvent,\n HttpHandler,\n HttpInterceptor,\n HttpRequest\n} from '@angular/common/http';\nimport { Injectable } from '@angular/core';\n\nimport { MessageService } from '@igo2/core/message';\n\nimport { Observable, throwError } from 'rxjs';\nimport { catchError, finalize } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class ErrorInterceptor implements HttpInterceptor {\n constructor(private messageService: MessageService) {}\n\n intercept(\n originalReq: HttpRequest<any>,\n next: HttpHandler\n ): Observable<HttpEvent<any>> {\n const interceptError = originalReq.headers.get('interceptError');\n const req = originalReq.clone({\n headers: originalReq.headers.delete('interceptError')\n });\n if (interceptError === 'false') {\n return next.handle(req);\n }\n const errorContainer = { httpError: undefined };\n return next.handle(req).pipe(\n catchError((error) => this.handleError(error, errorContainer)),\n finalize(() => {\n const httpError = errorContainer.httpError;\n if (!httpError) {\n return;\n }\n\n if (httpError.error.toDisplay) {\n this.handleCaughtError(httpError);\n } else if (!httpError.error.caught) {\n this.handleUncaughtError(httpError);\n }\n })\n );\n }\n\n private handleError(\n httpError: HttpErrorResponse,\n errorContainer: { httpError: HttpErrorResponse }\n ) {\n if (httpError instanceof HttpErrorResponse) {\n const errorObj = httpError.error === 'object' ? httpError.error : {};\n errorObj.message = httpError.error?.message || httpError.statusText;\n errorObj.caught = false;\n\n httpError = new HttpErrorResponse({\n error: errorObj,\n headers: httpError.headers,\n status: httpError.status,\n statusText: httpError.statusText,\n url: httpError.url\n });\n }\n\n errorContainer.httpError = httpError;\n return throwError(httpError);\n }\n\n private handleCaughtError(httpError: HttpErrorResponse) {\n httpError.error.caught = true;\n this.messageService.error(httpError.error.message, httpError.error.title, {\n progressBar: false\n });\n }\n\n private handleUncaughtError(httpError: HttpErrorResponse) {\n httpError.error.caught = true;\n this.messageService.error(\n 'igo.core.errors.uncaught.message',\n 'igo.core.errors.uncaught.title',\n {\n progressBar: false\n }\n );\n }\n}\n","import { HTTP_INTERCEPTORS } from '@angular/common/http';\nimport {\n ModuleWithProviders,\n NgModule,\n Optional,\n SkipSelf\n} from '@angular/core';\n\nimport { ErrorInterceptor } from './error.interceptor';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoErrorModule {\n static forRoot(): ModuleWithProviders<IgoErrorModule> {\n return {\n ngModule: IgoErrorModule,\n providers: [\n {\n provide: HTTP_INTERCEPTORS,\n useClass: ErrorInterceptor,\n multi: true\n }\n ]\n };\n }\n\n constructor(@Optional() @SkipSelf() parentModule: IgoErrorModule) {\n if (parentModule) {\n throw new Error(\n 'IgoErrorModule is already loaded. Import it in the AppModule only'\n );\n }\n }\n}\n","import {\n HttpEvent,\n HttpHandler,\n HttpInterceptor,\n HttpRequest,\n HttpResponse\n} from '@angular/common/http';\nimport { Injectable } from '@angular/core';\n\nimport { Observable } from 'rxjs';\nimport { finalize, tap } from 'rxjs/operators';\n\n@Injectable()\nexport class LoggingInterceptor implements HttpInterceptor {\n intercept(\n req: HttpRequest<any>,\n next: HttpHandler\n ): Observable<HttpEvent<any>> {\n const started = Date.now();\n let ok: string;\n\n // extend server response observable with logging\n return next.handle(req).pipe(\n tap(\n // Succeeds when there is a response; ignore other events\n (event) => (ok = event instanceof HttpResponse ? 'succeeded' : ''),\n // Operation failed; error is an HttpErrorResponse\n () => (ok = 'failed')\n ),\n // Log when response observable either completes or errors\n finalize(() => {\n const elapsed = Date.now() - started;\n const msg = `${req.method} \"${req.urlWithParams}\"\n ${ok} in ${elapsed} ms.`;\n\n console.log(msg);\n })\n );\n }\n}\n","import { HTTP_INTERCEPTORS } from '@angular/common/http';\nimport { ModuleWithProviders, NgModule } from '@angular/core';\n\nimport { LoggingInterceptor } from './logging.interceptor';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoLoggingModule {\n static forRoot(): ModuleWithProviders<IgoLoggingModule> {\n return {\n ngModule: IgoLoggingModule,\n providers: [\n {\n provide: HTTP_INTERCEPTORS,\n useClass: LoggingInterceptor,\n multi: true\n }\n ]\n };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;MAiBa,gBAAgB,CAAA;AACP,IAAA,cAAA,CAAA;AAApB,IAAA,WAAA,CAAoB,cAA8B,EAAA;QAA9B,IAAc,CAAA,cAAA,GAAd,cAAc,CAAgB;KAAI;IAEtD,SAAS,CACP,WAA6B,EAC7B,IAAiB,EAAA;QAEjB,MAAM,cAAc,GAAG,WAAW,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;AACjE,QAAA,MAAM,GAAG,GAAG,WAAW,CAAC,KAAK,CAAC;YAC5B,OAAO,EAAE,WAAW,CAAC,OAAO,CAAC,MAAM,CAAC,gBAAgB,CAAC;AACtD,SAAA,CAAC,CAAC;AACH,QAAA,IAAI,cAAc,KAAK,OAAO,EAAE;AAC9B,YAAA,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;SACzB;AACD,QAAA,MAAM,cAAc,GAAG,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC;AAChD,QAAA,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,CAC1B,UAAU,CAAC,CAAC,KAAK,KAAK,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,cAAc,CAAC,CAAC,EAC9D,QAAQ,CAAC,MAAK;AACZ,YAAA,MAAM,SAAS,GAAG,cAAc,CAAC,SAAS,CAAC;YAC3C,IAAI,CAAC,SAAS,EAAE;gBACd,OAAO;aACR;AAED,YAAA,IAAI,SAAS,CAAC,KAAK,CAAC,SAAS,EAAE;AAC7B,gBAAA,IAAI,CAAC,iBAAiB,CAAC,SAAS,CAAC,CAAC;aACnC;AAAM,iBAAA,IAA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C1B,YAAA,SAAS,EAAE;AACT,gBAAA;AACE,oBAAA,OAAO,EAAE,iBAAiB;AAC1B,oBAAA,QAAQ,EAAE,kBAAkB;AAC5B,oBAAA,KAAK,EAAE,IAAI;AACZ,iBAAA;AACF,aAAA;SACF,CAAC;KACH;uGAZU,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;wGAAhB,gBAAgB,EAAA,CAAA,CAAA;wGAAhB,gBAAgB,EAAA,CAAA,CAAA;;2FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAL5B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,EAAE;AACX,oBAAA,YAAY,EAAE,EAAE;AAChB,oBAAA,OAAO,EAAE,EAAE;AACZ,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
@@ -2,7 +2,7 @@ import * as i0 from '@angular/core';
2
2
  import { InjectionToken, Injectable, Inject, Optional } from '@angular/core';
3
3
  import * as i1 from '@angular/router';
4
4
 
5
- let ROUTE_SERVICE_OPTIONS = new InjectionToken('routeServiceOptions');
5
+ const ROUTE_SERVICE_OPTIONS = new InjectionToken('routeServiceOptions');
6
6
  function provideRouteServiceOptions(options) {
7
7
  return {
8
8
  provide: ROUTE_SERVICE_OPTIONS,
@@ -58,10 +58,10 @@ class RouteService {
58
58
  }
59
59
  return this.route.queryParams;
60
60
  }
61
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: RouteService, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: ROUTE_SERVICE_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
62
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: RouteService, providedIn: 'root' });
61
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: RouteService, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: ROUTE_SERVICE_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
62
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: RouteService, providedIn: 'root' });
63
63
  }
64
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: RouteService, decorators: [{
64
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: RouteService, decorators: [{
65
65
  type: Injectable,
66
66
  args: [{
67
67
  providedIn: 'root'
@@ -1 +1 @@
1
- {"version":3,"file":"igo2-core-route.mjs","sources":["../../../packages/core/route/src/route.service.ts","../../../packages/core/route/src/igo2-core-route.ts"],"sourcesContent":["import { Inject, Injectable, InjectionToken, Optional } from '@angular/core';\nimport { ActivatedRoute, Params, Router } from '@angular/router';\n\nimport { Observable } from 'rxjs';\n\nimport { RouteServiceOptions } from './route.interface';\n\nexport let ROUTE_SERVICE_OPTIONS = new InjectionToken<RouteServiceOptions>(\n 'routeServiceOptions'\n);\n\nexport function provideRouteServiceOptions(options: RouteServiceOptions) {\n return {\n provide: ROUTE_SERVICE_OPTIONS,\n useValue: options\n };\n}\n\n@Injectable({\n providedIn: 'root'\n})\nexport class RouteService {\n public options: RouteServiceOptions;\n\n constructor(\n private router: Router,\n public route: ActivatedRoute,\n @Inject(ROUTE_SERVICE_OPTIONS)\n @Optional()\n options: RouteServiceOptions\n ) {\n const defaultOptions = {\n centerKey: 'center',\n zoomKey: 'zoom',\n projectionKey: 'projection',\n contextKey: 'context',\n searchKey: 'search',\n visibleOnLayersKey: 'visiblelayers',\n visibleOffLayersKey: 'invisiblelayers',\n directionsCoordKey: 'routing',\n directionsOptionsKey: 'routingOptions',\n toolKey: 'tool',\n wmsUrlKey: 'wmsUrl',\n wmsLayersKey: 'wmsLayers',\n wmtsUrlKey: 'wmtsUrl',\n wmtsLayersKey: 'wmtsLayers',\n arcgisUrlKey: 'arcgisUrl',\n arcgisLayersKey: 'arcgisLayers',\n iarcgisUrlKey: 'iarcgisUrl',\n iarcgisLayersKey: 'iarcgisLayers',\n tarcgisUrlKey: 'tarcgisUrl',\n tarcgisLayersKey: 'tarcgisLayers',\n vectorKey: 'vector'\n };\n this.options = Object.assign({}, defaultOptions, options);\n }\n\n get queryParams(): Observable<Params> {\n let url = decodeURIComponent(location.search);\n if (url.includes('¢er=')) {\n url = url.replace('¢er', '&center');\n const queryParams: any = url\n .slice(1)\n .split('&')\n .map((p) => p.split('='))\n .reduce((obj, pair) => {\n const [key, value] = pair.map(decodeURIComponent);\n obj[key] = value;\n return obj;\n }, {});\n this.router.navigate([], { queryParams });\n }\n return this.route.queryParams;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;IAOW,qBAAqB,GAAG,IAAI,cAAc,CACnD,qBAAqB,EACrB;AAEI,SAAU,0BAA0B,CAAC,OAA4B,EAAA;IACrE,OAAO;AACL,QAAA,OAAO,EAAE,qBAAqB;AAC9B,QAAA,QAAQ,EAAE,OAAO;KAClB,CAAC;AACJ,CAAC;MAKY,YAAY,CAAA;AAIb,IAAA,MAAA,CAAA;AACD,IAAA,KAAA,CAAA;AAJF,IAAA,OAAO,CAAsB;AAEpC,IAAA,WAAA,CACU,MAAc,EACf,KAAqB,EAG5B,OAA4B,EAAA;QAJpB,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACf,IAAK,CAAA,KAAA,GAAL,KAAK,CAAgB;AAK5B,QAAA,MAAM,cAAc,GAAG;AACrB,YAAA,SAAS,EAAE,QAAQ;AACnB,YAAA,OAAO,EAAE,MAAM;AACf,YAAA,aAAa,EAAE,YAAY;AAC3B,YAAA,UAAU,EAAE,SAAS;AACrB,YAAA,SAAS,EAAE,QAAQ;AACnB,YAAA,kBAAkB,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,gBAAA,OAAO,GAAG,CAAC;aACZ,EAAE,EAAE,CAAC,CAAC;YACT,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,WAAW,EAAE,CAAC,CAAC;SAC3C;AACD,QAAA,OAAO,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC;KAC/B;AApDU,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,YAAY,sEAMb,qBAAqB,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AANpB,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,YAAY,cAFX,MAAM,EAAA,CAAA,CAAA;;2FAEP,YAAY,EAAA,UAAA,EAAA,CAAA;kBAHxB,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;0BAOI,MAAM;2BAAC,qBAAqB,CAAA;;0BAC5B,QAAQ;;;AC5Bb;;AAEG;;;;"}
1
+ {"version":3,"file":"igo2-core-route.mjs","sources":["../../../packages/core/route/src/route.service.ts","../../../packages/core/route/src/igo2-core-route.ts"],"sourcesContent":["import { Inject, Injectable, InjectionToken, Optional } from '@angular/core';\nimport { ActivatedRoute, Params, Router } from '@angular/router';\n\nimport { Observable } from 'rxjs';\n\nimport { RouteServiceOptions } from './route.interface';\n\nexport const ROUTE_SERVICE_OPTIONS = new InjectionToken<RouteServiceOptions>(\n 'routeServiceOptions'\n);\n\nexport function provideRouteServiceOptions(options: RouteServiceOptions) {\n return {\n provide: ROUTE_SERVICE_OPTIONS,\n useValue: options\n };\n}\n\n@Injectable({\n providedIn: 'root'\n})\nexport class RouteService {\n public options: RouteServiceOptions;\n\n constructor(\n private router: Router,\n public route: ActivatedRoute,\n @Inject(ROUTE_SERVICE_OPTIONS)\n @Optional()\n options: RouteServiceOptions\n ) {\n const defaultOptions = {\n centerKey: 'center',\n zoomKey: 'zoom',\n projectionKey: 'projection',\n contextKey: 'context',\n searchKey: 'search',\n visibleOnLayersKey: 'visiblelayers',\n visibleOffLayersKey: 'invisiblelayers',\n directionsCoordKey: 'routing',\n directionsOptionsKey: 'routingOptions',\n toolKey: 'tool',\n wmsUrlKey: 'wmsUrl',\n wmsLayersKey: 'wmsLayers',\n wmtsUrlKey: 'wmtsUrl',\n wmtsLayersKey: 'wmtsLayers',\n arcgisUrlKey: 'arcgisUrl',\n arcgisLayersKey: 'arcgisLayers',\n iarcgisUrlKey: 'iarcgisUrl',\n iarcgisLayersKey: 'iarcgisLayers',\n tarcgisUrlKey: 'tarcgisUrl',\n tarcgisLayersKey: 'tarcgisLayers',\n vectorKey: 'vector'\n };\n this.options = Object.assign({}, defaultOptions, options);\n }\n\n get queryParams(): Observable<Params> {\n let url = decodeURIComponent(location.search);\n if (url.includes('¢er=')) {\n url = url.replace('¢er', '&center');\n const queryParams: any = url\n .slice(1)\n .split('&')\n .map((p) => p.split('='))\n .reduce((obj, pair) => {\n const [key, value] = pair.map(decodeURIComponent);\n obj[key] = value;\n return obj;\n }, {});\n this.router.navigate([], { queryParams });\n }\n return this.route.queryParams;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;MAOa,qBAAqB,GAAG,IAAI,cAAc,CACrD,qBAAqB,EACrB;AAEI,SAAU,0BAA0B,CAAC,OAA4B,EAAA;IACrE,OAAO;AACL,QAAA,OAAO,EAAE,qBAAqB;AAC9B,QAAA,QAAQ,EAAE,OAAO;KAClB,CAAC;AACJ,CAAC;MAKY,YAAY,CAAA;AAIb,IAAA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AqB,CAAA;;0BAC5B,QAAQ;;;AC5Bb;;AAEG;;;;"}
@@ -35,10 +35,10 @@ class BaseStorage {
35
35
  }
36
36
  if (value) {
37
37
  try {
38
- value = JSON.parse(value);
38
+ return JSON.parse(value);
39
39
  }
40
40
  catch {
41
- value = value;
41
+ return value;
42
42
  }
43
43
  }
44
44
  return value;
@@ -96,10 +96,10 @@ class StorageService extends BaseStorage {
96
96
  super(config);
97
97
  this.config = config;
98
98
  }
99
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: StorageService, deps: [{ token: i1.ConfigService }], target: i0.ɵɵFactoryTarget.Injectable });
100
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: StorageService, providedIn: 'root' });
99
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: StorageService, deps: [{ token: i1.ConfigService }], target: i0.ɵɵFactoryTarget.Injectable });
100
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: StorageService, providedIn: 'root' });
101
101
  }
102
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: StorageService, decorators: [{
102
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: StorageService, decorators: [{
103
103
  type: Injectable,
104
104
  args: [{
105
105
  providedIn: 'root'
@@ -1 +1 @@
1
- {"version":3,"file":"igo2-core-storage.mjs","sources":["../../../packages/core/storage/src/storage.interface.ts","../../../packages/core/storage/src/storage.ts","../../../packages/core/storage/src/storage.service.ts","../../../packages/core/storage/src/igo2-core-storage.ts"],"sourcesContent":["export enum StorageScope {\n SESSION = 'Session',\n LOCAL = 'Local'\n}\n\nexport interface StorageOptions {\n key: string;\n}\n\nexport interface StorageServiceEvent {\n key?: string;\n scope: StorageScope;\n event: StorageServiceEventEnum;\n previousValue?: any;\n currentValue?: any;\n}\n\nexport enum StorageServiceEventEnum {\n ADDED = 'Added',\n MODIFIED = 'Modified',\n REMOVED = 'Removed',\n CLEARED = 'Cleared'\n}\n","import { ConfigService } from '@igo2/core/config';\n\nimport { BehaviorSubject } from 'rxjs';\n\nimport {\n StorageOptions,\n StorageScope,\n StorageServiceEvent,\n StorageServiceEventEnum\n} from './storage.interface';\n\nexport abstract class BaseStorage<T extends StorageOptions = StorageOptions> {\n protected options?: T;\n\n public storageChange$: BehaviorSubject<StorageServiceEvent> =\n new BehaviorSubject(undefined);\n\n constructor(config: ConfigService) {\n this.options = config.getConfig<T>('storage') || ({ key: 'igo' } as T);\n }\n\n /**\n * Use to get the data found in storage file\n */\n get(key: string, scope?: StorageScope): string | object | boolean | number {\n let value: any;\n\n if (!scope || scope === StorageScope.SESSION) {\n value = sessionStorage.getItem(`${this.options.key}.${key}`);\n }\n\n if (scope === StorageScope.LOCAL || (!value && !scope)) {\n value = localStorage.getItem(`${this.options.key}.${key}`);\n }\n\n if (value) {\n try {\n value = JSON.parse(value);\n } catch {\n value = value;\n }\n }\n\n return value;\n }\n\n set(\n key: string,\n value: string | object | boolean | number,\n scope: StorageScope = StorageScope.LOCAL\n ) {\n const previousValue = this.get(key, scope);\n if (scope === StorageScope.SESSION) {\n sessionStorage.setItem(\n `${this.options.key}.${key}`,\n JSON.stringify(value)\n );\n } else {\n localStorage.setItem(`${this.options.key}.${key}`, JSON.stringify(value));\n }\n const currentValue = this.get(key, scope);\n\n if (currentValue !== previousValue) {\n this.storageChange$.next({\n key,\n scope,\n event:\n previousValue !== undefined\n ? StorageServiceEventEnum.MODIFIED\n : StorageServiceEventEnum.ADDED,\n previousValue,\n currentValue\n });\n }\n }\n\n remove(key: string, scope: StorageScope = StorageScope.LOCAL) {\n const previousValue = this.get(key, scope);\n if (scope === StorageScope.SESSION) {\n sessionStorage.removeItem(`${this.options.key}.${key}`);\n } else {\n localStorage.removeItem(`${this.options.key}.${key}`);\n }\n this.storageChange$.next({\n key,\n scope,\n event: StorageServiceEventEnum.REMOVED,\n previousValue\n });\n }\n\n clear(scope: StorageScope = StorageScope.LOCAL) {\n if (scope === StorageScope.SESSION) {\n sessionStorage.clear();\n } else {\n localStorage.clear();\n }\n this.storageChange$.next({ scope, event: StorageServiceEventEnum.CLEARED });\n }\n}\n","import { Injectable } from '@angular/core';\n\nimport { ConfigService } from '@igo2/core/config';\n\nimport { BaseStorage } from './storage';\nimport { StorageOptions } from './storage.interface';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class StorageService extends BaseStorage<StorageOptions> {\n constructor(private config: ConfigService) {\n super(config);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;IAAY,aAGX;AAHD,CAAA,UAAY,YAAY,EAAA;AACtB,IAAA,YAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACjB,CAAC,EAHW,YAAY,KAAZ,YAAY,GAGvB,EAAA,CAAA,CAAA,CAAA;IAcW,wBAKX;AALD,CAAA,UAAY,uBAAuB,EAAA;AACjC,IAAA,uBAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,uBAAA,CAAA,UAAA,CAAA,GAAA,UAAqB,CAAA;AACrB,IAAA,uBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,uBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACrB,CAAC,EALW,uBAAuB,KAAvB,uBAAuB,GAKlC,EAAA,CAAA,CAAA;;MCXqB,WAAW,CAAA;AACrB,IAAA,OAAO,CAAK;AAEf,IAAA,cAAc,GACnB,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC;AAEjC,IAAA,WAAA,CAAY,MAAqB,EAAA;AAC/B,QAAA,IAAI,CAAC,OAAO,GAAG,MAAM,CA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AAc,CAAC,KAAK,EAAE,CAAC;SACxB;aAAM;YACL,YAAY,CAAC,KAAK,EAAE,CAAC;SACtB;AACD,QAAA,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,uBAAuB,CAAC,OAAO,EAAE,CAAC,CAAC;KAC7E;AACF;;ACzFK,MAAO,cAAe,SAAQ,WAA2B,CAAA;AACzC,IAAA,MAAA,CAAA;AAApB,IAAA,WAAA,CAAoB,MAAqB,EAAA;QACvC,KAAK,CAAC,MAAM,CAAC,CAAC;QADI,IAAM,CAAA,MAAA,GAAN,MAAM,CAAe;KAExC;uGAHU,cAAc,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,aAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAd,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,cAFb,MAAM,EAAA,CAAA,CAAA;;2FAEP,cAAc,EAAA,UAAA,EAAA,CAAA;kBAH1B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
1
+ {"version":3,"file":"igo2-core-storage.mjs","sources":["../../../packages/core/storage/src/storage.interface.ts","../../../packages/core/storage/src/storage.ts","../../../packages/core/storage/src/storage.service.ts","../../../packages/core/storage/src/igo2-core-storage.ts"],"sourcesContent":["export enum StorageScope {\n SESSION = 'Session',\n LOCAL = 'Local'\n}\n\nexport interface StorageOptions {\n key: string;\n}\n\nexport interface StorageServiceEvent {\n key?: string;\n scope: StorageScope;\n event: StorageServiceEventEnum;\n previousValue?: any;\n currentValue?: any;\n}\n\nexport enum StorageServiceEventEnum {\n ADDED = 'Added',\n MODIFIED = 'Modified',\n REMOVED = 'Removed',\n CLEARED = 'Cleared'\n}\n","import { ConfigService } from '@igo2/core/config';\n\nimport { BehaviorSubject } from 'rxjs';\n\nimport {\n StorageOptions,\n StorageScope,\n StorageServiceEvent,\n StorageServiceEventEnum\n} from './storage.interface';\n\nexport abstract class BaseStorage<T extends StorageOptions = StorageOptions> {\n protected options?: T;\n\n public storageChange$ = new BehaviorSubject<StorageServiceEvent>(undefined);\n\n constructor(config: ConfigService) {\n this.options = config.getConfig<T>('storage') || ({ key: 'igo' } as T);\n }\n\n /**\n * Use to get the data found in storage file\n */\n get(key: string, scope?: StorageScope): string | object | boolean | number {\n let value: any;\n\n if (!scope || scope === StorageScope.SESSION) {\n value = sessionStorage.getItem(`${this.options.key}.${key}`);\n }\n\n if (scope === StorageScope.LOCAL || (!value && !scope)) {\n value = localStorage.getItem(`${this.options.key}.${key}`);\n }\n\n if (value) {\n try {\n return JSON.parse(value);\n } catch {\n return value;\n }\n }\n\n return value;\n }\n\n set(\n key: string,\n value: string | object | boolean | number,\n scope: StorageScope = StorageScope.LOCAL\n ) {\n const previousValue = this.get(key, scope);\n if (scope === StorageScope.SESSION) {\n sessionStorage.setItem(\n `${this.options.key}.${key}`,\n JSON.stringify(value)\n );\n } else {\n localStorage.setItem(`${this.options.key}.${key}`, JSON.stringify(value));\n }\n const currentValue = this.get(key, scope);\n\n if (currentValue !== previousValue) {\n this.storageChange$.next({\n key,\n scope,\n event:\n previousValue !== undefined\n ? StorageServiceEventEnum.MODIFIED\n : StorageServiceEventEnum.ADDED,\n previousValue,\n currentValue\n });\n }\n }\n\n remove(key: string, scope: StorageScope = StorageScope.LOCAL) {\n const previousValue = this.get(key, scope);\n if (scope === StorageScope.SESSION) {\n sessionStorage.removeItem(`${this.options.key}.${key}`);\n } else {\n localStorage.removeItem(`${this.options.key}.${key}`);\n }\n this.storageChange$.next({\n key,\n scope,\n event: StorageServiceEventEnum.REMOVED,\n previousValue\n });\n }\n\n clear(scope: StorageScope = StorageScope.LOCAL) {\n if (scope === StorageScope.SESSION) {\n sessionStorage.clear();\n } else {\n localStorage.clear();\n }\n this.storageChange$.next({ scope, event: StorageServiceEventEnum.CLEARED });\n }\n}\n","import { Injectable } from '@angular/core';\n\nimport { ConfigService } from '@igo2/core/config';\n\nimport { BaseStorage } from './storage';\nimport { StorageOptions } from './storage.interface';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class StorageService extends BaseStorage<StorageOptions> {\n constructor(private config: ConfigService) {\n super(config);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;IAAY,aAGX;AAHD,CAAA,UAAY,YAAY,EAAA;AACtB,IAAA,YAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACjB,CAAC,EAHW,YAAY,KAAZ,YAAY,GAGvB,EAAA,CAAA,CAAA,CAAA;IAcW,wBAKX;AALD,CAAA,UAAY,uBAAuB,EAAA;AACjC,IAAA,uBAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,uBAAA,CAAA,UAAA,CAAA,GAAA,UAAqB,CAAA;AACrB,IAAA,uBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,uBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACrB,CAAC,EALW,uBAAuB,KAAvB,uBAAuB,GAKlC,EAAA,CAAA,CAAA;;MCXqB,WAAW,CAAA;AACrB,IAAA,OAAO,CAAK;AAEf,IAAA,cAAc,GAAG,IAAI,eAAe,CAAsB,SAAS,CAAC,CAAC;AAE5E,IAAA,WAAA,CAAY,MAAqB,EAAA;AAC/B,QAAA,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC,SAAS,CAAI,SAAS,CAAC,IAAK,EAAE,GAAG,EAAE,KAAK,EAAQ,CAAC;KACxE;AAED;;AAEG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AAI,CAAC,cAAc,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,uBAAuB,CAAC,OAAO,EAAE,CAAC,CAAC;KAC7E;AACF;;ACxFK,MAAO,cAAe,SAAQ,WAA2B,CAAA;AACzC,IAAA,MAAA,CAAA;AAApB,IAAA,WAAA,CAAoB,MAAqB,EAAA;QACvC,KAAK,CAAC,MAAM,CAAC,CAAC;QADI,IAAM,CAAA,MAAA,GAAN,MAAM,CAAe;KAExC;uGAHU,cAAc,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,aAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAd,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,cAFb,MAAM,EAAA,CAAA,CAAA;;2FAEP,cAAc,EAAA,UAAA,EAAA,CAAA;kBAH1B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
@@ -1,5 +1,5 @@
1
1
  import { CommonModule } from '@angular/common';
2
- import { HttpClientModule } from '@angular/common/http';
2
+ import { provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
3
3
  import * as i0 from '@angular/core';
4
4
  import { NgModule } from '@angular/core';
5
5
  import * as i1 from '@igo2/core/activity';
@@ -48,31 +48,27 @@ class IgoCoreModule {
48
48
  providers: [provideConfig(options), provideTranslation()]
49
49
  };
50
50
  }
51
- constructor() { }
52
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoCoreModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
53
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.9", ngImport: i0, type: IgoCoreModule, imports: [CommonModule,
54
- HttpClientModule, i1.IgoActivityModule, i2.IgoErrorModule, i3.NgxIndexedDBModule], exports: [IgoActivityModule, IgoErrorModule, IgoLanguageModule] });
55
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoCoreModule, providers: [provideMessage()], imports: [CommonModule,
56
- HttpClientModule,
51
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoCoreModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
52
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.2", ngImport: i0, type: IgoCoreModule, imports: [CommonModule, i1.IgoActivityModule, i2.IgoErrorModule, i3.NgxIndexedDBModule], exports: [IgoActivityModule, IgoErrorModule, IgoLanguageModule] });
53
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoCoreModule, providers: [provideMessage(), provideHttpClient(withInterceptorsFromDi())], imports: [CommonModule,
57
54
  IgoActivityModule.forRoot(),
58
55
  IgoErrorModule.forRoot(),
59
56
  NgxIndexedDBModule.forRoot(dbConfig), IgoActivityModule, IgoErrorModule, IgoLanguageModule] });
60
57
  }
61
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.9", ngImport: i0, type: IgoCoreModule, decorators: [{
58
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.2", ngImport: i0, type: IgoCoreModule, decorators: [{
62
59
  type: NgModule,
63
60
  args: [{
61
+ declarations: [],
62
+ exports: [IgoActivityModule, IgoErrorModule, IgoLanguageModule],
64
63
  imports: [
65
64
  CommonModule,
66
- HttpClientModule,
67
65
  IgoActivityModule.forRoot(),
68
66
  IgoErrorModule.forRoot(),
69
67
  NgxIndexedDBModule.forRoot(dbConfig)
70
68
  ],
71
- providers: [provideMessage()],
72
- declarations: [],
73
- exports: [IgoActivityModule, IgoErrorModule, IgoLanguageModule]
69
+ providers: [provideMessage(), provideHttpClient(withInterceptorsFromDi())]
74
70
  }]
75
- }], ctorParameters: () => [] });
71
+ }] });
76
72
 
77
73
  /*
78
74
  * Public API Surface of core
@@ -1 +1 @@
1
- {"version":3,"file":"igo2-core.mjs","sources":["../../../packages/core/src/lib/core.module.ts","../../../packages/core/src/public_api.ts","../../../packages/core/src/igo2-core.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport { HttpClientModule } from '@angular/common/http';\nimport { ModuleWithProviders, NgModule } from '@angular/core';\n\nimport { IgoActivityModule } from '@igo2/core/activity';\nimport { ConfigOptions, provideConfig } from '@igo2/core/config';\nimport { IgoLanguageModule, provideTranslation } from '@igo2/core/language';\nimport { provideMessage } from '@igo2/core/message';\nimport { IgoErrorModule } from '@igo2/core/request';\n\nimport { DBConfig, NgxIndexedDBModule } from 'ngx-indexed-db';\n\nconst dbConfig: DBConfig = {\n name: 'igo2DB',\n version: 2,\n objectStoresMeta: [\n {\n store: 'geoData',\n storeConfig: { keyPath: 'url', autoIncrement: false },\n storeSchema: [\n { name: 'regionID', keypath: 'regionID', options: { unique: false } }\n ]\n },\n {\n store: 'layerData',\n storeConfig: { keyPath: 'layerId', autoIncrement: false },\n storeSchema: [\n {\n name: 'layerOptions',\n keypath: 'layerOptions',\n options: { unique: false }\n },\n {\n name: 'sourceOptions',\n keypath: 'sourceOptions',\n options: { unique: false }\n }\n ]\n }\n ]\n};\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n IgoActivityModule.forRoot(),\n IgoErrorModule.forRoot(),\n NgxIndexedDBModule.forRoot(dbConfig)\n ],\n providers: [provideMessage()],\n declarations: [],\n exports: [IgoActivityModule, IgoErrorModule, IgoLanguageModule]\n})\nexport class IgoCoreModule {\n static forRoot(\n options: ConfigOptions = {}\n ): ModuleWithProviders<IgoCoreModule> {\n return {\n ngModule: IgoCoreModule,\n providers: [provideConfig(options), provideTranslation()]\n };\n }\n\n constructor() {}\n}\n","/*\n * Public API Surface of core\n */\n\nexport * from './lib/core.module';\n\n/** @deprecated */\n// export * from '@igo2/core/language';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAYA,MAAM,QAAQ,GAAa;AACzB,IAAA,IAAI,EAAE,QAAQ;AACd,IAAA,OAAO,EAAE,CAAC;AACV,IAAA,gBAAgB,EAAE;AAChB,QAAA;AACE,YAAA,KAAK,EAAE,SAAS;YAChB,WAAW,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,EAAE;AACrD,YAAA,WAAW,EAAE;AACX,gBAAA,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE;AACtE,aAAA;AACF,SAAA;AACD,QAAA;AACE,YAAA,KAAK,EAAE,WAAW;YAClB,WAAW,EAAE,EAAE,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,EAAE;AACzD,YAAA,WAAW,EAAE;AACX,gBAAA;AACE,oBAAA,IAAI,EAAE,cAAc;AACpB,oBAAA,OAAO,EAAE,cAAc;AACvB,oBAAA,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE;AAC3B,iBAAA;AACD,gBAAA;AACE,oBAAA,IAAI,EAAE,eAAe;AACrB,oBAAA,OAAO,EAAE,eAAe;AACxB,oBAAA,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE;AAC3B,iBAAA;AACF,aAAA;AACF,SAAA;AACF,KAAA;CACF,CAAC;MAaW,aAAa,CAAA;AACxB,IAAA,OAAO,OAAO,CACZ,OAAA,GAAyB,EAAE,EAAA;QAE3B,OAAO;AACL,YAAA,QAAQ,EAAE,aAAa;YACvB,SAAS,EAAE,CAAC,aAAa,CAAC,OAAO,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AAC;AAC7B,oBAAA,YAAY,EAAE,EAAE;AAChB,oBAAA,OAAO,EAAE,CAAC,iBAAiB,EAAE,cAAc,EAAE,iBAAiB,CAAC;AAChE,iBAAA,CAAA;;;ACpDD;;AAEG;AAIH;AACA;;ACPA;;AAEG;;;;"}
1
+ {"version":3,"file":"igo2-core.mjs","sources":["../../../packages/core/src/lib/core.module.ts","../../../packages/core/src/public_api.ts","../../../packages/core/src/igo2-core.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport {\n provideHttpClient,\n withInterceptorsFromDi\n} from '@angular/common/http';\nimport { ModuleWithProviders, NgModule } from '@angular/core';\n\nimport { IgoActivityModule } from '@igo2/core/activity';\nimport { ConfigOptions, provideConfig } from '@igo2/core/config';\nimport { IgoLanguageModule, provideTranslation } from '@igo2/core/language';\nimport { provideMessage } from '@igo2/core/message';\nimport { IgoErrorModule } from '@igo2/core/request';\n\nimport { DBConfig, NgxIndexedDBModule } from 'ngx-indexed-db';\n\nconst dbConfig: DBConfig = {\n name: 'igo2DB',\n version: 2,\n objectStoresMeta: [\n {\n store: 'geoData',\n storeConfig: { keyPath: 'url', autoIncrement: false },\n storeSchema: [\n { name: 'regionID', keypath: 'regionID', options: { unique: false } }\n ]\n },\n {\n store: 'layerData',\n storeConfig: { keyPath: 'layerId', autoIncrement: false },\n storeSchema: [\n {\n name: 'layerOptions',\n keypath: 'layerOptions',\n options: { unique: false }\n },\n {\n name: 'sourceOptions',\n keypath: 'sourceOptions',\n options: { unique: false }\n }\n ]\n }\n ]\n};\n@NgModule({\n declarations: [],\n exports: [IgoActivityModule, IgoErrorModule, IgoLanguageModule],\n imports: [\n CommonModule,\n IgoActivityModule.forRoot(),\n IgoErrorModule.forRoot(),\n NgxIndexedDBModule.forRoot(dbConfig)\n ],\n providers: [provideMessage(), provideHttpClient(withInterceptorsFromDi())]\n})\nexport class IgoCoreModule {\n static forRoot(\n options: ConfigOptions = {}\n ): ModuleWithProviders<IgoCoreModule> {\n return {\n ngModule: IgoCoreModule,\n providers: [provideConfig(options), provideTranslation()]\n };\n }\n}\n","/*\n * Public API Surface of core\n */\n\nexport * from './lib/core.module';\n\n/** @deprecated */\n// export * from '@igo2/core/language';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAeA,MAAM,QAAQ,GAAa;AACzB,IAAA,IAAI,EAAE,QAAQ;AACd,IAAA,OAAO,EAAE,CAAC;AACV,IAAA,gBAAgB,EAAE;AAChB,QAAA;AACE,YAAA,KAAK,EAAE,SAAS;YAChB,WAAW,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,EAAE;AACrD,YAAA,WAAW,EAAE;AACX,gBAAA,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE;AACtE,aAAA;AACF,SAAA;AACD,QAAA;AACE,YAAA,KAAK,EAAE,WAAW;YAClB,WAAW,EAAE,EAAE,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,EAAE;AACzD,YAAA,WAAW,EAAE;AACX,gBAAA;AACE,oBAAA,IAAI,EAAE,cAAc;AACpB,oBAAA,OAAO,EAAE,cAAc;AACvB,oBAAA,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE;AAC3B,iBAAA;AACD,gBAAA;AACE,oBAAA,IAAI,EAAE,eAAe;AACrB,oBAAA,OAAO,EAAE,eAAe;AACxB,oBAAA,OAAO,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE;AAC3B,iBAAA;AACF,aAAA;AACF,SAAA;AACF,KAAA;CACF,CAAC;MAYW,aAAa,CAAA;AACxB,IAAA,OAAO,OAAO,CACZ,OAAA,GAAyB,EAAE,EAAA;QAE3B,OAAO;AACL,YAAA,QAAQ,EAAE,aAAa;YACvB,SAAS,EAAE,CAAC,aAAa,CAAC,OAAO,CAAC,EAAE,kBAAk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AC,QAAQ,CAAC;AACrC,qBAAA;oBACD,SAAS,EAAE,CAAC,cAAc,EAAE,EAAE,iBAAiB,CAAC,sBAAsB,EAAE,CAAC,CAAC;AAC3E,iBAAA,CAAA;;;ACtDD;;AAEG;AAIH;AACA;;ACPA;;AAEG;;;;"}
@@ -1,2 +1,2 @@
1
- import { EnvironmentProviders, Provider } from '@angular/core';
2
- export declare function provideMockTranslation(loader?: Provider): EnvironmentProviders;
1
+ import { EnvironmentProviders } from '@angular/core';
2
+ export declare function provideMockTranslation(): EnvironmentProviders;
@@ -2,15 +2,13 @@ import { ModuleWithProviders } from '@angular/core';
2
2
  import { ConfigOptions } from '@igo2/core/config';
3
3
  import * as i0 from "@angular/core";
4
4
  import * as i1 from "@angular/common";
5
- import * as i2 from "@angular/common/http";
6
- import * as i3 from "@igo2/core/activity";
7
- import * as i4 from "@igo2/core/request";
8
- import * as i5 from "ngx-indexed-db";
9
- import * as i6 from "@igo2/core/language";
5
+ import * as i2 from "@igo2/core/activity";
6
+ import * as i3 from "@igo2/core/request";
7
+ import * as i4 from "ngx-indexed-db";
8
+ import * as i5 from "@igo2/core/language";
10
9
  export declare class IgoCoreModule {
11
10
  static forRoot(options?: ConfigOptions): ModuleWithProviders<IgoCoreModule>;
12
- constructor();
13
11
  static ɵfac: i0.ɵɵFactoryDeclaration<IgoCoreModule, never>;
14
- static ɵmod: i0.ɵɵNgModuleDeclaration<IgoCoreModule, never, [typeof i1.CommonModule, typeof i2.HttpClientModule, typeof i3.IgoActivityModule, typeof i4.IgoErrorModule, typeof i5.NgxIndexedDBModule], [typeof i3.IgoActivityModule, typeof i4.IgoErrorModule, typeof i6.IgoLanguageModule]>;
12
+ static ɵmod: i0.ɵɵNgModuleDeclaration<IgoCoreModule, never, [typeof i1.CommonModule, typeof i2.IgoActivityModule, typeof i3.IgoErrorModule, typeof i4.NgxIndexedDBModule], [typeof i2.IgoActivityModule, typeof i3.IgoErrorModule, typeof i5.IgoLanguageModule]>;
15
13
  static ɵinj: i0.ɵɵInjectorDeclaration<IgoCoreModule>;
16
14
  }
@@ -8,8 +8,8 @@ export interface Message {
8
8
  type?: MessageType;
9
9
  options?: MessageOptions;
10
10
  format?: 'text' | 'html';
11
- textInterpolateParams?: Object;
12
- titleInterpolateParams?: Object;
11
+ textInterpolateParams?: object;
12
+ titleInterpolateParams?: object;
13
13
  showIcon?: boolean;
14
14
  }
15
15
  export interface MessageOptions extends IndividualConfig {
@@ -17,11 +17,11 @@ export declare class MessageService {
17
17
  private get toastr();
18
18
  showError(httpError: HttpErrorResponse): ActiveToast<any>;
19
19
  message(message: Message): void;
20
- success(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: Object, titleInterpolateParams?: Object): ActiveToast<any>;
21
- error(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: Object, titleInterpolateParams?: Object): ActiveToast<any>;
22
- info(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: Object, titleInterpolateParams?: Object): ActiveToast<any>;
23
- alert(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: Object, titleInterpolateParams?: Object): ActiveToast<any>;
24
- show(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: Object, titleInterpolateParams?: Object): ActiveToast<any>;
20
+ success(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: object, titleInterpolateParams?: object): ActiveToast<any>;
21
+ error(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: object, titleInterpolateParams?: object): ActiveToast<any>;
22
+ info(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: object, titleInterpolateParams?: object): ActiveToast<any>;
23
+ alert(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: object, titleInterpolateParams?: object): ActiveToast<any>;
24
+ show(text: string, title?: string, options?: Partial<IndividualConfig>, textInterpolateParams?: object, titleInterpolateParams?: object): ActiveToast<any>;
25
25
  private handleNgxToastr;
26
26
  remove(id?: number): void;
27
27
  removeAllAreNotError(): void;
@@ -5,14 +5,14 @@
5
5
  $primary: map.get($theme, primary);
6
6
  $accent: map.get($theme, accent);
7
7
  $warn: map.get($theme, warn);
8
- $typography: mat.get-typography-config($theme);
8
+ $typography: mat.m2-get-typography-config($theme);
9
9
 
10
10
  .toast-error {
11
- background-color: mat.get-color-from-palette($warn) !important;
11
+ background-color: mat.m2-get-color-from-palette($warn) !important;
12
12
  }
13
13
 
14
14
  .toast-info {
15
- background-color: mat.get-color-from-palette($primary) !important;
15
+ background-color: mat.m2-get-color-from-palette($primary) !important;
16
16
  }
17
17
 
18
18
  .toast-no-icon {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@igo2/core",
3
- "version": "17.0.0",
3
+ "version": "17.0.1-next.2",
4
4
  "description": "IGO Library",
5
5
  "author": "IGO Community",
6
6
  "keywords": [
@@ -141,21 +141,21 @@
141
141
  "tslib": "^2.6.0"
142
142
  },
143
143
  "peerDependencies": {
144
- "@angular/cdk": "^17.0.3",
145
- "@angular/common": "^17.0.6",
146
- "@angular/core": "^17.0.6",
147
- "@angular/platform-browser": "^17.0.6",
148
- "@angular/router": "^17.0.6",
149
- "@igo2/utils": "^17.0.0",
144
+ "@angular/cdk": "^18.0.0",
145
+ "@angular/common": "^18.0.0",
146
+ "@angular/core": "^18.0.0",
147
+ "@angular/platform-browser": "^18.0.0",
148
+ "@angular/router": "^18.0.0",
149
+ "@igo2/utils": "^17.0.1-next.2",
150
150
  "@sentry/angular": "^8.26.0",
151
- "ngx-indexed-db": "^11.0.2",
152
- "ngx-toastr": "^18.0.0",
151
+ "ngx-indexed-db": "^19.0.0",
152
+ "ngx-toastr": "^19.0.0",
153
153
  "@ngx-translate/core": "^15.0.0",
154
154
  "@ngx-translate/http-loader": "^8.0.0",
155
155
  "rxjs": "^7.8.0"
156
156
  },
157
157
  "engines": {
158
- "node": ">=18.10.0"
158
+ "node": "^18.19.1 || ^20.11.1 || >=22.0.0"
159
159
  },
160
160
  "module": "fesm2022/igo2-core.mjs",
161
161
  "typings": "index.d.ts",
@@ -1,3 +1 @@
1
- export interface RegexOptions {
2
- [key: string]: any;
3
- }
1
+ export type RegexOptions = Record<string, any>;
@@ -3,7 +3,7 @@ import { ActivatedRoute, Params, Router } from '@angular/router';
3
3
  import { Observable } from 'rxjs';
4
4
  import { RouteServiceOptions } from './route.interface';
5
5
  import * as i0 from "@angular/core";
6
- export declare let ROUTE_SERVICE_OPTIONS: InjectionToken<RouteServiceOptions>;
6
+ export declare const ROUTE_SERVICE_OPTIONS: InjectionToken<RouteServiceOptions>;
7
7
  export declare function provideRouteServiceOptions(options: RouteServiceOptions): {
8
8
  provide: InjectionToken<RouteServiceOptions>;
9
9
  useValue: RouteServiceOptions;
@@ -16,8 +16,8 @@
16
16
 
17
17
  @mixin mat-button-toggle($theme) {
18
18
  $accent: map.get($theme, accent);
19
- $dark: mat.define-palette(mat.$grey-palette, 800, 700, 900);
20
- $density: mat.get-density-config($theme);
19
+ $dark: mat.m2-define-palette(mat.$m2-grey-palette, 800, 700, 900);
20
+ $density: mat.m2-get-density-config($theme);
21
21
 
22
22
  $theme: map.merge(
23
23
  $theme,
@@ -32,8 +32,8 @@
32
32
  color: black !important;
33
33
 
34
34
  &.mat-button-toggle-checked {
35
- background-color: mat.get-color-from-palette($accent);
36
- color: mat.get-color-from-palette($dark);
35
+ background-color: mat.m2-get-color-from-palette($accent);
36
+ color: mat.m2-get-color-from-palette($dark);
37
37
  }
38
38
  }
39
39
  }
@@ -3,12 +3,12 @@
3
3
  @use '../all-theme';
4
4
  @use '../typography';
5
5
 
6
- $primary: mat.define-palette(mat.$blue-palette, 700, 400, 900);
7
- $accent: mat.define-palette(mat.$blue-palette, 200);
8
- $warn: mat.define-palette(mat.$red-palette);
6
+ $primary: mat.m2-define-palette(mat.$m2-blue-palette, 700, 400, 900);
7
+ $accent: mat.m2-define-palette(mat.$m2-blue-palette, 200);
8
+ $warn: mat.m2-define-palette(mat.$m2-red-palette);
9
9
  $typography: typography.$igo-typography;
10
10
 
11
- $theme: mat.define-light-theme(
11
+ $theme: mat.m2-define-light-theme(
12
12
  (
13
13
  color: (
14
14
  primary: $primary,
@@ -36,12 +36,12 @@ $bluedark-palette: (
36
36
  )
37
37
  );
38
38
 
39
- $primary: mat.define-palette($bluedark-palette, 500);
40
- $accent: mat.define-palette($bluedark-palette, 200);
41
- $warn: mat.define-palette(mat.$red-palette);
39
+ $primary: mat.m2-define-palette($bluedark-palette, 500);
40
+ $accent: mat.m2-define-palette($bluedark-palette, 200);
41
+ $warn: mat.m2-define-palette(mat.$m2-red-palette);
42
42
  $typography: typography.$igo-typography;
43
43
 
44
- $theme: mat.define-light-theme(
44
+ $theme: mat.m2-define-light-theme(
45
45
  (
46
46
  color: (
47
47
  primary: $primary,
@@ -36,12 +36,12 @@ $dq-palette: (
36
36
  )
37
37
  );
38
38
 
39
- $primary: mat.define-palette($dq-palette, 900);
40
- $accent: mat.define-palette($dq-palette, 500);
41
- $warn: mat.define-palette(mat.$red-palette);
39
+ $primary: mat.m2-define-palette($dq-palette, 900);
40
+ $accent: mat.m2-define-palette($dq-palette, 500);
41
+ $warn: mat.m2-define-palette(mat.$m2-red-palette);
42
42
  $typography: typography.$igo-typography;
43
43
 
44
- $theme: mat.define-light-theme(
44
+ $theme: mat.m2-define-light-theme(
45
45
  (
46
46
  color: (
47
47
  primary: $primary,
@@ -2,12 +2,12 @@
2
2
  @use '../all-theme';
3
3
  @use '../typography';
4
4
 
5
- $primary: mat.define-palette(mat.$blue-grey-palette);
6
- $accent: mat.define-palette(mat.$pink-palette, A200, A100, A400);
7
- $warn: mat.define-palette(mat.$deep-orange-palette);
5
+ $primary: mat.m2-define-palette(mat.$m2-blue-grey-palette);
6
+ $accent: mat.m2-define-palette(mat.$m2-pink-palette, A200, A100, A400);
7
+ $warn: mat.m2-define-palette(mat.$m2-deep-orange-palette);
8
8
  $typography: typography.$igo-typography;
9
9
 
10
- $theme: mat.define-light-theme(
10
+ $theme: mat.m2-define-light-theme(
11
11
  (
12
12
  color: (
13
13
  primary: $primary,
@@ -2,12 +2,12 @@
2
2
  @use '../all-theme';
3
3
  @use '../typography';
4
4
 
5
- $primary: mat.define-palette(mat.$blue-grey-palette);
6
- $accent: mat.define-palette(mat.$pink-palette, A200, A100, A400);
7
- $warn: mat.define-palette(mat.$deep-orange-palette);
5
+ $primary: mat.m2-define-palette(mat.$m2-blue-grey-palette);
6
+ $accent: mat.m2-define-palette(mat.$m2-pink-palette, A200, A100, A400);
7
+ $warn: mat.m2-define-palette(mat.$m2-deep-orange-palette);
8
8
  $typography: typography.$igo-typography;
9
9
 
10
- $theme: mat.define-dark-theme(
10
+ $theme: mat.m2-define-dark-theme(
11
11
  (
12
12
  color: (
13
13
  primary: $primary,
@@ -2,12 +2,12 @@
2
2
  @use '../all-theme';
3
3
  @use '../typography';
4
4
 
5
- $primary: mat.define-palette(mat.$deep-purple-palette);
6
- $accent: mat.define-palette(mat.$amber-palette, A200, A100, A400);
7
- $warn: mat.define-palette(mat.$red-palette);
5
+ $primary: mat.m2-define-palette(mat.$m2-deep-purple-palette);
6
+ $accent: mat.m2-define-palette(mat.$m2-amber-palette, A200, A100, A400);
7
+ $warn: mat.m2-define-palette(mat.$m2-red-palette);
8
8
  $typography: typography.$igo-typography;
9
9
 
10
- $theme: mat.define-light-theme(
10
+ $theme: mat.m2-define-light-theme(
11
11
  (
12
12
  color: (
13
13
  primary: $primary,
@@ -2,12 +2,12 @@
2
2
  @use '../all-theme';
3
3
  @use '../typography';
4
4
 
5
- $primary: mat.define-palette(mat.$indigo-palette);
6
- $accent: mat.define-palette(mat.$pink-palette, A200, A100, A400);
7
- $warn: mat.define-palette(mat.$red-palette);
5
+ $primary: mat.m2-define-palette(mat.$m2-indigo-palette);
6
+ $accent: mat.m2-define-palette(mat.$m2-pink-palette, A200, A100, A400);
7
+ $warn: mat.m2-define-palette(mat.$m2-red-palette);
8
8
  $typography: typography.$igo-typography;
9
9
 
10
- $theme: mat.define-light-theme(
10
+ $theme: mat.m2-define-light-theme(
11
11
  (
12
12
  color: (
13
13
  primary: $primary,