@angular/compiler-cli 19.2.0-next.3 → 19.2.0-rc.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.
@@ -4,7 +4,7 @@
4
4
 
5
5
  import {
6
6
  angularJitApplicationTransform
7
- } from "./chunk-GTLLXINP.js";
7
+ } from "./chunk-E7POVVFX.js";
8
8
  import {
9
9
  CompilationMode,
10
10
  ComponentDecoratorHandler,
@@ -51,7 +51,7 @@ import {
51
51
  retagAllTsFiles,
52
52
  tryParseInitializerApi,
53
53
  untagAllTsFiles
54
- } from "./chunk-WX2MZD5K.js";
54
+ } from "./chunk-HHTMNOE7.js";
55
55
  import {
56
56
  AbsoluteModuleStrategy,
57
57
  AliasStrategy,
@@ -87,7 +87,7 @@ import {
87
87
  relativePathBetween,
88
88
  replaceTsWithNgInErrors,
89
89
  toUnredirectedSourceFile
90
- } from "./chunk-J3VFQRNB.js";
90
+ } from "./chunk-OZ2WSYWM.js";
91
91
  import {
92
92
  ActivePerfRecorder,
93
93
  DelegatingPerfRecorder,
@@ -3095,6 +3095,32 @@ var factory10 = {
3095
3095
  create: () => new UnusedLetDeclarationCheck()
3096
3096
  };
3097
3097
 
3098
+ // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/checks/skip_hydration_not_static/index.mjs
3099
+ import { TmplAstBoundAttribute as TmplAstBoundAttribute3, TmplAstTextAttribute as TmplAstTextAttribute2 } from "@angular/compiler";
3100
+ var NG_SKIP_HYDRATION_ATTR_NAME = "ngSkipHydration";
3101
+ var NgSkipHydrationSpec = class extends TemplateCheckWithVisitor {
3102
+ code = ErrorCode.SKIP_HYDRATION_NOT_STATIC;
3103
+ visitNode(ctx, component, node) {
3104
+ if (node instanceof TmplAstBoundAttribute3 && node.name === NG_SKIP_HYDRATION_ATTR_NAME) {
3105
+ const errorString = `ngSkipHydration should not be used as a binding.`;
3106
+ const diagnostic = ctx.makeTemplateDiagnostic(node.sourceSpan, errorString);
3107
+ return [diagnostic];
3108
+ }
3109
+ const acceptedValues = ["true", ""];
3110
+ if (node instanceof TmplAstTextAttribute2 && node.name === NG_SKIP_HYDRATION_ATTR_NAME && !acceptedValues.includes(node.value) && node.value !== void 0) {
3111
+ const errorString = `ngSkipHydration only accepts "true" or "" as value or no value at all. For example 'ngSkipHydration="true"' or 'ngSkipHydration'`;
3112
+ const diagnostic = ctx.makeTemplateDiagnostic(node.sourceSpan, errorString);
3113
+ return [diagnostic];
3114
+ }
3115
+ return [];
3116
+ }
3117
+ };
3118
+ var factory11 = {
3119
+ code: ErrorCode.SKIP_HYDRATION_NOT_STATIC,
3120
+ name: ExtendedTemplateDiagnosticName.SKIP_HYDRATION_NOT_STATIC,
3121
+ create: () => new NgSkipHydrationSpec()
3122
+ };
3123
+
3098
3124
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/extended/src/extended_template_checker.mjs
3099
3125
  import ts20 from "typescript";
3100
3126
 
@@ -3114,12 +3140,12 @@ var ExtendedTemplateCheckerImpl = class {
3114
3140
  var _a, _b, _c, _d, _e;
3115
3141
  this.partialCtx = { templateTypeChecker, typeChecker };
3116
3142
  this.templateChecks = /* @__PURE__ */ new Map();
3117
- for (const factory11 of templateCheckFactories) {
3118
- const category = diagnosticLabelToCategory((_e = (_d = (_b = (_a = options == null ? void 0 : options.extendedDiagnostics) == null ? void 0 : _a.checks) == null ? void 0 : _b[factory11.name]) != null ? _d : (_c = options == null ? void 0 : options.extendedDiagnostics) == null ? void 0 : _c.defaultCategory) != null ? _e : DiagnosticCategoryLabel.Warning);
3143
+ for (const factory12 of templateCheckFactories) {
3144
+ const category = diagnosticLabelToCategory((_e = (_d = (_b = (_a = options == null ? void 0 : options.extendedDiagnostics) == null ? void 0 : _a.checks) == null ? void 0 : _b[factory12.name]) != null ? _d : (_c = options == null ? void 0 : options.extendedDiagnostics) == null ? void 0 : _c.defaultCategory) != null ? _e : DiagnosticCategoryLabel.Warning);
3119
3145
  if (category === null) {
3120
3146
  continue;
3121
3147
  }
3122
- const check = factory11.create(options);
3148
+ const check = factory12.create(options);
3123
3149
  if (check === null) {
3124
3150
  continue;
3125
3151
  }
@@ -3172,12 +3198,13 @@ var ALL_DIAGNOSTIC_FACTORIES = [
3172
3198
  factory7,
3173
3199
  factory,
3174
3200
  factory9,
3175
- factory10
3201
+ factory10,
3202
+ factory11
3176
3203
  ];
3177
3204
  var SUPPORTED_DIAGNOSTIC_NAMES = /* @__PURE__ */ new Set([
3178
3205
  ExtendedTemplateDiagnosticName.CONTROL_FLOW_PREVENTING_CONTENT_PROJECTION,
3179
3206
  ExtendedTemplateDiagnosticName.UNUSED_STANDALONE_IMPORTS,
3180
- ...ALL_DIAGNOSTIC_FACTORIES.map((factory11) => factory11.name)
3207
+ ...ALL_DIAGNOSTIC_FACTORIES.map((factory12) => factory12.name)
3181
3208
  ]);
3182
3209
 
3183
3210
  // bazel-out/k8-fastbuild/bin/packages/compiler-cli/src/ngtsc/typecheck/template_semantics/src/template_semantics_checker.mjs
@@ -5034,4 +5061,4 @@ export {
5034
5061
  * Use of this source code is governed by an MIT-style license that can be
5035
5062
  * found in the LICENSE file at https://angular.dev/license
5036
5063
  */
5037
- //# sourceMappingURL=chunk-AE5PSHNW.js.map
5064
+ //# sourceMappingURL=chunk-67OPP2P5.js.map