@angular/localize 17.0.0-next.0 → 17.0.0-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.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../packages/localize/schematics/ng-add/index.ts"],
4
- "sourcesContent": ["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n *\n * @fileoverview Schematics for `ng add @angular/localize` schematic.\n */\n\nimport {chain, noop, Rule, SchematicContext, SchematicsException, Tree,} from '@angular-devkit/schematics';\nimport {NodePackageInstallTask} from '@angular-devkit/schematics/tasks';\nimport {addPackageJsonDependency, NodeDependencyType, removePackageJsonDependency,} from '@schematics/angular/utility/dependencies';\nimport {JSONFile, JSONPath} from '@schematics/angular/utility/json-file';\nimport {getWorkspace} from '@schematics/angular/utility/workspace';\nimport {Builders} from '@schematics/angular/utility/workspace-models';\n\nimport {Schema} from './schema';\n\nconst localizeType = `@angular/localize`;\nconst localizeTripleSlashType = `/// <reference types=\"@angular/localize\" />`;\n\nfunction addTypeScriptConfigTypes(projectName: string): Rule {\n return async (host: Tree) => {\n const workspace = await getWorkspace(host);\n const project = workspace.projects.get(projectName);\n if (!project) {\n throw new SchematicsException(`Invalid project name '${projectName}'.`);\n }\n\n // We add the root workspace tsconfig for better IDE support.\n const tsConfigFiles = new Set<string>();\n for (const target of project.targets.values()) {\n switch (target.builder) {\n case Builders.Karma:\n case Builders.Server:\n case Builders.Browser:\n const value = target.options?.['tsConfig'];\n if (typeof value === 'string') {\n tsConfigFiles.add(value);\n }\n\n break;\n }\n\n if (target.builder === Builders.Browser) {\n const value = target.options?.['main'];\n if (typeof value === 'string') {\n addTripleSlashType(host, value);\n }\n }\n }\n\n const typesJsonPath: JSONPath = ['compilerOptions', 'types'];\n for (const path of tsConfigFiles) {\n if (!host.exists(path)) {\n continue;\n }\n\n const json = new JSONFile(host, path);\n const types = json.get(typesJsonPath) ?? [];\n if (!Array.isArray(types)) {\n throw new SchematicsException(`TypeScript configuration file '${\n path}' has an invalid 'types' property. It must be an array.`);\n }\n\n const hasLocalizeType =\n types.some((t) => t === localizeType || t === '@angular/localize/init');\n if (hasLocalizeType) {\n // Skip has already localize type.\n continue;\n }\n\n json.modify(typesJsonPath, [...types, localizeType]);\n }\n };\n}\n\nfunction addTripleSlashType(host: Tree, path: string): void {\n const content = host.readText(path);\n if (!content.includes(localizeTripleSlashType)) {\n host.overwrite(path, localizeTripleSlashType + '\\n\\n' + content);\n }\n}\n\nfunction moveToDependencies(host: Tree, context: SchematicContext): void {\n if (!host.exists('package.json')) {\n return;\n }\n\n // Remove the previous dependency and add in a new one under the desired type.\n removePackageJsonDependency(host, '@angular/localize');\n addPackageJsonDependency(host, {\n name: '@angular/localize',\n type: NodeDependencyType.Default,\n version: `~17.0.0-next.0`,\n });\n\n // Add a task to run the package manager. This is necessary because we updated\n // \"package.json\" and we want lock files to reflect this.\n context.addTask(new NodePackageInstallTask());\n}\n\nexport default function(options: Schema): Rule {\n return () => {\n // We favor the name option because the project option has a\n // smart default which can be populated even when unspecified by the user.\n const projectName = options.name ?? options.project;\n\n if (!projectName) {\n throw new SchematicsException('Option \"project\" is required.');\n }\n\n return chain([\n addTypeScriptConfigTypes(projectName),\n // If `$localize` will be used at runtime then must install `@angular/localize`\n // into `dependencies`, rather than the default of `devDependencies`.\n options.useAtRuntime ? moveToDependencies : noop(),\n ]);\n };\n}\n"],
4
+ "sourcesContent": ["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n *\n * @fileoverview Schematics for `ng add @angular/localize` schematic.\n */\n\nimport {chain, noop, Rule, SchematicContext, SchematicsException, Tree,} from '@angular-devkit/schematics';\nimport {NodePackageInstallTask} from '@angular-devkit/schematics/tasks';\nimport {addPackageJsonDependency, NodeDependencyType, removePackageJsonDependency,} from '@schematics/angular/utility/dependencies';\nimport {JSONFile, JSONPath} from '@schematics/angular/utility/json-file';\nimport {getWorkspace} from '@schematics/angular/utility/workspace';\nimport {Builders} from '@schematics/angular/utility/workspace-models';\n\nimport {Schema} from './schema';\n\nconst localizeType = `@angular/localize`;\nconst localizeTripleSlashType = `/// <reference types=\"@angular/localize\" />`;\n\nfunction addTypeScriptConfigTypes(projectName: string): Rule {\n return async (host: Tree) => {\n const workspace = await getWorkspace(host);\n const project = workspace.projects.get(projectName);\n if (!project) {\n throw new SchematicsException(`Invalid project name '${projectName}'.`);\n }\n\n // We add the root workspace tsconfig for better IDE support.\n const tsConfigFiles = new Set<string>();\n for (const target of project.targets.values()) {\n switch (target.builder) {\n case Builders.Karma:\n case Builders.Server:\n case Builders.Browser:\n const value = target.options?.['tsConfig'];\n if (typeof value === 'string') {\n tsConfigFiles.add(value);\n }\n\n break;\n }\n\n if (target.builder === Builders.Browser) {\n const value = target.options?.['main'];\n if (typeof value === 'string') {\n addTripleSlashType(host, value);\n }\n }\n }\n\n const typesJsonPath: JSONPath = ['compilerOptions', 'types'];\n for (const path of tsConfigFiles) {\n if (!host.exists(path)) {\n continue;\n }\n\n const json = new JSONFile(host, path);\n const types = json.get(typesJsonPath) ?? [];\n if (!Array.isArray(types)) {\n throw new SchematicsException(`TypeScript configuration file '${\n path}' has an invalid 'types' property. It must be an array.`);\n }\n\n const hasLocalizeType =\n types.some((t) => t === localizeType || t === '@angular/localize/init');\n if (hasLocalizeType) {\n // Skip has already localize type.\n continue;\n }\n\n json.modify(typesJsonPath, [...types, localizeType]);\n }\n };\n}\n\nfunction addTripleSlashType(host: Tree, path: string): void {\n const content = host.readText(path);\n if (!content.includes(localizeTripleSlashType)) {\n host.overwrite(path, localizeTripleSlashType + '\\n\\n' + content);\n }\n}\n\nfunction moveToDependencies(host: Tree, context: SchematicContext): void {\n if (!host.exists('package.json')) {\n return;\n }\n\n // Remove the previous dependency and add in a new one under the desired type.\n removePackageJsonDependency(host, '@angular/localize');\n addPackageJsonDependency(host, {\n name: '@angular/localize',\n type: NodeDependencyType.Default,\n version: `~17.0.0-next.2`,\n });\n\n // Add a task to run the package manager. This is necessary because we updated\n // \"package.json\" and we want lock files to reflect this.\n context.addTask(new NodePackageInstallTask());\n}\n\nexport default function(options: Schema): Rule {\n return () => {\n // We favor the name option because the project option has a\n // smart default which can be populated even when unspecified by the user.\n const projectName = options.name ?? options.project;\n\n if (!projectName) {\n throw new SchematicsException('Option \"project\" is required.');\n }\n\n return chain([\n addTypeScriptConfigTypes(projectName),\n // If `$localize` will be used at runtime then must install `@angular/localize`\n // into `dependencies`, rather than the default of `devDependencies`.\n options.useAtRuntime ? moveToDependencies : noop(),\n ]);\n };\n}\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;AAUA,wBAA8E;AAC9E,mBAAqC;AACrC,0BAAyF;AACzF,uBAAiC;AACjC,uBAA2B;AAC3B,8BAAuB;AAIvB,IAAM,eAAe;AACrB,IAAM,0BAA0B;AAEhC,SAAS,yBAAyB,aAAmB;AACnD,SAAO,CAAO,SAAc;AAvB9B;AAwBI,UAAM,YAAY,UAAM,+BAAa,IAAI;AACzC,UAAM,UAAU,UAAU,SAAS,IAAI,WAAW;AAClD,QAAI,CAAC,SAAS;AACZ,YAAM,IAAI,sCAAoB,yBAAyB,eAAe;;AAIxE,UAAM,gBAAgB,oBAAI,IAAG;AAC7B,eAAW,UAAU,QAAQ,QAAQ,OAAM,GAAI;AAC7C,cAAQ,OAAO,SAAS;QACtB,KAAK,iCAAS;QACd,KAAK,iCAAS;QACd,KAAK,iCAAS;AACZ,gBAAM,SAAQ,YAAO,YAAP,mBAAiB;AAC/B,cAAI,OAAO,UAAU,UAAU;AAC7B,0BAAc,IAAI,KAAK;;AAGzB;;AAGJ,UAAI,OAAO,YAAY,iCAAS,SAAS;AACvC,cAAM,SAAQ,YAAO,YAAP,mBAAiB;AAC/B,YAAI,OAAO,UAAU,UAAU;AAC7B,6BAAmB,MAAM,KAAK;;;;AAKpC,UAAM,gBAA0B,CAAC,mBAAmB,OAAO;AAC3D,eAAW,QAAQ,eAAe;AAChC,UAAI,CAAC,KAAK,OAAO,IAAI,GAAG;AACtB;;AAGF,YAAM,OAAO,IAAI,0BAAS,MAAM,IAAI;AACpC,YAAM,SAAQ,UAAK,IAAI,aAAa,MAAtB,YAA2B,CAAA;AACzC,UAAI,CAAC,MAAM,QAAQ,KAAK,GAAG;AACzB,cAAM,IAAI,sCAAoB,kCAC1B,6DAA6D;;AAGnE,YAAM,kBACF,MAAM,KAAK,CAAC,MAAM,MAAM,gBAAgB,MAAM,wBAAwB;AAC1E,UAAI,iBAAiB;AAEnB;;AAGF,WAAK,OAAO,eAAe,CAAC,GAAG,OAAO,YAAY,CAAC;;EAEvD;AACF;AAEA,SAAS,mBAAmB,MAAY,MAAY;AAClD,QAAM,UAAU,KAAK,SAAS,IAAI;AAClC,MAAI,CAAC,QAAQ,SAAS,uBAAuB,GAAG;AAC9C,SAAK,UAAU,MAAM,0BAA0B,SAAS,OAAO;;AAEnE;AAEA,SAAS,mBAAmB,MAAY,SAAyB;AAC/D,MAAI,CAAC,KAAK,OAAO,cAAc,GAAG;AAChC;;AAIF,uDAA4B,MAAM,mBAAmB;AACrD,oDAAyB,MAAM;IAC7B,MAAM;IACN,MAAM,uCAAmB;IACzB,SAAS;GACV;AAID,UAAQ,QAAQ,IAAI,oCAAsB,CAAE;AAC9C;AAEc,SAAP,eAAiB,SAAe;AACrC,SAAO,MAAK;AAxGd;AA2GI,UAAM,eAAc,aAAQ,SAAR,YAAgB,QAAQ;AAE5C,QAAI,CAAC,aAAa;AAChB,YAAM,IAAI,sCAAoB,+BAA+B;;AAG/D,eAAO,yBAAM;MACX,yBAAyB,WAAW;MAGpC,QAAQ,eAAe,yBAAqB,wBAAI;KACjD;EACH;AACF;",
6
6
  "names": []
7
7
  }
@@ -14,9 +14,9 @@ import {
14
14
  unwrapMessagePartsFromLocalizeCall,
15
15
  unwrapMessagePartsFromTemplateLiteral,
16
16
  unwrapSubstitutionsFromLocalizeCall
17
- } from "./chunk-DTYQ3TT5.js";
17
+ } from "./chunk-SOWE44E4.js";
18
18
 
19
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/duplicates.mjs
19
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/duplicates.mjs
20
20
  function checkDuplicateMessages(fs, messages, duplicateMessageHandling, basePath) {
21
21
  const diagnostics = new Diagnostics();
22
22
  if (duplicateMessageHandling === "ignore")
@@ -50,11 +50,11 @@ function serializeMessage(fs, basePath, message) {
50
50
  }
51
51
  }
52
52
 
53
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/extraction.mjs
53
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/extraction.mjs
54
54
  import { SourceFileLoader } from "@angular/compiler-cli/private/localize";
55
55
  import { transformSync } from "@babel/core";
56
56
 
57
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/source_files/es2015_extract_plugin.mjs
57
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/source_files/es2015_extract_plugin.mjs
58
58
  import { \u0275parseMessage } from "@angular/localize";
59
59
  function makeEs2015ExtractPlugin(fs, messages, localizeName = "$localize") {
60
60
  return {
@@ -74,7 +74,7 @@ function makeEs2015ExtractPlugin(fs, messages, localizeName = "$localize") {
74
74
  };
75
75
  }
76
76
 
77
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/source_files/es5_extract_plugin.mjs
77
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/source_files/es5_extract_plugin.mjs
78
78
  import { \u0275parseMessage as \u0275parseMessage2 } from "@angular/localize";
79
79
  function makeEs5ExtractPlugin(fs, messages, localizeName = "$localize") {
80
80
  return {
@@ -102,7 +102,7 @@ function makeEs5ExtractPlugin(fs, messages, localizeName = "$localize") {
102
102
  };
103
103
  }
104
104
 
105
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/extraction.mjs
105
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/extraction.mjs
106
106
  var MessageExtractor = class {
107
107
  constructor(fs, logger, { basePath, useSourceMaps = true, localizeName = "$localize" }) {
108
108
  this.fs = fs;
@@ -169,7 +169,7 @@ var MessageExtractor = class {
169
169
  }
170
170
  };
171
171
 
172
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/utils.mjs
172
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/utils.mjs
173
173
  function consolidateMessages(messages, getMessageId2) {
174
174
  const messageGroups = /* @__PURE__ */ new Map();
175
175
  for (const message of messages) {
@@ -210,7 +210,7 @@ function compareLocations({ location: location1 }, { location: location2 }) {
210
210
  return 0;
211
211
  }
212
212
 
213
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/arb_translation_serializer.mjs
213
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/arb_translation_serializer.mjs
214
214
  var ArbTranslationSerializer = class {
215
215
  constructor(sourceLocale, basePath, fs) {
216
216
  this.sourceLocale = sourceLocale;
@@ -271,7 +271,7 @@ function getMessageId(message) {
271
271
  return message.customId || message.id;
272
272
  }
273
273
 
274
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/json_translation_serializer.mjs
274
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/json_translation_serializer.mjs
275
275
  var SimpleJsonTranslationSerializer = class {
276
276
  constructor(sourceLocale) {
277
277
  this.sourceLocale = sourceLocale;
@@ -285,7 +285,7 @@ var SimpleJsonTranslationSerializer = class {
285
285
  }
286
286
  };
287
287
 
288
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/legacy_message_id_migration_serializer.mjs
288
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/legacy_message_id_migration_serializer.mjs
289
289
  var LegacyMessageIdMigrationSerializer = class {
290
290
  constructor(_diagnostics) {
291
291
  this._diagnostics = _diagnostics;
@@ -314,7 +314,7 @@ function shouldMigrate(message) {
314
314
  return !message.customId && !!message.legacyIds && message.legacyIds.length > 0;
315
315
  }
316
316
 
317
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/format_options.mjs
317
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/format_options.mjs
318
318
  function validateOptions(name, validOptions, options) {
319
319
  const validOptionsMap = new Map(validOptions);
320
320
  for (const option in options) {
@@ -334,10 +334,10 @@ function parseFormatOptions(optionString = "{}") {
334
334
  return JSON.parse(optionString);
335
335
  }
336
336
 
337
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xliff1_translation_serializer.mjs
337
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xliff1_translation_serializer.mjs
338
338
  import { getFileSystem } from "@angular/compiler-cli/private/localize";
339
339
 
340
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/icu_parsing.mjs
340
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/icu_parsing.mjs
341
341
  function extractIcuPlaceholders(text) {
342
342
  const state = new StateStack();
343
343
  const pieces = new IcuPieces();
@@ -434,7 +434,7 @@ function assert(test, message) {
434
434
  }
435
435
  }
436
436
 
437
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xml_file.mjs
437
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xml_file.mjs
438
438
  var XmlFile = class {
439
439
  constructor() {
440
440
  this.output = '<?xml version="1.0" encoding="UTF-8" ?>\n';
@@ -516,7 +516,7 @@ function escapeXml(text) {
516
516
  return _ESCAPED_CHARS.reduce((text2, entry) => text2.replace(entry[0], entry[1]), text);
517
517
  }
518
518
 
519
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xliff1_translation_serializer.mjs
519
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xliff1_translation_serializer.mjs
520
520
  var LEGACY_XLIFF_MESSAGE_LENGTH = 40;
521
521
  var Xliff1TranslationSerializer = class {
522
522
  constructor(sourceLocale, basePath, useLegacyIds, formatOptions = {}, fs = getFileSystem()) {
@@ -664,7 +664,7 @@ var TAG_MAP = {
664
664
  "UNORDERED_LIST": "ul"
665
665
  };
666
666
 
667
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xliff2_translation_serializer.mjs
667
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xliff2_translation_serializer.mjs
668
668
  import { getFileSystem as getFileSystem2 } from "@angular/compiler-cli/private/localize";
669
669
  var MAX_LEGACY_XLIFF_2_MESSAGE_LENGTH = 20;
670
670
  var Xliff2TranslationSerializer = class {
@@ -806,7 +806,7 @@ function getTypeForPlaceholder(placeholder) {
806
806
  }
807
807
  }
808
808
 
809
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xmb_translation_serializer.mjs
809
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/translation_files/xmb_translation_serializer.mjs
810
810
  import { getFileSystem as getFileSystem3 } from "@angular/compiler-cli/private/localize";
811
811
  var XmbTranslationSerializer = class {
812
812
  constructor(basePath, useLegacyIds, fs = getFileSystem3()) {
@@ -899,4 +899,4 @@ export {
899
899
  * Use of this source code is governed by an MIT-style license that can be
900
900
  * found in the LICENSE file at https://angular.io/license
901
901
  */
902
- //# sourceMappingURL=chunk-ICJ4LFWD.js.map
902
+ //# sourceMappingURL=chunk-IHTOM4VK.js.map
@@ -12,9 +12,9 @@ import {
12
12
  unwrapMessagePartsFromLocalizeCall,
13
13
  unwrapMessagePartsFromTemplateLiteral,
14
14
  unwrapSubstitutionsFromLocalizeCall
15
- } from "./chunk-DTYQ3TT5.js";
15
+ } from "./chunk-SOWE44E4.js";
16
16
 
17
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/source_files/es2015_translate_plugin.mjs
17
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/source_files/es2015_translate_plugin.mjs
18
18
  import { getFileSystem } from "@angular/compiler-cli/private/localize";
19
19
  function makeEs2015TranslatePlugin(diagnostics, translations, { missingTranslation = "error", localizeName = "$localize" } = {}, fs = getFileSystem()) {
20
20
  return {
@@ -39,7 +39,7 @@ function makeEs2015TranslatePlugin(diagnostics, translations, { missingTranslati
39
39
  };
40
40
  }
41
41
 
42
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/source_files/es5_translate_plugin.mjs
42
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/source_files/es5_translate_plugin.mjs
43
43
  import { getFileSystem as getFileSystem2 } from "@angular/compiler-cli/private/localize";
44
44
  function makeEs5TranslatePlugin(diagnostics, translations, { missingTranslation = "error", localizeName = "$localize" } = {}, fs = getFileSystem2()) {
45
45
  return {
@@ -65,7 +65,7 @@ function makeEs5TranslatePlugin(diagnostics, translations, { missingTranslation
65
65
  };
66
66
  }
67
67
 
68
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/source_files/locale_plugin.mjs
68
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/source_files/locale_plugin.mjs
69
69
  import { types as t } from "@babel/core";
70
70
  function makeLocalePlugin(locale, { localizeName = "$localize" } = {}) {
71
71
  return {
@@ -105,7 +105,7 @@ function isLocalizeGuard(expression, localizeName) {
105
105
  return left.isUnaryExpression({ operator: "typeof" }) && isLocalize(left.get("argument"), localizeName) && right.isStringLiteral({ value: "undefined" }) || right.isUnaryExpression({ operator: "typeof" }) && isLocalize(right.get("argument"), localizeName) && left.isStringLiteral({ value: "undefined" });
106
106
  }
107
107
 
108
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/arb_translation_parser.mjs
108
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/arb_translation_parser.mjs
109
109
  import { \u0275parseTranslation } from "@angular/localize";
110
110
  var ArbTranslationParser = class {
111
111
  analyze(_filePath, contents) {
@@ -144,7 +144,7 @@ var ArbTranslationParser = class {
144
144
  }
145
145
  };
146
146
 
147
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/simple_json_translation_parser.mjs
147
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/simple_json_translation_parser.mjs
148
148
  import { \u0275parseTranslation as \u0275parseTranslation2 } from "@angular/localize";
149
149
  import { extname } from "path";
150
150
  var SimpleJsonTranslationParser = class {
@@ -189,10 +189,10 @@ var SimpleJsonTranslationParser = class {
189
189
  }
190
190
  };
191
191
 
192
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xliff1_translation_parser.mjs
192
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xliff1_translation_parser.mjs
193
193
  import { ParseErrorLevel as ParseErrorLevel3, visitAll as visitAll2 } from "@angular/compiler";
194
194
 
195
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/base_visitor.mjs
195
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/base_visitor.mjs
196
196
  var BaseVisitor = class {
197
197
  visitElement(_element, _context) {
198
198
  }
@@ -214,10 +214,10 @@ var BaseVisitor = class {
214
214
  }
215
215
  };
216
216
 
217
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/message_serialization/message_serializer.mjs
217
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/message_serialization/message_serializer.mjs
218
218
  import { Element as Element2, visitAll } from "@angular/compiler";
219
219
 
220
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/translation_parse_error.mjs
220
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/translation_parse_error.mjs
221
221
  import { ParseErrorLevel } from "@angular/compiler";
222
222
  var TranslationParseError = class extends Error {
223
223
  constructor(span, msg, level = ParseErrorLevel.ERROR) {
@@ -239,7 +239,7 @@ At ${span.start}${span.details ? `, ${span.details}` : ""}:
239
239
  return msg;
240
240
  }
241
241
 
242
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/translation_utils.mjs
242
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/translation_utils.mjs
243
243
  import { Element, ParseError, ParseErrorLevel as ParseErrorLevel2, XmlParser } from "@angular/compiler";
244
244
  function getAttrOrThrow(element, attrName) {
245
245
  const attrValue = getAttribute(element, attrName);
@@ -315,7 +315,7 @@ function addErrorsToBundle(bundle, errors) {
315
315
  }
316
316
  }
317
317
 
318
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/message_serialization/message_serializer.mjs
318
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/message_serialization/message_serializer.mjs
319
319
  var MessageSerializer = class extends BaseVisitor {
320
320
  constructor(renderer, config) {
321
321
  super();
@@ -377,7 +377,7 @@ var MessageSerializer = class extends BaseVisitor {
377
377
  }
378
378
  };
379
379
 
380
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/message_serialization/target_message_renderer.mjs
380
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/message_serialization/target_message_renderer.mjs
381
381
  import { \u0275makeParsedTranslation } from "@angular/localize";
382
382
  var TargetMessageRenderer = class {
383
383
  constructor() {
@@ -435,7 +435,7 @@ var TargetMessageRenderer = class {
435
435
  }
436
436
  };
437
437
 
438
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/serialize_translation_message.mjs
438
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/serialize_translation_message.mjs
439
439
  function serializeTranslationMessage(element, config) {
440
440
  const { rootNodes, errors: parseErrors } = parseInnerRange(element);
441
441
  try {
@@ -447,7 +447,7 @@ function serializeTranslationMessage(element, config) {
447
447
  }
448
448
  }
449
449
 
450
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xliff1_translation_parser.mjs
450
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xliff1_translation_parser.mjs
451
451
  var Xliff1TranslationParser = class {
452
452
  analyze(filePath, contents) {
453
453
  return canParseXml(filePath, contents, "xliff", { version: "1.2" });
@@ -524,7 +524,7 @@ var XliffTranslationVisitor = class extends BaseVisitor {
524
524
  }
525
525
  };
526
526
 
527
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xliff2_translation_parser.mjs
527
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xliff2_translation_parser.mjs
528
528
  import { Element as Element3, ParseErrorLevel as ParseErrorLevel4, visitAll as visitAll3 } from "@angular/compiler";
529
529
  var Xliff2TranslationParser = class {
530
530
  analyze(filePath, contents) {
@@ -603,7 +603,7 @@ function isFileElement(node) {
603
603
  return node instanceof Element3 && node.name === "file";
604
604
  }
605
605
 
606
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xtb_translation_parser.mjs
606
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_parsers/xtb_translation_parser.mjs
607
607
  import { ParseErrorLevel as ParseErrorLevel5, visitAll as visitAll4 } from "@angular/compiler";
608
608
  import { extname as extname2 } from "path";
609
609
  var XtbTranslationParser = class {
@@ -681,4 +681,4 @@ export {
681
681
  * Use of this source code is governed by an MIT-style license that can be
682
682
  * found in the LICENSE file at https://angular.io/license
683
683
  */
684
- //# sourceMappingURL=chunk-P36YJXSY.js.map
684
+ //# sourceMappingURL=chunk-QMXY6FD3.js.map
@@ -3,7 +3,7 @@
3
3
  const require = __cjsCompatRequire(import.meta.url);
4
4
 
5
5
 
6
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/diagnostics.mjs
6
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/diagnostics.mjs
7
7
  var Diagnostics = class {
8
8
  constructor() {
9
9
  this.messages = [];
@@ -38,7 +38,7 @@ var Diagnostics = class {
38
38
  }
39
39
  };
40
40
 
41
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/source_file_utils.mjs
41
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/source_file_utils.mjs
42
42
  import { getFileSystem } from "@angular/compiler-cli/private/localize";
43
43
  import { \u0275isMissingTranslationError, \u0275makeTemplateObject, \u0275translate } from "@angular/localize";
44
44
  import { types as t } from "@babel/core";
@@ -321,4 +321,4 @@ export {
321
321
  * Use of this source code is governed by an MIT-style license that can be
322
322
  * found in the LICENSE file at https://angular.io/license
323
323
  */
324
- //# sourceMappingURL=chunk-DTYQ3TT5.js.map
324
+ //# sourceMappingURL=chunk-SOWE44E4.js.map
@@ -11,7 +11,7 @@ import {
11
11
  Xliff2TranslationSerializer,
12
12
  XmbTranslationSerializer,
13
13
  checkDuplicateMessages
14
- } from "./chunk-ICJ4LFWD.js";
14
+ } from "./chunk-IHTOM4VK.js";
15
15
  import {
16
16
  ArbTranslationParser,
17
17
  SimpleJsonTranslationParser,
@@ -21,7 +21,7 @@ import {
21
21
  makeEs2015TranslatePlugin,
22
22
  makeEs5TranslatePlugin,
23
23
  makeLocalePlugin
24
- } from "./chunk-P36YJXSY.js";
24
+ } from "./chunk-QMXY6FD3.js";
25
25
  import {
26
26
  Diagnostics,
27
27
  buildLocalizeReplacement,
@@ -31,9 +31,9 @@ import {
31
31
  unwrapMessagePartsFromLocalizeCall,
32
32
  unwrapMessagePartsFromTemplateLiteral,
33
33
  unwrapSubstitutionsFromLocalizeCall
34
- } from "./chunk-DTYQ3TT5.js";
34
+ } from "./chunk-SOWE44E4.js";
35
35
 
36
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/index.mjs
36
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/index.mjs
37
37
  import { NodeJSFileSystem, setFileSystem } from "@angular/compiler-cli/private/localize";
38
38
  setFileSystem(new NodeJSFileSystem());
39
39
  export {
@@ -13,15 +13,15 @@ import {
13
13
  XmbTranslationSerializer,
14
14
  checkDuplicateMessages,
15
15
  parseFormatOptions
16
- } from "../../chunk-ICJ4LFWD.js";
17
- import "../../chunk-DTYQ3TT5.js";
16
+ } from "../../chunk-IHTOM4VK.js";
17
+ import "../../chunk-SOWE44E4.js";
18
18
 
19
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/cli.mjs
19
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/cli.mjs
20
20
  import { ConsoleLogger, LogLevel, NodeJSFileSystem, setFileSystem } from "@angular/compiler-cli/private/localize";
21
21
  import glob from "fast-glob";
22
22
  import yargs from "yargs";
23
23
 
24
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/index.mjs
24
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/index.mjs
25
25
  function extractTranslations({ rootPath: rootPath2, sourceFilePaths: sourceFilePaths2, sourceLocale, format: format2, outputPath: output, logger: logger2, useSourceMaps, useLegacyIds, duplicateMessageHandling: duplicateMessageHandling2, formatOptions: formatOptions2 = {}, fileSystem: fs }) {
26
26
  const basePath = fs.resolve(rootPath2);
27
27
  const extractor = new MessageExtractor(fs, logger2, { basePath, useSourceMaps });
@@ -64,7 +64,7 @@ function getSerializer(format2, sourceLocale, rootPath2, useLegacyIds, formatOpt
64
64
  throw new Error(`No translation serializer can handle the provided format: ${format2}`);
65
65
  }
66
66
 
67
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/extract/cli.mjs
67
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/extract/cli.mjs
68
68
  process.title = "Angular Localization Message Extractor (localize-extract)";
69
69
  var args = process.argv.slice(2);
70
70
  var options = yargs(args).option("l", {
@@ -4,15 +4,15 @@
4
4
  const require = __cjsCompatRequire(import.meta.url);
5
5
 
6
6
 
7
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/migrate/cli.mjs
7
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/migrate/cli.mjs
8
8
  import { ConsoleLogger, LogLevel, NodeJSFileSystem, setFileSystem } from "@angular/compiler-cli/private/localize";
9
9
  import glob from "fast-glob";
10
10
  import yargs from "yargs";
11
11
 
12
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/migrate/index.mjs
12
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/migrate/index.mjs
13
13
  import { getFileSystem } from "@angular/compiler-cli/private/localize";
14
14
 
15
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/migrate/migrate.mjs
15
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/migrate/migrate.mjs
16
16
  function migrateFile(sourceCode, mapping) {
17
17
  const legacyIds = Object.keys(mapping);
18
18
  for (const legacyId of legacyIds) {
@@ -26,7 +26,7 @@ function escapeRegExp(str) {
26
26
  return str.replace(/([.*+?^=!:${}()|[\]\/\\])/g, "\\$1");
27
27
  }
28
28
 
29
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/migrate/index.mjs
29
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/migrate/index.mjs
30
30
  function migrateFiles({ rootPath: rootPath2, translationFilePaths: translationFilePaths2, mappingFilePath, logger: logger2 }) {
31
31
  const fs2 = getFileSystem();
32
32
  const absoluteMappingPath = fs2.resolve(rootPath2, mappingFilePath);
@@ -42,7 +42,7 @@ function migrateFiles({ rootPath: rootPath2, translationFilePaths: translationFi
42
42
  }
43
43
  }
44
44
 
45
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/migrate/cli.mjs
45
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/migrate/cli.mjs
46
46
  var args = process.argv.slice(2);
47
47
  var options = yargs(args).option("r", {
48
48
  alias: "root",
@@ -12,26 +12,26 @@ import {
12
12
  makeEs2015TranslatePlugin,
13
13
  makeEs5TranslatePlugin,
14
14
  makeLocalePlugin
15
- } from "../../chunk-P36YJXSY.js";
15
+ } from "../../chunk-QMXY6FD3.js";
16
16
  import {
17
17
  Diagnostics
18
- } from "../../chunk-DTYQ3TT5.js";
18
+ } from "../../chunk-SOWE44E4.js";
19
19
 
20
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/cli.mjs
20
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/cli.mjs
21
21
  import { NodeJSFileSystem, setFileSystem } from "@angular/compiler-cli/private/localize";
22
22
  import glob from "fast-glob";
23
23
  import yargs from "yargs";
24
24
 
25
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/output_path.mjs
25
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/output_path.mjs
26
26
  function getOutputPathFn(fs2, outputFolder) {
27
27
  const [pre, post] = outputFolder.split("{{LOCALE}}");
28
28
  return post === void 0 ? (_locale, relativePath) => fs2.join(pre, relativePath) : (locale, relativePath) => fs2.join(pre + locale + post, relativePath);
29
29
  }
30
30
 
31
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/index.mjs
31
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/index.mjs
32
32
  import { getFileSystem, relativeFrom } from "@angular/compiler-cli/private/localize";
33
33
 
34
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/asset_files/asset_translation_handler.mjs
34
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/asset_files/asset_translation_handler.mjs
35
35
  import { absoluteFrom } from "@angular/compiler-cli/private/localize";
36
36
  var AssetTranslationHandler = class {
37
37
  constructor(fs2) {
@@ -59,7 +59,7 @@ var AssetTranslationHandler = class {
59
59
  }
60
60
  };
61
61
 
62
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/source_files/source_file_translation_handler.mjs
62
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/source_files/source_file_translation_handler.mjs
63
63
  import { absoluteFrom as absoluteFrom2 } from "@angular/compiler-cli/private/localize";
64
64
  import babel from "@babel/core";
65
65
  var SourceFileTranslationHandler = class {
@@ -127,7 +127,7 @@ var SourceFileTranslationHandler = class {
127
127
  }
128
128
  };
129
129
 
130
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_loader.mjs
130
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translation_files/translation_loader.mjs
131
131
  var TranslationLoader = class {
132
132
  constructor(fs2, translationParsers, duplicateTranslation2, diagnostics2) {
133
133
  this.fs = fs2;
@@ -197,7 +197,7 @@ ${parser.constructor.name} cannot parse translation file.`));
197
197
  }
198
198
  };
199
199
 
200
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/translator.mjs
200
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/translator.mjs
201
201
  var Translator = class {
202
202
  constructor(fs2, resourceHandlers, diagnostics2) {
203
203
  this.fs = fs2;
@@ -219,7 +219,7 @@ var Translator = class {
219
219
  }
220
220
  };
221
221
 
222
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/index.mjs
222
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/index.mjs
223
223
  function translateFiles({ sourceRootPath: sourceRootPath2, sourceFilePaths: sourceFilePaths2, translationFilePaths: translationFilePaths2, translationFileLocales: translationFileLocales2, outputPathFn: outputPathFn2, diagnostics: diagnostics2, missingTranslation: missingTranslation2, duplicateTranslation: duplicateTranslation2, sourceLocale: sourceLocale2 }) {
224
224
  const fs2 = getFileSystem();
225
225
  const translationLoader = new TranslationLoader(fs2, [
@@ -239,7 +239,7 @@ function translateFiles({ sourceRootPath: sourceRootPath2, sourceFilePaths: sour
239
239
  resourceProcessor.translateFiles(sourceFilePaths2.map(relativeFrom), fs2.resolve(sourceRootPath2), outputPathFn2, translations, sourceLocale2);
240
240
  }
241
241
 
242
- // bazel-out/darwin_arm64-fastbuild/bin/packages/localize/tools/src/translate/cli.mjs
242
+ // bazel-out/k8-fastbuild/bin/packages/localize/tools/src/translate/cli.mjs
243
243
  process.title = "Angular Localization Message Translator (localize-translate)";
244
244
  var args = process.argv.slice(2);
245
245
  var options = yargs(args).option("r", {