@o3r/localization 10.0.0-prerelease.4 → 10.0.0-prerelease.40

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/i18n/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAC,iBAAiB,EAAC,MAAM,UAAU,CAAC;;AAE3C,wBAsCG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/i18n/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAAC,iBAAiB,EAAC,MAAM,UAAU,CAAC;;AAE3C,wBAsCI"}
@@ -1,10 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const architect_1 = require("@angular-devkit/architect");
4
+ const extractors_1 = require("@o3r/extractors");
4
5
  const fs = require("node:fs");
5
6
  const globby_1 = require("globby");
6
7
  const path = require("node:path");
7
- exports.default = (0, architect_1.createBuilder)((options, context) => {
8
+ exports.default = (0, architect_1.createBuilder)((0, extractors_1.createBuilderWithMetricsIfInstalled)((options, context) => {
8
9
  const posixWorkspaceRoot = context.workspaceRoot.split(path.sep).join(path.posix.sep);
9
10
  options.localizationConfigs.forEach((config) => {
10
11
  const fileNames = (0, globby_1.sync)(config.localizationFiles.map((files) => path.posix.join(posixWorkspaceRoot, files)));
@@ -31,5 +32,5 @@ exports.default = (0, architect_1.createBuilder)((options, context) => {
31
32
  return {
32
33
  success: true
33
34
  };
34
- });
35
+ }));
35
36
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/localization/index.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,yBAAyB,EAAE,MAAM,UAAU,CAAC;AAgFrD;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG;IAAC,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;CAAC,CAGvE;AAED;;;;;;;;GAQG;AACH,wBAAgB,0BAA0B,CACxC,QAAQ,EAAE,MAAM,EAChB,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,EAC1C,sBAAsB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC9C,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAC9C,cAAc,GAAE,GAAG,CAAC,MAAM,CAAa,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CA8BjE;;AAgLD,wBA0MG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/localization/index.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,yBAAyB,EAAE,MAAM,UAAU,CAAC;AAgFrD;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG;IAAC,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;CAAC,CAGvE;AAED;;;;;;;;GAQG;AACH,wBAAgB,0BAA0B,CACxC,QAAQ,EAAE,MAAM,EAChB,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,EAC1C,sBAAsB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC9C,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EAC9C,cAAc,GAAE,GAAG,CAAC,MAAM,CAAa,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CA8BjE;;AAgLD,wBA0MI"}
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getTranslationsForLanguage = exports.loadTranslations = void 0;
4
4
  const architect_1 = require("@angular-devkit/architect");
5
+ const extractors_1 = require("@o3r/extractors");
5
6
  const schematics_1 = require("@o3r/schematics");
6
7
  const fs = require("node:fs");
7
8
  const globby_1 = require("globby");
@@ -255,7 +256,7 @@ async function checkMetadata(localizationMetaDataFile, localizationExtractorTarg
255
256
  }
256
257
  }
257
258
  }
258
- exports.default = (0, architect_1.createBuilder)(async (options, context) => {
259
+ exports.default = (0, architect_1.createBuilder)((0, extractors_1.createBuilderWithMetricsIfInstalled)(async (options, context) => {
259
260
  context.reportRunning();
260
261
  // Load Targets to get build options
261
262
  context.reportProgress(0, STEP_NUMBER, 'Checking required options');
@@ -418,5 +419,5 @@ exports.default = (0, architect_1.createBuilder)(async (options, context) => {
418
419
  metadataWatcher.once('error', (err) => reject(err));
419
420
  });
420
421
  }
421
- });
422
+ }));
422
423
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/localization-extractor/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,kCAAkC,EAAE,MAAM,UAAU,CAAC;AAG9D,cAAc,UAAU,CAAC;;AAEzB,wBAkMG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/localization-extractor/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,kCAAkC,EAAE,MAAM,UAAU,CAAC;AAG9D,cAAc,UAAU,CAAC;;AAEzB,wBAkMI"}
@@ -11,7 +11,7 @@ const path = require("node:path");
11
11
  const localization_generator_1 = require("../helpers/localization.generator");
12
12
  const validations_1 = require("./validations");
13
13
  tslib_1.__exportStar(require("./schema"), exports);
14
- exports.default = (0, architect_1.createBuilder)(async (options, context) => {
14
+ exports.default = (0, architect_1.createBuilder)((0, extractors_1.createBuilderWithMetricsIfInstalled)(async (options, context) => {
15
15
  context.reportRunning();
16
16
  const localizationExtractor = new localization_generator_1.LocalizationExtractor(path.resolve(context.workspaceRoot, options.tsConfig), context.logger, options);
17
17
  const cache = { libs: {}, locs: {} };
@@ -173,5 +173,5 @@ exports.default = (0, architect_1.createBuilder)(async (options, context) => {
173
173
  tsWatcher.on('error', (err) => reject(err));
174
174
  });
175
175
  }
176
- });
176
+ }));
177
177
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@o3r/localization",
3
- "version": "10.0.0-prerelease.4",
3
+ "version": "10.0.0-prerelease.40",
4
4
  "description": "This module provides a runtime dynamic language/translation support and debug tools.",
5
5
  "keywords": [
6
6
  "localization",
@@ -38,13 +38,13 @@
38
38
  "@angular/core": "~17.0.2",
39
39
  "@angular/platform-browser-dynamic": "~17.0.2",
40
40
  "@formatjs/intl-numberformat": "^8.0.2",
41
- "@ngrx/store": "~17.0.0",
41
+ "@ngrx/store": "~17.1.0",
42
42
  "@ngx-translate/core": "~15.0.0",
43
- "@o3r/core": "^10.0.0-prerelease.4",
44
- "@o3r/dynamic-content": "^10.0.0-prerelease.4",
45
- "@o3r/extractors": "^10.0.0-prerelease.4",
46
- "@o3r/logger": "^10.0.0-prerelease.4",
47
- "@o3r/schematics": "^10.0.0-prerelease.4",
43
+ "@o3r/core": "^10.0.0-prerelease.40",
44
+ "@o3r/dynamic-content": "^10.0.0-prerelease.40",
45
+ "@o3r/extractors": "^10.0.0-prerelease.40",
46
+ "@o3r/logger": "^10.0.0-prerelease.40",
47
+ "@o3r/schematics": "^10.0.0-prerelease.40",
48
48
  "@schematics/angular": "~17.0.0",
49
49
  "chokidar": "^3.5.2",
50
50
  "intl-messageformat": "~10.5.0",
@@ -2,8 +2,12 @@ import { Rule } from '@angular-devkit/schematics';
2
2
  import type { NgAddLocalizationKeySchematicsSchema } from './schema';
3
3
  /**
4
4
  * Add localization key to an existing component
5
- *
6
5
  * @param options
7
6
  */
8
- export declare function ngAddLocalizationKey(options: NgAddLocalizationKeySchematicsSchema): Rule;
7
+ export declare function ngAddLocalizationKeyFn(options: NgAddLocalizationKeySchematicsSchema): Rule;
8
+ /**
9
+ * Add localization key to an existing component
10
+ * @param options
11
+ */
12
+ export declare const ngAddLocalizationKey: (options: NgAddLocalizationKeySchematicsSchema) => Rule;
9
13
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/add-localization-key/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,IAAI,EAIL,MAAM,4BAA4B,CAAC;AAapC,OAAO,KAAK,EAAE,oCAAoC,EAAE,MAAM,UAAU,CAAC;AA8FrE;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,oCAAoC,GAAG,IAAI,CAyJxF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/add-localization-key/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,IAAI,EAIL,MAAM,4BAA4B,CAAC;AAcpC,OAAO,KAAK,EAAE,oCAAoC,EAAE,MAAM,UAAU,CAAC;AA8FrE;;;GAGG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,oCAAoC,GAAG,IAAI,CAyJ1F;AAED;;;GAGG;AACH,eAAO,MAAM,oBAAoB,yDAAgE,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ngAddLocalizationKey = void 0;
3
+ exports.ngAddLocalizationKey = exports.ngAddLocalizationKeyFn = void 0;
4
4
  const schematics_1 = require("@angular-devkit/schematics");
5
5
  const prompt_1 = require("@angular/cli/src/utilities/prompt");
6
6
  const schematics_2 = require("@o3r/schematics");
@@ -78,10 +78,9 @@ const getLocalizationInformation = (componentPath, tree) => {
78
78
  };
79
79
  /**
80
80
  * Add localization key to an existing component
81
- *
82
81
  * @param options
83
82
  */
84
- function ngAddLocalizationKey(options) {
83
+ function ngAddLocalizationKeyFn(options) {
85
84
  return async (tree, context) => {
86
85
  try {
87
86
  const { selector, templateRelativePath } = (0, schematics_2.getO3rComponentInfoOrThrowIfNotFound)(tree, options.path);
@@ -161,7 +160,7 @@ function ngAddLocalizationKey(options) {
161
160
  (0, schematics_1.externalSchematic)('@o3r/core', 'convert-component', {
162
161
  path: options.path
163
162
  }),
164
- ngAddLocalizationKey(options)
163
+ ngAddLocalizationKeyFn(options)
165
164
  ]);
166
165
  }
167
166
  }
@@ -172,13 +171,13 @@ function ngAddLocalizationKey(options) {
172
171
  (0, schematics_1.schematic)('localization-to-component', {
173
172
  path: options.path
174
173
  }),
175
- ngAddLocalizationKey(options)
174
+ ngAddLocalizationKeyFn(options)
176
175
  ]);
177
176
  }
178
177
  }
179
178
  else if (e instanceof KeyAlreadyExists && context.interactive) {
180
179
  const newKey = await (0, schematics_2.askUserInput)(`${e.message}\nPlease choose another key name:`);
181
- return ngAddLocalizationKey({
180
+ return ngAddLocalizationKeyFn({
182
181
  ...options,
183
182
  key: newKey
184
183
  });
@@ -187,5 +186,10 @@ function ngAddLocalizationKey(options) {
187
186
  }
188
187
  };
189
188
  }
190
- exports.ngAddLocalizationKey = ngAddLocalizationKey;
189
+ exports.ngAddLocalizationKeyFn = ngAddLocalizationKeyFn;
190
+ /**
191
+ * Add localization key to an existing component
192
+ * @param options
193
+ */
194
+ exports.ngAddLocalizationKey = (0, schematics_2.createSchematicWithMetricsIfInstalled)(ngAddLocalizationKeyFn);
191
195
  //# sourceMappingURL=index.js.map
@@ -3,9 +3,8 @@ import { Rule } from '@angular-devkit/schematics';
3
3
  * Update CMS adapter tools
4
4
  * @param options @see RuleFactory.options
5
5
  * @param options.projectName
6
- * @param rootPath @see RuleFactory.rootPath
7
6
  */
8
- export declare function updateCmsAdapter(options: {
7
+ export declare const updateCmsAdapter: (options: {
9
8
  projectName?: string | undefined;
10
- }): Rule;
9
+ }) => Rule;
11
10
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/cms-adapter/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAA0B,MAAM,4BAA4B,CAAC;AAKvF;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE;IAAE,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,GAAG,IAAI,CAoEpF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/cms-adapter/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAA0B,MAAM,4BAA4B,CAAC;AA+EvF;;;;GAIG;AACH,eAAO,MAAM,gBAAgB;kBA3EwB,MAAM,GAAG,SAAS;UA2EkB,CAAC"}
@@ -8,9 +8,8 @@ const path = require("node:path");
8
8
  * Update CMS adapter tools
9
9
  * @param options @see RuleFactory.options
10
10
  * @param options.projectName
11
- * @param rootPath @see RuleFactory.rootPath
12
11
  */
13
- function updateCmsAdapter(options) {
12
+ function updateCmsAdapterFn(options) {
14
13
  if (!options.projectName) {
15
14
  return schematics_1.noop;
16
15
  }
@@ -69,5 +68,10 @@ function updateCmsAdapter(options) {
69
68
  editAngularJson
70
69
  ]);
71
70
  }
72
- exports.updateCmsAdapter = updateCmsAdapter;
71
+ /**
72
+ * Update CMS adapter tools
73
+ * @param options @see RuleFactory.options
74
+ * @param options.projectName
75
+ */
76
+ exports.updateCmsAdapter = (0, schematics_2.createSchematicWithMetricsIfInstalled)(updateCmsAdapterFn);
73
77
  //# sourceMappingURL=index.js.map
@@ -8,12 +8,7 @@ import { Rule } from '@angular-devkit/schematics';
8
8
  export declare function updateLocalization(options: {
9
9
  projectName?: string | null | undefined;
10
10
  }, rootPath: string): Rule;
11
- /**
12
- *
13
- * @param options
14
- * @param options.projectName
15
- */
16
- export declare function updateI18n(options: {
11
+ export declare const updateI18n: (options: {
17
12
  projectName?: string | undefined;
18
- }): Rule;
13
+ }) => Rule;
19
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/localization-base/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsD,IAAI,EAAyC,MAAM,4BAA4B,CAAC;AA+B7I;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE;IAAE,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;CAAE,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,CAgb/G;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE;IAAC,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAAC,GAAG,IAAI,CAwC5E"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/localization-base/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsD,IAAI,EAAyC,MAAM,4BAA4B,CAAC;AAgC7I;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE;IAAE,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;CAAE,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,CAgb/G;AAiDD,eAAO,MAAM,UAAU;kBA1CuB,MAAM,GAAG,SAAS;UA0Ca,CAAC"}
@@ -367,7 +367,7 @@ exports.updateLocalization = updateLocalization;
367
367
  * @param options
368
368
  * @param options.projectName
369
369
  */
370
- function updateI18n(options) {
370
+ function updateI18nFn(options) {
371
371
  if (!options.projectName) {
372
372
  return schematics_1.noop;
373
373
  }
@@ -403,5 +403,5 @@ function updateI18n(options) {
403
403
  updateAngularJson
404
404
  ]);
405
405
  }
406
- exports.updateI18n = updateI18n;
406
+ exports.updateI18n = (0, schematics_2.createSchematicWithMetricsIfInstalled)(updateI18nFn);
407
407
  //# sourceMappingURL=index.js.map
@@ -2,8 +2,12 @@ import { Rule } from '@angular-devkit/schematics';
2
2
  import type { NgAddLocalizationSchematicsSchema } from './schema';
3
3
  /**
4
4
  * Add localization architecture to an existing component
5
- *
6
5
  * @param options
7
6
  */
8
- export declare function ngAddLocalization(options: NgAddLocalizationSchematicsSchema): Rule;
7
+ export declare function ngAddLocalizationFn(options: NgAddLocalizationSchematicsSchema): Rule;
8
+ /**
9
+ * Add localization architecture to an existing component
10
+ * @param options
11
+ */
12
+ export declare const ngAddLocalization: (options: NgAddLocalizationSchematicsSchema) => Rule;
9
13
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/localization-to-component/index.ts"],"names":[],"mappings":"AAAA,OAAO,EASL,IAAI,EAML,MAAM,4BAA4B,CAAC;AAqBpC,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,UAAU,CAAC;AAkClE;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,iCAAiC,GAAG,IAAI,CA6SlF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/localization-to-component/index.ts"],"names":[],"mappings":"AAAA,OAAO,EASL,IAAI,EAML,MAAM,4BAA4B,CAAC;AAsBpC,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,UAAU,CAAC;AAkClE;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,iCAAiC,GAAG,IAAI,CA6SpF;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB,sDAA6D,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ngAddLocalization = void 0;
3
+ exports.ngAddLocalization = exports.ngAddLocalizationFn = void 0;
4
4
  const schematics_1 = require("@angular-devkit/schematics");
5
5
  const schematics_2 = require("@o3r/schematics");
6
6
  const ast_utils_1 = require("@schematics/angular/utility/ast-utils");
@@ -29,10 +29,9 @@ const checkLocalization = (componentPath, tree, baseFileName) => {
29
29
  };
30
30
  /**
31
31
  * Add localization architecture to an existing component
32
- *
33
32
  * @param options
34
33
  */
35
- function ngAddLocalization(options) {
34
+ function ngAddLocalizationFn(options) {
36
35
  return async (tree, context) => {
37
36
  try {
38
37
  const baseFileName = (0, node_path_1.basename)(options.path, '.component.ts');
@@ -231,7 +230,7 @@ const mockTranslationsCompilerProvider: Provider = {
231
230
  (0, schematics_1.externalSchematic)('@o3r/core', 'convert-component', {
232
231
  path: options.path
233
232
  }),
234
- ngAddLocalization(options)
233
+ ngAddLocalizationFn(options)
235
234
  ]);
236
235
  }
237
236
  }
@@ -239,5 +238,10 @@ const mockTranslationsCompilerProvider: Provider = {
239
238
  }
240
239
  };
241
240
  }
242
- exports.ngAddLocalization = ngAddLocalization;
241
+ exports.ngAddLocalizationFn = ngAddLocalizationFn;
242
+ /**
243
+ * Add localization architecture to an existing component
244
+ * @param options
245
+ */
246
+ exports.ngAddLocalization = (0, schematics_2.createSchematicWithMetricsIfInstalled)(ngAddLocalizationFn);
243
247
  //# sourceMappingURL=index.js.map
@@ -4,5 +4,5 @@ import type { NgAddSchematicsSchema } from './schema';
4
4
  * Add Otter localization to an Angular Project
5
5
  * @param options for the dependencies installations
6
6
  */
7
- export declare function ngAdd(options: NgAddSchematicsSchema): Rule;
7
+ export declare const ngAdd: (options: NgAddSchematicsSchema) => Rule;
8
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAA0B,MAAM,4BAA4B,CAAC;AAKvF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AAGtD;;;GAGG;AACH,wBAAgB,KAAK,CAAC,OAAO,EAAE,qBAAqB,GAAG,IAAI,CAsD1D"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAA0B,MAAM,4BAA4B,CAAC;AAKvF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AA+DtD;;;GAGG;AACH,eAAO,MAAM,KAAK,0CAAiD,CAAC"}
@@ -11,7 +11,7 @@ const devtools_registration_1 = require("./helpers/devtools-registration");
11
11
  * Add Otter localization to an Angular Project
12
12
  * @param options for the dependencies installations
13
13
  */
14
- function ngAdd(options) {
14
+ function ngAddFn(options) {
15
15
  return async (tree, context) => {
16
16
  try {
17
17
  const { applyEsLintFix, install, getProjectNewDependenciesType, getWorkspaceConfig, ngAddPackages, ngAddPeerDependencyPackages, getO3rPeerDeps } = await Promise.resolve().then(() => require('@o3r/schematics'));
@@ -66,5 +66,9 @@ function ngAdd(options) {
66
66
  }
67
67
  };
68
68
  }
69
- exports.ngAdd = ngAdd;
69
+ /**
70
+ * Add Otter localization to an Angular Project
71
+ * @param options for the dependencies installations
72
+ */
73
+ exports.ngAdd = (0, schematics_2.createSchematicWithMetricsIfInstalled)(ngAddFn);
70
74
  //# sourceMappingURL=index.js.map