@ng-doc/builder 22.0.0 → 22.2.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 (98) hide show
  1. package/LICENSE +21 -0
  2. package/engine/builders/helpers/get-playground-metadata.js +7 -1
  3. package/engine/builders/helpers/get-playground-metadata.js.map +1 -1
  4. package/engine/builders/page/demo-assets.builder.js +2 -0
  5. package/engine/builders/page/demo-assets.builder.js.map +1 -1
  6. package/engine/builders/shared/content.builder.js +2 -0
  7. package/engine/builders/shared/content.builder.js.map +1 -1
  8. package/engine/builders/shared/page-wrapper.builder.js +2 -0
  9. package/engine/builders/shared/page-wrapper.builder.js.map +1 -1
  10. package/generator/bootstrap/bin.js +174 -107
  11. package/generator/bootstrap/cli.js +174 -107
  12. package/generator/bootstrap/index.js +139 -99
  13. package/generator/bootstrap/process-tree.d.ts +5 -4
  14. package/generator/build-metafile.json +647 -240
  15. package/generator/build-provenance.json +6 -4
  16. package/generator/compiler/index.d.ts +20 -0
  17. package/generator/compiler/index.js +2400 -945
  18. package/generator/compiler/plan.d.ts +24 -0
  19. package/generator/content/code-snippet.d.ts +20 -0
  20. package/generator/content/content-compiler.d.ts +5 -1
  21. package/generator/content/format-cache.d.ts +108 -0
  22. package/generator/content/highlight-cache.d.ts +12 -36
  23. package/generator/content/html-pipeline.d.ts +10 -1
  24. package/generator/content/html-pool.d.ts +8 -2
  25. package/generator/content/html-worker.js +630 -39
  26. package/generator/contracts.d.ts +57 -0
  27. package/generator/discovery/index.d.ts +2 -0
  28. package/generator/kernel/flags.d.ts +5 -0
  29. package/generator/outputs/index.d.ts +29 -0
  30. package/generator/semantic/angular.d.ts +21 -1
  31. package/generator/semantic/formatting.d.ts +27 -0
  32. package/generator/semantic/fragments.d.ts +11 -2
  33. package/generator/templates/api/class-declaration.html.nunj +5 -3
  34. package/generator/templates/demo-app.ts.nunj +37 -0
  35. package/generator/templates/demo-routes.ts.nunj +43 -0
  36. package/generator/templates/index.ts.nunj +5 -0
  37. package/generator/templates/page-wrapper.ts.nunj +6 -1
  38. package/generator/templates/page.ts.nunj +13 -2
  39. package/generator/templates/routes.ts.nunj +7 -3
  40. package/generator/templates/symbol/members.html.nunj +6 -4
  41. package/generator/templates/symbol/page.html.nunj +1 -1
  42. package/generator/vite/angular/analog-provenance.json +1 -1
  43. package/generator/vite/angular-composition.d.ts +25 -1
  44. package/generator/vite/application-builder.js +6 -1
  45. package/generator/vite/application.d.ts +14 -0
  46. package/generator/vite/content-updates.d.ts +62 -0
  47. package/generator/vite/demo-application.d.ts +34 -0
  48. package/generator/vite/dev-server-builder.js +6 -1
  49. package/generator/vite/host-updates.d.ts +153 -6
  50. package/generator/vite/index.js +985 -247
  51. package/generator/vite/lifecycle.d.ts +40 -2
  52. package/generator/vite/prerender-entry.js +72 -2
  53. package/generator/vite/prerender-runtime.d.ts +13 -0
  54. package/generator/vite/prerender.d.ts +2 -0
  55. package/helpers/format-cache.d.ts +34 -0
  56. package/helpers/format-cache.js +26 -0
  57. package/helpers/format-cache.js.map +1 -0
  58. package/helpers/format-code.js +9 -2
  59. package/helpers/format-code.js.map +1 -1
  60. package/helpers/playground/get-playground-inputs.js +6 -3
  61. package/helpers/playground/get-playground-inputs.js.map +1 -1
  62. package/helpers/playground/playground-options.d.ts +28 -0
  63. package/helpers/playground/playground-options.js +122 -0
  64. package/helpers/playground/playground-options.js.map +1 -0
  65. package/helpers/playground/written-union-order.d.ts +33 -0
  66. package/helpers/playground/written-union-order.js +106 -0
  67. package/helpers/playground/written-union-order.js.map +1 -0
  68. package/helpers/to-template-string.d.ts +5 -1
  69. package/helpers/to-template-string.js +7 -2
  70. package/helpers/to-template-string.js.map +1 -1
  71. package/interfaces/code-block-options.d.ts +5 -0
  72. package/interfaces/configuration.d.ts +92 -1
  73. package/package.json +6 -5
  74. package/parsers/parse-code-block-params.d.ts +10 -1
  75. package/parsers/parse-code-block-params.js +29 -3
  76. package/parsers/parse-code-block-params.js.map +1 -1
  77. package/schematics/collection.json +1 -1
  78. package/schematics/migrate-to-vite/analyze.js +46 -3
  79. package/schematics/migrate-to-vite/analyze.js.map +1 -1
  80. package/schematics/migrate-to-vite/setup/workspace.d.ts +5 -0
  81. package/schematics/migrate-to-vite/setup/workspace.js +20 -0
  82. package/schematics/migrate-to-vite/setup/workspace.js.map +1 -1
  83. package/schematics/migrate-to-vite/testing/fixtures.d.ts +12 -0
  84. package/schematics/migrate-to-vite/testing/fixtures.js +27 -0
  85. package/schematics/migrate-to-vite/testing/fixtures.js.map +1 -1
  86. package/schematics/vite-setup/index.d.ts +9 -5
  87. package/schematics/vite-setup/index.js +11 -5
  88. package/schematics/vite-setup/index.js.map +1 -1
  89. package/schematics/vite-setup/schema.json +1 -1
  90. package/templates/api/class-declaration.html.nunj +5 -3
  91. package/templates/demo-app.ts.nunj +37 -0
  92. package/templates/demo-routes.ts.nunj +43 -0
  93. package/templates/index.ts.nunj +5 -0
  94. package/templates/page-wrapper.ts.nunj +6 -1
  95. package/templates/page.ts.nunj +13 -2
  96. package/templates/routes.ts.nunj +7 -3
  97. package/templates/symbol/members.html.nunj +6 -4
  98. package/templates/symbol/page.html.nunj +1 -1
@@ -256,6 +256,21 @@ var ENGINE_SWITCHES = Object.freeze([
256
256
  values: /^(0|false|off|no)$/i,
257
257
  effect: "adding or removing a page compiles the application twice"
258
258
  },
259
+ {
260
+ name: "NGDOC_ANGULAR_DESCRIPTION_PASS",
261
+ values: /^(0|false|off|no)$/i,
262
+ effect: "a page title edit compiles the application twice"
263
+ },
264
+ {
265
+ name: "NGDOC_VITE_CONTENT_UPDATE",
266
+ values: /^(0|false|off|no)$/i,
267
+ effect: "guide text edits reload the page"
268
+ },
269
+ {
270
+ name: "NGDOC_VITE_MODULELESS_SETTLE",
271
+ values: /^(0|false|off|no)$/i,
272
+ effect: "hot updates of files the browser never loaded wait for the newest generation"
273
+ },
259
274
  {
260
275
  name: "NGDOC_VITE_BUILD_HANDOFF",
261
276
  values: /^(0|false|off|no)$/i,
@@ -266,6 +281,16 @@ var ENGINE_SWITCHES = Object.freeze([
266
281
  values: /^(0|false|off|no|verify)$/i,
267
282
  effect: "every code block is highlighted again"
268
283
  },
284
+ {
285
+ name: "NGDOC_FORMAT_CACHE",
286
+ values: /^(0|false|off|no|verify)$/i,
287
+ effect: "every signature and snippet is formatted again"
288
+ },
289
+ {
290
+ name: "NGDOC_USED_GRAMMARS",
291
+ values: /^(0|false|off|no)$/i,
292
+ effect: "every Shiki grammar is loaded before code is highlighted"
293
+ },
269
294
  {
270
295
  name: "NGDOC_PARALLEL_RENDER",
271
296
  values: /^(0|false|off|no|verify)$/i,
@@ -1602,7 +1627,7 @@ function createParcelEventSource(root, options = {}, subscribe2 = parcel.subscri
1602
1627
 
1603
1628
  // libs/builder/generator/bootstrap/constants.ts
1604
1629
  var GENERATOR_COMPILER_VERSION = "0.0.1";
1605
- var GENERATOR_TOOLCHAIN_DIGEST = "a837a4b43736f6b95b5565f442aa62d2f2175fb549d7a44138d2955d465c9ac3";
1630
+ var GENERATOR_TOOLCHAIN_DIGEST = "495b74972f5c2d99ad311bd24b03e2560f77343e401abd7c4d8185e4fee96764";
1606
1631
 
1607
1632
  // libs/builder/generator/bootstrap/index.ts
1608
1633
  import path7 from "node:path";
@@ -1620,12 +1645,17 @@ var INCREMENTAL_PROGRAM_FLAG = "NGDOC_INCREMENTAL_PROGRAM";
1620
1645
  var SHAPE_CLOSURE_FLAG = "NGDOC_SHAPE_CLOSURE";
1621
1646
  var ANGULAR_SHARED_PASS_FLAG = "NGDOC_ANGULAR_SHARED_PASS";
1622
1647
  var ANGULAR_STRUCTURAL_PASS_FLAG = "NGDOC_ANGULAR_STRUCTURAL_PASS";
1648
+ var ANGULAR_DESCRIPTION_PASS_FLAG = "NGDOC_ANGULAR_DESCRIPTION_PASS";
1649
+ var VITE_CONTENT_UPDATE_FLAG = "NGDOC_VITE_CONTENT_UPDATE";
1623
1650
  var VITE_BUILD_HANDOFF_FLAG = "NGDOC_VITE_BUILD_HANDOFF";
1651
+ var VITE_MODULELESS_SETTLE_FLAG = "NGDOC_VITE_MODULELESS_SETTLE";
1624
1652
  var TRACKED_PROGRAM_REUSE_FLAG = "NGDOC_TRACKED_PROGRAM_REUSE";
1625
1653
  var FAST_START_FLAG = "NGDOC_FAST_START";
1626
1654
  var PARALLEL_WRITES_FLAG = "NGDOC_PARALLEL_WRITES";
1627
1655
  var HIGHLIGHT_CACHE_FLAG = "NGDOC_HIGHLIGHT_CACHE";
1656
+ var FORMAT_CACHE_FLAG = "NGDOC_FORMAT_CACHE";
1628
1657
  var PARALLEL_RENDER_FLAG = "NGDOC_PARALLEL_RENDER";
1658
+ var USED_GRAMMARS_FLAG = "NGDOC_USED_GRAMMARS";
1629
1659
  var FLAGS = Object.freeze(
1630
1660
  [
1631
1661
  {
@@ -1693,6 +1723,21 @@ var FLAGS = Object.freeze(
1693
1723
  description: "In the Vite host, the generated modules and description modules a generation creates or deletes join that generation's Angular compiler pass instead of starting a pass of their own.",
1694
1724
  verify: false
1695
1725
  },
1726
+ {
1727
+ name: ANGULAR_DESCRIPTION_PASS_FLAG,
1728
+ description: "In the Vite host, an edited description module joins the Angular compiler pass of the generation it starts, when that generation rewrites generated TypeScript modules, instead of taking a pass of its own first.",
1729
+ verify: false
1730
+ },
1731
+ {
1732
+ name: VITE_CONTENT_UPDATE_FLAG,
1733
+ description: "In the Vite host, a generation that changes only content modules and the search index updates the open pages in place instead of reloading them.",
1734
+ verify: false
1735
+ },
1736
+ {
1737
+ name: VITE_MODULELESS_SETTLE_FLAG,
1738
+ description: "In the Vite host, a hot update that hands Vite no module to update settles once it is acknowledged, instead of waiting for the newest generation to be published.",
1739
+ verify: false
1740
+ },
1696
1741
  {
1697
1742
  name: VITE_BUILD_HANDOFF_FLAG,
1698
1743
  description: "The server build of the Vite production pipeline publishes the browser build's generation instead of generating again.",
@@ -1703,6 +1748,16 @@ var FLAGS = Object.freeze(
1703
1748
  description: "Code blocks are highlighted with one Shiki highlighter per runtime and cached by their text, language, meta, themes and Shiki version; development keeps the cache beside the artifact cache.",
1704
1749
  verify: true
1705
1750
  },
1751
+ {
1752
+ name: FORMAT_CACHE_FLAG,
1753
+ description: "The Prettier configuration is resolved once per generation, and formatted signatures and snippets are cached by their code, parser, configuration and Prettier version; development keeps the cache beside the artifact cache.",
1754
+ verify: true
1755
+ },
1756
+ {
1757
+ name: USED_GRAMMARS_FLAG,
1758
+ description: "Code blocks are highlighted by a highlighter that loads only the Shiki grammars their languages reach, instead of every bundled grammar; the HTML is the same.",
1759
+ verify: false
1760
+ },
1706
1761
  {
1707
1762
  name: PARALLEL_RENDER_FLAG,
1708
1763
  description: "A large generation runs the HTML processing of its pages (highlighting, anchors, keyword links, search records) on up to four worker threads, while the main thread prepares the next pages in order.",
@@ -2668,29 +2723,29 @@ function projectWatchInputs(dependencies) {
2668
2723
  const scopes = /* @__PURE__ */ new Map();
2669
2724
  const references = [];
2670
2725
  for (const dependency of dependencies) {
2671
- if (!isRecord(dependency) || typeof dependency.kind !== "string")
2726
+ if (!isRecord(dependency) || typeof dependency["kind"] !== "string")
2672
2727
  throw new Error("Invalid dependency");
2673
- switch (dependency.kind) {
2728
+ switch (dependency["kind"]) {
2674
2729
  case "content": {
2675
2730
  if (!hasExactKeys(dependency, ["digest", "kind", "path"]))
2676
2731
  throw new Error("Invalid content dependency");
2677
- files.add(path4(dependency.path, "content path"));
2678
- string(dependency.digest, "content digest");
2732
+ files.add(path4(dependency["path"], "content path"));
2733
+ string(dependency["digest"], "content digest");
2679
2734
  break;
2680
2735
  }
2681
2736
  case "existence": {
2682
- if (!hasExactKeys(dependency, ["exists", "kind", "path"]) || typeof dependency.exists !== "boolean")
2737
+ if (!hasExactKeys(dependency, ["exists", "kind", "path"]) || typeof dependency["exists"] !== "boolean")
2683
2738
  throw new Error("Invalid existence dependency");
2684
- files.add(path4(dependency.path, "existence path"));
2739
+ files.add(path4(dependency["path"], "existence path"));
2685
2740
  break;
2686
2741
  }
2687
2742
  case "glob": {
2688
2743
  if (!hasExactKeys(dependency, ["exclude", "include", "kind", "members", "root"]))
2689
2744
  throw new Error("Invalid glob dependency");
2690
- const root = path4(dependency.root, "glob root");
2691
- const include = strings(dependency.include, "glob include");
2692
- const exclude = strings(dependency.exclude, "glob exclude");
2693
- paths(dependency.members, "glob members").forEach((member) => files.add(member));
2745
+ const root = path4(dependency["root"], "glob root");
2746
+ const include = strings(dependency["include"], "glob include");
2747
+ const exclude = strings(dependency["exclude"], "glob exclude");
2748
+ paths(dependency["members"], "glob members").forEach((member) => files.add(member));
2694
2749
  const glob = { root, include, exclude };
2695
2750
  globs.set(JSON.stringify(glob), glob);
2696
2751
  break;
@@ -2698,10 +2753,10 @@ function projectWatchInputs(dependencies) {
2698
2753
  case "semantic": {
2699
2754
  if (!hasExactKeys(dependency, ["digest", "files", "kind", "reason", "scopeId"]))
2700
2755
  throw new Error("Invalid semantic dependency");
2701
- const scopeId = string(dependency.scopeId, "semantic scope ID");
2702
- const digest = string(dependency.digest, "semantic digest");
2703
- string(dependency.reason, "semantic reason");
2704
- const scopeFiles = paths(dependency.files, "semantic files");
2756
+ const scopeId = string(dependency["scopeId"], "semantic scope ID");
2757
+ const digest = string(dependency["digest"], "semantic digest");
2758
+ string(dependency["reason"], "semantic reason");
2759
+ const scopeFiles = paths(dependency["files"], "semantic files");
2705
2760
  scopeFiles.forEach((file) => files.add(file));
2706
2761
  const registered = scopes.get(scopeId) ?? [];
2707
2762
  registered.push({ digest });
@@ -2712,17 +2767,17 @@ function projectWatchInputs(dependencies) {
2712
2767
  if (!hasExactKeys(dependency, ["digest", "kind", "reason", "scopeId"]))
2713
2768
  throw new Error("Invalid semantic-reference dependency");
2714
2769
  references.push({
2715
- scopeId: string(dependency.scopeId, "semantic-reference scope ID"),
2716
- digest: string(dependency.digest, "semantic-reference digest")
2770
+ scopeId: string(dependency["scopeId"], "semantic-reference scope ID"),
2771
+ digest: string(dependency["digest"], "semantic-reference digest")
2717
2772
  });
2718
- string(dependency.reason, "semantic-reference reason");
2773
+ string(dependency["reason"], "semantic-reference reason");
2719
2774
  break;
2720
2775
  }
2721
2776
  case "keyword": {
2722
2777
  if (!hasExactKeys(dependency, ["digest", "key", "kind"]))
2723
2778
  throw new Error("Invalid keyword dependency");
2724
- string(dependency.key, "keyword key");
2725
- string(dependency.digest, "keyword digest");
2779
+ string(dependency["key"], "keyword key");
2780
+ string(dependency["digest"], "keyword digest");
2726
2781
  break;
2727
2782
  }
2728
2783
  // The non-physical kinds are validated but are never watch inputs: they name no path, and
@@ -2730,16 +2785,16 @@ function projectWatchInputs(dependencies) {
2730
2785
  case "semantic-closure": {
2731
2786
  if (!hasExactKeys(dependency, ["digest", "key", "kind", "scopeId"]))
2732
2787
  throw new Error("Invalid semantic-closure dependency");
2733
- string(dependency.scopeId, "semantic-closure scope ID");
2734
- string(dependency.key, "semantic-closure key");
2735
- string(dependency.digest, "semantic-closure digest");
2788
+ string(dependency["scopeId"], "semantic-closure scope ID");
2789
+ string(dependency["key"], "semantic-closure key");
2790
+ string(dependency["digest"], "semantic-closure digest");
2736
2791
  break;
2737
2792
  }
2738
2793
  case "evaluated": {
2739
2794
  if (!hasExactKeys(dependency, ["digest", "entryId", "kind"]))
2740
2795
  throw new Error("Invalid evaluated dependency");
2741
- string(dependency.entryId, "evaluated entry ID");
2742
- string(dependency.digest, "evaluated digest");
2796
+ string(dependency["entryId"], "evaluated entry ID");
2797
+ string(dependency["digest"], "evaluated digest");
2743
2798
  break;
2744
2799
  }
2745
2800
  default:
@@ -5756,7 +5811,7 @@ function normalizeRelative(value) {
5756
5811
  return normalized;
5757
5812
  }
5758
5813
  function trustedBase(last, request) {
5759
- const published = (manifest) => isRecord2(manifest) && manifest.projectId === last.projectId && manifest.revision === last.revision && manifest.generation === last.generation;
5814
+ const published = (manifest) => isRecord2(manifest) && manifest["projectId"] === last.projectId && manifest["revision"] === last.revision && manifest["generation"] === last.generation;
5760
5815
  const base = request.base;
5761
5816
  return isRecord2(base) && published(base.manifest) && published(request.previous) && isRecord2(base.snapshot) && base.snapshot.projectId === last.projectId && base.snapshot.revision === last.revision;
5762
5817
  }
@@ -5770,17 +5825,17 @@ function sameManifestStamp(left, right) {
5770
5825
  return left.dev === right.dev && left.ino === right.ino && left.size === right.size && left.mtimeNs === right.mtimeNs && left.ctimeNs === right.ctimeNs;
5771
5826
  }
5772
5827
  function configurationDigest(candidate) {
5773
- return isRecord2(candidate) && isRecord2(candidate.configuration) ? candidate.configuration.digest : void 0;
5828
+ return isRecord2(candidate) && isRecord2(candidate["configuration"]) ? candidate["configuration"]["digest"] : void 0;
5774
5829
  }
5775
5830
  function unchangedArtifact(artifact, last) {
5776
- const id = artifact.id;
5777
- const outputs = artifact.outputs;
5778
- if (!string2(artifact.revision) || last.revisions.get(id) !== artifact.revision || !Array.isArray(outputs) || outputs.length !== (last.counts.get(id) ?? 0))
5831
+ const id = artifact["id"];
5832
+ const outputs = artifact["outputs"];
5833
+ if (!string2(artifact["revision"]) || last.revisions.get(id) !== artifact["revision"] || !Array.isArray(outputs) || outputs.length !== (last.counts.get(id) ?? 0))
5779
5834
  return false;
5780
5835
  return outputs.every((output) => {
5781
- if (!isRecord2(output) || !string2(output.path)) return false;
5782
- const entry = last.files.get(output.path);
5783
- return entry?.ownerId === id && entry.digest === output.digest && entry.role === output.role;
5836
+ if (!isRecord2(output) || !string2(output["path"])) return false;
5837
+ const entry = last.files.get(output["path"]);
5838
+ return entry?.ownerId === id && entry.digest === output["digest"] && entry.role === output["role"];
5784
5839
  });
5785
5840
  }
5786
5841
  var EMPTY_SCOPE_FACTS = canonicalJson({ definitions: [], references: [] });
@@ -5963,7 +6018,7 @@ function stringArray(value) {
5963
6018
  function isIdentity(value) {
5964
6019
  if (!isRecord2(value) || !exact(value, ["projectId", "entryId", "role"], ["declarationId", "part"]))
5965
6020
  return false;
5966
- return string2(value.projectId) && string2(value.entryId) && [
6021
+ return string2(value["projectId"]) && string2(value["entryId"]) && [
5967
6022
  "page-shell",
5968
6023
  "content",
5969
6024
  "demo-assets",
@@ -5971,7 +6026,7 @@ function isIdentity(value) {
5971
6026
  "category",
5972
6027
  "api-list",
5973
6028
  "aggregate"
5974
- ].includes(String(value.role)) && (value.declarationId === void 0 || string2(value.declarationId)) && (value.part === void 0 || string2(value.part));
6029
+ ].includes(String(value["role"])) && (value["declarationId"] === void 0 || string2(value["declarationId"])) && (value["part"] === void 0 || string2(value["part"]));
5975
6030
  }
5976
6031
  function isFingerprint(value) {
5977
6032
  return isRecord2(value) && exact(value, [
@@ -5981,40 +6036,40 @@ function isFingerprint(value) {
5981
6036
  "configurationDigest",
5982
6037
  "inputDigest",
5983
6038
  "keywordDigest"
5984
- ]) && value.schemaVersion === SCHEMA_VERSION && [
5985
- value.compilerVersion,
5986
- value.toolchainDigest,
5987
- value.configurationDigest,
5988
- value.inputDigest,
5989
- value.keywordDigest
6039
+ ]) && value["schemaVersion"] === SCHEMA_VERSION && [
6040
+ value["compilerVersion"],
6041
+ value["toolchainDigest"],
6042
+ value["configurationDigest"],
6043
+ value["inputDigest"],
6044
+ value["keywordDigest"]
5990
6045
  ].every(string2);
5991
6046
  }
5992
6047
  function isDependency(value) {
5993
- if (!isRecord2(value) || !string2(value.kind)) return false;
5994
- if (value.kind === "content")
5995
- return exact(value, ["kind", "path", "digest"]) && string2(value.path) && string2(value.digest);
5996
- if (value.kind === "existence")
5997
- return exact(value, ["kind", "path", "exists"]) && string2(value.path) && typeof value.exists === "boolean";
5998
- if (value.kind === "glob")
5999
- return exact(value, ["kind", "root", "include", "exclude", "members"]) && string2(value.root) && stringArray(value.include) && stringArray(value.exclude) && stringArray(value.members);
6000
- if (value.kind === "semantic")
6001
- return exact(value, ["kind", "scopeId", "digest", "files", "reason"]) && string2(value.scopeId) && string2(value.digest) && stringArray(value.files) && string2(value.reason);
6002
- if (value.kind === "semantic-reference")
6003
- return exact(value, ["kind", "scopeId", "digest", "reason"]) && string2(value.scopeId) && string2(value.digest) && string2(value.reason);
6004
- if (value.kind === "semantic-closure")
6005
- return exact(value, ["kind", "scopeId", "key", "digest"]) && string2(value.scopeId) && string2(value.key) && string2(value.digest);
6006
- if (value.kind === "evaluated")
6007
- return exact(value, ["kind", "entryId", "digest"]) && string2(value.entryId) && string2(value.digest);
6008
- return value.kind === "keyword" && exact(value, ["kind", "key", "digest"]) && string2(value.key) && string2(value.digest);
6048
+ if (!isRecord2(value) || !string2(value["kind"])) return false;
6049
+ if (value["kind"] === "content")
6050
+ return exact(value, ["kind", "path", "digest"]) && string2(value["path"]) && string2(value["digest"]);
6051
+ if (value["kind"] === "existence")
6052
+ return exact(value, ["kind", "path", "exists"]) && string2(value["path"]) && typeof value["exists"] === "boolean";
6053
+ if (value["kind"] === "glob")
6054
+ return exact(value, ["kind", "root", "include", "exclude", "members"]) && string2(value["root"]) && stringArray(value["include"]) && stringArray(value["exclude"]) && stringArray(value["members"]);
6055
+ if (value["kind"] === "semantic")
6056
+ return exact(value, ["kind", "scopeId", "digest", "files", "reason"]) && string2(value["scopeId"]) && string2(value["digest"]) && stringArray(value["files"]) && string2(value["reason"]);
6057
+ if (value["kind"] === "semantic-reference")
6058
+ return exact(value, ["kind", "scopeId", "digest", "reason"]) && string2(value["scopeId"]) && string2(value["digest"]) && string2(value["reason"]);
6059
+ if (value["kind"] === "semantic-closure")
6060
+ return exact(value, ["kind", "scopeId", "key", "digest"]) && string2(value["scopeId"]) && string2(value["key"]) && string2(value["digest"]);
6061
+ if (value["kind"] === "evaluated")
6062
+ return exact(value, ["kind", "entryId", "digest"]) && string2(value["entryId"]) && string2(value["digest"]);
6063
+ return value["kind"] === "keyword" && exact(value, ["kind", "key", "digest"]) && string2(value["key"]) && string2(value["digest"]);
6009
6064
  }
6010
6065
  function isKeyword(value) {
6011
- return isRecord2(value) && exact(value, ["key", "title", "path"], ["type", "languages", "description"]) && string2(value.key) && string2(value.title) && string2(value.path) && (value.type === void 0 || value.type === "link") && (value.languages === void 0 || stringArray(value.languages)) && [value.description, value.signature].every((item) => item === void 0 || string2(item));
6066
+ return isRecord2(value) && exact(value, ["key", "title", "path"], ["type", "languages", "description"]) && string2(value["key"]) && string2(value["title"]) && string2(value["path"]) && (value["type"] === void 0 || value["type"] === "link") && (value["languages"] === void 0 || stringArray(value["languages"])) && [value["description"], value["signature"]].every((item) => item === void 0 || string2(item));
6012
6067
  }
6013
6068
  function isSource(value) {
6014
- return isRecord2(value) && exact(value, ["path"], ["line", "column"]) && string2(value.path) && (value.line === void 0 || finite(value.line)) && (value.column === void 0 || finite(value.column));
6069
+ return isRecord2(value) && exact(value, ["path"], ["line", "column"]) && string2(value["path"]) && (value["line"] === void 0 || finite(value["line"])) && (value["column"] === void 0 || finite(value["column"]));
6015
6070
  }
6016
6071
  function isDiagnostic(value) {
6017
- return isRecord2(value) && exact(value, ["code", "severity", "message", "stage"], ["source", "ownerId", "related"]) && string2(value.code) && ["error", "warning", "info"].includes(String(value.severity)) && string2(value.message) && [
6072
+ return isRecord2(value) && exact(value, ["code", "severity", "message", "stage"], ["source", "ownerId", "related"]) && string2(value["code"]) && ["error", "warning", "info"].includes(String(value["severity"])) && string2(value["message"]) && [
6018
6073
  "discovery",
6019
6074
  "evaluation",
6020
6075
  "semantic",
@@ -6023,8 +6078,8 @@ function isDiagnostic(value) {
6023
6078
  "cache",
6024
6079
  "commit",
6025
6080
  "host"
6026
- ].includes(String(value.stage)) && (value.source === void 0 || isSource(value.source)) && (value.ownerId === void 0 || string2(value.ownerId)) && (value.related === void 0 || Array.isArray(value.related) && value.related.every(
6027
- (item) => isRecord2(item) && exact(item, ["message", "source"]) && string2(item.message) && isSource(item.source)
6081
+ ].includes(String(value["stage"])) && (value["source"] === void 0 || isSource(value["source"])) && (value["ownerId"] === void 0 || string2(value["ownerId"])) && (value["related"] === void 0 || Array.isArray(value["related"]) && value["related"].every(
6082
+ (item) => isRecord2(item) && exact(item, ["message", "source"]) && string2(item["message"]) && isSource(item["source"])
6028
6083
  ));
6029
6084
  }
6030
6085
  function isSearch(value) {
@@ -6032,17 +6087,17 @@ function isSearch(value) {
6032
6087
  value,
6033
6088
  ["breadcrumbs", "pageType", "title", "section", "route", "content"],
6034
6089
  ["fragment", "kind", "signature", "description"]
6035
- ) && stringArray(value.breadcrumbs) && ["guide", "api"].includes(String(value.pageType)) && [value.title, value.section, value.route, value.content].every(string2) && [value.fragment, value.kind, value.signature, value.description].every(
6090
+ ) && stringArray(value["breadcrumbs"]) && ["guide", "api"].includes(String(value["pageType"])) && [value["title"], value["section"], value["route"], value["content"]].every(string2) && [value["fragment"], value["kind"], value["signature"], value["description"]].every(
6036
6091
  (item) => item === void 0 || string2(item)
6037
6092
  );
6038
6093
  }
6039
6094
  function isAnchor(value) {
6040
- return isRecord2(value) && exact(value, ["anchorId", "anchor", "title", "type"], ["scope"]) && [value.anchorId, value.anchor, value.title].every(string2) && ["heading", "member"].includes(String(value.type)) && (value.scope === void 0 || isRecord2(value.scope) && exact(value.scope, ["key", "title"]) && string2(value.scope.key) && string2(value.scope.title));
6095
+ return isRecord2(value) && exact(value, ["anchorId", "anchor", "title", "type"], ["scope"]) && [value["anchorId"], value["anchor"], value["title"]].every(string2) && ["heading", "member"].includes(String(value["type"])) && (value["scope"] === void 0 || isRecord2(value["scope"]) && exact(value["scope"], ["key", "title"]) && string2(value["scope"]["key"]) && string2(value["scope"]["title"]));
6041
6096
  }
6042
6097
  function isLinkedContent(value) {
6043
- if (!isRecord2(value) || !exact(value, ["ir", "html", "searchRecords", "keywordDigest"]) || !string2(value.html) || !string2(value.keywordDigest) || !Array.isArray(value.searchRecords) || !value.searchRecords.every(isSearch) || !isRecord2(value.ir))
6098
+ if (!isRecord2(value) || !exact(value, ["ir", "html", "searchRecords", "keywordDigest"]) || !string2(value["html"]) || !string2(value["keywordDigest"]) || !Array.isArray(value["searchRecords"]) || !value["searchRecords"].every(isSearch) || !isRecord2(value["ir"]))
6044
6099
  return false;
6045
- const ir = value.ir;
6100
+ const ir = value["ir"];
6046
6101
  return exact(
6047
6102
  ir,
6048
6103
  [
@@ -6061,7 +6116,9 @@ function isLinkedContent(value) {
6061
6116
  "diagnostics"
6062
6117
  ],
6063
6118
  ["icon", "searchBreadcrumbs"]
6064
- ) && ir.schemaVersion === SCHEMA_VERSION && [ir.id, ir.entryId, ir.title, ir.route, ir.absoluteRoute, ir.html].every(string2) && ["guide-tab", "api-tab", "header", "demo-assets"].includes(String(ir.role)) && (ir.searchBreadcrumbs === void 0 || stringArray(ir.searchBreadcrumbs)) && (ir.icon === void 0 || string2(ir.icon)) && Array.isArray(ir.anchors) && ir.anchors.every(isAnchor) && Array.isArray(ir.exportedKeywords) && ir.exportedKeywords.every(isKeyword) && stringArray(ir.usedKeywords) && Array.isArray(ir.dependencies) && ir.dependencies.every(isDependency) && Array.isArray(ir.diagnostics) && ir.diagnostics.every(isDiagnostic);
6119
+ ) && ir["schemaVersion"] === SCHEMA_VERSION && [ir["id"], ir["entryId"], ir["title"], ir["route"], ir["absoluteRoute"], ir["html"]].every(
6120
+ string2
6121
+ ) && ["guide-tab", "api-tab", "header", "demo-assets"].includes(String(ir["role"])) && (ir["searchBreadcrumbs"] === void 0 || stringArray(ir["searchBreadcrumbs"])) && (ir["icon"] === void 0 || string2(ir["icon"])) && Array.isArray(ir["anchors"]) && ir["anchors"].every(isAnchor) && Array.isArray(ir["exportedKeywords"]) && ir["exportedKeywords"].every(isKeyword) && stringArray(ir["usedKeywords"]) && Array.isArray(ir["dependencies"]) && ir["dependencies"].every(isDependency) && Array.isArray(ir["diagnostics"]) && ir["diagnostics"].every(isDiagnostic);
6065
6122
  }
6066
6123
  function isRoute(value) {
6067
6124
  return isRecord2(value) && exact(
@@ -6075,23 +6132,31 @@ function isRoute(value) {
6075
6132
  "metadata",
6076
6133
  "category",
6077
6134
  "modulePath",
6078
- "apiListSegment"
6135
+ "apiListSegment",
6136
+ "demoModulePath",
6137
+ "demoNames",
6138
+ "playgroundPages"
6079
6139
  ]
6080
- ) && [value.id, value.path, value.title].every(string2) && (value.parentId === void 0 || string2(value.parentId)) && (value.order === void 0 || finite(value.order)) && (value.hidden === void 0 || typeof value.hidden === "boolean") && (value.icon === void 0 || string2(value.icon)) && (value.modulePath === void 0 || string2(value.modulePath)) && (value.apiListSegment === void 0 || string2(value.apiListSegment)) && (value.metadata === void 0 || isRecord2(value.metadata) && exact(value.metadata, ["description", "tags"]) && string2(value.metadata.description) && isRecord2(value.metadata.tags) && Object.values(value.metadata.tags).every(stringArray)) && (value.category === void 0 || isRecord2(value.category) && exact(value.category, ["runtimeImport"], ["expandable", "expanded"]) && isRecord2(value.category.runtimeImport) && exact(value.category.runtimeImport, ["source", "exportName"]) && string2(value.category.runtimeImport.source) && string2(value.category.runtimeImport.exportName) && (value.category.expandable === void 0 || typeof value.category.expandable === "boolean") && (value.category.expanded === void 0 || typeof value.category.expanded === "boolean"));
6140
+ ) && [value["id"], value["path"], value["title"]].every(string2) && (value["parentId"] === void 0 || string2(value["parentId"])) && (value["order"] === void 0 || finite(value["order"])) && (value["hidden"] === void 0 || typeof value["hidden"] === "boolean") && (value["icon"] === void 0 || string2(value["icon"])) && (value["modulePath"] === void 0 || string2(value["modulePath"])) && (value["apiListSegment"] === void 0 || string2(value["apiListSegment"])) && (value["demoModulePath"] === void 0 || string2(value["demoModulePath"])) && (value["demoNames"] === void 0 || stringArray(value["demoNames"])) && (value["playgroundPages"] === void 0 || stringArray(value["playgroundPages"])) && (value["metadata"] === void 0 || isRecord2(value["metadata"]) && exact(value["metadata"], ["description", "tags"]) && string2(value["metadata"]["description"]) && isRecord2(value["metadata"]["tags"]) && Object.values(value["metadata"]["tags"]).every(stringArray)) && (value["category"] === void 0 || isRecord2(value["category"]) && exact(value["category"], ["runtimeImport"], ["expandable", "expanded"]) && isRecord2(value["category"]["runtimeImport"]) && exact(value["category"]["runtimeImport"], ["source", "exportName"]) && string2(value["category"]["runtimeImport"]["source"]) && string2(value["category"]["runtimeImport"]["exportName"]) && (value["category"]["expandable"] === void 0 || typeof value["category"]["expandable"] === "boolean") && (value["category"]["expanded"] === void 0 || typeof value["category"]["expanded"] === "boolean"));
6081
6141
  }
6082
6142
  function isApiList(value) {
6083
6143
  return isRecord2(value) && exact(
6084
6144
  value,
6085
6145
  ["apiEntryId", "scopeId", "scopeTitle", "name", "type", "route"],
6086
6146
  ["description", "signature"]
6087
- ) && [value.apiEntryId, value.scopeId, value.scopeTitle, value.name, value.type, value.route].every(
6088
- string2
6089
- ) && [value.description, value.signature].every((item) => item === void 0 || string2(item));
6147
+ ) && [
6148
+ value["apiEntryId"],
6149
+ value["scopeId"],
6150
+ value["scopeTitle"],
6151
+ value["name"],
6152
+ value["type"],
6153
+ value["route"]
6154
+ ].every(string2) && [value["description"], value["signature"]].every((item) => item === void 0 || string2(item));
6090
6155
  }
6091
6156
  function isFileOutput(value) {
6092
- return isRecord2(value) && exact(value, ["path", "role", "encoding", "content", "digest"]) && string2(value.path) && ["angular", "content", "asset", "routes", "context", "search", "api-list"].includes(
6093
- String(value.role)
6094
- ) && ["utf8", "base64"].includes(String(value.encoding)) && string2(value.content) && string2(value.digest);
6157
+ return isRecord2(value) && exact(value, ["path", "role", "encoding", "content", "digest"]) && string2(value["path"]) && ["angular", "content", "asset", "routes", "context", "search", "api-list"].includes(
6158
+ String(value["role"])
6159
+ ) && ["utf8", "base64"].includes(String(value["encoding"])) && string2(value["content"]) && string2(value["digest"]);
6095
6160
  }
6096
6161
  function isContentDescriptor(value) {
6097
6162
  if (!isRecord2(value) || !exact(
@@ -6115,23 +6180,23 @@ function isContentDescriptor(value) {
6115
6180
  ["icon", "keyword"]
6116
6181
  ))
6117
6182
  return false;
6118
- if (value.schemaVersion !== SCHEMA_VERSION || ![
6119
- value.id,
6120
- value.ownerId,
6121
- value.title,
6122
- value.route,
6123
- value.absoluteRoute,
6124
- value.inputDigest,
6125
- value.requestDigest
6126
- ].every(string2) || ![value.id, value.ownerId, value.inputDigest, value.requestDigest].every(
6183
+ if (value["schemaVersion"] !== SCHEMA_VERSION || ![
6184
+ value["id"],
6185
+ value["ownerId"],
6186
+ value["title"],
6187
+ value["route"],
6188
+ value["absoluteRoute"],
6189
+ value["inputDigest"],
6190
+ value["requestDigest"]
6191
+ ].every(string2) || ![value["id"], value["ownerId"], value["inputDigest"], value["requestDigest"]].every(
6127
6192
  (item) => string2(item) && item.length > 0 && !item.includes("\0")
6128
- ) || !finite(value.ordinal) || value.ordinal < 0 || !Number.isInteger(value.ordinal) || !["guide-tab", "api-tab", "header"].includes(String(value.role)) || !stringArray(value.searchBreadcrumbs) || !Array.isArray(value.dependencies) || !value.dependencies.every((dependency) => isPhysicalDescriptorDependency(dependency)) || new Set(value.dependencies.map((dependency) => canonicalJson(dependency))).size !== value.dependencies.length || !stringArray(value.closureIds) || value.icon !== void 0 && !string2(value.icon) || value.keyword !== void 0 && !string2(value.keyword) || !isRecord2(value.locator))
6193
+ ) || !finite(value["ordinal"]) || value["ordinal"] < 0 || !Number.isInteger(value["ordinal"]) || !["guide-tab", "api-tab", "header"].includes(String(value["role"])) || !stringArray(value["searchBreadcrumbs"]) || !Array.isArray(value["dependencies"]) || !value["dependencies"].every((dependency) => isPhysicalDescriptorDependency(dependency)) || new Set(value["dependencies"].map((dependency) => canonicalJson(dependency))).size !== value["dependencies"].length || !stringArray(value["closureIds"]) || value["icon"] !== void 0 && !string2(value["icon"]) || value["keyword"] !== void 0 && !string2(value["keyword"]) || !isRecord2(value["locator"]))
6129
6194
  return false;
6130
- const locator = value.locator;
6131
- return value.role === "header" ? exact(locator, ["kind"]) && locator.kind === "header" : value.role === "guide-tab" ? exact(locator, ["kind", "markdown"]) && locator.kind === "guide-tab" && string2(locator.markdown) : exact(locator, ["kind", "declarationId"]) && locator.kind === "api-tab" && string2(locator.declarationId);
6195
+ const locator = value["locator"];
6196
+ return value["role"] === "header" ? exact(locator, ["kind"]) && locator["kind"] === "header" : value["role"] === "guide-tab" ? exact(locator, ["kind", "markdown"]) && locator["kind"] === "guide-tab" && string2(locator["markdown"]) : exact(locator, ["kind", "declarationId"]) && locator["kind"] === "api-tab" && string2(locator["declarationId"]);
6132
6197
  }
6133
6198
  function isPhysicalDescriptorDependency(value) {
6134
- return isRecord2(value) && (value.kind === "content" && exact(value, ["kind", "path", "digest"]) && absoluteNormalizedPath(value.path) && string2(value.digest) || value.kind === "existence" && exact(value, ["kind", "path", "exists"]) && absoluteNormalizedPath(value.path) && typeof value.exists === "boolean");
6199
+ return isRecord2(value) && (value["kind"] === "content" && exact(value, ["kind", "path", "digest"]) && absoluteNormalizedPath(value["path"]) && string2(value["digest"]) || value["kind"] === "existence" && exact(value, ["kind", "path", "exists"]) && absoluteNormalizedPath(value["path"]) && typeof value["exists"] === "boolean");
6135
6200
  }
6136
6201
  function validDescriptorPlan(artifact) {
6137
6202
  const descriptors = artifact.contentDescriptors;
@@ -6216,7 +6281,7 @@ function isPageArtifact(value) {
6216
6281
  "diagnostics"
6217
6282
  ],
6218
6283
  ["contentDescriptors"]
6219
- ) && string2(value.id) && isIdentity(value.identity) && string2(value.revision) && isFingerprint(value.fingerprint) && Array.isArray(value.dependencies) && value.dependencies.every(isDependency) && Array.isArray(value.content) && value.content.every(isLinkedContent) && Array.isArray(value.exportedKeywords) && value.exportedKeywords.every(isKeyword) && stringArray(value.usedKeywords) && Array.isArray(value.searchRecords) && value.searchRecords.every(isSearch) && Array.isArray(value.routes) && value.routes.every(isRoute) && Array.isArray(value.apiList) && value.apiList.every(isApiList) && Array.isArray(value.outputs) && value.outputs.every((output) => isFileOutput(output) && validOutputDigest(output)) && Array.isArray(value.diagnostics) && value.diagnostics.every(isDiagnostic) && validDescriptorPlan(value);
6284
+ ) && string2(value["id"]) && isIdentity(value["identity"]) && string2(value["revision"]) && isFingerprint(value["fingerprint"]) && Array.isArray(value["dependencies"]) && value["dependencies"].every(isDependency) && Array.isArray(value["content"]) && value["content"].every(isLinkedContent) && Array.isArray(value["exportedKeywords"]) && value["exportedKeywords"].every(isKeyword) && stringArray(value["usedKeywords"]) && Array.isArray(value["searchRecords"]) && value["searchRecords"].every(isSearch) && Array.isArray(value["routes"]) && value["routes"].every(isRoute) && Array.isArray(value["apiList"]) && value["apiList"].every(isApiList) && Array.isArray(value["outputs"]) && value["outputs"].every((output) => isFileOutput(output) && validOutputDigest(output)) && Array.isArray(value["diagnostics"]) && value["diagnostics"].every(isDiagnostic) && validDescriptorPlan(value);
6220
6285
  }
6221
6286
  function isJsonTree(value, ancestors = /* @__PURE__ */ new WeakSet()) {
6222
6287
  if (value === null || string2(value) || typeof value === "boolean") return true;
@@ -6251,19 +6316,19 @@ function validOutputDigest(output) {
6251
6316
  }
6252
6317
  }
6253
6318
  function isPublishedGeneratorConfiguration(value) {
6254
- return isJsonTree(value) && isRecord2(value) && exact(value, ["outputRoot", "cacheRoot", "assetDirectory", "themes", "digest"]) && [value.outputRoot, value.cacheRoot].every(
6319
+ return isJsonTree(value) && isRecord2(value) && exact(value, ["outputRoot", "cacheRoot", "assetDirectory", "themes", "digest"]) && [value["outputRoot"], value["cacheRoot"]].every(
6255
6320
  (item) => string2(item) && path6.isAbsolute(item) && path6.resolve(item).replace(/\\/g, "/") === item && !item.includes("\0")
6256
- ) && string2(value.assetDirectory) && !path6.win32.parse(value.assetDirectory).root && safeRelative(value.assetDirectory) && isRecord2(value.themes) && exact(value.themes, ["light", "dark"]) && string2(value.themes.light) && string2(value.themes.dark) && string2(value.digest);
6321
+ ) && string2(value["assetDirectory"]) && !path6.win32.parse(value["assetDirectory"]).root && safeRelative(value["assetDirectory"]) && isRecord2(value["themes"]) && exact(value["themes"], ["light", "dark"]) && string2(value["themes"]["light"]) && string2(value["themes"]["dark"]) && string2(value["digest"]);
6257
6322
  }
6258
6323
  function isArtifactSnapshotShape(value) {
6259
6324
  return isJsonTree(value) && isRecord2(value) && exact(
6260
6325
  value,
6261
6326
  ["projectId", "revision", "artifacts", "globalKeywords", "remoteKeywords"],
6262
6327
  ["configuration"]
6263
- ) && (value.configuration === void 0 || isPublishedGeneratorConfiguration(value.configuration)) && string2(value.projectId) && string2(value.revision) && Array.isArray(value.artifacts) && value.artifacts.every(isPageArtifact) && Array.isArray(value.globalKeywords) && value.globalKeywords.every(isKeyword) && Array.isArray(value.remoteKeywords) && value.remoteKeywords.every(isRemoteKeywords);
6328
+ ) && (value["configuration"] === void 0 || isPublishedGeneratorConfiguration(value["configuration"])) && string2(value["projectId"]) && string2(value["revision"]) && Array.isArray(value["artifacts"]) && value["artifacts"].every(isPageArtifact) && Array.isArray(value["globalKeywords"]) && value["globalKeywords"].every(isKeyword) && Array.isArray(value["remoteKeywords"]) && value["remoteKeywords"].every(isRemoteKeywords);
6264
6329
  }
6265
6330
  function isRemoteKeywords(remote) {
6266
- return isRecord2(remote) && exact(remote, ["loaderId", "digest", "keywords"], ["validator"]) && string2(remote.loaderId) && string2(remote.digest) && Array.isArray(remote.keywords) && remote.keywords.every(isKeyword) && (remote.validator === void 0 || string2(remote.validator));
6331
+ return isRecord2(remote) && exact(remote, ["loaderId", "digest", "keywords"], ["validator"]) && string2(remote["loaderId"]) && string2(remote["digest"]) && Array.isArray(remote["keywords"]) && remote["keywords"].every(isKeyword) && (remote["validator"] === void 0 || string2(remote["validator"]));
6267
6332
  }
6268
6333
  function isSnapshotEnvelope(value) {
6269
6334
  if (!isRecord2(value) || Object.getPrototypeOf(value) !== Object.prototype) return false;
@@ -6274,7 +6339,7 @@ function isSnapshotEnvelope(value) {
6274
6339
  return descriptor?.enumerable === true && "value" in descriptor;
6275
6340
  }))
6276
6341
  return false;
6277
- const artifacts = value.artifacts;
6342
+ const artifacts = value["artifacts"];
6278
6343
  if (!Array.isArray(artifacts) || Object.getPrototypeOf(artifacts) !== Array.prototype || Reflect.ownKeys(artifacts).length !== artifacts.length + 1)
6279
6344
  return false;
6280
6345
  for (let index = 0; index < artifacts.length; index += 1)
@@ -6283,14 +6348,14 @@ function isSnapshotEnvelope(value) {
6283
6348
  value,
6284
6349
  ["projectId", "revision", "artifacts", "globalKeywords", "remoteKeywords"],
6285
6350
  ["configuration"]
6286
- ) && (value.configuration === void 0 || isPublishedGeneratorConfiguration(value.configuration)) && string2(value.projectId) && string2(value.revision) && isJsonTree(value.globalKeywords) && Array.isArray(value.globalKeywords) && value.globalKeywords.every(isKeyword) && isJsonTree(value.remoteKeywords) && Array.isArray(value.remoteKeywords) && value.remoteKeywords.every(isRemoteKeywords);
6351
+ ) && (value["configuration"] === void 0 || isPublishedGeneratorConfiguration(value["configuration"])) && string2(value["projectId"]) && string2(value["revision"]) && isJsonTree(value["globalKeywords"]) && Array.isArray(value["globalKeywords"]) && value["globalKeywords"].every(isKeyword) && isJsonTree(value["remoteKeywords"]) && Array.isArray(value["remoteKeywords"]) && value["remoteKeywords"].every(isRemoteKeywords);
6287
6352
  }
6288
6353
  function isOutputManifest(value) {
6289
- return isJsonTree(value) && isRecord2(value) && exact(value, ["schemaVersion", "projectId", "generation", "revision", "files"]) && value.schemaVersion === OUTPUT_SCHEMA_VERSION && string2(value.projectId) && finite(value.generation) && string2(value.revision) && Array.isArray(value.files) && value.files.every(
6290
- (file) => isRecord2(file) && exact(file, ["path", "ownerId", "digest", "role"]) && string2(file.path) && string2(file.ownerId) && string2(file.digest) && safeRelative(file.path) && ["angular", "content", "asset", "routes", "context", "search", "api-list"].includes(
6291
- String(file.role)
6354
+ return isJsonTree(value) && isRecord2(value) && exact(value, ["schemaVersion", "projectId", "generation", "revision", "files"]) && value["schemaVersion"] === OUTPUT_SCHEMA_VERSION && string2(value["projectId"]) && finite(value["generation"]) && string2(value["revision"]) && Array.isArray(value["files"]) && value["files"].every(
6355
+ (file) => isRecord2(file) && exact(file, ["path", "ownerId", "digest", "role"]) && string2(file["path"]) && string2(file["ownerId"]) && string2(file["digest"]) && safeRelative(file["path"]) && ["angular", "content", "asset", "routes", "context", "search", "api-list"].includes(
6356
+ String(file["role"])
6292
6357
  )
6293
- ) && new Set(value.files.map((file) => file.path)).size === value.files.length;
6358
+ ) && new Set(value["files"].map((file) => file.path)).size === value["files"].length;
6294
6359
  }
6295
6360
  function safeRelative(value) {
6296
6361
  try {
@@ -6582,16 +6647,18 @@ function quoteWindowsArgument(value, twice = false) {
6582
6647
  }
6583
6648
  function nodeEntry(command, options) {
6584
6649
  const exists2 = options.isFile ?? isFile;
6585
- const name = /^(ng|npm|npx)(?:\.cmd)?$/i.exec(command)?.[1]?.toLowerCase();
6650
+ const name = /^(ng|npm|npx|pnpm|pnpx)(?:\.cmd)?$/i.exec(command)?.[1]?.toLowerCase();
6586
6651
  if (!name) return void 0;
6652
+ const nodeDirectory = path8.win32.dirname(options.execPath ?? process.execPath);
6653
+ if (name === "pnpm" || name === "pnpx") {
6654
+ const shim = resolveWindowsCommand(name, options);
6655
+ if (!shim || path8.win32.dirname(shim).toLowerCase() !== nodeDirectory.toLowerCase())
6656
+ return void 0;
6657
+ const entry = path8.win32.join(nodeDirectory, "node_modules", "corepack", "dist", `${name}.js`);
6658
+ return exists2(entry) ? entry : void 0;
6659
+ }
6587
6660
  if (name !== "ng") {
6588
- const entry = path8.win32.join(
6589
- path8.win32.dirname(options.execPath ?? process.execPath),
6590
- "node_modules",
6591
- "npm",
6592
- "bin",
6593
- `${name}-cli.js`
6594
- );
6661
+ const entry = path8.win32.join(nodeDirectory, "node_modules", "npm", "bin", `${name}-cli.js`);
6595
6662
  return exists2(entry) ? entry : void 0;
6596
6663
  }
6597
6664
  for (let directory = path8.win32.resolve(options.cwd); ; ) {