@arcgis/api-extractor 5.1.0-next.81 → 5.1.0-next.83
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.
- package/dist/{ApiExtractor-IYYCO-EG.js → ApiExtractor-Mf9uoK3l.js} +199 -198
- package/dist/extractor/ApiExtractor.js +3 -3
- package/dist/extractor/config.d.ts +9 -0
- package/dist/extractor/config.js +7 -8
- package/dist/extractor/processing/links.js +25 -24
- package/dist/privateContext-CB7P40up.js +86 -0
- package/dist/typeScript-Dfd5XTQ_.js +66 -0
- package/dist/utils/apiHelpers.js +78 -15
- package/dist/utils/partPrinter.js +29 -28
- package/dist/vite/plugin.js +3 -3
- package/dist/vite/typeScript.js +1 -1
- package/dist/{worker-CsceZ1rD.js → worker-DqsVDByV.js} +950 -952
- package/package.json +3 -4
- package/dist/apiHelpers-dNwlX631.js +0 -161
- package/dist/typeScript-K2y-5lid.js +0 -64
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "../typeScript-
|
|
2
|
-
import "../worker-
|
|
1
|
+
import "../typeScript-Dfd5XTQ_.js";
|
|
2
|
+
import "../worker-DqsVDByV.js";
|
|
3
3
|
import "./processing/links.js";
|
|
4
4
|
import "typescript";
|
|
5
|
-
import { A as x } from "../ApiExtractor-
|
|
5
|
+
import { A as x } from "../ApiExtractor-Mf9uoK3l.js";
|
|
6
6
|
import "@arcgis/toolkit/function";
|
|
7
7
|
export {
|
|
8
8
|
x as ApiExtractor
|
|
@@ -279,6 +279,15 @@ export type TypeReplacements = Record<string, Record<string, readonly [modulePat
|
|
|
279
279
|
export interface ApiExtractorDocumentationConfig {
|
|
280
280
|
readonly copyDocDefinitions?: CopyDocDefinitions;
|
|
281
281
|
readonly noInheritMembers?: NoInheritMembers;
|
|
282
|
+
/**
|
|
283
|
+
* Whether to omit \@internal APIs from api.json.
|
|
284
|
+
* This can only be disabled if not emitting .d.ts files.
|
|
285
|
+
* Otherwise, you can manually filter out nodes that have
|
|
286
|
+
* .docsTags[].name==="internal" in the api.json.
|
|
287
|
+
*
|
|
288
|
+
* @default false
|
|
289
|
+
*/
|
|
290
|
+
readonly omitInternal?: boolean;
|
|
282
291
|
/**
|
|
283
292
|
* Get a prefix for a public-facing URL for each component story.
|
|
284
293
|
*
|
package/dist/extractor/config.js
CHANGED
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
import "@arcgis/components-build-utils";
|
|
2
|
-
import "../typeScript-
|
|
3
|
-
import { l
|
|
2
|
+
import "../typeScript-Dfd5XTQ_.js";
|
|
3
|
+
import { l, m as n, r as A } from "../worker-DqsVDByV.js";
|
|
4
4
|
import "./processing/links.js";
|
|
5
5
|
import "typescript";
|
|
6
6
|
import "fs/promises";
|
|
7
|
-
import "
|
|
8
|
-
import "util";
|
|
7
|
+
import "node:util";
|
|
9
8
|
import "@arcgis/toolkit/string";
|
|
10
|
-
import "../apiHelpers
|
|
9
|
+
import "../utils/apiHelpers.js";
|
|
11
10
|
import "@arcgis/toolkit/function";
|
|
12
11
|
import "node:fs";
|
|
13
12
|
import "node:url";
|
|
14
13
|
export {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
l as loadApiExtractorConfig,
|
|
15
|
+
n as mergeApiExtractorConfigs,
|
|
16
|
+
A as resolveApiExtractorConfig
|
|
18
17
|
};
|
|
@@ -1,29 +1,30 @@
|
|
|
1
|
-
import C from "
|
|
2
|
-
import {
|
|
1
|
+
import { styleText as C } from "node:util";
|
|
2
|
+
import { emitJsDocError as a, getApiNodeLabel as w } from "../../utils/apiHelpers.js";
|
|
3
|
+
import { g as y } from "../../privateContext-CB7P40up.js";
|
|
3
4
|
import { kebabToPascal as I } from "@arcgis/toolkit/string";
|
|
4
|
-
function
|
|
5
|
+
function W(e, n) {
|
|
5
6
|
if (typeof e == "string") {
|
|
6
7
|
const i = e.replaceAll(F, n.resolveJsDocLink).replaceAll(n.config.documentation.alternativeHost, n.config.documentation.host);
|
|
7
|
-
return e.includes("](.") && a(
|
|
8
|
+
return e.includes("](.") && a(P, e, n), i;
|
|
8
9
|
}
|
|
9
10
|
return e;
|
|
10
11
|
}
|
|
11
|
-
function
|
|
12
|
+
function j(e, n) {
|
|
12
13
|
if (e) {
|
|
13
14
|
const i = e.replaceAll(F, n.resolveJsDocLink).replaceAll(n.config.documentation.alternativeHost, n.config.documentation.host);
|
|
14
|
-
return i.includes("](.") && a(
|
|
15
|
+
return i.includes("](.") && a(P, i, n), i;
|
|
15
16
|
}
|
|
16
17
|
return e;
|
|
17
18
|
}
|
|
18
|
-
function
|
|
19
|
+
function J(e, n) {
|
|
19
20
|
if (e !== void 0 && n.inheritedModuleName === void 0)
|
|
20
21
|
for (let i = 0; i < e.length; ++i) {
|
|
21
22
|
const d = e[i];
|
|
22
|
-
d.text && (d.text = d.text.replaceAll(F, n.resolveJsDocLink).replaceAll(n.config.documentation.alternativeHost, n.config.documentation.host), d.text.includes("](.") && a(
|
|
23
|
+
d.text && (d.text = d.text.replaceAll(F, n.resolveJsDocLink).replaceAll(n.config.documentation.alternativeHost, n.config.documentation.host), d.text.includes("](.") && a(P, d.text, n));
|
|
23
24
|
}
|
|
24
25
|
}
|
|
25
|
-
const
|
|
26
|
-
function
|
|
26
|
+
const P = "Unexpected relative markdown link. For links to API within the package use {@link}. For all other links, use absolute markdown. Documentation: https://webgis.esri.com/webgis/core/core/documenting-api#link", F = /\{@link +([^}]+)\}/gu;
|
|
27
|
+
function N(e, n, i) {
|
|
27
28
|
let d = i.indexOf(" ");
|
|
28
29
|
d === -1 && (d = i.length);
|
|
29
30
|
const u = i.slice(0, d), m = i.slice(d + 1);
|
|
@@ -43,20 +44,20 @@ function J(e, n, i) {
|
|
|
43
44
|
let k = e.moduleMap.get(f);
|
|
44
45
|
if (k === void 0 && e.isComponentProject && !e.config.strict) {
|
|
45
46
|
for (const r of e.moduleMap.values())
|
|
46
|
-
if (
|
|
47
|
+
if (y(r).index.class?.name === f) {
|
|
47
48
|
k = r;
|
|
48
49
|
break;
|
|
49
50
|
}
|
|
50
51
|
}
|
|
51
52
|
if (k === void 0)
|
|
52
53
|
return e.config.verify.detectBrokenLinks ? a(
|
|
53
|
-
`Failed to find referenced module: ${C
|
|
54
|
+
`Failed to find referenced module: ${C("red", f)}${f.startsWith("module:") ? '. Module name in @link does not need the "module:" prefix' : f.startsWith("esri/") ? '. Module name in @link does not need to start with the "esri/" prefix.' : ""}`,
|
|
54
55
|
n,
|
|
55
56
|
e
|
|
56
57
|
) : e.silencedBrokenLinkCount += 1, n;
|
|
57
|
-
const v =
|
|
58
|
-
if (e.watchFiles !== void 0 && f !== D.path &&
|
|
59
|
-
const r =
|
|
58
|
+
const v = y(k), D = e.inheritedModuleName === void 0 ? e.apiModule : e.moduleMap.get(e.inheritedModuleName) ?? e.apiModule;
|
|
59
|
+
if (e.watchFiles !== void 0 && f !== D.path && y(D).isStale) {
|
|
60
|
+
const r = y(D).file.fileName.slice(e.config.context.cwd.length), s = v.file.fileName.slice(e.config.context.cwd.length);
|
|
60
61
|
e.watchFiles.get(r).docLinks.push(i), e.watchFiles.get(r).dependencies.add(s);
|
|
61
62
|
const b = e.watchFiles.get(s).dependents;
|
|
62
63
|
b.has(r) || b.set(r, !1);
|
|
@@ -65,11 +66,11 @@ function J(e, n, i) {
|
|
|
65
66
|
if (L !== void 0) {
|
|
66
67
|
const r = v.index.named[L];
|
|
67
68
|
return r === void 0 ? (e.config.verify.detectBrokenLinks ? a(
|
|
68
|
-
`Failed to find the referenced declaration inside the module: ${C
|
|
69
|
+
`Failed to find the referenced declaration inside the module: ${C("red", `${f}!${L}`)}`,
|
|
69
70
|
n,
|
|
70
71
|
e
|
|
71
72
|
) : e.silencedBrokenLinkCount += 1, n) : r === v.index.class ? (a(
|
|
72
|
-
`Invalid reference syntax used. Class/mixin/custom element declarations must be referenced without specifying the class name. Expected ${C
|
|
73
|
+
`Invalid reference syntax used. Class/mixin/custom element declarations must be referenced without specifying the class name. Expected ${C("green", f)}`,
|
|
73
74
|
n,
|
|
74
75
|
e
|
|
75
76
|
), n) : `[${m || w(r)}](${h})`;
|
|
@@ -81,7 +82,7 @@ function J(e, n, i) {
|
|
|
81
82
|
n,
|
|
82
83
|
e
|
|
83
84
|
) : e.silencedBrokenLinkCount += 1 : a(
|
|
84
|
-
`Invalid reference syntax used. This syntax is only permitted on modules that export a class/mixin/web component. Perhaps you meant to use ${C
|
|
85
|
+
`Invalid reference syntax used. This syntax is only permitted on modules that export a class/mixin/web component. Perhaps you meant to use ${C("red", `${f}!${t}`)} instead? Linking to properties in interfaces is not yet supported`,
|
|
85
86
|
n,
|
|
86
87
|
e
|
|
87
88
|
), n;
|
|
@@ -160,13 +161,13 @@ function A(e) {
|
|
|
160
161
|
const n = e.lastIndexOf("/");
|
|
161
162
|
return n === -1 ? e : e.slice(n + 1);
|
|
162
163
|
}
|
|
163
|
-
const
|
|
164
|
+
const E = (e) => `/javascript/latest/references/${e}/`;
|
|
164
165
|
export {
|
|
165
166
|
U as buildViewUrl,
|
|
166
|
-
|
|
167
|
+
E as getDefaultBasePath,
|
|
167
168
|
M as getViewUrl,
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
169
|
+
W as postProcessDeprecated,
|
|
170
|
+
j as postProcessDescription,
|
|
171
|
+
J as postProcessDocsTags,
|
|
172
|
+
N as resolveJsDocLink
|
|
172
173
|
};
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
const e = /* @__PURE__ */ Symbol("privateContext");
|
|
2
|
+
function s(t, o, i, n) {
|
|
3
|
+
return {
|
|
4
|
+
isStale: !0,
|
|
5
|
+
file: t,
|
|
6
|
+
dtsPath: o,
|
|
7
|
+
importsMap: i,
|
|
8
|
+
importsText: void 0,
|
|
9
|
+
constructorPropertiesInterface: void 0,
|
|
10
|
+
constructorOnlySetters: void 0,
|
|
11
|
+
constructorAutoCastType: void 0,
|
|
12
|
+
typeName: void 0,
|
|
13
|
+
inheritance: void 0,
|
|
14
|
+
index: n,
|
|
15
|
+
reExports: void 0,
|
|
16
|
+
namespaces: void 0
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
function a() {
|
|
20
|
+
return {
|
|
21
|
+
hasExplicitAbstract: void 0,
|
|
22
|
+
isDefaultExported: void 0,
|
|
23
|
+
eventTypesProperty: void 0,
|
|
24
|
+
isMixinBaseClass: void 0,
|
|
25
|
+
emitAsTypeAlias: void 0,
|
|
26
|
+
esriCompatibilityNames: void 0
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
function c() {
|
|
30
|
+
return {
|
|
31
|
+
isAbstract: void 0,
|
|
32
|
+
isAccessor: void 0,
|
|
33
|
+
hasAutoCasting: void 0,
|
|
34
|
+
autoCastingRequiresType: void 0,
|
|
35
|
+
autoCastingDefaultType: void 0,
|
|
36
|
+
isConstructorOnly: void 0,
|
|
37
|
+
isOverride: void 0,
|
|
38
|
+
dtsTypeOverride: void 0
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
function u() {
|
|
42
|
+
return {
|
|
43
|
+
isAbstract: void 0,
|
|
44
|
+
isDefaultExported: void 0,
|
|
45
|
+
hasQuestionToken: void 0,
|
|
46
|
+
esriCompatibilityNames: void 0
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
function d() {
|
|
50
|
+
return {
|
|
51
|
+
isDefaultExported: void 0,
|
|
52
|
+
esriCompatibilityNames: void 0
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
function v(t) {
|
|
56
|
+
return t[e];
|
|
57
|
+
}
|
|
58
|
+
function x(t) {
|
|
59
|
+
return t[e];
|
|
60
|
+
}
|
|
61
|
+
function p(t) {
|
|
62
|
+
return t[e];
|
|
63
|
+
}
|
|
64
|
+
function C(t) {
|
|
65
|
+
return t[e];
|
|
66
|
+
}
|
|
67
|
+
function l(t) {
|
|
68
|
+
return t[e];
|
|
69
|
+
}
|
|
70
|
+
function f(t) {
|
|
71
|
+
return t[e];
|
|
72
|
+
}
|
|
73
|
+
export {
|
|
74
|
+
x as a,
|
|
75
|
+
l as b,
|
|
76
|
+
C as c,
|
|
77
|
+
f as d,
|
|
78
|
+
p as e,
|
|
79
|
+
u as f,
|
|
80
|
+
v as g,
|
|
81
|
+
s as h,
|
|
82
|
+
c as i,
|
|
83
|
+
a as j,
|
|
84
|
+
d as k,
|
|
85
|
+
e as p
|
|
86
|
+
};
|
|
@@ -0,0 +1,66 @@
|
|
|
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.1.0-next.83", 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
|
+
};
|
package/dist/utils/apiHelpers.js
CHANGED
|
@@ -1,17 +1,80 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { g as f } from "../privateContext-CB7P40up.js";
|
|
2
|
+
const g = (e) => e.kind === "method", v = (e) => e.kind === "field";
|
|
3
|
+
function h(e, n) {
|
|
4
|
+
const o = e.sourcePath, i = n.sourcePath;
|
|
5
|
+
let t = 0;
|
|
6
|
+
for (; ; ) {
|
|
7
|
+
const c = o.indexOf("/", t), s = i.indexOf("/", t);
|
|
8
|
+
if (c === -1)
|
|
9
|
+
return s === -1 ? o.slice(t) < i.slice(t) ? -1 : 1 : -1;
|
|
10
|
+
if (s === -1)
|
|
11
|
+
return 1;
|
|
12
|
+
{
|
|
13
|
+
const r = o.slice(t, c), a = i.slice(t, s);
|
|
14
|
+
if (r !== a)
|
|
15
|
+
return r < a ? -1 : 1;
|
|
16
|
+
t = c + 1;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
const p = "global:";
|
|
21
|
+
function x(e, n, o) {
|
|
22
|
+
const i = f(o.apiModule).file, t = i.text.indexOf(n) ?? -1;
|
|
23
|
+
o.emitError(`${e}${t === -1 ? `. Found in: ${n}` : ""}`, {
|
|
24
|
+
file: i,
|
|
25
|
+
node: void 0,
|
|
26
|
+
scope: i === void 0 ? o.apiModule.sourcePath : void 0,
|
|
27
|
+
start: t,
|
|
28
|
+
length: n.length
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
const l = new Intl.Collator("en", { numeric: !0 }).compare, S = (e, n) => l(e.name, n.name), M = (e, n) => e.static !== void 0 && n.static === void 0 ? -1 : n.static !== void 0 && e.static === void 0 ? 1 : e.name === void 0 ? n.name === void 0 ? 0 : -1 : n.name === void 0 || "return" in e && !("return" in n) ? 1 : "return" in n && !("return" in e) ? -1 : l(e.name, n.name), d = (e) => e.name ?? (e.kind === "constructor" ? "constructor" : "call-signature"), P = (e) => e.static === !0 ? `static ${d(e)}` : d(e), T = (e) => ("bubbles" in e ? "@" : "") + (e.tagName ?? e.name ?? (e.kind === "constructor" ? "constructor" : "")) + ("return" in e ? "()" : "");
|
|
32
|
+
function k(e, n, o = -1) {
|
|
33
|
+
"description" in n && (n.description ??= e.description), "deprecated" in n && (n.deprecated ??= e.deprecated), "return" in n && e.return !== void 0 && (n.return.description ??= e.return?.description), "readonly" in n && (n.readonly ??= e.readonly);
|
|
34
|
+
const { docsTags: i } = e, t = n;
|
|
35
|
+
if (o !== -1 && (i === void 0 && t.docsTags.length === 1 ? t.docsTags = void 0 : t.docsTags.splice(o, 1)), i !== void 0) {
|
|
36
|
+
t.docsTags ??= [];
|
|
37
|
+
const c = /* @__PURE__ */ new Set();
|
|
38
|
+
for (let s = 0; s < t.docsTags.length; ++s)
|
|
39
|
+
c.add(t.docsTags[s].name);
|
|
40
|
+
for (let s = 0; s < i.length; ++s) {
|
|
41
|
+
const r = i[s];
|
|
42
|
+
c.has(r.name) && r.name !== "example" && r.name !== "see" || t.docsTags.push(r);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
function y(e, n) {
|
|
47
|
+
let o = e.text;
|
|
48
|
+
if (e.references !== void 0)
|
|
49
|
+
for (let i = e.references.length - 1; i >= 0; i--) {
|
|
50
|
+
const t = e.references[i];
|
|
51
|
+
if (t.package === p || t.module === void 0 && t.package === void 0 && t.viewUrl === void 0)
|
|
52
|
+
continue;
|
|
53
|
+
const r = t.name === "default" ? "default" : t.name, u = `import("${t.package === void 0 ? `./${t.module ?? n}.js` : t.package + (t.module === void 0 ? "" : `/${t.module}`)}").${r}`;
|
|
54
|
+
o = o.slice(0, t.start) + u + o.slice(t.end);
|
|
55
|
+
}
|
|
56
|
+
return {
|
|
57
|
+
...e,
|
|
58
|
+
text: o,
|
|
59
|
+
references: void 0
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
function A(e) {
|
|
63
|
+
return e.return.type.text.startsWith("Promise<");
|
|
64
|
+
}
|
|
2
65
|
export {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
66
|
+
y as apiTypeToImportType,
|
|
67
|
+
M as compareClassMembers,
|
|
68
|
+
S as compareNamedNodes,
|
|
69
|
+
l as compareStrings,
|
|
70
|
+
x as emitJsDocError,
|
|
71
|
+
d as getApiMemberName,
|
|
72
|
+
T as getApiNodeLabel,
|
|
73
|
+
P as getMaybeStaticApiMemberName,
|
|
74
|
+
p as globalPackageIdentifier,
|
|
75
|
+
g as isApiMethod,
|
|
76
|
+
A as isApiMethodAsync,
|
|
77
|
+
v as isApiProperty,
|
|
78
|
+
k as mergeApiNodes,
|
|
79
|
+
h as naturalSortModules
|
|
17
80
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { d as l } from "../privateContext-CB7P40up.js";
|
|
2
|
+
function m(t, r, i, e, n, o) {
|
|
2
3
|
return `${`${r ? "export default " : "export "}${t ? "abstract " : ""}`}class ${i}${f(e)}${n === void 0 ? "" : ` extends ${n}`} {${o}}`;
|
|
3
4
|
}
|
|
4
5
|
function f(t) {
|
|
@@ -11,31 +12,31 @@ function f(t) {
|
|
|
11
12
|
}
|
|
12
13
|
return r += ">", r;
|
|
13
14
|
}
|
|
14
|
-
function
|
|
15
|
+
function v(t, r, i, e, n) {
|
|
15
16
|
const o = t ? "export default " : "export ";
|
|
16
17
|
let $ = "";
|
|
17
18
|
if (e !== void 0) {
|
|
18
19
|
$ = " extends ";
|
|
19
20
|
for (let c = 0; c < e.length; ++c)
|
|
20
|
-
$ += e[c], c < e.length - 1 && ($ += ", ");
|
|
21
|
+
$ += l(e[c]), c < e.length - 1 && ($ += ", ");
|
|
21
22
|
}
|
|
22
23
|
return `${o}interface ${r}${f(i)}${$} {${n}}`;
|
|
23
24
|
}
|
|
24
|
-
function
|
|
25
|
-
const s = `${t ? "protected " : ""}${r ? "abstract " : ""}${i ? "static " : ""}`,
|
|
26
|
-
return `${s}${n === "" ? "" : d(n)}${e ? "?" : ""}${f(o)}(${
|
|
25
|
+
function g(t, r, i, e, n, o, $, c) {
|
|
26
|
+
const s = `${t ? "protected " : ""}${r ? "abstract " : ""}${i ? "static " : ""}`, x = c === void 0 ? "" : `: ${c}`;
|
|
27
|
+
return `${s}${n === "" ? "" : d(n)}${e ? "?" : ""}${f(o)}(${a($)})${x};`;
|
|
27
28
|
}
|
|
28
29
|
function d(t) {
|
|
29
|
-
return
|
|
30
|
+
return u.test(t) || t.startsWith("[") ? t : `"${t.replaceAll("\\", "\\\\").replaceAll('"', '\\"')}"`;
|
|
30
31
|
}
|
|
31
|
-
const
|
|
32
|
-
function
|
|
33
|
-
return `${t ? "export default " : "export "}function ${r}${f(i)}(${
|
|
32
|
+
const h = (t) => !u.test(t) && !t.startsWith("["), u = /^[A-Za-z_$][A-Za-z0-9_$]*$/u;
|
|
33
|
+
function b(t, r, i, e, n) {
|
|
34
|
+
return `${t ? "export default " : "export "}function ${r}${f(i)}(${a(e)}): ${n};`;
|
|
34
35
|
}
|
|
35
|
-
function
|
|
36
|
-
return `${f(t.typeParameters)}(${
|
|
36
|
+
function A(t) {
|
|
37
|
+
return `${f(t.typeParameters)}(${a(t.parameters)}): ${t.return.type.text}`;
|
|
37
38
|
}
|
|
38
|
-
function
|
|
39
|
+
function a(t) {
|
|
39
40
|
if (t === void 0)
|
|
40
41
|
return "";
|
|
41
42
|
let r = "";
|
|
@@ -45,38 +46,38 @@ function u(t) {
|
|
|
45
46
|
}
|
|
46
47
|
return r;
|
|
47
48
|
}
|
|
48
|
-
function
|
|
49
|
+
function P(t, r, i, e, n, o, $, c) {
|
|
49
50
|
return `${`${t ? "protected " : ""}${r ? "abstract " : i ? "static " : ""}${e ? "readonly " : n ? "accessor " : ""}`}${d($)}${o ? "?" : ""}: ${c};`;
|
|
50
51
|
}
|
|
51
|
-
function
|
|
52
|
+
function N(t, r, i, e, n, o) {
|
|
52
53
|
const $ = `${t ? "protected " : ""}${r ? "abstract " : ""}${i ? "static " : ""}`, c = d(e), s = o === void 0 ? "" : `
|
|
53
54
|
${$}set ${c}(value: ${o});`;
|
|
54
55
|
return `${$}get ${c}(): ${n};${s}`;
|
|
55
56
|
}
|
|
56
|
-
function
|
|
57
|
+
function z(t, r, i) {
|
|
57
58
|
const n = `${t ? "declare " : "export "}const ${r}: ${i};`;
|
|
58
59
|
return t ? `${n}
|
|
59
60
|
export default ${r};` : n;
|
|
60
61
|
}
|
|
61
|
-
function
|
|
62
|
+
function R(t, r, i, e) {
|
|
62
63
|
let n = `export type ${t}${f(r)} = `;
|
|
63
64
|
if (i !== void 0)
|
|
64
65
|
for (let o = 0; o < i.length; ++o)
|
|
65
|
-
n += i[o], (o < i.length - 1 || e !== void 0) && (n += `
|
|
66
|
+
n += l(i[o]), (o < i.length - 1 || e !== void 0) && (n += `
|
|
66
67
|
& `);
|
|
67
68
|
return e !== void 0 && (n += e), n += ";", n;
|
|
68
69
|
}
|
|
69
70
|
export {
|
|
70
|
-
|
|
71
|
+
h as isPropertyEscapeNeeded,
|
|
71
72
|
d as maybeEscapePropertyName,
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
73
|
+
m as printClass,
|
|
74
|
+
b as printFunction,
|
|
75
|
+
N as printGetterSetter,
|
|
76
|
+
v as printInterface,
|
|
77
|
+
g as printMethod,
|
|
78
|
+
P as printProperty,
|
|
79
|
+
A as printSignature,
|
|
80
|
+
R as printTypeAlias,
|
|
80
81
|
f as printTypeParameters,
|
|
81
|
-
|
|
82
|
+
z as printVariable
|
|
82
83
|
};
|
package/dist/vite/plugin.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { l as O, m as J } from "../worker-
|
|
2
|
-
import { A as S, w as T } from "../ApiExtractor-
|
|
3
|
-
import { p as A, l as C } from "../typeScript-
|
|
1
|
+
import { l as O, m as J } from "../worker-DqsVDByV.js";
|
|
2
|
+
import { A as S, w as T } from "../ApiExtractor-Mf9uoK3l.js";
|
|
3
|
+
import { p as A, l as C } from "../typeScript-Dfd5XTQ_.js";
|
|
4
4
|
import { writeFile as M } from "node:fs/promises";
|
|
5
5
|
import { path as w } from "@arcgis/components-build-utils";
|
|
6
6
|
const N = A.name;
|