@o3r/localization 10.2.0-prerelease.7 → 10.2.0-prerelease.70
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/README.md +3 -0
- package/devkit/localization-devkit.interface.d.ts +45 -2
- package/devkit/localization-devkit.interface.d.ts.map +1 -1
- package/devkit/localization-devtools.console.service.d.ts +6 -6
- package/devkit/localization-devtools.console.service.d.ts.map +1 -1
- package/devkit/localization-devtools.message.service.d.ts +11 -2
- package/devkit/localization-devtools.message.service.d.ts.map +1 -1
- package/devkit/localization-devtools.service.d.ts +30 -1
- package/devkit/localization-devtools.service.d.ts.map +1 -1
- package/devkit/localization-devtools.token.d.ts.map +1 -1
- package/esm2022/core/translate-messageformat-lazy.compiler.mjs +3 -3
- package/esm2022/devkit/localization-devkit.interface.mjs +1 -1
- package/esm2022/devkit/localization-devtools.console.service.mjs +17 -24
- package/esm2022/devkit/localization-devtools.message.service.mjs +73 -9
- package/esm2022/devkit/localization-devtools.module.mjs +4 -4
- package/esm2022/devkit/localization-devtools.service.mjs +58 -7
- package/esm2022/devkit/localization-devtools.token.mjs +3 -2
- package/esm2022/rules-engine/localization.handler-action.mjs +3 -3
- package/esm2022/rules-engine/localization.rules-engine.module.mjs +4 -4
- package/esm2022/stores/localization-override/localization-override.module.mjs +4 -4
- package/esm2022/tools/localization-translate.directive.mjs +3 -3
- package/esm2022/tools/localization-translate.pipe.mjs +6 -6
- package/esm2022/tools/localization.module.mjs +4 -4
- package/esm2022/tools/localization.service.mjs +10 -4
- package/esm2022/tools/localized-currency.pipe.mjs +3 -3
- package/esm2022/tools/localized-date.pipe.mjs +3 -3
- package/esm2022/tools/localized-decimal.pipe.mjs +3 -3
- package/esm2022/tools/text-direction.service.mjs +3 -3
- package/esm2022/tools/text-directionality.service.mjs +3 -3
- package/esm2022/tools/translations-loader.mjs +3 -3
- package/fesm2022/o3r-localization-rules-engine.mjs +7 -7
- package/fesm2022/o3r-localization.mjs +192 -78
- package/fesm2022/o3r-localization.mjs.map +1 -1
- package/package.json +21 -20
- package/schematics/ng-add/index.d.ts.map +1 -1
- package/schematics/ng-add/index.js +59 -59
- package/schematics/ng-add/index.js.map +1 -1
- package/tools/localization.service.d.ts +4 -0
- package/tools/localization.service.d.ts.map +1 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { immutablePrimitive, deepFill, otterComponentInfoPropertyName, filterMessageContent } from '@o3r/core';
|
|
1
|
+
import { immutablePrimitive, deepFill, otterComponentInfoPropertyName, sendOtterMessage, filterMessageContent } from '@o3r/core';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { InjectionToken, Injectable, Optional, Inject, NgModule, Directive, Input, Pipe, LOCALE_ID } from '@angular/core';
|
|
4
4
|
import * as i2 from '@ngx-translate/core';
|
|
5
5
|
import { TranslateCompiler, TranslateDirective, TranslatePipe, TranslateModule, TranslateLoader } from '@ngx-translate/core';
|
|
6
6
|
import { IntlMessageFormat } from 'intl-messageformat';
|
|
7
|
-
import { BehaviorSubject, combineLatest, of, from, lastValueFrom, Subscription, fromEvent } from 'rxjs';
|
|
8
|
-
import { map, distinctUntilChanged, switchMap, shareReplay, startWith, catchError, take } from 'rxjs/operators';
|
|
7
|
+
import { BehaviorSubject, combineLatest, of, from, lastValueFrom, Subscription, firstValueFrom, fromEvent } from 'rxjs';
|
|
9
8
|
import * as i3 from '@ngrx/store';
|
|
10
9
|
import { createAction, props, on, createReducer, StoreModule, createFeatureSelector, createSelector, select } from '@ngrx/store';
|
|
11
10
|
import * as i1 from '@o3r/logger';
|
|
12
11
|
import { LoggerService } from '@o3r/logger';
|
|
12
|
+
import { map, distinctUntilChanged, switchMap, shareReplay, startWith, catchError } from 'rxjs/operators';
|
|
13
13
|
import * as i2$1 from '@angular/cdk/bidi';
|
|
14
14
|
import { Directionality, DIR_DOCUMENT, BidiModule } from '@angular/cdk/bidi';
|
|
15
15
|
import { CurrencyPipe, DatePipe, DecimalPipe, CommonModule } from '@angular/common';
|
|
@@ -111,10 +111,10 @@ class TranslateMessageFormatLazyCompiler extends TranslateCompiler {
|
|
|
111
111
|
return Object.keys(translations)
|
|
112
112
|
.reduce(compilingStrategy, {});
|
|
113
113
|
}
|
|
114
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
115
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
114
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TranslateMessageFormatLazyCompiler, deps: [{ token: MESSAGE_FORMAT_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
115
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TranslateMessageFormatLazyCompiler }); }
|
|
116
116
|
}
|
|
117
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
117
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TranslateMessageFormatLazyCompiler, decorators: [{
|
|
118
118
|
type: Injectable
|
|
119
119
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
120
120
|
type: Optional
|
|
@@ -165,13 +165,13 @@ class LocalizationOverrideStoreModule {
|
|
|
165
165
|
]
|
|
166
166
|
};
|
|
167
167
|
}
|
|
168
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
169
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.
|
|
170
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.
|
|
168
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationOverrideStoreModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
169
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizationOverrideStoreModule, imports: [i3.StoreFeatureModule] }); }
|
|
170
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationOverrideStoreModule, providers: [
|
|
171
171
|
{ provide: LOCALIZATION_OVERRIDE_REDUCER_TOKEN, useFactory: getDefaultLocalizationOverrideReducer }
|
|
172
172
|
], imports: [StoreModule.forFeature(LOCALIZATION_OVERRIDE_STORE_NAME, LOCALIZATION_OVERRIDE_REDUCER_TOKEN)] }); }
|
|
173
173
|
}
|
|
174
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
174
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationOverrideStoreModule, decorators: [{
|
|
175
175
|
type: NgModule,
|
|
176
176
|
args: [{
|
|
177
177
|
imports: [
|
|
@@ -304,6 +304,12 @@ class LocalizationService {
|
|
|
304
304
|
this.translateService.setDefaultLang(language);
|
|
305
305
|
this.useLanguage(language);
|
|
306
306
|
}
|
|
307
|
+
/**
|
|
308
|
+
* Is the translation deactivation enabled
|
|
309
|
+
*/
|
|
310
|
+
isTranslationDeactivationEnabled() {
|
|
311
|
+
return this.configuration.enableTranslationDeactivation;
|
|
312
|
+
}
|
|
307
313
|
/**
|
|
308
314
|
* Wrapper to call the ngx-translate service TranslateService method getLangs().
|
|
309
315
|
*/
|
|
@@ -368,10 +374,10 @@ class LocalizationService {
|
|
|
368
374
|
translate(key, interpolateParams) {
|
|
369
375
|
return this.getKey(key).pipe(switchMap((translationKey) => this.getTranslationStream(translationKey, interpolateParams)), shareReplay(1));
|
|
370
376
|
}
|
|
371
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
372
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
377
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationService, deps: [{ token: i2.TranslateService }, { token: i1.LoggerService }, { token: LOCALIZATION_CONFIGURATION_TOKEN }, { token: i3.Store, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
378
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationService }); }
|
|
373
379
|
}
|
|
374
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
380
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationService, decorators: [{
|
|
375
381
|
type: Injectable
|
|
376
382
|
}], ctorParameters: () => [{ type: i2.TranslateService }, { type: i1.LoggerService }, { type: undefined, decorators: [{
|
|
377
383
|
type: Inject,
|
|
@@ -435,10 +441,10 @@ class LocalizationTranslateDirective extends TranslateDirective {
|
|
|
435
441
|
this.onKeyChange?.unsubscribe();
|
|
436
442
|
}
|
|
437
443
|
}
|
|
438
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
439
|
-
/** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.
|
|
444
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationTranslateDirective, deps: [{ token: LocalizationService }, { token: i2.TranslateService }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: LOCALIZATION_CONFIGURATION_TOKEN }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
445
|
+
/** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.1", type: LocalizationTranslateDirective, selector: "[translate],[ngx-translate]", inputs: { translate: "translate" }, usesInheritance: true, ngImport: i0 }); }
|
|
440
446
|
}
|
|
441
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
447
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationTranslateDirective, decorators: [{
|
|
442
448
|
type: Directive,
|
|
443
449
|
args: [{
|
|
444
450
|
selector: '[translate],[ngx-translate]'
|
|
@@ -503,10 +509,10 @@ class O3rLocalizationTranslatePipe extends TranslatePipe {
|
|
|
503
509
|
this.onShowKeysChange.unsubscribe();
|
|
504
510
|
}
|
|
505
511
|
}
|
|
506
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
507
|
-
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.
|
|
512
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: O3rLocalizationTranslatePipe, deps: [{ token: LocalizationService }, { token: i2.TranslateService }, { token: i0.ChangeDetectorRef }, { token: LOCALIZATION_CONFIGURATION_TOKEN }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
513
|
+
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: O3rLocalizationTranslatePipe, name: "o3rTranslate", pure: false }); }
|
|
508
514
|
}
|
|
509
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
515
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: O3rLocalizationTranslatePipe, decorators: [{
|
|
510
516
|
type: Pipe,
|
|
511
517
|
args: [{ name: 'o3rTranslate', pure: false }]
|
|
512
518
|
}], ctorParameters: () => [{ type: LocalizationService }, { type: i2.TranslateService }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
|
|
@@ -518,10 +524,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.3", ngImpor
|
|
|
518
524
|
* @deprecated please use O3rLocalizationTranslatePipe, will be removed in v12.
|
|
519
525
|
*/
|
|
520
526
|
class LocalizationTranslatePipe extends O3rLocalizationTranslatePipe {
|
|
521
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
522
|
-
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.
|
|
527
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationTranslatePipe, deps: null, target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
528
|
+
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizationTranslatePipe, name: "translate", pure: false }); }
|
|
523
529
|
}
|
|
524
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
530
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationTranslatePipe, decorators: [{
|
|
525
531
|
type: Pipe,
|
|
526
532
|
args: [{ name: 'translate', pure: false }]
|
|
527
533
|
}] });
|
|
@@ -542,10 +548,10 @@ class LocalizedCurrencyPipe extends CurrencyPipe {
|
|
|
542
548
|
ngOnDestroy() {
|
|
543
549
|
this.onLangChange.unsubscribe();
|
|
544
550
|
}
|
|
545
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
546
|
-
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.
|
|
551
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizedCurrencyPipe, deps: [{ token: LocalizationService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
552
|
+
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizedCurrencyPipe, name: "currency", pure: false }); }
|
|
547
553
|
}
|
|
548
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
554
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizedCurrencyPipe, decorators: [{
|
|
549
555
|
type: Pipe,
|
|
550
556
|
args: [{
|
|
551
557
|
name: 'currency',
|
|
@@ -574,10 +580,10 @@ class LocalizedDatePipe extends DatePipe {
|
|
|
574
580
|
ngOnDestroy() {
|
|
575
581
|
this.onLangChange.unsubscribe();
|
|
576
582
|
}
|
|
577
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
578
|
-
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.
|
|
583
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizedDatePipe, deps: [{ token: LocalizationService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
584
|
+
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizedDatePipe, name: "date", pure: false }); }
|
|
579
585
|
}
|
|
580
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
586
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizedDatePipe, decorators: [{
|
|
581
587
|
type: Pipe,
|
|
582
588
|
args: [{
|
|
583
589
|
name: 'date',
|
|
@@ -601,10 +607,10 @@ class LocalizedDecimalPipe extends DecimalPipe {
|
|
|
601
607
|
ngOnDestroy() {
|
|
602
608
|
this.onLangChange.unsubscribe();
|
|
603
609
|
}
|
|
604
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
605
|
-
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.
|
|
610
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizedDecimalPipe, deps: [{ token: LocalizationService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
611
|
+
/** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizedDecimalPipe, name: "decimal", pure: false }); }
|
|
606
612
|
}
|
|
607
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
613
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizedDecimalPipe, decorators: [{
|
|
608
614
|
type: Pipe,
|
|
609
615
|
args: [{
|
|
610
616
|
name: 'decimal',
|
|
@@ -638,10 +644,10 @@ class TextDirectionService {
|
|
|
638
644
|
});
|
|
639
645
|
return this.subscription;
|
|
640
646
|
}
|
|
641
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
642
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
647
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TextDirectionService, deps: [{ token: i2.TranslateService }, { token: LOCALIZATION_CONFIGURATION_TOKEN }, { token: i0.RendererFactory2 }, { token: i2$1.Directionality }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
648
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TextDirectionService }); }
|
|
643
649
|
}
|
|
644
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
650
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TextDirectionService, decorators: [{
|
|
645
651
|
type: Injectable
|
|
646
652
|
}], ctorParameters: () => [{ type: i2.TranslateService }, { type: undefined, decorators: [{
|
|
647
653
|
type: Inject,
|
|
@@ -658,10 +664,10 @@ class TextDirectionality extends Directionality {
|
|
|
658
664
|
ngOnDestroy() {
|
|
659
665
|
this.change.complete();
|
|
660
666
|
}
|
|
661
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
662
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
667
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TextDirectionality, deps: [{ token: DIR_DOCUMENT, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
668
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TextDirectionality }); }
|
|
663
669
|
}
|
|
664
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
670
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TextDirectionality, decorators: [{
|
|
665
671
|
type: Injectable
|
|
666
672
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
667
673
|
type: Optional
|
|
@@ -711,9 +717,9 @@ class LocalizationModule {
|
|
|
711
717
|
]
|
|
712
718
|
};
|
|
713
719
|
}
|
|
714
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
715
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.
|
|
716
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.
|
|
720
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
721
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizationModule, declarations: [O3rLocalizationTranslatePipe, LocalizationTranslatePipe, LocalizationTranslateDirective, LocalizedDatePipe, LocalizedDecimalPipe, LocalizedCurrencyPipe], imports: [TranslateModule, BidiModule, DynamicContentModule, CommonModule], exports: [TranslateModule, O3rLocalizationTranslatePipe, LocalizationTranslatePipe, LocalizationTranslateDirective, LocalizedDatePipe, LocalizedDecimalPipe, LocalizedCurrencyPipe] }); }
|
|
722
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationModule, providers: [
|
|
717
723
|
{ provide: LOCALIZATION_CONFIGURATION_TOKEN, useFactory: createLocalizationConfiguration, deps: [[new Optional(), CUSTOM_LOCALIZATION_CONFIGURATION_TOKEN]] },
|
|
718
724
|
{ provide: LOCALE_ID, useFactory: localeIdNgBridge, deps: [LocalizationService] },
|
|
719
725
|
{ provide: Directionality, useClass: TextDirectionality },
|
|
@@ -723,7 +729,7 @@ class LocalizationModule {
|
|
|
723
729
|
TextDirectionService
|
|
724
730
|
], imports: [TranslateModule, BidiModule, DynamicContentModule, CommonModule, TranslateModule] }); }
|
|
725
731
|
}
|
|
726
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
732
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationModule, decorators: [{
|
|
727
733
|
type: NgModule,
|
|
728
734
|
args: [{
|
|
729
735
|
declarations: [O3rLocalizationTranslatePipe, LocalizationTranslatePipe, LocalizationTranslateDirective, LocalizedDatePipe, LocalizedDecimalPipe, LocalizedCurrencyPipe],
|
|
@@ -830,10 +836,10 @@ class TranslationsLoader {
|
|
|
830
836
|
}
|
|
831
837
|
}));
|
|
832
838
|
}
|
|
833
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
834
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
839
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TranslationsLoader, deps: [{ token: LOCALIZATION_CONFIGURATION_TOKEN }, { token: i1.LoggerService, optional: true }, { token: i2$2.DynamicContentService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
840
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TranslationsLoader }); }
|
|
835
841
|
}
|
|
836
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
842
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: TranslationsLoader, decorators: [{
|
|
837
843
|
type: Injectable
|
|
838
844
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
839
845
|
type: Inject,
|
|
@@ -864,8 +870,16 @@ const translateLoaderProvider = {
|
|
|
864
870
|
};
|
|
865
871
|
|
|
866
872
|
class OtterLocalizationDevtools {
|
|
867
|
-
constructor(localizationService) {
|
|
873
|
+
constructor(localizationService, translateCompiler, appRef) {
|
|
868
874
|
this.localizationService = localizationService;
|
|
875
|
+
this.translateCompiler = translateCompiler;
|
|
876
|
+
this.appRef = appRef;
|
|
877
|
+
}
|
|
878
|
+
/**
|
|
879
|
+
* Is the translation deactivation enabled
|
|
880
|
+
*/
|
|
881
|
+
isTranslationDeactivationEnabled() {
|
|
882
|
+
return this.localizationService.isTranslationDeactivationEnabled();
|
|
869
883
|
}
|
|
870
884
|
/**
|
|
871
885
|
* Show localization keys
|
|
@@ -873,6 +887,7 @@ class OtterLocalizationDevtools {
|
|
|
873
887
|
*/
|
|
874
888
|
showLocalizationKeys(value) {
|
|
875
889
|
this.localizationService.toggleShowKeys(value);
|
|
890
|
+
this.appRef.tick();
|
|
876
891
|
}
|
|
877
892
|
/**
|
|
878
893
|
* Returns the current language
|
|
@@ -892,16 +907,56 @@ class OtterLocalizationDevtools {
|
|
|
892
907
|
fn(lang);
|
|
893
908
|
});
|
|
894
909
|
}
|
|
895
|
-
/**
|
|
896
|
-
|
|
910
|
+
/**
|
|
911
|
+
* Switch the current language to the specified value
|
|
912
|
+
* @param language new language to switch to
|
|
913
|
+
*/
|
|
914
|
+
async switchLanguage(language) {
|
|
915
|
+
await lastValueFrom(this.localizationService.useLanguage(language));
|
|
916
|
+
this.appRef.tick();
|
|
917
|
+
}
|
|
918
|
+
/**
|
|
919
|
+
* Updates the specified localization key/values for the current language.
|
|
920
|
+
*
|
|
921
|
+
* Recommendation: To be used with a small number of keys to update to avoid performance issues.
|
|
922
|
+
* @param keyValues key/values to update
|
|
923
|
+
* @param language if not provided, the current language value
|
|
924
|
+
*/
|
|
925
|
+
updateLocalizationKeys(keyValues, language) {
|
|
926
|
+
const lang = language || this.getCurrentLanguage();
|
|
927
|
+
const translateService = this.localizationService.getTranslateService();
|
|
928
|
+
Object.entries(keyValues).forEach(([key, value]) => {
|
|
929
|
+
translateService.set(key, value, lang);
|
|
930
|
+
});
|
|
931
|
+
this.appRef.tick();
|
|
932
|
+
}
|
|
933
|
+
/**
|
|
934
|
+
* Reload a language from the language file
|
|
935
|
+
* @see https://github.com/ngx-translate/core/blob/master/packages/core/lib/translate.service.ts#L490
|
|
936
|
+
* @param language language to reload
|
|
937
|
+
*/
|
|
938
|
+
async reloadLocalizationKeys(language) {
|
|
939
|
+
const lang = language || this.getCurrentLanguage();
|
|
940
|
+
if (this.translateCompiler.clearCache) {
|
|
941
|
+
this.translateCompiler.clearCache();
|
|
942
|
+
}
|
|
943
|
+
const initialLocs = await lastValueFrom(this.localizationService
|
|
944
|
+
.getTranslateService()
|
|
945
|
+
.reloadLang(lang));
|
|
946
|
+
this.localizationService.getTranslateService().setTranslation(language || this.getCurrentLanguage(), initialLocs);
|
|
947
|
+
this.appRef.tick();
|
|
948
|
+
}
|
|
949
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: OtterLocalizationDevtools, deps: [{ token: LocalizationService }, { token: i2.TranslateCompiler }, { token: i0.ApplicationRef }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
950
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: OtterLocalizationDevtools }); }
|
|
897
951
|
}
|
|
898
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
952
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: OtterLocalizationDevtools, decorators: [{
|
|
899
953
|
type: Injectable
|
|
900
|
-
}], ctorParameters: () => [{ type: LocalizationService }] });
|
|
954
|
+
}], ctorParameters: () => [{ type: LocalizationService }, { type: i2.TranslateCompiler }, { type: i0.ApplicationRef }] });
|
|
901
955
|
|
|
902
956
|
const OTTER_LOCALIZATION_DEVTOOLS_DEFAULT_OPTIONS = {
|
|
903
957
|
isActivatedOnBootstrap: false,
|
|
904
|
-
isActivatedOnBootstrapWhenCMSContext: true
|
|
958
|
+
isActivatedOnBootstrapWhenCMSContext: true,
|
|
959
|
+
metadataFilePath: './metadata/localisation.metadata.json'
|
|
905
960
|
};
|
|
906
961
|
const OTTER_LOCALIZATION_DEVTOOLS_OPTIONS = new InjectionToken('Otter Localization Devtools options');
|
|
907
962
|
|
|
@@ -909,10 +964,8 @@ const OTTER_LOCALIZATION_DEVTOOLS_OPTIONS = new InjectionToken('Otter Localizati
|
|
|
909
964
|
class LocalizationDevtoolsConsoleService {
|
|
910
965
|
/** Name of the Window property to access to the devtools */
|
|
911
966
|
static { this.windowModuleName = 'localization'; }
|
|
912
|
-
constructor(localizationDevtools,
|
|
967
|
+
constructor(localizationDevtools, options = OTTER_LOCALIZATION_DEVTOOLS_DEFAULT_OPTIONS) {
|
|
913
968
|
this.localizationDevtools = localizationDevtools;
|
|
914
|
-
this.localizationService = localizationService;
|
|
915
|
-
this.appRef = appRef;
|
|
916
969
|
this.options = options;
|
|
917
970
|
if (this.options.isActivatedOnBootstrap
|
|
918
971
|
|| (this.options.isActivatedOnBootstrapWhenCMSContext
|
|
@@ -929,12 +982,17 @@ class LocalizationDevtoolsConsoleService {
|
|
|
929
982
|
windowWithDevtools._OTTER_DEVTOOLS_[LocalizationDevtoolsConsoleService.windowModuleName] = this;
|
|
930
983
|
console.info(`Otter localization Devtools is now accessible via the _OTTER_DEVTOOLS_.${LocalizationDevtoolsConsoleService.windowModuleName} variable`);
|
|
931
984
|
}
|
|
985
|
+
/**
|
|
986
|
+
* @inheritdoc
|
|
987
|
+
*/
|
|
988
|
+
isTranslationDeactivationEnabled() {
|
|
989
|
+
return this.localizationDevtools.isTranslationDeactivationEnabled();
|
|
990
|
+
}
|
|
932
991
|
/**
|
|
933
992
|
* @inheritdoc
|
|
934
993
|
*/
|
|
935
994
|
showLocalizationKeys(value) {
|
|
936
995
|
this.localizationDevtools.showLocalizationKeys(value);
|
|
937
|
-
this.appRef.tick();
|
|
938
996
|
}
|
|
939
997
|
/**
|
|
940
998
|
* @inheritdoc
|
|
@@ -948,8 +1006,7 @@ class LocalizationDevtoolsConsoleService {
|
|
|
948
1006
|
*/
|
|
949
1007
|
async switchLanguage(language) {
|
|
950
1008
|
const previous = this.localizationDevtools.getCurrentLanguage();
|
|
951
|
-
await
|
|
952
|
-
this.appRef.tick();
|
|
1009
|
+
await this.localizationDevtools.switchLanguage(language);
|
|
953
1010
|
const current = this.localizationDevtools.getCurrentLanguage();
|
|
954
1011
|
return {
|
|
955
1012
|
requested: language,
|
|
@@ -967,25 +1024,20 @@ class LocalizationDevtoolsConsoleService {
|
|
|
967
1024
|
* @inheritdoc
|
|
968
1025
|
*/
|
|
969
1026
|
updateLocalizationKeys(keyValues, language) {
|
|
970
|
-
|
|
1027
|
+
return this.localizationDevtools.updateLocalizationKeys(keyValues, language);
|
|
971
1028
|
}
|
|
972
1029
|
/**
|
|
973
1030
|
* @inheritdoc
|
|
974
1031
|
*/
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
const initialLocs = await lastValueFrom(this.localizationService
|
|
978
|
-
.getTranslateService()
|
|
979
|
-
.reloadLang(lang)
|
|
980
|
-
.pipe(take(1)));
|
|
981
|
-
return this.updateLocalizationKeys(initialLocs, lang);
|
|
1032
|
+
reloadLocalizationKeys(language) {
|
|
1033
|
+
return this.localizationDevtools.reloadLocalizationKeys(language);
|
|
982
1034
|
}
|
|
983
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
984
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
1035
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsConsoleService, deps: [{ token: OtterLocalizationDevtools }, { token: OTTER_LOCALIZATION_DEVTOOLS_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1036
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsConsoleService }); }
|
|
985
1037
|
}
|
|
986
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1038
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsConsoleService, decorators: [{
|
|
987
1039
|
type: Injectable
|
|
988
|
-
}], ctorParameters: () => [{ type: OtterLocalizationDevtools }, { type:
|
|
1040
|
+
}], ctorParameters: () => [{ type: OtterLocalizationDevtools }, { type: undefined, decorators: [{
|
|
989
1041
|
type: Optional
|
|
990
1042
|
}, {
|
|
991
1043
|
type: Inject,
|
|
@@ -993,18 +1045,62 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.3", ngImpor
|
|
|
993
1045
|
}] }] });
|
|
994
1046
|
|
|
995
1047
|
const isLocalizationMessage = (message) => {
|
|
996
|
-
return message && message.dataType === 'displayLocalizationKeys'
|
|
1048
|
+
return message && (message.dataType === 'displayLocalizationKeys'
|
|
1049
|
+
|| message.dataType === 'languages'
|
|
1050
|
+
|| message.dataType === 'switchLanguage'
|
|
1051
|
+
|| message.dataType === 'localizations'
|
|
1052
|
+
|| message.dataType === 'updateLocalization'
|
|
1053
|
+
|| message.dataType === 'requestMessages'
|
|
1054
|
+
|| message.dataType === 'connect'
|
|
1055
|
+
|| message.dataType === 'reloadLocalizationKeys'
|
|
1056
|
+
|| message.dataType === 'isTranslationDeactivationEnabled'
|
|
1057
|
+
|| message.dataType === 'getTranslationValuesContentMessage');
|
|
997
1058
|
};
|
|
998
1059
|
class LocalizationDevtoolsMessageService {
|
|
999
|
-
constructor(logger, localizationDevTools, options = OTTER_LOCALIZATION_DEVTOOLS_DEFAULT_OPTIONS) {
|
|
1060
|
+
constructor(logger, localizationDevTools, localizationService, options = OTTER_LOCALIZATION_DEVTOOLS_DEFAULT_OPTIONS) {
|
|
1000
1061
|
this.logger = logger;
|
|
1001
1062
|
this.localizationDevTools = localizationDevTools;
|
|
1063
|
+
this.localizationService = localizationService;
|
|
1002
1064
|
this.options = options;
|
|
1003
1065
|
this.subscriptions = new Subscription();
|
|
1066
|
+
this.sendMessage = (sendOtterMessage);
|
|
1067
|
+
this.options = {
|
|
1068
|
+
...OTTER_LOCALIZATION_DEVTOOLS_DEFAULT_OPTIONS,
|
|
1069
|
+
...this.options
|
|
1070
|
+
};
|
|
1004
1071
|
if (this.options.isActivatedOnBootstrap) {
|
|
1005
1072
|
this.activate();
|
|
1006
1073
|
}
|
|
1007
1074
|
}
|
|
1075
|
+
async sendLocalizationsMetadata() {
|
|
1076
|
+
const metadata = await (await fetch(this.options.metadataFilePath)).json();
|
|
1077
|
+
this.sendMessage('localizations', {
|
|
1078
|
+
localizations: metadata
|
|
1079
|
+
});
|
|
1080
|
+
}
|
|
1081
|
+
/**
|
|
1082
|
+
* Function to trigger a re-send a requested messages to the Otter Chrome DevTools extension
|
|
1083
|
+
* @param only restricted list of messages to re-send
|
|
1084
|
+
*/
|
|
1085
|
+
async handleReEmitRequest(only) {
|
|
1086
|
+
if (!only || only.includes('localizations')) {
|
|
1087
|
+
void this.sendLocalizationsMetadata();
|
|
1088
|
+
}
|
|
1089
|
+
if (!only || only.includes('switchLanguage')) {
|
|
1090
|
+
this.sendMessage('switchLanguage', { language: this.localizationDevTools.getCurrentLanguage() });
|
|
1091
|
+
}
|
|
1092
|
+
if (!only || only.includes('languages')) {
|
|
1093
|
+
this.sendMessage('languages', { languages: this.localizationService.getLanguages() });
|
|
1094
|
+
}
|
|
1095
|
+
if (!only || only.includes('getTranslationValuesContentMessage')) {
|
|
1096
|
+
this.sendMessage('getTranslationValuesContentMessage', {
|
|
1097
|
+
translations: await firstValueFrom(this.localizationService.getTranslateService().getTranslation(this.localizationService.getCurrentLanguage()))
|
|
1098
|
+
});
|
|
1099
|
+
}
|
|
1100
|
+
if (!only || only.includes('isTranslationDeactivationEnabled')) {
|
|
1101
|
+
this.sendMessage('isTranslationDeactivationEnabled', { enabled: this.localizationService.isTranslationDeactivationEnabled() });
|
|
1102
|
+
}
|
|
1103
|
+
}
|
|
1008
1104
|
/**
|
|
1009
1105
|
* Function to handle the incoming messages from Otter Chrome DevTools extension
|
|
1010
1106
|
* @param event Event coming from the Otter Chrome DevTools extension
|
|
@@ -1021,6 +1117,24 @@ class LocalizationDevtoolsMessageService {
|
|
|
1021
1117
|
this.localizationDevTools.showLocalizationKeys(message.toggle);
|
|
1022
1118
|
break;
|
|
1023
1119
|
}
|
|
1120
|
+
case 'requestMessages': {
|
|
1121
|
+
void this.handleReEmitRequest(message.only);
|
|
1122
|
+
break;
|
|
1123
|
+
}
|
|
1124
|
+
case 'switchLanguage': {
|
|
1125
|
+
void this.localizationDevTools.switchLanguage(message.language);
|
|
1126
|
+
break;
|
|
1127
|
+
}
|
|
1128
|
+
case 'updateLocalization': {
|
|
1129
|
+
void this.localizationDevTools.updateLocalizationKeys({
|
|
1130
|
+
[message.key]: message.value
|
|
1131
|
+
}, message.lang);
|
|
1132
|
+
break;
|
|
1133
|
+
}
|
|
1134
|
+
case 'reloadLocalizationKeys': {
|
|
1135
|
+
void this.localizationDevTools.reloadLocalizationKeys(message.lang);
|
|
1136
|
+
break;
|
|
1137
|
+
}
|
|
1024
1138
|
default: {
|
|
1025
1139
|
this.logger.warn('Message ignored by the localization service', message);
|
|
1026
1140
|
}
|
|
@@ -1040,12 +1154,12 @@ class LocalizationDevtoolsMessageService {
|
|
|
1040
1154
|
ngOnDestroy() {
|
|
1041
1155
|
this.subscriptions.unsubscribe();
|
|
1042
1156
|
}
|
|
1043
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1044
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.
|
|
1157
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsMessageService, deps: [{ token: i1.LoggerService }, { token: OtterLocalizationDevtools }, { token: LocalizationService }, { token: OTTER_LOCALIZATION_DEVTOOLS_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1158
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsMessageService }); }
|
|
1045
1159
|
}
|
|
1046
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1160
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsMessageService, decorators: [{
|
|
1047
1161
|
type: Injectable
|
|
1048
|
-
}], ctorParameters: () => [{ type: i1.LoggerService }, { type: OtterLocalizationDevtools }, { type: undefined, decorators: [{
|
|
1162
|
+
}], ctorParameters: () => [{ type: i1.LoggerService }, { type: OtterLocalizationDevtools }, { type: LocalizationService }, { type: undefined, decorators: [{
|
|
1049
1163
|
type: Optional
|
|
1050
1164
|
}, {
|
|
1051
1165
|
type: Inject,
|
|
@@ -1068,16 +1182,16 @@ class LocalizationDevtoolsModule {
|
|
|
1068
1182
|
]
|
|
1069
1183
|
};
|
|
1070
1184
|
}
|
|
1071
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.
|
|
1072
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.
|
|
1073
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.
|
|
1185
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1186
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsModule, imports: [LocalizationModule] }); }
|
|
1187
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsModule, providers: [
|
|
1074
1188
|
{ provide: OTTER_LOCALIZATION_DEVTOOLS_OPTIONS, useValue: OTTER_LOCALIZATION_DEVTOOLS_DEFAULT_OPTIONS },
|
|
1075
1189
|
LocalizationDevtoolsMessageService,
|
|
1076
1190
|
LocalizationDevtoolsConsoleService,
|
|
1077
1191
|
OtterLocalizationDevtools
|
|
1078
1192
|
], imports: [LocalizationModule] }); }
|
|
1079
1193
|
}
|
|
1080
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.
|
|
1194
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.1", ngImport: i0, type: LocalizationDevtoolsModule, decorators: [{
|
|
1081
1195
|
type: NgModule,
|
|
1082
1196
|
args: [{
|
|
1083
1197
|
imports: [
|