@arcgis/api-extractor 5.2.0-next.30 → 5.2.0-next.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
- import { l as H, a as se, e as Ge, p as pe } from "./typeScript-BefbgHqD.js";
2
- import { a as re, o as xe, t as De, b as Le, c as Ne, e as Oe, p as Be, d as We, f as _, i as ue, g as Ue, h as je, j as ze, k as He, n as Je, r as Ve } from "./worker-DyCrruHC.js";
1
+ import { l as H, a as se, e as Ge, p as pe } from "./typeScript-D9-14xKa.js";
2
+ import { a as re, o as xe, t as De, b as Le, c as Ne, e as Oe, p as Be, d as We, f as _, i as ue, g as Ue, h as je, j as ze, k as He, n as Je, r as Ve } from "./worker-CD_LOCAU.js";
3
3
  import { getViewUrl as Xe, postProcessDeprecated as Q, postProcessDescription as G, postProcessDocsTags as V, resolveJsDocLink as Ye } from "./extractor/processing/links.js";
4
4
  import E from "typescript";
5
- import { path as O, toPosixPathSeparators as qe } from "@arcgis/components-build-utils";
5
+ import { path as O, toPosixPathSeparators as qe } from "@arcgis/node-toolkit/path";
6
6
  import { mkdir as ae, writeFile as Pe } from "fs/promises";
7
7
  import { styleText as x } from "node:util";
8
8
  import { kebabToPascal as Ze } from "@arcgis/toolkit/string";
@@ -1,4 +1,4 @@
1
- import { path as s } from "@arcgis/components-build-utils";
1
+ import { path as s } from "@arcgis/node-toolkit/path";
2
2
  import { execSync as c } from "node:child_process";
3
3
  import { mkdir as m, writeFile as d } from "node:fs/promises";
4
4
  const a = "diff --new-file --recursive", u = `${a} --unified=2`;
@@ -1,8 +1,8 @@
1
- import "../typeScript-BefbgHqD.js";
2
- import "../worker-DyCrruHC.js";
1
+ import "../typeScript-D9-14xKa.js";
2
+ import "../worker-CD_LOCAU.js";
3
3
  import "./processing/links.js";
4
4
  import "typescript";
5
- import { A as x } from "../ApiExtractor-CWl5XnZ5.js";
5
+ import { A as x } from "../ApiExtractor-DS2lno-G.js";
6
6
  import "@arcgis/toolkit/function";
7
7
  export {
8
8
  x as ApiExtractor
@@ -1,5 +1,5 @@
1
1
  import type ts from "typescript";
2
- import type { PackageJson } from "@arcgis/components-build-utils";
2
+ import type { PackageJson } from "@arcgis/node-toolkit/packageJson";
3
3
  import type { CopyDocDefinitions } from "./extractors/copyDoc.js";
4
4
  import type { ApiExtractor } from "./ApiExtractor.js";
5
5
  import type { TypeScriptConfigResult } from "../vite/typeScript.js";
@@ -1,6 +1,8 @@
1
- import "@arcgis/components-build-utils";
2
- import "../typeScript-BefbgHqD.js";
3
- import { l as n, m as A, r as C } from "../worker-DyCrruHC.js";
1
+ import "@arcgis/node-toolkit/file";
2
+ import "@arcgis/node-toolkit/path";
3
+ import "@arcgis/node-toolkit/packageJson";
4
+ import "../typeScript-D9-14xKa.js";
5
+ import { l as C, m as E, r as d } from "../worker-CD_LOCAU.js";
4
6
  import "./processing/links.js";
5
7
  import "typescript";
6
8
  import "fs/promises";
@@ -12,7 +14,7 @@ import "@arcgis/toolkit/function";
12
14
  import "node:fs";
13
15
  import "node:url";
14
16
  export {
15
- n as loadApiExtractorConfig,
16
- A as mergeApiExtractorConfigs,
17
- C as resolveApiExtractorConfig
17
+ C as loadApiExtractorConfig,
18
+ E as mergeApiExtractorConfigs,
19
+ d as resolveApiExtractorConfig
18
20
  };
@@ -1,4 +1,4 @@
1
- import { path as a } from "@arcgis/components-build-utils";
1
+ import { path as a } from "@arcgis/node-toolkit/path";
2
2
  function u(o, s, n) {
3
3
  const e = n.indexOf(a.sep);
4
4
  let t = s.componentPathMapping;
@@ -0,0 +1,67 @@
1
+ import { findPath as E } from "@arcgis/node-toolkit/file";
2
+ import { path as u, toSystemPathSeparators as S } from "@arcgis/node-toolkit/path";
3
+ import t from "typescript";
4
+ import { styleText as l } from "util";
5
+ const w = "@arcgis/api-extractor", P = "5.2.0-next.31", D = {
6
+ name: w,
7
+ version: P
8
+ };
9
+ let x;
10
+ function N(o) {
11
+ return x ??= t.createPrinter(), x.printNode(t.EmitHint.Unspecified, o, void 0);
12
+ }
13
+ function A(o, r) {
14
+ return o.pos !== -1 && o.end !== -1 && r !== void 0 ? o.getText(r) : N(o);
15
+ }
16
+ let h;
17
+ const g = D.name, m = {
18
+ getCurrentDirectory: process.cwd,
19
+ getCanonicalFileName: (o) => o,
20
+ getNewLine: () => t.sys.newLine
21
+ }, W = function(o, { file: r, node: n, scope: i, start: s, length: c }) {
22
+ this.errorCount += 1, process.exitCode = 1, s ??= n === void 0 || n.pos === -1 ? -1 : n.getStart(r, !1);
23
+ const a = n?.end ?? -1;
24
+ c ??= a === -1 ? -1 : Math.max(1, a - s);
25
+ const e = s >= 0 && c >= 0, d = !e && i !== void 0, p = {
26
+ category: t.DiagnosticCategory.Error,
27
+ code: e ? g : v,
28
+ file: d ? void 0 : r,
29
+ start: e ? s : 0,
30
+ length: e ? c : 0,
31
+ messageText: (d ? `${l("cyan", i, { stream: process.stderr })}: ` : "") + o + (e || n === void 0 ? "" : `
32
+
33
+ ${A(n, r)}`)
34
+ }, f = t.formatDiagnosticsWithColorAndContext([p], m);
35
+ h ??= process.env.CI !== void 0 || l("red", "", { stream: process.stderr }) !== "";
36
+ const C = h ? f : f.replaceAll(F, ""), y = e ? C : C.replace(v.toString(), g);
37
+ this.config.context.logger.error(y);
38
+ }, v = 1490, F = /\x1B\[[0-9;]*m/gu, k = l("cyan", `[${g}] `);
39
+ function J(o = process.cwd(), r, n) {
40
+ const i = r === void 0 ? E("tsconfig.json", o) : u.resolve(o, r);
41
+ if (i === void 0)
42
+ throw Error(
43
+ `Unable to find ${S(String(r))}. Please make sure the file exists, or provide types.tsconfigPath option to useLumina()`
44
+ );
45
+ const s = t.readConfigFile(i, t.sys.readFile);
46
+ if (s.error !== void 0)
47
+ throw Error(t.formatDiagnosticsWithColorAndContext([s.error], m));
48
+ const c = s.config, a = n ? c : {
49
+ ...c,
50
+ include: [],
51
+ files: [],
52
+ exclude: []
53
+ }, e = t.parseJsonConfigFileContent(a, t.sys, u.dirname(i)), d = 18002, p = n ? e.errors : e.errors.filter((f) => f.code !== d);
54
+ if (p.length > 0)
55
+ throw Error(t.formatDiagnosticsWithColorAndContext(p, m));
56
+ return {
57
+ configPath: i,
58
+ config: e
59
+ };
60
+ }
61
+ export {
62
+ m as a,
63
+ J as b,
64
+ W as e,
65
+ k as l,
66
+ D as p
67
+ };
@@ -1,8 +1,8 @@
1
- import { l as O, m as J } from "../worker-DyCrruHC.js";
2
- import { A as S, w as T } from "../ApiExtractor-CWl5XnZ5.js";
3
- import { p as A, l as C } from "../typeScript-BefbgHqD.js";
1
+ import { l as O, m as J } from "../worker-CD_LOCAU.js";
2
+ import { A as S, w as T } from "../ApiExtractor-DS2lno-G.js";
3
+ import { p as A, l as C } from "../typeScript-D9-14xKa.js";
4
4
  import { writeFile as M } from "node:fs/promises";
5
- import { path as w } from "@arcgis/components-build-utils";
5
+ import { path as w } from "@arcgis/node-toolkit/path";
6
6
  const N = A.name;
7
7
  function $(s = {}) {
8
8
  let t = !1, v = !1, e, o, c, l, E = !0, h = !1, f, m, u, y, p;
@@ -1,6 +1,7 @@
1
- import "@arcgis/components-build-utils";
1
+ import "@arcgis/node-toolkit/file";
2
+ import "@arcgis/node-toolkit/path";
2
3
  import "typescript";
3
- import { b as t } from "../typeScript-BefbgHqD.js";
4
+ import { b as m } from "../typeScript-D9-14xKa.js";
4
5
  export {
5
- t as loadTypeScriptConfig
6
+ m as loadTypeScriptConfig
6
7
  };
@@ -1,5 +1,7 @@
1
- import { path as He, existsAsync as ei, getCwd as Li, retrievePackageJson as ct, toPosixPathSeparators as Ii } from "@arcgis/components-build-utils";
2
- import { b as Ai, p as ki, l as Gi } from "./typeScript-BefbgHqD.js";
1
+ import { existsAsync as ei } from "@arcgis/node-toolkit/file";
2
+ import { path as He, getCwd as Li, toPosixPathSeparators as Ii } from "@arcgis/node-toolkit/path";
3
+ import { retrievePackageJson as ct } from "@arcgis/node-toolkit/packageJson";
4
+ import { b as Ai, p as ki, l as Gi } from "./typeScript-D9-14xKa.js";
3
5
  import { getDefaultBasePath as ti, buildViewUrl as Fi, getViewUrl as Ue } from "./extractor/processing/links.js";
4
6
  import o from "typescript";
5
7
  import "fs/promises";
@@ -19,7 +21,7 @@ import { pathToFileURL as tn } from "node:url";
19
21
  import nn from "path";
20
22
  import { getWidenedLiteralType as on, unsafeUndocumentedTs as an, unsafeGetUndocumentedPrinter as rn } from "./utils/internalTypeScriptApis.js";
21
23
  const At = "developers.arcgis.com", kt = "next.gha.afd.arcgis.com";
22
- function Sa(e) {
24
+ function Ta(e) {
23
25
  if (e.isResolvedConfig === !0)
24
26
  return e;
25
27
  const t = e.context, n = e.types, i = e.documentation, r = `${t?.cwd === void 0 ? Li() : He.resolve(t?.cwd)}/`, s = t?.packageJson ?? ct(r);
@@ -115,7 +117,7 @@ function Sa(e) {
115
117
  afterApiJsonCreate: e.afterApiJsonCreate ?? Se
116
118
  };
117
119
  }
118
- async function ga(e, t) {
120
+ async function ha(e, t) {
119
121
  const n = t !== void 0, i = e ?? process.cwd(), a = He.resolve(i, t ?? "api-extractor.config.ts"), r = await ei(a);
120
122
  if (n && !r)
121
123
  throw Error(`The provided config file at ${a} does not exist.`);
@@ -130,7 +132,7 @@ async function ga(e, t) {
130
132
  }
131
133
  };
132
134
  }
133
- function Ta(e, t) {
135
+ function Ea(e, t) {
134
136
  const n = e.context, i = t.context, a = e.types, r = t.types, s = e.documentation, l = t.documentation, c = e.verify, p = t.verify, d = e.watch, m = t.watch;
135
137
  return {
136
138
  isResolvedConfig: e.isResolvedConfig || t.isResolvedConfig || void 0,
@@ -562,7 +564,7 @@ export namespace tsx {
562
564
  return e;
563
565
  }
564
566
  }
565
- function ha(e, t) {
567
+ function Ca(e, t) {
566
568
  let n = `/// <reference types="../index.d.ts" />
567
569
  `, i = `
568
570
 
@@ -705,7 +707,7 @@ function Sn(e, t) {
705
707
  ` : "";
706
708
  return [r.length === 0 ? "" : `${r}, `, s];
707
709
  }
708
- function Ea(e, t) {
710
+ function Pa(e, t) {
709
711
  const n = t.moduleMap.get("index");
710
712
  if (n === void 0)
711
713
  e.unshift(gn);
@@ -889,7 +891,7 @@ function Ot(e, t) {
889
891
  }
890
892
  return !0;
891
893
  }
892
- function Ca(e, t) {
894
+ function ba(e, t) {
893
895
  const n = Te(e), i = he(n), a = me(e);
894
896
  if (a.index.class?.privacy !== void 0)
895
897
  return e.declarations.length > 1 && t.emitError(
@@ -1120,7 +1122,7 @@ Use EventNames and EventTypes helpers from @arcgis/core/Evented`
1120
1122
  }
1121
1123
  ]
1122
1124
  });
1123
- function Pa() {
1125
+ function Ma() {
1124
1126
  const e = Date.now();
1125
1127
  return () => (Date.now() - e) / Cn;
1126
1128
  }
@@ -2558,7 +2560,7 @@ function Jt(e) {
2558
2560
  }
2559
2561
  t & ko || n || (oe = !0);
2560
2562
  }
2561
- const ko = o.TypeFlags.Null | o.TypeFlags.VoidLike, ba = (e) => e.map(Go).join(" | "), Go = (e) => e.type === "string" && e.value !== void 0 ? `"${e.value}"` : e.value ?? e.type;
2563
+ const ko = o.TypeFlags.Null | o.TypeFlags.VoidLike, xa = (e) => e.map(Go).join(" | "), Go = (e) => e.type === "string" && e.value !== void 0 ? `"${e.value}"` : e.value ?? e.type;
2562
2564
  function Fo(e, t, n) {
2563
2565
  let i;
2564
2566
  const a = e.initializer;
@@ -3565,7 +3567,7 @@ function Ho(e, t) {
3565
3567
  }
3566
3568
  ) : (v && m.docsTags.push(N.internal), pn(h, m))), h;
3567
3569
  }
3568
- async function Ma(e) {
3570
+ async function Da(e) {
3569
3571
  const t = [], n = e.basePath, i = e.config.context.excludedDirectories, a = `${e.basePath}components/`, r = [], s = !e.config.strict || e.config.context.includeLuminaPrivateComponents;
3570
3572
  e.componentPathMapping = /* @__PURE__ */ Object.create(null);
3571
3573
  const l = e.isComponentProject ? (m) => zi(m, a) : () => !1, c = e.isComponentProject ? p : d;
@@ -3661,7 +3663,7 @@ async function Ma(e) {
3661
3663
  const $o = (e, t) => zo(e) && jo(e, t), zo = (e) => (e.endsWith(".ts") || e.endsWith(".tsx")) && !Mi(e), Mi = (e) => e.includes("__test") || e.includes(".e2e.") || e.includes(".spec.") || e.includes(".test."), jo = (e, t) => e.startsWith(t.basePath) && !t.config.context.excludedDirectories.has(
3662
3664
  Pn(e.slice(t.basePath.length))
3663
3665
  ) && !e.includes("node_modules"), Yt = 32, Jo = 64, xi = "@public", qo = Buffer.from(xi), Di = "@internal", Qo = Buffer.from(Di);
3664
- async function xa(e) {
3666
+ async function Ra(e) {
3665
3667
  await ei(e) && await Ri(e, /* @__PURE__ */ new Set(), $i);
3666
3668
  }
3667
3669
  async function Ri(e, t, n) {
@@ -3716,21 +3718,21 @@ function Zt(e, t) {
3716
3718
  }
3717
3719
  export {
3718
3720
  Tn as a,
3719
- Ea as b,
3720
- xa as c,
3721
- Ca as d,
3722
- Ma as e,
3723
- Pa as f,
3721
+ Pa as b,
3722
+ Ra as c,
3723
+ ba as d,
3724
+ Da as e,
3725
+ Ma as f,
3724
3726
  zo as g,
3725
3727
  jo as h,
3726
3728
  $o as i,
3727
3729
  Mi as j,
3728
3730
  Zt as k,
3729
- ga as l,
3730
- Ta as m,
3731
+ ha as l,
3732
+ Ea as m,
3731
3733
  Ot as n,
3732
3734
  Ft as o,
3733
- ha as p,
3734
- Sa as r,
3735
- ba as t
3735
+ Ca as p,
3736
+ Ta as r,
3737
+ xa as t
3736
3738
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcgis/api-extractor",
3
- "version": "5.2.0-next.30",
3
+ "version": "5.2.0-next.31",
4
4
  "description": "Documentation engine for WebGIS SDK packages",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -53,8 +53,8 @@
53
53
  "@commander-js/extra-typings": "^14.0.0",
54
54
  "commander": "^14.0.0",
55
55
  "tslib": "^2.8.1",
56
- "@arcgis/components-build-utils": "5.2.0-next.30",
57
- "@arcgis/toolkit": "5.2.0-next.30"
56
+ "@arcgis/node-toolkit": "5.2.0-next.31",
57
+ "@arcgis/toolkit": "5.2.0-next.31"
58
58
  },
59
59
  "peerDependencies": {
60
60
  "typescript": "~6.0.2",
@@ -1,66 +0,0 @@
1
- import { findPath as E, path as u, toSystemPathSeparators as S } from "@arcgis/components-build-utils";
2
- import t from "typescript";
3
- import { styleText as f } from "util";
4
- const w = "@arcgis/api-extractor", P = "5.2.0-next.30", D = {
5
- name: w,
6
- version: P
7
- };
8
- let x;
9
- function N(o) {
10
- return x ??= t.createPrinter(), x.printNode(t.EmitHint.Unspecified, o, void 0);
11
- }
12
- function A(o, e) {
13
- return o.pos !== -1 && o.end !== -1 && e !== void 0 ? o.getText(e) : N(o);
14
- }
15
- let h;
16
- const g = D.name, m = {
17
- getCurrentDirectory: process.cwd,
18
- getCanonicalFileName: (o) => o,
19
- getNewLine: () => t.sys.newLine
20
- }, L = function(o, { file: e, node: n, scope: i, start: s, length: c }) {
21
- this.errorCount += 1, process.exitCode = 1, s ??= n === void 0 || n.pos === -1 ? -1 : n.getStart(e, !1);
22
- const a = n?.end ?? -1;
23
- c ??= a === -1 ? -1 : Math.max(1, a - s);
24
- const r = s >= 0 && c >= 0, d = !r && i !== void 0, l = {
25
- category: t.DiagnosticCategory.Error,
26
- code: r ? g : v,
27
- file: d ? void 0 : e,
28
- start: r ? s : 0,
29
- length: r ? c : 0,
30
- messageText: (d ? `${f("cyan", i, { stream: process.stderr })}: ` : "") + o + (r || n === void 0 ? "" : `
31
-
32
- ${A(n, e)}`)
33
- }, p = t.formatDiagnosticsWithColorAndContext([l], m);
34
- h ??= process.env.CI !== void 0 || f("red", "", { stream: process.stderr }) !== "";
35
- const C = h ? p : p.replaceAll(F, ""), y = r ? C : C.replace(v.toString(), g);
36
- this.config.context.logger.error(y);
37
- }, v = 1490, F = /\x1B\[[0-9;]*m/gu, W = f("cyan", `[${g}] `);
38
- function k(o = process.cwd(), e, n) {
39
- const i = e === void 0 ? E("tsconfig.json", o) : u.resolve(o, e);
40
- if (i === void 0)
41
- throw Error(
42
- `Unable to find ${S(String(e))}. Please make sure the file exists, or provide types.tsconfigPath option to useLumina()`
43
- );
44
- const s = t.readConfigFile(i, t.sys.readFile);
45
- if (s.error !== void 0)
46
- throw Error(t.formatDiagnosticsWithColorAndContext([s.error], m));
47
- const c = s.config, a = n ? c : {
48
- ...c,
49
- include: [],
50
- files: [],
51
- exclude: []
52
- }, r = t.parseJsonConfigFileContent(a, t.sys, u.dirname(i)), d = 18002, l = n ? r.errors : r.errors.filter((p) => p.code !== d);
53
- if (l.length > 0)
54
- throw Error(t.formatDiagnosticsWithColorAndContext(l, m));
55
- return {
56
- configPath: i,
57
- config: r
58
- };
59
- }
60
- export {
61
- m as a,
62
- k as b,
63
- L as e,
64
- W as l,
65
- D as p
66
- };