@angular/compiler-cli 20.0.1 → 20.1.0-next.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/bundles/{chunk-M3WWDK6S.js → chunk-CZ5FD3CS.js} +4 -15
  2. package/bundles/{chunk-M3WWDK6S.js.map → chunk-CZ5FD3CS.js.map} +1 -1
  3. package/bundles/{chunk-QAGJD3X3.js → chunk-FPJJEIPU.js} +2 -2
  4. package/bundles/{chunk-C5GIHHVB.js → chunk-FYR5CLCG.js} +5 -5
  5. package/bundles/{chunk-C5GIHHVB.js.map → chunk-FYR5CLCG.js.map} +1 -1
  6. package/bundles/{chunk-4OIPE63R.js → chunk-N3B6BMGR.js} +30 -30
  7. package/bundles/{chunk-4OIPE63R.js.map → chunk-N3B6BMGR.js.map} +1 -1
  8. package/bundles/{chunk-NODL47CE.js → chunk-OVACIG5Q.js} +3 -3
  9. package/bundles/{chunk-NODL47CE.js.map → chunk-OVACIG5Q.js.map} +1 -1
  10. package/bundles/{chunk-KGJOQ7ZK.js → chunk-PG2VUSMN.js} +161 -324
  11. package/bundles/chunk-PG2VUSMN.js.map +6 -0
  12. package/bundles/{chunk-3TXROOKD.js → chunk-UMD7AW7S.js} +1720 -883
  13. package/bundles/chunk-UMD7AW7S.js.map +6 -0
  14. package/bundles/index.js +19 -21
  15. package/bundles/index.js.map +2 -2
  16. package/bundles/linker/babel/index.js +9 -9
  17. package/bundles/linker/babel/index.js.map +1 -1
  18. package/bundles/linker/index.js +2 -2
  19. package/bundles/private/migrations.js +2 -3
  20. package/bundles/private/tooling.js +4 -5
  21. package/bundles/src/bin/ng_xi18n.js +8 -9
  22. package/bundles/src/bin/ng_xi18n.js.map +2 -2
  23. package/bundles/src/bin/ngc.js +6 -7
  24. package/bundles/src/bin/ngc.js.map +2 -2
  25. package/linker/src/file_linker/partial_linkers/util.d.ts +1 -1
  26. package/package.json +2 -6
  27. package/src/ngtsc/annotations/component/src/handler.d.ts +5 -2
  28. package/src/ngtsc/annotations/component/src/metadata.d.ts +7 -0
  29. package/src/ngtsc/annotations/component/src/selectorless.d.ts +16 -0
  30. package/src/ngtsc/annotations/directive/src/handler.d.ts +2 -1
  31. package/src/ngtsc/annotations/directive/src/shared.d.ts +2 -2
  32. package/src/ngtsc/annotations/ng_module/src/handler.d.ts +2 -1
  33. package/src/ngtsc/annotations/src/pipe.d.ts +1 -1
  34. package/src/ngtsc/core/api/src/public_options.d.ts +13 -0
  35. package/src/ngtsc/core/src/compiler.d.ts +1 -0
  36. package/src/ngtsc/diagnostics/src/error_code.d.ts +4 -0
  37. package/src/ngtsc/docs/src/entities.d.ts +1 -1
  38. package/src/ngtsc/indexer/src/api.d.ts +20 -8
  39. package/src/ngtsc/metadata/src/api.d.ts +9 -3
  40. package/src/ngtsc/scope/index.d.ts +2 -1
  41. package/src/ngtsc/scope/src/api.d.ts +12 -2
  42. package/src/ngtsc/scope/src/selectorless_scope.d.ts +25 -0
  43. package/src/ngtsc/scope/src/typecheck.d.ts +5 -3
  44. package/src/ngtsc/transform/index.d.ts +1 -0
  45. package/src/ngtsc/transform/src/api.d.ts +0 -2
  46. package/src/ngtsc/transform/src/compilation.d.ts +2 -1
  47. package/src/ngtsc/transform/src/implicit_signal_debug_name_transform.d.ts +74 -0
  48. package/src/ngtsc/transform/src/transform.d.ts +1 -1
  49. package/src/ngtsc/translator/src/translator.d.ts +0 -3
  50. package/src/ngtsc/typecheck/api/api.d.ts +3 -0
  51. package/src/ngtsc/typecheck/api/checker.d.ts +24 -6
  52. package/src/ngtsc/typecheck/api/scope.d.ts +17 -1
  53. package/src/ngtsc/typecheck/api/symbols.d.ts +39 -3
  54. package/src/ngtsc/typecheck/src/checker.d.ts +12 -4
  55. package/src/ngtsc/typecheck/src/completion.d.ts +7 -2
  56. package/src/ngtsc/typecheck/src/oob.d.ts +3 -3
  57. package/src/ngtsc/typecheck/src/template_symbol_builder.d.ts +6 -2
  58. package/bundles/chunk-3TXROOKD.js.map +0 -6
  59. package/bundles/chunk-KGJOQ7ZK.js.map +0 -6
  60. package/bundles/chunk-WUCT7QTW.js +0 -216
  61. package/bundles/chunk-WUCT7QTW.js.map +0 -6
  62. package/bundles/private/bazel.js +0 -19
  63. package/bundles/private/bazel.js.map +0 -6
  64. package/private/babel.d.ts +0 -28
  65. package/private/bazel.d.ts +0 -12
  66. /package/bundles/{chunk-QAGJD3X3.js.map → chunk-FPJJEIPU.js.map} +0 -0
@@ -4,9 +4,10 @@
4
4
 
5
5
  import {
6
6
  angularJitApplicationTransform
7
- } from "./chunk-QAGJD3X3.js";
7
+ } from "./chunk-FPJJEIPU.js";
8
8
  import {
9
9
  AbsoluteModuleStrategy,
10
+ ActivePerfRecorder,
10
11
  AliasStrategy,
11
12
  COMPILER_ERRORS_WITH_GUIDES,
12
13
  CompilationMode,
@@ -17,6 +18,7 @@ import {
17
18
  CompoundMetadataRegistry,
18
19
  DefaultImportTracker,
19
20
  DeferredSymbolTracker,
21
+ DelegatingPerfRecorder,
20
22
  DirectiveDecoratorHandler,
21
23
  DtsMetadataReader,
22
24
  DtsTransformRegistry,
@@ -46,6 +48,9 @@ import {
46
48
  OUTPUT_INITIALIZER_FNS,
47
49
  OptimizeFor,
48
50
  PartialEvaluator,
51
+ PerfCheckpoint,
52
+ PerfEvent,
53
+ PerfPhase,
49
54
  PipeDecoratorHandler,
50
55
  PrivateExportAliasingHost,
51
56
  QUERY_INITIALIZER_FNS,
@@ -54,6 +59,7 @@ import {
54
59
  ReferenceEmitter,
55
60
  RelativePathStrategy,
56
61
  ResourceRegistry,
62
+ SelectorlessComponentScopeReader,
57
63
  SemanticDepGraphUpdater,
58
64
  ShimAdapter,
59
65
  ShimReferenceTagger,
@@ -82,17 +88,11 @@ import {
82
88
  relativePathBetween,
83
89
  replaceTsWithNgInErrors,
84
90
  retagAllTsFiles,
91
+ signalMetadataTransform,
85
92
  toUnredirectedSourceFile,
86
93
  tryParseInitializerApi,
87
94
  untagAllTsFiles
88
- } from "./chunk-3TXROOKD.js";
89
- import {
90
- ActivePerfRecorder,
91
- DelegatingPerfRecorder,
92
- PerfCheckpoint,
93
- PerfEvent,
94
- PerfPhase
95
- } from "./chunk-WUCT7QTW.js";
95
+ } from "./chunk-UMD7AW7S.js";
96
96
  import {
97
97
  LogicalFileSystem,
98
98
  absoluteFrom,
@@ -104,7 +104,7 @@ import {
104
104
  resolve
105
105
  } from "./chunk-3AHGFMNS.js";
106
106
 
107
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/api.mjs
107
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/api.js
108
108
  var DEFAULT_ERROR_CODE = 100;
109
109
  var UNKNOWN_ERROR_CODE = 500;
110
110
  var SOURCE = "angular";
@@ -122,7 +122,7 @@ var EmitFlags;
122
122
  EmitFlags2[EmitFlags2["All"] = 31] = "All";
123
123
  })(EmitFlags || (EmitFlags = {}));
124
124
 
125
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/compiler_host.mjs
125
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/compiler_host.js
126
126
  import ts from "typescript";
127
127
  var wrapHostForTest = null;
128
128
  function createCompilerHost({ options, tsHost = ts.createCompilerHost(options, true) }) {
@@ -1087,11 +1087,11 @@ function getRelativeFilePath(sourceFile, rootDir) {
1087
1087
  return relativePath;
1088
1088
  }
1089
1089
 
1090
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/program.mjs
1090
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/program.js
1091
1091
  import { HtmlParser, MessageBundle } from "@angular/compiler";
1092
1092
  import ts27 from "typescript";
1093
1093
 
1094
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/i18n.mjs
1094
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/i18n.js
1095
1095
  import { Xliff, Xliff2, Xmb } from "@angular/compiler";
1096
1096
  import * as path from "path";
1097
1097
  function i18nGetExtension(formatName) {
@@ -1142,10 +1142,10 @@ function getPathNormalizer(basePath) {
1142
1142
  };
1143
1143
  }
1144
1144
 
1145
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/typescript_support.mjs
1145
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/typescript_support.js
1146
1146
  import ts13 from "typescript";
1147
1147
 
1148
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/version_helpers.mjs
1148
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/version_helpers.js
1149
1149
  function toNumbers(value) {
1150
1150
  const suffixIndex = value.lastIndexOf("-");
1151
1151
  return value.slice(0, suffixIndex === -1 ? value.length : suffixIndex).split(".").map((segment) => {
@@ -1180,7 +1180,7 @@ function compareVersions(v1, v2) {
1180
1180
  return compareNumbers(toNumbers(v1), toNumbers(v2));
1181
1181
  }
1182
1182
 
1183
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/typescript_support.mjs
1183
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/typescript_support.js
1184
1184
  var MIN_TS_VERSION = "5.8.0";
1185
1185
  var MAX_TS_VERSION = "5.9.0";
1186
1186
  var tsVersion = ts13.version;
@@ -1869,6 +1869,8 @@ var IdentifierKind;
1869
1869
  IdentifierKind2[IdentifierKind2["Reference"] = 5] = "Reference";
1870
1870
  IdentifierKind2[IdentifierKind2["Variable"] = 6] = "Variable";
1871
1871
  IdentifierKind2[IdentifierKind2["LetDeclaration"] = 7] = "LetDeclaration";
1872
+ IdentifierKind2[IdentifierKind2["Component"] = 8] = "Component";
1873
+ IdentifierKind2[IdentifierKind2["Directive"] = 9] = "Directive";
1872
1874
  })(IdentifierKind || (IdentifierKind = {}));
1873
1875
  var AbsoluteSourceSpan = class {
1874
1876
  start;
@@ -1891,203 +1893,100 @@ var IndexingContext = class {
1891
1893
  import { ParseSourceFile } from "@angular/compiler";
1892
1894
 
1893
1895
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/indexer/src/template.js
1894
- import { ASTWithSource, ImplicitReceiver, PropertyRead, PropertyWrite, RecursiveAstVisitor, TmplAstBoundDeferredTrigger, TmplAstComponent, TmplAstDirective, TmplAstElement, TmplAstRecursiveVisitor, TmplAstReference, TmplAstTemplate, TmplAstVariable } from "@angular/compiler";
1895
- var ExpressionVisitor = class extends RecursiveAstVisitor {
1896
- expressionStr;
1897
- absoluteOffset;
1898
- boundTemplate;
1899
- targetToIdentifier;
1900
- identifiers = [];
1901
- errors = [];
1902
- constructor(expressionStr, absoluteOffset, boundTemplate, targetToIdentifier) {
1903
- super();
1904
- this.expressionStr = expressionStr;
1905
- this.absoluteOffset = absoluteOffset;
1906
- this.boundTemplate = boundTemplate;
1907
- this.targetToIdentifier = targetToIdentifier;
1908
- }
1909
- static getIdentifiers(ast, source, absoluteOffset, boundTemplate, targetToIdentifier) {
1910
- const visitor = new ExpressionVisitor(source, absoluteOffset, boundTemplate, targetToIdentifier);
1911
- visitor.visit(ast);
1912
- return { identifiers: visitor.identifiers, errors: visitor.errors };
1913
- }
1914
- visit(ast) {
1915
- ast.visit(this);
1916
- }
1917
- visitPropertyRead(ast, context) {
1918
- this.visitIdentifier(ast, IdentifierKind.Property);
1919
- super.visitPropertyRead(ast, context);
1920
- }
1921
- visitPropertyWrite(ast, context) {
1922
- this.visitIdentifier(ast, IdentifierKind.Property);
1923
- super.visitPropertyWrite(ast, context);
1924
- }
1925
- visitIdentifier(ast, kind) {
1926
- if (!(ast.receiver instanceof ImplicitReceiver)) {
1927
- return;
1928
- }
1929
- let identifierStart = ast.sourceSpan.start - this.absoluteOffset;
1930
- if (ast instanceof PropertyRead || ast instanceof PropertyWrite) {
1931
- identifierStart = ast.nameSpan.start - this.absoluteOffset;
1932
- }
1933
- if (!this.expressionStr.substring(identifierStart).startsWith(ast.name)) {
1934
- this.errors.push(new Error(`Impossible state: "${ast.name}" not found in "${this.expressionStr}" at location ${identifierStart}`));
1935
- return;
1936
- }
1937
- const absoluteStart = this.absoluteOffset + identifierStart;
1938
- const span = new AbsoluteSourceSpan(absoluteStart, absoluteStart + ast.name.length);
1939
- const targetAst = this.boundTemplate.getExpressionTarget(ast);
1940
- const target = targetAst ? this.targetToIdentifier(targetAst) : null;
1941
- const identifier = {
1942
- name: ast.name,
1943
- span,
1944
- kind,
1945
- target
1946
- };
1947
- this.identifiers.push(identifier);
1948
- }
1949
- };
1950
- var TemplateVisitor = class extends TmplAstRecursiveVisitor {
1896
+ import { ASTWithSource, CombinedRecursiveAstVisitor, ImplicitReceiver, PropertyRead, TmplAstComponent, TmplAstDirective, TmplAstElement, TmplAstReference, TmplAstTemplate, TmplAstVariable, tmplAstVisitAll } from "@angular/compiler";
1897
+ var TemplateVisitor = class extends CombinedRecursiveAstVisitor {
1951
1898
  boundTemplate;
1952
1899
  identifiers = /* @__PURE__ */ new Set();
1953
1900
  errors = [];
1901
+ currentAstWithSource = null;
1954
1902
  targetIdentifierCache = /* @__PURE__ */ new Map();
1955
- elementAndTemplateIdentifierCache = /* @__PURE__ */ new Map();
1903
+ directiveHostIdentifierCache = /* @__PURE__ */ new Map();
1956
1904
  constructor(boundTemplate) {
1957
1905
  super();
1958
1906
  this.boundTemplate = boundTemplate;
1959
1907
  }
1960
- visit(node) {
1961
- node.visit(this);
1962
- }
1963
- visitAll(nodes) {
1964
- nodes.forEach((node) => this.visit(node));
1965
- }
1966
1908
  visitElement(element) {
1967
- const elementIdentifier = this.elementOrTemplateToIdentifier(element);
1909
+ const elementIdentifier = this.directiveHostToIdentifier(element);
1968
1910
  if (elementIdentifier !== null) {
1969
1911
  this.identifiers.add(elementIdentifier);
1970
1912
  }
1971
- this.visitAll(element.references);
1972
- this.visitAll(element.inputs);
1973
- this.visitAll(element.attributes);
1974
- this.visitAll(element.directives);
1975
- this.visitAll(element.children);
1976
- this.visitAll(element.outputs);
1913
+ super.visitElement(element);
1977
1914
  }
1978
1915
  visitTemplate(template) {
1979
- const templateIdentifier = this.elementOrTemplateToIdentifier(template);
1916
+ const templateIdentifier = this.directiveHostToIdentifier(template);
1980
1917
  if (templateIdentifier !== null) {
1981
1918
  this.identifiers.add(templateIdentifier);
1982
1919
  }
1983
- this.visitAll(template.directives);
1984
- this.visitAll(template.variables);
1985
- this.visitAll(template.attributes);
1986
- this.visitAll(template.templateAttrs);
1987
- this.visitAll(template.children);
1988
- this.visitAll(template.references);
1989
- }
1990
- visitBoundAttribute(attribute) {
1991
- if (attribute.valueSpan === void 0) {
1992
- return;
1993
- }
1994
- const { identifiers, errors } = ExpressionVisitor.getIdentifiers(attribute.value, attribute.valueSpan.toString(), attribute.valueSpan.start.offset, this.boundTemplate, this.targetToIdentifier.bind(this));
1995
- identifiers.forEach((id) => this.identifiers.add(id));
1996
- this.errors.push(...errors);
1997
- }
1998
- visitBoundEvent(attribute) {
1999
- this.visitExpression(attribute.handler);
2000
- }
2001
- visitBoundText(text) {
2002
- this.visitExpression(text.value);
1920
+ super.visitTemplate(template);
2003
1921
  }
2004
1922
  visitReference(reference) {
2005
1923
  const referenceIdentifier = this.targetToIdentifier(reference);
2006
- if (referenceIdentifier === null) {
2007
- return;
1924
+ if (referenceIdentifier !== null) {
1925
+ this.identifiers.add(referenceIdentifier);
2008
1926
  }
2009
- this.identifiers.add(referenceIdentifier);
1927
+ super.visitReference(reference);
2010
1928
  }
2011
1929
  visitVariable(variable) {
2012
1930
  const variableIdentifier = this.targetToIdentifier(variable);
2013
- if (variableIdentifier === null) {
2014
- return;
1931
+ if (variableIdentifier !== null) {
1932
+ this.identifiers.add(variableIdentifier);
2015
1933
  }
2016
- this.identifiers.add(variableIdentifier);
2017
- }
2018
- visitDeferredBlock(deferred) {
2019
- deferred.visitAll(this);
2020
- }
2021
- visitDeferredBlockPlaceholder(block) {
2022
- this.visitAll(block.children);
2023
- }
2024
- visitDeferredBlockError(block) {
2025
- this.visitAll(block.children);
2026
- }
2027
- visitDeferredBlockLoading(block) {
2028
- this.visitAll(block.children);
2029
- }
2030
- visitDeferredTrigger(trigger) {
2031
- if (trigger instanceof TmplAstBoundDeferredTrigger) {
2032
- this.visitExpression(trigger.value);
2033
- }
2034
- }
2035
- visitSwitchBlock(block) {
2036
- this.visitExpression(block.expression);
2037
- this.visitAll(block.cases);
2038
- }
2039
- visitSwitchBlockCase(block) {
2040
- block.expression && this.visitExpression(block.expression);
2041
- this.visitAll(block.children);
2042
- }
2043
- visitForLoopBlock(block) {
2044
- block.item.visit(this);
2045
- this.visitAll(block.contextVariables);
2046
- this.visitExpression(block.expression);
2047
- this.visitAll(block.children);
2048
- block.empty?.visit(this);
2049
- }
2050
- visitForLoopBlockEmpty(block) {
2051
- this.visitAll(block.children);
2052
- }
2053
- visitIfBlock(block) {
2054
- this.visitAll(block.branches);
2055
- }
2056
- visitIfBlockBranch(block) {
2057
- block.expression && this.visitExpression(block.expression);
2058
- block.expressionAlias?.visit(this);
2059
- this.visitAll(block.children);
1934
+ super.visitVariable(variable);
2060
1935
  }
2061
1936
  visitLetDeclaration(decl) {
2062
1937
  const identifier = this.targetToIdentifier(decl);
2063
1938
  if (identifier !== null) {
2064
1939
  this.identifiers.add(identifier);
2065
1940
  }
2066
- this.visitExpression(decl.value);
1941
+ super.visitLetDeclaration(decl);
2067
1942
  }
2068
1943
  visitComponent(component) {
2069
- throw new Error("TODO");
1944
+ const identifier = this.directiveHostToIdentifier(component);
1945
+ if (identifier !== null) {
1946
+ this.identifiers.add(identifier);
1947
+ }
1948
+ super.visitComponent(component);
2070
1949
  }
2071
1950
  visitDirective(directive) {
2072
- throw new Error("TODO");
2073
- }
2074
- elementOrTemplateToIdentifier(node) {
2075
- if (node instanceof TmplAstComponent || node instanceof TmplAstDirective) {
2076
- throw new Error("TODO");
1951
+ const identifier = this.directiveHostToIdentifier(directive);
1952
+ if (identifier !== null) {
1953
+ this.identifiers.add(identifier);
2077
1954
  }
2078
- if (this.elementAndTemplateIdentifierCache.has(node)) {
2079
- return this.elementAndTemplateIdentifierCache.get(node);
1955
+ super.visitDirective(directive);
1956
+ }
1957
+ visitPropertyRead(ast) {
1958
+ this.visitIdentifier(ast, IdentifierKind.Property);
1959
+ super.visitPropertyRead(ast, null);
1960
+ }
1961
+ visitBoundAttribute(attribute) {
1962
+ const previous = this.currentAstWithSource;
1963
+ this.currentAstWithSource = {
1964
+ source: attribute.valueSpan?.toString() || null,
1965
+ absoluteOffset: attribute.valueSpan ? attribute.valueSpan.start.offset : -1
1966
+ };
1967
+ this.visit(attribute.value instanceof ASTWithSource ? attribute.value.ast : attribute.value);
1968
+ this.currentAstWithSource = previous;
1969
+ }
1970
+ directiveHostToIdentifier(node) {
1971
+ if (this.directiveHostIdentifierCache.has(node)) {
1972
+ return this.directiveHostIdentifierCache.get(node);
2080
1973
  }
2081
1974
  let name;
2082
1975
  let kind;
2083
1976
  if (node instanceof TmplAstTemplate) {
2084
1977
  name = node.tagName ?? "ng-template";
2085
1978
  kind = IdentifierKind.Template;
2086
- } else {
1979
+ } else if (node instanceof TmplAstElement) {
2087
1980
  name = node.name;
2088
1981
  kind = IdentifierKind.Element;
1982
+ } else if (node instanceof TmplAstComponent) {
1983
+ name = node.fullName;
1984
+ kind = IdentifierKind.Component;
1985
+ } else {
1986
+ name = node.name;
1987
+ kind = IdentifierKind.Directive;
2089
1988
  }
2090
- if (name.startsWith(":")) {
1989
+ if ((node instanceof TmplAstTemplate || node instanceof TmplAstElement) && name.startsWith(":")) {
2091
1990
  name = name.split(":").pop();
2092
1991
  }
2093
1992
  const sourceSpan = node.startSourceSpan;
@@ -2116,7 +2015,7 @@ var TemplateVisitor = class extends TmplAstRecursiveVisitor {
2116
2015
  };
2117
2016
  }))
2118
2017
  };
2119
- this.elementAndTemplateIdentifierCache.set(node, identifier);
2018
+ this.directiveHostIdentifierCache.set(node, identifier);
2120
2019
  return identifier;
2121
2020
  }
2122
2021
  targetToIdentifier(node) {
@@ -2137,9 +2036,9 @@ var TemplateVisitor = class extends TmplAstRecursiveVisitor {
2137
2036
  let node2 = null;
2138
2037
  let directive = null;
2139
2038
  if (refTarget instanceof TmplAstElement || refTarget instanceof TmplAstTemplate || refTarget instanceof TmplAstComponent || refTarget instanceof TmplAstDirective) {
2140
- node2 = this.elementOrTemplateToIdentifier(refTarget);
2039
+ node2 = this.directiveHostToIdentifier(refTarget);
2141
2040
  } else {
2142
- node2 = this.elementOrTemplateToIdentifier(refTarget.node);
2041
+ node2 = this.directiveHostToIdentifier(refTarget.node);
2143
2042
  directive = refTarget.directive.ref.node;
2144
2043
  }
2145
2044
  if (node2 === null) {
@@ -2180,20 +2079,49 @@ var TemplateVisitor = class extends TmplAstRecursiveVisitor {
2180
2079
  }
2181
2080
  return context.start.offset + localStr.indexOf(name);
2182
2081
  }
2183
- visitExpression(ast) {
2184
- if (ast instanceof ASTWithSource && ast.source !== null) {
2185
- const targetToIdentifier = this.targetToIdentifier.bind(this);
2186
- const absoluteOffset = ast.sourceSpan.start;
2187
- const { identifiers, errors } = ExpressionVisitor.getIdentifiers(ast, ast.source, absoluteOffset, this.boundTemplate, targetToIdentifier);
2188
- identifiers.forEach((id) => this.identifiers.add(id));
2189
- this.errors.push(...errors);
2082
+ visit(node) {
2083
+ if (node instanceof ASTWithSource) {
2084
+ const previous = this.currentAstWithSource;
2085
+ this.currentAstWithSource = { source: node.source, absoluteOffset: node.sourceSpan.start };
2086
+ super.visit(node.ast);
2087
+ this.currentAstWithSource = previous;
2088
+ } else {
2089
+ super.visit(node);
2190
2090
  }
2191
2091
  }
2092
+ visitIdentifier(ast, kind) {
2093
+ if (this.currentAstWithSource === null || this.currentAstWithSource.source === null) {
2094
+ return;
2095
+ }
2096
+ if (!(ast.receiver instanceof ImplicitReceiver)) {
2097
+ return;
2098
+ }
2099
+ const { absoluteOffset, source: expressionStr } = this.currentAstWithSource;
2100
+ let identifierStart = ast.sourceSpan.start - absoluteOffset;
2101
+ if (ast instanceof PropertyRead) {
2102
+ identifierStart = ast.nameSpan.start - absoluteOffset;
2103
+ }
2104
+ if (!expressionStr.substring(identifierStart).startsWith(ast.name)) {
2105
+ this.errors.push(new Error(`Impossible state: "${ast.name}" not found in "${expressionStr}" at location ${identifierStart}`));
2106
+ return;
2107
+ }
2108
+ const absoluteStart = absoluteOffset + identifierStart;
2109
+ const span = new AbsoluteSourceSpan(absoluteStart, absoluteStart + ast.name.length);
2110
+ const targetAst = this.boundTemplate.getExpressionTarget(ast);
2111
+ const target = targetAst ? this.targetToIdentifier(targetAst) : null;
2112
+ const identifier = {
2113
+ name: ast.name,
2114
+ span,
2115
+ kind,
2116
+ target
2117
+ };
2118
+ this.identifiers.add(identifier);
2119
+ }
2192
2120
  };
2193
2121
  function getTemplateIdentifiers(boundTemplate) {
2194
2122
  const visitor = new TemplateVisitor(boundTemplate);
2195
2123
  if (boundTemplate.target.template !== void 0) {
2196
- visitor.visitAll(boundTemplate.target.template);
2124
+ tmplAstVisitAll(visitor, boundTemplate.target.template);
2197
2125
  }
2198
2126
  return { identifiers: visitor.identifiers, errors: visitor.errors };
2199
2127
  }
@@ -2496,7 +2424,7 @@ var StandaloneComponentScopeReader = class {
2496
2424
  if (!this.cache.has(clazz)) {
2497
2425
  const clazzRef = new Reference(clazz);
2498
2426
  const clazzMeta = this.metaReader.getDirectiveMetadata(clazzRef);
2499
- if (clazzMeta === null || !clazzMeta.isComponent || !clazzMeta.isStandalone) {
2427
+ if (clazzMeta === null || !clazzMeta.isComponent || !clazzMeta.isStandalone || clazzMeta.selectorlessEnabled) {
2500
2428
  this.cache.set(clazz, null);
2501
2429
  return null;
2502
2430
  }
@@ -2580,7 +2508,7 @@ var StandaloneComponentScopeReader = class {
2580
2508
  };
2581
2509
 
2582
2510
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/checks/interpolated_signal_not_invoked/index.js
2583
- import { ASTWithSource as ASTWithSource3, BindingType, Interpolation, PropertyRead as PropertyRead2, TmplAstBoundAttribute } from "@angular/compiler";
2511
+ import { ASTWithSource as ASTWithSource2, BindingType, Interpolation, PropertyRead as PropertyRead2, TmplAstBoundAttribute } from "@angular/compiler";
2584
2512
 
2585
2513
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/src/symbol_util.js
2586
2514
  import ts18 from "typescript";
@@ -2603,7 +2531,7 @@ function isSignalSymbol(symbol) {
2603
2531
  }
2604
2532
 
2605
2533
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/api/api.js
2606
- import { ASTWithSource as ASTWithSource2, RecursiveAstVisitor as RecursiveAstVisitor2, TmplAstBoundDeferredTrigger as TmplAstBoundDeferredTrigger2 } from "@angular/compiler";
2534
+ import { CombinedRecursiveAstVisitor as CombinedRecursiveAstVisitor2 } from "@angular/compiler";
2607
2535
  var TemplateCheckWithVisitor = class {
2608
2536
  canVisitStructuralAttributes = true;
2609
2537
  run(ctx, component, template) {
@@ -2611,7 +2539,7 @@ var TemplateCheckWithVisitor = class {
2611
2539
  return visitor.getDiagnostics(template);
2612
2540
  }
2613
2541
  };
2614
- var TemplateVisitor2 = class extends RecursiveAstVisitor2 {
2542
+ var TemplateVisitor2 = class extends CombinedRecursiveAstVisitor2 {
2615
2543
  ctx;
2616
2544
  component;
2617
2545
  check;
@@ -2622,133 +2550,28 @@ var TemplateVisitor2 = class extends RecursiveAstVisitor2 {
2622
2550
  this.component = component;
2623
2551
  this.check = check;
2624
2552
  }
2625
- visit(node, context) {
2553
+ visit(node) {
2626
2554
  this.diagnostics.push(...this.check.visitNode(this.ctx, this.component, node));
2627
- node.visit(this);
2628
- }
2629
- visitAllNodes(nodes) {
2630
- for (const node of nodes) {
2631
- this.visit(node);
2632
- }
2633
- }
2634
- visitAst(ast) {
2635
- if (ast instanceof ASTWithSource2) {
2636
- ast = ast.ast;
2637
- }
2638
- this.visit(ast);
2639
- }
2640
- visitElement(element) {
2641
- this.visitAllNodes(element.attributes);
2642
- this.visitAllNodes(element.inputs);
2643
- this.visitAllNodes(element.outputs);
2644
- this.visitAllNodes(element.directives);
2645
- this.visitAllNodes(element.references);
2646
- this.visitAllNodes(element.children);
2555
+ super.visit(node);
2647
2556
  }
2648
2557
  visitTemplate(template) {
2649
2558
  const isInlineTemplate = template.tagName === "ng-template";
2650
- this.visitAllNodes(template.attributes);
2559
+ this.visitAllTemplateNodes(template.attributes);
2651
2560
  if (isInlineTemplate) {
2652
- this.visitAllNodes(template.inputs);
2653
- this.visitAllNodes(template.outputs);
2561
+ this.visitAllTemplateNodes(template.inputs);
2562
+ this.visitAllTemplateNodes(template.outputs);
2654
2563
  }
2655
- this.visitAllNodes(template.directives);
2564
+ this.visitAllTemplateNodes(template.directives);
2656
2565
  if (this.check.canVisitStructuralAttributes || isInlineTemplate) {
2657
- this.visitAllNodes(template.templateAttrs);
2566
+ this.visitAllTemplateNodes(template.templateAttrs);
2658
2567
  }
2659
- this.visitAllNodes(template.variables);
2660
- this.visitAllNodes(template.references);
2661
- this.visitAllNodes(template.children);
2662
- }
2663
- visitContent(content) {
2664
- this.visitAllNodes(content.children);
2665
- }
2666
- visitVariable(variable) {
2667
- }
2668
- visitReference(reference) {
2669
- }
2670
- visitTextAttribute(attribute) {
2671
- }
2672
- visitUnknownBlock(block) {
2673
- }
2674
- visitBoundAttribute(attribute) {
2675
- this.visitAst(attribute.value);
2676
- }
2677
- visitBoundEvent(attribute) {
2678
- this.visitAst(attribute.handler);
2679
- }
2680
- visitText(text) {
2681
- }
2682
- visitBoundText(text) {
2683
- this.visitAst(text.value);
2684
- }
2685
- visitIcu(icu) {
2686
- Object.keys(icu.vars).forEach((key) => this.visit(icu.vars[key]));
2687
- Object.keys(icu.placeholders).forEach((key) => this.visit(icu.placeholders[key]));
2688
- }
2689
- visitDeferredBlock(deferred) {
2690
- deferred.visitAll(this);
2691
- }
2692
- visitDeferredTrigger(trigger) {
2693
- if (trigger instanceof TmplAstBoundDeferredTrigger2) {
2694
- this.visitAst(trigger.value);
2695
- }
2696
- }
2697
- visitDeferredBlockPlaceholder(block) {
2698
- this.visitAllNodes(block.children);
2699
- }
2700
- visitDeferredBlockError(block) {
2701
- this.visitAllNodes(block.children);
2702
- }
2703
- visitDeferredBlockLoading(block) {
2704
- this.visitAllNodes(block.children);
2705
- }
2706
- visitSwitchBlock(block) {
2707
- this.visitAst(block.expression);
2708
- this.visitAllNodes(block.cases);
2709
- }
2710
- visitSwitchBlockCase(block) {
2711
- block.expression && this.visitAst(block.expression);
2712
- this.visitAllNodes(block.children);
2713
- }
2714
- visitForLoopBlock(block) {
2715
- block.item.visit(this);
2716
- this.visitAllNodes(block.contextVariables);
2717
- this.visitAst(block.expression);
2718
- this.visitAllNodes(block.children);
2719
- block.empty?.visit(this);
2720
- }
2721
- visitForLoopBlockEmpty(block) {
2722
- this.visitAllNodes(block.children);
2723
- }
2724
- visitIfBlock(block) {
2725
- this.visitAllNodes(block.branches);
2726
- }
2727
- visitIfBlockBranch(block) {
2728
- block.expression && this.visitAst(block.expression);
2729
- block.expressionAlias?.visit(this);
2730
- this.visitAllNodes(block.children);
2731
- }
2732
- visitLetDeclaration(decl) {
2733
- this.visitAst(decl.value);
2734
- }
2735
- visitComponent(component) {
2736
- this.visitAllNodes(component.attributes);
2737
- this.visitAllNodes(component.inputs);
2738
- this.visitAllNodes(component.outputs);
2739
- this.visitAllNodes(component.directives);
2740
- this.visitAllNodes(component.references);
2741
- this.visitAllNodes(component.children);
2742
- }
2743
- visitDirective(directive) {
2744
- this.visitAllNodes(directive.attributes);
2745
- this.visitAllNodes(directive.inputs);
2746
- this.visitAllNodes(directive.outputs);
2747
- this.visitAllNodes(directive.references);
2568
+ this.visitAllTemplateNodes(template.variables);
2569
+ this.visitAllTemplateNodes(template.references);
2570
+ this.visitAllTemplateNodes(template.children);
2748
2571
  }
2749
2572
  getDiagnostics(template) {
2750
2573
  this.diagnostics = [];
2751
- this.visitAllNodes(template);
2574
+ this.visitAllTemplateNodes(template);
2752
2575
  return this.diagnostics;
2753
2576
  }
2754
2577
  };
@@ -2766,7 +2589,7 @@ var InterpolatedSignalCheck = class extends TemplateCheckWithVisitor {
2766
2589
  if (usedDirectives !== null && usedDirectives.some((dir) => dir.inputs.getByBindingPropertyName(node.name) !== null)) {
2767
2590
  return [];
2768
2591
  }
2769
- if ((node.type === BindingType.Property || node.type === BindingType.Class || node.type === BindingType.Style || node.type === BindingType.Attribute || node.type === BindingType.Animation) && node.value instanceof ASTWithSource3 && node.value.ast instanceof PropertyRead2) {
2592
+ if ((node.type === BindingType.Property || node.type === BindingType.Class || node.type === BindingType.Style || node.type === BindingType.Attribute || node.type === BindingType.Animation) && node.value instanceof ASTWithSource2 && node.value.ast instanceof PropertyRead2) {
2770
2593
  return buildDiagnosticForSignal(ctx, node.value.ast, component);
2771
2594
  }
2772
2595
  }
@@ -3108,7 +2931,7 @@ var factory10 = {
3108
2931
  };
3109
2932
 
3110
2933
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/checks/uninvoked_function_in_event_binding/index.js
3111
- import { ASTWithSource as ASTWithSource4, Call, Chain, Conditional, ParsedEventType, PropertyRead as PropertyRead3, SafeCall as SafeCall2, SafePropertyRead as SafePropertyRead2, TmplAstBoundEvent as TmplAstBoundEvent2 } from "@angular/compiler";
2934
+ import { ASTWithSource as ASTWithSource3, Call, Chain, Conditional, ParsedEventType, PropertyRead as PropertyRead3, SafeCall as SafeCall2, SafePropertyRead as SafePropertyRead2, TmplAstBoundEvent as TmplAstBoundEvent2 } from "@angular/compiler";
3112
2935
  var UninvokedFunctionInEventBindingSpec = class extends TemplateCheckWithVisitor {
3113
2936
  code = ErrorCode.UNINVOKED_FUNCTION_IN_EVENT_BINDING;
3114
2937
  visitNode(ctx, component, node) {
@@ -3116,7 +2939,7 @@ var UninvokedFunctionInEventBindingSpec = class extends TemplateCheckWithVisitor
3116
2939
  return [];
3117
2940
  if (node.type !== ParsedEventType.Regular && node.type !== ParsedEventType.Animation)
3118
2941
  return [];
3119
- if (!(node.handler instanceof ASTWithSource4))
2942
+ if (!(node.handler instanceof ASTWithSource3))
3120
2943
  return [];
3121
2944
  const sourceExpressionText = node.handler.source || "";
3122
2945
  if (node.handler.ast instanceof Chain) {
@@ -3186,7 +3009,7 @@ var factory12 = {
3186
3009
  };
3187
3010
 
3188
3011
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/checks/unused_let_declaration/index.js
3189
- import { AST, ASTWithSource as ASTWithSource5, TmplAstLetDeclaration } from "@angular/compiler";
3012
+ import { AST, ASTWithSource as ASTWithSource4, TmplAstLetDeclaration } from "@angular/compiler";
3190
3013
  var UnusedLetDeclarationCheck = class extends TemplateCheckWithVisitor {
3191
3014
  code = ErrorCode.UNUSED_LET_DECLARATION;
3192
3015
  analysis = /* @__PURE__ */ new Map();
@@ -3206,7 +3029,7 @@ var UnusedLetDeclarationCheck = class extends TemplateCheckWithVisitor {
3206
3029
  if (node instanceof TmplAstLetDeclaration) {
3207
3030
  this.getAnalysis(component).allLetDeclarations.add(node);
3208
3031
  } else if (node instanceof AST) {
3209
- const unwrappedNode = node instanceof ASTWithSource5 ? node.ast : node;
3032
+ const unwrappedNode = node instanceof ASTWithSource4 ? node.ast : node;
3210
3033
  const target = ctx.templateTypeChecker.getExpressionTarget(unwrappedNode, component);
3211
3034
  if (target !== null && target instanceof TmplAstLetDeclaration) {
3212
3035
  this.getAnalysis(component).usedLetDeclarations.add(target);
@@ -3348,7 +3171,7 @@ var SUPPORTED_DIAGNOSTIC_NAMES = /* @__PURE__ */ new Set([
3348
3171
  ]);
3349
3172
 
3350
3173
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/template_semantics/src/template_semantics_checker.js
3351
- import { ASTWithSource as ASTWithSource6, ImplicitReceiver as ImplicitReceiver2, ParsedEventType as ParsedEventType2, RecursiveAstVisitor as RecursiveAstVisitor3, TmplAstBoundEvent as TmplAstBoundEvent3, TmplAstLetDeclaration as TmplAstLetDeclaration2, TmplAstRecursiveVisitor as TmplAstRecursiveVisitor2, TmplAstVariable as TmplAstVariable2 } from "@angular/compiler";
3174
+ import { ASTWithSource as ASTWithSource5, ImplicitReceiver as ImplicitReceiver2, ParsedEventType as ParsedEventType2, PropertyRead as PropertyRead5, RecursiveAstVisitor, TmplAstBoundEvent as TmplAstBoundEvent3, TmplAstLetDeclaration as TmplAstLetDeclaration2, TmplAstRecursiveVisitor, TmplAstVariable as TmplAstVariable2 } from "@angular/compiler";
3352
3175
  import ts22 from "typescript";
3353
3176
  var TemplateSemanticsCheckerImpl = class {
3354
3177
  templateTypeChecker;
@@ -3360,7 +3183,7 @@ var TemplateSemanticsCheckerImpl = class {
3360
3183
  return template !== null ? TemplateSemanticsVisitor.visit(template, component, this.templateTypeChecker) : [];
3361
3184
  }
3362
3185
  };
3363
- var TemplateSemanticsVisitor = class extends TmplAstRecursiveVisitor2 {
3186
+ var TemplateSemanticsVisitor = class extends TmplAstRecursiveVisitor {
3364
3187
  expressionVisitor;
3365
3188
  constructor(expressionVisitor) {
3366
3189
  super();
@@ -3378,7 +3201,7 @@ var TemplateSemanticsVisitor = class extends TmplAstRecursiveVisitor2 {
3378
3201
  event.handler.visit(this.expressionVisitor, event);
3379
3202
  }
3380
3203
  };
3381
- var ExpressionsSemanticsVisitor = class extends RecursiveAstVisitor3 {
3204
+ var ExpressionsSemanticsVisitor = class extends RecursiveAstVisitor {
3382
3205
  templateTypeChecker;
3383
3206
  component;
3384
3207
  diagnostics;
@@ -3388,9 +3211,12 @@ var ExpressionsSemanticsVisitor = class extends RecursiveAstVisitor3 {
3388
3211
  this.component = component;
3389
3212
  this.diagnostics = diagnostics;
3390
3213
  }
3391
- visitPropertyWrite(ast, context) {
3392
- super.visitPropertyWrite(ast, context);
3393
- this.checkForIllegalWriteInEventBinding(ast, context);
3214
+ visitBinary(ast, context) {
3215
+ if (ast.operation === "=" && ast.left instanceof PropertyRead5) {
3216
+ this.checkForIllegalWriteInEventBinding(ast.left, context);
3217
+ } else {
3218
+ super.visitBinary(ast, context);
3219
+ }
3394
3220
  }
3395
3221
  visitPropertyRead(ast, context) {
3396
3222
  super.visitPropertyRead(ast, context);
@@ -3440,7 +3266,7 @@ var ExpressionsSemanticsVisitor = class extends RecursiveAstVisitor3 {
3440
3266
  }
3441
3267
  };
3442
3268
  function unwrapAstWithSource(ast) {
3443
- return ast instanceof ASTWithSource6 ? ast.ast : ast;
3269
+ return ast instanceof ASTWithSource5 ? ast.ast : ast;
3444
3270
  }
3445
3271
 
3446
3272
  // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/validation/src/rules/initializer_api_usage_rule.js
@@ -3553,7 +3379,7 @@ var UnusedStandaloneImportsRule = class {
3553
3379
  continue;
3554
3380
  }
3555
3381
  const pipeMeta = this.templateTypeChecker.getPipeMetadata(currentNode);
3556
- if (pipeMeta !== null && pipeMeta.isStandalone && !usedPipes.has(pipeMeta.name) && !this.isPotentialSharedReference(current, rawImports)) {
3382
+ if (pipeMeta !== null && pipeMeta.isStandalone && pipeMeta.name !== null && !usedPipes.has(pipeMeta.name) && !this.isPotentialSharedReference(current, rawImports)) {
3557
3383
  unused ??= [];
3558
3384
  unused.push(current);
3559
3385
  }
@@ -3720,6 +3546,7 @@ var NgCompiler = class {
3720
3546
  enableHmr;
3721
3547
  implicitStandaloneValue;
3722
3548
  enableSelectorless;
3549
+ emitDeclarationOnly;
3723
3550
  delegatingPerfRecorder;
3724
3551
  static fromTicket(ticket, adapter) {
3725
3552
  switch (ticket.kind) {
@@ -3749,6 +3576,7 @@ var NgCompiler = class {
3749
3576
  this.enableBlockSyntax = options["_enableBlockSyntax"] ?? true;
3750
3577
  this.enableLetSyntax = options["_enableLetSyntax"] ?? true;
3751
3578
  this.enableSelectorless = options["_enableSelectorless"] ?? false;
3579
+ this.emitDeclarationOnly = !!options.emitDeclarationOnly && !!options._experimentalAllowEmitDeclarationOnly;
3752
3580
  this.implicitStandaloneValue = this.angularCoreVersion === null || coreVersionSupportsFeature(this.angularCoreVersion, ">= 19.0.0");
3753
3581
  this.enableHmr = !!options["_enableHmr"];
3754
3582
  this.constructionDiagnostics.push(...this.adapter.constructionDiagnostics, ...verifyCompatibleTypeCheckOptions(this.options));
@@ -3943,7 +3771,7 @@ var NgCompiler = class {
3943
3771
  }
3944
3772
  const defaultImportTracker = new DefaultImportTracker();
3945
3773
  const before = [
3946
- ivyTransformFactory(compilation.traitCompiler, compilation.reflector, importRewriter, defaultImportTracker, compilation.localCompilationExtraImportsTracker, this.delegatingPerfRecorder, compilation.isCore, this.closureCompilerEnabled),
3774
+ ivyTransformFactory(compilation.traitCompiler, compilation.reflector, importRewriter, defaultImportTracker, compilation.localCompilationExtraImportsTracker, this.delegatingPerfRecorder, compilation.isCore, this.closureCompilerEnabled, this.emitDeclarationOnly),
3947
3775
  aliasTransformFactory(compilation.traitCompiler.exportStatements),
3948
3776
  defaultImportTracker.importPreservingTransformer()
3949
3777
  ];
@@ -3966,8 +3794,12 @@ var NgCompiler = class {
3966
3794
  };
3967
3795
  });
3968
3796
  }
3797
+ before.push(signalMetadataTransform(this.inputProgram));
3969
3798
  const afterDeclarations = [];
3970
- if (this.options.compilationMode !== "experimental-local" && compilation.dtsTransforms !== null) {
3799
+ if ((this.options.compilationMode !== "experimental-local" || this.emitDeclarationOnly) && compilation.dtsTransforms !== null) {
3800
+ if (this.emitDeclarationOnly) {
3801
+ afterDeclarations.push(...before);
3802
+ }
3971
3803
  afterDeclarations.push(declarationTransformFactory(compilation.dtsTransforms, compilation.reflector, compilation.refEmitter, importRewriter));
3972
3804
  }
3973
3805
  if (compilation.aliasingHost !== null && compilation.aliasingHost.aliasExportsInDts) {
@@ -4231,6 +4063,9 @@ var NgCompiler = class {
4231
4063
  break;
4232
4064
  }
4233
4065
  }
4066
+ if (this.emitDeclarationOnly) {
4067
+ compilationMode = CompilationMode.LOCAL;
4068
+ }
4234
4069
  const checker = this.inputProgram.getTypeChecker();
4235
4070
  const reflector = new TypeScriptReflectionHost(checker, compilationMode === CompilationMode.LOCAL);
4236
4071
  let refEmitter;
@@ -4269,8 +4104,10 @@ var NgCompiler = class {
4269
4104
  const ngModuleIndex = new NgModuleIndexImpl(metaReader, localMetaReader);
4270
4105
  const ngModuleScopeRegistry = new LocalModuleScopeRegistry(localMetaReader, metaReader, depScopeReader, refEmitter, aliasingHost);
4271
4106
  const standaloneScopeReader = new StandaloneComponentScopeReader(metaReader, ngModuleScopeRegistry, depScopeReader);
4107
+ const selectorlessScopeReader = new SelectorlessComponentScopeReader(metaReader, reflector);
4272
4108
  const scopeReader = new CompoundComponentScopeReader([
4273
4109
  ngModuleScopeRegistry,
4110
+ selectorlessScopeReader,
4274
4111
  standaloneScopeReader
4275
4112
  ]);
4276
4113
  const semanticDepGraphUpdater = this.incrementalCompilation.semanticDepGraphUpdater;
@@ -4312,13 +4149,13 @@ var NgCompiler = class {
4312
4149
  }
4313
4150
  const jitDeclarationRegistry = new JitDeclarationRegistry();
4314
4151
  const handlers = [
4315
- new ComponentDecoratorHandler(reflector, evaluator, metaRegistry, metaReader, scopeReader, this.adapter, ngModuleScopeRegistry, typeCheckScopeRegistry, resourceRegistry, isCore, strictCtorDeps, this.resourceManager, this.adapter.rootDirs, this.options.preserveWhitespaces || false, this.options.i18nUseExternalIds !== false, this.options.enableI18nLegacyMessageIdFormat !== false, this.usePoisonedData, this.options.i18nNormalizeLineEndingsInICUs === true, this.moduleResolver, this.cycleAnalyzer, cycleHandlingStrategy, refEmitter, referencesRegistry, this.incrementalCompilation.depGraph, injectableRegistry, semanticDepGraphUpdater, this.closureCompilerEnabled, this.delegatingPerfRecorder, hostDirectivesResolver, importTracker, supportTestBed, compilationMode, deferredSymbolsTracker, !!this.options.forbidOrphanComponents, this.enableBlockSyntax, this.enableLetSyntax, externalRuntimeStyles, localCompilationExtraImportsTracker, jitDeclarationRegistry, this.options.i18nPreserveWhitespaceForLegacyExtraction ?? true, !!this.options.strictStandalone, this.enableHmr, this.implicitStandaloneValue, typeCheckHostBindings, this.enableSelectorless),
4316
- new DirectiveDecoratorHandler(reflector, evaluator, metaRegistry, ngModuleScopeRegistry, metaReader, injectableRegistry, refEmitter, referencesRegistry, isCore, strictCtorDeps, semanticDepGraphUpdater, this.closureCompilerEnabled, this.delegatingPerfRecorder, importTracker, supportTestBed, typeCheckScopeRegistry, compilationMode, jitDeclarationRegistry, resourceRegistry, !!this.options.strictStandalone, this.implicitStandaloneValue, this.usePoisonedData, typeCheckHostBindings),
4152
+ new ComponentDecoratorHandler(reflector, evaluator, metaRegistry, metaReader, scopeReader, this.adapter, ngModuleScopeRegistry, typeCheckScopeRegistry, resourceRegistry, isCore, strictCtorDeps, this.resourceManager, this.adapter.rootDirs, this.options.preserveWhitespaces || false, this.options.i18nUseExternalIds !== false, this.options.enableI18nLegacyMessageIdFormat !== false, this.usePoisonedData, this.options.i18nNormalizeLineEndingsInICUs === true, this.moduleResolver, this.cycleAnalyzer, cycleHandlingStrategy, refEmitter, referencesRegistry, this.incrementalCompilation.depGraph, injectableRegistry, semanticDepGraphUpdater, this.closureCompilerEnabled, this.delegatingPerfRecorder, hostDirectivesResolver, importTracker, supportTestBed, compilationMode, deferredSymbolsTracker, !!this.options.forbidOrphanComponents, this.enableBlockSyntax, this.enableLetSyntax, externalRuntimeStyles, localCompilationExtraImportsTracker, jitDeclarationRegistry, this.options.i18nPreserveWhitespaceForLegacyExtraction ?? true, !!this.options.strictStandalone, this.enableHmr, this.implicitStandaloneValue, typeCheckHostBindings, this.enableSelectorless, this.emitDeclarationOnly),
4153
+ new DirectiveDecoratorHandler(reflector, evaluator, metaRegistry, ngModuleScopeRegistry, metaReader, injectableRegistry, refEmitter, referencesRegistry, isCore, strictCtorDeps, semanticDepGraphUpdater, this.closureCompilerEnabled, this.delegatingPerfRecorder, importTracker, supportTestBed, typeCheckScopeRegistry, compilationMode, jitDeclarationRegistry, resourceRegistry, !!this.options.strictStandalone, this.implicitStandaloneValue, this.usePoisonedData, typeCheckHostBindings, this.emitDeclarationOnly),
4317
4154
  new PipeDecoratorHandler(reflector, evaluator, metaRegistry, ngModuleScopeRegistry, injectableRegistry, isCore, this.delegatingPerfRecorder, supportTestBed, compilationMode, !!this.options.generateExtraImportsInLocalMode, !!this.options.strictStandalone, this.implicitStandaloneValue),
4318
4155
  new InjectableDecoratorHandler(reflector, evaluator, isCore, strictCtorDeps, injectableRegistry, this.delegatingPerfRecorder, supportTestBed, compilationMode),
4319
- new NgModuleDecoratorHandler(reflector, evaluator, metaReader, metaRegistry, ngModuleScopeRegistry, referencesRegistry, exportedProviderStatusResolver, semanticDepGraphUpdater, isCore, refEmitter, this.closureCompilerEnabled, this.options.onlyPublishPublicTypingsForNgModules ?? false, injectableRegistry, this.delegatingPerfRecorder, supportTestBed, supportJitMode, compilationMode, localCompilationExtraImportsTracker, jitDeclarationRegistry)
4156
+ new NgModuleDecoratorHandler(reflector, evaluator, metaReader, metaRegistry, ngModuleScopeRegistry, referencesRegistry, exportedProviderStatusResolver, semanticDepGraphUpdater, isCore, refEmitter, this.closureCompilerEnabled, this.options.onlyPublishPublicTypingsForNgModules ?? false, injectableRegistry, this.delegatingPerfRecorder, supportTestBed, supportJitMode, compilationMode, localCompilationExtraImportsTracker, jitDeclarationRegistry, this.emitDeclarationOnly)
4320
4157
  ];
4321
- const traitCompiler = new TraitCompiler(handlers, reflector, this.delegatingPerfRecorder, this.incrementalCompilation, this.options.compileNonExportedClasses !== false, compilationMode, dtsTransforms, semanticDepGraphUpdater, this.adapter);
4158
+ const traitCompiler = new TraitCompiler(handlers, reflector, this.delegatingPerfRecorder, this.incrementalCompilation, this.options.compileNonExportedClasses !== false, compilationMode, dtsTransforms, semanticDepGraphUpdater, this.adapter, this.emitDeclarationOnly);
4322
4159
  const notifyingDriver = new NotifyingProgramDriverWrapper(this.programDriver, (program) => {
4323
4160
  this.incrementalStrategy.setIncrementalState(this.incrementalCompilation.state, program);
4324
4161
  this.currentProgram = program;
@@ -4686,7 +4523,7 @@ var NgCompilerHost = class extends DelegatingCompilerHost {
4686
4523
  }
4687
4524
  };
4688
4525
 
4689
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/program.mjs
4526
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/ngtsc/program.js
4690
4527
  var NgtscProgram = class {
4691
4528
  options;
4692
4529
  compiler;
@@ -4914,15 +4751,15 @@ function mergeEmitResults(emitResults) {
4914
4751
  return { diagnostics, emitSkipped, emittedFiles };
4915
4752
  }
4916
4753
 
4917
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/program.mjs
4754
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/program.js
4918
4755
  function createProgram({ rootNames, options, host, oldProgram }) {
4919
4756
  return new NgtscProgram(rootNames, options, host, oldProgram);
4920
4757
  }
4921
4758
 
4922
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/perform_compile.mjs
4759
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/perform_compile.js
4923
4760
  import ts29 from "typescript";
4924
4761
 
4925
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/util.mjs
4762
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/transformers/util.js
4926
4763
  import ts28 from "typescript";
4927
4764
  function createMessageDiagnostic(messageText) {
4928
4765
  return {
@@ -4936,7 +4773,7 @@ function createMessageDiagnostic(messageText) {
4936
4773
  };
4937
4774
  }
4938
4775
 
4939
- // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/perform_compile.mjs
4776
+ // bazel-out/darwin_arm64-fastbuild/bin/packages/compiler-cli/src/perform_compile.js
4940
4777
  var defaultFormatHost = {
4941
4778
  getCurrentDirectory: () => ts29.sys.getCurrentDirectory(),
4942
4779
  getCanonicalFileName: (fileName) => fileName,
@@ -5166,4 +5003,4 @@ export {
5166
5003
  * Use of this source code is governed by an MIT-style license that can be
5167
5004
  * found in the LICENSE file at https://angular.dev/license
5168
5005
  */
5169
- //# sourceMappingURL=chunk-KGJOQ7ZK.js.map
5006
+ //# sourceMappingURL=chunk-PG2VUSMN.js.map