@angular/compiler-cli 13.3.5 → 13.3.8

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.
@@ -11,7 +11,6 @@ import {
11
11
  DirectiveDecoratorHandler,
12
12
  DtsMetadataReader,
13
13
  DtsTransformRegistry,
14
- FactoryGenerator,
15
14
  InjectableClassRegistry,
16
15
  InjectableDecoratorHandler,
17
16
  LocalMetadataRegistry,
@@ -21,20 +20,12 @@ import {
21
20
  PipeDecoratorHandler,
22
21
  ResourceRegistry,
23
22
  SemanticDepGraphUpdater,
24
- ShimAdapter,
25
- ShimReferenceTagger,
26
- SummaryGenerator,
27
23
  TraitCompiler,
28
24
  aliasTransformFactory,
29
- copyFileShimData,
30
25
  declarationTransformFactory,
31
26
  flattenInheritedDirectiveMetadata,
32
- generatedFactoryTransform,
33
- isShim,
34
- ivyTransformFactory,
35
- retagAllTsFiles,
36
- untagAllTsFiles
37
- } from "./chunk-MSOUQGBK.js";
27
+ ivyTransformFactory
28
+ } from "./chunk-KAJ5EOEG.js";
38
29
  import {
39
30
  TypeScriptReflectionHost,
40
31
  isNamedClassDeclaration
@@ -84,6 +75,7 @@ import {
84
75
  LogicalFileSystem,
85
76
  absoluteFrom,
86
77
  absoluteFromSourceFile,
78
+ basename,
87
79
  dirname,
88
80
  getFileSystem,
89
81
  getSourceFileOrError,
@@ -162,7 +154,7 @@ var SymbolKind;
162
154
 
163
155
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/program.mjs
164
156
  import { HtmlParser, MessageBundle } from "@angular/compiler";
165
- import ts32 from "typescript";
157
+ import ts35 from "typescript";
166
158
 
167
159
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/transformers/i18n.mjs
168
160
  import { Xliff, Xliff2, Xmb } from "@angular/compiler";
@@ -267,7 +259,7 @@ function verifySupportedTypeScriptVersion() {
267
259
  }
268
260
 
269
261
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/core/src/compiler.mjs
270
- import ts30 from "typescript";
262
+ import ts33 from "typescript";
271
263
 
272
264
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/cycles/src/analyzer.mjs
273
265
  var CycleAnalyzer = class {
@@ -616,7 +608,407 @@ var UpdateMode;
616
608
  })(UpdateMode || (UpdateMode = {}));
617
609
 
618
610
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/program_driver/src/ts_create_program_driver.mjs
611
+ import ts9 from "typescript";
612
+
613
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/adapter.mjs
619
614
  import ts6 from "typescript";
615
+
616
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/expando.mjs
617
+ var NgExtension = Symbol("NgExtension");
618
+ function isExtended(sf) {
619
+ return sf[NgExtension] !== void 0;
620
+ }
621
+ function sfExtensionData(sf) {
622
+ const extSf = sf;
623
+ if (extSf[NgExtension] !== void 0) {
624
+ return extSf[NgExtension];
625
+ }
626
+ const extension = {
627
+ isTopLevelShim: false,
628
+ fileShim: null,
629
+ originalReferencedFiles: null,
630
+ taggedReferenceFiles: null
631
+ };
632
+ extSf[NgExtension] = extension;
633
+ return extension;
634
+ }
635
+ function isFileShimSourceFile(sf) {
636
+ return isExtended(sf) && sf[NgExtension].fileShim !== null;
637
+ }
638
+ function isShim(sf) {
639
+ return isExtended(sf) && (sf[NgExtension].fileShim !== null || sf[NgExtension].isTopLevelShim);
640
+ }
641
+ function copyFileShimData(from, to) {
642
+ if (!isFileShimSourceFile(from)) {
643
+ return;
644
+ }
645
+ sfExtensionData(to).fileShim = sfExtensionData(from).fileShim;
646
+ }
647
+ function untagAllTsFiles(program) {
648
+ for (const sf of program.getSourceFiles()) {
649
+ untagTsFile(sf);
650
+ }
651
+ }
652
+ function retagAllTsFiles(program) {
653
+ for (const sf of program.getSourceFiles()) {
654
+ retagTsFile(sf);
655
+ }
656
+ }
657
+ function untagTsFile(sf) {
658
+ if (sf.isDeclarationFile || !isExtended(sf)) {
659
+ return;
660
+ }
661
+ const ext = sfExtensionData(sf);
662
+ if (ext.originalReferencedFiles !== null) {
663
+ sf.referencedFiles = ext.originalReferencedFiles;
664
+ }
665
+ }
666
+ function retagTsFile(sf) {
667
+ if (sf.isDeclarationFile || !isExtended(sf)) {
668
+ return;
669
+ }
670
+ const ext = sfExtensionData(sf);
671
+ if (ext.taggedReferenceFiles !== null) {
672
+ sf.referencedFiles = ext.taggedReferenceFiles;
673
+ }
674
+ }
675
+
676
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/util.mjs
677
+ var TS_EXTENSIONS = /\.tsx?$/i;
678
+ function makeShimFileName(fileName, suffix) {
679
+ return absoluteFrom(fileName.replace(TS_EXTENSIONS, suffix));
680
+ }
681
+ function generatedModuleName(originalModuleName, originalFileName, genSuffix) {
682
+ let moduleName;
683
+ if (originalFileName.endsWith("/index.ts")) {
684
+ moduleName = originalModuleName + "/index" + genSuffix;
685
+ } else {
686
+ moduleName = originalModuleName + genSuffix;
687
+ }
688
+ return moduleName;
689
+ }
690
+
691
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/adapter.mjs
692
+ var ShimAdapter = class {
693
+ constructor(delegate, tsRootFiles, topLevelGenerators, perFileGenerators, oldProgram) {
694
+ this.delegate = delegate;
695
+ this.shims = /* @__PURE__ */ new Map();
696
+ this.priorShims = /* @__PURE__ */ new Map();
697
+ this.notShims = /* @__PURE__ */ new Set();
698
+ this.generators = [];
699
+ this.ignoreForEmit = /* @__PURE__ */ new Set();
700
+ this.extensionPrefixes = [];
701
+ for (const gen of perFileGenerators) {
702
+ const pattern = `^(.*)\\.${gen.extensionPrefix}\\.ts$`;
703
+ const regexp = new RegExp(pattern, "i");
704
+ this.generators.push({
705
+ generator: gen,
706
+ test: regexp,
707
+ suffix: `.${gen.extensionPrefix}.ts`
708
+ });
709
+ this.extensionPrefixes.push(gen.extensionPrefix);
710
+ }
711
+ const extraInputFiles = [];
712
+ for (const gen of topLevelGenerators) {
713
+ const sf = gen.makeTopLevelShim();
714
+ sfExtensionData(sf).isTopLevelShim = true;
715
+ if (!gen.shouldEmit) {
716
+ this.ignoreForEmit.add(sf);
717
+ }
718
+ const fileName = absoluteFromSourceFile(sf);
719
+ this.shims.set(fileName, sf);
720
+ extraInputFiles.push(fileName);
721
+ }
722
+ for (const rootFile of tsRootFiles) {
723
+ for (const gen of this.generators) {
724
+ extraInputFiles.push(makeShimFileName(rootFile, gen.suffix));
725
+ }
726
+ }
727
+ this.extraInputFiles = extraInputFiles;
728
+ if (oldProgram !== null) {
729
+ for (const oldSf of oldProgram.getSourceFiles()) {
730
+ if (oldSf.isDeclarationFile || !isFileShimSourceFile(oldSf)) {
731
+ continue;
732
+ }
733
+ this.priorShims.set(absoluteFromSourceFile(oldSf), oldSf);
734
+ }
735
+ }
736
+ }
737
+ maybeGenerate(fileName) {
738
+ if (this.notShims.has(fileName)) {
739
+ return null;
740
+ } else if (this.shims.has(fileName)) {
741
+ return this.shims.get(fileName);
742
+ }
743
+ if (isDtsPath(fileName)) {
744
+ this.notShims.add(fileName);
745
+ return null;
746
+ }
747
+ for (const record of this.generators) {
748
+ const match = record.test.exec(fileName);
749
+ if (match === null) {
750
+ continue;
751
+ }
752
+ const prefix = match[1];
753
+ let baseFileName = absoluteFrom(prefix + ".ts");
754
+ if (!this.delegate.fileExists(baseFileName)) {
755
+ baseFileName = absoluteFrom(prefix + ".tsx");
756
+ if (!this.delegate.fileExists(baseFileName)) {
757
+ return void 0;
758
+ }
759
+ }
760
+ const inputFile = this.delegate.getSourceFile(baseFileName, ts6.ScriptTarget.Latest);
761
+ if (inputFile === void 0 || isShim(inputFile)) {
762
+ return void 0;
763
+ }
764
+ return this.generateSpecific(fileName, record.generator, inputFile);
765
+ }
766
+ this.notShims.add(fileName);
767
+ return null;
768
+ }
769
+ generateSpecific(fileName, generator, inputFile) {
770
+ let priorShimSf = null;
771
+ if (this.priorShims.has(fileName)) {
772
+ priorShimSf = this.priorShims.get(fileName);
773
+ this.priorShims.delete(fileName);
774
+ }
775
+ const shimSf = generator.generateShimForFile(inputFile, fileName, priorShimSf);
776
+ sfExtensionData(shimSf).fileShim = {
777
+ extension: generator.extensionPrefix,
778
+ generatedFrom: absoluteFromSourceFile(inputFile)
779
+ };
780
+ if (!generator.shouldEmit) {
781
+ this.ignoreForEmit.add(shimSf);
782
+ }
783
+ this.shims.set(fileName, shimSf);
784
+ return shimSf;
785
+ }
786
+ };
787
+
788
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/factory_generator.mjs
789
+ import ts7 from "typescript";
790
+ var TS_DTS_SUFFIX = /(\.d)?\.ts$/;
791
+ var STRIP_NG_FACTORY = /(.*)NgFactory$/;
792
+ var FactoryGenerator = class {
793
+ constructor() {
794
+ this.sourceInfo = /* @__PURE__ */ new Map();
795
+ this.sourceToFactorySymbols = /* @__PURE__ */ new Map();
796
+ this.shouldEmit = true;
797
+ this.extensionPrefix = "ngfactory";
798
+ }
799
+ generateShimForFile(sf, genFilePath) {
800
+ const absoluteSfPath = absoluteFromSourceFile(sf);
801
+ const relativePathToSource = "./" + basename(sf.fileName).replace(TS_DTS_SUFFIX, "");
802
+ const symbolNames = sf.statements.filter(ts7.isClassDeclaration).filter((decl) => isExported(decl) && decl.decorators !== void 0 && decl.name !== void 0).map((decl) => decl.name.text);
803
+ let sourceText = "";
804
+ const leadingComment = getFileoverviewComment(sf);
805
+ if (leadingComment !== null) {
806
+ sourceText = leadingComment + "\n\n";
807
+ }
808
+ if (symbolNames.length > 0) {
809
+ const varLines = symbolNames.map((name) => `export const ${name}NgFactory: i0.\u0275NgModuleFactory<any> = new i0.\u0275NgModuleFactory(${name});`);
810
+ sourceText += [
811
+ `import * as i0 from '@angular/core';`,
812
+ `import {${symbolNames.join(", ")}} from '${relativePathToSource}';`,
813
+ ...varLines
814
+ ].join("\n");
815
+ }
816
+ sourceText += "\nexport const \u0275NonEmptyModule = true;";
817
+ const genFile = ts7.createSourceFile(genFilePath, sourceText, sf.languageVersion, true, ts7.ScriptKind.TS);
818
+ if (sf.moduleName !== void 0) {
819
+ genFile.moduleName = generatedModuleName(sf.moduleName, sf.fileName, ".ngfactory");
820
+ }
821
+ const moduleSymbols = /* @__PURE__ */ new Map();
822
+ this.sourceToFactorySymbols.set(absoluteSfPath, moduleSymbols);
823
+ this.sourceInfo.set(genFilePath, {
824
+ sourceFilePath: absoluteSfPath,
825
+ moduleSymbols
826
+ });
827
+ return genFile;
828
+ }
829
+ track(sf, moduleInfo) {
830
+ if (this.sourceToFactorySymbols.has(sf.fileName)) {
831
+ this.sourceToFactorySymbols.get(sf.fileName).set(moduleInfo.name, moduleInfo);
832
+ }
833
+ }
834
+ };
835
+ function isExported(decl) {
836
+ return decl.modifiers !== void 0 && decl.modifiers.some((mod) => mod.kind == ts7.SyntaxKind.ExportKeyword);
837
+ }
838
+ function generatedFactoryTransform(factoryMap, importRewriter) {
839
+ return (context) => {
840
+ return (file) => {
841
+ return transformFactorySourceFile(factoryMap, context, importRewriter, file);
842
+ };
843
+ };
844
+ }
845
+ function transformFactorySourceFile(factoryMap, context, importRewriter, file) {
846
+ if (!factoryMap.has(file.fileName)) {
847
+ return file;
848
+ }
849
+ const { moduleSymbols, sourceFilePath } = factoryMap.get(file.fileName);
850
+ const transformedStatements = [];
851
+ let nonEmptyExport = null;
852
+ const coreImportIdentifiers = /* @__PURE__ */ new Set();
853
+ for (const stmt of file.statements) {
854
+ if (ts7.isImportDeclaration(stmt) && ts7.isStringLiteral(stmt.moduleSpecifier) && stmt.moduleSpecifier.text === "@angular/core") {
855
+ const rewrittenModuleSpecifier = importRewriter.rewriteSpecifier("@angular/core", sourceFilePath);
856
+ if (rewrittenModuleSpecifier !== stmt.moduleSpecifier.text) {
857
+ transformedStatements.push(ts7.updateImportDeclaration(stmt, stmt.decorators, stmt.modifiers, stmt.importClause, ts7.createStringLiteral(rewrittenModuleSpecifier), void 0));
858
+ if (stmt.importClause !== void 0 && stmt.importClause.namedBindings !== void 0 && ts7.isNamespaceImport(stmt.importClause.namedBindings)) {
859
+ coreImportIdentifiers.add(stmt.importClause.namedBindings.name.text);
860
+ }
861
+ } else {
862
+ transformedStatements.push(stmt);
863
+ }
864
+ } else if (ts7.isVariableStatement(stmt) && stmt.declarationList.declarations.length === 1) {
865
+ const decl = stmt.declarationList.declarations[0];
866
+ if (ts7.isIdentifier(decl.name)) {
867
+ if (decl.name.text === "\u0275NonEmptyModule") {
868
+ nonEmptyExport = stmt;
869
+ continue;
870
+ }
871
+ const match = STRIP_NG_FACTORY.exec(decl.name.text);
872
+ const module = match ? moduleSymbols.get(match[1]) : null;
873
+ if (module) {
874
+ const moduleIsTreeShakable = !module.hasId;
875
+ const newStmt = !moduleIsTreeShakable ? stmt : updateInitializers(stmt, (init) => init ? wrapInNoSideEffects(init) : void 0);
876
+ transformedStatements.push(newStmt);
877
+ }
878
+ } else {
879
+ transformedStatements.push(stmt);
880
+ }
881
+ } else {
882
+ transformedStatements.push(stmt);
883
+ }
884
+ }
885
+ if (!transformedStatements.some(ts7.isVariableStatement) && nonEmptyExport !== null) {
886
+ transformedStatements.push(nonEmptyExport);
887
+ }
888
+ file = ts7.updateSourceFileNode(file, transformedStatements);
889
+ if (coreImportIdentifiers.size > 0) {
890
+ const visit = (node) => {
891
+ node = ts7.visitEachChild(node, (child) => visit(child), context);
892
+ if (ts7.isPropertyAccessExpression(node) && ts7.isIdentifier(node.expression) && coreImportIdentifiers.has(node.expression.text)) {
893
+ const rewrittenSymbol = importRewriter.rewriteSymbol(node.name.text, "@angular/core");
894
+ if (rewrittenSymbol !== node.name.text) {
895
+ const updated = ts7.updatePropertyAccess(node, node.expression, ts7.createIdentifier(rewrittenSymbol));
896
+ node = updated;
897
+ }
898
+ }
899
+ return node;
900
+ };
901
+ file = visit(file);
902
+ }
903
+ return file;
904
+ }
905
+ function getFileoverviewComment(sourceFile) {
906
+ const text = sourceFile.getFullText();
907
+ const trivia = text.substring(0, sourceFile.getStart());
908
+ const leadingComments = ts7.getLeadingCommentRanges(trivia, 0);
909
+ if (!leadingComments || leadingComments.length === 0) {
910
+ return null;
911
+ }
912
+ const comment = leadingComments[0];
913
+ if (comment.kind !== ts7.SyntaxKind.MultiLineCommentTrivia) {
914
+ return null;
915
+ }
916
+ if (text.substring(comment.end, comment.end + 2) !== "\n\n") {
917
+ return null;
918
+ }
919
+ const commentText = text.substring(comment.pos, comment.end);
920
+ if (commentText.indexOf("@license") !== -1) {
921
+ return null;
922
+ }
923
+ return commentText;
924
+ }
925
+ function wrapInNoSideEffects(expr) {
926
+ const noSideEffects = ts7.createPropertyAccess(ts7.createIdentifier("i0"), "\u0275noSideEffects");
927
+ return ts7.createCall(noSideEffects, [], [
928
+ ts7.createFunctionExpression([], void 0, void 0, [], [], void 0, ts7.createBlock([
929
+ ts7.createReturn(expr)
930
+ ]))
931
+ ]);
932
+ }
933
+ function updateInitializers(stmt, update) {
934
+ return ts7.updateVariableStatement(stmt, stmt.modifiers, ts7.updateVariableDeclarationList(stmt.declarationList, stmt.declarationList.declarations.map((decl) => ts7.updateVariableDeclaration(decl, decl.name, decl.type, update(decl.initializer)))));
935
+ }
936
+
937
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/reference_tagger.mjs
938
+ var ShimReferenceTagger = class {
939
+ constructor(shimExtensions) {
940
+ this.tagged = /* @__PURE__ */ new Set();
941
+ this.enabled = true;
942
+ this.suffixes = shimExtensions.map((extension) => `.${extension}.ts`);
943
+ }
944
+ tag(sf) {
945
+ if (!this.enabled || sf.isDeclarationFile || isShim(sf) || this.tagged.has(sf) || !isNonDeclarationTsPath(sf.fileName)) {
946
+ return;
947
+ }
948
+ const ext = sfExtensionData(sf);
949
+ if (ext.originalReferencedFiles === null) {
950
+ ext.originalReferencedFiles = sf.referencedFiles;
951
+ }
952
+ const referencedFiles = [...ext.originalReferencedFiles];
953
+ const sfPath = absoluteFromSourceFile(sf);
954
+ for (const suffix of this.suffixes) {
955
+ referencedFiles.push({
956
+ fileName: makeShimFileName(sfPath, suffix),
957
+ pos: 0,
958
+ end: 0
959
+ });
960
+ }
961
+ ext.taggedReferenceFiles = referencedFiles;
962
+ sf.referencedFiles = referencedFiles;
963
+ this.tagged.add(sf);
964
+ }
965
+ finalize() {
966
+ this.enabled = false;
967
+ this.tagged.clear();
968
+ }
969
+ };
970
+
971
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/shims/src/summary_generator.mjs
972
+ import ts8 from "typescript";
973
+ var SummaryGenerator = class {
974
+ constructor() {
975
+ this.shouldEmit = true;
976
+ this.extensionPrefix = "ngsummary";
977
+ }
978
+ generateShimForFile(sf, genFilePath) {
979
+ const symbolNames = [];
980
+ for (const stmt of sf.statements) {
981
+ if (ts8.isClassDeclaration(stmt)) {
982
+ if (!isExported2(stmt) || stmt.decorators === void 0 || stmt.name === void 0) {
983
+ continue;
984
+ }
985
+ symbolNames.push(stmt.name.text);
986
+ } else if (ts8.isExportDeclaration(stmt)) {
987
+ if (stmt.exportClause === void 0 || stmt.moduleSpecifier !== void 0 || !ts8.isNamedExports(stmt.exportClause)) {
988
+ continue;
989
+ }
990
+ for (const specifier of stmt.exportClause.elements) {
991
+ symbolNames.push(specifier.name.text);
992
+ }
993
+ }
994
+ }
995
+ const varLines = symbolNames.map((name) => `export const ${name}NgSummary: any = null;`);
996
+ if (varLines.length === 0) {
997
+ varLines.push(`export const \u0275empty = null;`);
998
+ }
999
+ const sourceText = varLines.join("\n");
1000
+ const genFile = ts8.createSourceFile(genFilePath, sourceText, sf.languageVersion, true, ts8.ScriptKind.TS);
1001
+ if (sf.moduleName !== void 0) {
1002
+ genFile.moduleName = generatedModuleName(sf.moduleName, sf.fileName, ".ngsummary");
1003
+ }
1004
+ return genFile;
1005
+ }
1006
+ };
1007
+ function isExported2(decl) {
1008
+ return decl.modifiers !== void 0 && decl.modifiers.some((mod) => mod.kind == ts8.SyntaxKind.ExportKeyword);
1009
+ }
1010
+
1011
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/program_driver/src/ts_create_program_driver.mjs
620
1012
  var DelegatingCompilerHost = class {
621
1013
  constructor(delegate) {
622
1014
  this.delegate = delegate;
@@ -705,7 +1097,7 @@ var TsCreateProgramDriver = class {
705
1097
  this.sfMap.clear();
706
1098
  }
707
1099
  for (const [filePath, { newText, originalFile }] of contents.entries()) {
708
- const sf = ts6.createSourceFile(filePath, newText, ts6.ScriptTarget.Latest, true);
1100
+ const sf = ts9.createSourceFile(filePath, newText, ts9.ScriptTarget.Latest, true);
709
1101
  if (originalFile !== null) {
710
1102
  sf[NgOriginalFile] = originalFile;
711
1103
  }
@@ -714,7 +1106,7 @@ var TsCreateProgramDriver = class {
714
1106
  const host = new UpdatedProgramHost(this.sfMap, this.originalProgram, this.originalHost, this.shimExtensionPrefixes);
715
1107
  const oldProgram = this.program;
716
1108
  retagAllTsFiles(oldProgram);
717
- this.program = ts6.createProgram({
1109
+ this.program = ts9.createProgram({
718
1110
  host,
719
1111
  rootNames: this.program.getRootFileNames(),
720
1112
  options: this.options,
@@ -1343,7 +1735,7 @@ function generateAnalysis(context) {
1343
1735
  }
1344
1736
 
1345
1737
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/resource/src/loader.mjs
1346
- import ts7 from "typescript";
1738
+ import ts10 from "typescript";
1347
1739
  var CSS_PREPROCESSOR_EXT = /(\.scss|\.sass|\.less|\.styl)$/;
1348
1740
  var RESOURCE_MARKER = ".$ngresource$";
1349
1741
  var RESOURCE_MARKER_TS = RESOURCE_MARKER + ".ts";
@@ -1453,7 +1845,7 @@ var AdapterResourceLoader = class {
1453
1845
  return this.adapter.rootDirs.map((rootDir) => join(rootDir, segment));
1454
1846
  }
1455
1847
  getResolvedCandidateLocations(url, fromFile) {
1456
- const failedLookup = ts7.resolveModuleName(url + RESOURCE_MARKER, fromFile, this.options, this.lookupResolutionHost);
1848
+ const failedLookup = ts10.resolveModuleName(url + RESOURCE_MARKER, fromFile, this.options, this.lookupResolutionHost);
1457
1849
  if (failedLookup.failedLookupLocations === void 0) {
1458
1850
  throw new Error(`Internal error: expected to find failedLookupLocations during resolution of resource '${url}' in context of ${fromFile}`);
1459
1851
  }
@@ -1576,7 +1968,7 @@ var MetadataDtsModuleScopeResolver = class {
1576
1968
 
1577
1969
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/scope/src/local.mjs
1578
1970
  import { ExternalExpr } from "@angular/compiler";
1579
- import ts8 from "typescript";
1971
+ import ts11 from "typescript";
1580
1972
  var LocalModuleScopeRegistry = class {
1581
1973
  constructor(localReader, dependencyScopeReader, refEmitter, aliasingHost) {
1582
1974
  this.localReader = localReader;
@@ -1777,7 +2169,7 @@ var LocalModuleScopeRegistry = class {
1777
2169
  }
1778
2170
  getExportedScope(ref, diagnostics, ownerForErrors, type) {
1779
2171
  if (ref.node.getSourceFile().isDeclarationFile) {
1780
- if (!ts8.isClassDeclaration(ref.node)) {
2172
+ if (!ts11.isClassDeclaration(ref.node)) {
1781
2173
  const code = type === "import" ? ErrorCode.NGMODULE_INVALID_IMPORT : ErrorCode.NGMODULE_INVALID_EXPORT;
1782
2174
  diagnostics.push(makeDiagnostic(code, identifierOfNode(ref.node) || ref.node, `Appears in the NgModule.${type}s of ${nodeNameForError(ownerForErrors)}, but could not be resolved to an NgModule`));
1783
2175
  return "invalid";
@@ -1886,7 +2278,7 @@ function reexportCollision(module, refA, refB) {
1886
2278
 
1887
2279
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/scope/src/typecheck.mjs
1888
2280
  import { CssSelector, SelectorMatcher } from "@angular/compiler";
1889
- import ts9 from "typescript";
2281
+ import ts12 from "typescript";
1890
2282
  var TypeCheckScopeRegistry = class {
1891
2283
  constructor(scopeReader, metaReader) {
1892
2284
  this.scopeReader = scopeReader;
@@ -1919,8 +2311,8 @@ var TypeCheckScopeRegistry = class {
1919
2311
  }
1920
2312
  }
1921
2313
  for (const { name, ref } of scope.compilation.pipes) {
1922
- if (!ts9.isClassDeclaration(ref.node)) {
1923
- throw new Error(`Unexpected non-class declaration ${ts9.SyntaxKind[ref.node.kind]} for pipe ${ref.debugName}`);
2314
+ if (!ts12.isClassDeclaration(ref.node)) {
2315
+ throw new Error(`Unexpected non-class declaration ${ts12.SyntaxKind[ref.node.kind]} for pipe ${ref.debugName}`);
1924
2316
  }
1925
2317
  pipes.set(name, ref);
1926
2318
  }
@@ -1949,7 +2341,7 @@ var TypeCheckScopeRegistry = class {
1949
2341
  import { CssSelector as CssSelector2, DomElementSchemaRegistry as DomElementSchemaRegistry2 } from "@angular/compiler";
1950
2342
 
1951
2343
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/diagnostics/src/diagnostic.mjs
1952
- import ts10 from "typescript";
2344
+ import ts13 from "typescript";
1953
2345
  function makeTemplateDiagnostic(templateId, mapping, span, category, code, messageText, relatedMessages) {
1954
2346
  if (mapping.type === "direct") {
1955
2347
  let relatedInformation = void 0;
@@ -1957,7 +2349,7 @@ function makeTemplateDiagnostic(templateId, mapping, span, category, code, messa
1957
2349
  relatedInformation = [];
1958
2350
  for (const relatedMessage of relatedMessages) {
1959
2351
  relatedInformation.push({
1960
- category: ts10.DiagnosticCategory.Message,
2352
+ category: ts13.DiagnosticCategory.Message,
1961
2353
  code: 0,
1962
2354
  file: relatedMessage.sourceFile,
1963
2355
  start: relatedMessage.start,
@@ -1982,12 +2374,12 @@ function makeTemplateDiagnostic(templateId, mapping, span, category, code, messa
1982
2374
  const componentSf = mapping.componentClass.getSourceFile();
1983
2375
  const componentName = mapping.componentClass.name.text;
1984
2376
  const fileName = mapping.type === "indirect" ? `${componentSf.fileName} (${componentName} template)` : mapping.templateUrl;
1985
- const sf = ts10.createSourceFile(fileName, mapping.template, ts10.ScriptTarget.Latest, false, ts10.ScriptKind.JSX);
2377
+ const sf = ts13.createSourceFile(fileName, mapping.template, ts13.ScriptTarget.Latest, false, ts13.ScriptKind.JSX);
1986
2378
  let relatedInformation = [];
1987
2379
  if (relatedMessages !== void 0) {
1988
2380
  for (const relatedMessage of relatedMessages) {
1989
2381
  relatedInformation.push({
1990
- category: ts10.DiagnosticCategory.Message,
2382
+ category: ts13.DiagnosticCategory.Message,
1991
2383
  code: 0,
1992
2384
  file: relatedMessage.sourceFile,
1993
2385
  start: relatedMessage.start,
@@ -1997,7 +2389,7 @@ function makeTemplateDiagnostic(templateId, mapping, span, category, code, messa
1997
2389
  }
1998
2390
  }
1999
2391
  relatedInformation.push({
2000
- category: ts10.DiagnosticCategory.Message,
2392
+ category: ts13.DiagnosticCategory.Message,
2001
2393
  code: 0,
2002
2394
  file: componentSf,
2003
2395
  start: mapping.node.getStart(),
@@ -2040,15 +2432,15 @@ function allocateTemplateId(sf) {
2040
2432
 
2041
2433
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/completion.mjs
2042
2434
  import { EmptyExpr, ImplicitReceiver as ImplicitReceiver2, PropertyRead as PropertyRead2, PropertyWrite as PropertyWrite2, SafePropertyRead, TmplAstReference as TmplAstReference2, TmplAstTextAttribute } from "@angular/compiler";
2043
- import ts12 from "typescript";
2435
+ import ts15 from "typescript";
2044
2436
 
2045
2437
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/comments.mjs
2046
2438
  import { AbsoluteSourceSpan as AbsoluteSourceSpan2 } from "@angular/compiler";
2047
- import ts11 from "typescript";
2439
+ import ts14 from "typescript";
2048
2440
  var parseSpanComment = /^(\d+),(\d+)$/;
2049
2441
  function readSpanComment(node, sourceFile = node.getSourceFile()) {
2050
- return ts11.forEachTrailingCommentRange(sourceFile.text, node.getEnd(), (pos, end, kind) => {
2051
- if (kind !== ts11.SyntaxKind.MultiLineCommentTrivia) {
2442
+ return ts14.forEachTrailingCommentRange(sourceFile.text, node.getEnd(), (pos, end, kind) => {
2443
+ if (kind !== ts14.SyntaxKind.MultiLineCommentTrivia) {
2052
2444
  return null;
2053
2445
  }
2054
2446
  const commentText = sourceFile.text.substring(pos + 2, end - 2);
@@ -2071,15 +2463,15 @@ var ExpressionIdentifier;
2071
2463
  ExpressionIdentifier2["EVENT_PARAMETER"] = "EP";
2072
2464
  })(ExpressionIdentifier || (ExpressionIdentifier = {}));
2073
2465
  function addExpressionIdentifier(node, identifier) {
2074
- ts11.addSyntheticTrailingComment(node, ts11.SyntaxKind.MultiLineCommentTrivia, `${CommentTriviaType.EXPRESSION_TYPE_IDENTIFIER}:${identifier}`, false);
2466
+ ts14.addSyntheticTrailingComment(node, ts14.SyntaxKind.MultiLineCommentTrivia, `${CommentTriviaType.EXPRESSION_TYPE_IDENTIFIER}:${identifier}`, false);
2075
2467
  }
2076
2468
  var IGNORE_FOR_DIAGNOSTICS_MARKER = `${CommentTriviaType.DIAGNOSTIC}:ignore`;
2077
2469
  function markIgnoreDiagnostics(node) {
2078
- ts11.addSyntheticTrailingComment(node, ts11.SyntaxKind.MultiLineCommentTrivia, IGNORE_FOR_DIAGNOSTICS_MARKER, false);
2470
+ ts14.addSyntheticTrailingComment(node, ts14.SyntaxKind.MultiLineCommentTrivia, IGNORE_FOR_DIAGNOSTICS_MARKER, false);
2079
2471
  }
2080
2472
  function hasIgnoreForDiagnosticsMarker(node, sourceFile) {
2081
- return ts11.forEachTrailingCommentRange(sourceFile.text, node.getEnd(), (pos, end, kind) => {
2082
- if (kind !== ts11.SyntaxKind.MultiLineCommentTrivia) {
2473
+ return ts14.forEachTrailingCommentRange(sourceFile.text, node.getEnd(), (pos, end, kind) => {
2474
+ if (kind !== ts14.SyntaxKind.MultiLineCommentTrivia) {
2083
2475
  return null;
2084
2476
  }
2085
2477
  const commentText = sourceFile.text.substring(pos + 2, end - 2);
@@ -2153,8 +2545,8 @@ function findAllMatchingNodes(tcb, opts) {
2153
2545
  return results;
2154
2546
  }
2155
2547
  function hasExpressionIdentifier(sourceFile, node, identifier) {
2156
- return ts11.forEachTrailingCommentRange(sourceFile.text, node.getEnd(), (pos, end, kind) => {
2157
- if (kind !== ts11.SyntaxKind.MultiLineCommentTrivia) {
2548
+ return ts14.forEachTrailingCommentRange(sourceFile.text, node.getEnd(), (pos, end, kind) => {
2549
+ if (kind !== ts14.SyntaxKind.MultiLineCommentTrivia) {
2158
2550
  return false;
2159
2551
  }
2160
2552
  const commentText = sourceFile.text.substring(pos + 2, end - 2);
@@ -2172,7 +2564,7 @@ var CompletionEngine = class {
2172
2564
  this.templateContextCache = /* @__PURE__ */ new Map();
2173
2565
  this.expressionCompletionCache = /* @__PURE__ */ new Map();
2174
2566
  const globalRead = findFirstMatchingNode(this.tcb, {
2175
- filter: ts12.isPropertyAccessExpression,
2567
+ filter: ts15.isPropertyAccessExpression,
2176
2568
  withExpressionIdentifier: ExpressionIdentifier.COMPONENT_COMPLETION
2177
2569
  });
2178
2570
  if (globalRead !== null) {
@@ -2196,7 +2588,7 @@ var CompletionEngine = class {
2196
2588
  let nodeContext = null;
2197
2589
  if (node instanceof EmptyExpr) {
2198
2590
  const nodeLocation = findFirstMatchingNode(this.tcb, {
2199
- filter: ts12.isIdentifier,
2591
+ filter: ts15.isIdentifier,
2200
2592
  withSpan: node.sourceSpan
2201
2593
  });
2202
2594
  if (nodeLocation !== null) {
@@ -2209,7 +2601,7 @@ var CompletionEngine = class {
2209
2601
  }
2210
2602
  if (node instanceof PropertyRead2 && node.receiver instanceof ImplicitReceiver2) {
2211
2603
  const nodeLocation = findFirstMatchingNode(this.tcb, {
2212
- filter: ts12.isPropertyAccessExpression,
2604
+ filter: ts15.isPropertyAccessExpression,
2213
2605
  withSpan: node.sourceSpan
2214
2606
  });
2215
2607
  if (nodeLocation) {
@@ -2233,21 +2625,21 @@ var CompletionEngine = class {
2233
2625
  let tsExpr = null;
2234
2626
  if (expr instanceof PropertyRead2 || expr instanceof PropertyWrite2) {
2235
2627
  tsExpr = findFirstMatchingNode(this.tcb, {
2236
- filter: ts12.isPropertyAccessExpression,
2628
+ filter: ts15.isPropertyAccessExpression,
2237
2629
  withSpan: expr.nameSpan
2238
2630
  });
2239
2631
  } else if (expr instanceof SafePropertyRead) {
2240
2632
  const ternaryExpr = findFirstMatchingNode(this.tcb, {
2241
- filter: ts12.isParenthesizedExpression,
2633
+ filter: ts15.isParenthesizedExpression,
2242
2634
  withSpan: expr.sourceSpan
2243
2635
  });
2244
- if (ternaryExpr === null || !ts12.isConditionalExpression(ternaryExpr.expression)) {
2636
+ if (ternaryExpr === null || !ts15.isConditionalExpression(ternaryExpr.expression)) {
2245
2637
  return null;
2246
2638
  }
2247
2639
  const whenTrue = ternaryExpr.expression.whenTrue;
2248
- if (ts12.isPropertyAccessExpression(whenTrue)) {
2640
+ if (ts15.isPropertyAccessExpression(whenTrue)) {
2249
2641
  tsExpr = whenTrue;
2250
- } else if (ts12.isCallExpression(whenTrue) && ts12.isPropertyAccessExpression(whenTrue.expression)) {
2642
+ } else if (ts15.isCallExpression(whenTrue) && ts15.isPropertyAccessExpression(whenTrue.expression)) {
2251
2643
  tsExpr = whenTrue.expression;
2252
2644
  }
2253
2645
  }
@@ -2269,15 +2661,15 @@ var CompletionEngine = class {
2269
2661
  let tsExpr = null;
2270
2662
  if (expr instanceof TmplAstTextAttribute) {
2271
2663
  const strNode = findFirstMatchingNode(this.tcb, {
2272
- filter: ts12.isParenthesizedExpression,
2664
+ filter: ts15.isParenthesizedExpression,
2273
2665
  withSpan: expr.sourceSpan
2274
2666
  });
2275
- if (strNode !== null && ts12.isStringLiteral(strNode.expression)) {
2667
+ if (strNode !== null && ts15.isStringLiteral(strNode.expression)) {
2276
2668
  tsExpr = strNode.expression;
2277
2669
  }
2278
2670
  } else {
2279
2671
  tsExpr = findFirstMatchingNode(this.tcb, {
2280
- filter: (n) => ts12.isStringLiteral(n) || ts12.isNumericLiteral(n),
2672
+ filter: (n) => ts15.isStringLiteral(n) || ts15.isNumericLiteral(n),
2281
2673
  withSpan: expr.sourceSpan
2282
2674
  });
2283
2675
  }
@@ -2285,7 +2677,7 @@ var CompletionEngine = class {
2285
2677
  return null;
2286
2678
  }
2287
2679
  let positionInShimFile = tsExpr.getEnd();
2288
- if (ts12.isStringLiteral(tsExpr)) {
2680
+ if (ts15.isStringLiteral(tsExpr)) {
2289
2681
  positionInShimFile -= 1;
2290
2682
  }
2291
2683
  const res = {
@@ -2320,11 +2712,11 @@ var CompletionEngine = class {
2320
2712
  };
2321
2713
 
2322
2714
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/context.mjs
2323
- import ts26 from "typescript";
2715
+ import ts29 from "typescript";
2324
2716
 
2325
2717
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/dom.mjs
2326
2718
  import { DomElementSchemaRegistry } from "@angular/compiler";
2327
- import ts13 from "typescript";
2719
+ import ts16 from "typescript";
2328
2720
  var REGISTRY = new DomElementSchemaRegistry();
2329
2721
  var REMOVE_XHTML_REGEX = /^:xhtml:/;
2330
2722
  var RegistryDomSchemaChecker = class {
@@ -2348,7 +2740,7 @@ var RegistryDomSchemaChecker = class {
2348
2740
  } else {
2349
2741
  errorMsg += `2. To allow any element add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.`;
2350
2742
  }
2351
- const diag = makeTemplateDiagnostic(id, mapping, element.startSourceSpan, ts13.DiagnosticCategory.Error, ngErrorCode(ErrorCode.SCHEMA_INVALID_ELEMENT), errorMsg);
2743
+ const diag = makeTemplateDiagnostic(id, mapping, element.startSourceSpan, ts16.DiagnosticCategory.Error, ngErrorCode(ErrorCode.SCHEMA_INVALID_ELEMENT), errorMsg);
2352
2744
  this._diagnostics.push(diag);
2353
2745
  }
2354
2746
  }
@@ -2366,7 +2758,7 @@ var RegistryDomSchemaChecker = class {
2366
2758
  2. If '${element.name}' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
2367
2759
  3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.`;
2368
2760
  }
2369
- const diag = makeTemplateDiagnostic(id, mapping, span, ts13.DiagnosticCategory.Error, ngErrorCode(ErrorCode.SCHEMA_INVALID_ATTRIBUTE), errorMsg);
2761
+ const diag = makeTemplateDiagnostic(id, mapping, span, ts16.DiagnosticCategory.Error, ngErrorCode(ErrorCode.SCHEMA_INVALID_ATTRIBUTE), errorMsg);
2370
2762
  this._diagnostics.push(diag);
2371
2763
  }
2372
2764
  }
@@ -2374,62 +2766,62 @@ var RegistryDomSchemaChecker = class {
2374
2766
 
2375
2767
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/environment.mjs
2376
2768
  import { ExpressionType, ExternalExpr as ExternalExpr2, TypeModifier } from "@angular/compiler";
2377
- import ts19 from "typescript";
2769
+ import ts22 from "typescript";
2378
2770
 
2379
2771
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/ts_util.mjs
2380
- import ts14 from "typescript";
2772
+ import ts17 from "typescript";
2381
2773
  var SAFE_TO_CAST_WITHOUT_PARENS = /* @__PURE__ */ new Set([
2382
- ts14.SyntaxKind.ParenthesizedExpression,
2383
- ts14.SyntaxKind.Identifier,
2384
- ts14.SyntaxKind.CallExpression,
2385
- ts14.SyntaxKind.NonNullExpression,
2386
- ts14.SyntaxKind.ElementAccessExpression,
2387
- ts14.SyntaxKind.PropertyAccessExpression,
2388
- ts14.SyntaxKind.ArrayLiteralExpression,
2389
- ts14.SyntaxKind.ObjectLiteralExpression,
2390
- ts14.SyntaxKind.StringLiteral,
2391
- ts14.SyntaxKind.NumericLiteral,
2392
- ts14.SyntaxKind.TrueKeyword,
2393
- ts14.SyntaxKind.FalseKeyword,
2394
- ts14.SyntaxKind.NullKeyword,
2395
- ts14.SyntaxKind.UndefinedKeyword
2774
+ ts17.SyntaxKind.ParenthesizedExpression,
2775
+ ts17.SyntaxKind.Identifier,
2776
+ ts17.SyntaxKind.CallExpression,
2777
+ ts17.SyntaxKind.NonNullExpression,
2778
+ ts17.SyntaxKind.ElementAccessExpression,
2779
+ ts17.SyntaxKind.PropertyAccessExpression,
2780
+ ts17.SyntaxKind.ArrayLiteralExpression,
2781
+ ts17.SyntaxKind.ObjectLiteralExpression,
2782
+ ts17.SyntaxKind.StringLiteral,
2783
+ ts17.SyntaxKind.NumericLiteral,
2784
+ ts17.SyntaxKind.TrueKeyword,
2785
+ ts17.SyntaxKind.FalseKeyword,
2786
+ ts17.SyntaxKind.NullKeyword,
2787
+ ts17.SyntaxKind.UndefinedKeyword
2396
2788
  ]);
2397
2789
  function tsCastToAny(expr) {
2398
2790
  if (!SAFE_TO_CAST_WITHOUT_PARENS.has(expr.kind)) {
2399
- expr = ts14.createParen(expr);
2791
+ expr = ts17.createParen(expr);
2400
2792
  }
2401
- return ts14.createParen(ts14.createAsExpression(expr, ts14.createKeywordTypeNode(ts14.SyntaxKind.AnyKeyword)));
2793
+ return ts17.createParen(ts17.createAsExpression(expr, ts17.createKeywordTypeNode(ts17.SyntaxKind.AnyKeyword)));
2402
2794
  }
2403
2795
  function tsCreateElement(tagName) {
2404
- const createElement = ts14.createPropertyAccess(ts14.createIdentifier("document"), "createElement");
2405
- return ts14.createCall(createElement, void 0, [ts14.createLiteral(tagName)]);
2796
+ const createElement = ts17.createPropertyAccess(ts17.createIdentifier("document"), "createElement");
2797
+ return ts17.createCall(createElement, void 0, [ts17.createLiteral(tagName)]);
2406
2798
  }
2407
2799
  function tsDeclareVariable(id, type) {
2408
- const decl = ts14.createVariableDeclaration(id, type, ts14.createNonNullExpression(ts14.createNull()));
2409
- return ts14.createVariableStatement(void 0, [decl]);
2800
+ const decl = ts17.createVariableDeclaration(id, type, ts17.createNonNullExpression(ts17.createNull()));
2801
+ return ts17.createVariableStatement(void 0, [decl]);
2410
2802
  }
2411
2803
  function tsCreateTypeQueryForCoercedInput(typeName, coercedInputName) {
2412
- return ts14.createTypeQueryNode(ts14.createQualifiedName(typeName, `ngAcceptInputType_${coercedInputName}`));
2804
+ return ts17.createTypeQueryNode(ts17.createQualifiedName(typeName, `ngAcceptInputType_${coercedInputName}`));
2413
2805
  }
2414
2806
  function tsCreateVariable(id, initializer) {
2415
- const decl = ts14.createVariableDeclaration(id, void 0, initializer);
2416
- return ts14.createVariableStatement(void 0, [decl]);
2807
+ const decl = ts17.createVariableDeclaration(id, void 0, initializer);
2808
+ return ts17.createVariableStatement(void 0, [decl]);
2417
2809
  }
2418
2810
  function tsCallMethod(receiver, methodName, args = []) {
2419
- const methodAccess = ts14.createPropertyAccess(receiver, methodName);
2420
- return ts14.createCall(methodAccess, void 0, args);
2811
+ const methodAccess = ts17.createPropertyAccess(receiver, methodName);
2812
+ return ts17.createCall(methodAccess, void 0, args);
2421
2813
  }
2422
2814
  function checkIfClassIsExported(node) {
2423
- if (node.modifiers !== void 0 && node.modifiers.some((mod) => mod.kind === ts14.SyntaxKind.ExportKeyword)) {
2815
+ if (node.modifiers !== void 0 && node.modifiers.some((mod) => mod.kind === ts17.SyntaxKind.ExportKeyword)) {
2424
2816
  return true;
2425
- } else if (node.parent !== void 0 && ts14.isSourceFile(node.parent) && checkIfFileHasExport(node.parent, node.name.text)) {
2817
+ } else if (node.parent !== void 0 && ts17.isSourceFile(node.parent) && checkIfFileHasExport(node.parent, node.name.text)) {
2426
2818
  return true;
2427
2819
  }
2428
2820
  return false;
2429
2821
  }
2430
2822
  function checkIfFileHasExport(sf, name) {
2431
2823
  for (const stmt of sf.statements) {
2432
- if (ts14.isExportDeclaration(stmt) && stmt.exportClause !== void 0 && ts14.isNamedExports(stmt.exportClause)) {
2824
+ if (ts17.isExportDeclaration(stmt) && stmt.exportClause !== void 0 && ts17.isNamedExports(stmt.exportClause)) {
2433
2825
  for (const element of stmt.exportClause.elements) {
2434
2826
  if (element.propertyName === void 0 && element.name.text === name) {
2435
2827
  return true;
@@ -2442,20 +2834,20 @@ function checkIfFileHasExport(sf, name) {
2442
2834
  return false;
2443
2835
  }
2444
2836
  function isAccessExpression(node) {
2445
- return ts14.isPropertyAccessExpression(node) || ts14.isElementAccessExpression(node);
2837
+ return ts17.isPropertyAccessExpression(node) || ts17.isElementAccessExpression(node);
2446
2838
  }
2447
2839
 
2448
2840
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/type_constructor.mjs
2449
- import ts18 from "typescript";
2841
+ import ts21 from "typescript";
2450
2842
 
2451
2843
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/tcb_util.mjs
2452
- import ts17 from "typescript";
2844
+ import ts20 from "typescript";
2453
2845
 
2454
2846
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/type_parameter_emitter.mjs
2455
- import ts16 from "typescript";
2847
+ import ts19 from "typescript";
2456
2848
 
2457
2849
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/type_emitter.mjs
2458
- import ts15 from "typescript";
2850
+ import ts18 from "typescript";
2459
2851
  var INELIGIBLE = {};
2460
2852
  function canEmitType(type, canEmit) {
2461
2853
  return canEmitTypeWorker(type);
@@ -2463,13 +2855,13 @@ function canEmitType(type, canEmit) {
2463
2855
  return visitNode(type2) !== INELIGIBLE;
2464
2856
  }
2465
2857
  function visitNode(node) {
2466
- if (ts15.isImportTypeNode(node)) {
2858
+ if (ts18.isImportTypeNode(node)) {
2467
2859
  return INELIGIBLE;
2468
2860
  }
2469
- if (ts15.isTypeReferenceNode(node) && !canEmitTypeReference(node)) {
2861
+ if (ts18.isTypeReferenceNode(node) && !canEmitTypeReference(node)) {
2470
2862
  return INELIGIBLE;
2471
2863
  } else {
2472
- return ts15.forEachChild(node, visitNode);
2864
+ return ts18.forEachChild(node, visitNode);
2473
2865
  }
2474
2866
  }
2475
2867
  function canEmitTypeReference(type2) {
@@ -2486,22 +2878,22 @@ var TypeEmitter = class {
2486
2878
  emitType(type) {
2487
2879
  const typeReferenceTransformer = (context) => {
2488
2880
  const visitNode = (node) => {
2489
- if (ts15.isImportTypeNode(node)) {
2881
+ if (ts18.isImportTypeNode(node)) {
2490
2882
  throw new Error("Unable to emit import type");
2491
2883
  }
2492
- if (ts15.isTypeReferenceNode(node)) {
2884
+ if (ts18.isTypeReferenceNode(node)) {
2493
2885
  return this.emitTypeReference(node);
2494
- } else if (ts15.isLiteralExpression(node)) {
2495
- const clone = ts15.getMutableClone(node);
2496
- ts15.setTextRange(clone, { pos: -1, end: -1 });
2886
+ } else if (ts18.isLiteralExpression(node)) {
2887
+ const clone = ts18.getMutableClone(node);
2888
+ ts18.setTextRange(clone, { pos: -1, end: -1 });
2497
2889
  return clone;
2498
2890
  } else {
2499
- return ts15.visitEachChild(node, visitNode, context);
2891
+ return ts18.visitEachChild(node, visitNode, context);
2500
2892
  }
2501
2893
  };
2502
- return (node) => ts15.visitNode(node, visitNode);
2894
+ return (node) => ts18.visitNode(node, visitNode);
2503
2895
  };
2504
- return ts15.transform(type, [typeReferenceTransformer]).transformed[0];
2896
+ return ts18.transform(type, [typeReferenceTransformer]).transformed[0];
2505
2897
  }
2506
2898
  emitTypeReference(type) {
2507
2899
  const translatedType = this.translator(type);
@@ -2510,9 +2902,9 @@ var TypeEmitter = class {
2510
2902
  }
2511
2903
  let typeArguments = void 0;
2512
2904
  if (type.typeArguments !== void 0) {
2513
- typeArguments = ts15.createNodeArray(type.typeArguments.map((typeArg) => this.emitType(typeArg)));
2905
+ typeArguments = ts18.createNodeArray(type.typeArguments.map((typeArg) => this.emitType(typeArg)));
2514
2906
  }
2515
- return ts15.updateTypeReferenceNode(type, translatedType.typeName, typeArguments);
2907
+ return ts18.updateTypeReferenceNode(type, translatedType.typeName, typeArguments);
2516
2908
  }
2517
2909
  };
2518
2910
 
@@ -2553,11 +2945,11 @@ var TypeParameterEmitter = class {
2553
2945
  return this.typeParameters.map((typeParam) => {
2554
2946
  const constraint = typeParam.constraint !== void 0 ? emitter.emitType(typeParam.constraint) : void 0;
2555
2947
  const defaultType = typeParam.default !== void 0 ? emitter.emitType(typeParam.default) : void 0;
2556
- return ts16.updateTypeParameterDeclaration(typeParam, typeParam.name, constraint, defaultType);
2948
+ return ts19.updateTypeParameterDeclaration(typeParam, typeParam.name, constraint, defaultType);
2557
2949
  });
2558
2950
  }
2559
2951
  resolveTypeReference(type) {
2560
- const target = ts16.isIdentifier(type.typeName) ? type.typeName : type.typeName.right;
2952
+ const target = ts19.isIdentifier(type.typeName) ? type.typeName : type.typeName.right;
2561
2953
  const declaration = this.reflector.getDeclarationOfIdentifier(target);
2562
2954
  if (declaration === null || declaration.node === null) {
2563
2955
  return null;
@@ -2583,8 +2975,8 @@ var TypeParameterEmitter = class {
2583
2975
  if (typeNode === null) {
2584
2976
  return null;
2585
2977
  }
2586
- if (!ts16.isTypeReferenceNode(typeNode)) {
2587
- throw new Error(`Expected TypeReferenceNode for emitted reference, got ${ts16.SyntaxKind[typeNode.kind]}.`);
2978
+ if (!ts19.isTypeReferenceNode(typeNode)) {
2979
+ throw new Error(`Expected TypeReferenceNode for emitted reference, got ${ts19.SyntaxKind[typeNode.kind]}.`);
2588
2980
  }
2589
2981
  return typeNode;
2590
2982
  }
@@ -2626,14 +3018,14 @@ function getTemplateMapping(shimSf, position, resolver, isDiagnosticRequest) {
2626
3018
  }
2627
3019
  function findTypeCheckBlock(file, id, isDiagnosticRequest) {
2628
3020
  for (const stmt of file.statements) {
2629
- if (ts17.isFunctionDeclaration(stmt) && getTemplateId2(stmt, file, isDiagnosticRequest) === id) {
3021
+ if (ts20.isFunctionDeclaration(stmt) && getTemplateId2(stmt, file, isDiagnosticRequest) === id) {
2630
3022
  return stmt;
2631
3023
  }
2632
3024
  }
2633
3025
  return null;
2634
3026
  }
2635
3027
  function findSourceLocation(node, sourceFile, isDiagnosticsRequest) {
2636
- while (node !== void 0 && !ts17.isFunctionDeclaration(node)) {
3028
+ while (node !== void 0 && !ts20.isFunctionDeclaration(node)) {
2637
3029
  if (hasIgnoreForDiagnosticsMarker(node, sourceFile) && isDiagnosticsRequest) {
2638
3030
  return null;
2639
3031
  }
@@ -2650,7 +3042,7 @@ function findSourceLocation(node, sourceFile, isDiagnosticsRequest) {
2650
3042
  return null;
2651
3043
  }
2652
3044
  function getTemplateId2(node, sourceFile, isDiagnosticRequest) {
2653
- while (!ts17.isFunctionDeclaration(node)) {
3045
+ while (!ts20.isFunctionDeclaration(node)) {
2654
3046
  if (hasIgnoreForDiagnosticsMarker(node, sourceFile) && isDiagnosticRequest) {
2655
3047
  return null;
2656
3048
  }
@@ -2660,8 +3052,8 @@ function getTemplateId2(node, sourceFile, isDiagnosticRequest) {
2660
3052
  }
2661
3053
  }
2662
3054
  const start = node.getFullStart();
2663
- return ts17.forEachLeadingCommentRange(sourceFile.text, start, (pos, end, kind) => {
2664
- if (kind !== ts17.SyntaxKind.MultiLineCommentTrivia) {
3055
+ return ts20.forEachLeadingCommentRange(sourceFile.text, start, (pos, end, kind) => {
3056
+ if (kind !== ts20.SyntaxKind.MultiLineCommentTrivia) {
2665
3057
  return null;
2666
3058
  }
2667
3059
  const commentText = sourceFile.text.substring(pos + 2, end - 2);
@@ -2676,29 +3068,29 @@ function checkIfGenericTypeBoundsCanBeEmitted(node, reflector, env) {
2676
3068
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/type_constructor.mjs
2677
3069
  function generateTypeCtorDeclarationFn(node, meta, nodeTypeRef, typeParams) {
2678
3070
  const rawTypeArgs = typeParams !== void 0 ? generateGenericArgs(typeParams) : void 0;
2679
- const rawType = ts18.createTypeReferenceNode(nodeTypeRef, rawTypeArgs);
3071
+ const rawType = ts21.createTypeReferenceNode(nodeTypeRef, rawTypeArgs);
2680
3072
  const initParam = constructTypeCtorParameter(node, meta, rawType);
2681
3073
  const typeParameters = typeParametersWithDefaultTypes(typeParams);
2682
3074
  if (meta.body) {
2683
- const fnType = ts18.createFunctionTypeNode(typeParameters, [initParam], rawType);
2684
- const decl = ts18.createVariableDeclaration(meta.fnName, fnType, ts18.createNonNullExpression(ts18.createNull()));
2685
- const declList = ts18.createVariableDeclarationList([decl], ts18.NodeFlags.Const);
2686
- return ts18.createVariableStatement(void 0, declList);
3075
+ const fnType = ts21.createFunctionTypeNode(typeParameters, [initParam], rawType);
3076
+ const decl = ts21.createVariableDeclaration(meta.fnName, fnType, ts21.createNonNullExpression(ts21.createNull()));
3077
+ const declList = ts21.createVariableDeclarationList([decl], ts21.NodeFlags.Const);
3078
+ return ts21.createVariableStatement(void 0, declList);
2687
3079
  } else {
2688
- return ts18.createFunctionDeclaration(void 0, [ts18.createModifier(ts18.SyntaxKind.DeclareKeyword)], void 0, meta.fnName, typeParameters, [initParam], rawType, void 0);
3080
+ return ts21.createFunctionDeclaration(void 0, [ts21.createModifier(ts21.SyntaxKind.DeclareKeyword)], void 0, meta.fnName, typeParameters, [initParam], rawType, void 0);
2689
3081
  }
2690
3082
  }
2691
3083
  function generateInlineTypeCtor(node, meta) {
2692
3084
  const rawTypeArgs = node.typeParameters !== void 0 ? generateGenericArgs(node.typeParameters) : void 0;
2693
- const rawType = ts18.createTypeReferenceNode(node.name, rawTypeArgs);
3085
+ const rawType = ts21.createTypeReferenceNode(node.name, rawTypeArgs);
2694
3086
  const initParam = constructTypeCtorParameter(node, meta, rawType);
2695
3087
  let body = void 0;
2696
3088
  if (meta.body) {
2697
- body = ts18.createBlock([
2698
- ts18.createReturn(ts18.createNonNullExpression(ts18.createNull()))
3089
+ body = ts21.createBlock([
3090
+ ts21.createReturn(ts21.createNonNullExpression(ts21.createNull()))
2699
3091
  ]);
2700
3092
  }
2701
- return ts18.createMethod(void 0, [ts18.createModifier(ts18.SyntaxKind.StaticKeyword)], void 0, meta.fnName, void 0, typeParametersWithDefaultTypes(node.typeParameters), [initParam], rawType, body);
3093
+ return ts21.createMethod(void 0, [ts21.createModifier(ts21.SyntaxKind.StaticKeyword)], void 0, meta.fnName, void 0, typeParametersWithDefaultTypes(node.typeParameters), [initParam], rawType, body);
2702
3094
  }
2703
3095
  function constructTypeCtorParameter(node, meta, rawType) {
2704
3096
  let initType = null;
@@ -2707,26 +3099,26 @@ function constructTypeCtorParameter(node, meta, rawType) {
2707
3099
  const coercedKeys = [];
2708
3100
  for (const key of keys) {
2709
3101
  if (!meta.coercedInputFields.has(key)) {
2710
- plainKeys.push(ts18.createLiteralTypeNode(ts18.createStringLiteral(key)));
3102
+ plainKeys.push(ts21.createLiteralTypeNode(ts21.createStringLiteral(key)));
2711
3103
  } else {
2712
- coercedKeys.push(ts18.createPropertySignature(void 0, key, void 0, tsCreateTypeQueryForCoercedInput(rawType.typeName, key), void 0));
3104
+ coercedKeys.push(ts21.createPropertySignature(void 0, key, void 0, tsCreateTypeQueryForCoercedInput(rawType.typeName, key), void 0));
2713
3105
  }
2714
3106
  }
2715
3107
  if (plainKeys.length > 0) {
2716
- const keyTypeUnion = ts18.createUnionTypeNode(plainKeys);
2717
- initType = ts18.createTypeReferenceNode("Pick", [rawType, keyTypeUnion]);
3108
+ const keyTypeUnion = ts21.createUnionTypeNode(plainKeys);
3109
+ initType = ts21.createTypeReferenceNode("Pick", [rawType, keyTypeUnion]);
2718
3110
  }
2719
3111
  if (coercedKeys.length > 0) {
2720
- const coercedLiteral = ts18.createTypeLiteralNode(coercedKeys);
2721
- initType = initType !== null ? ts18.createIntersectionTypeNode([initType, coercedLiteral]) : coercedLiteral;
3112
+ const coercedLiteral = ts21.createTypeLiteralNode(coercedKeys);
3113
+ initType = initType !== null ? ts21.createIntersectionTypeNode([initType, coercedLiteral]) : coercedLiteral;
2722
3114
  }
2723
3115
  if (initType === null) {
2724
- initType = ts18.createTypeLiteralNode([]);
3116
+ initType = ts21.createTypeLiteralNode([]);
2725
3117
  }
2726
- return ts18.createParameter(void 0, void 0, void 0, "init", void 0, initType, void 0);
3118
+ return ts21.createParameter(void 0, void 0, void 0, "init", void 0, initType, void 0);
2727
3119
  }
2728
3120
  function generateGenericArgs(params) {
2729
- return params.map((param) => ts18.createTypeReferenceNode(param.name, void 0));
3121
+ return params.map((param) => ts21.createTypeReferenceNode(param.name, void 0));
2730
3122
  }
2731
3123
  function requiresInlineTypeCtor(node, host, env) {
2732
3124
  return !checkIfGenericTypeBoundsCanBeEmitted(node, host, env);
@@ -2737,7 +3129,7 @@ function typeParametersWithDefaultTypes(params) {
2737
3129
  }
2738
3130
  return params.map((param) => {
2739
3131
  if (param.default === void 0) {
2740
- return ts18.updateTypeParameterDeclaration(param, param.name, param.constraint, ts18.createKeywordTypeNode(ts18.SyntaxKind.AnyKeyword));
3132
+ return ts21.updateTypeParameterDeclaration(param, param.name, param.constraint, ts21.createKeywordTypeNode(ts21.SyntaxKind.AnyKeyword));
2741
3133
  } else {
2742
3134
  return param;
2743
3135
  }
@@ -2769,13 +3161,13 @@ var Environment = class {
2769
3161
  }
2770
3162
  if (requiresInlineTypeCtor(node, this.reflector, this)) {
2771
3163
  const ref = this.reference(dirRef);
2772
- const typeCtorExpr = ts19.createPropertyAccess(ref, "ngTypeCtor");
3164
+ const typeCtorExpr = ts22.createPropertyAccess(ref, "ngTypeCtor");
2773
3165
  this.typeCtors.set(node, typeCtorExpr);
2774
3166
  return typeCtorExpr;
2775
3167
  } else {
2776
3168
  const fnName = `_ctor${this.nextIds.typeCtor++}`;
2777
3169
  const nodeTypeRef = this.referenceType(dirRef);
2778
- if (!ts19.isTypeReferenceNode(nodeTypeRef)) {
3170
+ if (!ts22.isTypeReferenceNode(nodeTypeRef)) {
2779
3171
  throw new Error(`Expected TypeReferenceNode from reference to ${dirRef.debugName}`);
2780
3172
  }
2781
3173
  const meta = {
@@ -2791,7 +3183,7 @@ var Environment = class {
2791
3183
  const typeParams = this.emitTypeParameters(node);
2792
3184
  const typeCtor = generateTypeCtorDeclarationFn(node, meta, nodeTypeRef.typeName, typeParams);
2793
3185
  this.typeCtorStatements.push(typeCtor);
2794
- const fnId = ts19.createIdentifier(fnName);
3186
+ const fnId = ts22.createIdentifier(fnName);
2795
3187
  this.typeCtors.set(node, fnId);
2796
3188
  return fnId;
2797
3189
  }
@@ -2801,7 +3193,7 @@ var Environment = class {
2801
3193
  return this.pipeInsts.get(ref.node);
2802
3194
  }
2803
3195
  const pipeType = this.referenceType(ref);
2804
- const pipeInstId = ts19.createIdentifier(`_pipe${this.nextIds.pipeInst++}`);
3196
+ const pipeInstId = ts22.createIdentifier(`_pipe${this.nextIds.pipeInst++}`);
2805
3197
  this.pipeInstStatements.push(tsDeclareVariable(pipeInstId, pipeType));
2806
3198
  this.pipeInsts.set(ref.node, pipeInstId);
2807
3199
  return pipeInstId;
@@ -2838,7 +3230,7 @@ var Environment = class {
2838
3230
 
2839
3231
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/oob.mjs
2840
3232
  import { TmplAstElement as TmplAstElement2 } from "@angular/compiler";
2841
- import ts20 from "typescript";
3233
+ import ts23 from "typescript";
2842
3234
  var OutOfBandDiagnosticRecorderImpl = class {
2843
3235
  constructor(resolver) {
2844
3236
  this.resolver = resolver;
@@ -2852,7 +3244,7 @@ var OutOfBandDiagnosticRecorderImpl = class {
2852
3244
  const mapping = this.resolver.getSourceMapping(templateId);
2853
3245
  const value = ref.value.trim();
2854
3246
  const errorMsg = `No directive found with exportAs '${value}'.`;
2855
- this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, ref.valueSpan || ref.sourceSpan, ts20.DiagnosticCategory.Error, ngErrorCode(ErrorCode.MISSING_REFERENCE_TARGET), errorMsg));
3247
+ this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, ref.valueSpan || ref.sourceSpan, ts23.DiagnosticCategory.Error, ngErrorCode(ErrorCode.MISSING_REFERENCE_TARGET), errorMsg));
2856
3248
  }
2857
3249
  missingPipe(templateId, ast) {
2858
3250
  if (this.recordedPipes.has(ast)) {
@@ -2864,7 +3256,7 @@ var OutOfBandDiagnosticRecorderImpl = class {
2864
3256
  if (sourceSpan === null) {
2865
3257
  throw new Error(`Assertion failure: no SourceLocation found for usage of pipe '${ast.name}'.`);
2866
3258
  }
2867
- this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, sourceSpan, ts20.DiagnosticCategory.Error, ngErrorCode(ErrorCode.MISSING_PIPE), errorMsg));
3259
+ this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, sourceSpan, ts23.DiagnosticCategory.Error, ngErrorCode(ErrorCode.MISSING_PIPE), errorMsg));
2868
3260
  this.recordedPipes.add(ast);
2869
3261
  }
2870
3262
  illegalAssignmentToTemplateVar(templateId, assignment, target) {
@@ -2875,7 +3267,7 @@ var OutOfBandDiagnosticRecorderImpl = class {
2875
3267
  if (sourceSpan === null) {
2876
3268
  throw new Error(`Assertion failure: no SourceLocation found for property binding.`);
2877
3269
  }
2878
- this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, sourceSpan, ts20.DiagnosticCategory.Error, ngErrorCode(ErrorCode.WRITE_TO_READ_ONLY_VARIABLE), errorMsg, [{
3270
+ this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, sourceSpan, ts23.DiagnosticCategory.Error, ngErrorCode(ErrorCode.WRITE_TO_READ_ONLY_VARIABLE), errorMsg, [{
2879
3271
  text: `The variable ${assignment.name} is declared here.`,
2880
3272
  start: ((_a = target.valueSpan) == null ? void 0 : _a.start.offset) || target.sourceSpan.start.offset,
2881
3273
  end: ((_b = target.valueSpan) == null ? void 0 : _b.end.offset) || target.sourceSpan.end.offset,
@@ -2885,7 +3277,7 @@ var OutOfBandDiagnosticRecorderImpl = class {
2885
3277
  duplicateTemplateVar(templateId, variable, firstDecl) {
2886
3278
  const mapping = this.resolver.getSourceMapping(templateId);
2887
3279
  const errorMsg = `Cannot redeclare variable '${variable.name}' as it was previously declared elsewhere for the same template.`;
2888
- this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, variable.sourceSpan, ts20.DiagnosticCategory.Error, ngErrorCode(ErrorCode.DUPLICATE_VARIABLE_DECLARATION), errorMsg, [{
3280
+ this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, variable.sourceSpan, ts23.DiagnosticCategory.Error, ngErrorCode(ErrorCode.DUPLICATE_VARIABLE_DECLARATION), errorMsg, [{
2889
3281
  text: `The variable '${firstDecl.name}' was first declared here.`,
2890
3282
  start: firstDecl.sourceSpan.start.offset,
2891
3283
  end: firstDecl.sourceSpan.end.offset,
@@ -2924,7 +3316,7 @@ var OutOfBandDiagnosticRecorderImpl = class {
2924
3316
  const message = `This structural directive supports advanced type inference, but the current compiler configuration prevents its usage. The variable ${varIdentification} will have type 'any' as a result.
2925
3317
 
2926
3318
  Consider enabling the 'strictTemplates' option in your tsconfig.json for better type inference within this template.`;
2927
- this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, diagnosticVar.keySpan, ts20.DiagnosticCategory.Suggestion, ngErrorCode(ErrorCode.SUGGEST_SUBOPTIMAL_TYPE_INFERENCE), message));
3319
+ this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, diagnosticVar.keySpan, ts23.DiagnosticCategory.Suggestion, ngErrorCode(ErrorCode.SUGGEST_SUBOPTIMAL_TYPE_INFERENCE), message));
2928
3320
  }
2929
3321
  splitTwoWayBinding(templateId, input, output, inputConsumer, outputConsumer) {
2930
3322
  const mapping = this.resolver.getSourceMapping(templateId);
@@ -2958,7 +3350,7 @@ Consider enabling the 'strictTemplates' option in your tsconfig.json for better
2958
3350
  sourceFile: outputConsumer.name.getSourceFile()
2959
3351
  });
2960
3352
  }
2961
- this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, input.keySpan, ts20.DiagnosticCategory.Error, ngErrorCode(ErrorCode.SPLIT_TWO_WAY_BINDING), errorMsg, relatedMessages));
3353
+ this._diagnostics.push(makeTemplateDiagnostic(templateId, mapping, input.keySpan, ts23.DiagnosticCategory.Error, ngErrorCode(ErrorCode.SPLIT_TWO_WAY_BINDING), errorMsg, relatedMessages));
2962
3354
  }
2963
3355
  };
2964
3356
  function makeInlineDiagnostic(templateId, code, node, messageText, relatedInformation) {
@@ -2969,7 +3361,7 @@ function makeInlineDiagnostic(templateId, code, node, messageText, relatedInform
2969
3361
  }
2970
3362
 
2971
3363
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/shim.mjs
2972
- import ts21 from "typescript";
3364
+ import ts24 from "typescript";
2973
3365
  var TypeCheckShimGenerator = class {
2974
3366
  constructor() {
2975
3367
  this.extensionPrefix = "ngtypecheck";
@@ -2979,7 +3371,7 @@ var TypeCheckShimGenerator = class {
2979
3371
  if (priorShimSf !== null) {
2980
3372
  return priorShimSf;
2981
3373
  }
2982
- return ts21.createSourceFile(genFilePath, "export const USED_FOR_NG_TYPE_CHECKING = true;", ts21.ScriptTarget.Latest, true, ts21.ScriptKind.TS);
3374
+ return ts24.createSourceFile(genFilePath, "export const USED_FOR_NG_TYPE_CHECKING = true;", ts24.ScriptTarget.Latest, true, ts24.ScriptKind.TS);
2983
3375
  }
2984
3376
  static shimFor(fileName) {
2985
3377
  return absoluteFrom(fileName.replace(/\.tsx?$/, ".ngtypecheck.ts"));
@@ -2988,16 +3380,16 @@ var TypeCheckShimGenerator = class {
2988
3380
 
2989
3381
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/type_check_block.mjs
2990
3382
  import { BindingPipe, Call as Call2, DYNAMIC_TYPE, ImplicitReceiver as ImplicitReceiver4, PropertyRead as PropertyRead4, PropertyWrite as PropertyWrite3, SafeCall, SafePropertyRead as SafePropertyRead3, ThisReceiver, TmplAstBoundAttribute, TmplAstBoundText, TmplAstElement as TmplAstElement3, TmplAstIcu, TmplAstReference as TmplAstReference3, TmplAstTemplate as TmplAstTemplate2, TmplAstTextAttribute as TmplAstTextAttribute2, TmplAstVariable as TmplAstVariable2 } from "@angular/compiler";
2991
- import ts24 from "typescript";
3383
+ import ts27 from "typescript";
2992
3384
 
2993
3385
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/diagnostics.mjs
2994
3386
  import { AbsoluteSourceSpan as AbsoluteSourceSpan3 } from "@angular/compiler";
2995
- import ts22 from "typescript";
3387
+ import ts25 from "typescript";
2996
3388
  function wrapForDiagnostics(expr) {
2997
- return ts22.createParen(expr);
3389
+ return ts25.createParen(expr);
2998
3390
  }
2999
3391
  function wrapForTypeChecker(expr) {
3000
- return ts22.createParen(expr);
3392
+ return ts25.createParen(expr);
3001
3393
  }
3002
3394
  function addParseSpanInfo(node, span) {
3003
3395
  let commentText;
@@ -3006,10 +3398,10 @@ function addParseSpanInfo(node, span) {
3006
3398
  } else {
3007
3399
  commentText = `${span.start.offset},${span.end.offset}`;
3008
3400
  }
3009
- ts22.addSyntheticTrailingComment(node, ts22.SyntaxKind.MultiLineCommentTrivia, commentText, false);
3401
+ ts25.addSyntheticTrailingComment(node, ts25.SyntaxKind.MultiLineCommentTrivia, commentText, false);
3010
3402
  }
3011
3403
  function addTemplateId(tcb, id) {
3012
- ts22.addSyntheticLeadingComment(tcb, ts22.SyntaxKind.MultiLineCommentTrivia, id, true);
3404
+ ts25.addSyntheticLeadingComment(tcb, ts25.SyntaxKind.MultiLineCommentTrivia, id, true);
3013
3405
  }
3014
3406
  function shouldReportDiagnostic(diagnostic) {
3015
3407
  const { code } = diagnostic;
@@ -3038,32 +3430,32 @@ function translateDiagnostic(diagnostic, resolver) {
3038
3430
 
3039
3431
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/expression.mjs
3040
3432
  import { ASTWithSource as ASTWithSource2, Call, EmptyExpr as EmptyExpr2, PropertyRead as PropertyRead3, SafeKeyedRead, SafePropertyRead as SafePropertyRead2 } from "@angular/compiler";
3041
- import ts23 from "typescript";
3042
- var NULL_AS_ANY = ts23.createAsExpression(ts23.createNull(), ts23.createKeywordTypeNode(ts23.SyntaxKind.AnyKeyword));
3043
- var UNDEFINED = ts23.createIdentifier("undefined");
3433
+ import ts26 from "typescript";
3434
+ var NULL_AS_ANY = ts26.createAsExpression(ts26.createNull(), ts26.createKeywordTypeNode(ts26.SyntaxKind.AnyKeyword));
3435
+ var UNDEFINED = ts26.createIdentifier("undefined");
3044
3436
  var UNARY_OPS = /* @__PURE__ */ new Map([
3045
- ["+", ts23.SyntaxKind.PlusToken],
3046
- ["-", ts23.SyntaxKind.MinusToken]
3437
+ ["+", ts26.SyntaxKind.PlusToken],
3438
+ ["-", ts26.SyntaxKind.MinusToken]
3047
3439
  ]);
3048
3440
  var BINARY_OPS = /* @__PURE__ */ new Map([
3049
- ["+", ts23.SyntaxKind.PlusToken],
3050
- ["-", ts23.SyntaxKind.MinusToken],
3051
- ["<", ts23.SyntaxKind.LessThanToken],
3052
- [">", ts23.SyntaxKind.GreaterThanToken],
3053
- ["<=", ts23.SyntaxKind.LessThanEqualsToken],
3054
- [">=", ts23.SyntaxKind.GreaterThanEqualsToken],
3055
- ["==", ts23.SyntaxKind.EqualsEqualsToken],
3056
- ["===", ts23.SyntaxKind.EqualsEqualsEqualsToken],
3057
- ["*", ts23.SyntaxKind.AsteriskToken],
3058
- ["/", ts23.SyntaxKind.SlashToken],
3059
- ["%", ts23.SyntaxKind.PercentToken],
3060
- ["!=", ts23.SyntaxKind.ExclamationEqualsToken],
3061
- ["!==", ts23.SyntaxKind.ExclamationEqualsEqualsToken],
3062
- ["||", ts23.SyntaxKind.BarBarToken],
3063
- ["&&", ts23.SyntaxKind.AmpersandAmpersandToken],
3064
- ["&", ts23.SyntaxKind.AmpersandToken],
3065
- ["|", ts23.SyntaxKind.BarToken],
3066
- ["??", ts23.SyntaxKind.QuestionQuestionToken]
3441
+ ["+", ts26.SyntaxKind.PlusToken],
3442
+ ["-", ts26.SyntaxKind.MinusToken],
3443
+ ["<", ts26.SyntaxKind.LessThanToken],
3444
+ [">", ts26.SyntaxKind.GreaterThanToken],
3445
+ ["<=", ts26.SyntaxKind.LessThanEqualsToken],
3446
+ [">=", ts26.SyntaxKind.GreaterThanEqualsToken],
3447
+ ["==", ts26.SyntaxKind.EqualsEqualsToken],
3448
+ ["===", ts26.SyntaxKind.EqualsEqualsEqualsToken],
3449
+ ["*", ts26.SyntaxKind.AsteriskToken],
3450
+ ["/", ts26.SyntaxKind.SlashToken],
3451
+ ["%", ts26.SyntaxKind.PercentToken],
3452
+ ["!=", ts26.SyntaxKind.ExclamationEqualsToken],
3453
+ ["!==", ts26.SyntaxKind.ExclamationEqualsEqualsToken],
3454
+ ["||", ts26.SyntaxKind.BarBarToken],
3455
+ ["&&", ts26.SyntaxKind.AmpersandAmpersandToken],
3456
+ ["&", ts26.SyntaxKind.AmpersandToken],
3457
+ ["|", ts26.SyntaxKind.BarToken],
3458
+ ["??", ts26.SyntaxKind.QuestionQuestionToken]
3067
3459
  ]);
3068
3460
  function astToTypescript(ast, maybeResolve, config) {
3069
3461
  const translator = new AstTranslator(maybeResolve, config);
@@ -3079,7 +3471,7 @@ var AstTranslator = class {
3079
3471
  ast = ast.ast;
3080
3472
  }
3081
3473
  if (ast instanceof EmptyExpr2) {
3082
- const res = ts23.factory.createIdentifier("undefined");
3474
+ const res = ts26.factory.createIdentifier("undefined");
3083
3475
  addParseSpanInfo(res, ast.sourceSpan);
3084
3476
  return res;
3085
3477
  }
@@ -3095,7 +3487,7 @@ var AstTranslator = class {
3095
3487
  if (op === void 0) {
3096
3488
  throw new Error(`Unsupported Unary.operator: ${ast.operator}`);
3097
3489
  }
3098
- const node = wrapForDiagnostics(ts23.createPrefix(op, expr));
3490
+ const node = wrapForDiagnostics(ts26.createPrefix(op, expr));
3099
3491
  addParseSpanInfo(node, ast.sourceSpan);
3100
3492
  return node;
3101
3493
  }
@@ -3106,13 +3498,13 @@ var AstTranslator = class {
3106
3498
  if (op === void 0) {
3107
3499
  throw new Error(`Unsupported Binary.operation: ${ast.operation}`);
3108
3500
  }
3109
- const node = ts23.createBinary(lhs, op, rhs);
3501
+ const node = ts26.createBinary(lhs, op, rhs);
3110
3502
  addParseSpanInfo(node, ast.sourceSpan);
3111
3503
  return node;
3112
3504
  }
3113
3505
  visitChain(ast) {
3114
3506
  const elements = ast.expressions.map((expr) => this.translate(expr));
3115
- const node = wrapForDiagnostics(ts23.createCommaList(elements));
3507
+ const node = wrapForDiagnostics(ts26.createCommaList(elements));
3116
3508
  addParseSpanInfo(node, ast.sourceSpan);
3117
3509
  return node;
3118
3510
  }
@@ -3120,7 +3512,7 @@ var AstTranslator = class {
3120
3512
  const condExpr = this.translate(ast.condition);
3121
3513
  const trueExpr = this.translate(ast.trueExp);
3122
3514
  const falseExpr = wrapForTypeChecker(this.translate(ast.falseExp));
3123
- const node = ts23.createParen(ts23.createConditional(condExpr, trueExpr, falseExpr));
3515
+ const node = ts26.createParen(ts26.createConditional(condExpr, trueExpr, falseExpr));
3124
3516
  addParseSpanInfo(node, ast.sourceSpan);
3125
3517
  return node;
3126
3518
  }
@@ -3131,26 +3523,26 @@ var AstTranslator = class {
3131
3523
  throw new Error("Method not implemented.");
3132
3524
  }
3133
3525
  visitInterpolation(ast) {
3134
- return ast.expressions.reduce((lhs, ast2) => ts23.createBinary(lhs, ts23.SyntaxKind.PlusToken, wrapForTypeChecker(this.translate(ast2))), ts23.createLiteral(""));
3526
+ return ast.expressions.reduce((lhs, ast2) => ts26.createBinary(lhs, ts26.SyntaxKind.PlusToken, wrapForTypeChecker(this.translate(ast2))), ts26.createLiteral(""));
3135
3527
  }
3136
3528
  visitKeyedRead(ast) {
3137
3529
  const receiver = wrapForDiagnostics(this.translate(ast.receiver));
3138
3530
  const key = this.translate(ast.key);
3139
- const node = ts23.createElementAccess(receiver, key);
3531
+ const node = ts26.createElementAccess(receiver, key);
3140
3532
  addParseSpanInfo(node, ast.sourceSpan);
3141
3533
  return node;
3142
3534
  }
3143
3535
  visitKeyedWrite(ast) {
3144
3536
  const receiver = wrapForDiagnostics(this.translate(ast.receiver));
3145
- const left = ts23.createElementAccess(receiver, this.translate(ast.key));
3537
+ const left = ts26.createElementAccess(receiver, this.translate(ast.key));
3146
3538
  const right = wrapForTypeChecker(this.translate(ast.value));
3147
- const node = wrapForDiagnostics(ts23.createBinary(left, ts23.SyntaxKind.EqualsToken, right));
3539
+ const node = wrapForDiagnostics(ts26.createBinary(left, ts26.SyntaxKind.EqualsToken, right));
3148
3540
  addParseSpanInfo(node, ast.sourceSpan);
3149
3541
  return node;
3150
3542
  }
3151
3543
  visitLiteralArray(ast) {
3152
3544
  const elements = ast.expressions.map((expr) => this.translate(expr));
3153
- const literal = ts23.createArrayLiteral(elements);
3545
+ const literal = ts26.createArrayLiteral(elements);
3154
3546
  const node = this.config.strictLiteralTypes ? literal : tsCastToAny(literal);
3155
3547
  addParseSpanInfo(node, ast.sourceSpan);
3156
3548
  return node;
@@ -3158,9 +3550,9 @@ var AstTranslator = class {
3158
3550
  visitLiteralMap(ast) {
3159
3551
  const properties = ast.keys.map(({ key }, idx) => {
3160
3552
  const value = this.translate(ast.values[idx]);
3161
- return ts23.createPropertyAssignment(ts23.createStringLiteral(key), value);
3553
+ return ts26.createPropertyAssignment(ts26.createStringLiteral(key), value);
3162
3554
  });
3163
- const literal = ts23.createObjectLiteral(properties, true);
3555
+ const literal = ts26.createObjectLiteral(properties, true);
3164
3556
  const node = this.config.strictLiteralTypes ? literal : tsCastToAny(literal);
3165
3557
  addParseSpanInfo(node, ast.sourceSpan);
3166
3558
  return node;
@@ -3168,18 +3560,18 @@ var AstTranslator = class {
3168
3560
  visitLiteralPrimitive(ast) {
3169
3561
  let node;
3170
3562
  if (ast.value === void 0) {
3171
- node = ts23.createIdentifier("undefined");
3563
+ node = ts26.createIdentifier("undefined");
3172
3564
  } else if (ast.value === null) {
3173
- node = ts23.createNull();
3565
+ node = ts26.createNull();
3174
3566
  } else {
3175
- node = ts23.createLiteral(ast.value);
3567
+ node = ts26.createLiteral(ast.value);
3176
3568
  }
3177
3569
  addParseSpanInfo(node, ast.sourceSpan);
3178
3570
  return node;
3179
3571
  }
3180
3572
  visitNonNullAssert(ast) {
3181
3573
  const expr = wrapForDiagnostics(this.translate(ast.expression));
3182
- const node = ts23.createNonNullExpression(expr);
3574
+ const node = ts26.createNonNullExpression(expr);
3183
3575
  addParseSpanInfo(node, ast.sourceSpan);
3184
3576
  return node;
3185
3577
  }
@@ -3188,13 +3580,13 @@ var AstTranslator = class {
3188
3580
  }
3189
3581
  visitPrefixNot(ast) {
3190
3582
  const expression = wrapForDiagnostics(this.translate(ast.expression));
3191
- const node = ts23.createLogicalNot(expression);
3583
+ const node = ts26.createLogicalNot(expression);
3192
3584
  addParseSpanInfo(node, ast.sourceSpan);
3193
3585
  return node;
3194
3586
  }
3195
3587
  visitPropertyRead(ast) {
3196
3588
  const receiver = wrapForDiagnostics(this.translate(ast.receiver));
3197
- const name = ts23.createPropertyAccess(receiver, ast.name);
3589
+ const name = ts26.createPropertyAccess(receiver, ast.name);
3198
3590
  addParseSpanInfo(name, ast.nameSpan);
3199
3591
  const node = wrapForDiagnostics(name);
3200
3592
  addParseSpanInfo(node, ast.sourceSpan);
@@ -3202,12 +3594,12 @@ var AstTranslator = class {
3202
3594
  }
3203
3595
  visitPropertyWrite(ast) {
3204
3596
  const receiver = wrapForDiagnostics(this.translate(ast.receiver));
3205
- const left = ts23.createPropertyAccess(receiver, ast.name);
3597
+ const left = ts26.createPropertyAccess(receiver, ast.name);
3206
3598
  addParseSpanInfo(left, ast.nameSpan);
3207
3599
  const leftWithPath = wrapForDiagnostics(left);
3208
3600
  addParseSpanInfo(leftWithPath, ast.sourceSpan);
3209
3601
  const right = wrapForTypeChecker(this.translate(ast.value));
3210
- const node = wrapForDiagnostics(ts23.createBinary(leftWithPath, ts23.SyntaxKind.EqualsToken, right));
3602
+ const node = wrapForDiagnostics(ts26.createBinary(leftWithPath, ts26.SyntaxKind.EqualsToken, right));
3211
3603
  addParseSpanInfo(node, ast.sourceSpan);
3212
3604
  return node;
3213
3605
  }
@@ -3218,13 +3610,13 @@ var AstTranslator = class {
3218
3610
  let node;
3219
3611
  const receiver = wrapForDiagnostics(this.translate(ast.receiver));
3220
3612
  if (this.config.strictSafeNavigationTypes) {
3221
- const expr = ts23.createPropertyAccess(ts23.createNonNullExpression(receiver), ast.name);
3613
+ const expr = ts26.createPropertyAccess(ts26.createNonNullExpression(receiver), ast.name);
3222
3614
  addParseSpanInfo(expr, ast.nameSpan);
3223
- node = ts23.createParen(ts23.createConditional(NULL_AS_ANY, expr, UNDEFINED));
3615
+ node = ts26.createParen(ts26.createConditional(NULL_AS_ANY, expr, UNDEFINED));
3224
3616
  } else if (VeSafeLhsInferenceBugDetector.veWillInferAnyFor(ast)) {
3225
- node = ts23.createPropertyAccess(tsCastToAny(receiver), ast.name);
3617
+ node = ts26.createPropertyAccess(tsCastToAny(receiver), ast.name);
3226
3618
  } else {
3227
- const expr = ts23.createPropertyAccess(ts23.createNonNullExpression(receiver), ast.name);
3619
+ const expr = ts26.createPropertyAccess(ts26.createNonNullExpression(receiver), ast.name);
3228
3620
  addParseSpanInfo(expr, ast.nameSpan);
3229
3621
  node = tsCastToAny(expr);
3230
3622
  }
@@ -3236,13 +3628,13 @@ var AstTranslator = class {
3236
3628
  const key = this.translate(ast.key);
3237
3629
  let node;
3238
3630
  if (this.config.strictSafeNavigationTypes) {
3239
- const expr = ts23.createElementAccess(ts23.createNonNullExpression(receiver), key);
3631
+ const expr = ts26.createElementAccess(ts26.createNonNullExpression(receiver), key);
3240
3632
  addParseSpanInfo(expr, ast.sourceSpan);
3241
- node = ts23.createParen(ts23.createConditional(NULL_AS_ANY, expr, UNDEFINED));
3633
+ node = ts26.createParen(ts26.createConditional(NULL_AS_ANY, expr, UNDEFINED));
3242
3634
  } else if (VeSafeLhsInferenceBugDetector.veWillInferAnyFor(ast)) {
3243
- node = ts23.createElementAccess(tsCastToAny(receiver), key);
3635
+ node = ts26.createElementAccess(tsCastToAny(receiver), key);
3244
3636
  } else {
3245
- const expr = ts23.createElementAccess(ts23.createNonNullExpression(receiver), key);
3637
+ const expr = ts26.createElementAccess(ts26.createNonNullExpression(receiver), key);
3246
3638
  addParseSpanInfo(expr, ast.sourceSpan);
3247
3639
  node = tsCastToAny(expr);
3248
3640
  }
@@ -3259,7 +3651,7 @@ var AstTranslator = class {
3259
3651
  expr = resolved;
3260
3652
  } else {
3261
3653
  const propertyReceiver = wrapForDiagnostics(this.translate(receiver.receiver));
3262
- expr = ts23.createPropertyAccess(propertyReceiver, receiver.name);
3654
+ expr = ts26.createPropertyAccess(propertyReceiver, receiver.name);
3263
3655
  addParseSpanInfo(expr, receiver.nameSpan);
3264
3656
  }
3265
3657
  } else {
@@ -3269,7 +3661,7 @@ var AstTranslator = class {
3269
3661
  if (ast.receiver instanceof SafePropertyRead2 || ast.receiver instanceof SafeKeyedRead) {
3270
3662
  node = this.convertToSafeCall(ast, expr, args);
3271
3663
  } else {
3272
- node = ts23.createCall(expr, void 0, args);
3664
+ node = ts26.createCall(expr, void 0, args);
3273
3665
  }
3274
3666
  addParseSpanInfo(node, ast.sourceSpan);
3275
3667
  return node;
@@ -3283,13 +3675,13 @@ var AstTranslator = class {
3283
3675
  }
3284
3676
  convertToSafeCall(ast, expr, args) {
3285
3677
  if (this.config.strictSafeNavigationTypes) {
3286
- const call = ts23.createCall(ts23.createNonNullExpression(expr), void 0, args);
3287
- return ts23.createParen(ts23.createConditional(NULL_AS_ANY, call, UNDEFINED));
3678
+ const call = ts26.createCall(ts26.createNonNullExpression(expr), void 0, args);
3679
+ return ts26.createParen(ts26.createConditional(NULL_AS_ANY, call, UNDEFINED));
3288
3680
  }
3289
3681
  if (VeSafeLhsInferenceBugDetector.veWillInferAnyFor(ast)) {
3290
- return ts23.createCall(tsCastToAny(expr), void 0, args);
3682
+ return ts26.createCall(tsCastToAny(expr), void 0, args);
3291
3683
  }
3292
- return tsCastToAny(ts23.createCall(ts23.createNonNullExpression(expr), void 0, args));
3684
+ return tsCastToAny(ts26.createCall(ts26.createNonNullExpression(expr), void 0, args));
3293
3685
  }
3294
3686
  };
3295
3687
  var VeSafeLhsInferenceBugDetector = class {
@@ -3401,7 +3793,7 @@ function generateTypeCheckBlock(env, ref, name, meta, domSchemaChecker, oobRecor
3401
3793
  const tcb = new Context(env, domSchemaChecker, oobRecorder, meta.id, meta.boundTarget, meta.pipes, meta.schemas);
3402
3794
  const scope = Scope.forNodes(tcb, null, tcb.boundTarget.target.template, null);
3403
3795
  const ctxRawType = env.referenceType(ref);
3404
- if (!ts24.isTypeReferenceNode(ctxRawType)) {
3796
+ if (!ts27.isTypeReferenceNode(ctxRawType)) {
3405
3797
  throw new Error(`Expected TypeReferenceNode when referencing the ctx param for ${ref.debugName}`);
3406
3798
  }
3407
3799
  let typeParameters = void 0;
@@ -3413,25 +3805,25 @@ function generateTypeCheckBlock(env, ref, name, meta, domSchemaChecker, oobRecor
3413
3805
  switch (genericContextBehavior) {
3414
3806
  case TcbGenericContextBehavior.UseEmitter:
3415
3807
  typeParameters = new TypeParameterEmitter(ref.node.typeParameters, env.reflector).emit((typeRef) => env.referenceType(typeRef));
3416
- typeArguments = typeParameters.map((param) => ts24.factory.createTypeReferenceNode(param.name));
3808
+ typeArguments = typeParameters.map((param) => ts27.factory.createTypeReferenceNode(param.name));
3417
3809
  break;
3418
3810
  case TcbGenericContextBehavior.CopyClassNodes:
3419
3811
  typeParameters = [...ref.node.typeParameters];
3420
- typeArguments = typeParameters.map((param) => ts24.factory.createTypeReferenceNode(param.name));
3812
+ typeArguments = typeParameters.map((param) => ts27.factory.createTypeReferenceNode(param.name));
3421
3813
  break;
3422
3814
  case TcbGenericContextBehavior.FallbackToAny:
3423
- typeArguments = ref.node.typeParameters.map(() => ts24.factory.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword));
3815
+ typeArguments = ref.node.typeParameters.map(() => ts27.factory.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword));
3424
3816
  break;
3425
3817
  }
3426
3818
  }
3427
3819
  const paramList = [tcbCtxParam(ref.node, ctxRawType.typeName, typeArguments)];
3428
3820
  const scopeStatements = scope.render();
3429
- const innerBody = ts24.createBlock([
3821
+ const innerBody = ts27.createBlock([
3430
3822
  ...env.getPreludeStatements(),
3431
3823
  ...scopeStatements
3432
3824
  ]);
3433
- const body = ts24.createBlock([ts24.createIf(ts24.createTrue(), innerBody, void 0)]);
3434
- const fnDecl = ts24.createFunctionDeclaration(void 0, void 0, void 0, name, env.config.useContextGenericType ? typeParameters : void 0, paramList, void 0, body);
3825
+ const body = ts27.createBlock([ts27.createIf(ts27.createTrue(), innerBody, void 0)]);
3826
+ const fnDecl = ts27.createFunctionDeclaration(void 0, void 0, void 0, name, env.config.useContextGenericType ? typeParameters : void 0, paramList, void 0, body);
3435
3827
  addTemplateId(fnDecl, meta.id);
3436
3828
  return fnDecl;
3437
3829
  }
@@ -3472,7 +3864,7 @@ var TcbVariableOp = class extends TcbOp {
3472
3864
  execute() {
3473
3865
  const ctx = this.scope.resolve(this.template);
3474
3866
  const id = this.tcb.allocateId();
3475
- const initializer = ts24.createPropertyAccess(ctx, this.variable.value || "$implicit");
3867
+ const initializer = ts27.createPropertyAccess(ctx, this.variable.value || "$implicit");
3476
3868
  addParseSpanInfo(id, this.variable.keySpan);
3477
3869
  let variable;
3478
3870
  if (this.variable.valueSpan !== void 0) {
@@ -3495,7 +3887,7 @@ var TcbTemplateContextOp = class extends TcbOp {
3495
3887
  }
3496
3888
  execute() {
3497
3889
  const ctx = this.tcb.allocateId();
3498
- const type = ts24.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword);
3890
+ const type = ts27.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword);
3499
3891
  this.scope.addStatement(tsDeclareVariable(ctx, type));
3500
3892
  return ctx;
3501
3893
  }
@@ -3548,16 +3940,16 @@ var TcbTemplateBodyOp = class extends TcbOp {
3548
3940
  }
3549
3941
  let guard = null;
3550
3942
  if (directiveGuards.length > 0) {
3551
- guard = directiveGuards.reduce((expr, dirGuard) => ts24.createBinary(expr, ts24.SyntaxKind.AmpersandAmpersandToken, dirGuard), directiveGuards.pop());
3943
+ guard = directiveGuards.reduce((expr, dirGuard) => ts27.createBinary(expr, ts27.SyntaxKind.AmpersandAmpersandToken, dirGuard), directiveGuards.pop());
3552
3944
  }
3553
3945
  const tmplScope = Scope.forNodes(this.tcb, this.scope, this.template, guard);
3554
3946
  const statements = tmplScope.render();
3555
3947
  if (statements.length === 0) {
3556
3948
  return null;
3557
3949
  }
3558
- let tmplBlock = ts24.createBlock(statements);
3950
+ let tmplBlock = ts27.createBlock(statements);
3559
3951
  if (guard !== null) {
3560
- tmplBlock = ts24.createIf(guard, tmplBlock);
3952
+ tmplBlock = ts27.createIf(guard, tmplBlock);
3561
3953
  }
3562
3954
  this.scope.addStatement(tmplBlock);
3563
3955
  return null;
@@ -3575,7 +3967,7 @@ var TcbTextInterpolationOp = class extends TcbOp {
3575
3967
  }
3576
3968
  execute() {
3577
3969
  const expr = tcbExpression(this.binding.value, this.tcb, this.scope);
3578
- this.scope.addStatement(ts24.createExpressionStatement(expr));
3970
+ this.scope.addStatement(ts27.createExpressionStatement(expr));
3579
3971
  return null;
3580
3972
  }
3581
3973
  };
@@ -3597,11 +3989,11 @@ var TcbDirectiveTypeOpBase = class extends TcbOp {
3597
3989
  if (this.dir.isGeneric === false || dirRef.node.typeParameters === void 0) {
3598
3990
  type = rawType;
3599
3991
  } else {
3600
- if (!ts24.isTypeReferenceNode(rawType)) {
3992
+ if (!ts27.isTypeReferenceNode(rawType)) {
3601
3993
  throw new Error(`Expected TypeReferenceNode when referencing the type for ${this.dir.ref.debugName}`);
3602
3994
  }
3603
- const typeArguments = dirRef.node.typeParameters.map(() => ts24.factory.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword));
3604
- type = ts24.factory.createTypeReferenceNode(rawType.typeName, typeArguments);
3995
+ const typeArguments = dirRef.node.typeParameters.map(() => ts27.factory.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword));
3996
+ type = ts27.factory.createTypeReferenceNode(rawType.typeName, typeArguments);
3605
3997
  }
3606
3998
  const id = this.tcb.allocateId();
3607
3999
  addExpressionIdentifier(type, ExpressionIdentifier.DIRECTIVE);
@@ -3642,11 +4034,11 @@ var TcbReferenceOp = class extends TcbOp {
3642
4034
  const id = this.tcb.allocateId();
3643
4035
  let initializer = this.target instanceof TmplAstTemplate2 || this.target instanceof TmplAstElement3 ? this.scope.resolve(this.target) : this.scope.resolve(this.host, this.target);
3644
4036
  if (this.target instanceof TmplAstElement3 && !this.tcb.env.config.checkTypeOfDomReferences || !this.tcb.env.config.checkTypeOfNonDomReferences) {
3645
- initializer = ts24.createAsExpression(initializer, ts24.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword));
4037
+ initializer = ts27.createAsExpression(initializer, ts27.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword));
3646
4038
  } else if (this.target instanceof TmplAstTemplate2) {
3647
- initializer = ts24.createAsExpression(initializer, ts24.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword));
3648
- initializer = ts24.createAsExpression(initializer, this.tcb.env.referenceExternalType("@angular/core", "TemplateRef", [DYNAMIC_TYPE]));
3649
- initializer = ts24.createParen(initializer);
4039
+ initializer = ts27.createAsExpression(initializer, ts27.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword));
4040
+ initializer = ts27.createAsExpression(initializer, this.tcb.env.referenceExternalType("@angular/core", "TemplateRef", [DYNAMIC_TYPE]));
4041
+ initializer = ts27.createParen(initializer);
3650
4042
  }
3651
4043
  addParseSpanInfo(initializer, this.node.sourceSpan);
3652
4044
  addParseSpanInfo(id, this.node.keySpan);
@@ -3736,7 +4128,7 @@ var TcbDirectiveInputsOp = class extends TcbOp {
3736
4128
  let target;
3737
4129
  if (this.dir.coercedInputFields.has(fieldName)) {
3738
4130
  const dirTypeRef = this.tcb.env.referenceType(this.dir.ref);
3739
- if (!ts24.isTypeReferenceNode(dirTypeRef)) {
4131
+ if (!ts27.isTypeReferenceNode(dirTypeRef)) {
3740
4132
  throw new Error(`Expected TypeReferenceNode from reference to ${this.dir.ref.debugName}`);
3741
4133
  }
3742
4134
  const id = this.tcb.allocateId();
@@ -3751,10 +4143,10 @@ var TcbDirectiveInputsOp = class extends TcbOp {
3751
4143
  }
3752
4144
  const id = this.tcb.allocateId();
3753
4145
  const dirTypeRef = this.tcb.env.referenceType(this.dir.ref);
3754
- if (!ts24.isTypeReferenceNode(dirTypeRef)) {
4146
+ if (!ts27.isTypeReferenceNode(dirTypeRef)) {
3755
4147
  throw new Error(`Expected TypeReferenceNode from reference to ${this.dir.ref.debugName}`);
3756
4148
  }
3757
- const type = ts24.createIndexedAccessTypeNode(ts24.createTypeQueryNode(dirId), ts24.createLiteralTypeNode(ts24.createStringLiteral(fieldName)));
4149
+ const type = ts27.createIndexedAccessTypeNode(ts27.createTypeQueryNode(dirId), ts27.createLiteralTypeNode(ts27.createStringLiteral(fieldName)));
3758
4150
  const temp = tsDeclareVariable(id, type);
3759
4151
  this.scope.addStatement(temp);
3760
4152
  target = id;
@@ -3762,18 +4154,18 @@ var TcbDirectiveInputsOp = class extends TcbOp {
3762
4154
  if (dirId === null) {
3763
4155
  dirId = this.scope.resolve(this.node, this.dir);
3764
4156
  }
3765
- target = this.dir.stringLiteralInputFields.has(fieldName) ? ts24.createElementAccess(dirId, ts24.createStringLiteral(fieldName)) : ts24.createPropertyAccess(dirId, ts24.createIdentifier(fieldName));
4157
+ target = this.dir.stringLiteralInputFields.has(fieldName) ? ts27.createElementAccess(dirId, ts27.createStringLiteral(fieldName)) : ts27.createPropertyAccess(dirId, ts27.createIdentifier(fieldName));
3766
4158
  }
3767
4159
  if (input.attribute.keySpan !== void 0) {
3768
4160
  addParseSpanInfo(target, input.attribute.keySpan);
3769
4161
  }
3770
- assignment = ts24.createBinary(target, ts24.SyntaxKind.EqualsToken, assignment);
4162
+ assignment = ts27.createBinary(target, ts27.SyntaxKind.EqualsToken, assignment);
3771
4163
  }
3772
4164
  addParseSpanInfo(assignment, input.attribute.sourceSpan);
3773
4165
  if (!this.tcb.env.config.checkTypeOfAttributes && input.attribute instanceof TmplAstTextAttribute2) {
3774
4166
  markIgnoreDiagnostics(assignment);
3775
4167
  }
3776
- this.scope.addStatement(ts24.createExpressionStatement(assignment));
4168
+ this.scope.addStatement(ts27.createExpressionStatement(assignment));
3777
4169
  }
3778
4170
  return null;
3779
4171
  }
@@ -3792,7 +4184,7 @@ var TcbDirectiveCtorCircularFallbackOp = class extends TcbOp {
3792
4184
  execute() {
3793
4185
  const id = this.tcb.allocateId();
3794
4186
  const typeCtor = this.tcb.env.typeCtorFor(this.dir);
3795
- const circularPlaceholder = ts24.createCall(typeCtor, void 0, [ts24.createNonNullExpression(ts24.createNull())]);
4187
+ const circularPlaceholder = ts27.createCall(typeCtor, void 0, [ts27.createNonNullExpression(ts27.createNull())]);
3796
4188
  this.scope.addStatement(tsCreateVariable(id, circularPlaceholder));
3797
4189
  return id;
3798
4190
  }
@@ -3858,15 +4250,15 @@ var TcbUnclaimedInputsOp = class extends TcbOp {
3858
4250
  elId = this.scope.resolve(this.element);
3859
4251
  }
3860
4252
  const propertyName = ATTR_TO_PROP[binding.name] || binding.name;
3861
- const prop = ts24.createElementAccess(elId, ts24.createStringLiteral(propertyName));
3862
- const stmt = ts24.createBinary(prop, ts24.SyntaxKind.EqualsToken, wrapForDiagnostics(expr));
4253
+ const prop = ts27.createElementAccess(elId, ts27.createStringLiteral(propertyName));
4254
+ const stmt = ts27.createBinary(prop, ts27.SyntaxKind.EqualsToken, wrapForDiagnostics(expr));
3863
4255
  addParseSpanInfo(stmt, binding.sourceSpan);
3864
- this.scope.addStatement(ts24.createExpressionStatement(stmt));
4256
+ this.scope.addStatement(ts27.createExpressionStatement(stmt));
3865
4257
  } else {
3866
- this.scope.addStatement(ts24.createExpressionStatement(expr));
4258
+ this.scope.addStatement(ts27.createExpressionStatement(expr));
3867
4259
  }
3868
4260
  } else {
3869
- this.scope.addStatement(ts24.createExpressionStatement(expr));
4261
+ this.scope.addStatement(ts27.createExpressionStatement(expr));
3870
4262
  }
3871
4263
  }
3872
4264
  return null;
@@ -3898,18 +4290,18 @@ var TcbDirectiveOutputsOp = class extends TcbOp {
3898
4290
  if (dirId === null) {
3899
4291
  dirId = this.scope.resolve(this.node, this.dir);
3900
4292
  }
3901
- const outputField = ts24.createElementAccess(dirId, ts24.createStringLiteral(field));
4293
+ const outputField = ts27.createElementAccess(dirId, ts27.createStringLiteral(field));
3902
4294
  addParseSpanInfo(outputField, output.keySpan);
3903
4295
  if (this.tcb.env.config.checkTypeOfOutputEvents) {
3904
4296
  const handler = tcbCreateEventHandler(output, this.tcb, this.scope, 0);
3905
- const subscribeFn = ts24.createPropertyAccess(outputField, "subscribe");
3906
- const call = ts24.createCall(subscribeFn, void 0, [handler]);
4297
+ const subscribeFn = ts27.createPropertyAccess(outputField, "subscribe");
4298
+ const call = ts27.createCall(subscribeFn, void 0, [handler]);
3907
4299
  addParseSpanInfo(call, output.sourceSpan);
3908
- this.scope.addStatement(ts24.createExpressionStatement(call));
4300
+ this.scope.addStatement(ts27.createExpressionStatement(call));
3909
4301
  } else {
3910
- this.scope.addStatement(ts24.createExpressionStatement(outputField));
4302
+ this.scope.addStatement(ts27.createExpressionStatement(outputField));
3911
4303
  const handler = tcbCreateEventHandler(output, this.tcb, this.scope, 1);
3912
- this.scope.addStatement(ts24.createExpressionStatement(handler));
4304
+ this.scope.addStatement(ts27.createExpressionStatement(handler));
3913
4305
  }
3914
4306
  ExpressionSemanticVisitor.visit(output.handler, this.tcb.id, this.tcb.boundTarget, this.tcb.oobRecorder);
3915
4307
  }
@@ -3942,20 +4334,20 @@ var TcbUnclaimedOutputsOp = class extends TcbOp {
3942
4334
  if (output.type === 1) {
3943
4335
  const eventType = this.tcb.env.config.checkTypeOfAnimationEvents ? this.tcb.env.referenceExternalType("@angular/animations", "AnimationEvent") : 1;
3944
4336
  const handler = tcbCreateEventHandler(output, this.tcb, this.scope, eventType);
3945
- this.scope.addStatement(ts24.createExpressionStatement(handler));
4337
+ this.scope.addStatement(ts27.createExpressionStatement(handler));
3946
4338
  } else if (this.tcb.env.config.checkTypeOfDomEvents) {
3947
4339
  const handler = tcbCreateEventHandler(output, this.tcb, this.scope, 0);
3948
4340
  if (elId === null) {
3949
4341
  elId = this.scope.resolve(this.element);
3950
4342
  }
3951
- const propertyAccess = ts24.createPropertyAccess(elId, "addEventListener");
4343
+ const propertyAccess = ts27.createPropertyAccess(elId, "addEventListener");
3952
4344
  addParseSpanInfo(propertyAccess, output.keySpan);
3953
- const call = ts24.createCall(propertyAccess, void 0, [ts24.createStringLiteral(output.name), handler]);
4345
+ const call = ts27.createCall(propertyAccess, void 0, [ts27.createStringLiteral(output.name), handler]);
3954
4346
  addParseSpanInfo(call, output.sourceSpan);
3955
- this.scope.addStatement(ts24.createExpressionStatement(call));
4347
+ this.scope.addStatement(ts27.createExpressionStatement(call));
3956
4348
  } else {
3957
4349
  const handler = tcbCreateEventHandler(output, this.tcb, this.scope, 1);
3958
- this.scope.addStatement(ts24.createExpressionStatement(handler));
4350
+ this.scope.addStatement(ts27.createExpressionStatement(handler));
3959
4351
  }
3960
4352
  ExpressionSemanticVisitor.visit(output.handler, this.tcb.id, this.tcb.boundTarget, this.tcb.oobRecorder);
3961
4353
  }
@@ -3969,15 +4361,15 @@ var TcbComponentContextCompletionOp = class extends TcbOp {
3969
4361
  this.optional = false;
3970
4362
  }
3971
4363
  execute() {
3972
- const ctx = ts24.createIdentifier("ctx");
3973
- const ctxDot = ts24.createPropertyAccess(ctx, "");
4364
+ const ctx = ts27.createIdentifier("ctx");
4365
+ const ctxDot = ts27.createPropertyAccess(ctx, "");
3974
4366
  markIgnoreDiagnostics(ctxDot);
3975
4367
  addExpressionIdentifier(ctxDot, ExpressionIdentifier.COMPONENT_COMPLETION);
3976
- this.scope.addStatement(ts24.createExpressionStatement(ctxDot));
4368
+ this.scope.addStatement(ts27.createExpressionStatement(ctxDot));
3977
4369
  return null;
3978
4370
  }
3979
4371
  };
3980
- var INFER_TYPE_FOR_CIRCULAR_OP_EXPR = ts24.createNonNullExpression(ts24.createNull());
4372
+ var INFER_TYPE_FOR_CIRCULAR_OP_EXPR = ts27.createNonNullExpression(ts27.createNull());
3981
4373
  var Context = class {
3982
4374
  constructor(env, domSchemaChecker, oobRecorder, id, boundTarget, pipes, schemas) {
3983
4375
  this.env = env;
@@ -3990,7 +4382,7 @@ var Context = class {
3990
4382
  this.nextId = 1;
3991
4383
  }
3992
4384
  allocateId() {
3993
- return ts24.createIdentifier(`_t${this.nextId++}`);
4385
+ return ts27.createIdentifier(`_t${this.nextId++}`);
3994
4386
  }
3995
4387
  getPipeByName(name) {
3996
4388
  if (!this.pipes.has(name)) {
@@ -4042,8 +4434,8 @@ var Scope = class {
4042
4434
  resolve(node, directive) {
4043
4435
  const res = this.resolveLocal(node, directive);
4044
4436
  if (res !== null) {
4045
- const clone = ts24.getMutableClone(res);
4046
- ts24.setSyntheticTrailingComments(clone, []);
4437
+ const clone = ts27.getMutableClone(res);
4438
+ ts27.setSyntheticTrailingComments(clone, []);
4047
4439
  return clone;
4048
4440
  } else if (this.parent !== null) {
4049
4441
  return this.parent.resolve(node, directive);
@@ -4071,7 +4463,7 @@ var Scope = class {
4071
4463
  } else if (parentGuards === null) {
4072
4464
  return this.guard;
4073
4465
  } else {
4074
- return ts24.createBinary(parentGuards, ts24.SyntaxKind.AmpersandAmpersandToken, this.guard);
4466
+ return ts27.createBinary(parentGuards, ts27.SyntaxKind.AmpersandAmpersandToken, this.guard);
4075
4467
  }
4076
4468
  }
4077
4469
  resolveLocal(ref, directive) {
@@ -4251,8 +4643,8 @@ var Scope = class {
4251
4643
  }
4252
4644
  };
4253
4645
  function tcbCtxParam(node, name, typeArguments) {
4254
- const type = ts24.factory.createTypeReferenceNode(name, typeArguments);
4255
- return ts24.factory.createParameterDeclaration(void 0, void 0, void 0, "ctx", void 0, type, void 0);
4646
+ const type = ts27.factory.createTypeReferenceNode(name, typeArguments);
4647
+ return ts27.factory.createParameterDeclaration(void 0, void 0, void 0, "ctx", void 0, type, void 0);
4256
4648
  }
4257
4649
  function tcbExpression(ast, tcb, scope) {
4258
4650
  const translator = new TcbExpressionTranslator(tcb, scope);
@@ -4275,11 +4667,11 @@ var TcbExpressionTranslator = class {
4275
4667
  return null;
4276
4668
  }
4277
4669
  const expr = this.translate(ast.value);
4278
- const result = ts24.createParen(ts24.createBinary(target, ts24.SyntaxKind.EqualsToken, expr));
4670
+ const result = ts27.createParen(ts27.createBinary(target, ts27.SyntaxKind.EqualsToken, expr));
4279
4671
  addParseSpanInfo(result, ast.sourceSpan);
4280
4672
  return result;
4281
4673
  } else if (ast instanceof ImplicitReceiver4) {
4282
- return ts24.createIdentifier("ctx");
4674
+ return ts27.createIdentifier("ctx");
4283
4675
  } else if (ast instanceof BindingPipe) {
4284
4676
  const expr = this.translate(ast.exp);
4285
4677
  const pipeRef = this.tcb.getPipeByName(ast.name);
@@ -4291,19 +4683,19 @@ var TcbExpressionTranslator = class {
4291
4683
  pipe = this.tcb.env.pipeInst(pipeRef);
4292
4684
  }
4293
4685
  const args = ast.args.map((arg) => this.translate(arg));
4294
- let methodAccess = ts24.factory.createPropertyAccessExpression(pipe, "transform");
4686
+ let methodAccess = ts27.factory.createPropertyAccessExpression(pipe, "transform");
4295
4687
  addParseSpanInfo(methodAccess, ast.nameSpan);
4296
4688
  if (!this.tcb.env.config.checkTypeOfPipes) {
4297
- methodAccess = ts24.factory.createAsExpression(methodAccess, ts24.factory.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword));
4689
+ methodAccess = ts27.factory.createAsExpression(methodAccess, ts27.factory.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword));
4298
4690
  }
4299
- const result = ts24.createCall(methodAccess, void 0, [expr, ...args]);
4691
+ const result = ts27.createCall(methodAccess, void 0, [expr, ...args]);
4300
4692
  addParseSpanInfo(result, ast.sourceSpan);
4301
4693
  return result;
4302
4694
  } else if ((ast instanceof Call2 || ast instanceof SafeCall) && (ast.receiver instanceof PropertyRead4 || ast.receiver instanceof SafePropertyRead3)) {
4303
4695
  if (ast.receiver.receiver instanceof ImplicitReceiver4 && !(ast.receiver.receiver instanceof ThisReceiver) && ast.receiver.name === "$any" && ast.args.length === 1) {
4304
4696
  const expr = this.translate(ast.args[0]);
4305
- const exprAsAny = ts24.createAsExpression(expr, ts24.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword));
4306
- const result = ts24.createParen(exprAsAny);
4697
+ const exprAsAny = ts27.createAsExpression(expr, ts27.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword));
4698
+ const result = ts27.createParen(exprAsAny);
4307
4699
  addParseSpanInfo(result, ast.sourceSpan);
4308
4700
  return result;
4309
4701
  }
@@ -4314,7 +4706,7 @@ var TcbExpressionTranslator = class {
4314
4706
  const method = wrapForDiagnostics(receiver);
4315
4707
  addParseSpanInfo(method, ast.receiver.nameSpan);
4316
4708
  const args = ast.args.map((arg) => this.translate(arg));
4317
- const node = ts24.createCall(method, void 0, args);
4709
+ const node = ts27.createCall(method, void 0, args);
4318
4710
  addParseSpanInfo(node, ast.sourceSpan);
4319
4711
  return node;
4320
4712
  } else {
@@ -4334,17 +4726,17 @@ var TcbExpressionTranslator = class {
4334
4726
  function tcbCallTypeCtor(dir, tcb, inputs) {
4335
4727
  const typeCtor = tcb.env.typeCtorFor(dir);
4336
4728
  const members = inputs.map((input) => {
4337
- const propertyName = ts24.createStringLiteral(input.field);
4729
+ const propertyName = ts27.createStringLiteral(input.field);
4338
4730
  if (input.type === "binding") {
4339
4731
  const expr = widenBinding(input.expression, tcb);
4340
- const assignment = ts24.createPropertyAssignment(propertyName, wrapForDiagnostics(expr));
4732
+ const assignment = ts27.createPropertyAssignment(propertyName, wrapForDiagnostics(expr));
4341
4733
  addParseSpanInfo(assignment, input.sourceSpan);
4342
4734
  return assignment;
4343
4735
  } else {
4344
- return ts24.createPropertyAssignment(propertyName, NULL_AS_ANY);
4736
+ return ts27.createPropertyAssignment(propertyName, NULL_AS_ANY);
4345
4737
  }
4346
4738
  });
4347
- return ts24.createCall(typeCtor, void 0, [ts24.createObjectLiteral(members)]);
4739
+ return ts27.createCall(typeCtor, void 0, [ts27.createObjectLiteral(members)]);
4348
4740
  }
4349
4741
  function getBoundInputs(directive, node, tcb) {
4350
4742
  const boundInputs = [];
@@ -4370,17 +4762,17 @@ function translateInput(attr, tcb, scope) {
4370
4762
  if (attr instanceof TmplAstBoundAttribute) {
4371
4763
  return tcbExpression(attr.value, tcb, scope);
4372
4764
  } else {
4373
- return ts24.createStringLiteral(attr.value);
4765
+ return ts27.createStringLiteral(attr.value);
4374
4766
  }
4375
4767
  }
4376
4768
  function widenBinding(expr, tcb) {
4377
4769
  if (!tcb.env.config.checkTypeOfInputBindings) {
4378
4770
  return tsCastToAny(expr);
4379
4771
  } else if (!tcb.env.config.strictNullInputBindings) {
4380
- if (ts24.isObjectLiteralExpression(expr) || ts24.isArrayLiteralExpression(expr)) {
4772
+ if (ts27.isObjectLiteralExpression(expr) || ts27.isArrayLiteralExpression(expr)) {
4381
4773
  return expr;
4382
4774
  } else {
4383
- return ts24.createNonNullExpression(expr);
4775
+ return ts27.createNonNullExpression(expr);
4384
4776
  }
4385
4777
  } else {
4386
4778
  return expr;
@@ -4393,18 +4785,18 @@ function tcbCreateEventHandler(event, tcb, scope, eventType) {
4393
4785
  if (eventType === 0) {
4394
4786
  eventParamType = void 0;
4395
4787
  } else if (eventType === 1) {
4396
- eventParamType = ts24.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword);
4788
+ eventParamType = ts27.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword);
4397
4789
  } else {
4398
4790
  eventParamType = eventType;
4399
4791
  }
4400
4792
  const guards = scope.guards();
4401
- let body = ts24.createExpressionStatement(handler);
4793
+ let body = ts27.createExpressionStatement(handler);
4402
4794
  if (guards !== null) {
4403
- body = ts24.createIf(guards, body);
4795
+ body = ts27.createIf(guards, body);
4404
4796
  }
4405
- const eventParam = ts24.createParameter(void 0, void 0, void 0, EVENT_PARAMETER, void 0, eventParamType);
4797
+ const eventParam = ts27.createParameter(void 0, void 0, void 0, EVENT_PARAMETER, void 0, eventParamType);
4406
4798
  addExpressionIdentifier(eventParam, ExpressionIdentifier.EVENT_PARAMETER);
4407
- return ts24.createFunctionExpression(void 0, void 0, void 0, void 0, [eventParam], ts24.createKeywordTypeNode(ts24.SyntaxKind.AnyKeyword), ts24.createBlock([body]));
4799
+ return ts27.createFunctionExpression(void 0, void 0, void 0, void 0, [eventParam], ts27.createKeywordTypeNode(ts27.SyntaxKind.AnyKeyword), ts27.createBlock([body]));
4408
4800
  }
4409
4801
  function tcbEventHandlerExpression(ast, tcb, scope) {
4410
4802
  const translator = new TcbEventHandlerTranslator(tcb, scope);
@@ -4432,7 +4824,7 @@ function isSplitTwoWayBinding(inputName, output, inputs, tcb) {
4432
4824
  var TcbEventHandlerTranslator = class extends TcbExpressionTranslator {
4433
4825
  resolve(ast) {
4434
4826
  if (ast instanceof PropertyRead4 && ast.receiver instanceof ImplicitReceiver4 && !(ast.receiver instanceof ThisReceiver) && ast.name === EVENT_PARAMETER) {
4435
- const event = ts24.createIdentifier(EVENT_PARAMETER);
4827
+ const event = ts27.createIdentifier(EVENT_PARAMETER);
4436
4828
  addParseSpanInfo(event, ast.nameSpan);
4437
4829
  return event;
4438
4830
  }
@@ -4441,32 +4833,32 @@ var TcbEventHandlerTranslator = class extends TcbExpressionTranslator {
4441
4833
  };
4442
4834
 
4443
4835
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/type_check_file.mjs
4444
- import ts25 from "typescript";
4836
+ import ts28 from "typescript";
4445
4837
  var TypeCheckFile = class extends Environment {
4446
4838
  constructor(fileName, config, refEmitter, reflector, compilerHost) {
4447
- super(config, new ImportManager(new NoopImportRewriter(), "i"), refEmitter, reflector, ts25.createSourceFile(compilerHost.getCanonicalFileName(fileName), "", ts25.ScriptTarget.Latest, true));
4839
+ super(config, new ImportManager(new NoopImportRewriter(), "i"), refEmitter, reflector, ts28.createSourceFile(compilerHost.getCanonicalFileName(fileName), "", ts28.ScriptTarget.Latest, true));
4448
4840
  this.fileName = fileName;
4449
4841
  this.nextTcbId = 1;
4450
4842
  this.tcbStatements = [];
4451
4843
  }
4452
4844
  addTypeCheckBlock(ref, meta, domSchemaChecker, oobRecorder, genericContextBehavior) {
4453
- const fnId = ts25.createIdentifier(`_tcb${this.nextTcbId++}`);
4845
+ const fnId = ts28.createIdentifier(`_tcb${this.nextTcbId++}`);
4454
4846
  const fn = generateTypeCheckBlock(this, ref, fnId, meta, domSchemaChecker, oobRecorder, genericContextBehavior);
4455
4847
  this.tcbStatements.push(fn);
4456
4848
  }
4457
4849
  render(removeComments) {
4458
4850
  let source = this.importManager.getAllImports(this.contextFile.fileName).map((i) => `import * as ${i.qualifier.text} from '${i.specifier}';`).join("\n") + "\n\n";
4459
- const printer = ts25.createPrinter({ removeComments });
4851
+ const printer = ts28.createPrinter({ removeComments });
4460
4852
  source += "\n";
4461
4853
  for (const stmt of this.pipeInstStatements) {
4462
- source += printer.printNode(ts25.EmitHint.Unspecified, stmt, this.contextFile) + "\n";
4854
+ source += printer.printNode(ts28.EmitHint.Unspecified, stmt, this.contextFile) + "\n";
4463
4855
  }
4464
4856
  for (const stmt of this.typeCtorStatements) {
4465
- source += printer.printNode(ts25.EmitHint.Unspecified, stmt, this.contextFile) + "\n";
4857
+ source += printer.printNode(ts28.EmitHint.Unspecified, stmt, this.contextFile) + "\n";
4466
4858
  }
4467
4859
  source += "\n";
4468
4860
  for (const stmt of this.tcbStatements) {
4469
- source += printer.printNode(ts25.EmitHint.Unspecified, stmt, this.contextFile) + "\n";
4861
+ source += printer.printNode(ts28.EmitHint.Unspecified, stmt, this.contextFile) + "\n";
4470
4862
  }
4471
4863
  source += "\nexport const IS_A_MODULE = true;\n";
4472
4864
  return source;
@@ -4574,7 +4966,7 @@ var TypeCheckContextImpl = class {
4574
4966
  const importManager = new ImportManager(new NoopImportRewriter(), "_i");
4575
4967
  const ops = this.opMap.get(sf).sort(orderOps);
4576
4968
  const textParts = splitStringAtPoints(sf.text, ops.map((op) => op.splitPoint));
4577
- const printer = ts26.createPrinter({ omitTrailingSemicolon: true });
4969
+ const printer = ts29.createPrinter({ omitTrailingSemicolon: true });
4578
4970
  let code = textParts[0];
4579
4971
  ops.forEach((op, idx) => {
4580
4972
  const text = op.execute(importManager, sf, this.refEmitter, printer);
@@ -4655,7 +5047,7 @@ var TypeCheckContextImpl = class {
4655
5047
  if (span.start.offset === span.end.offset) {
4656
5048
  span.end.offset++;
4657
5049
  }
4658
- return makeTemplateDiagnostic(templateId, sourceMapping, span, ts26.DiagnosticCategory.Error, ngErrorCode(ErrorCode.TEMPLATE_PARSE_ERROR), error.msg);
5050
+ return makeTemplateDiagnostic(templateId, sourceMapping, span, ts29.DiagnosticCategory.Error, ngErrorCode(ErrorCode.TEMPLATE_PARSE_ERROR), error.msg);
4659
5051
  });
4660
5052
  }
4661
5053
  };
@@ -4673,9 +5065,9 @@ var InlineTcbOp = class {
4673
5065
  }
4674
5066
  execute(im, sf, refEmitter, printer) {
4675
5067
  const env = new Environment(this.config, im, refEmitter, this.reflector, sf);
4676
- const fnName = ts26.createIdentifier(`_tcb_${this.ref.node.pos}`);
5068
+ const fnName = ts29.createIdentifier(`_tcb_${this.ref.node.pos}`);
4677
5069
  const fn = generateTypeCheckBlock(env, this.ref, fnName, this.meta, this.domSchemaChecker, this.oobRecorder, TcbGenericContextBehavior.CopyClassNodes);
4678
- return printer.printNode(ts26.EmitHint.Unspecified, fn, sf);
5070
+ return printer.printNode(ts29.EmitHint.Unspecified, fn, sf);
4679
5071
  }
4680
5072
  };
4681
5073
  var TypeCtorOp = class {
@@ -4688,7 +5080,7 @@ var TypeCtorOp = class {
4688
5080
  }
4689
5081
  execute(im, sf, refEmitter, printer) {
4690
5082
  const tcb = generateInlineTypeCtor(this.ref.node, this.meta);
4691
- return printer.printNode(ts26.EmitHint.Unspecified, tcb, sf);
5083
+ return printer.printNode(ts29.EmitHint.Unspecified, tcb, sf);
4692
5084
  }
4693
5085
  };
4694
5086
  function orderOps(op1, op2) {
@@ -4803,7 +5195,7 @@ var TemplateSourceManager = class {
4803
5195
 
4804
5196
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/template_symbol_builder.mjs
4805
5197
  import { AST, ASTWithSource as ASTWithSource3, BindingPipe as BindingPipe2, PropertyRead as PropertyRead5, PropertyWrite as PropertyWrite4, SafePropertyRead as SafePropertyRead4, TmplAstBoundAttribute as TmplAstBoundAttribute2, TmplAstBoundEvent, TmplAstElement as TmplAstElement4, TmplAstReference as TmplAstReference4, TmplAstTemplate as TmplAstTemplate3, TmplAstTextAttribute as TmplAstTextAttribute3, TmplAstVariable as TmplAstVariable3 } from "@angular/compiler";
4806
- import ts27 from "typescript";
5198
+ import ts30 from "typescript";
4807
5199
  var SymbolBuilder = class {
4808
5200
  constructor(tcbPath, tcbIsShim, typeCheckBlock, templateData, componentScopeReader, getTypeChecker) {
4809
5201
  this.tcbPath = tcbPath;
@@ -4847,7 +5239,7 @@ var SymbolBuilder = class {
4847
5239
  getSymbolOfElement(element) {
4848
5240
  var _a;
4849
5241
  const elementSourceSpan = (_a = element.startSourceSpan) != null ? _a : element.sourceSpan;
4850
- const node = findFirstMatchingNode(this.typeCheckBlock, { withSpan: elementSourceSpan, filter: ts27.isVariableDeclaration });
5242
+ const node = findFirstMatchingNode(this.typeCheckBlock, { withSpan: elementSourceSpan, filter: ts30.isVariableDeclaration });
4851
5243
  if (node === null) {
4852
5244
  return null;
4853
5245
  }
@@ -4866,12 +5258,12 @@ var SymbolBuilder = class {
4866
5258
  var _a;
4867
5259
  const elementSourceSpan = (_a = element.startSourceSpan) != null ? _a : element.sourceSpan;
4868
5260
  const tcbSourceFile = this.typeCheckBlock.getSourceFile();
4869
- const isDirectiveDeclaration = (node) => (ts27.isTypeNode(node) || ts27.isIdentifier(node)) && ts27.isVariableDeclaration(node.parent) && hasExpressionIdentifier(tcbSourceFile, node, ExpressionIdentifier.DIRECTIVE);
5261
+ const isDirectiveDeclaration = (node) => (ts30.isTypeNode(node) || ts30.isIdentifier(node)) && ts30.isVariableDeclaration(node.parent) && hasExpressionIdentifier(tcbSourceFile, node, ExpressionIdentifier.DIRECTIVE);
4870
5262
  const nodes = findAllMatchingNodes(this.typeCheckBlock, { withSpan: elementSourceSpan, filter: isDirectiveDeclaration });
4871
5263
  return nodes.map((node) => {
4872
5264
  var _a2;
4873
5265
  const symbol = this.getSymbolOfTsNode(node.parent);
4874
- if (symbol === null || !isSymbolWithValueDeclaration(symbol.tsSymbol) || !ts27.isClassDeclaration(symbol.tsSymbol.valueDeclaration)) {
5266
+ if (symbol === null || !isSymbolWithValueDeclaration(symbol.tsSymbol) || !ts30.isClassDeclaration(symbol.tsSymbol.valueDeclaration)) {
4875
5267
  return null;
4876
5268
  }
4877
5269
  const meta = this.getDirectiveMeta(element, symbol.tsSymbol.valueDeclaration);
@@ -4940,17 +5332,17 @@ var SymbolBuilder = class {
4940
5332
  if (!isAccessExpression(n)) {
4941
5333
  return false;
4942
5334
  }
4943
- if (ts27.isPropertyAccessExpression(n)) {
5335
+ if (ts30.isPropertyAccessExpression(n)) {
4944
5336
  return n.name.getText() === expectedAccess;
4945
5337
  } else {
4946
- return ts27.isStringLiteral(n.argumentExpression) && n.argumentExpression.text === expectedAccess;
5338
+ return ts30.isStringLiteral(n.argumentExpression) && n.argumentExpression.text === expectedAccess;
4947
5339
  }
4948
5340
  }
4949
5341
  const outputFieldAccesses = findAllMatchingNodes(this.typeCheckBlock, { withSpan: eventBinding.keySpan, filter });
4950
5342
  const bindings = [];
4951
5343
  for (const outputFieldAccess of outputFieldAccesses) {
4952
5344
  if (consumer instanceof TmplAstTemplate3 || consumer instanceof TmplAstElement4) {
4953
- if (!ts27.isPropertyAccessExpression(outputFieldAccess)) {
5345
+ if (!ts30.isPropertyAccessExpression(outputFieldAccess)) {
4954
5346
  continue;
4955
5347
  }
4956
5348
  const addEventListener = outputFieldAccess.name;
@@ -4973,7 +5365,7 @@ var SymbolBuilder = class {
4973
5365
  }
4974
5366
  });
4975
5367
  } else {
4976
- if (!ts27.isElementAccessExpression(outputFieldAccess)) {
5368
+ if (!ts30.isElementAccessExpression(outputFieldAccess)) {
4977
5369
  continue;
4978
5370
  }
4979
5371
  const tsSymbol = this.getTypeChecker().getSymbolAtLocation(outputFieldAccess.argumentExpression);
@@ -5045,11 +5437,11 @@ var SymbolBuilder = class {
5045
5437
  return null;
5046
5438
  }
5047
5439
  const [declaration] = tsSymbol.declarations;
5048
- if (!ts27.isVariableDeclaration(declaration) || !hasExpressionIdentifier(declaration.getSourceFile(), (_a = declaration.type) != null ? _a : declaration.name, ExpressionIdentifier.DIRECTIVE)) {
5440
+ if (!ts30.isVariableDeclaration(declaration) || !hasExpressionIdentifier(declaration.getSourceFile(), (_a = declaration.type) != null ? _a : declaration.name, ExpressionIdentifier.DIRECTIVE)) {
5049
5441
  return null;
5050
5442
  }
5051
5443
  const symbol = this.getSymbolOfTsNode(declaration);
5052
- if (symbol === null || !isSymbolWithValueDeclaration(symbol.tsSymbol) || !ts27.isClassDeclaration(symbol.tsSymbol.valueDeclaration)) {
5444
+ if (symbol === null || !isSymbolWithValueDeclaration(symbol.tsSymbol) || !ts30.isClassDeclaration(symbol.tsSymbol.valueDeclaration)) {
5053
5445
  return null;
5054
5446
  }
5055
5447
  const ngModule = this.getDirectiveModule(symbol.tsSymbol.valueDeclaration);
@@ -5065,7 +5457,7 @@ var SymbolBuilder = class {
5065
5457
  };
5066
5458
  }
5067
5459
  getSymbolOfVariable(variable) {
5068
- const node = findFirstMatchingNode(this.typeCheckBlock, { withSpan: variable.sourceSpan, filter: ts27.isVariableDeclaration });
5460
+ const node = findFirstMatchingNode(this.typeCheckBlock, { withSpan: variable.sourceSpan, filter: ts30.isVariableDeclaration });
5069
5461
  if (node === null || node.initializer === void 0) {
5070
5462
  return null;
5071
5463
  }
@@ -5088,11 +5480,11 @@ var SymbolBuilder = class {
5088
5480
  }
5089
5481
  getSymbolOfReference(ref) {
5090
5482
  const target = this.templateData.boundTarget.getReferenceTarget(ref);
5091
- let node = findFirstMatchingNode(this.typeCheckBlock, { withSpan: ref.sourceSpan, filter: ts27.isVariableDeclaration });
5483
+ let node = findFirstMatchingNode(this.typeCheckBlock, { withSpan: ref.sourceSpan, filter: ts30.isVariableDeclaration });
5092
5484
  if (node === null || target === null || node.initializer === void 0) {
5093
5485
  return null;
5094
5486
  }
5095
- const originalDeclaration = ts27.isParenthesizedExpression(node.initializer) && ts27.isAsExpression(node.initializer.expression) ? this.getTypeChecker().getSymbolAtLocation(node.name) : this.getTypeChecker().getSymbolAtLocation(node.initializer);
5487
+ const originalDeclaration = ts30.isParenthesizedExpression(node.initializer) && ts30.isAsExpression(node.initializer.expression) ? this.getTypeChecker().getSymbolAtLocation(node.name) : this.getTypeChecker().getSymbolAtLocation(node.initializer);
5096
5488
  if (originalDeclaration === void 0 || originalDeclaration.valueDeclaration === void 0) {
5097
5489
  return null;
5098
5490
  }
@@ -5116,7 +5508,7 @@ var SymbolBuilder = class {
5116
5508
  referenceVarLocation: referenceVarTcbLocation
5117
5509
  };
5118
5510
  } else {
5119
- if (!ts27.isClassDeclaration(target.directive.ref.node)) {
5511
+ if (!ts30.isClassDeclaration(target.directive.ref.node)) {
5120
5512
  return null;
5121
5513
  }
5122
5514
  return {
@@ -5131,7 +5523,7 @@ var SymbolBuilder = class {
5131
5523
  }
5132
5524
  }
5133
5525
  getSymbolOfPipe(expression) {
5134
- const methodAccess = findFirstMatchingNode(this.typeCheckBlock, { withSpan: expression.nameSpan, filter: ts27.isPropertyAccessExpression });
5526
+ const methodAccess = findFirstMatchingNode(this.typeCheckBlock, { withSpan: expression.nameSpan, filter: ts30.isPropertyAccessExpression });
5135
5527
  if (methodAccess === null) {
5136
5528
  return null;
5137
5529
  }
@@ -5170,7 +5562,7 @@ var SymbolBuilder = class {
5170
5562
  }
5171
5563
  let node = null;
5172
5564
  if (expression instanceof PropertyRead5) {
5173
- node = findFirstMatchingNode(this.typeCheckBlock, { withSpan, filter: ts27.isPropertyAccessExpression });
5565
+ node = findFirstMatchingNode(this.typeCheckBlock, { withSpan, filter: ts30.isPropertyAccessExpression });
5174
5566
  }
5175
5567
  if (node === null) {
5176
5568
  node = findFirstMatchingNode(this.typeCheckBlock, { withSpan, filter: anyNodeFilter });
@@ -5178,10 +5570,10 @@ var SymbolBuilder = class {
5178
5570
  if (node === null) {
5179
5571
  return null;
5180
5572
  }
5181
- while (ts27.isParenthesizedExpression(node)) {
5573
+ while (ts30.isParenthesizedExpression(node)) {
5182
5574
  node = node.expression;
5183
5575
  }
5184
- if (expression instanceof SafePropertyRead4 && ts27.isConditionalExpression(node)) {
5576
+ if (expression instanceof SafePropertyRead4 && ts30.isConditionalExpression(node)) {
5185
5577
  const whenTrueSymbol = this.getSymbolOfTsNode(node.whenTrue);
5186
5578
  if (whenTrueSymbol === null) {
5187
5579
  return null;
@@ -5197,13 +5589,13 @@ var SymbolBuilder = class {
5197
5589
  }
5198
5590
  getSymbolOfTsNode(node) {
5199
5591
  var _a;
5200
- while (ts27.isParenthesizedExpression(node)) {
5592
+ while (ts30.isParenthesizedExpression(node)) {
5201
5593
  node = node.expression;
5202
5594
  }
5203
5595
  let tsSymbol;
5204
- if (ts27.isPropertyAccessExpression(node)) {
5596
+ if (ts30.isPropertyAccessExpression(node)) {
5205
5597
  tsSymbol = this.getTypeChecker().getSymbolAtLocation(node.name);
5206
- } else if (ts27.isElementAccessExpression(node)) {
5598
+ } else if (ts30.isElementAccessExpression(node)) {
5207
5599
  tsSymbol = this.getTypeChecker().getSymbolAtLocation(node.argumentExpression);
5208
5600
  } else {
5209
5601
  tsSymbol = this.getTypeChecker().getSymbolAtLocation(node);
@@ -5221,13 +5613,13 @@ var SymbolBuilder = class {
5221
5613
  };
5222
5614
  }
5223
5615
  getTcbPositionForNode(node) {
5224
- if (ts27.isTypeReferenceNode(node)) {
5616
+ if (ts30.isTypeReferenceNode(node)) {
5225
5617
  return this.getTcbPositionForNode(node.typeName);
5226
- } else if (ts27.isQualifiedName(node)) {
5618
+ } else if (ts30.isQualifiedName(node)) {
5227
5619
  return node.right.getStart();
5228
- } else if (ts27.isPropertyAccessExpression(node)) {
5620
+ } else if (ts30.isPropertyAccessExpression(node)) {
5229
5621
  return node.name.getStart();
5230
- } else if (ts27.isElementAccessExpression(node)) {
5622
+ } else if (ts30.isElementAccessExpression(node)) {
5231
5623
  return node.argumentExpression.getStart();
5232
5624
  } else {
5233
5625
  return node.getStart();
@@ -5882,7 +6274,7 @@ var factory = {
5882
6274
 
5883
6275
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/checks/nullish_coalescing_not_nullable/index.mjs
5884
6276
  import { Binary } from "@angular/compiler";
5885
- import ts28 from "typescript";
6277
+ import ts31 from "typescript";
5886
6278
  var NullishCoalescingNotNullableCheck = class extends TemplateCheckWithVisitor {
5887
6279
  constructor() {
5888
6280
  super(...arguments);
@@ -5896,7 +6288,7 @@ var NullishCoalescingNotNullableCheck = class extends TemplateCheckWithVisitor {
5896
6288
  return [];
5897
6289
  }
5898
6290
  const typeLeft = symbolLeft.tsType;
5899
- if (typeLeft.flags & (ts28.TypeFlags.Any | ts28.TypeFlags.Unknown)) {
6291
+ if (typeLeft.flags & (ts31.TypeFlags.Any | ts31.TypeFlags.Unknown)) {
5900
6292
  return [];
5901
6293
  }
5902
6294
  if (typeLeft.getNonNullableType() !== typeLeft)
@@ -5926,7 +6318,7 @@ var factory2 = {
5926
6318
  };
5927
6319
 
5928
6320
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/src/extended_template_checker.mjs
5929
- import ts29 from "typescript";
6321
+ import ts32 from "typescript";
5930
6322
 
5931
6323
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/core/api/src/public_options.mjs
5932
6324
  var DiagnosticCategoryLabel;
@@ -5974,9 +6366,9 @@ var ExtendedTemplateCheckerImpl = class {
5974
6366
  function diagnosticLabelToCategory(label) {
5975
6367
  switch (label) {
5976
6368
  case DiagnosticCategoryLabel.Warning:
5977
- return ts29.DiagnosticCategory.Warning;
6369
+ return ts32.DiagnosticCategory.Warning;
5978
6370
  case DiagnosticCategoryLabel.Error:
5979
- return ts29.DiagnosticCategory.Error;
6371
+ return ts32.DiagnosticCategory.Error;
5980
6372
  case DiagnosticCategoryLabel.Suppress:
5981
6373
  return null;
5982
6374
  default:
@@ -6071,7 +6463,7 @@ var NgCompiler = class {
6071
6463
  this.currentProgram = inputProgram;
6072
6464
  this.closureCompilerEnabled = !!this.options.annotateForClosureCompiler;
6073
6465
  this.entryPoint = adapter.entryPoint !== null ? getSourceFileOrNull(inputProgram, adapter.entryPoint) : null;
6074
- const moduleResolutionCache = ts30.createModuleResolutionCache(this.adapter.getCurrentDirectory(), this.adapter.getCanonicalFileName.bind(this.adapter));
6466
+ const moduleResolutionCache = ts33.createModuleResolutionCache(this.adapter.getCurrentDirectory(), this.adapter.getCanonicalFileName.bind(this.adapter));
6075
6467
  this.moduleResolver = new ModuleResolver(inputProgram, this.options, this.adapter, moduleResolutionCache);
6076
6468
  this.resourceManager = new AdapterResourceLoader(adapter, this.options);
6077
6469
  this.cycleAnalyzer = new CycleAnalyzer(new ImportGraph(inputProgram.getTypeChecker(), this.delegatingPerfRecorder));
@@ -6127,7 +6519,7 @@ var NgCompiler = class {
6127
6519
  }
6128
6520
  for (const clazz of classesToUpdate) {
6129
6521
  this.compilation.traitCompiler.updateResources(clazz);
6130
- if (!ts30.isClassDeclaration(clazz)) {
6522
+ if (!ts33.isClassDeclaration(clazz)) {
6131
6523
  continue;
6132
6524
  }
6133
6525
  this.compilation.templateTypeChecker.invalidateClass(clazz);
@@ -6505,7 +6897,7 @@ var NgCompiler = class {
6505
6897
  new InjectableDecoratorHandler(reflector, isCore, this.options.strictInjectionParameters || false, injectableRegistry, this.delegatingPerfRecorder),
6506
6898
  new NgModuleDecoratorHandler(reflector, evaluator, metaReader, metaRegistry, scopeRegistry, referencesRegistry, isCore, refEmitter, this.adapter.factoryTracker, this.closureCompilerEnabled, injectableRegistry, this.delegatingPerfRecorder)
6507
6899
  ];
6508
- const traitCompiler = new TraitCompiler(handlers, reflector, this.delegatingPerfRecorder, this.incrementalCompilation, this.options.compileNonExportedClasses !== false, compilationMode, dtsTransforms, semanticDepGraphUpdater);
6900
+ const traitCompiler = new TraitCompiler(handlers, reflector, this.delegatingPerfRecorder, this.incrementalCompilation, this.options.compileNonExportedClasses !== false, compilationMode, dtsTransforms, semanticDepGraphUpdater, this.adapter);
6509
6901
  const notifyingDriver = new NotifyingProgramDriverWrapper(this.programDriver, (program) => {
6510
6902
  this.incrementalStrategy.setIncrementalState(this.incrementalCompilation.state, program);
6511
6903
  this.currentProgram = program;
@@ -6535,17 +6927,17 @@ function isAngularCorePackage(program) {
6535
6927
  return false;
6536
6928
  }
6537
6929
  return r3Symbols.statements.some((stmt) => {
6538
- if (!ts30.isVariableStatement(stmt)) {
6930
+ if (!ts33.isVariableStatement(stmt)) {
6539
6931
  return false;
6540
6932
  }
6541
- if (stmt.modifiers === void 0 || !stmt.modifiers.some((mod) => mod.kind === ts30.SyntaxKind.ExportKeyword)) {
6933
+ if (stmt.modifiers === void 0 || !stmt.modifiers.some((mod) => mod.kind === ts33.SyntaxKind.ExportKeyword)) {
6542
6934
  return false;
6543
6935
  }
6544
6936
  return stmt.declarationList.declarations.some((decl) => {
6545
- if (!ts30.isIdentifier(decl.name) || decl.name.text !== "ITS_JUST_ANGULAR") {
6937
+ if (!ts33.isIdentifier(decl.name) || decl.name.text !== "ITS_JUST_ANGULAR") {
6546
6938
  return false;
6547
6939
  }
6548
- if (decl.initializer === void 0 || decl.initializer.kind !== ts30.SyntaxKind.TrueKeyword) {
6940
+ if (decl.initializer === void 0 || decl.initializer.kind !== ts33.SyntaxKind.TrueKeyword) {
6549
6941
  return false;
6550
6942
  }
6551
6943
  return true;
@@ -6559,7 +6951,7 @@ function* verifyCompatibleTypeCheckOptions(options) {
6559
6951
  var _a, _b, _c;
6560
6952
  if (options.fullTemplateTypeCheck === false && options.strictTemplates === true) {
6561
6953
  yield makeConfigDiagnostic({
6562
- category: ts30.DiagnosticCategory.Error,
6954
+ category: ts33.DiagnosticCategory.Error,
6563
6955
  code: ErrorCode.CONFIG_STRICT_TEMPLATES_IMPLIES_FULL_TEMPLATE_TYPECHECK,
6564
6956
  messageText: `
6565
6957
  Angular compiler option "strictTemplates" is enabled, however "fullTemplateTypeCheck" is disabled.
@@ -6578,7 +6970,7 @@ https://angular.io/guide/template-typecheck
6578
6970
  }
6579
6971
  if (options.extendedDiagnostics && options.strictTemplates === false) {
6580
6972
  yield makeConfigDiagnostic({
6581
- category: ts30.DiagnosticCategory.Error,
6973
+ category: ts33.DiagnosticCategory.Error,
6582
6974
  code: ErrorCode.CONFIG_EXTENDED_DIAGNOSTICS_IMPLIES_STRICT_TEMPLATES,
6583
6975
  messageText: `
6584
6976
  Angular compiler option "extendedDiagnostics" is configured, however "strictTemplates" is disabled.
@@ -6595,7 +6987,7 @@ One of the following actions is required:
6595
6987
  const defaultCategory = (_a = options.extendedDiagnostics) == null ? void 0 : _a.defaultCategory;
6596
6988
  if (defaultCategory && !allowedCategoryLabels.includes(defaultCategory)) {
6597
6989
  yield makeConfigDiagnostic({
6598
- category: ts30.DiagnosticCategory.Error,
6990
+ category: ts33.DiagnosticCategory.Error,
6599
6991
  code: ErrorCode.CONFIG_EXTENDED_DIAGNOSTICS_UNKNOWN_CATEGORY_LABEL,
6600
6992
  messageText: `
6601
6993
  Angular compiler option "extendedDiagnostics.defaultCategory" has an unknown diagnostic category: "${defaultCategory}".
@@ -6609,7 +7001,7 @@ ${allowedCategoryLabels.join("\n")}
6609
7001
  for (const [checkName, category] of Object.entries((_c = (_b = options.extendedDiagnostics) == null ? void 0 : _b.checks) != null ? _c : {})) {
6610
7002
  if (!allExtendedDiagnosticNames.includes(checkName)) {
6611
7003
  yield makeConfigDiagnostic({
6612
- category: ts30.DiagnosticCategory.Error,
7004
+ category: ts33.DiagnosticCategory.Error,
6613
7005
  code: ErrorCode.CONFIG_EXTENDED_DIAGNOSTICS_UNKNOWN_CHECK,
6614
7006
  messageText: `
6615
7007
  Angular compiler option "extendedDiagnostics.checks" has an unknown check: "${checkName}".
@@ -6621,7 +7013,7 @@ ${allExtendedDiagnosticNames.join("\n")}
6621
7013
  }
6622
7014
  if (!allowedCategoryLabels.includes(category)) {
6623
7015
  yield makeConfigDiagnostic({
6624
- category: ts30.DiagnosticCategory.Error,
7016
+ category: ts33.DiagnosticCategory.Error,
6625
7017
  code: ErrorCode.CONFIG_EXTENDED_DIAGNOSTICS_UNKNOWN_CATEGORY_LABEL,
6626
7018
  messageText: `
6627
7019
  Angular compiler option "extendedDiagnostics.checks['${checkName}']" has an unknown diagnostic category: "${category}".
@@ -6651,7 +7043,7 @@ var ReferenceGraphAdapter = class {
6651
7043
  for (const { node } of references) {
6652
7044
  let sourceFile = node.getSourceFile();
6653
7045
  if (sourceFile === void 0) {
6654
- sourceFile = ts30.getOriginalNode(node).getSourceFile();
7046
+ sourceFile = ts33.getOriginalNode(node).getSourceFile();
6655
7047
  }
6656
7048
  if (sourceFile === void 0 || !isDtsPath(sourceFile.fileName)) {
6657
7049
  this.graph.add(source, node);
@@ -6690,7 +7082,7 @@ function versionMapFromProgram(program, driver) {
6690
7082
  }
6691
7083
 
6692
7084
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/core/src/host.mjs
6693
- import ts31 from "typescript";
7085
+ import ts34 from "typescript";
6694
7086
  var DelegatingCompilerHost2 = class {
6695
7087
  constructor(delegate) {
6696
7088
  this.delegate = delegate;
@@ -6780,7 +7172,7 @@ var NgCompilerHost = class extends DelegatingCompilerHost2 {
6780
7172
  entryPoint = findFlatIndexEntryPoint(normalizedTsInputFiles);
6781
7173
  if (entryPoint === null) {
6782
7174
  diagnostics.push({
6783
- category: ts31.DiagnosticCategory.Error,
7175
+ category: ts34.DiagnosticCategory.Error,
6784
7176
  code: ngErrorCode(ErrorCode.CONFIG_FLAT_MODULE_NO_INDEX),
6785
7177
  file: void 0,
6786
7178
  start: void 0,
@@ -6801,6 +7193,9 @@ var NgCompilerHost = class extends DelegatingCompilerHost2 {
6801
7193
  isShim(sf) {
6802
7194
  return isShim(sf);
6803
7195
  }
7196
+ isResource(sf) {
7197
+ return false;
7198
+ }
6804
7199
  getSourceFile(fileName, languageVersion, onError, shouldCreateNewSourceFile) {
6805
7200
  const shimSf = this.shimAdapter.maybeGenerate(resolve(fileName));
6806
7201
  if (shimSf !== null) {
@@ -6820,10 +7215,10 @@ var NgCompilerHost = class extends DelegatingCompilerHost2 {
6820
7215
  return this.fileNameToModuleName !== void 0 ? this : null;
6821
7216
  }
6822
7217
  createCachedResolveModuleNamesFunction() {
6823
- const moduleResolutionCache = ts31.createModuleResolutionCache(this.getCurrentDirectory(), this.getCanonicalFileName.bind(this));
7218
+ const moduleResolutionCache = ts34.createModuleResolutionCache(this.getCurrentDirectory(), this.getCanonicalFileName.bind(this));
6824
7219
  return (moduleNames, containingFile, reusedNames, redirectedReference, options) => {
6825
7220
  return moduleNames.map((moduleName) => {
6826
- const module = ts31.resolveModuleName(moduleName, containingFile, options, this, moduleResolutionCache, redirectedReference);
7221
+ const module = ts34.resolveModuleName(moduleName, containingFile, options, this, moduleResolutionCache, redirectedReference);
6827
7222
  return module.resolvedModule;
6828
7223
  });
6829
7224
  };
@@ -6844,7 +7239,7 @@ var NgtscProgram = class {
6844
7239
  if (reuseProgram !== void 0) {
6845
7240
  retagAllTsFiles(reuseProgram);
6846
7241
  }
6847
- this.tsProgram = perfRecorder.inPhase(PerfPhase.TypeScriptProgramCreate, () => ts32.createProgram(this.host.inputFiles, options, this.host, reuseProgram));
7242
+ this.tsProgram = perfRecorder.inPhase(PerfPhase.TypeScriptProgramCreate, () => ts35.createProgram(this.host.inputFiles, options, this.host, reuseProgram));
6848
7243
  perfRecorder.phase(PerfPhase.Unaccounted);
6849
7244
  perfRecorder.memory(PerfCheckpoint.TypeScriptProgramCreate);
6850
7245
  this.host.postProgramCreationCleanup();
@@ -7043,17 +7438,17 @@ function createProgram({ rootNames, options, host, oldProgram }) {
7043
7438
  }
7044
7439
 
7045
7440
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/perform_compile.mjs
7046
- import ts34 from "typescript";
7441
+ import ts37 from "typescript";
7047
7442
 
7048
7443
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/transformers/util.mjs
7049
- import ts33 from "typescript";
7444
+ import ts36 from "typescript";
7050
7445
  var GENERATED_FILES = /(.*?)\.(ngfactory|shim\.ngstyle|ngstyle|ngsummary)\.(js|d\.ts|ts)$/;
7051
7446
  function createMessageDiagnostic(messageText) {
7052
7447
  return {
7053
7448
  file: void 0,
7054
7449
  start: void 0,
7055
7450
  length: void 0,
7056
- category: ts33.DiagnosticCategory.Message,
7451
+ category: ts36.DiagnosticCategory.Message,
7057
7452
  messageText,
7058
7453
  code: DEFAULT_ERROR_CODE,
7059
7454
  source: SOURCE
@@ -7062,13 +7457,13 @@ function createMessageDiagnostic(messageText) {
7062
7457
 
7063
7458
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/perform_compile.mjs
7064
7459
  var defaultFormatHost = {
7065
- getCurrentDirectory: () => ts34.sys.getCurrentDirectory(),
7460
+ getCurrentDirectory: () => ts37.sys.getCurrentDirectory(),
7066
7461
  getCanonicalFileName: (fileName) => fileName,
7067
- getNewLine: () => ts34.sys.newLine
7462
+ getNewLine: () => ts37.sys.newLine
7068
7463
  };
7069
7464
  function formatDiagnostics(diags, host = defaultFormatHost) {
7070
7465
  if (diags && diags.length) {
7071
- return diags.map((diagnostic) => replaceTsWithNgInErrors(ts34.formatDiagnosticsWithColorAndContext([diagnostic], host))).join("");
7466
+ return diags.map((diagnostic) => replaceTsWithNgInErrors(ts37.formatDiagnosticsWithColorAndContext([diagnostic], host))).join("");
7072
7467
  } else {
7073
7468
  return "";
7074
7469
  }
@@ -7085,7 +7480,7 @@ function readConfiguration(project, existingOptions, host = getFileSystem()) {
7085
7480
  var _a, _b;
7086
7481
  try {
7087
7482
  const fs = getFileSystem();
7088
- const readConfigFile = (configFile) => ts34.readConfigFile(configFile, (file) => host.readFile(host.resolve(file)));
7483
+ const readConfigFile = (configFile) => ts37.readConfigFile(configFile, (file) => host.readFile(host.resolve(file)));
7089
7484
  const readAngularCompilerOptions = (configFile, parentOptions = {}) => {
7090
7485
  const { config: config2, error: error2 } = readConfigFile(configFile);
7091
7486
  if (error2) {
@@ -7117,7 +7512,7 @@ function readConfiguration(project, existingOptions, host = getFileSystem()) {
7117
7512
  basePath
7118
7513
  }, readAngularCompilerOptions(configFileName)), existingOptions);
7119
7514
  const parseConfigHost = createParseConfigHost(host, fs);
7120
- const { options, errors, fileNames: rootNames, projectReferences } = ts34.parseJsonConfigFileContent(config, parseConfigHost, basePath, existingCompilerOptions, configFileName);
7515
+ const { options, errors, fileNames: rootNames, projectReferences } = ts37.parseJsonConfigFileContent(config, parseConfigHost, basePath, existingCompilerOptions, configFileName);
7121
7516
  options.enableIvy = !!((_a = options.enableIvy) != null ? _a : true);
7122
7517
  let emitFlags = EmitFlags.Default;
7123
7518
  if (!(options.skipMetadataEmit || options.flatModuleOutFile)) {
@@ -7129,7 +7524,7 @@ function readConfiguration(project, existingOptions, host = getFileSystem()) {
7129
7524
  return { project: projectFile, rootNames, projectReferences, options, errors, emitFlags };
7130
7525
  } catch (e) {
7131
7526
  const errors = [{
7132
- category: ts34.DiagnosticCategory.Error,
7527
+ category: ts37.DiagnosticCategory.Error,
7133
7528
  messageText: (_b = e.stack) != null ? _b : e.message,
7134
7529
  file: void 0,
7135
7530
  start: void 0,
@@ -7143,7 +7538,7 @@ function readConfiguration(project, existingOptions, host = getFileSystem()) {
7143
7538
  function createParseConfigHost(host, fs = getFileSystem()) {
7144
7539
  return {
7145
7540
  fileExists: host.exists.bind(host),
7146
- readDirectory: ts34.sys.readDirectory,
7541
+ readDirectory: ts37.sys.readDirectory,
7147
7542
  readFile: host.readFile.bind(host),
7148
7543
  useCaseSensitiveFileNames: fs.isCaseSensitive()
7149
7544
  };
@@ -7163,7 +7558,7 @@ function getExtendedConfigPathWorker(configFile, extendsValue, host, fs) {
7163
7558
  }
7164
7559
  } else {
7165
7560
  const parseConfigHost = createParseConfigHost(host, fs);
7166
- const { resolvedModule } = ts34.nodeModuleNameResolver(extendsValue, configFile, { moduleResolution: ts34.ModuleResolutionKind.NodeJs, resolveJsonModule: true }, parseConfigHost);
7561
+ const { resolvedModule } = ts37.nodeModuleNameResolver(extendsValue, configFile, { moduleResolution: ts37.ModuleResolutionKind.NodeJs, resolveJsonModule: true }, parseConfigHost);
7167
7562
  if (resolvedModule) {
7168
7563
  return absoluteFrom(resolvedModule.resolvedFileName);
7169
7564
  }
@@ -7173,7 +7568,7 @@ function getExtendedConfigPathWorker(configFile, extendsValue, host, fs) {
7173
7568
  function exitCodeFromResult(diags) {
7174
7569
  if (!diags)
7175
7570
  return 0;
7176
- if (diags.every((diag) => diag.category !== ts34.DiagnosticCategory.Error)) {
7571
+ if (diags.every((diag) => diag.category !== ts37.DiagnosticCategory.Error)) {
7177
7572
  return 0;
7178
7573
  }
7179
7574
  return diags.some((d) => d.source === "angular" && d.code === UNKNOWN_ERROR_CODE) ? 2 : 1;
@@ -7206,7 +7601,7 @@ function performCompilation({ rootNames, options, host, oldProgram, emitCallback
7206
7601
  } catch (e) {
7207
7602
  program = void 0;
7208
7603
  allDiagnostics.push({
7209
- category: ts34.DiagnosticCategory.Error,
7604
+ category: ts37.DiagnosticCategory.Error,
7210
7605
  messageText: (_a = e.stack) != null ? _a : e.message,
7211
7606
  code: UNKNOWN_ERROR_CODE,
7212
7607
  file: void 0,
@@ -7233,7 +7628,7 @@ function defaultGatherDiagnostics(program) {
7233
7628
  return allDiagnostics;
7234
7629
  }
7235
7630
  function hasErrors(diags) {
7236
- return diags.some((d) => d.category === ts34.DiagnosticCategory.Error);
7631
+ return diags.some((d) => d.category === ts37.DiagnosticCategory.Error);
7237
7632
  }
7238
7633
 
7239
7634
  export {
@@ -7245,6 +7640,8 @@ export {
7245
7640
  createCompilerHost,
7246
7641
  CycleAnalyzer,
7247
7642
  ImportGraph,
7643
+ isShim,
7644
+ untagAllTsFiles,
7248
7645
  TsCreateProgramDriver,
7249
7646
  PatchedProgramIncrementalBuildStrategy,
7250
7647
  MetadataDtsModuleScopeResolver,
@@ -7273,4 +7670,5 @@ export {
7273
7670
  * Use of this source code is governed by an MIT-style license that can be
7274
7671
  * found in the LICENSE file at https://angular.io/license
7275
7672
  */
7276
- //# sourceMappingURL=chunk-6DYPLTK7.js.map
7673
+ // Closure Compiler ignores @suppress and similar if the comment contains @license.
7674
+ //# sourceMappingURL=chunk-ZPZWKMTE.js.map