@arcgis/api-extractor 5.2.0-next.10 → 5.2.0-next.12

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,18 +1,19 @@
1
- import { l as H, a as se, e as Re, p as pe } from "./typeScript-B79ma30F.js";
2
- import { a as re, o as xe, t as De, b as Le, c as Oe, e as Ne, 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-DDand5P_.js";
3
- import { getViewUrl as Xe, postProcessDeprecated as Q, postProcessDescription as R, postProcessDocsTags as V, resolveJsDocLink as Ye } from "./extractor/processing/links.js";
1
+ import { l as H, a as se, e as Ge, p as pe } from "./typeScript-DI0FVnqf.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-Der__ngY.js";
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 N, toPosixPathSeparators as qe } from "@arcgis/components-build-utils";
5
+ import { path as O, toPosixPathSeparators as qe } from "@arcgis/components-build-utils";
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";
9
- import { g as h, a as me, b as _e, c as Ke, d as Ie, e as oe, p as ne } from "./privateContext-CB7P40up.js";
10
- import { apiTypeToImportType as le, globalPackageIdentifier as fe, getApiMemberName as Qe, getMaybeStaticApiMemberName as ce, mergeApiNodes as Se, naturalSortModules as et, compareNamedNodes as tt, compareClassMembers as it } from "./utils/apiHelpers.js";
9
+ import { g as h, a as fe, b as _e, c as Ke, d as Ie, e as oe, p as ne } from "./privateContext-CB7P40up.js";
10
+ import { apiTypeToImportType as le, globalPackageIdentifier as me, getApiMemberName as Qe, getMaybeStaticApiMemberName as ce, mergeApiNodes as Se, naturalSortModules as et, compareNamedNodes as tt, compareClassMembers as it } from "./utils/apiHelpers.js";
11
11
  import { printTypeParameters as te, printTypeAlias as ot } from "./utils/partPrinter.js";
12
- import { identity as ke, debounce as nt } from "@arcgis/toolkit/function";
13
- import { hasRuntimeDeclaration as rt } from "./utils/inferEntrypoints.js";
14
- import { opendirSync as st, watch as at, readFileSync as lt, statSync as ct } from "node:fs";
15
- const k = "/** @deprecated since 5.0. Refactor using \\@arcgis/codemod */", dt = `${k}
12
+ import { getBasename as nt } from "./utils/astHelpers.js";
13
+ import { identity as ke, debounce as rt } from "@arcgis/toolkit/function";
14
+ import { hasRuntimeDeclaration as st } from "./utils/inferEntrypoints.js";
15
+ import { opendirSync as at, watch as lt, readFileSync as ct, statSync as dt } from "node:fs";
16
+ const k = "/** @deprecated since 5.0. Refactor using \\@arcgis/codemod */", ft = `${k}
16
17
  type HashMap<T> = Record<string, T | undefined>;
17
18
  ${k}
18
19
  type nullish = null | undefined;
@@ -1094,8 +1095,8 @@ declare namespace __esri {
1094
1095
  ${k}
1095
1096
  export type On = (eventName: string, eventHandler: EventHandlerCallback) => IHandle;
1096
1097
  }`;
1097
- let B, D, j, W, O = "", U = "", q = "", ee = "";
1098
- function ft(e, t) {
1098
+ let B, D, j, W, N = "", U = "", q = "", ee = "";
1099
+ function pt(e, t) {
1099
1100
  j = void 0, W = void 0, U = e.path, q = "", ee = "";
1100
1101
  const i = `import("./${U}.js")`;
1101
1102
  let o = "";
@@ -1109,9 +1110,9 @@ function ft(e, t) {
1109
1110
  const l = e.declarations[n];
1110
1111
  if (he(l), A.length === 0)
1111
1112
  continue;
1112
- const c = l.name === s, d = c ? "default" : l.name, f = l.kind === "function", m = l.kind === "variable";
1113
- if (f || m) {
1114
- if (f) {
1113
+ const c = l.name === s, d = c ? "default" : l.name, m = l.kind === "function", f = l.kind === "variable";
1114
+ if (m || f) {
1115
+ if (m) {
1115
1116
  if (l.name === r)
1116
1117
  continue;
1117
1118
  if (r = l.name, c) {
@@ -1132,34 +1133,34 @@ function ft(e, t) {
1132
1133
  `;
1133
1134
  continue;
1134
1135
  }
1135
- } else if (m && c) {
1136
+ } else if (f && c) {
1136
1137
  A.length !== 1 && t.emitError("Expected only a single @esriCompatibilityName tag on a default export variable.", {
1137
1138
  file: h(e).file,
1138
1139
  node: void 0
1139
1140
  }), Z(A[0], t), (D !== void 0 || B !== void 0) && t.emitError("Expected default export @esriCompatibilityName tag to not include a # or .", {
1140
1141
  file: h(e).file,
1141
1142
  node: void 0
1142
- }), o += ` export const ${O}: typeof ${i}.default;
1143
+ }), o += ` export const ${N}: typeof ${i}.default;
1143
1144
 
1144
1145
  `;
1145
1146
  continue;
1146
1147
  }
1147
1148
  for (let p = 0; p < A.length; ++p)
1148
- Z(A[p], t), m && j !== void 0 ? q += ` export const ${O}: ${i}.${d};
1149
- ` : ee += ` ${O}: typeof ${i}.${d};
1149
+ Z(A[p], t), f && j !== void 0 ? q += ` export const ${N}: ${i}.${d};
1150
+ ` : ee += ` ${N}: typeof ${i}.${d};
1150
1151
  `;
1151
- } else if (l.kind === "class" || l.kind === "mixin" || l.kind === "interface" && me(l).isMixinBaseClass === !0) {
1152
+ } else if (l.kind === "class" || l.kind === "mixin" || l.kind === "interface" && fe(l).isMixinBaseClass === !0) {
1152
1153
  const p = te(K(l.typeParameters, !1, U)), g = te(K(l.typeParameters, !1, void 0)), u = te(K(l.typeParameters, !0, void 0)), v = ` ${i}.${d}`;
1153
1154
  for (let C = 0; C < A.length; ++C) {
1154
- if (Z(A[C], t), O.startsWith("$")) {
1155
- const b = O.slice(1);
1156
- o += pt(b, l, d, U);
1155
+ if (Z(A[C], t), N.startsWith("$")) {
1156
+ const b = N.slice(1);
1157
+ o += ut(b, l, d, U);
1157
1158
  continue;
1158
1159
  }
1159
1160
  const y = B === void 0 ? " " : " ";
1160
1161
  o += `${y}${k}
1161
- ${y}export type ${O}${p} =${v}${g};
1162
- ${y}export const ${O}: typeof${v}${u};
1162
+ ${y}export type ${N}${p} =${v}${g};
1163
+ ${y}export const ${N}: typeof${v}${u};
1163
1164
 
1164
1165
  `;
1165
1166
  }
@@ -1191,7 +1192,7 @@ function ye(e, t, i, o) {
1191
1192
  let n = "";
1192
1193
  for (let l = 0; l < A.length; ++l) {
1193
1194
  Z(A[l], o);
1194
- const c = ot(O, a, void 0, r);
1195
+ const c = ot(N, a, void 0, r);
1195
1196
  B === void 0 ? n += ` ${k}
1196
1197
  ${c}
1197
1198
  ` : q += ` ${k}
@@ -1246,12 +1247,12 @@ function K(e, t, i) {
1246
1247
  const ie = [];
1247
1248
  let A = ie;
1248
1249
  function he(e) {
1249
- e.kind === "variable" ? A = _e(e).esriCompatibilityNames ?? ie : e.kind === "function" ? A = Ke(e).esriCompatibilityNames ?? ie : A = me(e).esriCompatibilityNames ?? ie;
1250
+ e.kind === "variable" ? A = _e(e).esriCompatibilityNames ?? ie : e.kind === "function" ? A = Ke(e).esriCompatibilityNames ?? ie : A = fe(e).esriCompatibilityNames ?? ie;
1250
1251
  }
1251
1252
  function Z(e, t) {
1252
1253
  const i = e.indexOf(".");
1253
1254
  if (i !== -1) {
1254
- B = e.slice(0, i), D = void 0, O = e.slice(i + 1), j === void 0 ? j = B : j !== B && t.emitError(
1255
+ B = e.slice(0, i), D = void 0, N = e.slice(i + 1), j === void 0 ? j = B : j !== B && t.emitError(
1255
1256
  `Invalid @esriCompatibilityName usage: Multiple different namespaces in a single file are not supported. Found ${j} and ${B}`,
1256
1257
  {
1257
1258
  file: void 0,
@@ -1263,7 +1264,7 @@ function Z(e, t) {
1263
1264
  }
1264
1265
  const o = e.indexOf("#");
1265
1266
  if (o !== -1) {
1266
- B = void 0, D = e.slice(0, o), O = e.slice(o + 1), W === void 0 ? W = D : W !== D && t.emitError(
1267
+ B = void 0, D = e.slice(0, o), N = e.slice(o + 1), W === void 0 ? W = D : W !== D && t.emitError(
1267
1268
  `Invalid @esriCompatibilityName usage: Multiple different __esri interfaces in a single file are not supported. Found ${W} and ${D}`,
1268
1269
  {
1269
1270
  file: void 0,
@@ -1273,11 +1274,11 @@ function Z(e, t) {
1273
1274
  );
1274
1275
  return;
1275
1276
  }
1276
- B = void 0, D = void 0, O = e;
1277
+ B = void 0, D = void 0, N = e;
1277
1278
  }
1278
- function pt(e, t, i, o) {
1279
- const s = ut(e, t.events), r = `${// IdentityManager fake class got renamed to IdentityManagerBase real class
1280
- t.name.startsWith(A[0]) ? A[0] : t.name}${Ze(e)}Event`, n = yt(s, o) ?? ` = import("./${o}.js").${i}["@eventTypes"]["${e}"]`, l = n.startsWith("<") ? n.indexOf(">") + 1 : -1, c = l !== -1 ? n.slice(0, l) : "";
1279
+ function ut(e, t, i, o) {
1280
+ const s = yt(e, t.events), r = `${// IdentityManager fake class got renamed to IdentityManagerBase real class
1281
+ t.name.startsWith(A[0]) ? A[0] : t.name}${Ze(e)}Event`, n = ht(s, o) ?? ` = import("./${o}.js").${i}["@eventTypes"]["${e}"]`, l = n.startsWith("<") ? n.indexOf(">") + 1 : -1, c = l !== -1 ? n.slice(0, l) : "";
1281
1282
  return ` ${k}
1282
1283
  export type ${r}${n};
1283
1284
  ${k}
@@ -1285,7 +1286,7 @@ function pt(e, t, i, o) {
1285
1286
 
1286
1287
  `;
1287
1288
  }
1288
- function ut(e, t) {
1289
+ function yt(e, t) {
1289
1290
  if (t !== void 0)
1290
1291
  for (let i = 0; i < t.length; ++i) {
1291
1292
  const o = t[i];
@@ -1293,7 +1294,7 @@ function ut(e, t) {
1293
1294
  return o;
1294
1295
  }
1295
1296
  }
1296
- function yt(e, t) {
1297
+ function ht(e, t) {
1297
1298
  const i = e?.type;
1298
1299
  if (t = e?.inheritedFrom?.module ?? t, i?.references?.length === 1) {
1299
1300
  const a = i.references[0];
@@ -1306,16 +1307,16 @@ function yt(e, t) {
1306
1307
  if (!(o.package !== void 0 || s.package !== void 0 || s.module !== void 0 || s.viewUrl !== void 0) && i.text === `${o.name}<${s.name}>`)
1307
1308
  return t = o.module ?? t, `<${s.name}> = import("./${t}.js").${o.name}<${s.name}>`;
1308
1309
  }
1309
- function ht(e, t) {
1310
- let i = dt;
1310
+ function gt(e, t) {
1311
+ let i = ft;
1311
1312
  for (let o = 0; o < e.length; ++o) {
1312
1313
  const s = e[o];
1313
- i += ft(s, t);
1314
+ i += pt(s, t);
1314
1315
  }
1315
1316
  return i + mt;
1316
1317
  }
1317
- function gt(e, t, i) {
1318
- let o = "";
1318
+ function vt(e, t, i) {
1319
+ let o = Ct(t.file);
1319
1320
  const s = t.importsMap, a = /* @__PURE__ */ Object.create(null);
1320
1321
  for (const r in s) {
1321
1322
  const n = s[r];
@@ -1338,12 +1339,12 @@ function gt(e, t, i) {
1338
1339
  const c = n.replacementName ?? r;
1339
1340
  if (n.type === "named") {
1340
1341
  if (n.modulePath !== void 0) {
1341
- const m = n.actualName ?? c, p = i.moduleMap.get(n.modulePath), g = p === void 0 ? void 0 : h(p);
1342
- if (g?.index.named[m] === void 0) {
1342
+ const f = n.actualName ?? c, p = i.moduleMap.get(n.modulePath), g = p === void 0 ? void 0 : h(p);
1343
+ if (g?.index.named[f] === void 0) {
1343
1344
  if (i.privateMixinModuleNames.has(n.modulePath))
1344
1345
  continue;
1345
1346
  i.emitError(
1346
- `The ${x("red", m)} imported from ${x("red", p?.sourcePath ?? n.modulePath)} is not @public but used in the type of a @public declaration. Add /** @public */ JSDoc, refactor out the usage, or ensure ${x("red", m)} is not a re-export, not a namespace, and not an enum.`,
1347
+ `The ${x("red", f)} imported from ${x("red", p?.sourcePath ?? n.modulePath)} is not @public but used in the type of a @public declaration. Add /** @public */ JSDoc, refactor out the usage, or ensure ${x("red", f)} is not a re-export, not a namespace, and not an enum.`,
1347
1348
  {
1348
1349
  file: t.file,
1349
1350
  node: void 0
@@ -1352,18 +1353,18 @@ function gt(e, t, i) {
1352
1353
  } else
1353
1354
  l = re(t.dtsPath, g.dtsPath);
1354
1355
  }
1355
- const d = a[l], f = n.actualName === void 0 ? c : `${n.actualName} as ${c}`;
1356
- a[l] = d === void 0 ? f : `${d}, ${f}`;
1356
+ const d = a[l], m = n.actualName === void 0 ? c : `${n.actualName} as ${c}`;
1357
+ a[l] = d === void 0 ? m : `${d}, ${m}`;
1357
1358
  } else if (n.type === "default") {
1358
1359
  if (n.modulePath !== void 0) {
1359
- const d = i.moduleMap.get(n.modulePath), f = d === void 0 ? void 0 : h(d);
1360
- f?.index.default === void 0 ? i.emitError(
1360
+ const d = i.moduleMap.get(n.modulePath), m = d === void 0 ? void 0 : h(d);
1361
+ m?.index.default === void 0 ? i.emitError(
1361
1362
  `The default exported declaration in ${x("red", d?.sourcePath ?? n.modulePath)} is not @public but used in the type of a @public declaration. Add /** @public */ JSDoc or refactor out the usage.`,
1362
1363
  {
1363
1364
  file: t.file,
1364
1365
  node: void 0
1365
1366
  }
1366
- ) : l = re(t.dtsPath, f.dtsPath);
1367
+ ) : l = re(t.dtsPath, m.dtsPath);
1367
1368
  }
1368
1369
  o += `import type ${c} from "${l}";
1369
1370
  `;
@@ -1383,8 +1384,8 @@ ${o}` : o += `import type * as ${c} from "${l}";
1383
1384
  `;
1384
1385
  }
1385
1386
  if (n.modulePath !== void 0 && i.watchFiles !== void 0) {
1386
- const d = i.moduleMap.get(n.modulePath), m = (d === void 0 ? void 0 : h(d))?.file.fileName.slice(i.config.context.cwd.length);
1387
- m !== void 0 && (i.watchFiles.get(e.sourcePath).dependencies.add(m), i.watchFiles.get(m).dependents.set(e.sourcePath, !0));
1387
+ const d = i.moduleMap.get(n.modulePath), f = (d === void 0 ? void 0 : h(d))?.file.fileName.slice(i.config.context.cwd.length);
1388
+ f !== void 0 && (i.watchFiles.get(e.sourcePath).dependencies.add(f), i.watchFiles.get(f).dependents.set(e.sourcePath, !0));
1388
1389
  }
1389
1390
  }
1390
1391
  if (i.produceDts) {
@@ -1396,7 +1397,26 @@ ${o}` : o += `import type * as ${c} from "${l}";
1396
1397
  t.importsText = o;
1397
1398
  }
1398
1399
  }
1399
- function vt(e, t, i, o) {
1400
+ function Ct(e) {
1401
+ let t = "";
1402
+ for (let i = 0; i < e.libReferenceDirectives.length; ++i) {
1403
+ const o = e.libReferenceDirectives[i];
1404
+ o.preserve === !0 && (t += `/// <reference lib="${o.fileName}" preserve="true" />
1405
+ `);
1406
+ }
1407
+ for (let i = 0; i < e.typeReferenceDirectives.length; ++i) {
1408
+ const o = e.typeReferenceDirectives[i];
1409
+ o.preserve === !0 && (t += `/// <reference types="${o.fileName}" preserve="true" />
1410
+ `);
1411
+ }
1412
+ for (let i = 0; i < e.referencedFiles.length; ++i) {
1413
+ const o = e.referencedFiles[i];
1414
+ o.preserve === !0 && (t += `/// <reference path="${nt(o.fileName)}.d.ts" preserve="true" />
1415
+ `);
1416
+ }
1417
+ return t;
1418
+ }
1419
+ function Mt(e, t, i, o) {
1400
1420
  const s = e.references;
1401
1421
  if (s !== void 0) {
1402
1422
  if (t.autoCastingRequiresType === void 0 && s.length > 1 && s[0].module === "core/Collection")
@@ -1413,11 +1433,11 @@ function Ee(e, t, i, o, s) {
1413
1433
  for (let a = s.length - 1; a >= 0; a--) {
1414
1434
  const r = s[a];
1415
1435
  if (r.package !== void 0) {
1416
- r.package === fe && r.name === "Date" && ge(
1436
+ r.package === me && r.name === "Date" && ge(
1417
1437
  e,
1418
1438
  s,
1419
1439
  a,
1420
- { type: bt, inheritedFrom: void 0 },
1440
+ { type: Pt, inheritedFrom: void 0 },
1421
1441
  i,
1422
1442
  o,
1423
1443
  t
@@ -1426,8 +1446,8 @@ function Ee(e, t, i, o, s) {
1426
1446
  }
1427
1447
  const n = r.module === void 0 ? o : i.moduleMap.get(r.module), l = n === void 0 ? void 0 : h(n), c = r.name === "default" ? l?.index.default : l?.index.named[r.name];
1428
1448
  if (Fe(c)) {
1429
- const f = `(${c.type.text})`, m = e.text;
1430
- e.text = `${e.text.slice(0, r.start)}${f}${e.text.slice(r.end)}`;
1449
+ const m = `(${c.type.text})`, f = e.text;
1450
+ e.text = `${e.text.slice(0, r.start)}${m}${e.text.slice(r.end)}`;
1431
1451
  const p = e.text, g = r.start + 1, u = [];
1432
1452
  for (let C = 0; C < c.type.references.length; ++C) {
1433
1453
  const y = c.type.references[C], b = y.module ?? n?.path, M = b === o.path;
@@ -1439,11 +1459,11 @@ function Ee(e, t, i, o, s) {
1439
1459
  });
1440
1460
  }
1441
1461
  if (Ee(e, t, i, o, u), e.text === p) {
1442
- e.text = m;
1462
+ e.text = f;
1443
1463
  continue;
1444
1464
  }
1445
1465
  s.splice(a, 1, ...u);
1446
- const v = e.text.length - m.length;
1466
+ const v = e.text.length - f.length;
1447
1467
  xe(s, v, a + u.length);
1448
1468
  continue;
1449
1469
  }
@@ -1475,10 +1495,10 @@ function Te(e, t, i, o) {
1475
1495
  const s = h(t), a = s.constructorAutoCastType;
1476
1496
  if (a !== void 0)
1477
1497
  return a;
1478
- const r = Ct(e, t, i, o);
1498
+ const r = bt(e, t, i, o);
1479
1499
  return r !== void 0 && (s.constructorAutoCastType = r), r;
1480
1500
  }
1481
- function Ct(e, t, i, o) {
1501
+ function bt(e, t, i, o) {
1482
1502
  if (e.members !== void 0)
1483
1503
  for (let r = 0; r < e.members.length; ++r) {
1484
1504
  const n = e.members[r];
@@ -1524,8 +1544,8 @@ function ge(e, t, i, { type: o, inheritedFrom: s }, a, r, n) {
1524
1544
  references: l
1525
1545
  });
1526
1546
  let c = o.text;
1527
- const d = t[i], f = o.text.length - (d.end - d.start);
1528
- let m = 0;
1547
+ const d = t[i], m = o.text.length - (d.end - d.start);
1548
+ let f = 0;
1529
1549
  t.splice(i, 1);
1530
1550
  for (let p = l.length - 1; p >= 0; p--) {
1531
1551
  const g = l[p], u = o.text.slice(g.start, g.end);
@@ -1553,25 +1573,25 @@ function ge(e, t, i, { type: o, inheritedFrom: s }, a, r, n) {
1553
1573
  $e(g, C, a, r);
1554
1574
  const M = d.start, I = {
1555
1575
  ...g,
1556
- start: g.start + M + m,
1557
- end: g.end + M + m
1576
+ start: g.start + M + f,
1577
+ end: g.end + M + f
1558
1578
  }, P = y.typeName;
1559
1579
  if (l.length === 1 && n.autoCastingRequiresType === !0 && P !== void 0) {
1560
1580
  const L = n.autoCastingDefaultType === P, S = `(${u} & { type${L ? "?" : ""}: "${P}" })`, F = S.length - u.length;
1561
- m += F, I.end += F, c = c.slice(0, g.start) + S + c.slice(g.end);
1581
+ f += F, I.end += F, c = c.slice(0, g.start) + S + c.slice(g.end);
1562
1582
  }
1563
1583
  t.splice(i, 0, I);
1564
1584
  }
1565
1585
  return e.text = e.text.slice(0, d.start) + c + e.text.slice(d.end), xe(
1566
1586
  t,
1567
- f + m,
1587
+ m + f,
1568
1588
  i + (l?.length ?? 0)
1569
1589
  ), !0;
1570
1590
  }
1571
1591
  function $e(e, t, i, o) {
1572
1592
  const s = h(o);
1573
1593
  if (e.package !== void 0) {
1574
- if (e.package === fe)
1594
+ if (e.package === me)
1575
1595
  return;
1576
1596
  i.emitError(
1577
1597
  `Unsupported case: cannot yet handle auto-adding imports for external packages. Tried to add ${e.name} from ${e.package} when resolving auto-casting type.`,
@@ -1614,9 +1634,9 @@ function $e(e, t, i, o) {
1614
1634
  ) : d.wasUsed = !0;
1615
1635
  }
1616
1636
  function Fe(e) {
1617
- return e?.kind === "interface" && e.members === void 0 && e.supertypes === void 0 && e.type?.references !== void 0 && e.type.references.length > 1 && e.typeParameters === void 0 && Mt(e.type);
1637
+ return e?.kind === "interface" && e.members === void 0 && e.supertypes === void 0 && e.type?.references !== void 0 && e.type.references.length > 1 && e.typeParameters === void 0 && xt(e.type);
1618
1638
  }
1619
- function Mt(e) {
1639
+ function xt(e) {
1620
1640
  let t = 0;
1621
1641
  for (let i = 0; i < e.references.length; ++i) {
1622
1642
  const o = e.references[i], s = e.text.slice(t, o.start).trim();
@@ -1626,14 +1646,14 @@ function Mt(e) {
1626
1646
  }
1627
1647
  return t === e.text.length;
1628
1648
  }
1629
- const bt = {
1649
+ const Pt = {
1630
1650
  // Wrap in parents to correctly substitute Date[] in TimeInfo.stops
1631
1651
  text: "(Date | number | string)",
1632
1652
  references: [
1633
1653
  {
1634
1654
  name: "Date",
1635
1655
  module: void 0,
1636
- package: fe,
1656
+ package: me,
1637
1657
  viewUrl: "https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Date",
1638
1658
  start: 1,
1639
1659
  end: 5
@@ -1642,7 +1662,7 @@ const bt = {
1642
1662
  values: void 0,
1643
1663
  source: void 0
1644
1664
  };
1645
- function xt(e, t) {
1665
+ function It(e, t) {
1646
1666
  const i = e.constructorPropertiesInterface;
1647
1667
  i.type = void 0;
1648
1668
  const o = h(t.apiModule).index.class;
@@ -1685,27 +1705,27 @@ function xt(e, t) {
1685
1705
  isConstructorOnly: void 0,
1686
1706
  isOverride: void 0,
1687
1707
  dtsTypeOverride: void 0
1688
- }, f = n, m = {
1708
+ }, m = n, f = {
1689
1709
  [ne]: d,
1690
1710
  kind: "field",
1691
- name: f.name,
1711
+ name: m.name,
1692
1712
  static: void 0,
1693
- deprecated: f.deprecated,
1713
+ deprecated: m.deprecated,
1694
1714
  summary: void 0,
1695
- description: f.description,
1696
- docsTags: f.docsTags,
1715
+ description: m.description,
1716
+ docsTags: m.docsTags,
1697
1717
  type: c,
1698
1718
  getterType: void 0,
1699
- default: f.default,
1719
+ default: m.default,
1700
1720
  readonly: void 0,
1701
1721
  inheritedFrom: void 0,
1702
- privacy: f.privacy,
1722
+ privacy: m.privacy,
1703
1723
  source: void 0,
1704
1724
  attribute: void 0,
1705
1725
  reflects: void 0,
1706
1726
  docsOnlyReadonly: void 0
1707
1727
  };
1708
- i.members ??= [], i.members.push(m);
1728
+ i.members ??= [], i.members.push(f);
1709
1729
  }
1710
1730
  if (a.length > 0) {
1711
1731
  i.supertypes ??= [];
@@ -1755,7 +1775,7 @@ function ve(e, t) {
1755
1775
  * views/3d/environment/SunLighting as it imports webscene/SunLighting.
1756
1776
  * apiReference.name !== class.name for references to mixin base classes.
1757
1777
  */
1758
- [ne]: a === e.name ? void 0 : Pt(a, o.index.class.name),
1778
+ [ne]: a === e.name ? void 0 : St(a, o.index.class.name),
1759
1779
  name: s.name,
1760
1780
  module: e.module,
1761
1781
  package: e.package,
@@ -1764,14 +1784,14 @@ function ve(e, t) {
1764
1784
  };
1765
1785
  return $e(r, i, t, t.apiModule), r[ne] ??= s.name, r;
1766
1786
  }
1767
- function Pt(e, t) {
1787
+ function St(e, t) {
1768
1788
  if (e === void 0 || e === t)
1769
1789
  return;
1770
1790
  const i = e.indexOf("<");
1771
1791
  if (e = i === -1 ? e : e.slice(0, i), e !== t)
1772
1792
  return `${e}Properties`;
1773
1793
  }
1774
- function It(e) {
1794
+ function kt(e) {
1775
1795
  if (e.customElement === void 0)
1776
1796
  return;
1777
1797
  const t = e, i = [];
@@ -1812,9 +1832,9 @@ const de = {
1812
1832
  */
1813
1833
  deferred: 1
1814
1834
  };
1815
- function St(e, t, i, o) {
1835
+ function Et(e, t, i, o) {
1816
1836
  const s = e;
1817
- o.produceDts && (me(t).eventTypesProperty = s);
1837
+ o.produceDts && (fe(t).eventTypesProperty = s);
1818
1838
  const a = h(i), r = `${t.name}Events`;
1819
1839
  if (s.type.text !== r && !s.type.text.startsWith(`${r}<`)) {
1820
1840
  if (s.type.text === "unknown")
@@ -1908,14 +1928,14 @@ function we(e, t, i) {
1908
1928
  o.inheritance = de.deferred;
1909
1929
  let a = !1;
1910
1930
  if (t.members !== void 0)
1911
- for (let f = 0; f < t.members.length; ++f) {
1912
- const m = t.members[f];
1913
- if (m.kind === "field") {
1914
- if (m.name === "@eventTypes") {
1915
- a = !0, St(m, t, e, i), t.members.splice(f, 1), f -= 1;
1931
+ for (let m = 0; m < t.members.length; ++m) {
1932
+ const f = t.members[m];
1933
+ if (f.kind === "field") {
1934
+ if (f.name === "@eventTypes") {
1935
+ a = !0, Et(f, t, e, i), t.members.splice(m, 1), m -= 1;
1916
1936
  continue;
1917
1937
  }
1918
- m.inheritedFrom === void 0 && Et(m, e, i);
1938
+ f.inheritedFrom === void 0 && $t(f, e, i);
1919
1939
  }
1920
1940
  }
1921
1941
  const r = t;
@@ -1923,30 +1943,30 @@ function we(e, t, i) {
1923
1943
  if (c?.supertypes !== void 0) {
1924
1944
  n = n === void 0 ? [] : [...n];
1925
1945
  do {
1926
- const f = c.supertypes.length > 1, m = f ? 1 : 0;
1927
- for (let p = c.supertypes.length - 1; p >= m; p--) {
1946
+ const m = c.supertypes.length > 1, f = m ? 1 : 0;
1947
+ for (let p = c.supertypes.length - 1; p >= f; p--) {
1928
1948
  const g = c.supertypes[p], u = g.module === void 0 ? { ...g, module: l.module } : g;
1929
1949
  n.unshift(u);
1930
1950
  }
1931
- l = f ? c.supertypes[0] : void 0, c = l === void 0 ? void 0 : be(l, e, i);
1951
+ l = m ? c.supertypes[0] : void 0, c = l === void 0 ? void 0 : be(l, e, i);
1932
1952
  } while (c?.supertypes !== void 0);
1933
1953
  }
1934
1954
  if (n !== void 0) {
1935
- const f = n.length - (t.mixins?.length ?? 0);
1936
- for (let m = n.length - 1; m >= 0; m--) {
1937
- const p = n[m], g = Me(p.module ?? e.path, !0, i);
1938
- typeof g == "object" ? Ce(g, t, a, i) : m >= f && (t.mixins.splice(m - f, 1), t.mixins.length === 0 && (t.mixins = void 0));
1955
+ const m = n.length - (t.mixins?.length ?? 0);
1956
+ for (let f = n.length - 1; f >= 0; f--) {
1957
+ const p = n[f], g = Me(p.module ?? e.path, !0, i);
1958
+ typeof g == "object" ? Ce(g, t, a, i) : f >= m && (t.mixins.splice(f - m, 1), t.mixins.length === 0 && (t.mixins = void 0));
1939
1959
  }
1940
1960
  }
1941
1961
  if (l?.package !== void 0)
1942
1962
  return;
1943
1963
  const d = l?.module;
1944
1964
  if (d !== void 0) {
1945
- const f = Me(d, !1, i);
1946
- typeof f == "object" && (f.declaration.privacy !== void 0 && t.privacy === void 0 && i.emitError(
1947
- `Public component may only subclass a public component to avoid broken inheritance. Tried to inherit from private ${f.declaration.name}. Remove @private from it but feel free to add a jsdoc description stating the base class is abstract - not for direct consumption. Lumina does bare minimum extraction work for private components, which makes them ineligible for public docs.`,
1965
+ const m = Me(d, !1, i);
1966
+ typeof m == "object" && (m.declaration.privacy !== void 0 && t.privacy === void 0 && i.emitError(
1967
+ `Public component may only subclass a public component to avoid broken inheritance. Tried to inherit from private ${m.declaration.name}. Remove @private from it but feel free to add a jsdoc description stating the base class is abstract - not for direct consumption. Lumina does bare minimum extraction work for private components, which makes them ineligible for public docs.`,
1948
1968
  { file: o.file, node: void 0 }
1949
- ), Ce(f, t, a, i));
1969
+ ), Ce(m, t, a, i));
1950
1970
  }
1951
1971
  }
1952
1972
  function Ce(e, t, i, o) {
@@ -1956,22 +1976,22 @@ function Ce(e, t, i, o) {
1956
1976
  const r = t.members, n = o.config.documentation.noInheritMembers[e.inheritanceData.module];
1957
1977
  let l = n === void 0 ? void 0 : new Set(n);
1958
1978
  for (let d = 0; d < r.length; ++d) {
1959
- const f = r[d], m = ce(f), p = e.indexedMembers[m];
1979
+ const m = r[d], f = ce(m), p = e.indexedMembers[f];
1960
1980
  if (p === void 0)
1961
1981
  continue;
1962
- if (l ??= /* @__PURE__ */ new Set(), l.add(m), f.kind === "field") {
1963
- const u = oe(f);
1982
+ if (l ??= /* @__PURE__ */ new Set(), l.add(f), m.kind === "field") {
1983
+ const u = oe(m);
1964
1984
  oe(p).isAccessor === !0 && (u.isAccessor = !0), u.isOverride = !0;
1965
1985
  }
1966
- p !== void 0 && f.inheritedFrom === void 0 && Se(p, f);
1986
+ p !== void 0 && m.inheritedFrom === void 0 && Se(p, m);
1967
1987
  }
1968
1988
  const c = s.members;
1969
1989
  for (let d = 0; d < c.length; ++d) {
1970
- const f = c[d];
1990
+ const m = c[d];
1971
1991
  // Most classes don't override any public members, so don't even check
1972
1992
  // for this if no members were overridden.
1973
- (l?.has(ce(f)) ?? !1) || t.members.push(
1974
- f.inheritedFrom === void 0 ? { ...f, inheritedFrom: e.inheritanceData } : f
1993
+ (l?.has(ce(m)) ?? !1) || t.members.push(
1994
+ m.inheritedFrom === void 0 ? { ...m, inheritedFrom: e.inheritanceData } : m
1975
1995
  );
1976
1996
  }
1977
1997
  }
@@ -2018,7 +2038,7 @@ function X(e = [], t, i, o) {
2018
2038
  return e;
2019
2039
  }
2020
2040
  function Me(e, t, i) {
2021
- const o = i.moduleMap.get(e), s = kt(o, e, t, i), a = o === void 0 ? void 0 : h(o);
2041
+ const o = i.moduleMap.get(e), s = Tt(o, e, t, i), a = o === void 0 ? void 0 : h(o);
2022
2042
  if (s === !1 || o === void 0)
2023
2043
  return a !== void 0 ? a.inheritance = de.skip : t && i.privateMixinModuleNames.add(e), de.skip;
2024
2044
  const [r, n] = s, l = n;
@@ -2026,12 +2046,12 @@ function Me(e, t, i) {
2026
2046
  let c, d = !1;
2027
2047
  if (n.members !== void 0) {
2028
2048
  c = /* @__PURE__ */ Object.create(null);
2029
- for (let m = 0; m < n.members.length; ++m) {
2030
- const p = n.members[m], g = ce(p), v = c[g] !== void 0;
2049
+ for (let f = 0; f < n.members.length; ++f) {
2050
+ const p = n.members[f], g = ce(p), v = c[g] !== void 0;
2031
2051
  c[g] = v ? void 0 : p, d ||= p.kind === "field" && p.readonly === void 0;
2032
2052
  }
2033
2053
  }
2034
- const f = {
2054
+ const m = {
2035
2055
  inheritanceData: {
2036
2056
  name: n.name,
2037
2057
  module: r,
@@ -2048,7 +2068,7 @@ function Me(e, t, i) {
2048
2068
  indexedCssProperties: Y(l.cssProperties),
2049
2069
  indexedCssStates: Y(l.cssStates)
2050
2070
  };
2051
- return a.inheritance = f, f;
2071
+ return a.inheritance = m, m;
2052
2072
  }
2053
2073
  function Y(e) {
2054
2074
  if (e === void 0)
@@ -2060,7 +2080,7 @@ function Y(e) {
2060
2080
  }
2061
2081
  return t;
2062
2082
  }
2063
- function kt(e, t, i, o) {
2083
+ function Tt(e, t, i, o) {
2064
2084
  const s = e === void 0 ? void 0 : h(e), a = s?.index.class;
2065
2085
  return a === void 0 ? (i || o.emitError(
2066
2086
  `Failed to find @public class/custom element declaration in ${x("red", t)}. Referenced in the extends clause by ${x("blue", o.apiModule.sourcePath)}`,
@@ -2088,11 +2108,11 @@ function be(e, t, i) {
2088
2108
  }
2089
2109
  return a.kind === "interface" ? a : void 0;
2090
2110
  }
2091
- function Et(e, t, i) {
2111
+ function $t(e, t, i) {
2092
2112
  const o = oe(e), s = h(t);
2093
- o.hasAutoCasting === !0 && (vt(e.type, o, t, i), o.isConstructorOnly !== !0 && e.getterType?.text === e.type.text && (e.getterType = void 0)), o.isConstructorOnly === !0 && (s.constructorOnlySetters ??= {}, s.constructorOnlySetters[e.name] = e.type, e.type = e.getterType ?? e.type, e.getterType = void 0, e.readonly = !0);
2113
+ o.hasAutoCasting === !0 && (Mt(e.type, o, t, i), o.isConstructorOnly !== !0 && e.getterType?.text === e.type.text && (e.getterType = void 0)), o.isConstructorOnly === !0 && (s.constructorOnlySetters ??= {}, s.constructorOnlySetters[e.name] = e.type, e.type = e.getterType ?? e.type, e.getterType = void 0, e.readonly = !0);
2094
2114
  }
2095
- function Tt(e, t, i) {
2115
+ function Ft(e, t, i) {
2096
2116
  if (!(i.watchFiles === void 0 || t.reExports === void 0))
2097
2117
  for (let o = 0; o < t.reExports.length; ++o) {
2098
2118
  const s = t.reExports[o];
@@ -2102,10 +2122,10 @@ function Tt(e, t, i) {
2102
2122
  n !== void 0 && (i.watchFiles.get(e.sourcePath).dependencies.add(n), i.watchFiles.get(n).dependents.set(e.sourcePath, !0));
2103
2123
  }
2104
2124
  }
2105
- function $t(e, t) {
2106
- e.sort(et), Ft(e, t), t.isComponentProject && Le(e, t);
2125
+ function At(e, t) {
2126
+ e.sort(et), wt(e, t), t.isComponentProject && Le(e, t);
2107
2127
  }
2108
- function Ft(e, t) {
2128
+ function wt(e, t) {
2109
2129
  for (let i = 0; i < e.length; ++i) {
2110
2130
  const o = e[i];
2111
2131
  if (!h(o).isStale)
@@ -2137,29 +2157,29 @@ function Ft(e, t) {
2137
2157
  }
2138
2158
  continue;
2139
2159
  }
2140
- t.apiModule = o, t.inheritedModuleName = void 0, o.deprecated = Q(o.deprecated, t), o.description = R(o.description, t), V(o.docsTags, t);
2160
+ t.apiModule = o, t.inheritedModuleName = void 0, o.deprecated = Q(o.deprecated, t), o.description = G(o.description, t), V(o.docsTags, t);
2141
2161
  for (let a = 0; a < o.declarations.length; ++a) {
2142
2162
  const r = o.declarations[a];
2143
- if (r.deprecated = Q(r.deprecated, t), r.description = R(r.description, t), V(r.docsTags, t), r.kind === "function") {
2163
+ if (r.deprecated = Q(r.deprecated, t), r.description = G(r.description, t), V(r.docsTags, t), r.kind === "function") {
2144
2164
  if (r.parameters !== void 0)
2145
2165
  for (let l = 0; l < r.parameters.length; ++l) {
2146
2166
  const c = r.parameters[l];
2147
- c.description = R(c.description, t), V(c.docsTags, t);
2167
+ c.description = G(c.description, t), V(c.docsTags, t);
2148
2168
  }
2149
- r.return !== void 0 && (r.return.description = R(r.return.description, t));
2169
+ r.return !== void 0 && (r.return.description = G(r.return.description, t));
2150
2170
  }
2151
2171
  const n = r;
2152
2172
  if (n.members !== void 0) {
2153
2173
  for (let c = 0; c < n.members.length; ++c) {
2154
- const d = n.members[c], f = d.inheritedFrom, m = f !== void 0;
2155
- if (t.inheritedModuleName = f?.module, d.deprecated = Q(d.deprecated, t), d.description = R(d.description, t), V(d.docsTags, t), !m && d.kind !== "field") {
2174
+ const d = n.members[c], m = d.inheritedFrom, f = m !== void 0;
2175
+ if (t.inheritedModuleName = m?.module, d.deprecated = Q(d.deprecated, t), d.description = G(d.description, t), V(d.docsTags, t), !f && d.kind !== "field") {
2156
2176
  if (d.parameters !== void 0)
2157
2177
  for (let g = 0; g < d.parameters.length; ++g) {
2158
2178
  const u = d.parameters[g];
2159
- u.description = R(u.description, t), V(u.docsTags, t);
2179
+ u.description = G(u.description, t), V(u.docsTags, t);
2160
2180
  }
2161
2181
  const p = d;
2162
- p.return !== void 0 && (p.return.description = R(p.return.description, t));
2182
+ p.return !== void 0 && (p.return.description = G(p.return.description, t));
2163
2183
  }
2164
2184
  t.inheritedModuleName = void 0;
2165
2185
  }
@@ -2168,52 +2188,52 @@ function Ft(e, t) {
2168
2188
  if (l.events !== void 0) {
2169
2189
  for (let c = 0; c < l.events.length; ++c) {
2170
2190
  const d = l.events[c];
2171
- t.inheritedModuleName = d.inheritedFrom?.module, d.deprecated = Q(d.deprecated, t), d.description = R(d.description, t), V(d.docsTags, t);
2191
+ t.inheritedModuleName = d.inheritedFrom?.module, d.deprecated = Q(d.deprecated, t), d.description = G(d.description, t), V(d.docsTags, t);
2172
2192
  }
2173
2193
  t.inheritedModuleName = void 0;
2174
2194
  }
2175
- if (t.config.context.isLuminaMinimalExtraction || It(n), l.slots !== void 0)
2195
+ if (t.config.context.isLuminaMinimalExtraction || kt(n), l.slots !== void 0)
2176
2196
  for (let c = 0; c < l.slots.length; ++c) {
2177
2197
  const d = l.slots[c];
2178
- d.description = R(d.description, t);
2198
+ d.description = G(d.description, t);
2179
2199
  }
2180
2200
  if (l.cssProperties !== void 0)
2181
2201
  for (let c = 0; c < l.cssProperties.length; ++c) {
2182
2202
  const d = l.cssProperties[c];
2183
- d.description = R(d.description, t);
2203
+ d.description = G(d.description, t);
2184
2204
  }
2185
2205
  if (l.cssParts !== void 0)
2186
2206
  for (let c = 0; c < l.cssParts.length; ++c) {
2187
2207
  const d = l.cssParts[c];
2188
- d.description = R(d.description, t);
2208
+ d.description = G(d.description, t);
2189
2209
  }
2190
2210
  if (l.cssStates !== void 0)
2191
2211
  for (let c = 0; c < l.cssStates.length; ++c) {
2192
2212
  const d = l.cssStates[c];
2193
- d.description = R(d.description, t);
2213
+ d.description = G(d.description, t);
2194
2214
  }
2195
2215
  if (l.demos !== void 0)
2196
2216
  for (let c = 0; c < l.demos.length; ++c) {
2197
2217
  const d = l.demos[c];
2198
- d.description = R(d.description, t);
2218
+ d.description = G(d.description, t);
2199
2219
  }
2200
2220
  } else r === s.constructorPropertiesInterface && (o.declarations.splice(a, 1), a -= 1);
2201
2221
  }
2202
- s.constructorPropertiesInterface !== void 0 && xt(s, t), gt(o, s, t), Tt(o, s, t);
2222
+ s.constructorPropertiesInterface !== void 0 && It(s, t), vt(o, s, t), Ft(o, s, t);
2203
2223
  }
2204
2224
  }
2205
- function At(e) {
2206
- const t = [wt];
2225
+ function Rt(e) {
2226
+ const t = [Gt];
2207
2227
  for (let i = 0; i < e.length; ++i) {
2208
2228
  const o = e[i];
2209
- rt(o) && t.push(
2229
+ st(o) && t.push(
2210
2230
  ` "@arcgis/core/${o.path}.js": typeof import("./${o.path}.js")${o.exports === void 0 ? "" : ".default"};
2211
2231
  `
2212
2232
  );
2213
2233
  }
2214
- return t.push(Gt), t.join("");
2234
+ return t.push(Dt), t.join("");
2215
2235
  }
2216
- const wt = `declare global {
2236
+ const Gt = `declare global {
2217
2237
  const $arcgis: ArcgisGlobal;
2218
2238
  }
2219
2239
 
@@ -2233,8 +2253,8 @@ interface ArcgisImport {
2233
2253
  }
2234
2254
 
2235
2255
  export interface ArcgisImportModules {
2236
- `, Gt = `}
2237
- `, Rt = async function() {
2256
+ `, Dt = `}
2257
+ `, Lt = async function() {
2238
2258
  if (this.isRunInProgress)
2239
2259
  throw Error(
2240
2260
  "The ApiExtractor.run() is already in progress, or previous run crashed with unrecoverable error. Await the previous run first or create a new ApiExtractor"
@@ -2244,7 +2264,7 @@ export interface ArcgisImportModules {
2244
2264
  this.watchFiles === void 0 && (this.moduleMap = /* @__PURE__ */ new Map());
2245
2265
  const t = e.context.dtsEmitPath !== "", i = e.context.emptyDtsEmitPath && t ? (
2246
2266
  // This takes 80ms for JSAPI
2247
- Oe(e.context.dtsEmitPath)
2267
+ Ne(e.context.dtsEmitPath)
2248
2268
  ) : void 0;
2249
2269
  if (e.types.typeCheckedExtraction || e.types.fullTypeCheck) {
2250
2270
  const n = _(), l = e.types.typeScriptConfig;
@@ -2257,10 +2277,10 @@ export interface ArcgisImportModules {
2257
2277
  });
2258
2278
  this.program = d, e.types.typeScriptInstanceCreated(d, c);
2259
2279
  }
2260
- Ge(this, n);
2280
+ Re(this, n);
2261
2281
  }
2262
- const o = _(), s = await Ne(this);
2263
- $t(s, this);
2282
+ const o = _(), s = await Oe(this);
2283
+ At(s, this);
2264
2284
  const a = this.wrapApiModules(s);
2265
2285
  e.context.logger.info(
2266
2286
  `${H}Extracted ${s.length} @public files in ${x("green", `${o()}s`)}`
@@ -2269,17 +2289,17 @@ export interface ArcgisImportModules {
2269
2289
  if (e.afterApiJsonCreate !== ke && e.afterApiJsonCreate(r), this.produceDts) {
2270
2290
  const n = _(), l = this.dtsFiles;
2271
2291
  if (this.dtsFiles = /* @__PURE__ */ new Map(), this.isJsApi) {
2272
- const c = ht(s, this), d = `${e.context.dtsEmitPath}interfaces.d.ts`;
2292
+ const c = gt(s, this), d = `${e.context.dtsEmitPath}interfaces.d.ts`;
2273
2293
  this.dtsFiles.set(d, c);
2274
- const f = At(s), m = `${e.context.dtsEmitPath}arcgisGlobal.d.ts`;
2275
- this.dtsFiles.set(m, f);
2294
+ const m = Rt(s), f = `${e.context.dtsEmitPath}arcgisGlobal.d.ts`;
2295
+ this.dtsFiles.set(f, m);
2276
2296
  } else this.isComponentProject && Be(s, this);
2277
2297
  for (let c = 0; c < s.length; ++c) {
2278
- const d = s[c], f = h(d);
2279
- let m = `${e.context.dtsEmitPath + f.dtsPath}.d.ts`, p;
2280
- if (f.isStale) {
2298
+ const d = s[c], m = h(d);
2299
+ let f = `${e.context.dtsEmitPath + m.dtsPath}.d.ts`, p;
2300
+ if (m.isStale) {
2281
2301
  if (p = We(d, this), e.types.declarationTextTransformers.length > 0) {
2282
- let v = { filePath: m, content: p };
2302
+ let v = { filePath: f, content: p };
2283
2303
  for (let C = 0; C < e.types.declarationTextTransformers.length; ++C) {
2284
2304
  const y = e.types.declarationTextTransformers[C];
2285
2305
  if (v = y(v, d, this), v === !1)
@@ -2287,49 +2307,49 @@ export interface ArcgisImportModules {
2287
2307
  }
2288
2308
  if (v === !1)
2289
2309
  continue;
2290
- m = v.filePath, p = v.content;
2310
+ f = v.filePath, p = v.content;
2291
2311
  }
2292
2312
  } else
2293
- p = l.get(m);
2313
+ p = l.get(f);
2294
2314
  if (d.exports?.[0].kind === "custom-element-definition" && p.length > 0) {
2295
- const v = `${m.slice(0, -19)}/index.d.ts`;
2315
+ const v = `${f.slice(0, -19)}/index.d.ts`;
2296
2316
  this.dtsFiles.set(v, 'export * from "./customElement.js";');
2297
2317
  }
2298
- this.dtsFiles.set(m, p);
2318
+ this.dtsFiles.set(f, p);
2299
2319
  }
2300
2320
  if (this.changedDtsFiles !== void 0)
2301
2321
  for (const [c, d] of this.dtsFiles)
2302
2322
  l.get(c) !== d && this.changedDtsFiles.set(c, d);
2303
2323
  if (t) {
2304
- await i, await ae(e.context.dtsEmitPath, { recursive: !0 }), await Dt(e.context.dtsEmitPath, !0, this.changedDtsFiles ?? this.dtsFiles);
2305
- const c = N.join(N.relative(process.cwd(), e.context.dtsEmitPath), "/");
2324
+ await i, await ae(e.context.dtsEmitPath, { recursive: !0 }), await Nt(e.context.dtsEmitPath, !0, this.changedDtsFiles ?? this.dtsFiles);
2325
+ const c = O.join(O.relative(process.cwd(), e.context.dtsEmitPath), "/");
2306
2326
  e.context.logger.info(
2307
2327
  `${H}Wrote ${c}**/*${x("blue", ".d.ts")} in ${x("green", `${n()}s`)}`
2308
2328
  );
2309
2329
  }
2310
2330
  }
2311
2331
  if (e.context.apiJsonEmitPath !== "") {
2312
- const n = N.resolve(e.context.cwd, e.context.apiJsonEmitPath), l = N.join(N.relative(process.cwd(), N.dirname(n)), "/");
2313
- await ae(N.dirname(n), { recursive: !0 }), await Pe(
2332
+ const n = O.resolve(e.context.cwd, e.context.apiJsonEmitPath), l = O.join(O.relative(process.cwd(), O.dirname(n)), "/");
2333
+ await ae(O.dirname(n), { recursive: !0 }), await Pe(
2314
2334
  n,
2315
2335
  e.context.environment === "production" ? JSON.stringify(a) : JSON.stringify(a, null, 2)
2316
2336
  ), e.context.logger.info(
2317
- `${H}Wrote ${l}${x("yellow", N.basename(n))}`
2337
+ `${H}Wrote ${l}${x("yellow", O.basename(n))}`
2318
2338
  );
2319
2339
  }
2320
2340
  return this.typeVerifier?.verifyTypes(s), this.errorCount > 0 && e.context.logger.error(
2321
2341
  `${H}${x("red", `Found ${this.errorCount} ${this.errorCount === 1 ? "error" : "errors"}`)}`
2322
2342
  ), this.silencedBrokenLinkCount > 0 && e.context.logger.info(`${H}Silenced ${this.silencedBrokenLinkCount} broken link errors.`), this.isRunInProgress = !1, this.produceDts && (r.dtsFiles = this.dtsFiles), r;
2323
2343
  };
2324
- async function Dt(e, t, i) {
2344
+ async function Nt(e, t, i) {
2325
2345
  const o = /* @__PURE__ */ new Set(), s = Array.from(i.entries());
2326
2346
  for (let l = 0; l < s.length; ++l) {
2327
2347
  const [c, d] = s[l];
2328
2348
  if (d.length === 0)
2329
2349
  continue;
2330
- const f = (t ? c.slice(e.length) : c).split("/");
2331
- for (let m = 1; m < f.length; ++m)
2332
- o.add(f.slice(0, m).join("/"));
2350
+ const m = (t ? c.slice(e.length) : c).split("/");
2351
+ for (let f = 1; f < m.length; ++f)
2352
+ o.add(m.slice(0, f).join("/"));
2333
2353
  }
2334
2354
  const a = new Array(o.size);
2335
2355
  for (const l of o)
@@ -2340,12 +2360,12 @@ async function Dt(e, t, i) {
2340
2360
  const [c, d] = s[l];
2341
2361
  if (d.length === 0)
2342
2362
  continue;
2343
- const f = n + c;
2344
- r[l] = Pe(f, d);
2363
+ const m = n + c;
2364
+ r[l] = Pe(m, d);
2345
2365
  }
2346
2366
  await Promise.all(r);
2347
2367
  }
2348
- function Ge(e, t) {
2368
+ function Re(e, t) {
2349
2369
  if (e.config.types.fullTypeCheck)
2350
2370
  if ("getSemanticDiagnostics" in e.program) {
2351
2371
  const i = e.builderProgram === void 0 ? E.getPreEmitDiagnostics(e.program) : e.builderProgram.getSemanticDiagnostics();
@@ -2358,7 +2378,7 @@ function Ge(e, t) {
2358
2378
  node: void 0
2359
2379
  });
2360
2380
  }
2361
- const Lt = async function() {
2381
+ const Ot = async function() {
2362
2382
  if (this.watchFiles !== void 0)
2363
2383
  throw Error(
2364
2384
  "The ApiExtractor.watch() is already in progress, or previous watch crashed with unrecoverable error. Stop the previous watch first or create a new ApiExtractor"
@@ -2385,7 +2405,7 @@ const Lt = async function() {
2385
2405
  }
2386
2406
  }, n = (u, v, C) => {
2387
2407
  if (v === void 0) {
2388
- const y = e.context.cwd + u, b = lt(y, "utf8");
2408
+ const y = e.context.cwd + u, b = ct(y, "utf8");
2389
2409
  v = He(y, b);
2390
2410
  }
2391
2411
  this.watchFiles.set(u, {
@@ -2401,11 +2421,11 @@ const Lt = async function() {
2401
2421
  });
2402
2422
  };
2403
2423
  let l, c = !0, d;
2404
- f();
2405
- function f() {
2424
+ m();
2425
+ function m() {
2406
2426
  return d === void 0 ? (d = Promise.withResolvers(), e.watch.onUpdate(d.promise), !0) : !1;
2407
2427
  }
2408
- function m(u) {
2428
+ function f(u) {
2409
2429
  d?.resolve(u), d = void 0;
2410
2430
  }
2411
2431
  const p = async () => {
@@ -2414,7 +2434,7 @@ const Lt = async function() {
2414
2434
  try {
2415
2435
  u = await this.run();
2416
2436
  } catch (M) {
2417
- throw m(void 0), M;
2437
+ throw f(void 0), M;
2418
2438
  }
2419
2439
  const v = [], C = [];
2420
2440
  for (const M of this.watchFiles.values()) {
@@ -2445,7 +2465,7 @@ const Lt = async function() {
2445
2465
  };
2446
2466
  o = [];
2447
2467
  const b = c || v.length > 0 || C.length > 0 || y.removedModules.length > 0;
2448
- c = !1, m(b ? y : void 0), l?.();
2468
+ c = !1, f(b ? y : void 0), l?.();
2449
2469
  };
2450
2470
  if (e.types.typeCheckedExtraction || e.types.fullTypeCheck) {
2451
2471
  const u = e.types.fullTypeCheck ? E.createSemanticDiagnosticsBuilderProgram : E.createAbstractBuilder;
@@ -2472,11 +2492,11 @@ const Lt = async function() {
2472
2492
  y.setTimeout = b === void 0 ? void 0 : (S, F, ...T) => {
2473
2493
  if (!(T[0] === "timerToUpdateProgram"))
2474
2494
  return b(S, F, ...T);
2475
- const G = M !== void 0 ? Promise.resolve() : d === void 0 ? Promise.resolve(f()) : d.promise.finally(f);
2495
+ const R = M !== void 0 ? Promise.resolve() : d === void 0 ? Promise.resolve(m()) : d.promise.finally(m);
2476
2496
  return M = b(
2477
2497
  (...J) => {
2478
- M = void 0, G.finally(() => {
2479
- this.program = void 0, S(...J), this.program === void 0 && m(void 0);
2498
+ M = void 0, R.finally(() => {
2499
+ this.program = void 0, S(...J), this.program === void 0 && f(void 0);
2480
2500
  });
2481
2501
  },
2482
2502
  e.watch.debounceTime,
@@ -2496,27 +2516,27 @@ const Lt = async function() {
2496
2516
  $.wasRemoved = !0;
2497
2517
  let w = !1;
2498
2518
  for (let $ = 0; $ < T.length; ++$) {
2499
- const G = T[$];
2500
- if (!ue(G.fileName, this))
2519
+ const R = T[$];
2520
+ if (!ue(R.fileName, this))
2501
2521
  continue;
2502
- const z = G.fileName.slice(e.context.cwd.length), J = this.watchFiles.get(z);
2503
- J === void 0 ? (n(z, G, void 0), w = !0) : J.file !== G ? (s(J, z, G), w = !0) : J.wasRemoved = !1;
2522
+ const z = R.fileName.slice(e.context.cwd.length), J = this.watchFiles.get(z);
2523
+ J === void 0 ? (n(z, R, void 0), w = !0) : J.file !== R ? (s(J, z, R), w = !0) : J.wasRemoved = !1;
2504
2524
  }
2505
- for (const [$, G] of this.watchFiles)
2506
- G.wasRemoved && (a(G, $), w = !0);
2507
- w ? p() : (Ge(this, _()), m(void 0));
2525
+ for (const [$, R] of this.watchFiles)
2526
+ R.wasRemoved && (a(R, $), w = !0);
2527
+ w ? p() : (Re(this, _()), f(void 0));
2508
2528
  }, t = E.createWatchProgram(y);
2509
2529
  } else {
2510
2530
  let u = function(y) {
2511
- return ct(y, {
2531
+ return dt(y, {
2512
2532
  throwIfNoEntry: !1
2513
2533
  })?.isFile();
2514
2534
  };
2515
- const v = nt(() => {
2535
+ const v = rt(() => {
2516
2536
  let y = !1;
2517
2537
  for (const [b, M] of i)
2518
2538
  y = C(b, M) || y;
2519
- i.clear(), y ? (e.watch.clearScreen && E.sys.clearScreen?.(), p()) : m(void 0);
2539
+ i.clear(), y ? (e.watch.clearScreen && E.sys.clearScreen?.(), p()) : f(void 0);
2520
2540
  }, e.watch.debounceTime), C = (y, b) => {
2521
2541
  const M = e.context.cwd + y, I = !b, P = this.watchFiles.get(y), L = P !== void 0;
2522
2542
  if (I || P === void 0) {
@@ -2524,7 +2544,7 @@ const Lt = async function() {
2524
2544
  if (S === !1) {
2525
2545
  let T, w = !1;
2526
2546
  try {
2527
- T = st(M, { recursive: !0 });
2547
+ T = at(M, { recursive: !0 });
2528
2548
  let $;
2529
2549
  for (; ($ = T.readSync()) !== null; ) {
2530
2550
  if ($.isDirectory())
@@ -2551,16 +2571,16 @@ const Lt = async function() {
2551
2571
  {
2552
2572
  let T = !1;
2553
2573
  const w = `${y}/`;
2554
- for (const [$, G] of this.watchFiles)
2555
- $.startsWith(w) && (a(G, $), T = !0);
2574
+ for (const [$, R] of this.watchFiles)
2575
+ $.startsWith(w) && (a(R, $), T = !0);
2556
2576
  return T;
2557
2577
  }
2558
2578
  }
2559
2579
  } else
2560
2580
  return s(P, y, void 0), !0;
2561
2581
  };
2562
- t = at(this.basePath, { recursive: !0 }, (y, b) => {
2563
- const M = f(), I = b === null ? void 0 : qe(b), P = y === "change";
2582
+ t = lt(this.basePath, { recursive: !0 }, (y, b) => {
2583
+ const M = m(), I = b === null ? void 0 : qe(b), P = y === "change";
2564
2584
  if (I !== void 0 && // If changed, check if it is an included file
2565
2585
  // For a rename, we don't know if it is directory or a file - only check
2566
2586
  // if directory is included, and the file will be checked later.
@@ -2578,17 +2598,17 @@ const Lt = async function() {
2578
2598
  t.close(), i.clear(), await d?.promise, this.watchFiles = void 0;
2579
2599
  }
2580
2600
  };
2581
- }, Ot = ".verify-typings.ts";
2582
- class Nt {
2583
- constructor(t, i = N.join(process.cwd(), "dist")) {
2584
- this.extractor = t, this.virtualCwdPath = N.join(i, "/");
2601
+ }, Bt = ".verify-typings.ts";
2602
+ class Wt {
2603
+ constructor(t, i = O.join(process.cwd(), "dist")) {
2604
+ this.extractor = t, this.virtualCwdPath = O.join(i, "/");
2585
2605
  }
2586
2606
  verifyTypes(t) {
2587
2607
  const i = _(), o = /* @__PURE__ */ Object.create(null);
2588
- o[this.virtualCwdPath + Ot] = this.getVerificationFileContents(t);
2608
+ o[this.virtualCwdPath + Bt] = this.getVerificationFileContents(t);
2589
2609
  const s = this.extractor.config.context.dtsEmitPath === "" ? this.virtualCwdPath : "";
2590
- for (const [m, p] of this.extractor.dtsFiles)
2591
- o[s + m] = p;
2610
+ for (const [f, p] of this.extractor.dtsFiles)
2611
+ o[s + f] = p;
2592
2612
  const a = {
2593
2613
  lib: ["lib.dom.d.ts", "lib.esnext.d.ts"],
2594
2614
  module: E.ModuleKind.ESNext,
@@ -2608,22 +2628,22 @@ class Nt {
2608
2628
  // Performance optimization. Don't look up node_modules/@typescript/lib-...
2609
2629
  libReplacement: !1
2610
2630
  }, r = E.createCompilerHost(a), n = r.fileExists;
2611
- r.fileExists = (m) => m.endsWith("package.json") ? m.includes("node_modules") ? n(m) : !1 : o[m] !== void 0 ? !0 : m.endsWith(".d.ts") ? n(m) : !1, r.useCaseSensitiveFileNames = () => !0;
2631
+ r.fileExists = (f) => f.endsWith("package.json") ? f.includes("node_modules") ? n(f) : !1 : o[f] !== void 0 ? !0 : f.endsWith(".d.ts") ? n(f) : !1, r.useCaseSensitiveFileNames = () => !0;
2612
2632
  const l = r.readFile;
2613
- r.readFile = (m) => {
2614
- const p = o[m];
2615
- return p === void 0 ? l(m) : p;
2633
+ r.readFile = (f) => {
2634
+ const p = o[f];
2635
+ return p === void 0 ? l(f) : p;
2616
2636
  };
2617
2637
  const c = r.directoryExists;
2618
- r.directoryExists = (m) => m.includes("node_modules") ? c(m) : !0, r.getCurrentDirectory = () => this.virtualCwdPath, r.getCanonicalFileName = se.getCanonicalFileName;
2638
+ r.directoryExists = (f) => f.includes("node_modules") ? c(f) : !0, r.getCurrentDirectory = () => this.virtualCwdPath, r.getCanonicalFileName = se.getCanonicalFileName;
2619
2639
  const d = E.createProgram({
2620
2640
  rootNames: Object.keys(o),
2621
2641
  host: r,
2622
2642
  options: a
2623
- }), f = E.getPreEmitDiagnostics(d).filter(this.extractor.config.verify.filterTypeCheckDiagnostic);
2624
- f.length && (this.extractor.config.context.logger.error(
2625
- E.formatDiagnosticsWithColorAndContext(f, se)
2626
- ), process.exitCode = 1, this.extractor.errorCount += f.length), this.extractor.config.context.logger.info(`${H}Types verified in ${x("green", `${i()}s`)}`);
2643
+ }), m = E.getPreEmitDiagnostics(d).filter(this.extractor.config.verify.filterTypeCheckDiagnostic);
2644
+ m.length && (this.extractor.config.context.logger.error(
2645
+ E.formatDiagnosticsWithColorAndContext(m, se)
2646
+ ), process.exitCode = 1, this.extractor.errorCount += m.length), this.extractor.config.context.logger.info(`${H}Types verified in ${x("green", `${i()}s`)}`);
2627
2647
  }
2628
2648
  printTypeParameters(t, i) {
2629
2649
  if (t === void 0)
@@ -2655,18 +2675,18 @@ class Nt {
2655
2675
  return i;
2656
2676
  }
2657
2677
  }
2658
- class Qt {
2678
+ class ii {
2659
2679
  /**
2660
2680
  * @public
2661
2681
  * @param rawConfig Optional configuration for the extractor.
2662
2682
  */
2663
2683
  constructor(t = {}) {
2664
- this.componentStories = /* @__PURE__ */ Object.create(null), this.dtsFiles = /* @__PURE__ */ new Map(), this.changedDtsFiles = void 0, this.isRunInProgress = !1, this.watchFiles = void 0, this.program = void 0, this.builderProgram = void 0, this.componentPathMapping = void 0, this.componentCssFileDocs = void 0, this.vanillaComponentTypes = void 0, this.isInLuminaMinimalExtraction = !1, this.errorCount = 0, this.silencedBrokenLinkCount = 0, this.loggedBooleanWarning = !1, this.moduleMap = void 0, this.privateMixinModuleNames = /* @__PURE__ */ new Set(), this.implicitPublicModules = void 0, this.file = void 0, this.apiModule = void 0, this.componentTagName = void 0, this.pairedSetter = void 0, this.statementJsDocs = [], this.jsDoc = void 0, this.apiObject = void 0, this.moduleContext = void 0, this.localDeclarations = /* @__PURE__ */ new Set(), this.exportDefaultName = void 0, this.objectLikeTypeParameters = void 0, this.functionLikeTypeParameters = void 0, this.apiClassLikeName = void 0, this.mixinName = void 0, this.mixinMixins = void 0, this.moduleHasAccessorLikeClass = !1, this.moduleHasClass = !1, this.inheritedModuleName = void 0, this.run = Rt.bind(this), this.watch = Lt.bind(this), this.emitError = Re.bind(this);
2684
+ this.componentStories = /* @__PURE__ */ Object.create(null), this.dtsFiles = /* @__PURE__ */ new Map(), this.changedDtsFiles = void 0, this.isRunInProgress = !1, this.watchFiles = void 0, this.program = void 0, this.builderProgram = void 0, this.componentPathMapping = void 0, this.componentCssFileDocs = void 0, this.vanillaComponentTypes = void 0, this.isInLuminaMinimalExtraction = !1, this.errorCount = 0, this.silencedBrokenLinkCount = 0, this.loggedBooleanWarning = !1, this.moduleMap = void 0, this.privateMixinModuleNames = /* @__PURE__ */ new Set(), this.implicitPublicModules = void 0, this.file = void 0, this.apiModule = void 0, this.componentTagName = void 0, this.pairedSetter = void 0, this.statementJsDocs = [], this.jsDoc = void 0, this.apiObject = void 0, this.moduleContext = void 0, this.localDeclarations = /* @__PURE__ */ new Set(), this.exportDefaultName = void 0, this.objectLikeTypeParameters = void 0, this.functionLikeTypeParameters = void 0, this.apiClassLikeName = void 0, this.mixinName = void 0, this.mixinMixins = void 0, this.moduleHasAccessorLikeClass = !1, this.moduleHasClass = !1, this.inheritedModuleName = void 0, this.run = Lt.bind(this), this.watch = Ot.bind(this), this.emitError = Ge.bind(this);
2665
2685
  const i = Ve(t);
2666
2686
  this.config = i, this.produceDts = i.types.forceProduceDts || i.context.dtsEmitPath !== "" || i.verify.typeCheckTypes, this.basePath = `${i.context.cwd}${i.context.basePath}`, this.normalizedApiReferencePrefix = `https://${this.config.documentation.host}${this.config.documentation.basePath}`, this.runtimeDependencyNames = /* @__PURE__ */ new Set([
2667
2687
  ...Object.keys(i.context.packageJson.dependencies ?? {}),
2668
2688
  ...Object.keys(i.context.packageJson.peerDependencies ?? {})
2669
- ]), this.resolveJsDocLink = i.context.isLuminaMinimalExtraction ? ke : Ye.bind(void 0, this), this.isComponentProject = "@arcgis/lumina" in (i.context.packageJson.dependencies ?? {}), this.isJsApi = i.context.packageJson.name === "arcgis-js-api", this.typeVerifier = i.verify.typeCheckTypes ? new Nt(this, i.context.dtsEmitPath || void 0) : void 0, this.localPrivateDeclarations = i.strict ? void 0 : /* @__PURE__ */ new Map();
2689
+ ]), this.resolveJsDocLink = i.context.isLuminaMinimalExtraction ? ke : Ye.bind(void 0, this), this.isComponentProject = "@arcgis/lumina" in (i.context.packageJson.dependencies ?? {}), this.isJsApi = i.context.packageJson.name === "arcgis-js-api", this.typeVerifier = i.verify.typeCheckTypes ? new Wt(this, i.context.dtsEmitPath || void 0) : void 0, this.localPrivateDeclarations = i.strict ? void 0 : /* @__PURE__ */ new Map();
2670
2690
  }
2671
2691
  /**
2672
2692
  * Given an array of ApiModules, add top-level api.json metadata and return
@@ -2693,6 +2713,6 @@ class Qt {
2693
2713
  }
2694
2714
  }
2695
2715
  export {
2696
- Qt as A,
2697
- Dt as w
2716
+ ii as A,
2717
+ Nt as w
2698
2718
  };