storybook 9.0.0-alpha.17 → 9.0.0-alpha.19
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/bin/index.cjs +48 -49
- package/dist/bin/index.js +55 -56
- package/dist/cli/bin/index.cjs +1 -1
- package/dist/cli/bin/index.js +1 -1
- package/dist/common/index.cjs +42 -43
- package/dist/common/index.d.ts +0 -1
- package/dist/common/index.js +42 -43
- package/dist/core-server/index.cjs +122 -119
- package/dist/core-server/index.js +1596 -1593
- package/dist/core-server/presets/common-manager.js +5730 -3498
- package/dist/instrumenter/index.cjs +1354 -1711
- package/dist/instrumenter/index.js +188 -545
- package/dist/manager/globals-runtime.js +24667 -22626
- package/dist/manager/runtime.js +4 -2
- package/dist/manager-api/index.cjs +1 -1
- package/dist/manager-api/index.js +1 -1
- package/dist/preview/runtime.js +17670 -15630
- package/dist/test/index.cjs +6 -6
- package/dist/test/index.js +6 -6
- package/package.json +1 -1
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var
|
|
2
|
+
var Pe = Object.defineProperty;
|
|
3
3
|
var gr = Object.getOwnPropertyDescriptor;
|
|
4
4
|
var hr = Object.getOwnPropertyNames;
|
|
5
5
|
var yr = Object.prototype.hasOwnProperty;
|
|
6
|
-
var c = (
|
|
7
|
-
var dr = (
|
|
8
|
-
for (var n in
|
|
9
|
-
|
|
10
|
-
}, br = (
|
|
11
|
-
if (
|
|
12
|
-
for (let o of hr(
|
|
13
|
-
!yr.call(
|
|
14
|
-
return
|
|
6
|
+
var c = (e, t) => Pe(e, "name", { value: t, configurable: !0 });
|
|
7
|
+
var dr = (e, t) => {
|
|
8
|
+
for (var n in t)
|
|
9
|
+
Pe(e, n, { get: t[n], enumerable: !0 });
|
|
10
|
+
}, br = (e, t, n, r) => {
|
|
11
|
+
if (t && typeof t == "object" || typeof t == "function")
|
|
12
|
+
for (let o of hr(t))
|
|
13
|
+
!yr.call(e, o) && o !== n && Pe(e, o, { get: () => t[o], enumerable: !(r = gr(t, o)) || r.enumerable });
|
|
14
|
+
return e;
|
|
15
15
|
};
|
|
16
|
-
var Sr = (
|
|
16
|
+
var Sr = (e) => br(Pe({}, "__esModule", { value: !0 }), e);
|
|
17
17
|
|
|
18
18
|
// src/instrumenter/index.ts
|
|
19
19
|
var ci = {};
|
|
20
20
|
dr(ci, {
|
|
21
21
|
CallStates: () => cr,
|
|
22
|
-
EVENTS: () =>
|
|
22
|
+
EVENTS: () => ee,
|
|
23
23
|
instrument: () => mr
|
|
24
24
|
});
|
|
25
25
|
module.exports = Sr(ci);
|
|
26
26
|
|
|
27
27
|
// src/instrumenter/instrumenter.ts
|
|
28
|
-
var fr = require("storybook/internal/client-logger"),
|
|
28
|
+
var fr = require("storybook/internal/client-logger"), ye = require("storybook/internal/core-events"), W = require("@storybook/global");
|
|
29
29
|
|
|
30
30
|
// ../node_modules/tinyrainbow/dist/chunk-BVHSVHOK.js
|
|
31
31
|
var Er = {
|
|
@@ -71,20 +71,20 @@ var Er = {
|
|
|
71
71
|
bgCyanBright: [106, 49],
|
|
72
72
|
bgWhiteBright: [107, 49]
|
|
73
73
|
}, _r = Object.entries(Er);
|
|
74
|
-
function
|
|
75
|
-
return String(
|
|
76
|
-
}
|
|
77
|
-
c(
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
function
|
|
81
|
-
let
|
|
82
|
-
return !("NO_COLOR" in n || r.includes("--no-color")) && ("FORCE_COLOR" in n || r.includes("--color") ||
|
|
74
|
+
function Qe(e) {
|
|
75
|
+
return String(e);
|
|
76
|
+
}
|
|
77
|
+
c(Qe, "a");
|
|
78
|
+
Qe.open = "";
|
|
79
|
+
Qe.close = "";
|
|
80
|
+
function xt(e = !1) {
|
|
81
|
+
let t = typeof process < "u" ? process : void 0, n = t?.env || {}, r = t?.argv || [];
|
|
82
|
+
return !("NO_COLOR" in n || r.includes("--no-color")) && ("FORCE_COLOR" in n || r.includes("--color") || t?.platform === "win32" || e && n.
|
|
83
83
|
TERM !== "dumb" || "CI" in n) || typeof window < "u" && !!window.chrome;
|
|
84
84
|
}
|
|
85
|
-
c(
|
|
86
|
-
function
|
|
87
|
-
let
|
|
85
|
+
c(xt, "C");
|
|
86
|
+
function Ft(e = !1) {
|
|
87
|
+
let t = xt(e), n = /* @__PURE__ */ c((i, a, l, m) => {
|
|
88
88
|
let p = "", f = 0;
|
|
89
89
|
do
|
|
90
90
|
p += i.substring(f, m) + l, f = m + a.length, m = i.indexOf(a, f);
|
|
@@ -92,35 +92,35 @@ function Fe(t = !1) {
|
|
|
92
92
|
return p + i.substring(f);
|
|
93
93
|
}, "i"), r = /* @__PURE__ */ c((i, a, l = i) => {
|
|
94
94
|
let m = /* @__PURE__ */ c((p) => {
|
|
95
|
-
let f = String(p),
|
|
96
|
-
return ~
|
|
95
|
+
let f = String(p), b = f.indexOf(a, i.length);
|
|
96
|
+
return ~b ? i + n(f, a, l, b) + a : i + f + a;
|
|
97
97
|
}, "o");
|
|
98
98
|
return m.open = i, m.close = a, m;
|
|
99
99
|
}, "g"), o = {
|
|
100
|
-
isColorSupported:
|
|
100
|
+
isColorSupported: t
|
|
101
101
|
}, s = /* @__PURE__ */ c((i) => `\x1B[${i}m`, "d");
|
|
102
102
|
for (let [i, a] of _r)
|
|
103
|
-
o[i] =
|
|
103
|
+
o[i] = t ? r(
|
|
104
104
|
s(a[0]),
|
|
105
105
|
s(a[1]),
|
|
106
106
|
a[2]
|
|
107
|
-
) :
|
|
107
|
+
) : Qe;
|
|
108
108
|
return o;
|
|
109
109
|
}
|
|
110
|
-
c(
|
|
110
|
+
c(Ft, "p");
|
|
111
111
|
|
|
112
112
|
// ../node_modules/tinyrainbow/dist/node.js
|
|
113
|
-
var
|
|
114
|
-
var Tr = process.env.FORCE_TTY !== void 0 || (0,
|
|
115
|
-
var
|
|
113
|
+
var Dt = require("tty");
|
|
114
|
+
var Tr = process.env.FORCE_TTY !== void 0 || (0, Dt.isatty)(1);
|
|
115
|
+
var ne = Ft(Tr);
|
|
116
116
|
|
|
117
|
-
// ../node_modules/@vitest/
|
|
118
|
-
function
|
|
119
|
-
return
|
|
117
|
+
// ../node_modules/@vitest/pretty-format/dist/index.js
|
|
118
|
+
function Zt(e, t) {
|
|
119
|
+
return t.forEach(function(n) {
|
|
120
120
|
n && typeof n != "string" && !Array.isArray(n) && Object.keys(n).forEach(function(r) {
|
|
121
|
-
if (r !== "default" && !(r in
|
|
121
|
+
if (r !== "default" && !(r in e)) {
|
|
122
122
|
var o = Object.getOwnPropertyDescriptor(n, r);
|
|
123
|
-
Object.defineProperty(
|
|
123
|
+
Object.defineProperty(e, r, o.get ? o : {
|
|
124
124
|
enumerable: !0,
|
|
125
125
|
get: /* @__PURE__ */ c(function() {
|
|
126
126
|
return n[r];
|
|
@@ -128,387 +128,262 @@ function Ze(t, e) {
|
|
|
128
128
|
});
|
|
129
129
|
}
|
|
130
130
|
});
|
|
131
|
-
}), Object.freeze(
|
|
131
|
+
}), Object.freeze(e);
|
|
132
132
|
}
|
|
133
|
-
c(
|
|
134
|
-
function Cr(
|
|
135
|
-
let n = Object.keys(
|
|
133
|
+
c(Zt, "_mergeNamespaces");
|
|
134
|
+
function Cr(e, t) {
|
|
135
|
+
let n = Object.keys(e), r = t === null ? n : n.sort(t);
|
|
136
136
|
if (Object.getOwnPropertySymbols)
|
|
137
|
-
for (let o of Object.getOwnPropertySymbols(
|
|
138
|
-
Object.getOwnPropertyDescriptor(
|
|
137
|
+
for (let o of Object.getOwnPropertySymbols(e))
|
|
138
|
+
Object.getOwnPropertyDescriptor(e, o).enumerable && r.push(o);
|
|
139
139
|
return r;
|
|
140
140
|
}
|
|
141
141
|
c(Cr, "getKeysOfEnumerableProperties");
|
|
142
|
-
function
|
|
143
|
-
let a = "", l = 0, m =
|
|
142
|
+
function Oe(e, t, n, r, o, s, i = ": ") {
|
|
143
|
+
let a = "", l = 0, m = e.next();
|
|
144
144
|
if (!m.done) {
|
|
145
|
-
a +=
|
|
146
|
-
let p = n +
|
|
145
|
+
a += t.spacingOuter;
|
|
146
|
+
let p = n + t.indent;
|
|
147
147
|
for (; !m.done; ) {
|
|
148
|
-
if (a += p, l++ ===
|
|
148
|
+
if (a += p, l++ === t.maxWidth) {
|
|
149
149
|
a += "\u2026";
|
|
150
150
|
break;
|
|
151
151
|
}
|
|
152
|
-
let f = s(
|
|
153
|
-
|
|
154
|
-
e,
|
|
155
|
-
p,
|
|
156
|
-
r,
|
|
157
|
-
o
|
|
158
|
-
), S = s(
|
|
159
|
-
m.value[1],
|
|
160
|
-
e,
|
|
161
|
-
p,
|
|
162
|
-
r,
|
|
163
|
-
o
|
|
164
|
-
);
|
|
165
|
-
a += f + i + S, m = t.next(), m.done ? e.min || (a += ",") : a += `,${e.spacingInner}`;
|
|
152
|
+
let f = s(m.value[0], t, p, r, o), b = s(m.value[1], t, p, r, o);
|
|
153
|
+
a += f + i + b, m = e.next(), m.done ? t.min || (a += ",") : a += `,${t.spacingInner}`;
|
|
166
154
|
}
|
|
167
|
-
a +=
|
|
155
|
+
a += t.spacingOuter + n;
|
|
168
156
|
}
|
|
169
157
|
return a;
|
|
170
158
|
}
|
|
171
|
-
c(
|
|
172
|
-
function
|
|
173
|
-
let i = "", a = 0, l =
|
|
159
|
+
c(Oe, "printIteratorEntries");
|
|
160
|
+
function nt(e, t, n, r, o, s) {
|
|
161
|
+
let i = "", a = 0, l = e.next();
|
|
174
162
|
if (!l.done) {
|
|
175
|
-
i +=
|
|
176
|
-
let m = n +
|
|
163
|
+
i += t.spacingOuter;
|
|
164
|
+
let m = n + t.indent;
|
|
177
165
|
for (; !l.done; ) {
|
|
178
|
-
if (i += m, a++ ===
|
|
166
|
+
if (i += m, a++ === t.maxWidth) {
|
|
179
167
|
i += "\u2026";
|
|
180
168
|
break;
|
|
181
169
|
}
|
|
182
|
-
i += s(l.value,
|
|
170
|
+
i += s(l.value, t, m, r, o), l = e.next(), l.done ? t.min || (i += ",") : i += `,${t.spacingInner}`;
|
|
183
171
|
}
|
|
184
|
-
i +=
|
|
172
|
+
i += t.spacingOuter + n;
|
|
185
173
|
}
|
|
186
174
|
return i;
|
|
187
175
|
}
|
|
188
|
-
c(
|
|
189
|
-
function
|
|
176
|
+
c(nt, "printIteratorValues");
|
|
177
|
+
function Fe(e, t, n, r, o, s) {
|
|
190
178
|
let i = "";
|
|
191
|
-
|
|
192
|
-
let a = /* @__PURE__ */ c((m) => m instanceof DataView, "isDataView"), l = a(
|
|
179
|
+
e = e instanceof ArrayBuffer ? new DataView(e) : e;
|
|
180
|
+
let a = /* @__PURE__ */ c((m) => m instanceof DataView, "isDataView"), l = a(e) ? e.byteLength : e.length;
|
|
193
181
|
if (l > 0) {
|
|
194
|
-
i +=
|
|
195
|
-
let m = n +
|
|
182
|
+
i += t.spacingOuter;
|
|
183
|
+
let m = n + t.indent;
|
|
196
184
|
for (let p = 0; p < l; p++) {
|
|
197
|
-
if (i += m, p ===
|
|
185
|
+
if (i += m, p === t.maxWidth) {
|
|
198
186
|
i += "\u2026";
|
|
199
187
|
break;
|
|
200
188
|
}
|
|
201
|
-
(a(
|
|
202
|
-
a(t) ? t.getInt8(p) : t[p],
|
|
203
|
-
e,
|
|
204
|
-
m,
|
|
205
|
-
r,
|
|
206
|
-
o
|
|
207
|
-
)), p < l - 1 ? i += `,${e.spacingInner}` : e.min || (i += ",");
|
|
189
|
+
(a(e) || p in e) && (i += s(a(e) ? e.getInt8(p) : e[p], t, m, r, o)), p < l - 1 ? i += `,${t.spacingInner}` : t.min || (i += ",");
|
|
208
190
|
}
|
|
209
|
-
i +=
|
|
191
|
+
i += t.spacingOuter + n;
|
|
210
192
|
}
|
|
211
193
|
return i;
|
|
212
194
|
}
|
|
213
|
-
c(
|
|
214
|
-
function
|
|
215
|
-
let i = "", a = Cr(
|
|
195
|
+
c(Fe, "printListItems");
|
|
196
|
+
function rt(e, t, n, r, o, s) {
|
|
197
|
+
let i = "", a = Cr(e, t.compareKeys);
|
|
216
198
|
if (a.length > 0) {
|
|
217
|
-
i +=
|
|
218
|
-
let l = n +
|
|
199
|
+
i += t.spacingOuter;
|
|
200
|
+
let l = n + t.indent;
|
|
219
201
|
for (let m = 0; m < a.length; m++) {
|
|
220
|
-
let p = a[m], f = s(p,
|
|
221
|
-
i += `${l + f}: ${
|
|
202
|
+
let p = a[m], f = s(p, t, l, r, o), b = s(e[p], t, l, r, o);
|
|
203
|
+
i += `${l + f}: ${b}`, m < a.length - 1 ? i += `,${t.spacingInner}` : t.min || (i += ",");
|
|
222
204
|
}
|
|
223
|
-
i +=
|
|
205
|
+
i += t.spacingOuter + n;
|
|
224
206
|
}
|
|
225
207
|
return i;
|
|
226
208
|
}
|
|
227
|
-
c(
|
|
228
|
-
var Or = typeof Symbol == "function" && Symbol.for ? Symbol.for("jest.asymmetricMatcher") : 1267621,
|
|
229
|
-
let i =
|
|
209
|
+
c(rt, "printObjectProperties");
|
|
210
|
+
var Or = typeof Symbol == "function" && Symbol.for ? Symbol.for("jest.asymmetricMatcher") : 1267621, Ie = " ", $r = /* @__PURE__ */ c((e, t, n, r, o, s) => {
|
|
211
|
+
let i = e.toString();
|
|
230
212
|
if (i === "ArrayContaining" || i === "ArrayNotContaining")
|
|
231
|
-
return ++r >
|
|
232
|
-
t.sample,
|
|
233
|
-
e,
|
|
234
|
-
n,
|
|
235
|
-
r,
|
|
236
|
-
o,
|
|
237
|
-
s
|
|
238
|
-
)}]`;
|
|
213
|
+
return ++r > t.maxDepth ? `[${i}]` : `${i + Ie}[${Fe(e.sample, t, n, r, o, s)}]`;
|
|
239
214
|
if (i === "ObjectContaining" || i === "ObjectNotContaining")
|
|
240
|
-
return ++r >
|
|
241
|
-
t.sample,
|
|
242
|
-
e,
|
|
243
|
-
n,
|
|
244
|
-
r,
|
|
245
|
-
o,
|
|
246
|
-
s
|
|
247
|
-
)}}`;
|
|
215
|
+
return ++r > t.maxDepth ? `[${i}]` : `${i + Ie}{${rt(e.sample, t, n, r, o, s)}}`;
|
|
248
216
|
if (i === "StringMatching" || i === "StringNotMatching" || i === "StringContaining" || i === "StringNotContaining")
|
|
249
|
-
return i +
|
|
250
|
-
if (typeof
|
|
251
|
-
throw new TypeError(
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
["DOMStringMap", "NamedNodeMap"]), Nr = /^(?:HTML\w*Collection|NodeList)$/;
|
|
257
|
-
function Pr(
|
|
258
|
-
return
|
|
217
|
+
return i + Ie + s(e.sample, t, n, r, o);
|
|
218
|
+
if (typeof e.toAsymmetricMatcher != "function")
|
|
219
|
+
throw new TypeError(`Asymmetric matcher ${e.constructor.name} does not implement toAsymmetricMatcher()`);
|
|
220
|
+
return e.toAsymmetricMatcher();
|
|
221
|
+
}, "serialize$5"), wr = /* @__PURE__ */ c((e) => e && e.$$typeof === Or, "test$5"), Ar = {
|
|
222
|
+
serialize: $r,
|
|
223
|
+
test: wr
|
|
224
|
+
}, Rr = " ", vt = /* @__PURE__ */ new Set(["DOMStringMap", "NamedNodeMap"]), Nr = /^(?:HTML\w*Collection|NodeList)$/;
|
|
225
|
+
function Pr(e) {
|
|
226
|
+
return vt.has(e) || Nr.test(e);
|
|
259
227
|
}
|
|
260
228
|
c(Pr, "testName");
|
|
261
|
-
var Ir = /* @__PURE__ */ c((
|
|
262
|
-
function Mr(
|
|
263
|
-
return
|
|
229
|
+
var Ir = /* @__PURE__ */ c((e) => e && e.constructor && !!e.constructor.name && Pr(e.constructor.name), "test$4");
|
|
230
|
+
function Mr(e) {
|
|
231
|
+
return e.constructor.name === "NamedNodeMap";
|
|
264
232
|
}
|
|
265
233
|
c(Mr, "isNamedNodeMap");
|
|
266
|
-
var Lr = /* @__PURE__ */ c((
|
|
267
|
-
let i =
|
|
268
|
-
return ++r >
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
[...t],
|
|
280
|
-
e,
|
|
281
|
-
n,
|
|
282
|
-
r,
|
|
283
|
-
o,
|
|
284
|
-
s
|
|
285
|
-
)}]`);
|
|
286
|
-
}, "serialize$4"), xr = { serialize: Lr, test: Ir };
|
|
287
|
-
function ve(t) {
|
|
288
|
-
return t.replaceAll("<", "<").replaceAll(">", ">");
|
|
289
|
-
}
|
|
290
|
-
c(ve, "escapeHTML");
|
|
291
|
-
function oe(t, e, n, r, o, s, i) {
|
|
234
|
+
var Lr = /* @__PURE__ */ c((e, t, n, r, o, s) => {
|
|
235
|
+
let i = e.constructor.name;
|
|
236
|
+
return ++r > t.maxDepth ? `[${i}]` : (t.min ? "" : i + Rr) + (vt.has(i) ? `{${rt(Mr(e) ? [...e].reduce((a, l) => (a[l.name] = l.value, a),
|
|
237
|
+
{}) : { ...e }, t, n, r, o, s)}}` : `[${Fe([...e], t, n, r, o, s)}]`);
|
|
238
|
+
}, "serialize$4"), xr = {
|
|
239
|
+
serialize: Lr,
|
|
240
|
+
test: Ir
|
|
241
|
+
};
|
|
242
|
+
function Qt(e) {
|
|
243
|
+
return e.replaceAll("<", "<").replaceAll(">", ">");
|
|
244
|
+
}
|
|
245
|
+
c(Qt, "escapeHTML");
|
|
246
|
+
function ot(e, t, n, r, o, s, i) {
|
|
292
247
|
let a = r + n.indent, l = n.colors;
|
|
293
|
-
return
|
|
294
|
-
let p =
|
|
248
|
+
return e.map((m) => {
|
|
249
|
+
let p = t[m], f = i(p, n, a, o, s);
|
|
295
250
|
return typeof p != "string" && (f.includes(`
|
|
296
251
|
`) && (f = n.spacingOuter + a + f + n.spacingOuter + r), f = `{${f}}`), `${n.spacingInner + r + l.prop.open + m + l.prop.close}=${l.value.open}${f}${l.
|
|
297
252
|
value.close}`;
|
|
298
253
|
}).join("");
|
|
299
254
|
}
|
|
300
|
-
c(
|
|
301
|
-
function
|
|
302
|
-
return
|
|
303
|
-
(i) => e.spacingOuter + n + (typeof i == "string" ? tn(i, e) : s(i, e, n, r, o))
|
|
304
|
-
).join("");
|
|
255
|
+
c(ot, "printProps");
|
|
256
|
+
function st(e, t, n, r, o, s) {
|
|
257
|
+
return e.map((i) => t.spacingOuter + n + (typeof i == "string" ? en(i, t) : s(i, t, n, r, o))).join("");
|
|
305
258
|
}
|
|
306
|
-
c(
|
|
307
|
-
function
|
|
308
|
-
let n =
|
|
309
|
-
return n.open +
|
|
259
|
+
c(st, "printChildren");
|
|
260
|
+
function en(e, t) {
|
|
261
|
+
let n = t.colors.content;
|
|
262
|
+
return n.open + Qt(e) + n.close;
|
|
310
263
|
}
|
|
311
|
-
c(
|
|
312
|
-
function Fr(
|
|
313
|
-
let n =
|
|
314
|
-
return `${n.open}<!--${
|
|
264
|
+
c(en, "printText");
|
|
265
|
+
function Fr(e, t) {
|
|
266
|
+
let n = t.colors.comment;
|
|
267
|
+
return `${n.open}<!--${Qt(e)}-->${n.close}`;
|
|
315
268
|
}
|
|
316
269
|
c(Fr, "printComment");
|
|
317
|
-
function
|
|
270
|
+
function it(e, t, n, r, o) {
|
|
318
271
|
let s = r.colors.tag;
|
|
319
|
-
return `${s.open}<${
|
|
272
|
+
return `${s.open}<${e}${t && s.close + t + r.spacingOuter + o + s.open}${n ? `>${s.close}${n}${r.spacingOuter}${o}${s.open}</${e}` : `${t &&
|
|
320
273
|
!r.min ? "" : " "}/`}>${s.close}`;
|
|
321
274
|
}
|
|
322
|
-
c(
|
|
323
|
-
function
|
|
324
|
-
let n =
|
|
325
|
-
return `${n.open}<${
|
|
275
|
+
c(it, "printElement");
|
|
276
|
+
function ct(e, t) {
|
|
277
|
+
let n = t.colors.tag;
|
|
278
|
+
return `${n.open}<${e}${n.close} \u2026${n.open} />${n.close}`;
|
|
326
279
|
}
|
|
327
|
-
c(
|
|
328
|
-
var Dr = 1,
|
|
329
|
-
function Br(
|
|
280
|
+
c(ct, "printElementAsLeaf");
|
|
281
|
+
var Dr = 1, tn = 3, nn = 8, rn = 11, jr = /^(?:(?:HTML|SVG)\w*)?Element$/;
|
|
282
|
+
function Br(e) {
|
|
330
283
|
try {
|
|
331
|
-
return typeof
|
|
284
|
+
return typeof e.hasAttribute == "function" && e.hasAttribute("is");
|
|
332
285
|
} catch {
|
|
333
286
|
return !1;
|
|
334
287
|
}
|
|
335
288
|
}
|
|
336
289
|
c(Br, "testHasAttribute");
|
|
337
|
-
function kr(
|
|
338
|
-
let
|
|
339
|
-
return n === Dr && (jr.test(
|
|
290
|
+
function kr(e) {
|
|
291
|
+
let t = e.constructor.name, { nodeType: n, tagName: r } = e, o = typeof r == "string" && r.includes("-") || Br(e);
|
|
292
|
+
return n === Dr && (jr.test(t) || o) || n === tn && t === "Text" || n === nn && t === "Comment" || n === rn && t === "DocumentFragment";
|
|
340
293
|
}
|
|
341
294
|
c(kr, "testNode");
|
|
342
|
-
var zr = /* @__PURE__ */ c((
|
|
343
|
-
var
|
|
344
|
-
return (
|
|
295
|
+
var zr = /* @__PURE__ */ c((e) => {
|
|
296
|
+
var t;
|
|
297
|
+
return (e == null || (t = e.constructor) === null || t === void 0 ? void 0 : t.name) && kr(e);
|
|
345
298
|
}, "test$3");
|
|
346
|
-
function Yr(
|
|
347
|
-
return
|
|
299
|
+
function Yr(e) {
|
|
300
|
+
return e.nodeType === tn;
|
|
348
301
|
}
|
|
349
302
|
c(Yr, "nodeIsText");
|
|
350
|
-
function Ur(
|
|
351
|
-
return
|
|
303
|
+
function Ur(e) {
|
|
304
|
+
return e.nodeType === nn;
|
|
352
305
|
}
|
|
353
306
|
c(Ur, "nodeIsComment");
|
|
354
|
-
function
|
|
355
|
-
return
|
|
356
|
-
}
|
|
357
|
-
c(
|
|
358
|
-
var Wr = /* @__PURE__ */ c((
|
|
359
|
-
if (Yr(
|
|
360
|
-
return
|
|
361
|
-
if (Ur(
|
|
362
|
-
return Fr(
|
|
363
|
-
let i =
|
|
364
|
-
return ++r >
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
n
|
|
388
|
-
);
|
|
389
|
-
}, "serialize$3"), Vr = { serialize: Wr, test: zr }, qr = "@@__IMMUTABLE_ITERABLE__@@", Kr = "@@__IMMUTABLE_LIST__@@", Gr = "@@__IMMUTABLE_K\
|
|
390
|
-
EYED__@@", Hr = "@@__IMMUTABLE_MAP__@@", je = "@@__IMMUTABLE_ORDERED__@@", Jr = "@@__IMMUTABLE_RECORD__@@", Xr = "@@__IMMUTABLE_SEQ__@@", Zr = "\
|
|
391
|
-
@@__IMMUTABLE_SET__@@", Qr = "@@__IMMUTABLE_STACK__@@", bt = /* @__PURE__ */ c((t) => `Immutable.${t}`, "getImmutableName"), jt = /* @__PURE__ */ c(
|
|
392
|
-
(t) => `[${t}]`, "printAsLeaf"), Ct = " ", Be = "\u2026";
|
|
393
|
-
function vr(t, e, n, r, o, s, i) {
|
|
394
|
-
return ++r > e.maxDepth ? jt(bt(i)) : `${bt(i) + Ct}{${Ot(
|
|
395
|
-
t.entries(),
|
|
396
|
-
e,
|
|
397
|
-
n,
|
|
398
|
-
r,
|
|
399
|
-
o,
|
|
400
|
-
s
|
|
401
|
-
)}}`;
|
|
402
|
-
}
|
|
403
|
-
c(vr, "printImmutableEntries");
|
|
404
|
-
function to(t) {
|
|
405
|
-
let e = 0;
|
|
406
|
-
return {
|
|
407
|
-
next() {
|
|
408
|
-
if (e < t._keys.length) {
|
|
409
|
-
let n = t._keys[e++];
|
|
410
|
-
return { done: !1, value: [n, t.get(n)] };
|
|
411
|
-
}
|
|
412
|
-
return { done: !0, value: void 0 };
|
|
307
|
+
function et(e) {
|
|
308
|
+
return e.nodeType === rn;
|
|
309
|
+
}
|
|
310
|
+
c(et, "nodeIsFragment");
|
|
311
|
+
var Wr = /* @__PURE__ */ c((e, t, n, r, o, s) => {
|
|
312
|
+
if (Yr(e))
|
|
313
|
+
return en(e.data, t);
|
|
314
|
+
if (Ur(e))
|
|
315
|
+
return Fr(e.data, t);
|
|
316
|
+
let i = et(e) ? "DocumentFragment" : e.tagName.toLowerCase();
|
|
317
|
+
return ++r > t.maxDepth ? ct(i, t) : it(i, ot(et(e) ? [] : Array.from(e.attributes, (a) => a.name).sort(), et(e) ? {} : [...e.attributes].
|
|
318
|
+
reduce((a, l) => (a[l.name] = l.value, a), {}), t, n + t.indent, r, o, s), st(Array.prototype.slice.call(e.childNodes || e.children), t, n +
|
|
319
|
+
t.indent, r, o, s), t, n);
|
|
320
|
+
}, "serialize$3"), Vr = {
|
|
321
|
+
serialize: Wr,
|
|
322
|
+
test: zr
|
|
323
|
+
}, qr = "@@__IMMUTABLE_ITERABLE__@@", Kr = "@@__IMMUTABLE_LIST__@@", Gr = "@@__IMMUTABLE_KEYED__@@", Hr = "@@__IMMUTABLE_MAP__@@", jt = "@@_\
|
|
324
|
+
_IMMUTABLE_ORDERED__@@", Jr = "@@__IMMUTABLE_RECORD__@@", Xr = "@@__IMMUTABLE_SEQ__@@", Zr = "@@__IMMUTABLE_SET__@@", vr = "@@__IMMUTABLE_ST\
|
|
325
|
+
ACK__@@", be = /* @__PURE__ */ c((e) => `Immutable.${e}`, "getImmutableName"), je = /* @__PURE__ */ c((e) => `[${e}]`, "printAsLeaf"), Ce = "\
|
|
326
|
+
", Bt = "\u2026";
|
|
327
|
+
function Qr(e, t, n, r, o, s, i) {
|
|
328
|
+
return ++r > t.maxDepth ? je(be(i)) : `${be(i) + Ce}{${Oe(e.entries(), t, n, r, o, s)}}`;
|
|
329
|
+
}
|
|
330
|
+
c(Qr, "printImmutableEntries");
|
|
331
|
+
function eo(e) {
|
|
332
|
+
let t = 0;
|
|
333
|
+
return { next() {
|
|
334
|
+
if (t < e._keys.length) {
|
|
335
|
+
let n = e._keys[t++];
|
|
336
|
+
return {
|
|
337
|
+
done: !1,
|
|
338
|
+
value: [n, e.get(n)]
|
|
339
|
+
};
|
|
413
340
|
}
|
|
414
|
-
|
|
341
|
+
return {
|
|
342
|
+
done: !0,
|
|
343
|
+
value: void 0
|
|
344
|
+
};
|
|
345
|
+
} };
|
|
415
346
|
}
|
|
416
|
-
c(
|
|
417
|
-
function
|
|
418
|
-
let i =
|
|
419
|
-
return ++r >
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
)}}`;
|
|
427
|
-
}
|
|
428
|
-
c(eo, "printImmutableRecord");
|
|
429
|
-
function no(t, e, n, r, o, s) {
|
|
430
|
-
let i = bt("Seq");
|
|
431
|
-
return ++r > e.maxDepth ? jt(i) : t[Gr] ? `${i + Ct}{${// from Immutable collection of entries or from ECMAScript object
|
|
432
|
-
t._iter || t._object ? Ot(
|
|
433
|
-
t.entries(),
|
|
434
|
-
e,
|
|
435
|
-
n,
|
|
436
|
-
r,
|
|
437
|
-
o,
|
|
438
|
-
s
|
|
439
|
-
) : Be}}` : `${i + Ct}[${t._iter || t._array || t._collection || t._iterable ? ne(
|
|
440
|
-
t.values(),
|
|
441
|
-
e,
|
|
442
|
-
n,
|
|
443
|
-
r,
|
|
444
|
-
o,
|
|
445
|
-
s
|
|
446
|
-
) : Be}]`;
|
|
347
|
+
c(eo, "getRecordEntries");
|
|
348
|
+
function to(e, t, n, r, o, s) {
|
|
349
|
+
let i = be(e._name || "Record");
|
|
350
|
+
return ++r > t.maxDepth ? je(i) : `${i + Ce}{${Oe(eo(e), t, n, r, o, s)}}`;
|
|
351
|
+
}
|
|
352
|
+
c(to, "printImmutableRecord");
|
|
353
|
+
function no(e, t, n, r, o, s) {
|
|
354
|
+
let i = be("Seq");
|
|
355
|
+
return ++r > t.maxDepth ? je(i) : e[Gr] ? `${i + Ce}{${e._iter || e._object ? Oe(e.entries(), t, n, r, o, s) : Bt}}` : `${i + Ce}[${e._iter ||
|
|
356
|
+
e._array || e._collection || e._iterable ? nt(e.values(), t, n, r, o, s) : Bt}]`;
|
|
447
357
|
}
|
|
448
358
|
c(no, "printImmutableSeq");
|
|
449
|
-
function
|
|
450
|
-
return ++r >
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
}
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
t,
|
|
462
|
-
e,
|
|
463
|
-
n,
|
|
464
|
-
r,
|
|
465
|
-
o,
|
|
466
|
-
s,
|
|
467
|
-
t[je] ? "OrderedMap" : "Map"
|
|
468
|
-
) : t[Kr] ? ee(
|
|
469
|
-
t,
|
|
470
|
-
e,
|
|
471
|
-
n,
|
|
472
|
-
r,
|
|
473
|
-
o,
|
|
474
|
-
s,
|
|
475
|
-
"List"
|
|
476
|
-
) : t[Zr] ? ee(
|
|
477
|
-
t,
|
|
478
|
-
e,
|
|
479
|
-
n,
|
|
480
|
-
r,
|
|
481
|
-
o,
|
|
482
|
-
s,
|
|
483
|
-
t[je] ? "OrderedSet" : "Set"
|
|
484
|
-
) : t[Qr] ? ee(
|
|
485
|
-
t,
|
|
486
|
-
e,
|
|
487
|
-
n,
|
|
488
|
-
r,
|
|
489
|
-
o,
|
|
490
|
-
s,
|
|
491
|
-
"Stack"
|
|
492
|
-
) : t[Xr] ? no(t, e, n, r, o, s) : eo(t, e, n, r, o, s), "serialize$2"), oo = /* @__PURE__ */ c((t) => t && (t[qr] === !0 || t[Jr] === !0), "\
|
|
493
|
-
test$2"), so = { serialize: ro, test: oo };
|
|
494
|
-
function on(t) {
|
|
495
|
-
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
359
|
+
function tt(e, t, n, r, o, s, i) {
|
|
360
|
+
return ++r > t.maxDepth ? je(be(i)) : `${be(i) + Ce}[${nt(e.values(), t, n, r, o, s)}]`;
|
|
361
|
+
}
|
|
362
|
+
c(tt, "printImmutableValues");
|
|
363
|
+
var ro = /* @__PURE__ */ c((e, t, n, r, o, s) => e[Hr] ? Qr(e, t, n, r, o, s, e[jt] ? "OrderedMap" : "Map") : e[Kr] ? tt(e, t, n, r, o, s, "\
|
|
364
|
+
List") : e[Zr] ? tt(e, t, n, r, o, s, e[jt] ? "OrderedSet" : "Set") : e[vr] ? tt(e, t, n, r, o, s, "Stack") : e[Xr] ? no(e, t, n, r, o, s) :
|
|
365
|
+
to(e, t, n, r, o, s), "serialize$2"), oo = /* @__PURE__ */ c((e) => e && (e[qr] === !0 || e[Jr] === !0), "test$2"), so = {
|
|
366
|
+
serialize: ro,
|
|
367
|
+
test: oo
|
|
368
|
+
};
|
|
369
|
+
function on(e) {
|
|
370
|
+
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
496
371
|
}
|
|
497
372
|
c(on, "getDefaultExportFromCjs");
|
|
498
|
-
var
|
|
499
|
-
var
|
|
373
|
+
var Me = { exports: {} }, N = {};
|
|
374
|
+
var kt;
|
|
500
375
|
function io() {
|
|
501
|
-
if (
|
|
502
|
-
|
|
503
|
-
var
|
|
376
|
+
if (kt) return N;
|
|
377
|
+
kt = 1;
|
|
378
|
+
var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.\
|
|
504
379
|
strict_mode"), o = Symbol.for("react.profiler"), s = Symbol.for("react.consumer"), i = Symbol.for("react.context"), a = Symbol.for("react.fo\
|
|
505
380
|
rward_ref"), l = Symbol.for("react.suspense"), m = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), f = Symbol.for("react.la\
|
|
506
|
-
zy"),
|
|
381
|
+
zy"), b = Symbol.for("react.offscreen"), y = Symbol.for("react.client.reference");
|
|
507
382
|
function g(u) {
|
|
508
383
|
if (typeof u == "object" && u !== null) {
|
|
509
384
|
var h = u.$$typeof;
|
|
510
385
|
switch (h) {
|
|
511
|
-
case
|
|
386
|
+
case e:
|
|
512
387
|
switch (u = u.type, u) {
|
|
513
388
|
case n:
|
|
514
389
|
case o:
|
|
@@ -529,18 +404,18 @@ zy"), S = Symbol.for("react.offscreen"), y = Symbol.for("react.client.reference"
|
|
|
529
404
|
return h;
|
|
530
405
|
}
|
|
531
406
|
}
|
|
532
|
-
case
|
|
407
|
+
case t:
|
|
533
408
|
return h;
|
|
534
409
|
}
|
|
535
410
|
}
|
|
536
411
|
}
|
|
537
|
-
return c(g, "typeOf"), N.ContextConsumer = s, N.ContextProvider = i, N.Element =
|
|
538
|
-
p, N.Portal =
|
|
412
|
+
return c(g, "typeOf"), N.ContextConsumer = s, N.ContextProvider = i, N.Element = e, N.ForwardRef = a, N.Fragment = n, N.Lazy = f, N.Memo =
|
|
413
|
+
p, N.Portal = t, N.Profiler = o, N.StrictMode = r, N.Suspense = l, N.SuspenseList = m, N.isContextConsumer = function(u) {
|
|
539
414
|
return g(u) === s;
|
|
540
415
|
}, N.isContextProvider = function(u) {
|
|
541
416
|
return g(u) === i;
|
|
542
417
|
}, N.isElement = function(u) {
|
|
543
|
-
return typeof u == "object" && u !== null && u.$$typeof ===
|
|
418
|
+
return typeof u == "object" && u !== null && u.$$typeof === e;
|
|
544
419
|
}, N.isForwardRef = function(u) {
|
|
545
420
|
return g(u) === a;
|
|
546
421
|
}, N.isFragment = function(u) {
|
|
@@ -550,7 +425,7 @@ zy"), S = Symbol.for("react.offscreen"), y = Symbol.for("react.client.reference"
|
|
|
550
425
|
}, N.isMemo = function(u) {
|
|
551
426
|
return g(u) === p;
|
|
552
427
|
}, N.isPortal = function(u) {
|
|
553
|
-
return g(u) ===
|
|
428
|
+
return g(u) === t;
|
|
554
429
|
}, N.isProfiler = function(u) {
|
|
555
430
|
return g(u) === o;
|
|
556
431
|
}, N.isStrictMode = function(u) {
|
|
@@ -560,21 +435,21 @@ zy"), S = Symbol.for("react.offscreen"), y = Symbol.for("react.client.reference"
|
|
|
560
435
|
}, N.isSuspenseList = function(u) {
|
|
561
436
|
return g(u) === m;
|
|
562
437
|
}, N.isValidElementType = function(u) {
|
|
563
|
-
return typeof u == "string" || typeof u == "function" || u === n || u === o || u === r || u === l || u === m || u ===
|
|
438
|
+
return typeof u == "string" || typeof u == "function" || u === n || u === o || u === r || u === l || u === m || u === b || typeof u == "\
|
|
564
439
|
object" && u !== null && (u.$$typeof === f || u.$$typeof === p || u.$$typeof === i || u.$$typeof === s || u.$$typeof === a || u.$$typeof ===
|
|
565
440
|
y || u.getModuleId !== void 0);
|
|
566
441
|
}, N.typeOf = g, N;
|
|
567
442
|
}
|
|
568
443
|
c(io, "requireReactIs_production");
|
|
569
444
|
var P = {};
|
|
570
|
-
var
|
|
445
|
+
var zt;
|
|
571
446
|
function co() {
|
|
572
|
-
return
|
|
573
|
-
function
|
|
447
|
+
return zt || (zt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
448
|
+
function e(u) {
|
|
574
449
|
if (typeof u == "object" && u !== null) {
|
|
575
450
|
var h = u.$$typeof;
|
|
576
451
|
switch (h) {
|
|
577
|
-
case
|
|
452
|
+
case t:
|
|
578
453
|
switch (u = u.type, u) {
|
|
579
454
|
case r:
|
|
580
455
|
case s:
|
|
@@ -586,7 +461,7 @@ function co() {
|
|
|
586
461
|
switch (u = u && u.$$typeof, u) {
|
|
587
462
|
case a:
|
|
588
463
|
case l:
|
|
589
|
-
case
|
|
464
|
+
case b:
|
|
590
465
|
case f:
|
|
591
466
|
return u;
|
|
592
467
|
case i:
|
|
@@ -600,67 +475,67 @@ function co() {
|
|
|
600
475
|
}
|
|
601
476
|
}
|
|
602
477
|
}
|
|
603
|
-
c(
|
|
604
|
-
var
|
|
478
|
+
c(e, "typeOf");
|
|
479
|
+
var t = Symbol.for("react.transitional.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), o = Symbol.for("reac\
|
|
605
480
|
t.strict_mode"), s = Symbol.for("react.profiler"), i = Symbol.for("react.consumer"), a = Symbol.for("react.context"), l = Symbol.for("react.\
|
|
606
|
-
forward_ref"), m = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"),
|
|
481
|
+
forward_ref"), m = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), b = Symbol.for("react.\
|
|
607
482
|
lazy"), y = Symbol.for("react.offscreen"), g = Symbol.for("react.client.reference");
|
|
608
|
-
P.ContextConsumer = i, P.ContextProvider = a, P.Element =
|
|
483
|
+
P.ContextConsumer = i, P.ContextProvider = a, P.Element = t, P.ForwardRef = l, P.Fragment = r, P.Lazy = b, P.Memo = f, P.Portal = n, P.Profiler =
|
|
609
484
|
s, P.StrictMode = o, P.Suspense = m, P.SuspenseList = p, P.isContextConsumer = function(u) {
|
|
610
|
-
return
|
|
485
|
+
return e(u) === i;
|
|
611
486
|
}, P.isContextProvider = function(u) {
|
|
612
|
-
return
|
|
487
|
+
return e(u) === a;
|
|
613
488
|
}, P.isElement = function(u) {
|
|
614
|
-
return typeof u == "object" && u !== null && u.$$typeof ===
|
|
489
|
+
return typeof u == "object" && u !== null && u.$$typeof === t;
|
|
615
490
|
}, P.isForwardRef = function(u) {
|
|
616
|
-
return
|
|
491
|
+
return e(u) === l;
|
|
617
492
|
}, P.isFragment = function(u) {
|
|
618
|
-
return
|
|
493
|
+
return e(u) === r;
|
|
619
494
|
}, P.isLazy = function(u) {
|
|
620
|
-
return
|
|
495
|
+
return e(u) === b;
|
|
621
496
|
}, P.isMemo = function(u) {
|
|
622
|
-
return
|
|
497
|
+
return e(u) === f;
|
|
623
498
|
}, P.isPortal = function(u) {
|
|
624
|
-
return
|
|
499
|
+
return e(u) === n;
|
|
625
500
|
}, P.isProfiler = function(u) {
|
|
626
|
-
return
|
|
501
|
+
return e(u) === s;
|
|
627
502
|
}, P.isStrictMode = function(u) {
|
|
628
|
-
return
|
|
503
|
+
return e(u) === o;
|
|
629
504
|
}, P.isSuspense = function(u) {
|
|
630
|
-
return
|
|
505
|
+
return e(u) === m;
|
|
631
506
|
}, P.isSuspenseList = function(u) {
|
|
632
|
-
return
|
|
507
|
+
return e(u) === p;
|
|
633
508
|
}, P.isValidElementType = function(u) {
|
|
634
509
|
return typeof u == "string" || typeof u == "function" || u === r || u === s || u === o || u === m || u === p || u === y || typeof u ==
|
|
635
|
-
"object" && u !== null && (u.$$typeof ===
|
|
510
|
+
"object" && u !== null && (u.$$typeof === b || u.$$typeof === f || u.$$typeof === a || u.$$typeof === i || u.$$typeof === l || u.$$typeof ===
|
|
636
511
|
g || u.getModuleId !== void 0);
|
|
637
|
-
}, P.typeOf =
|
|
512
|
+
}, P.typeOf = e;
|
|
638
513
|
}()), P;
|
|
639
514
|
}
|
|
640
515
|
c(co, "requireReactIs_development$1");
|
|
641
|
-
var
|
|
516
|
+
var Yt;
|
|
642
517
|
function uo() {
|
|
643
|
-
return
|
|
518
|
+
return Yt || (Yt = 1, process.env.NODE_ENV === "production" ? Me.exports = io() : Me.exports = co()), Me.exports;
|
|
644
519
|
}
|
|
645
520
|
c(uo, "requireReactIs$1");
|
|
646
|
-
var sn =
|
|
521
|
+
var sn = uo(), lo = /* @__PURE__ */ on(sn), ao = /* @__PURE__ */ Zt({
|
|
647
522
|
__proto__: null,
|
|
648
523
|
default: lo
|
|
649
|
-
}, [sn]),
|
|
650
|
-
var
|
|
524
|
+
}, [sn]), Le = { exports: {} }, w = {};
|
|
525
|
+
var Ut;
|
|
651
526
|
function fo() {
|
|
652
|
-
if (
|
|
653
|
-
|
|
654
|
-
var
|
|
527
|
+
if (Ut) return w;
|
|
528
|
+
Ut = 1;
|
|
529
|
+
var e = Symbol.for("react.element"), t = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"),
|
|
655
530
|
o = Symbol.for("react.profiler"), s = Symbol.for("react.provider"), i = Symbol.for("react.context"), a = Symbol.for("react.server_context"),
|
|
656
531
|
l = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"),
|
|
657
|
-
|
|
532
|
+
b = Symbol.for("react.lazy"), y = Symbol.for("react.offscreen"), g;
|
|
658
533
|
g = Symbol.for("react.module.reference");
|
|
659
534
|
function u(h) {
|
|
660
535
|
if (typeof h == "object" && h !== null) {
|
|
661
|
-
var
|
|
662
|
-
switch (
|
|
663
|
-
case
|
|
536
|
+
var S = h.$$typeof;
|
|
537
|
+
switch (S) {
|
|
538
|
+
case e:
|
|
664
539
|
switch (h = h.type, h) {
|
|
665
540
|
case n:
|
|
666
541
|
case o:
|
|
@@ -673,21 +548,21 @@ function fo() {
|
|
|
673
548
|
case a:
|
|
674
549
|
case i:
|
|
675
550
|
case l:
|
|
676
|
-
case
|
|
551
|
+
case b:
|
|
677
552
|
case f:
|
|
678
553
|
case s:
|
|
679
554
|
return h;
|
|
680
555
|
default:
|
|
681
|
-
return
|
|
556
|
+
return S;
|
|
682
557
|
}
|
|
683
558
|
}
|
|
684
|
-
case
|
|
685
|
-
return
|
|
559
|
+
case t:
|
|
560
|
+
return S;
|
|
686
561
|
}
|
|
687
562
|
}
|
|
688
563
|
}
|
|
689
|
-
return c(u, "v"), w.ContextConsumer = i, w.ContextProvider = s, w.Element =
|
|
690
|
-
Portal =
|
|
564
|
+
return c(u, "v"), w.ContextConsumer = i, w.ContextProvider = s, w.Element = e, w.ForwardRef = l, w.Fragment = n, w.Lazy = b, w.Memo = f, w.
|
|
565
|
+
Portal = t, w.Profiler = o, w.StrictMode = r, w.Suspense = m, w.SuspenseList = p, w.isAsyncMode = function() {
|
|
691
566
|
return !1;
|
|
692
567
|
}, w.isConcurrentMode = function() {
|
|
693
568
|
return !1;
|
|
@@ -696,17 +571,17 @@ function fo() {
|
|
|
696
571
|
}, w.isContextProvider = function(h) {
|
|
697
572
|
return u(h) === s;
|
|
698
573
|
}, w.isElement = function(h) {
|
|
699
|
-
return typeof h == "object" && h !== null && h.$$typeof ===
|
|
574
|
+
return typeof h == "object" && h !== null && h.$$typeof === e;
|
|
700
575
|
}, w.isForwardRef = function(h) {
|
|
701
576
|
return u(h) === l;
|
|
702
577
|
}, w.isFragment = function(h) {
|
|
703
578
|
return u(h) === n;
|
|
704
579
|
}, w.isLazy = function(h) {
|
|
705
|
-
return u(h) ===
|
|
580
|
+
return u(h) === b;
|
|
706
581
|
}, w.isMemo = function(h) {
|
|
707
582
|
return u(h) === f;
|
|
708
583
|
}, w.isPortal = function(h) {
|
|
709
|
-
return u(h) ===
|
|
584
|
+
return u(h) === t;
|
|
710
585
|
}, w.isProfiler = function(h) {
|
|
711
586
|
return u(h) === o;
|
|
712
587
|
}, w.isStrictMode = function(h) {
|
|
@@ -717,23 +592,23 @@ function fo() {
|
|
|
717
592
|
return u(h) === p;
|
|
718
593
|
}, w.isValidElementType = function(h) {
|
|
719
594
|
return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === m || h === p || h === y || typeof h == "\
|
|
720
|
-
object" && h !== null && (h.$$typeof ===
|
|
595
|
+
object" && h !== null && (h.$$typeof === b || h.$$typeof === f || h.$$typeof === s || h.$$typeof === i || h.$$typeof === l || h.$$typeof ===
|
|
721
596
|
g || h.getModuleId !== void 0);
|
|
722
597
|
}, w.typeOf = u, w;
|
|
723
598
|
}
|
|
724
599
|
c(fo, "requireReactIs_production_min");
|
|
725
600
|
var A = {};
|
|
726
|
-
var
|
|
601
|
+
var Wt;
|
|
727
602
|
function mo() {
|
|
728
|
-
return
|
|
729
|
-
var
|
|
603
|
+
return Wt || (Wt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
604
|
+
var e = Symbol.for("react.element"), t = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"),
|
|
730
605
|
o = Symbol.for("react.profiler"), s = Symbol.for("react.provider"), i = Symbol.for("react.context"), a = Symbol.for("react.server_contex\
|
|
731
606
|
t"), l = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.mem\
|
|
732
|
-
o"),
|
|
607
|
+
o"), b = Symbol.for("react.lazy"), y = Symbol.for("react.offscreen"), g = !1, u = !1, h = !1, S = !1, _ = !1, O;
|
|
733
608
|
O = Symbol.for("react.module.reference");
|
|
734
609
|
function d(C) {
|
|
735
|
-
return !!(typeof C == "string" || typeof C == "function" || C === n || C === o || _ || C === r || C === m || C === p ||
|
|
736
|
-
g || u || h || typeof C == "object" && C !== null && (C.$$typeof ===
|
|
610
|
+
return !!(typeof C == "string" || typeof C == "function" || C === n || C === o || _ || C === r || C === m || C === p || S || C === y ||
|
|
611
|
+
g || u || h || typeof C == "object" && C !== null && (C.$$typeof === b || C.$$typeof === f || C.$$typeof === s || C.$$typeof === i || C.
|
|
737
612
|
$$typeof === l || // This needs to include all possible module reference object
|
|
738
613
|
// types supported by any Flight configuration anywhere since
|
|
739
614
|
// we don't know which Flight build this will end up being used
|
|
@@ -743,46 +618,46 @@ o"), S = Symbol.for("react.lazy"), y = Symbol.for("react.offscreen"), g = !1, u
|
|
|
743
618
|
c(d, "isValidElementType");
|
|
744
619
|
function E(C) {
|
|
745
620
|
if (typeof C == "object" && C !== null) {
|
|
746
|
-
var
|
|
747
|
-
switch (
|
|
748
|
-
case
|
|
749
|
-
var
|
|
750
|
-
switch (
|
|
621
|
+
var ve = C.$$typeof;
|
|
622
|
+
switch (ve) {
|
|
623
|
+
case e:
|
|
624
|
+
var Ne = C.type;
|
|
625
|
+
switch (Ne) {
|
|
751
626
|
case n:
|
|
752
627
|
case o:
|
|
753
628
|
case r:
|
|
754
629
|
case m:
|
|
755
630
|
case p:
|
|
756
|
-
return
|
|
631
|
+
return Ne;
|
|
757
632
|
default:
|
|
758
|
-
var
|
|
759
|
-
switch (
|
|
633
|
+
var Lt = Ne && Ne.$$typeof;
|
|
634
|
+
switch (Lt) {
|
|
760
635
|
case a:
|
|
761
636
|
case i:
|
|
762
637
|
case l:
|
|
763
|
-
case
|
|
638
|
+
case b:
|
|
764
639
|
case f:
|
|
765
640
|
case s:
|
|
766
|
-
return
|
|
641
|
+
return Lt;
|
|
767
642
|
default:
|
|
768
|
-
return
|
|
643
|
+
return ve;
|
|
769
644
|
}
|
|
770
645
|
}
|
|
771
|
-
case
|
|
772
|
-
return
|
|
646
|
+
case t:
|
|
647
|
+
return ve;
|
|
773
648
|
}
|
|
774
649
|
}
|
|
775
650
|
}
|
|
776
651
|
c(E, "typeOf");
|
|
777
|
-
var $ = i, T = s, R =
|
|
652
|
+
var $ = i, T = s, R = e, J = l, te = n, L = b, z = f, X = t, V = o, M = r, F = m, D = p, Z = !1, B = !1;
|
|
778
653
|
function K(C) {
|
|
779
654
|
return Z || (Z = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1;
|
|
780
655
|
}
|
|
781
656
|
c(K, "isAsyncMode");
|
|
782
|
-
function
|
|
657
|
+
function se(C) {
|
|
783
658
|
return B || (B = !0, console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")), !1;
|
|
784
659
|
}
|
|
785
|
-
c(
|
|
660
|
+
c(se, "isConcurrentMode");
|
|
786
661
|
function G(C) {
|
|
787
662
|
return E(C) === i;
|
|
788
663
|
}
|
|
@@ -791,58 +666,58 @@ o"), S = Symbol.for("react.lazy"), y = Symbol.for("react.offscreen"), g = !1, u
|
|
|
791
666
|
return E(C) === s;
|
|
792
667
|
}
|
|
793
668
|
c(H, "isContextProvider");
|
|
794
|
-
function
|
|
795
|
-
return typeof C == "object" && C !== null && C.$$typeof ===
|
|
669
|
+
function ce(C) {
|
|
670
|
+
return typeof C == "object" && C !== null && C.$$typeof === e;
|
|
796
671
|
}
|
|
797
|
-
c(
|
|
798
|
-
function
|
|
672
|
+
c(ce, "isElement");
|
|
673
|
+
function v(C) {
|
|
799
674
|
return E(C) === l;
|
|
800
675
|
}
|
|
801
|
-
c(
|
|
676
|
+
c(v, "isForwardRef");
|
|
802
677
|
function q(C) {
|
|
803
678
|
return E(C) === n;
|
|
804
679
|
}
|
|
805
680
|
c(q, "isFragment");
|
|
806
|
-
function
|
|
807
|
-
return E(C) ===
|
|
681
|
+
function ie(C) {
|
|
682
|
+
return E(C) === b;
|
|
808
683
|
}
|
|
809
|
-
c(
|
|
810
|
-
function
|
|
684
|
+
c(ie, "isLazy");
|
|
685
|
+
function de(C) {
|
|
811
686
|
return E(C) === f;
|
|
812
687
|
}
|
|
813
|
-
c(
|
|
814
|
-
function
|
|
815
|
-
return E(C) ===
|
|
688
|
+
c(de, "isMemo");
|
|
689
|
+
function ae(C) {
|
|
690
|
+
return E(C) === t;
|
|
816
691
|
}
|
|
817
|
-
c(
|
|
818
|
-
function
|
|
692
|
+
c(ae, "isPortal");
|
|
693
|
+
function Te(C) {
|
|
819
694
|
return E(C) === o;
|
|
820
695
|
}
|
|
821
|
-
c(
|
|
822
|
-
function
|
|
696
|
+
c(Te, "isProfiler");
|
|
697
|
+
function Ae(C) {
|
|
823
698
|
return E(C) === r;
|
|
824
699
|
}
|
|
825
|
-
c(
|
|
826
|
-
function
|
|
700
|
+
c(Ae, "isStrictMode");
|
|
701
|
+
function Re(C) {
|
|
827
702
|
return E(C) === m;
|
|
828
703
|
}
|
|
829
|
-
c(
|
|
704
|
+
c(Re, "isSuspense");
|
|
830
705
|
function pr(C) {
|
|
831
706
|
return E(C) === p;
|
|
832
707
|
}
|
|
833
|
-
c(pr, "isSuspenseList"), A.ContextConsumer = $, A.ContextProvider = T, A.Element = R, A.ForwardRef = J, A.Fragment =
|
|
834
|
-
z, A.Portal = X, A.Profiler = V, A.StrictMode = M, A.Suspense = F, A.SuspenseList = D, A.isAsyncMode = K, A.isConcurrentMode =
|
|
835
|
-
G, A.isContextProvider = H, A.isElement =
|
|
836
|
-
|
|
708
|
+
c(pr, "isSuspenseList"), A.ContextConsumer = $, A.ContextProvider = T, A.Element = R, A.ForwardRef = J, A.Fragment = te, A.Lazy = L, A.Memo =
|
|
709
|
+
z, A.Portal = X, A.Profiler = V, A.StrictMode = M, A.Suspense = F, A.SuspenseList = D, A.isAsyncMode = K, A.isConcurrentMode = se, A.isContextConsumer =
|
|
710
|
+
G, A.isContextProvider = H, A.isElement = ce, A.isForwardRef = v, A.isFragment = q, A.isLazy = ie, A.isMemo = de, A.isPortal = ae, A.isProfiler =
|
|
711
|
+
Te, A.isStrictMode = Ae, A.isSuspense = Re, A.isSuspenseList = pr, A.isValidElementType = d, A.typeOf = E;
|
|
837
712
|
}()), A;
|
|
838
713
|
}
|
|
839
714
|
c(mo, "requireReactIs_development");
|
|
840
|
-
var
|
|
715
|
+
var Vt;
|
|
841
716
|
function po() {
|
|
842
|
-
return
|
|
717
|
+
return Vt || (Vt = 1, process.env.NODE_ENV === "production" ? Le.exports = fo() : Le.exports = mo()), Le.exports;
|
|
843
718
|
}
|
|
844
719
|
c(po, "requireReactIs");
|
|
845
|
-
var cn = po(), go = /* @__PURE__ */ on(cn), ho = /* @__PURE__ */
|
|
720
|
+
var cn = po(), go = /* @__PURE__ */ on(cn), ho = /* @__PURE__ */ Zt({
|
|
846
721
|
__proto__: null,
|
|
847
722
|
default: go
|
|
848
723
|
}, [cn]), yo = [
|
|
@@ -861,302 +736,213 @@ var cn = po(), go = /* @__PURE__ */ on(cn), ho = /* @__PURE__ */ Ze({
|
|
|
861
736
|
"isSuspense",
|
|
862
737
|
"isSuspenseList",
|
|
863
738
|
"isValidElementType"
|
|
864
|
-
],
|
|
865
|
-
|
|
866
|
-
)
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
else t != null && t !== !1 && t !== "" && e.push(t);
|
|
872
|
-
return e;
|
|
739
|
+
], me = Object.fromEntries(yo.map((e) => [e, (t) => ho[e](t) || ao[e](t)]));
|
|
740
|
+
function un(e, t = []) {
|
|
741
|
+
if (Array.isArray(e))
|
|
742
|
+
for (let n of e)
|
|
743
|
+
un(n, t);
|
|
744
|
+
else e != null && e !== !1 && e !== "" && t.push(e);
|
|
745
|
+
return t;
|
|
873
746
|
}
|
|
874
747
|
c(un, "getChildren");
|
|
875
|
-
function
|
|
876
|
-
let
|
|
877
|
-
if (typeof
|
|
878
|
-
return
|
|
879
|
-
if (typeof
|
|
880
|
-
return
|
|
881
|
-
if (
|
|
748
|
+
function qt(e) {
|
|
749
|
+
let t = e.type;
|
|
750
|
+
if (typeof t == "string")
|
|
751
|
+
return t;
|
|
752
|
+
if (typeof t == "function")
|
|
753
|
+
return t.displayName || t.name || "Unknown";
|
|
754
|
+
if (me.isFragment(e))
|
|
882
755
|
return "React.Fragment";
|
|
883
|
-
if (
|
|
756
|
+
if (me.isSuspense(e))
|
|
884
757
|
return "React.Suspense";
|
|
885
|
-
if (typeof
|
|
886
|
-
if (
|
|
758
|
+
if (typeof t == "object" && t !== null) {
|
|
759
|
+
if (me.isContextProvider(e))
|
|
887
760
|
return "Context.Provider";
|
|
888
|
-
if (
|
|
761
|
+
if (me.isContextConsumer(e))
|
|
889
762
|
return "Context.Consumer";
|
|
890
|
-
if (
|
|
891
|
-
if (
|
|
892
|
-
return
|
|
893
|
-
let n =
|
|
763
|
+
if (me.isForwardRef(e)) {
|
|
764
|
+
if (t.displayName)
|
|
765
|
+
return t.displayName;
|
|
766
|
+
let n = t.render.displayName || t.render.name || "";
|
|
894
767
|
return n === "" ? "ForwardRef" : `ForwardRef(${n})`;
|
|
895
768
|
}
|
|
896
|
-
if (
|
|
897
|
-
let n =
|
|
769
|
+
if (me.isMemo(e)) {
|
|
770
|
+
let n = t.displayName || t.type.displayName || t.type.name || "";
|
|
898
771
|
return n === "" ? "Memo" : `Memo(${n})`;
|
|
899
772
|
}
|
|
900
773
|
}
|
|
901
774
|
return "UNDEFINED";
|
|
902
775
|
}
|
|
903
|
-
c(
|
|
904
|
-
function bo(
|
|
905
|
-
let { props:
|
|
906
|
-
return Object.keys(
|
|
776
|
+
c(qt, "getType");
|
|
777
|
+
function bo(e) {
|
|
778
|
+
let { props: t } = e;
|
|
779
|
+
return Object.keys(t).filter((n) => n !== "children" && t[n] !== void 0).sort();
|
|
907
780
|
}
|
|
908
781
|
c(bo, "getPropKeys$1");
|
|
909
|
-
var So = /* @__PURE__ */ c((
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
s
|
|
919
|
-
),
|
|
920
|
-
se(
|
|
921
|
-
un(t.props.children),
|
|
922
|
-
e,
|
|
923
|
-
n + e.indent,
|
|
924
|
-
r,
|
|
925
|
-
o,
|
|
926
|
-
s
|
|
927
|
-
),
|
|
928
|
-
e,
|
|
929
|
-
n
|
|
930
|
-
), "serialize$1"), Eo = /* @__PURE__ */ c((t) => t != null && mt.isElement(t), "test$1"), _o = { serialize: So, test: Eo }, To = typeof Symbol ==
|
|
931
|
-
"function" && Symbol.for ? Symbol.for("react.test.json") : 245830487;
|
|
932
|
-
function Co(t) {
|
|
933
|
-
let { props: e } = t;
|
|
934
|
-
return e ? Object.keys(e).filter((n) => e[n] !== void 0).sort() : [];
|
|
782
|
+
var So = /* @__PURE__ */ c((e, t, n, r, o, s) => ++r > t.maxDepth ? ct(qt(e), t) : it(qt(e), ot(bo(e), e.props, t, n + t.indent, r, o, s), st(
|
|
783
|
+
un(e.props.children), t, n + t.indent, r, o, s), t, n), "serialize$1"), Eo = /* @__PURE__ */ c((e) => e != null && me.isElement(e), "test$1"),
|
|
784
|
+
_o = {
|
|
785
|
+
serialize: So,
|
|
786
|
+
test: Eo
|
|
787
|
+
}, To = typeof Symbol == "function" && Symbol.for ? Symbol.for("react.test.json") : 245830487;
|
|
788
|
+
function Co(e) {
|
|
789
|
+
let { props: t } = e;
|
|
790
|
+
return t ? Object.keys(t).filter((n) => t[n] !== void 0).sort() : [];
|
|
935
791
|
}
|
|
936
792
|
c(Co, "getPropKeys");
|
|
937
|
-
var Oo = /* @__PURE__ */ c((
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
t.children,
|
|
950
|
-
e,
|
|
951
|
-
n + e.indent,
|
|
952
|
-
r,
|
|
953
|
-
o,
|
|
954
|
-
s
|
|
955
|
-
) : "",
|
|
956
|
-
e,
|
|
957
|
-
n
|
|
958
|
-
), "serialize"), $o = /* @__PURE__ */ c((t) => t && t.$$typeof === To, "test"), wo = { serialize: Oo, test: $o }, ln = Object.prototype.toString,
|
|
959
|
-
Ao = Date.prototype.toISOString, Ro = Error.prototype.toString, Ke = RegExp.prototype.toString;
|
|
960
|
-
function xt(t) {
|
|
961
|
-
return typeof t.constructor == "function" && t.constructor.name || "Object";
|
|
962
|
-
}
|
|
963
|
-
c(xt, "getConstructorName");
|
|
964
|
-
function No(t) {
|
|
965
|
-
return typeof window < "u" && t === window;
|
|
793
|
+
var Oo = /* @__PURE__ */ c((e, t, n, r, o, s) => ++r > t.maxDepth ? ct(e.type, t) : it(e.type, e.props ? ot(Co(e), e.props, t, n + t.indent,
|
|
794
|
+
r, o, s) : "", e.children ? st(e.children, t, n + t.indent, r, o, s) : "", t, n), "serialize"), $o = /* @__PURE__ */ c((e) => e && e.$$typeof ===
|
|
795
|
+
To, "test"), wo = {
|
|
796
|
+
serialize: Oo,
|
|
797
|
+
test: $o
|
|
798
|
+
}, ln = Object.prototype.toString, Ao = Date.prototype.toISOString, Ro = Error.prototype.toString, Kt = RegExp.prototype.toString;
|
|
799
|
+
function xe(e) {
|
|
800
|
+
return typeof e.constructor == "function" && e.constructor.name || "Object";
|
|
801
|
+
}
|
|
802
|
+
c(xe, "getConstructorName");
|
|
803
|
+
function No(e) {
|
|
804
|
+
return typeof window < "u" && e === window;
|
|
966
805
|
}
|
|
967
806
|
c(No, "isWindow");
|
|
968
|
-
var Po = /^Symbol\((.*)\)(.*)$/, Io = /\n/g,
|
|
807
|
+
var Po = /^Symbol\((.*)\)(.*)$/, Io = /\n/g, De = class extends Error {
|
|
969
808
|
static {
|
|
970
809
|
c(this, "PrettyFormatPluginError");
|
|
971
810
|
}
|
|
972
|
-
constructor(
|
|
973
|
-
super(
|
|
811
|
+
constructor(t, n) {
|
|
812
|
+
super(t), this.stack = n, this.name = this.constructor.name;
|
|
974
813
|
}
|
|
975
814
|
};
|
|
976
|
-
function Mo(
|
|
977
|
-
return
|
|
978
|
-
ect Float64Array]" ||
|
|
979
|
-
|
|
815
|
+
function Mo(e) {
|
|
816
|
+
return e === "[object Array]" || e === "[object ArrayBuffer]" || e === "[object DataView]" || e === "[object Float32Array]" || e === "[obj\
|
|
817
|
+
ect Float64Array]" || e === "[object Int8Array]" || e === "[object Int16Array]" || e === "[object Int32Array]" || e === "[object Uint8Array]" ||
|
|
818
|
+
e === "[object Uint8ClampedArray]" || e === "[object Uint16Array]" || e === "[object Uint32Array]";
|
|
980
819
|
}
|
|
981
820
|
c(Mo, "isToStringedArrayType");
|
|
982
|
-
function Lo(
|
|
983
|
-
return Object.is(
|
|
821
|
+
function Lo(e) {
|
|
822
|
+
return Object.is(e, -0) ? "-0" : String(e);
|
|
984
823
|
}
|
|
985
824
|
c(Lo, "printNumber");
|
|
986
|
-
function xo(
|
|
987
|
-
return `${
|
|
825
|
+
function xo(e) {
|
|
826
|
+
return `${e}n`;
|
|
988
827
|
}
|
|
989
828
|
c(xo, "printBigInt");
|
|
990
|
-
function
|
|
991
|
-
return
|
|
992
|
-
}
|
|
993
|
-
c(
|
|
994
|
-
function
|
|
995
|
-
return String(
|
|
996
|
-
}
|
|
997
|
-
c(
|
|
998
|
-
function
|
|
999
|
-
return `[${Ro.call(
|
|
1000
|
-
}
|
|
1001
|
-
c(
|
|
1002
|
-
function an(
|
|
1003
|
-
if (
|
|
1004
|
-
return `${
|
|
1005
|
-
if (
|
|
829
|
+
function Gt(e, t) {
|
|
830
|
+
return t ? `[Function ${e.name || "anonymous"}]` : "[Function]";
|
|
831
|
+
}
|
|
832
|
+
c(Gt, "printFunction");
|
|
833
|
+
function Ht(e) {
|
|
834
|
+
return String(e).replace(Po, "Symbol($1)");
|
|
835
|
+
}
|
|
836
|
+
c(Ht, "printSymbol");
|
|
837
|
+
function Jt(e) {
|
|
838
|
+
return `[${Ro.call(e)}]`;
|
|
839
|
+
}
|
|
840
|
+
c(Jt, "printError");
|
|
841
|
+
function an(e, t, n, r) {
|
|
842
|
+
if (e === !0 || e === !1)
|
|
843
|
+
return `${e}`;
|
|
844
|
+
if (e === void 0)
|
|
1006
845
|
return "undefined";
|
|
1007
|
-
if (
|
|
846
|
+
if (e === null)
|
|
1008
847
|
return "null";
|
|
1009
|
-
let o = typeof
|
|
848
|
+
let o = typeof e;
|
|
1010
849
|
if (o === "number")
|
|
1011
|
-
return Lo(
|
|
850
|
+
return Lo(e);
|
|
1012
851
|
if (o === "bigint")
|
|
1013
|
-
return xo(
|
|
852
|
+
return xo(e);
|
|
1014
853
|
if (o === "string")
|
|
1015
|
-
return r ? `"${
|
|
854
|
+
return r ? `"${e.replaceAll(/"|\\/g, "\\$&")}"` : `"${e}"`;
|
|
1016
855
|
if (o === "function")
|
|
1017
|
-
return
|
|
856
|
+
return Gt(e, t);
|
|
1018
857
|
if (o === "symbol")
|
|
1019
|
-
return
|
|
1020
|
-
let s = ln.call(
|
|
858
|
+
return Ht(e);
|
|
859
|
+
let s = ln.call(e);
|
|
1021
860
|
return s === "[object WeakMap]" ? "WeakMap {}" : s === "[object WeakSet]" ? "WeakSet {}" : s === "[object Function]" || s === "[object Gen\
|
|
1022
|
-
eratorFunction]" ?
|
|
1023
|
-
"[object Error]" ?
|
|
1024
|
-
|
|
861
|
+
eratorFunction]" ? Gt(e, t) : s === "[object Symbol]" ? Ht(e) : s === "[object Date]" ? Number.isNaN(+e) ? "Date { NaN }" : Ao.call(e) : s ===
|
|
862
|
+
"[object Error]" ? Jt(e) : s === "[object RegExp]" ? n ? Kt.call(e).replaceAll(/[$()*+.?[\\\]^{|}]/g, "\\$&") : Kt.call(e) : e instanceof Error ?
|
|
863
|
+
Jt(e) : null;
|
|
1025
864
|
}
|
|
1026
865
|
c(an, "printBasicValue");
|
|
1027
|
-
function fn(
|
|
1028
|
-
if (o.includes(
|
|
866
|
+
function fn(e, t, n, r, o, s) {
|
|
867
|
+
if (o.includes(e))
|
|
1029
868
|
return "[Circular]";
|
|
1030
|
-
o = [...o], o.push(
|
|
1031
|
-
let i = ++r >
|
|
1032
|
-
if (
|
|
1033
|
-
return
|
|
1034
|
-
let l = ln.call(
|
|
1035
|
-
return l === "[object Arguments]" ? i ? "[Arguments]" : `${a ? "" : "Arguments "}[${
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
o,
|
|
1041
|
-
ft
|
|
1042
|
-
)}]` : Mo(l) ? i ? `[${t.constructor.name}]` : `${a || !e.printBasicPrototype && t.constructor.name === "Array" ? "" : `${t.constructor.name}\
|
|
1043
|
-
`}[${Ft(t, e, n, r, o, ft)}]` : l === "[object Map]" ? i ? "[Map]" : `Map {${Ot(
|
|
1044
|
-
t.entries(),
|
|
1045
|
-
e,
|
|
1046
|
-
n,
|
|
1047
|
-
r,
|
|
1048
|
-
o,
|
|
1049
|
-
ft,
|
|
1050
|
-
" => "
|
|
1051
|
-
)}}` : l === "[object Set]" ? i ? "[Set]" : `Set {${ne(
|
|
1052
|
-
t.values(),
|
|
1053
|
-
e,
|
|
1054
|
-
n,
|
|
1055
|
-
r,
|
|
1056
|
-
o,
|
|
1057
|
-
ft
|
|
1058
|
-
)}}` : i || No(t) ? `[${xt(t)}]` : `${a || !e.printBasicPrototype && xt(t) === "Object" ? "" : `${xt(t)} `}{${re(
|
|
1059
|
-
t,
|
|
1060
|
-
e,
|
|
1061
|
-
n,
|
|
1062
|
-
r,
|
|
1063
|
-
o,
|
|
1064
|
-
ft
|
|
1065
|
-
)}}`;
|
|
869
|
+
o = [...o], o.push(e);
|
|
870
|
+
let i = ++r > t.maxDepth, a = t.min;
|
|
871
|
+
if (t.callToJSON && !i && e.toJSON && typeof e.toJSON == "function" && !s)
|
|
872
|
+
return fe(e.toJSON(), t, n, r, o, !0);
|
|
873
|
+
let l = ln.call(e);
|
|
874
|
+
return l === "[object Arguments]" ? i ? "[Arguments]" : `${a ? "" : "Arguments "}[${Fe(e, t, n, r, o, fe)}]` : Mo(l) ? i ? `[${e.constructor.
|
|
875
|
+
name}]` : `${a || !t.printBasicPrototype && e.constructor.name === "Array" ? "" : `${e.constructor.name} `}[${Fe(e, t, n, r, o, fe)}]` : l ===
|
|
876
|
+
"[object Map]" ? i ? "[Map]" : `Map {${Oe(e.entries(), t, n, r, o, fe, " => ")}}` : l === "[object Set]" ? i ? "[Set]" : `Set {${nt(e.values(),
|
|
877
|
+
t, n, r, o, fe)}}` : i || No(e) ? `[${xe(e)}]` : `${a || !t.printBasicPrototype && xe(e) === "Object" ? "" : `${xe(e)} `}{${rt(e, t, n, r,
|
|
878
|
+
o, fe)}}`;
|
|
1066
879
|
}
|
|
1067
880
|
c(fn, "printComplexValue");
|
|
1068
881
|
var Fo = {
|
|
1069
|
-
test: /* @__PURE__ */ c((
|
|
1070
|
-
serialize(
|
|
1071
|
-
if (o.includes(
|
|
882
|
+
test: /* @__PURE__ */ c((e) => e && e instanceof Error, "test"),
|
|
883
|
+
serialize(e, t, n, r, o, s) {
|
|
884
|
+
if (o.includes(e))
|
|
1072
885
|
return "[Circular]";
|
|
1073
|
-
o = [...o,
|
|
1074
|
-
let i = ++r >
|
|
886
|
+
o = [...o, e];
|
|
887
|
+
let i = ++r > t.maxDepth, { message: a, cause: l, ...m } = e, p = {
|
|
1075
888
|
message: a,
|
|
1076
889
|
...typeof l < "u" ? { cause: l } : {},
|
|
1077
|
-
...
|
|
890
|
+
...e instanceof AggregateError ? { errors: e.errors } : {},
|
|
1078
891
|
...m
|
|
1079
|
-
}, f =
|
|
1080
|
-
return i ? `[${f}]` : `${f} {${
|
|
1081
|
-
Object.entries(p).values(),
|
|
1082
|
-
e,
|
|
1083
|
-
n,
|
|
1084
|
-
r,
|
|
1085
|
-
o,
|
|
1086
|
-
s
|
|
1087
|
-
)}}`;
|
|
892
|
+
}, f = e.name !== "Error" ? e.name : xe(e);
|
|
893
|
+
return i ? `[${f}]` : `${f} {${Oe(Object.entries(p).values(), t, n, r, o, s)}}`;
|
|
1088
894
|
}
|
|
1089
895
|
};
|
|
1090
|
-
function Do(
|
|
1091
|
-
return
|
|
896
|
+
function Do(e) {
|
|
897
|
+
return e.serialize != null;
|
|
1092
898
|
}
|
|
1093
899
|
c(Do, "isNewPlugin");
|
|
1094
|
-
function mn(
|
|
900
|
+
function mn(e, t, n, r, o, s) {
|
|
1095
901
|
let i;
|
|
1096
902
|
try {
|
|
1097
|
-
i = Do(
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
(a) => {
|
|
1101
|
-
let l = r + n.indent;
|
|
1102
|
-
return l + a.replaceAll(Io, `
|
|
903
|
+
i = Do(e) ? e.serialize(t, n, r, o, s, fe) : e.print(t, (a) => fe(a, n, r, o, s), (a) => {
|
|
904
|
+
let l = r + n.indent;
|
|
905
|
+
return l + a.replaceAll(Io, `
|
|
1103
906
|
${l}`);
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
},
|
|
1110
|
-
n.colors
|
|
1111
|
-
);
|
|
907
|
+
}, {
|
|
908
|
+
edgeSpacing: n.spacingOuter,
|
|
909
|
+
min: n.min,
|
|
910
|
+
spacing: n.spacingInner
|
|
911
|
+
}, n.colors);
|
|
1112
912
|
} catch (a) {
|
|
1113
|
-
throw new
|
|
913
|
+
throw new De(a.message, a.stack);
|
|
1114
914
|
}
|
|
1115
915
|
if (typeof i != "string")
|
|
1116
|
-
throw new TypeError(
|
|
1117
|
-
`pretty-format: Plugin must return type "string" but instead returned "${typeof i}".`
|
|
1118
|
-
);
|
|
916
|
+
throw new TypeError(`pretty-format: Plugin must return type "string" but instead returned "${typeof i}".`);
|
|
1119
917
|
return i;
|
|
1120
918
|
}
|
|
1121
919
|
c(mn, "printPlugin");
|
|
1122
|
-
function pn(
|
|
1123
|
-
for (let n of
|
|
920
|
+
function pn(e, t) {
|
|
921
|
+
for (let n of e)
|
|
1124
922
|
try {
|
|
1125
|
-
if (n.test(
|
|
923
|
+
if (n.test(t))
|
|
1126
924
|
return n;
|
|
1127
925
|
} catch (r) {
|
|
1128
|
-
throw new
|
|
926
|
+
throw new De(r.message, r.stack);
|
|
1129
927
|
}
|
|
1130
928
|
return null;
|
|
1131
929
|
}
|
|
1132
930
|
c(pn, "findPlugin");
|
|
1133
|
-
function
|
|
1134
|
-
let i = pn(
|
|
931
|
+
function fe(e, t, n, r, o, s) {
|
|
932
|
+
let i = pn(t.plugins, e);
|
|
1135
933
|
if (i !== null)
|
|
1136
|
-
return mn(i,
|
|
1137
|
-
let a = an(
|
|
1138
|
-
|
|
1139
|
-
e.printFunctionName,
|
|
1140
|
-
e.escapeRegex,
|
|
1141
|
-
e.escapeString
|
|
1142
|
-
);
|
|
1143
|
-
return a !== null ? a : fn(
|
|
1144
|
-
t,
|
|
1145
|
-
e,
|
|
1146
|
-
n,
|
|
1147
|
-
r,
|
|
1148
|
-
o,
|
|
1149
|
-
s
|
|
1150
|
-
);
|
|
934
|
+
return mn(i, e, t, n, r, o);
|
|
935
|
+
let a = an(e, t.printFunctionName, t.escapeRegex, t.escapeString);
|
|
936
|
+
return a !== null ? a : fn(e, t, n, r, o, s);
|
|
1151
937
|
}
|
|
1152
|
-
c(
|
|
1153
|
-
var
|
|
938
|
+
c(fe, "printer");
|
|
939
|
+
var ut = {
|
|
1154
940
|
comment: "gray",
|
|
1155
941
|
content: "reset",
|
|
1156
942
|
prop: "yellow",
|
|
1157
943
|
tag: "cyan",
|
|
1158
944
|
value: "green"
|
|
1159
|
-
}, gn = Object.keys(
|
|
945
|
+
}, gn = Object.keys(ut), re = {
|
|
1160
946
|
callToJSON: !0,
|
|
1161
947
|
compareKeys: void 0,
|
|
1162
948
|
escapeRegex: !1,
|
|
@@ -1169,88 +955,82 @@ var ue = {
|
|
|
1169
955
|
plugins: [],
|
|
1170
956
|
printBasicPrototype: !0,
|
|
1171
957
|
printFunctionName: !0,
|
|
1172
|
-
theme:
|
|
958
|
+
theme: ut
|
|
1173
959
|
};
|
|
1174
|
-
function jo(
|
|
1175
|
-
for (let
|
|
1176
|
-
if (!Object.prototype.hasOwnProperty.call(
|
|
1177
|
-
throw new Error(`pretty-format: Unknown option "${
|
|
1178
|
-
if (
|
|
1179
|
-
throw new Error(
|
|
1180
|
-
'pretty-format: Options "min" and "indent" cannot be used together.'
|
|
1181
|
-
);
|
|
960
|
+
function jo(e) {
|
|
961
|
+
for (let t of Object.keys(e))
|
|
962
|
+
if (!Object.prototype.hasOwnProperty.call(re, t))
|
|
963
|
+
throw new Error(`pretty-format: Unknown option "${t}".`);
|
|
964
|
+
if (e.min && e.indent !== void 0 && e.indent !== 0)
|
|
965
|
+
throw new Error('pretty-format: Options "min" and "indent" cannot be used together.');
|
|
1182
966
|
}
|
|
1183
967
|
c(jo, "validateOptions");
|
|
1184
968
|
function Bo() {
|
|
1185
|
-
return gn.reduce((
|
|
1186
|
-
let n =
|
|
969
|
+
return gn.reduce((e, t) => {
|
|
970
|
+
let n = ut[t], r = n && ne[n];
|
|
1187
971
|
if (r && typeof r.close == "string" && typeof r.open == "string")
|
|
1188
|
-
t
|
|
972
|
+
e[t] = r;
|
|
1189
973
|
else
|
|
1190
|
-
throw new Error(
|
|
1191
|
-
|
|
1192
|
-
);
|
|
1193
|
-
return t;
|
|
974
|
+
throw new Error(`pretty-format: Option "theme" has a key "${t}" whose value "${n}" is undefined in ansi-styles.`);
|
|
975
|
+
return e;
|
|
1194
976
|
}, /* @__PURE__ */ Object.create(null));
|
|
1195
977
|
}
|
|
1196
978
|
c(Bo, "getColorsHighlight");
|
|
1197
979
|
function ko() {
|
|
1198
|
-
return gn.reduce((
|
|
980
|
+
return gn.reduce((e, t) => (e[t] = {
|
|
981
|
+
close: "",
|
|
982
|
+
open: ""
|
|
983
|
+
}, e), /* @__PURE__ */ Object.create(null));
|
|
1199
984
|
}
|
|
1200
985
|
c(ko, "getColorsEmpty");
|
|
1201
|
-
function hn(
|
|
1202
|
-
return
|
|
986
|
+
function hn(e) {
|
|
987
|
+
return e?.printFunctionName ?? re.printFunctionName;
|
|
1203
988
|
}
|
|
1204
989
|
c(hn, "getPrintFunctionName");
|
|
1205
|
-
function yn(
|
|
1206
|
-
return
|
|
990
|
+
function yn(e) {
|
|
991
|
+
return e?.escapeRegex ?? re.escapeRegex;
|
|
1207
992
|
}
|
|
1208
993
|
c(yn, "getEscapeRegex");
|
|
1209
|
-
function dn(
|
|
1210
|
-
return
|
|
994
|
+
function dn(e) {
|
|
995
|
+
return e?.escapeString ?? re.escapeString;
|
|
1211
996
|
}
|
|
1212
997
|
c(dn, "getEscapeString");
|
|
1213
|
-
function
|
|
998
|
+
function Xt(e) {
|
|
1214
999
|
return {
|
|
1215
|
-
callToJSON:
|
|
1216
|
-
colors:
|
|
1217
|
-
compareKeys: typeof
|
|
1218
|
-
escapeRegex: yn(
|
|
1219
|
-
escapeString: dn(
|
|
1220
|
-
indent:
|
|
1221
|
-
maxDepth:
|
|
1222
|
-
maxWidth:
|
|
1223
|
-
min:
|
|
1224
|
-
plugins:
|
|
1225
|
-
printBasicPrototype:
|
|
1226
|
-
printFunctionName: hn(
|
|
1227
|
-
spacingInner:
|
|
1000
|
+
callToJSON: e?.callToJSON ?? re.callToJSON,
|
|
1001
|
+
colors: e?.highlight ? Bo() : ko(),
|
|
1002
|
+
compareKeys: typeof e?.compareKeys == "function" || e?.compareKeys === null ? e.compareKeys : re.compareKeys,
|
|
1003
|
+
escapeRegex: yn(e),
|
|
1004
|
+
escapeString: dn(e),
|
|
1005
|
+
indent: e?.min ? "" : zo(e?.indent ?? re.indent),
|
|
1006
|
+
maxDepth: e?.maxDepth ?? re.maxDepth,
|
|
1007
|
+
maxWidth: e?.maxWidth ?? re.maxWidth,
|
|
1008
|
+
min: e?.min ?? re.min,
|
|
1009
|
+
plugins: e?.plugins ?? re.plugins,
|
|
1010
|
+
printBasicPrototype: e?.printBasicPrototype ?? !0,
|
|
1011
|
+
printFunctionName: hn(e),
|
|
1012
|
+
spacingInner: e?.min ? " " : `
|
|
1228
1013
|
`,
|
|
1229
|
-
spacingOuter:
|
|
1014
|
+
spacingOuter: e?.min ? "" : `
|
|
1230
1015
|
`
|
|
1231
1016
|
};
|
|
1232
1017
|
}
|
|
1233
|
-
c(
|
|
1234
|
-
function zo(
|
|
1235
|
-
return Array.from({ length:
|
|
1018
|
+
c(Xt, "getConfig");
|
|
1019
|
+
function zo(e) {
|
|
1020
|
+
return Array.from({ length: e + 1 }).join(" ");
|
|
1236
1021
|
}
|
|
1237
1022
|
c(zo, "createIndent");
|
|
1238
|
-
function
|
|
1239
|
-
if (
|
|
1240
|
-
let r = pn(
|
|
1023
|
+
function Q(e, t) {
|
|
1024
|
+
if (t && (jo(t), t.plugins)) {
|
|
1025
|
+
let r = pn(t.plugins, e);
|
|
1241
1026
|
if (r !== null)
|
|
1242
|
-
return mn(r,
|
|
1027
|
+
return mn(r, e, Xt(t), "", 0, []);
|
|
1243
1028
|
}
|
|
1244
|
-
let n = an(
|
|
1245
|
-
|
|
1246
|
-
hn(e),
|
|
1247
|
-
yn(e),
|
|
1248
|
-
dn(e)
|
|
1249
|
-
);
|
|
1250
|
-
return n !== null ? n : fn(t, Xe(e), "", 0, []);
|
|
1029
|
+
let n = an(e, hn(t), yn(t), dn(t));
|
|
1030
|
+
return n !== null ? n : fn(e, Xt(t), "", 0, []);
|
|
1251
1031
|
}
|
|
1252
|
-
c(
|
|
1253
|
-
var $
|
|
1032
|
+
c(Q, "format");
|
|
1033
|
+
var $e = {
|
|
1254
1034
|
AsymmetricMatcher: Ar,
|
|
1255
1035
|
DOMCollection: xr,
|
|
1256
1036
|
DOMElement: Vr,
|
|
@@ -1300,15 +1080,15 @@ var bn = {
|
|
|
1300
1080
|
symbol: "green",
|
|
1301
1081
|
date: "magenta",
|
|
1302
1082
|
regexp: "red"
|
|
1303
|
-
},
|
|
1304
|
-
function Uo(
|
|
1305
|
-
let n = bn[Yo[
|
|
1306
|
-
return n ? `\x1B[${n[0]}m${String(
|
|
1083
|
+
}, ue = "\u2026";
|
|
1084
|
+
function Uo(e, t) {
|
|
1085
|
+
let n = bn[Yo[t]] || bn[t] || "";
|
|
1086
|
+
return n ? `\x1B[${n[0]}m${String(e)}\x1B[${n[1]}m` : String(e);
|
|
1307
1087
|
}
|
|
1308
1088
|
c(Uo, "colorise");
|
|
1309
1089
|
function Sn({
|
|
1310
|
-
showHidden:
|
|
1311
|
-
depth:
|
|
1090
|
+
showHidden: e = !1,
|
|
1091
|
+
depth: t = 2,
|
|
1312
1092
|
colors: n = !1,
|
|
1313
1093
|
customInspect: r = !0,
|
|
1314
1094
|
showProxy: o = !1,
|
|
@@ -1320,8 +1100,8 @@ function Sn({
|
|
|
1320
1100
|
stylize: m = String
|
|
1321
1101
|
} = {}, p) {
|
|
1322
1102
|
let f = {
|
|
1323
|
-
showHidden: !!
|
|
1324
|
-
depth: Number(
|
|
1103
|
+
showHidden: !!e,
|
|
1104
|
+
depth: Number(t),
|
|
1325
1105
|
colors: !!n,
|
|
1326
1106
|
customInspect: !!r,
|
|
1327
1107
|
showProxy: !!o,
|
|
@@ -1335,39 +1115,39 @@ function Sn({
|
|
|
1335
1115
|
return f.colors && (f.stylize = Uo), f;
|
|
1336
1116
|
}
|
|
1337
1117
|
c(Sn, "normaliseOptions");
|
|
1338
|
-
function Wo(
|
|
1339
|
-
return
|
|
1118
|
+
function Wo(e) {
|
|
1119
|
+
return e >= "\uD800" && e <= "\uDBFF";
|
|
1340
1120
|
}
|
|
1341
1121
|
c(Wo, "isHighSurrogate");
|
|
1342
|
-
function Y(
|
|
1343
|
-
|
|
1344
|
-
let r = n.length, o =
|
|
1345
|
-
if (r >
|
|
1122
|
+
function Y(e, t, n = ue) {
|
|
1123
|
+
e = String(e);
|
|
1124
|
+
let r = n.length, o = e.length;
|
|
1125
|
+
if (r > t && o > r)
|
|
1346
1126
|
return n;
|
|
1347
|
-
if (o >
|
|
1348
|
-
let s =
|
|
1349
|
-
return s > 0 && Wo(
|
|
1127
|
+
if (o > t && o > r) {
|
|
1128
|
+
let s = t - r;
|
|
1129
|
+
return s > 0 && Wo(e[s - 1]) && (s = s - 1), `${e.slice(0, s)}${n}`;
|
|
1350
1130
|
}
|
|
1351
|
-
return
|
|
1131
|
+
return e;
|
|
1352
1132
|
}
|
|
1353
1133
|
c(Y, "truncate");
|
|
1354
|
-
function j(
|
|
1355
|
-
n = n ||
|
|
1356
|
-
let o =
|
|
1134
|
+
function j(e, t, n, r = ", ") {
|
|
1135
|
+
n = n || t.inspect;
|
|
1136
|
+
let o = e.length;
|
|
1357
1137
|
if (o === 0)
|
|
1358
1138
|
return "";
|
|
1359
|
-
let s =
|
|
1139
|
+
let s = t.truncate, i = "", a = "", l = "";
|
|
1360
1140
|
for (let m = 0; m < o; m += 1) {
|
|
1361
|
-
let p = m + 1 ===
|
|
1362
|
-
l = `${
|
|
1363
|
-
let
|
|
1364
|
-
|
|
1365
|
-
let y = a || n(
|
|
1366
|
-
if (p && g > s && i.length + l.length <= s || !p && !f && u > s || (a = p ? "" : n(
|
|
1141
|
+
let p = m + 1 === e.length, f = m + 2 === e.length;
|
|
1142
|
+
l = `${ue}(${e.length - m})`;
|
|
1143
|
+
let b = e[m];
|
|
1144
|
+
t.truncate = s - i.length - (p ? 0 : r.length);
|
|
1145
|
+
let y = a || n(b, t) + (p ? "" : r), g = i.length + y.length, u = g + l.length;
|
|
1146
|
+
if (p && g > s && i.length + l.length <= s || !p && !f && u > s || (a = p ? "" : n(e[m + 1], t) + (f ? "" : r), !p && f && u > s && g + a.
|
|
1367
1147
|
length > s))
|
|
1368
1148
|
break;
|
|
1369
1149
|
if (i += y, !p && !f && g + a.length >= s) {
|
|
1370
|
-
l = `${
|
|
1150
|
+
l = `${ue}(${e.length - m - 1})`;
|
|
1371
1151
|
break;
|
|
1372
1152
|
}
|
|
1373
1153
|
l = "";
|
|
@@ -1375,120 +1155,120 @@ function j(t, e, n, r = ", ") {
|
|
|
1375
1155
|
return `${i}${l}`;
|
|
1376
1156
|
}
|
|
1377
1157
|
c(j, "inspectList");
|
|
1378
|
-
function Vo(
|
|
1379
|
-
return
|
|
1158
|
+
function Vo(e) {
|
|
1159
|
+
return e.match(/^[a-zA-Z_][a-zA-Z_0-9]*$/) ? e : JSON.stringify(e).replace(/'/g, "\\'").replace(/\\"/g, '"').replace(/(^"|"$)/g, "'");
|
|
1380
1160
|
}
|
|
1381
1161
|
c(Vo, "quoteComplexKey");
|
|
1382
|
-
function
|
|
1383
|
-
return n.truncate -= 2, typeof
|
|
1384
|
-
n.inspect(
|
|
1162
|
+
function le([e, t], n) {
|
|
1163
|
+
return n.truncate -= 2, typeof e == "string" ? e = Vo(e) : typeof e != "number" && (e = `[${n.inspect(e, n)}]`), n.truncate -= e.length, t =
|
|
1164
|
+
n.inspect(t, n), `${e}: ${t}`;
|
|
1385
1165
|
}
|
|
1386
|
-
c(
|
|
1166
|
+
c(le, "inspectProperty");
|
|
1387
1167
|
|
|
1388
1168
|
// ../node_modules/loupe/lib/array.js
|
|
1389
|
-
function
|
|
1390
|
-
let n = Object.keys(
|
|
1391
|
-
if (!
|
|
1169
|
+
function lt(e, t) {
|
|
1170
|
+
let n = Object.keys(e).slice(e.length);
|
|
1171
|
+
if (!e.length && !n.length)
|
|
1392
1172
|
return "[]";
|
|
1393
|
-
|
|
1394
|
-
let r = j(
|
|
1395
|
-
|
|
1173
|
+
t.truncate -= 4;
|
|
1174
|
+
let r = j(e, t);
|
|
1175
|
+
t.truncate -= r.length;
|
|
1396
1176
|
let o = "";
|
|
1397
|
-
return n.length && (o = j(n.map((s) => [s,
|
|
1177
|
+
return n.length && (o = j(n.map((s) => [s, e[s]]), t, le)), `[ ${r}${o ? `, ${o}` : ""} ]`;
|
|
1398
1178
|
}
|
|
1399
|
-
c(
|
|
1179
|
+
c(lt, "inspectArray");
|
|
1400
1180
|
|
|
1401
1181
|
// ../node_modules/loupe/lib/typedarray.js
|
|
1402
|
-
var qo = /* @__PURE__ */ c((
|
|
1403
|
-
|
|
1404
|
-
function
|
|
1405
|
-
let n = qo(
|
|
1406
|
-
|
|
1407
|
-
let r = Object.keys(
|
|
1408
|
-
if (!
|
|
1182
|
+
var qo = /* @__PURE__ */ c((e) => typeof Buffer == "function" && e instanceof Buffer ? "Buffer" : e[Symbol.toStringTag] ? e[Symbol.toStringTag] :
|
|
1183
|
+
e.constructor.name, "getArrayName");
|
|
1184
|
+
function oe(e, t) {
|
|
1185
|
+
let n = qo(e);
|
|
1186
|
+
t.truncate -= n.length + 4;
|
|
1187
|
+
let r = Object.keys(e).slice(e.length);
|
|
1188
|
+
if (!e.length && !r.length)
|
|
1409
1189
|
return `${n}[]`;
|
|
1410
1190
|
let o = "";
|
|
1411
|
-
for (let i = 0; i <
|
|
1412
|
-
let a = `${
|
|
1413
|
-
if (
|
|
1414
|
-
o += `${
|
|
1191
|
+
for (let i = 0; i < e.length; i++) {
|
|
1192
|
+
let a = `${t.stylize(Y(e[i], t.truncate), "number")}${i === e.length - 1 ? "" : ", "}`;
|
|
1193
|
+
if (t.truncate -= a.length, e[i] !== e.length && t.truncate <= 3) {
|
|
1194
|
+
o += `${ue}(${e.length - e[i] + 1})`;
|
|
1415
1195
|
break;
|
|
1416
1196
|
}
|
|
1417
1197
|
o += a;
|
|
1418
1198
|
}
|
|
1419
1199
|
let s = "";
|
|
1420
|
-
return r.length && (s = j(r.map((i) => [i,
|
|
1200
|
+
return r.length && (s = j(r.map((i) => [i, e[i]]), t, le)), `${n}[ ${o}${s ? `, ${s}` : ""} ]`;
|
|
1421
1201
|
}
|
|
1422
|
-
c(
|
|
1202
|
+
c(oe, "inspectTypedArray");
|
|
1423
1203
|
|
|
1424
1204
|
// ../node_modules/loupe/lib/date.js
|
|
1425
|
-
function
|
|
1426
|
-
let n =
|
|
1205
|
+
function at(e, t) {
|
|
1206
|
+
let n = e.toJSON();
|
|
1427
1207
|
if (n === null)
|
|
1428
1208
|
return "Invalid Date";
|
|
1429
1209
|
let r = n.split("T"), o = r[0];
|
|
1430
|
-
return
|
|
1210
|
+
return t.stylize(`${o}T${Y(r[1], t.truncate - o.length - 1)}`, "date");
|
|
1431
1211
|
}
|
|
1432
|
-
c(
|
|
1212
|
+
c(at, "inspectDate");
|
|
1433
1213
|
|
|
1434
1214
|
// ../node_modules/loupe/lib/function.js
|
|
1435
|
-
function
|
|
1436
|
-
let n =
|
|
1437
|
-
return r ?
|
|
1215
|
+
function Be(e, t) {
|
|
1216
|
+
let n = e[Symbol.toStringTag] || "Function", r = e.name;
|
|
1217
|
+
return r ? t.stylize(`[${n} ${Y(r, t.truncate - 11)}]`, "special") : t.stylize(`[${n}]`, "special");
|
|
1438
1218
|
}
|
|
1439
|
-
c(
|
|
1219
|
+
c(Be, "inspectFunction");
|
|
1440
1220
|
|
|
1441
1221
|
// ../node_modules/loupe/lib/map.js
|
|
1442
|
-
function Ko([
|
|
1443
|
-
return n.truncate -= 4,
|
|
1222
|
+
function Ko([e, t], n) {
|
|
1223
|
+
return n.truncate -= 4, e = n.inspect(e, n), n.truncate -= e.length, t = n.inspect(t, n), `${e} => ${t}`;
|
|
1444
1224
|
}
|
|
1445
1225
|
c(Ko, "inspectMapEntry");
|
|
1446
|
-
function Go(
|
|
1447
|
-
let
|
|
1448
|
-
return
|
|
1449
|
-
|
|
1450
|
-
}),
|
|
1226
|
+
function Go(e) {
|
|
1227
|
+
let t = [];
|
|
1228
|
+
return e.forEach((n, r) => {
|
|
1229
|
+
t.push([r, n]);
|
|
1230
|
+
}), t;
|
|
1451
1231
|
}
|
|
1452
1232
|
c(Go, "mapToEntries");
|
|
1453
|
-
function
|
|
1454
|
-
return
|
|
1233
|
+
function ft(e, t) {
|
|
1234
|
+
return e.size === 0 ? "Map{}" : (t.truncate -= 7, `Map{ ${j(Go(e), t, Ko)} }`);
|
|
1455
1235
|
}
|
|
1456
|
-
c(
|
|
1236
|
+
c(ft, "inspectMap");
|
|
1457
1237
|
|
|
1458
1238
|
// ../node_modules/loupe/lib/number.js
|
|
1459
|
-
var Ho = Number.isNaN || ((
|
|
1460
|
-
function
|
|
1461
|
-
return Ho(
|
|
1462
|
-
|
|
1239
|
+
var Ho = Number.isNaN || ((e) => e !== e);
|
|
1240
|
+
function ke(e, t) {
|
|
1241
|
+
return Ho(e) ? t.stylize("NaN", "number") : e === 1 / 0 ? t.stylize("Infinity", "number") : e === -1 / 0 ? t.stylize("-Infinity", "number") :
|
|
1242
|
+
e === 0 ? t.stylize(1 / e === 1 / 0 ? "+0" : "-0", "number") : t.stylize(Y(String(e), t.truncate), "number");
|
|
1463
1243
|
}
|
|
1464
|
-
c(
|
|
1244
|
+
c(ke, "inspectNumber");
|
|
1465
1245
|
|
|
1466
1246
|
// ../node_modules/loupe/lib/bigint.js
|
|
1467
|
-
function
|
|
1468
|
-
let n = Y(
|
|
1469
|
-
return n !==
|
|
1247
|
+
function ze(e, t) {
|
|
1248
|
+
let n = Y(e.toString(), t.truncate - 1);
|
|
1249
|
+
return n !== ue && (n += "n"), t.stylize(n, "bigint");
|
|
1470
1250
|
}
|
|
1471
|
-
c(
|
|
1251
|
+
c(ze, "inspectBigInt");
|
|
1472
1252
|
|
|
1473
1253
|
// ../node_modules/loupe/lib/regexp.js
|
|
1474
|
-
function
|
|
1475
|
-
let n =
|
|
1476
|
-
return
|
|
1254
|
+
function mt(e, t) {
|
|
1255
|
+
let n = e.toString().split("/")[2], r = t.truncate - (2 + n.length), o = e.source;
|
|
1256
|
+
return t.stylize(`/${Y(o, r)}/${n}`, "regexp");
|
|
1477
1257
|
}
|
|
1478
|
-
c(
|
|
1258
|
+
c(mt, "inspectRegExp");
|
|
1479
1259
|
|
|
1480
1260
|
// ../node_modules/loupe/lib/set.js
|
|
1481
|
-
function Jo(
|
|
1482
|
-
let
|
|
1483
|
-
return
|
|
1484
|
-
|
|
1485
|
-
}),
|
|
1261
|
+
function Jo(e) {
|
|
1262
|
+
let t = [];
|
|
1263
|
+
return e.forEach((n) => {
|
|
1264
|
+
t.push(n);
|
|
1265
|
+
}), t;
|
|
1486
1266
|
}
|
|
1487
1267
|
c(Jo, "arrayFromSet");
|
|
1488
|
-
function
|
|
1489
|
-
return
|
|
1268
|
+
function pt(e, t) {
|
|
1269
|
+
return e.size === 0 ? "Set{}" : (t.truncate -= 7, `Set{ ${j(Jo(e), t)} }`);
|
|
1490
1270
|
}
|
|
1491
|
-
c(
|
|
1271
|
+
c(pt, "inspectSet");
|
|
1492
1272
|
|
|
1493
1273
|
// ../node_modules/loupe/lib/string.js
|
|
1494
1274
|
var En = new RegExp("['\\u0000-\\u001f\\u007f-\\u009f\\u00ad\\u0600-\\u0604\\u070f\\u17b4\\u17b5\\u200c-\\u200f\\u2028-\\u202f\\u2060-\\u206f\\ufeff\\ufff0-\\u\
|
|
@@ -1500,66 +1280,66 @@ ffff]", "g"), Xo = {
|
|
|
1500
1280
|
"\r": "\\r",
|
|
1501
1281
|
"'": "\\'",
|
|
1502
1282
|
"\\": "\\\\"
|
|
1503
|
-
}, Zo = 16,
|
|
1504
|
-
function
|
|
1505
|
-
return Xo[
|
|
1283
|
+
}, Zo = 16, vo = 4;
|
|
1284
|
+
function Qo(e) {
|
|
1285
|
+
return Xo[e] || `\\u${`0000${e.charCodeAt(0).toString(Zo)}`.slice(-vo)}`;
|
|
1506
1286
|
}
|
|
1507
|
-
c(
|
|
1508
|
-
function
|
|
1509
|
-
return En.test(
|
|
1287
|
+
c(Qo, "escape");
|
|
1288
|
+
function Ye(e, t) {
|
|
1289
|
+
return En.test(e) && (e = e.replace(En, Qo)), t.stylize(`'${Y(e, t.truncate - 2)}'`, "string");
|
|
1510
1290
|
}
|
|
1511
|
-
c(
|
|
1291
|
+
c(Ye, "inspectString");
|
|
1512
1292
|
|
|
1513
1293
|
// ../node_modules/loupe/lib/symbol.js
|
|
1514
|
-
function
|
|
1515
|
-
return "description" in Symbol.prototype ?
|
|
1294
|
+
function Ue(e) {
|
|
1295
|
+
return "description" in Symbol.prototype ? e.description ? `Symbol(${e.description})` : "Symbol()" : e.toString();
|
|
1516
1296
|
}
|
|
1517
|
-
c(
|
|
1297
|
+
c(Ue, "inspectSymbol");
|
|
1518
1298
|
|
|
1519
1299
|
// ../node_modules/loupe/lib/promise.js
|
|
1520
1300
|
var _n = /* @__PURE__ */ c(() => "Promise{\u2026}", "getPromiseValue");
|
|
1521
1301
|
try {
|
|
1522
|
-
let { getPromiseDetails:
|
|
1523
|
-
Array.isArray(
|
|
1524
|
-
let [s, i] =
|
|
1525
|
-
return s ===
|
|
1302
|
+
let { getPromiseDetails: e, kPending: t, kRejected: n } = process.binding("util");
|
|
1303
|
+
Array.isArray(e(Promise.resolve())) && (_n = /* @__PURE__ */ c((r, o) => {
|
|
1304
|
+
let [s, i] = e(r);
|
|
1305
|
+
return s === t ? "Promise{<pending>}" : `Promise${s === n ? "!" : ""}{${o.inspect(i, o)}}`;
|
|
1526
1306
|
}, "getPromiseValue"));
|
|
1527
1307
|
} catch {
|
|
1528
1308
|
}
|
|
1529
1309
|
var Tn = _n;
|
|
1530
1310
|
|
|
1531
1311
|
// ../node_modules/loupe/lib/object.js
|
|
1532
|
-
function
|
|
1533
|
-
let n = Object.getOwnPropertyNames(
|
|
1312
|
+
function pe(e, t) {
|
|
1313
|
+
let n = Object.getOwnPropertyNames(e), r = Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(e) : [];
|
|
1534
1314
|
if (n.length === 0 && r.length === 0)
|
|
1535
1315
|
return "{}";
|
|
1536
|
-
if (
|
|
1316
|
+
if (t.truncate -= 4, t.seen = t.seen || [], t.seen.includes(e))
|
|
1537
1317
|
return "[Circular]";
|
|
1538
|
-
|
|
1539
|
-
let o = j(n.map((a) => [a,
|
|
1540
|
-
|
|
1318
|
+
t.seen.push(e);
|
|
1319
|
+
let o = j(n.map((a) => [a, e[a]]), t, le), s = j(r.map((a) => [a, e[a]]), t, le);
|
|
1320
|
+
t.seen.pop();
|
|
1541
1321
|
let i = "";
|
|
1542
1322
|
return o && s && (i = ", "), `{ ${o}${i}${s} }`;
|
|
1543
1323
|
}
|
|
1544
|
-
c(
|
|
1324
|
+
c(pe, "inspectObject");
|
|
1545
1325
|
|
|
1546
1326
|
// ../node_modules/loupe/lib/class.js
|
|
1547
|
-
var
|
|
1548
|
-
function
|
|
1327
|
+
var gt = typeof Symbol < "u" && Symbol.toStringTag ? Symbol.toStringTag : !1;
|
|
1328
|
+
function ht(e, t) {
|
|
1549
1329
|
let n = "";
|
|
1550
|
-
return
|
|
1551
|
-
`${n}${
|
|
1330
|
+
return gt && gt in e && (n = e[gt]), n = n || e.constructor.name, (!n || n === "_class") && (n = "<Anonymous Class>"), t.truncate -= n.length,
|
|
1331
|
+
`${n}${pe(e, t)}`;
|
|
1552
1332
|
}
|
|
1553
|
-
c(
|
|
1333
|
+
c(ht, "inspectClass");
|
|
1554
1334
|
|
|
1555
1335
|
// ../node_modules/loupe/lib/arguments.js
|
|
1556
|
-
function
|
|
1557
|
-
return
|
|
1336
|
+
function yt(e, t) {
|
|
1337
|
+
return e.length === 0 ? "Arguments[]" : (t.truncate -= 13, `Arguments[ ${j(e, t)} ]`);
|
|
1558
1338
|
}
|
|
1559
|
-
c(
|
|
1339
|
+
c(yt, "inspectArguments");
|
|
1560
1340
|
|
|
1561
1341
|
// ../node_modules/loupe/lib/error.js
|
|
1562
|
-
var
|
|
1342
|
+
var es = [
|
|
1563
1343
|
"stack",
|
|
1564
1344
|
"line",
|
|
1565
1345
|
"column",
|
|
@@ -1572,116 +1352,109 @@ var ts = [
|
|
|
1572
1352
|
"description",
|
|
1573
1353
|
"cause"
|
|
1574
1354
|
];
|
|
1575
|
-
function
|
|
1576
|
-
let n = Object.getOwnPropertyNames(
|
|
1577
|
-
|
|
1355
|
+
function dt(e, t) {
|
|
1356
|
+
let n = Object.getOwnPropertyNames(e).filter((i) => es.indexOf(i) === -1), r = e.name;
|
|
1357
|
+
t.truncate -= r.length;
|
|
1578
1358
|
let o = "";
|
|
1579
|
-
if (typeof
|
|
1580
|
-
|
|
1359
|
+
if (typeof e.message == "string" ? o = Y(e.message, t.truncate) : n.unshift("message"), o = o ? `: ${o}` : "", t.truncate -= o.length + 5,
|
|
1360
|
+
t.seen = t.seen || [], t.seen.includes(e))
|
|
1581
1361
|
return "[Circular]";
|
|
1582
|
-
|
|
1583
|
-
let s = j(n.map((i) => [i,
|
|
1362
|
+
t.seen.push(e);
|
|
1363
|
+
let s = j(n.map((i) => [i, e[i]]), t, le);
|
|
1584
1364
|
return `${r}${o}${s ? ` { ${s} }` : ""}`;
|
|
1585
1365
|
}
|
|
1586
|
-
c(
|
|
1366
|
+
c(dt, "inspectObject");
|
|
1587
1367
|
|
|
1588
1368
|
// ../node_modules/loupe/lib/html.js
|
|
1589
|
-
function
|
|
1590
|
-
return n.truncate -= 3,
|
|
1369
|
+
function ts([e, t], n) {
|
|
1370
|
+
return n.truncate -= 3, t ? `${n.stylize(String(e), "yellow")}=${n.stylize(`"${t}"`, "string")}` : `${n.stylize(String(e), "yellow")}`;
|
|
1591
1371
|
}
|
|
1592
|
-
c(
|
|
1593
|
-
function
|
|
1594
|
-
return j(
|
|
1372
|
+
c(ts, "inspectAttribute");
|
|
1373
|
+
function We(e, t) {
|
|
1374
|
+
return j(e, t, Ve, `
|
|
1595
1375
|
`);
|
|
1596
1376
|
}
|
|
1597
|
-
c(
|
|
1598
|
-
function
|
|
1599
|
-
let n =
|
|
1377
|
+
c(We, "inspectHTMLCollection");
|
|
1378
|
+
function Ve(e, t) {
|
|
1379
|
+
let n = e.getAttributeNames(), r = e.tagName.toLowerCase(), o = t.stylize(`<${r}`, "special"), s = t.stylize(">", "special"), i = t.stylize(
|
|
1600
1380
|
`</${r}>`, "special");
|
|
1601
|
-
|
|
1381
|
+
t.truncate -= r.length * 2 + 5;
|
|
1602
1382
|
let a = "";
|
|
1603
|
-
n.length > 0 && (a += " ", a += j(n.map((p) => [p,
|
|
1604
|
-
let l =
|
|
1605
|
-
return m && m.length > l && (m = `${
|
|
1383
|
+
n.length > 0 && (a += " ", a += j(n.map((p) => [p, e.getAttribute(p)]), t, ts, " ")), t.truncate -= a.length;
|
|
1384
|
+
let l = t.truncate, m = We(e.children, t);
|
|
1385
|
+
return m && m.length > l && (m = `${ue}(${e.children.length})`), `${o}${a}${s}${m}${i}`;
|
|
1606
1386
|
}
|
|
1607
|
-
c(
|
|
1387
|
+
c(Ve, "inspectHTML");
|
|
1608
1388
|
|
|
1609
1389
|
// ../node_modules/loupe/lib/index.js
|
|
1610
|
-
var ns = typeof Symbol == "function" && typeof Symbol.for == "function",
|
|
1390
|
+
var ns = typeof Symbol == "function" && typeof Symbol.for == "function", bt = ns ? Symbol.for("chai/inspect") : "@@chai/inspect", Se = !1;
|
|
1611
1391
|
try {
|
|
1612
|
-
let
|
|
1613
|
-
|
|
1392
|
+
let e = require("util");
|
|
1393
|
+
Se = e.inspect ? e.inspect.custom : !1;
|
|
1614
1394
|
} catch {
|
|
1615
|
-
|
|
1395
|
+
Se = !1;
|
|
1616
1396
|
}
|
|
1617
1397
|
var Cn = /* @__PURE__ */ new WeakMap(), On = {}, $n = {
|
|
1618
|
-
undefined: /* @__PURE__ */ c((
|
|
1619
|
-
null: /* @__PURE__ */ c((
|
|
1620
|
-
boolean: /* @__PURE__ */ c((
|
|
1621
|
-
Boolean: /* @__PURE__ */ c((
|
|
1622
|
-
number:
|
|
1623
|
-
Number:
|
|
1624
|
-
bigint:
|
|
1625
|
-
BigInt:
|
|
1626
|
-
string:
|
|
1627
|
-
String:
|
|
1628
|
-
function:
|
|
1629
|
-
Function:
|
|
1630
|
-
symbol:
|
|
1398
|
+
undefined: /* @__PURE__ */ c((e, t) => t.stylize("undefined", "undefined"), "undefined"),
|
|
1399
|
+
null: /* @__PURE__ */ c((e, t) => t.stylize("null", "null"), "null"),
|
|
1400
|
+
boolean: /* @__PURE__ */ c((e, t) => t.stylize(String(e), "boolean"), "boolean"),
|
|
1401
|
+
Boolean: /* @__PURE__ */ c((e, t) => t.stylize(String(e), "boolean"), "Boolean"),
|
|
1402
|
+
number: ke,
|
|
1403
|
+
Number: ke,
|
|
1404
|
+
bigint: ze,
|
|
1405
|
+
BigInt: ze,
|
|
1406
|
+
string: Ye,
|
|
1407
|
+
String: Ye,
|
|
1408
|
+
function: Be,
|
|
1409
|
+
Function: Be,
|
|
1410
|
+
symbol: Ue,
|
|
1631
1411
|
// A Symbol polyfill will return `Symbol` not `symbol` from typedetect
|
|
1632
|
-
Symbol:
|
|
1633
|
-
Array:
|
|
1634
|
-
Date:
|
|
1635
|
-
Map:
|
|
1636
|
-
Set:
|
|
1637
|
-
RegExp:
|
|
1412
|
+
Symbol: Ue,
|
|
1413
|
+
Array: lt,
|
|
1414
|
+
Date: at,
|
|
1415
|
+
Map: ft,
|
|
1416
|
+
Set: pt,
|
|
1417
|
+
RegExp: mt,
|
|
1638
1418
|
Promise: Tn,
|
|
1639
1419
|
// WeakSet, WeakMap are totally opaque to us
|
|
1640
|
-
WeakSet: /* @__PURE__ */ c((
|
|
1641
|
-
WeakMap: /* @__PURE__ */ c((
|
|
1642
|
-
Arguments:
|
|
1643
|
-
Int8Array:
|
|
1644
|
-
Uint8Array:
|
|
1645
|
-
Uint8ClampedArray:
|
|
1646
|
-
Int16Array:
|
|
1647
|
-
Uint16Array:
|
|
1648
|
-
Int32Array:
|
|
1649
|
-
Uint32Array:
|
|
1650
|
-
Float32Array:
|
|
1651
|
-
Float64Array:
|
|
1420
|
+
WeakSet: /* @__PURE__ */ c((e, t) => t.stylize("WeakSet{\u2026}", "special"), "WeakSet"),
|
|
1421
|
+
WeakMap: /* @__PURE__ */ c((e, t) => t.stylize("WeakMap{\u2026}", "special"), "WeakMap"),
|
|
1422
|
+
Arguments: yt,
|
|
1423
|
+
Int8Array: oe,
|
|
1424
|
+
Uint8Array: oe,
|
|
1425
|
+
Uint8ClampedArray: oe,
|
|
1426
|
+
Int16Array: oe,
|
|
1427
|
+
Uint16Array: oe,
|
|
1428
|
+
Int32Array: oe,
|
|
1429
|
+
Uint32Array: oe,
|
|
1430
|
+
Float32Array: oe,
|
|
1431
|
+
Float64Array: oe,
|
|
1652
1432
|
Generator: /* @__PURE__ */ c(() => "", "Generator"),
|
|
1653
1433
|
DataView: /* @__PURE__ */ c(() => "", "DataView"),
|
|
1654
1434
|
ArrayBuffer: /* @__PURE__ */ c(() => "", "ArrayBuffer"),
|
|
1655
|
-
Error:
|
|
1656
|
-
HTMLCollection:
|
|
1657
|
-
NodeList:
|
|
1658
|
-
}, rs = /* @__PURE__ */ c((
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
function
|
|
1662
|
-
let n = Sn(
|
|
1663
|
-
if (o === "object" && (o = os.call(
|
|
1664
|
-
return $n[o](
|
|
1665
|
-
if (r &&
|
|
1666
|
-
let i = rs(
|
|
1435
|
+
Error: dt,
|
|
1436
|
+
HTMLCollection: We,
|
|
1437
|
+
NodeList: We
|
|
1438
|
+
}, rs = /* @__PURE__ */ c((e, t, n) => bt in e && typeof e[bt] == "function" ? e[bt](t) : Se && Se in e && typeof e[Se] == "function" ? e[Se](
|
|
1439
|
+
t.depth, t) : "inspect" in e && typeof e.inspect == "function" ? e.inspect(t.depth, t) : "constructor" in e && Cn.has(e.constructor) ? Cn.get(
|
|
1440
|
+
e.constructor)(e, t) : On[n] ? On[n](e, t) : "", "inspectCustom"), os = Object.prototype.toString;
|
|
1441
|
+
function qe(e, t = {}) {
|
|
1442
|
+
let n = Sn(t, qe), { customInspect: r } = n, o = e === null ? "null" : typeof e;
|
|
1443
|
+
if (o === "object" && (o = os.call(e).slice(8, -1)), o in $n)
|
|
1444
|
+
return $n[o](e, n);
|
|
1445
|
+
if (r && e) {
|
|
1446
|
+
let i = rs(e, n, o);
|
|
1667
1447
|
if (i)
|
|
1668
|
-
return typeof i == "string" ? i :
|
|
1448
|
+
return typeof i == "string" ? i : qe(i, n);
|
|
1669
1449
|
}
|
|
1670
|
-
let s =
|
|
1671
|
-
return s === Object.prototype || s === null ?
|
|
1672
|
-
onstructor" in
|
|
1450
|
+
let s = e ? Object.getPrototypeOf(e) : !1;
|
|
1451
|
+
return s === Object.prototype || s === null ? pe(e, n) : e && typeof HTMLElement == "function" && e instanceof HTMLElement ? Ve(e, n) : "c\
|
|
1452
|
+
onstructor" in e ? e.constructor !== Object ? ht(e, n) : pe(e, n) : e === Object(e) ? pe(e, n) : n.stylize(String(e), o);
|
|
1673
1453
|
}
|
|
1674
|
-
c(
|
|
1454
|
+
c(qe, "inspect");
|
|
1675
1455
|
|
|
1676
1456
|
// ../node_modules/@vitest/utils/dist/chunk-_commonjsHelpers.js
|
|
1677
|
-
var {
|
|
1678
|
-
AsymmetricMatcher: is,
|
|
1679
|
-
DOMCollection: cs,
|
|
1680
|
-
DOMElement: us,
|
|
1681
|
-
Immutable: ls,
|
|
1682
|
-
ReactElement: as,
|
|
1683
|
-
ReactTestComponent: fs
|
|
1684
|
-
} = $t, wn = [
|
|
1457
|
+
var { AsymmetricMatcher: is, DOMCollection: cs, DOMElement: us, Immutable: ls, ReactElement: as, ReactTestComponent: fs } = $e, wn = [
|
|
1685
1458
|
fs,
|
|
1686
1459
|
as,
|
|
1687
1460
|
us,
|
|
@@ -1689,74 +1462,80 @@ var {
|
|
|
1689
1462
|
ls,
|
|
1690
1463
|
is
|
|
1691
1464
|
];
|
|
1692
|
-
function
|
|
1465
|
+
function ge(e, t = 10, { maxLength: n, ...r } = {}) {
|
|
1693
1466
|
let o = n ?? 1e4, s;
|
|
1694
1467
|
try {
|
|
1695
|
-
s =
|
|
1696
|
-
maxDepth:
|
|
1468
|
+
s = Q(e, {
|
|
1469
|
+
maxDepth: t,
|
|
1697
1470
|
escapeString: !1,
|
|
1698
|
-
// min: true,
|
|
1699
1471
|
plugins: wn,
|
|
1700
1472
|
...r
|
|
1701
1473
|
});
|
|
1702
1474
|
} catch {
|
|
1703
|
-
s =
|
|
1475
|
+
s = Q(e, {
|
|
1704
1476
|
callToJSON: !1,
|
|
1705
|
-
maxDepth:
|
|
1477
|
+
maxDepth: t,
|
|
1706
1478
|
escapeString: !1,
|
|
1707
|
-
// min: true,
|
|
1708
1479
|
plugins: wn,
|
|
1709
1480
|
...r
|
|
1710
1481
|
});
|
|
1711
1482
|
}
|
|
1712
|
-
return s.length >= o &&
|
|
1483
|
+
return s.length >= o && t > 1 ? ge(e, Math.floor(Math.min(t, Number.MAX_SAFE_INTEGER) / 2), {
|
|
1484
|
+
maxLength: n,
|
|
1485
|
+
...r
|
|
1486
|
+
}) : s;
|
|
1713
1487
|
}
|
|
1714
|
-
c(
|
|
1488
|
+
c(ge, "stringify");
|
|
1715
1489
|
var ms = /%[sdjifoOc%]/g;
|
|
1716
|
-
function An(...
|
|
1717
|
-
if (typeof
|
|
1490
|
+
function An(...e) {
|
|
1491
|
+
if (typeof e[0] != "string") {
|
|
1718
1492
|
let s = [];
|
|
1719
|
-
for (let i = 0; i <
|
|
1720
|
-
s.push(
|
|
1493
|
+
for (let i = 0; i < e.length; i++)
|
|
1494
|
+
s.push(we(e[i], {
|
|
1495
|
+
depth: 0,
|
|
1496
|
+
colors: !1
|
|
1497
|
+
}));
|
|
1721
1498
|
return s.join(" ");
|
|
1722
1499
|
}
|
|
1723
|
-
let
|
|
1500
|
+
let t = e.length, n = 1, r = e[0], o = String(r).replace(ms, (s) => {
|
|
1724
1501
|
if (s === "%%")
|
|
1725
1502
|
return "%";
|
|
1726
|
-
if (n >=
|
|
1503
|
+
if (n >= t)
|
|
1727
1504
|
return s;
|
|
1728
1505
|
switch (s) {
|
|
1729
1506
|
case "%s": {
|
|
1730
|
-
let i =
|
|
1507
|
+
let i = e[n++];
|
|
1731
1508
|
return typeof i == "bigint" ? `${i.toString()}n` : typeof i == "number" && i === 0 && 1 / i < 0 ? "-0" : typeof i == "object" && i !==
|
|
1732
|
-
null ? typeof i.toString == "function" && i.toString !== Object.prototype.toString ? i.toString() :
|
|
1733
|
-
|
|
1509
|
+
null ? typeof i.toString == "function" && i.toString !== Object.prototype.toString ? i.toString() : we(i, {
|
|
1510
|
+
depth: 0,
|
|
1511
|
+
colors: !1
|
|
1512
|
+
}) : String(i);
|
|
1734
1513
|
}
|
|
1735
1514
|
case "%d": {
|
|
1736
|
-
let i =
|
|
1515
|
+
let i = e[n++];
|
|
1737
1516
|
return typeof i == "bigint" ? `${i.toString()}n` : Number(i).toString();
|
|
1738
1517
|
}
|
|
1739
1518
|
case "%i": {
|
|
1740
|
-
let i =
|
|
1519
|
+
let i = e[n++];
|
|
1741
1520
|
return typeof i == "bigint" ? `${i.toString()}n` : Number.parseInt(String(i)).toString();
|
|
1742
1521
|
}
|
|
1743
1522
|
case "%f":
|
|
1744
|
-
return Number.parseFloat(String(
|
|
1523
|
+
return Number.parseFloat(String(e[n++])).toString();
|
|
1745
1524
|
case "%o":
|
|
1746
|
-
return
|
|
1525
|
+
return we(e[n++], {
|
|
1526
|
+
showHidden: !0,
|
|
1527
|
+
showProxy: !0
|
|
1528
|
+
});
|
|
1747
1529
|
case "%O":
|
|
1748
|
-
return
|
|
1530
|
+
return we(e[n++]);
|
|
1749
1531
|
case "%c":
|
|
1750
1532
|
return n++, "";
|
|
1751
1533
|
case "%j":
|
|
1752
1534
|
try {
|
|
1753
|
-
return JSON.stringify(
|
|
1535
|
+
return JSON.stringify(e[n++]);
|
|
1754
1536
|
} catch (i) {
|
|
1755
1537
|
let a = i.message;
|
|
1756
|
-
if (
|
|
1757
|
-
// chromium
|
|
1758
|
-
a.includes("circular structure") || a.includes("cyclic structures") || a.includes("cyclic object")
|
|
1759
|
-
)
|
|
1538
|
+
if (a.includes("circular structure") || a.includes("cyclic structures") || a.includes("cyclic object"))
|
|
1760
1539
|
return "[Circular]";
|
|
1761
1540
|
throw i;
|
|
1762
1541
|
}
|
|
@@ -1764,61 +1543,61 @@ function An(...t) {
|
|
|
1764
1543
|
return s;
|
|
1765
1544
|
}
|
|
1766
1545
|
});
|
|
1767
|
-
for (let s =
|
|
1768
|
-
s === null || typeof s != "object" ? o += ` ${s}` : o += ` ${
|
|
1546
|
+
for (let s = e[n]; n < t; s = e[++n])
|
|
1547
|
+
s === null || typeof s != "object" ? o += ` ${s}` : o += ` ${we(s)}`;
|
|
1769
1548
|
return o;
|
|
1770
1549
|
}
|
|
1771
1550
|
c(An, "format");
|
|
1772
|
-
function
|
|
1773
|
-
return
|
|
1551
|
+
function we(e, t = {}) {
|
|
1552
|
+
return t.truncate === 0 && (t.truncate = Number.POSITIVE_INFINITY), qe(e, t);
|
|
1774
1553
|
}
|
|
1775
|
-
c(
|
|
1776
|
-
function Rn(
|
|
1777
|
-
return
|
|
1554
|
+
c(we, "inspect");
|
|
1555
|
+
function Rn(e) {
|
|
1556
|
+
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1778
1557
|
}
|
|
1779
1558
|
c(Rn, "getDefaultExportFromCjs");
|
|
1780
1559
|
|
|
1781
1560
|
// ../node_modules/@vitest/utils/dist/helpers.js
|
|
1782
|
-
function ps(
|
|
1783
|
-
return
|
|
1561
|
+
function ps(e) {
|
|
1562
|
+
return e === Object.prototype || e === Function.prototype || e === RegExp.prototype;
|
|
1784
1563
|
}
|
|
1785
1564
|
c(ps, "isFinalObj");
|
|
1786
|
-
function
|
|
1787
|
-
return Object.prototype.toString.apply(
|
|
1565
|
+
function Ke(e) {
|
|
1566
|
+
return Object.prototype.toString.apply(e).slice(8, -1);
|
|
1788
1567
|
}
|
|
1789
|
-
c(
|
|
1790
|
-
function gs(
|
|
1791
|
-
let n = typeof
|
|
1792
|
-
Object.getOwnPropertyNames(
|
|
1568
|
+
c(Ke, "getType");
|
|
1569
|
+
function gs(e, t) {
|
|
1570
|
+
let n = typeof t == "function" ? t : (r) => t.add(r);
|
|
1571
|
+
Object.getOwnPropertyNames(e).forEach(n), Object.getOwnPropertySymbols(e).forEach(n);
|
|
1793
1572
|
}
|
|
1794
1573
|
c(gs, "collectOwnProperties");
|
|
1795
|
-
function
|
|
1796
|
-
let
|
|
1797
|
-
return ps(
|
|
1574
|
+
function Et(e) {
|
|
1575
|
+
let t = /* @__PURE__ */ new Set();
|
|
1576
|
+
return ps(e) ? [] : (gs(e, t), Array.from(t));
|
|
1798
1577
|
}
|
|
1799
|
-
c(
|
|
1578
|
+
c(Et, "getOwnProperties");
|
|
1800
1579
|
var Nn = { forceWritable: !1 };
|
|
1801
|
-
function
|
|
1802
|
-
return
|
|
1580
|
+
function _t(e, t = Nn) {
|
|
1581
|
+
return St(e, /* @__PURE__ */ new WeakMap(), t);
|
|
1803
1582
|
}
|
|
1804
|
-
c(
|
|
1805
|
-
function
|
|
1583
|
+
c(_t, "deepClone");
|
|
1584
|
+
function St(e, t, n = Nn) {
|
|
1806
1585
|
let r, o;
|
|
1807
|
-
if (
|
|
1808
|
-
return
|
|
1809
|
-
if (Array.isArray(
|
|
1810
|
-
for (o = Array.from({ length: r =
|
|
1811
|
-
o[r] =
|
|
1586
|
+
if (t.has(e))
|
|
1587
|
+
return t.get(e);
|
|
1588
|
+
if (Array.isArray(e)) {
|
|
1589
|
+
for (o = Array.from({ length: r = e.length }), t.set(e, o); r--; )
|
|
1590
|
+
o[r] = St(e[r], t, n);
|
|
1812
1591
|
return o;
|
|
1813
1592
|
}
|
|
1814
|
-
if (Object.prototype.toString.call(
|
|
1815
|
-
o = Object.create(Object.getPrototypeOf(
|
|
1816
|
-
let s =
|
|
1593
|
+
if (Object.prototype.toString.call(e) === "[object Object]") {
|
|
1594
|
+
o = Object.create(Object.getPrototypeOf(e)), t.set(e, o);
|
|
1595
|
+
let s = Et(e);
|
|
1817
1596
|
for (let i of s) {
|
|
1818
|
-
let a = Object.getOwnPropertyDescriptor(
|
|
1597
|
+
let a = Object.getOwnPropertyDescriptor(e, i);
|
|
1819
1598
|
if (!a)
|
|
1820
1599
|
continue;
|
|
1821
|
-
let l =
|
|
1600
|
+
let l = St(e[i], t, n);
|
|
1822
1601
|
n.forceWritable ? Object.defineProperty(o, i, {
|
|
1823
1602
|
enumerable: a.enumerable,
|
|
1824
1603
|
configurable: !0,
|
|
@@ -1836,9 +1615,9 @@ function Se(t, e, n = Nn) {
|
|
|
1836
1615
|
}
|
|
1837
1616
|
return o;
|
|
1838
1617
|
}
|
|
1839
|
-
return
|
|
1618
|
+
return e;
|
|
1840
1619
|
}
|
|
1841
|
-
c(
|
|
1620
|
+
c(St, "clone");
|
|
1842
1621
|
|
|
1843
1622
|
// ../node_modules/@vitest/utils/dist/diff.js
|
|
1844
1623
|
var U = -1, k = 1, x = 0, I = class {
|
|
@@ -1847,173 +1626,147 @@ var U = -1, k = 1, x = 0, I = class {
|
|
|
1847
1626
|
}
|
|
1848
1627
|
0;
|
|
1849
1628
|
1;
|
|
1850
|
-
constructor(
|
|
1851
|
-
this[0] =
|
|
1629
|
+
constructor(t, n) {
|
|
1630
|
+
this[0] = t, this[1] = n;
|
|
1852
1631
|
}
|
|
1853
1632
|
};
|
|
1854
|
-
function hs(
|
|
1855
|
-
if (!
|
|
1633
|
+
function hs(e, t) {
|
|
1634
|
+
if (!e || !t || e.charAt(0) !== t.charAt(0))
|
|
1856
1635
|
return 0;
|
|
1857
|
-
let n = 0, r = Math.min(
|
|
1636
|
+
let n = 0, r = Math.min(e.length, t.length), o = r, s = 0;
|
|
1858
1637
|
for (; n < o; )
|
|
1859
|
-
|
|
1638
|
+
e.substring(s, o) === t.substring(s, o) ? (n = o, s = n) : r = o, o = Math.floor((r - n) / 2 + n);
|
|
1860
1639
|
return o;
|
|
1861
1640
|
}
|
|
1862
1641
|
c(hs, "diff_commonPrefix");
|
|
1863
|
-
function qn(
|
|
1864
|
-
if (!
|
|
1642
|
+
function qn(e, t) {
|
|
1643
|
+
if (!e || !t || e.charAt(e.length - 1) !== t.charAt(t.length - 1))
|
|
1865
1644
|
return 0;
|
|
1866
|
-
let n = 0, r = Math.min(
|
|
1645
|
+
let n = 0, r = Math.min(e.length, t.length), o = r, s = 0;
|
|
1867
1646
|
for (; n < o; )
|
|
1868
|
-
|
|
1647
|
+
e.substring(e.length - o, e.length - s) === t.substring(t.length - o, t.length - s) ? (n = o, s = n) : r = o, o = Math.floor((r - n) / 2 +
|
|
1869
1648
|
n);
|
|
1870
1649
|
return o;
|
|
1871
1650
|
}
|
|
1872
1651
|
c(qn, "diff_commonSuffix");
|
|
1873
|
-
function Pn(
|
|
1874
|
-
let n =
|
|
1652
|
+
function Pn(e, t) {
|
|
1653
|
+
let n = e.length, r = t.length;
|
|
1875
1654
|
if (n === 0 || r === 0)
|
|
1876
1655
|
return 0;
|
|
1877
|
-
n > r ?
|
|
1656
|
+
n > r ? e = e.substring(n - r) : n < r && (t = t.substring(0, n));
|
|
1878
1657
|
let o = Math.min(n, r);
|
|
1879
|
-
if (
|
|
1658
|
+
if (e === t)
|
|
1880
1659
|
return o;
|
|
1881
1660
|
let s = 0, i = 1;
|
|
1882
1661
|
for (; ; ) {
|
|
1883
|
-
let a =
|
|
1662
|
+
let a = e.substring(o - i), l = t.indexOf(a);
|
|
1884
1663
|
if (l === -1)
|
|
1885
1664
|
return s;
|
|
1886
|
-
i += l, (l === 0 ||
|
|
1665
|
+
i += l, (l === 0 || e.substring(o - i) === t.substring(0, i)) && (s = i, i++);
|
|
1887
1666
|
}
|
|
1888
1667
|
}
|
|
1889
1668
|
c(Pn, "diff_commonOverlap_");
|
|
1890
|
-
function ys(
|
|
1891
|
-
let
|
|
1892
|
-
for (; s <
|
|
1893
|
-
|
|
1894
|
-
o.length <= Math.max(i, a) && o.length <= Math.max(l, m) && (
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
S >= y ? (S >= p.length / 2 || S >= f.length / 2) && (t.splice(
|
|
1903
|
-
s,
|
|
1904
|
-
0,
|
|
1905
|
-
new I(x, f.substring(0, S))
|
|
1906
|
-
), t[s - 1][1] = p.substring(
|
|
1907
|
-
0,
|
|
1908
|
-
p.length - S
|
|
1909
|
-
), t[s + 1][1] = f.substring(S), s++) : (y >= p.length / 2 || y >= f.length / 2) && (t.splice(
|
|
1910
|
-
s,
|
|
1911
|
-
0,
|
|
1912
|
-
new I(x, p.substring(0, y))
|
|
1913
|
-
), t[s - 1][0] = k, t[s - 1][1] = f.substring(
|
|
1914
|
-
0,
|
|
1915
|
-
f.length - y
|
|
1916
|
-
), t[s + 1][0] = U, t[s + 1][1] = p.substring(y), s++), s++;
|
|
1669
|
+
function ys(e) {
|
|
1670
|
+
let t = !1, n = [], r = 0, o = null, s = 0, i = 0, a = 0, l = 0, m = 0;
|
|
1671
|
+
for (; s < e.length; )
|
|
1672
|
+
e[s][0] === x ? (n[r++] = s, i = l, a = m, l = 0, m = 0, o = e[s][1]) : (e[s][0] === k ? l += e[s][1].length : m += e[s][1].length, o &&
|
|
1673
|
+
o.length <= Math.max(i, a) && o.length <= Math.max(l, m) && (e.splice(n[r - 1], 0, new I(U, o)), e[n[r - 1] + 1][0] = k, r--, r--, s = r >
|
|
1674
|
+
0 ? n[r - 1] : -1, i = 0, a = 0, l = 0, m = 0, o = null, t = !0)), s++;
|
|
1675
|
+
for (t && Kn(e), Ss(e), s = 1; s < e.length; ) {
|
|
1676
|
+
if (e[s - 1][0] === U && e[s][0] === k) {
|
|
1677
|
+
let p = e[s - 1][1], f = e[s][1], b = Pn(p, f), y = Pn(f, p);
|
|
1678
|
+
b >= y ? (b >= p.length / 2 || b >= f.length / 2) && (e.splice(s, 0, new I(x, f.substring(0, b))), e[s - 1][1] = p.substring(0, p.length -
|
|
1679
|
+
b), e[s + 1][1] = f.substring(b), s++) : (y >= p.length / 2 || y >= f.length / 2) && (e.splice(s, 0, new I(x, p.substring(0, y))), e[s -
|
|
1680
|
+
1][0] = k, e[s - 1][1] = f.substring(0, f.length - y), e[s + 1][0] = U, e[s + 1][1] = p.substring(y), s++), s++;
|
|
1917
1681
|
}
|
|
1918
1682
|
s++;
|
|
1919
1683
|
}
|
|
1920
1684
|
}
|
|
1921
1685
|
c(ys, "diff_cleanupSemantic");
|
|
1922
1686
|
var In = /[^a-z0-9]/i, Mn = /\s/, Ln = /[\r\n]/, ds = /\n\r?\n$/, bs = /^\r?\n\r?\n/;
|
|
1923
|
-
function Ss(
|
|
1924
|
-
let
|
|
1925
|
-
for (;
|
|
1926
|
-
if (t
|
|
1927
|
-
let n = t
|
|
1687
|
+
function Ss(e) {
|
|
1688
|
+
let t = 1;
|
|
1689
|
+
for (; t < e.length - 1; ) {
|
|
1690
|
+
if (e[t - 1][0] === x && e[t + 1][0] === x) {
|
|
1691
|
+
let n = e[t - 1][1], r = e[t][1], o = e[t + 1][1], s = qn(n, r);
|
|
1928
1692
|
if (s) {
|
|
1929
1693
|
let p = r.substring(r.length - s);
|
|
1930
1694
|
n = n.substring(0, n.length - s), r = p + r.substring(0, r.length - s), o = p + o;
|
|
1931
1695
|
}
|
|
1932
|
-
let i = n, a = r, l = o, m =
|
|
1696
|
+
let i = n, a = r, l = o, m = Ge(n, r) + Ge(r, o);
|
|
1933
1697
|
for (; r.charAt(0) === o.charAt(0); ) {
|
|
1934
1698
|
n += r.charAt(0), r = r.substring(1) + o.charAt(0), o = o.substring(1);
|
|
1935
|
-
let p =
|
|
1699
|
+
let p = Ge(n, r) + Ge(r, o);
|
|
1936
1700
|
p >= m && (m = p, i = n, a = r, l = o);
|
|
1937
1701
|
}
|
|
1938
|
-
t
|
|
1702
|
+
e[t - 1][1] !== i && (i ? e[t - 1][1] = i : (e.splice(t - 1, 1), t--), e[t][1] = a, l ? e[t + 1][1] = l : (e.splice(t + 1, 1), t--));
|
|
1939
1703
|
}
|
|
1940
|
-
|
|
1704
|
+
t++;
|
|
1941
1705
|
}
|
|
1942
1706
|
}
|
|
1943
1707
|
c(Ss, "diff_cleanupSemanticLossless");
|
|
1944
|
-
function Kn(
|
|
1945
|
-
|
|
1946
|
-
let
|
|
1947
|
-
for (;
|
|
1948
|
-
switch (t
|
|
1708
|
+
function Kn(e) {
|
|
1709
|
+
e.push(new I(x, ""));
|
|
1710
|
+
let t = 0, n = 0, r = 0, o = "", s = "", i;
|
|
1711
|
+
for (; t < e.length; )
|
|
1712
|
+
switch (e[t][0]) {
|
|
1949
1713
|
case k:
|
|
1950
|
-
r++, s += t
|
|
1714
|
+
r++, s += e[t][1], t++;
|
|
1951
1715
|
break;
|
|
1952
1716
|
case U:
|
|
1953
|
-
n++, o += t
|
|
1717
|
+
n++, o += e[t][1], t++;
|
|
1954
1718
|
break;
|
|
1955
1719
|
case x:
|
|
1956
|
-
n + r > 1 ? (n !== 0 && r !== 0 && (i = hs(s, o), i !== 0 && (
|
|
1957
|
-
substring(0, i) : (
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
), e++), s = s.substring(i), o = o.substring(i)), i = qn(s, o), i !== 0 && (t[e][1] = s.substring(s.length - i) + t[e][1], s = s.substring(
|
|
1962
|
-
0,
|
|
1963
|
-
s.length - i
|
|
1964
|
-
), o = o.substring(
|
|
1965
|
-
0,
|
|
1966
|
-
o.length - i
|
|
1967
|
-
))), e -= n + r, t.splice(e, n + r), o.length && (t.splice(e, 0, new I(U, o)), e++), s.length && (t.splice(e, 0, new I(k, s)), e++),
|
|
1968
|
-
e++) : e !== 0 && t[e - 1][0] === x ? (t[e - 1][1] += t[e][1], t.splice(e, 1)) : e++, r = 0, n = 0, o = "", s = "";
|
|
1720
|
+
n + r > 1 ? (n !== 0 && r !== 0 && (i = hs(s, o), i !== 0 && (t - n - r > 0 && e[t - n - r - 1][0] === x ? e[t - n - r - 1][1] += s.
|
|
1721
|
+
substring(0, i) : (e.splice(0, 0, new I(x, s.substring(0, i))), t++), s = s.substring(i), o = o.substring(i)), i = qn(s, o), i !== 0 &&
|
|
1722
|
+
(e[t][1] = s.substring(s.length - i) + e[t][1], s = s.substring(0, s.length - i), o = o.substring(0, o.length - i))), t -= n + r, e.
|
|
1723
|
+
splice(t, n + r), o.length && (e.splice(t, 0, new I(U, o)), t++), s.length && (e.splice(t, 0, new I(k, s)), t++), t++) : t !== 0 && e[t -
|
|
1724
|
+
1][0] === x ? (e[t - 1][1] += e[t][1], e.splice(t, 1)) : t++, r = 0, n = 0, o = "", s = "";
|
|
1969
1725
|
break;
|
|
1970
1726
|
}
|
|
1971
|
-
|
|
1727
|
+
e[e.length - 1][1] === "" && e.pop();
|
|
1972
1728
|
let a = !1;
|
|
1973
|
-
for (
|
|
1974
|
-
t
|
|
1975
|
-
|
|
1976
|
-
) === t[e - 1][1]
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
), t[e + 1][1] = t[e - 1][1] + t[e + 1][1], t.splice(e - 1, 1), a = !0) : t[e][1].substring(0, t[e + 1][1].length) === t[e + 1][1] && (t[e -
|
|
1980
|
-
1][1] += t[e + 1][1], t[e][1] = t[e][1].substring(t[e + 1][1].length) + t[e + 1][1], t.splice(e + 1, 1), a = !0)), e++;
|
|
1981
|
-
a && Kn(t);
|
|
1729
|
+
for (t = 1; t < e.length - 1; )
|
|
1730
|
+
e[t - 1][0] === x && e[t + 1][0] === x && (e[t][1].substring(e[t][1].length - e[t - 1][1].length) === e[t - 1][1] ? (e[t][1] = e[t - 1][1] +
|
|
1731
|
+
e[t][1].substring(0, e[t][1].length - e[t - 1][1].length), e[t + 1][1] = e[t - 1][1] + e[t + 1][1], e.splice(t - 1, 1), a = !0) : e[t][1].
|
|
1732
|
+
substring(0, e[t + 1][1].length) === e[t + 1][1] && (e[t - 1][1] += e[t + 1][1], e[t][1] = e[t][1].substring(e[t + 1][1].length) + e[t +
|
|
1733
|
+
1][1], e.splice(t + 1, 1), a = !0)), t++;
|
|
1734
|
+
a && Kn(e);
|
|
1982
1735
|
}
|
|
1983
1736
|
c(Kn, "diff_cleanupMerge");
|
|
1984
|
-
function
|
|
1985
|
-
if (!
|
|
1737
|
+
function Ge(e, t) {
|
|
1738
|
+
if (!e || !t)
|
|
1986
1739
|
return 6;
|
|
1987
|
-
let n =
|
|
1988
|
-
match(Ln), m = a && r.match(Ln), p = l &&
|
|
1740
|
+
let n = e.charAt(e.length - 1), r = t.charAt(0), o = n.match(In), s = r.match(In), i = o && n.match(Mn), a = s && r.match(Mn), l = i && n.
|
|
1741
|
+
match(Ln), m = a && r.match(Ln), p = l && e.match(ds), f = m && t.match(bs);
|
|
1989
1742
|
return p || f ? 5 : l || m ? 4 : o && !i && a ? 3 : i || a ? 2 : o || s ? 1 : 0;
|
|
1990
1743
|
}
|
|
1991
|
-
c(
|
|
1744
|
+
c(Ge, "diff_cleanupSemanticScore_");
|
|
1992
1745
|
var Gn = "Compared values have no visual difference.", Es = "Compared values serialize to the same structure.\nPrinting internal object struc\
|
|
1993
|
-
ture without calling `toJSON` instead.",
|
|
1746
|
+
ture without calling `toJSON` instead.", He = {}, xn;
|
|
1994
1747
|
function _s() {
|
|
1995
|
-
if (xn) return
|
|
1996
|
-
xn = 1, Object.defineProperty(
|
|
1748
|
+
if (xn) return He;
|
|
1749
|
+
xn = 1, Object.defineProperty(He, "__esModule", {
|
|
1997
1750
|
value: !0
|
|
1998
|
-
}),
|
|
1999
|
-
let
|
|
1751
|
+
}), He.default = b;
|
|
1752
|
+
let e = "diff-sequences", t = 0, n = /* @__PURE__ */ c((y, g, u, h, S) => {
|
|
2000
1753
|
let _ = 0;
|
|
2001
|
-
for (; y < g && u < h &&
|
|
1754
|
+
for (; y < g && u < h && S(y, u); )
|
|
2002
1755
|
y += 1, u += 1, _ += 1;
|
|
2003
1756
|
return _;
|
|
2004
|
-
}, "countCommonItemsF"), r = /* @__PURE__ */ c((y, g, u, h,
|
|
1757
|
+
}, "countCommonItemsF"), r = /* @__PURE__ */ c((y, g, u, h, S) => {
|
|
2005
1758
|
let _ = 0;
|
|
2006
|
-
for (; y <= g && u <= h &&
|
|
1759
|
+
for (; y <= g && u <= h && S(g, h); )
|
|
2007
1760
|
g -= 1, h -= 1, _ += 1;
|
|
2008
1761
|
return _;
|
|
2009
|
-
}, "countCommonItemsR"), o = /* @__PURE__ */ c((y, g, u, h,
|
|
1762
|
+
}, "countCommonItemsR"), o = /* @__PURE__ */ c((y, g, u, h, S, _, O) => {
|
|
2010
1763
|
let d = 0, E = -y, $ = _[d], T = $;
|
|
2011
1764
|
_[d] += n(
|
|
2012
1765
|
$ + 1,
|
|
2013
1766
|
g,
|
|
2014
1767
|
h + $ - E + 1,
|
|
2015
1768
|
u,
|
|
2016
|
-
|
|
1769
|
+
S
|
|
2017
1770
|
);
|
|
2018
1771
|
let R = y < O ? y : O;
|
|
2019
1772
|
for (d += 1, E += 2; d <= R; d += 1, E += 2) {
|
|
@@ -2021,17 +1774,17 @@ function _s() {
|
|
|
2021
1774
|
$ = _[d];
|
|
2022
1775
|
else if ($ = T + 1, g <= $)
|
|
2023
1776
|
return d - 1;
|
|
2024
|
-
T = _[d], _[d] = $ + n($ + 1, g, h + $ - E + 1, u,
|
|
1777
|
+
T = _[d], _[d] = $ + n($ + 1, g, h + $ - E + 1, u, S);
|
|
2025
1778
|
}
|
|
2026
1779
|
return O;
|
|
2027
|
-
}, "extendPathsF"), s = /* @__PURE__ */ c((y, g, u, h,
|
|
1780
|
+
}, "extendPathsF"), s = /* @__PURE__ */ c((y, g, u, h, S, _, O) => {
|
|
2028
1781
|
let d = 0, E = y, $ = _[d], T = $;
|
|
2029
1782
|
_[d] -= r(
|
|
2030
1783
|
g,
|
|
2031
1784
|
$ - 1,
|
|
2032
1785
|
u,
|
|
2033
1786
|
h + $ - E - 1,
|
|
2034
|
-
|
|
1787
|
+
S
|
|
2035
1788
|
);
|
|
2036
1789
|
let R = y < O ? y : O;
|
|
2037
1790
|
for (d += 1, E -= 2; d <= R; d += 1, E -= 2) {
|
|
@@ -2044,80 +1797,80 @@ function _s() {
|
|
|
2044
1797
|
$ - 1,
|
|
2045
1798
|
u,
|
|
2046
1799
|
h + $ - E - 1,
|
|
2047
|
-
|
|
1800
|
+
S
|
|
2048
1801
|
);
|
|
2049
1802
|
}
|
|
2050
1803
|
return O;
|
|
2051
|
-
}, "extendPathsR"), i = /* @__PURE__ */ c((y, g, u, h,
|
|
2052
|
-
let R = h - g, J = u - g, L =
|
|
1804
|
+
}, "extendPathsR"), i = /* @__PURE__ */ c((y, g, u, h, S, _, O, d, E, $, T) => {
|
|
1805
|
+
let R = h - g, J = u - g, L = S - h - J, z = -L - (y - 1), X = -L + (y - 1), V = t, M = y < d ? y : d;
|
|
2053
1806
|
for (let F = 0, D = -y; F <= M; F += 1, D += 2) {
|
|
2054
|
-
let Z = F === 0 || F !== y && V < O[F], B = Z ? O[F] : V, K = Z ? B : B + 1,
|
|
1807
|
+
let Z = F === 0 || F !== y && V < O[F], B = Z ? O[F] : V, K = Z ? B : B + 1, se = R + K - D, G = n(
|
|
2055
1808
|
K + 1,
|
|
2056
1809
|
u,
|
|
2057
|
-
|
|
2058
|
-
|
|
1810
|
+
se + 1,
|
|
1811
|
+
S,
|
|
2059
1812
|
_
|
|
2060
1813
|
), H = K + G;
|
|
2061
1814
|
if (V = O[F], O[F] = H, z <= D && D <= X) {
|
|
2062
|
-
let
|
|
2063
|
-
if (
|
|
2064
|
-
let
|
|
1815
|
+
let ce = (y - 1 - (D + L)) / 2;
|
|
1816
|
+
if (ce <= $ && E[ce] - 1 <= H) {
|
|
1817
|
+
let v = R + B - (Z ? D + 1 : D - 1), q = r(
|
|
2065
1818
|
g,
|
|
2066
1819
|
B,
|
|
2067
1820
|
h,
|
|
2068
|
-
|
|
1821
|
+
v,
|
|
2069
1822
|
_
|
|
2070
|
-
),
|
|
2071
|
-
T.nChangePreceding = y - 1, y - 1 ===
|
|
2072
|
-
|
|
2073
|
-
aCommonFollowing = K + 1, T.bCommonFollowing =
|
|
2074
|
-
let
|
|
2075
|
-
return T.nChangeFollowing = y - 1, y - 1 === u +
|
|
2076
|
-
|
|
1823
|
+
), ie = B - q, de = v - q, ae = ie + 1, Te = de + 1;
|
|
1824
|
+
T.nChangePreceding = y - 1, y - 1 === ae + Te - g - h ? (T.aEndPreceding = g, T.bEndPreceding = h) : (T.aEndPreceding = ae, T.bEndPreceding =
|
|
1825
|
+
Te), T.nCommonPreceding = q, q !== 0 && (T.aCommonPreceding = ae, T.bCommonPreceding = Te), T.nCommonFollowing = G, G !== 0 && (T.
|
|
1826
|
+
aCommonFollowing = K + 1, T.bCommonFollowing = se + 1);
|
|
1827
|
+
let Ae = H + 1, Re = se + G + 1;
|
|
1828
|
+
return T.nChangeFollowing = y - 1, y - 1 === u + S - Ae - Re ? (T.aStartFollowing = u, T.bStartFollowing = S) : (T.aStartFollowing =
|
|
1829
|
+
Ae, T.bStartFollowing = Re), !0;
|
|
2077
1830
|
}
|
|
2078
1831
|
}
|
|
2079
1832
|
}
|
|
2080
1833
|
return !1;
|
|
2081
|
-
}, "extendOverlappablePathsF"), a = /* @__PURE__ */ c((y, g, u, h,
|
|
2082
|
-
let R =
|
|
1834
|
+
}, "extendOverlappablePathsF"), a = /* @__PURE__ */ c((y, g, u, h, S, _, O, d, E, $, T) => {
|
|
1835
|
+
let R = S - u, J = u - g, L = S - h - J, z = L - y, X = L + y, V = t, M = y < $ ? y : $;
|
|
2083
1836
|
for (let F = 0, D = y; F <= M; F += 1, D -= 2) {
|
|
2084
|
-
let Z = F === 0 || F !== y && E[F] < V, B = Z ? E[F] : V, K = Z ? B : B - 1,
|
|
1837
|
+
let Z = F === 0 || F !== y && E[F] < V, B = Z ? E[F] : V, K = Z ? B : B - 1, se = R + K - D, G = r(
|
|
2085
1838
|
g,
|
|
2086
1839
|
K - 1,
|
|
2087
1840
|
h,
|
|
2088
|
-
|
|
1841
|
+
se - 1,
|
|
2089
1842
|
_
|
|
2090
1843
|
), H = K - G;
|
|
2091
1844
|
if (V = E[F], E[F] = H, z <= D && D <= X) {
|
|
2092
|
-
let
|
|
2093
|
-
if (
|
|
2094
|
-
let
|
|
2095
|
-
if (T.nChangePreceding = y, y === H +
|
|
2096
|
-
|
|
2097
|
-
T.nCommonFollowing = 0, T.aStartFollowing = u, T.bStartFollowing =
|
|
1845
|
+
let ce = (y + (D - L)) / 2;
|
|
1846
|
+
if (ce <= d && H - 1 <= O[ce]) {
|
|
1847
|
+
let v = se - G;
|
|
1848
|
+
if (T.nChangePreceding = y, y === H + v - g - h ? (T.aEndPreceding = g, T.bEndPreceding = h) : (T.aEndPreceding = H, T.bEndPreceding =
|
|
1849
|
+
v), T.nCommonPreceding = G, G !== 0 && (T.aCommonPreceding = H, T.bCommonPreceding = v), T.nChangeFollowing = y - 1, y === 1)
|
|
1850
|
+
T.nCommonFollowing = 0, T.aStartFollowing = u, T.bStartFollowing = S;
|
|
2098
1851
|
else {
|
|
2099
|
-
let q = R + B - (Z ? D - 1 : D + 1),
|
|
1852
|
+
let q = R + B - (Z ? D - 1 : D + 1), ie = n(
|
|
2100
1853
|
B,
|
|
2101
1854
|
u,
|
|
2102
1855
|
q,
|
|
2103
|
-
|
|
1856
|
+
S,
|
|
2104
1857
|
_
|
|
2105
1858
|
);
|
|
2106
|
-
T.nCommonFollowing =
|
|
2107
|
-
let
|
|
2108
|
-
y - 1 === u +
|
|
1859
|
+
T.nCommonFollowing = ie, ie !== 0 && (T.aCommonFollowing = B, T.bCommonFollowing = q);
|
|
1860
|
+
let de = B + ie, ae = q + ie;
|
|
1861
|
+
y - 1 === u + S - de - ae ? (T.aStartFollowing = u, T.bStartFollowing = S) : (T.aStartFollowing = de, T.bStartFollowing = ae);
|
|
2109
1862
|
}
|
|
2110
1863
|
return !0;
|
|
2111
1864
|
}
|
|
2112
1865
|
}
|
|
2113
1866
|
}
|
|
2114
1867
|
return !1;
|
|
2115
|
-
}, "extendOverlappablePathsR"), l = /* @__PURE__ */ c((y, g, u, h,
|
|
2116
|
-
let $ = h - g, T =
|
|
2117
|
-
if (O[0] = g - 1, d[0] = u,
|
|
2118
|
-
let X = (y ||
|
|
1868
|
+
}, "extendOverlappablePathsR"), l = /* @__PURE__ */ c((y, g, u, h, S, _, O, d, E) => {
|
|
1869
|
+
let $ = h - g, T = S - u, R = u - g, J = S - h, te = J - R, L = R, z = R;
|
|
1870
|
+
if (O[0] = g - 1, d[0] = u, te % 2 === 0) {
|
|
1871
|
+
let X = (y || te) / 2, V = (R + J) / 2;
|
|
2119
1872
|
for (let M = 1; M <= V; M += 1)
|
|
2120
|
-
if (L = o(M, u,
|
|
1873
|
+
if (L = o(M, u, S, $, _, O, L), M < X)
|
|
2121
1874
|
z = s(M, g, h, T, _, d, z);
|
|
2122
1875
|
else if (
|
|
2123
1876
|
// If a reverse path overlaps a forward path in the same diagonal,
|
|
@@ -2127,7 +1880,7 @@ function _s() {
|
|
|
2127
1880
|
g,
|
|
2128
1881
|
u,
|
|
2129
1882
|
h,
|
|
2130
|
-
|
|
1883
|
+
S,
|
|
2131
1884
|
_,
|
|
2132
1885
|
O,
|
|
2133
1886
|
L,
|
|
@@ -2138,8 +1891,8 @@ function _s() {
|
|
|
2138
1891
|
)
|
|
2139
1892
|
return;
|
|
2140
1893
|
} else {
|
|
2141
|
-
let X = ((y ||
|
|
2142
|
-
for (L = o(M, u,
|
|
1894
|
+
let X = ((y || te) + 1) / 2, V = (R + J + 1) / 2, M = 1;
|
|
1895
|
+
for (L = o(M, u, S, $, _, O, L), M += 1; M <= V; M += 1)
|
|
2143
1896
|
if (z = s(
|
|
2144
1897
|
M - 1,
|
|
2145
1898
|
g,
|
|
@@ -2149,7 +1902,7 @@ function _s() {
|
|
|
2149
1902
|
d,
|
|
2150
1903
|
z
|
|
2151
1904
|
), M < X)
|
|
2152
|
-
L = o(M, u,
|
|
1905
|
+
L = o(M, u, S, $, _, O, L);
|
|
2153
1906
|
else if (
|
|
2154
1907
|
// If a forward path overlaps a reverse path in the same diagonal,
|
|
2155
1908
|
// return a division of the index intervals at the middle change.
|
|
@@ -2158,7 +1911,7 @@ function _s() {
|
|
|
2158
1911
|
g,
|
|
2159
1912
|
u,
|
|
2160
1913
|
h,
|
|
2161
|
-
|
|
1914
|
+
S,
|
|
2162
1915
|
_,
|
|
2163
1916
|
O,
|
|
2164
1917
|
L,
|
|
@@ -2170,21 +1923,21 @@ function _s() {
|
|
|
2170
1923
|
return;
|
|
2171
1924
|
}
|
|
2172
1925
|
throw new Error(
|
|
2173
|
-
`${
|
|
1926
|
+
`${e}: no overlap aStart=${g} aEnd=${u} bStart=${h} bEnd=${S}`
|
|
2174
1927
|
);
|
|
2175
|
-
}, "divide"), m = /* @__PURE__ */ c((y, g, u, h,
|
|
2176
|
-
if (
|
|
1928
|
+
}, "divide"), m = /* @__PURE__ */ c((y, g, u, h, S, _, O, d, E, $) => {
|
|
1929
|
+
if (S - h < u - g) {
|
|
2177
1930
|
if (_ = !_, _ && O.length === 1) {
|
|
2178
|
-
let { foundSubsequence: H, isCommon:
|
|
1931
|
+
let { foundSubsequence: H, isCommon: ce } = O[0];
|
|
2179
1932
|
O[1] = {
|
|
2180
|
-
foundSubsequence: /* @__PURE__ */ c((
|
|
2181
|
-
H(
|
|
1933
|
+
foundSubsequence: /* @__PURE__ */ c((v, q, ie) => {
|
|
1934
|
+
H(v, ie, q);
|
|
2182
1935
|
}, "foundSubsequence"),
|
|
2183
|
-
isCommon: /* @__PURE__ */ c((
|
|
1936
|
+
isCommon: /* @__PURE__ */ c((v, q) => ce(q, v), "isCommon")
|
|
2184
1937
|
};
|
|
2185
1938
|
}
|
|
2186
|
-
let
|
|
2187
|
-
g = h, u =
|
|
1939
|
+
let se = g, G = u;
|
|
1940
|
+
g = h, u = S, h = se, S = G;
|
|
2188
1941
|
}
|
|
2189
1942
|
let { foundSubsequence: T, isCommon: R } = O[_ ? 1 : 0];
|
|
2190
1943
|
l(
|
|
@@ -2192,7 +1945,7 @@ function _s() {
|
|
|
2192
1945
|
g,
|
|
2193
1946
|
u,
|
|
2194
1947
|
h,
|
|
2195
|
-
|
|
1948
|
+
S,
|
|
2196
1949
|
R,
|
|
2197
1950
|
d,
|
|
2198
1951
|
E,
|
|
@@ -2200,7 +1953,7 @@ function _s() {
|
|
|
2200
1953
|
);
|
|
2201
1954
|
let {
|
|
2202
1955
|
nChangePreceding: J,
|
|
2203
|
-
aEndPreceding:
|
|
1956
|
+
aEndPreceding: te,
|
|
2204
1957
|
bEndPreceding: L,
|
|
2205
1958
|
nCommonPreceding: z,
|
|
2206
1959
|
aCommonPreceding: X,
|
|
@@ -2212,10 +1965,10 @@ function _s() {
|
|
|
2212
1965
|
aStartFollowing: B,
|
|
2213
1966
|
bStartFollowing: K
|
|
2214
1967
|
} = $;
|
|
2215
|
-
g <
|
|
1968
|
+
g < te && h < L && m(
|
|
2216
1969
|
J,
|
|
2217
1970
|
g,
|
|
2218
|
-
|
|
1971
|
+
te,
|
|
2219
1972
|
h,
|
|
2220
1973
|
L,
|
|
2221
1974
|
_,
|
|
@@ -2223,12 +1976,12 @@ function _s() {
|
|
|
2223
1976
|
d,
|
|
2224
1977
|
E,
|
|
2225
1978
|
$
|
|
2226
|
-
), z !== 0 && T(z, X, V), M !== 0 && T(M, F, D), B < u && K <
|
|
1979
|
+
), z !== 0 && T(z, X, V), M !== 0 && T(M, F, D), B < u && K < S && m(
|
|
2227
1980
|
Z,
|
|
2228
1981
|
B,
|
|
2229
1982
|
u,
|
|
2230
1983
|
K,
|
|
2231
|
-
|
|
1984
|
+
S,
|
|
2232
1985
|
_,
|
|
2233
1986
|
O,
|
|
2234
1987
|
d,
|
|
@@ -2237,27 +1990,27 @@ function _s() {
|
|
|
2237
1990
|
);
|
|
2238
1991
|
}, "findSubsequences"), p = /* @__PURE__ */ c((y, g) => {
|
|
2239
1992
|
if (typeof g != "number")
|
|
2240
|
-
throw new TypeError(`${
|
|
1993
|
+
throw new TypeError(`${e}: ${y} typeof ${typeof g} is not a number`);
|
|
2241
1994
|
if (!Number.isSafeInteger(g))
|
|
2242
|
-
throw new RangeError(`${
|
|
1995
|
+
throw new RangeError(`${e}: ${y} value ${g} is not a safe integer`);
|
|
2243
1996
|
if (g < 0)
|
|
2244
|
-
throw new RangeError(`${
|
|
1997
|
+
throw new RangeError(`${e}: ${y} value ${g} is a negative integer`);
|
|
2245
1998
|
}, "validateLength"), f = /* @__PURE__ */ c((y, g) => {
|
|
2246
1999
|
let u = typeof g;
|
|
2247
2000
|
if (u !== "function")
|
|
2248
|
-
throw new TypeError(`${
|
|
2001
|
+
throw new TypeError(`${e}: ${y} typeof ${u} is not a function`);
|
|
2249
2002
|
}, "validateCallback");
|
|
2250
|
-
function
|
|
2003
|
+
function b(y, g, u, h) {
|
|
2251
2004
|
p("aLength", y), p("bLength", g), f("isCommon", u), f("foundSubsequence", h);
|
|
2252
|
-
let
|
|
2253
|
-
if (
|
|
2254
|
-
let _ =
|
|
2005
|
+
let S = n(0, y, 0, g, u);
|
|
2006
|
+
if (S !== 0 && h(S, 0, 0), y !== S || g !== S) {
|
|
2007
|
+
let _ = S, O = S, d = r(
|
|
2255
2008
|
_,
|
|
2256
2009
|
y - 1,
|
|
2257
2010
|
O,
|
|
2258
2011
|
g - 1,
|
|
2259
2012
|
u
|
|
2260
|
-
), E = y - d, $ = g - d, T =
|
|
2013
|
+
), E = y - d, $ = g - d, T = S + d;
|
|
2261
2014
|
y !== T && g !== T && m(
|
|
2262
2015
|
0,
|
|
2263
2016
|
_,
|
|
@@ -2271,98 +2024,58 @@ function _s() {
|
|
|
2271
2024
|
isCommon: u
|
|
2272
2025
|
}
|
|
2273
2026
|
],
|
|
2274
|
-
[
|
|
2275
|
-
[
|
|
2027
|
+
[t],
|
|
2028
|
+
[t],
|
|
2276
2029
|
{
|
|
2277
|
-
aCommonFollowing:
|
|
2278
|
-
aCommonPreceding:
|
|
2279
|
-
aEndPreceding:
|
|
2280
|
-
aStartFollowing:
|
|
2281
|
-
bCommonFollowing:
|
|
2282
|
-
bCommonPreceding:
|
|
2283
|
-
bEndPreceding:
|
|
2284
|
-
bStartFollowing:
|
|
2285
|
-
nChangeFollowing:
|
|
2286
|
-
nChangePreceding:
|
|
2287
|
-
nCommonFollowing:
|
|
2288
|
-
nCommonPreceding:
|
|
2030
|
+
aCommonFollowing: t,
|
|
2031
|
+
aCommonPreceding: t,
|
|
2032
|
+
aEndPreceding: t,
|
|
2033
|
+
aStartFollowing: t,
|
|
2034
|
+
bCommonFollowing: t,
|
|
2035
|
+
bCommonPreceding: t,
|
|
2036
|
+
bEndPreceding: t,
|
|
2037
|
+
bStartFollowing: t,
|
|
2038
|
+
nChangeFollowing: t,
|
|
2039
|
+
nChangePreceding: t,
|
|
2040
|
+
nCommonFollowing: t,
|
|
2041
|
+
nCommonPreceding: t
|
|
2289
2042
|
}
|
|
2290
2043
|
), d !== 0 && h(d, E, $);
|
|
2291
2044
|
}
|
|
2292
2045
|
}
|
|
2293
|
-
return c(
|
|
2046
|
+
return c(b, "diffSequence"), He;
|
|
2294
2047
|
}
|
|
2295
2048
|
c(_s, "requireBuild");
|
|
2296
2049
|
var Ts = _s(), Hn = /* @__PURE__ */ Rn(Ts);
|
|
2297
|
-
function Cs(
|
|
2298
|
-
return
|
|
2050
|
+
function Cs(e, t) {
|
|
2051
|
+
return e.replace(/\s+$/, (n) => t(n));
|
|
2299
2052
|
}
|
|
2300
2053
|
c(Cs, "formatTrailingSpaces");
|
|
2301
|
-
function
|
|
2302
|
-
return t.length !== 0 ? n(
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
}
|
|
2306
|
-
|
|
2307
|
-
function Jn(t, e, {
|
|
2308
|
-
aColor: n,
|
|
2309
|
-
aIndicator: r,
|
|
2310
|
-
changeLineTrailingSpaceColor: o,
|
|
2311
|
-
emptyFirstOrLastLinePlaceholder: s
|
|
2312
|
-
}) {
|
|
2313
|
-
return Re(
|
|
2314
|
-
t,
|
|
2315
|
-
e,
|
|
2316
|
-
n,
|
|
2317
|
-
r,
|
|
2318
|
-
o,
|
|
2319
|
-
s
|
|
2320
|
-
);
|
|
2054
|
+
function Rt(e, t, n, r, o, s) {
|
|
2055
|
+
return e.length !== 0 ? n(`${r} ${Cs(e, o)}`) : r !== " " ? n(r) : t && s.length !== 0 ? n(`${r} ${s}`) : "";
|
|
2056
|
+
}
|
|
2057
|
+
c(Rt, "printDiffLine");
|
|
2058
|
+
function Jn(e, t, { aColor: n, aIndicator: r, changeLineTrailingSpaceColor: o, emptyFirstOrLastLinePlaceholder: s }) {
|
|
2059
|
+
return Rt(e, t, n, r, o, s);
|
|
2321
2060
|
}
|
|
2322
2061
|
c(Jn, "printDeleteLine");
|
|
2323
|
-
function Xn(t,
|
|
2324
|
-
|
|
2325
|
-
bIndicator: r,
|
|
2326
|
-
changeLineTrailingSpaceColor: o,
|
|
2327
|
-
emptyFirstOrLastLinePlaceholder: s
|
|
2328
|
-
}) {
|
|
2329
|
-
return Re(
|
|
2330
|
-
t,
|
|
2331
|
-
e,
|
|
2332
|
-
n,
|
|
2333
|
-
r,
|
|
2334
|
-
o,
|
|
2335
|
-
s
|
|
2336
|
-
);
|
|
2062
|
+
function Xn(e, t, { bColor: n, bIndicator: r, changeLineTrailingSpaceColor: o, emptyFirstOrLastLinePlaceholder: s }) {
|
|
2063
|
+
return Rt(e, t, n, r, o, s);
|
|
2337
2064
|
}
|
|
2338
2065
|
c(Xn, "printInsertLine");
|
|
2339
|
-
function Zn(t,
|
|
2340
|
-
|
|
2341
|
-
commonIndicator: r,
|
|
2342
|
-
commonLineTrailingSpaceColor: o,
|
|
2343
|
-
emptyFirstOrLastLinePlaceholder: s
|
|
2344
|
-
}) {
|
|
2345
|
-
return Re(
|
|
2346
|
-
t,
|
|
2347
|
-
e,
|
|
2348
|
-
n,
|
|
2349
|
-
r,
|
|
2350
|
-
o,
|
|
2351
|
-
s
|
|
2352
|
-
);
|
|
2066
|
+
function Zn(e, t, { commonColor: n, commonIndicator: r, commonLineTrailingSpaceColor: o, emptyFirstOrLastLinePlaceholder: s }) {
|
|
2067
|
+
return Rt(e, t, n, r, o, s);
|
|
2353
2068
|
}
|
|
2354
2069
|
c(Zn, "printCommonLine");
|
|
2355
|
-
function Fn(
|
|
2356
|
-
return o(
|
|
2357
|
-
`@@ -${t + 1},${e - t} +${n + 1},${r - n} @@`
|
|
2358
|
-
);
|
|
2070
|
+
function Fn(e, t, n, r, { patchColor: o }) {
|
|
2071
|
+
return o(`@@ -${e + 1},${t - e} +${n + 1},${r - n} @@`);
|
|
2359
2072
|
}
|
|
2360
2073
|
c(Fn, "createPatchMark");
|
|
2361
|
-
function Os(
|
|
2362
|
-
let n =
|
|
2074
|
+
function Os(e, t) {
|
|
2075
|
+
let n = e.length, r = t.contextLines, o = r + r, s = n, i = !1, a = 0, l = 0;
|
|
2363
2076
|
for (; l !== n; ) {
|
|
2364
2077
|
let d = l;
|
|
2365
|
-
for (; l !== n &&
|
|
2078
|
+
for (; l !== n && e[l][0] === x; )
|
|
2366
2079
|
l += 1;
|
|
2367
2080
|
if (d !== l)
|
|
2368
2081
|
if (d === 0)
|
|
@@ -2374,328 +2087,291 @@ function Os(t, e) {
|
|
|
2374
2087
|
let E = l - d;
|
|
2375
2088
|
E > o && (s -= E - o, a += 1);
|
|
2376
2089
|
}
|
|
2377
|
-
for (; l !== n &&
|
|
2090
|
+
for (; l !== n && e[l][0] !== x; )
|
|
2378
2091
|
l += 1;
|
|
2379
2092
|
}
|
|
2380
2093
|
let m = a !== 0 || i;
|
|
2381
2094
|
a !== 0 ? s += a + 1 : i && (s += 1);
|
|
2382
|
-
let p = s - 1, f = [],
|
|
2095
|
+
let p = s - 1, f = [], b = 0;
|
|
2383
2096
|
m && f.push("");
|
|
2384
|
-
let y = 0, g = 0, u = 0, h = 0,
|
|
2097
|
+
let y = 0, g = 0, u = 0, h = 0, S = /* @__PURE__ */ c((d) => {
|
|
2385
2098
|
let E = f.length;
|
|
2386
|
-
f.push(Zn(d, E === 0 || E === p,
|
|
2099
|
+
f.push(Zn(d, E === 0 || E === p, t)), u += 1, h += 1;
|
|
2387
2100
|
}, "pushCommonLine"), _ = /* @__PURE__ */ c((d) => {
|
|
2388
2101
|
let E = f.length;
|
|
2389
|
-
f.push(Jn(d, E === 0 || E === p,
|
|
2102
|
+
f.push(Jn(d, E === 0 || E === p, t)), u += 1;
|
|
2390
2103
|
}, "pushDeleteLine"), O = /* @__PURE__ */ c((d) => {
|
|
2391
2104
|
let E = f.length;
|
|
2392
|
-
f.push(Xn(d, E === 0 || E === p,
|
|
2105
|
+
f.push(Xn(d, E === 0 || E === p, t)), h += 1;
|
|
2393
2106
|
}, "pushInsertLine");
|
|
2394
2107
|
for (l = 0; l !== n; ) {
|
|
2395
2108
|
let d = l;
|
|
2396
|
-
for (; l !== n &&
|
|
2109
|
+
for (; l !== n && e[l][0] === x; )
|
|
2397
2110
|
l += 1;
|
|
2398
2111
|
if (d !== l)
|
|
2399
2112
|
if (d === 0) {
|
|
2400
2113
|
l > r && (d = l - r, y = d, g = d, u = y, h = g);
|
|
2401
2114
|
for (let E = d; E !== l; E += 1)
|
|
2402
|
-
|
|
2115
|
+
S(e[E][1]);
|
|
2403
2116
|
} else if (l === n) {
|
|
2404
2117
|
let E = l - d > r ? d + r : l;
|
|
2405
2118
|
for (let $ = d; $ !== E; $ += 1)
|
|
2406
|
-
|
|
2119
|
+
S(e[$][1]);
|
|
2407
2120
|
} else {
|
|
2408
2121
|
let E = l - d;
|
|
2409
2122
|
if (E > o) {
|
|
2410
2123
|
let $ = d + r;
|
|
2411
2124
|
for (let R = d; R !== $; R += 1)
|
|
2412
|
-
|
|
2413
|
-
f[
|
|
2414
|
-
y,
|
|
2415
|
-
u,
|
|
2416
|
-
g,
|
|
2417
|
-
h,
|
|
2418
|
-
e
|
|
2419
|
-
), S = f.length, f.push("");
|
|
2125
|
+
S(e[R][1]);
|
|
2126
|
+
f[b] = Fn(y, u, g, h, t), b = f.length, f.push("");
|
|
2420
2127
|
let T = E - o;
|
|
2421
2128
|
y = u + T, g = h + T, u = y, h = g;
|
|
2422
2129
|
for (let R = l - r; R !== l; R += 1)
|
|
2423
|
-
|
|
2130
|
+
S(e[R][1]);
|
|
2424
2131
|
} else
|
|
2425
2132
|
for (let $ = d; $ !== l; $ += 1)
|
|
2426
|
-
|
|
2133
|
+
S(e[$][1]);
|
|
2427
2134
|
}
|
|
2428
|
-
for (; l !== n &&
|
|
2429
|
-
_(
|
|
2430
|
-
for (; l !== n &&
|
|
2431
|
-
O(
|
|
2135
|
+
for (; l !== n && e[l][0] === U; )
|
|
2136
|
+
_(e[l][1]), l += 1;
|
|
2137
|
+
for (; l !== n && e[l][0] === k; )
|
|
2138
|
+
O(e[l][1]), l += 1;
|
|
2432
2139
|
}
|
|
2433
|
-
return m && (f[
|
|
2140
|
+
return m && (f[b] = Fn(y, u, g, h, t)), f.join(`
|
|
2434
2141
|
`);
|
|
2435
2142
|
}
|
|
2436
2143
|
c(Os, "joinAlignedDiffsNoExpand");
|
|
2437
|
-
function $s(
|
|
2438
|
-
return
|
|
2144
|
+
function $s(e, t) {
|
|
2145
|
+
return e.map((n, r, o) => {
|
|
2439
2146
|
let s = n[1], i = r === 0 || r === o.length - 1;
|
|
2440
2147
|
switch (n[0]) {
|
|
2441
2148
|
case U:
|
|
2442
|
-
return Jn(s, i,
|
|
2149
|
+
return Jn(s, i, t);
|
|
2443
2150
|
case k:
|
|
2444
|
-
return Xn(s, i,
|
|
2151
|
+
return Xn(s, i, t);
|
|
2445
2152
|
default:
|
|
2446
|
-
return Zn(s, i,
|
|
2153
|
+
return Zn(s, i, t);
|
|
2447
2154
|
}
|
|
2448
2155
|
}).join(`
|
|
2449
2156
|
`);
|
|
2450
2157
|
}
|
|
2451
2158
|
c($s, "joinAlignedDiffsExpand");
|
|
2452
|
-
var
|
|
2159
|
+
var Tt = /* @__PURE__ */ c((e) => e, "noColor"), vn = 5, ws = 0;
|
|
2453
2160
|
function As() {
|
|
2454
2161
|
return {
|
|
2455
2162
|
aAnnotation: "Expected",
|
|
2456
|
-
aColor:
|
|
2163
|
+
aColor: ne.green,
|
|
2457
2164
|
aIndicator: "-",
|
|
2458
2165
|
bAnnotation: "Received",
|
|
2459
|
-
bColor:
|
|
2166
|
+
bColor: ne.red,
|
|
2460
2167
|
bIndicator: "+",
|
|
2461
|
-
changeColor:
|
|
2462
|
-
changeLineTrailingSpaceColor:
|
|
2463
|
-
commonColor:
|
|
2168
|
+
changeColor: ne.inverse,
|
|
2169
|
+
changeLineTrailingSpaceColor: Tt,
|
|
2170
|
+
commonColor: ne.dim,
|
|
2464
2171
|
commonIndicator: " ",
|
|
2465
|
-
commonLineTrailingSpaceColor:
|
|
2172
|
+
commonLineTrailingSpaceColor: Tt,
|
|
2466
2173
|
compareKeys: void 0,
|
|
2467
|
-
contextLines:
|
|
2174
|
+
contextLines: vn,
|
|
2468
2175
|
emptyFirstOrLastLinePlaceholder: "",
|
|
2469
|
-
expand: !
|
|
2176
|
+
expand: !1,
|
|
2470
2177
|
includeChangeCounts: !1,
|
|
2471
2178
|
omitAnnotationLines: !1,
|
|
2472
|
-
patchColor:
|
|
2179
|
+
patchColor: ne.yellow,
|
|
2473
2180
|
printBasicPrototype: !1,
|
|
2474
2181
|
truncateThreshold: ws,
|
|
2475
2182
|
truncateAnnotation: "... Diff result is truncated",
|
|
2476
|
-
truncateAnnotationColor:
|
|
2183
|
+
truncateAnnotationColor: Tt
|
|
2477
2184
|
};
|
|
2478
2185
|
}
|
|
2479
2186
|
c(As, "getDefaultOptions");
|
|
2480
|
-
function Rs(
|
|
2481
|
-
return
|
|
2187
|
+
function Rs(e) {
|
|
2188
|
+
return e && typeof e == "function" ? e : void 0;
|
|
2482
2189
|
}
|
|
2483
2190
|
c(Rs, "getCompareKeys");
|
|
2484
|
-
function Ns(
|
|
2485
|
-
return typeof
|
|
2191
|
+
function Ns(e) {
|
|
2192
|
+
return typeof e == "number" && Number.isSafeInteger(e) && e >= 0 ? e : vn;
|
|
2486
2193
|
}
|
|
2487
2194
|
c(Ns, "getContextLines");
|
|
2488
|
-
function
|
|
2195
|
+
function he(e = {}) {
|
|
2489
2196
|
return {
|
|
2490
2197
|
...As(),
|
|
2491
|
-
...
|
|
2492
|
-
compareKeys: Rs(
|
|
2493
|
-
contextLines: Ns(
|
|
2198
|
+
...e,
|
|
2199
|
+
compareKeys: Rs(e.compareKeys),
|
|
2200
|
+
contextLines: Ns(e.contextLines)
|
|
2494
2201
|
};
|
|
2495
2202
|
}
|
|
2496
|
-
c(
|
|
2497
|
-
function
|
|
2498
|
-
return
|
|
2203
|
+
c(he, "normalizeDiffOptions");
|
|
2204
|
+
function Ee(e) {
|
|
2205
|
+
return e.length === 1 && e[0].length === 0;
|
|
2499
2206
|
}
|
|
2500
|
-
c(
|
|
2501
|
-
function Ps(
|
|
2502
|
-
let
|
|
2503
|
-
return
|
|
2207
|
+
c(Ee, "isEmptyString");
|
|
2208
|
+
function Ps(e) {
|
|
2209
|
+
let t = 0, n = 0;
|
|
2210
|
+
return e.forEach((r) => {
|
|
2504
2211
|
switch (r[0]) {
|
|
2505
2212
|
case U:
|
|
2506
|
-
|
|
2213
|
+
t += 1;
|
|
2507
2214
|
break;
|
|
2508
2215
|
case k:
|
|
2509
2216
|
n += 1;
|
|
2510
2217
|
break;
|
|
2511
2218
|
}
|
|
2512
|
-
}), {
|
|
2219
|
+
}), {
|
|
2220
|
+
a: t,
|
|
2221
|
+
b: n
|
|
2222
|
+
};
|
|
2513
2223
|
}
|
|
2514
2224
|
c(Ps, "countChanges");
|
|
2515
|
-
function Is({
|
|
2516
|
-
aAnnotation: t,
|
|
2517
|
-
aColor: e,
|
|
2518
|
-
aIndicator: n,
|
|
2519
|
-
bAnnotation: r,
|
|
2520
|
-
bColor: o,
|
|
2521
|
-
bIndicator: s,
|
|
2522
|
-
includeChangeCounts: i,
|
|
2523
|
-
omitAnnotationLines: a
|
|
2524
|
-
}, l) {
|
|
2225
|
+
function Is({ aAnnotation: e, aColor: t, aIndicator: n, bAnnotation: r, bColor: o, bIndicator: s, includeChangeCounts: i, omitAnnotationLines: a }, l) {
|
|
2525
2226
|
if (a)
|
|
2526
2227
|
return "";
|
|
2527
2228
|
let m = "", p = "";
|
|
2528
2229
|
if (i) {
|
|
2529
|
-
let y = String(l.a), g = String(l.b), u = r.length -
|
|
2230
|
+
let y = String(l.a), g = String(l.b), u = r.length - e.length, h = " ".repeat(Math.max(0, u)), S = " ".repeat(Math.max(0, -u)), _ = g.length -
|
|
2530
2231
|
y.length, O = " ".repeat(Math.max(0, _)), d = " ".repeat(Math.max(0, -_));
|
|
2531
|
-
m = `${h} ${n} ${O}${y}`, p = `${
|
|
2232
|
+
m = `${h} ${n} ${O}${y}`, p = `${S} ${s} ${d}${g}`;
|
|
2532
2233
|
}
|
|
2533
|
-
let f = `${n} ${
|
|
2534
|
-
return `${
|
|
2535
|
-
${o(
|
|
2234
|
+
let f = `${n} ${e}${m}`, b = `${s} ${r}${p}`;
|
|
2235
|
+
return `${t(f)}
|
|
2236
|
+
${o(b)}
|
|
2536
2237
|
|
|
2537
2238
|
`;
|
|
2538
2239
|
}
|
|
2539
2240
|
c(Is, "printAnnotation");
|
|
2540
|
-
function
|
|
2541
|
-
return Is(n, Ps(
|
|
2241
|
+
function Nt(e, t, n) {
|
|
2242
|
+
return Is(n, Ps(e)) + (n.expand ? $s(e, n) : Os(e, n)) + (t ? n.truncateAnnotationColor(`
|
|
2542
2243
|
${n.truncateAnnotation}`) : "");
|
|
2543
2244
|
}
|
|
2544
|
-
c(
|
|
2545
|
-
function
|
|
2546
|
-
let r =
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
function Ms(t, e, n, r, o) {
|
|
2555
|
-
if (Et(t) && Et(n) && (t = [], n = []), Et(e) && Et(r) && (e = [], r = []), t.length !== n.length || e.length !== r.length)
|
|
2556
|
-
return Xt(t, e, o);
|
|
2557
|
-
let [s, i] = vn(
|
|
2558
|
-
n,
|
|
2559
|
-
r,
|
|
2560
|
-
o
|
|
2561
|
-
), a = 0, l = 0;
|
|
2245
|
+
c(Nt, "printDiffLines");
|
|
2246
|
+
function Xe(e, t, n) {
|
|
2247
|
+
let r = he(n), [o, s] = Qn(Ee(e) ? [] : e, Ee(t) ? [] : t, r);
|
|
2248
|
+
return Nt(o, s, r);
|
|
2249
|
+
}
|
|
2250
|
+
c(Xe, "diffLinesUnified");
|
|
2251
|
+
function Ms(e, t, n, r, o) {
|
|
2252
|
+
if (Ee(e) && Ee(n) && (e = [], n = []), Ee(t) && Ee(r) && (t = [], r = []), e.length !== n.length || t.length !== r.length)
|
|
2253
|
+
return Xe(e, t, o);
|
|
2254
|
+
let [s, i] = Qn(n, r, o), a = 0, l = 0;
|
|
2562
2255
|
return s.forEach((m) => {
|
|
2563
2256
|
switch (m[0]) {
|
|
2564
2257
|
case U:
|
|
2565
|
-
m[1] =
|
|
2258
|
+
m[1] = e[a], a += 1;
|
|
2566
2259
|
break;
|
|
2567
2260
|
case k:
|
|
2568
|
-
m[1] =
|
|
2261
|
+
m[1] = t[l], l += 1;
|
|
2569
2262
|
break;
|
|
2570
2263
|
default:
|
|
2571
|
-
m[1] =
|
|
2264
|
+
m[1] = t[l], a += 1, l += 1;
|
|
2572
2265
|
}
|
|
2573
|
-
}),
|
|
2266
|
+
}), Nt(s, i, he(o));
|
|
2574
2267
|
}
|
|
2575
2268
|
c(Ms, "diffLinesUnified2");
|
|
2576
|
-
function
|
|
2577
|
-
let r = n?.truncateThreshold ?? !1, o = Math.max(
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
), s = r ? Math.min(t.length, o) : t.length, i = r ? Math.min(e.length, o) : e.length, a = s !== t.length || i !== e.length, l = /* @__PURE__ */ c(
|
|
2581
|
-
(y, g) => t[y] === e[g], "isCommon"), m = [], p = 0, f = 0;
|
|
2269
|
+
function Qn(e, t, n) {
|
|
2270
|
+
let r = n?.truncateThreshold ?? !1, o = Math.max(Math.floor(n?.truncateThreshold ?? 0), 0), s = r ? Math.min(e.length, o) : e.length, i = r ?
|
|
2271
|
+
Math.min(t.length, o) : t.length, a = s !== e.length || i !== t.length, l = /* @__PURE__ */ c((y, g) => e[y] === t[g], "isCommon"), m = [],
|
|
2272
|
+
p = 0, f = 0;
|
|
2582
2273
|
for (Hn(s, i, l, /* @__PURE__ */ c((y, g, u) => {
|
|
2583
2274
|
for (; p !== g; p += 1)
|
|
2584
|
-
m.push(new I(U,
|
|
2275
|
+
m.push(new I(U, e[p]));
|
|
2585
2276
|
for (; f !== u; f += 1)
|
|
2586
|
-
m.push(new I(k,
|
|
2277
|
+
m.push(new I(k, t[f]));
|
|
2587
2278
|
for (; y !== 0; y -= 1, p += 1, f += 1)
|
|
2588
|
-
m.push(new I(x,
|
|
2279
|
+
m.push(new I(x, t[f]));
|
|
2589
2280
|
}, "foundSubsequence")); p !== s; p += 1)
|
|
2590
|
-
m.push(new I(U,
|
|
2281
|
+
m.push(new I(U, e[p]));
|
|
2591
2282
|
for (; f !== i; f += 1)
|
|
2592
|
-
m.push(new I(k,
|
|
2283
|
+
m.push(new I(k, t[f]));
|
|
2593
2284
|
return [m, a];
|
|
2594
2285
|
}
|
|
2595
|
-
c(
|
|
2596
|
-
function Dn(
|
|
2597
|
-
if (
|
|
2286
|
+
c(Qn, "diffLinesRaw");
|
|
2287
|
+
function Dn(e) {
|
|
2288
|
+
if (e === void 0)
|
|
2598
2289
|
return "undefined";
|
|
2599
|
-
if (
|
|
2290
|
+
if (e === null)
|
|
2600
2291
|
return "null";
|
|
2601
|
-
if (Array.isArray(
|
|
2292
|
+
if (Array.isArray(e))
|
|
2602
2293
|
return "array";
|
|
2603
|
-
if (typeof
|
|
2294
|
+
if (typeof e == "boolean")
|
|
2604
2295
|
return "boolean";
|
|
2605
|
-
if (typeof
|
|
2296
|
+
if (typeof e == "function")
|
|
2606
2297
|
return "function";
|
|
2607
|
-
if (typeof
|
|
2298
|
+
if (typeof e == "number")
|
|
2608
2299
|
return "number";
|
|
2609
|
-
if (typeof
|
|
2300
|
+
if (typeof e == "string")
|
|
2610
2301
|
return "string";
|
|
2611
|
-
if (typeof
|
|
2302
|
+
if (typeof e == "bigint")
|
|
2612
2303
|
return "bigint";
|
|
2613
|
-
if (typeof
|
|
2614
|
-
if (
|
|
2615
|
-
if (
|
|
2304
|
+
if (typeof e == "object") {
|
|
2305
|
+
if (e != null) {
|
|
2306
|
+
if (e.constructor === RegExp)
|
|
2616
2307
|
return "regexp";
|
|
2617
|
-
if (
|
|
2308
|
+
if (e.constructor === Map)
|
|
2618
2309
|
return "map";
|
|
2619
|
-
if (
|
|
2310
|
+
if (e.constructor === Set)
|
|
2620
2311
|
return "set";
|
|
2621
|
-
if (
|
|
2312
|
+
if (e.constructor === Date)
|
|
2622
2313
|
return "date";
|
|
2623
2314
|
}
|
|
2624
2315
|
return "object";
|
|
2625
|
-
} else if (typeof
|
|
2316
|
+
} else if (typeof e == "symbol")
|
|
2626
2317
|
return "symbol";
|
|
2627
|
-
throw new Error(`value of unknown type: ${
|
|
2318
|
+
throw new Error(`value of unknown type: ${e}`);
|
|
2628
2319
|
}
|
|
2629
2320
|
c(Dn, "getType");
|
|
2630
|
-
function jn(
|
|
2631
|
-
return
|
|
2321
|
+
function jn(e) {
|
|
2322
|
+
return e.includes(`\r
|
|
2632
2323
|
`) ? `\r
|
|
2633
2324
|
` : `
|
|
2634
2325
|
`;
|
|
2635
2326
|
}
|
|
2636
2327
|
c(jn, "getNewLineSymbol");
|
|
2637
|
-
function Ls(
|
|
2638
|
-
let r = n?.truncateThreshold ?? !1, o = Math.max(
|
|
2639
|
-
Math.floor(n?.truncateThreshold ?? 0),
|
|
2640
|
-
0
|
|
2641
|
-
), s = t.length, i = e.length;
|
|
2328
|
+
function Ls(e, t, n) {
|
|
2329
|
+
let r = n?.truncateThreshold ?? !1, o = Math.max(Math.floor(n?.truncateThreshold ?? 0), 0), s = e.length, i = t.length;
|
|
2642
2330
|
if (r) {
|
|
2643
|
-
let y =
|
|
2644
|
-
`), g =
|
|
2645
|
-
`), u = jn(
|
|
2646
|
-
` :
|
|
2647
|
-
` :
|
|
2648
|
-
s =
|
|
2649
|
-
}
|
|
2650
|
-
let a = s !==
|
|
2331
|
+
let y = e.includes(`
|
|
2332
|
+
`), g = t.includes(`
|
|
2333
|
+
`), u = jn(e), h = jn(t), S = y ? `${e.split(u, o).join(u)}
|
|
2334
|
+
` : e, _ = g ? `${t.split(h, o).join(h)}
|
|
2335
|
+
` : t;
|
|
2336
|
+
s = S.length, i = _.length;
|
|
2337
|
+
}
|
|
2338
|
+
let a = s !== e.length || i !== t.length, l = /* @__PURE__ */ c((y, g) => e[y] === t[g], "isCommon"), m = 0, p = 0, f = [];
|
|
2651
2339
|
return Hn(s, i, l, /* @__PURE__ */ c((y, g, u) => {
|
|
2652
|
-
m !== g && f.push(new I(U,
|
|
2340
|
+
m !== g && f.push(new I(U, e.slice(m, g))), p !== u && f.push(new I(k, t.slice(p, u))), m = g + y, p = u + y, f.push(new I(x, t.slice(u,
|
|
2653
2341
|
p)));
|
|
2654
|
-
}, "foundSubsequence")), m !== s && f.push(new I(U,
|
|
2342
|
+
}, "foundSubsequence")), m !== s && f.push(new I(U, e.slice(m))), p !== i && f.push(new I(k, t.slice(p))), [f, a];
|
|
2655
2343
|
}
|
|
2656
2344
|
c(Ls, "diffStrings");
|
|
2657
|
-
function xs(
|
|
2658
|
-
return
|
|
2659
|
-
(r, o) => r + (o[0] === x ? o[1] : o[0] === t && o[1].length !== 0 ? n(o[1]) : ""),
|
|
2660
|
-
""
|
|
2661
|
-
);
|
|
2345
|
+
function xs(e, t, n) {
|
|
2346
|
+
return t.reduce((r, o) => r + (o[0] === x ? o[1] : o[0] === e && o[1].length !== 0 ? n(o[1]) : ""), "");
|
|
2662
2347
|
}
|
|
2663
2348
|
c(xs, "concatenateRelevantDiffs");
|
|
2664
|
-
var
|
|
2349
|
+
var Je = class {
|
|
2665
2350
|
static {
|
|
2666
2351
|
c(this, "ChangeBuffer");
|
|
2667
2352
|
}
|
|
2668
2353
|
op;
|
|
2669
2354
|
line;
|
|
2670
|
-
// incomplete line
|
|
2671
2355
|
lines;
|
|
2672
|
-
// complete lines
|
|
2673
2356
|
changeColor;
|
|
2674
|
-
constructor(
|
|
2675
|
-
this.op =
|
|
2357
|
+
constructor(t, n) {
|
|
2358
|
+
this.op = t, this.line = [], this.lines = [], this.changeColor = n;
|
|
2676
2359
|
}
|
|
2677
|
-
pushSubstring(
|
|
2678
|
-
this.pushDiff(new I(this.op,
|
|
2360
|
+
pushSubstring(t) {
|
|
2361
|
+
this.pushDiff(new I(this.op, t));
|
|
2679
2362
|
}
|
|
2680
2363
|
pushLine() {
|
|
2681
|
-
this.lines.push(
|
|
2682
|
-
|
|
2683
|
-
this.op,
|
|
2684
|
-
xs(this.op, this.line, this.changeColor)
|
|
2685
|
-
) : this.line[0][0] === this.op ? this.line[0] : new I(this.op, this.line[0][1])
|
|
2686
|
-
// was common diff
|
|
2687
|
-
), this.line.length = 0;
|
|
2364
|
+
this.lines.push(this.line.length !== 1 ? new I(this.op, xs(this.op, this.line, this.changeColor)) : this.line[0][0] === this.op ? this.line[0] :
|
|
2365
|
+
new I(this.op, this.line[0][1])), this.line.length = 0;
|
|
2688
2366
|
}
|
|
2689
2367
|
isLineEmpty() {
|
|
2690
2368
|
return this.line.length === 0;
|
|
2691
2369
|
}
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
this.line.push(e);
|
|
2370
|
+
pushDiff(t) {
|
|
2371
|
+
this.line.push(t);
|
|
2695
2372
|
}
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
let n = e[1];
|
|
2373
|
+
align(t) {
|
|
2374
|
+
let n = t[1];
|
|
2699
2375
|
if (n.includes(`
|
|
2700
2376
|
`)) {
|
|
2701
2377
|
let r = n.split(`
|
|
@@ -2704,36 +2380,34 @@ var Jt = class {
|
|
|
2704
2380
|
i < o ? (this.pushSubstring(s), this.pushLine()) : s.length !== 0 && this.pushSubstring(s);
|
|
2705
2381
|
});
|
|
2706
2382
|
} else
|
|
2707
|
-
this.pushDiff(
|
|
2383
|
+
this.pushDiff(t);
|
|
2708
2384
|
}
|
|
2709
|
-
|
|
2710
|
-
|
|
2711
|
-
this.isLineEmpty() || this.pushLine(), e.push(...this.lines), this.lines.length = 0;
|
|
2385
|
+
moveLinesTo(t) {
|
|
2386
|
+
this.isLineEmpty() || this.pushLine(), t.push(...this.lines), this.lines.length = 0;
|
|
2712
2387
|
}
|
|
2713
|
-
},
|
|
2388
|
+
}, Ot = class {
|
|
2714
2389
|
static {
|
|
2715
2390
|
c(this, "CommonBuffer");
|
|
2716
2391
|
}
|
|
2717
2392
|
deleteBuffer;
|
|
2718
2393
|
insertBuffer;
|
|
2719
2394
|
lines;
|
|
2720
|
-
constructor(
|
|
2721
|
-
this.deleteBuffer =
|
|
2395
|
+
constructor(t, n) {
|
|
2396
|
+
this.deleteBuffer = t, this.insertBuffer = n, this.lines = [];
|
|
2722
2397
|
}
|
|
2723
|
-
pushDiffCommonLine(
|
|
2724
|
-
this.lines.push(
|
|
2398
|
+
pushDiffCommonLine(t) {
|
|
2399
|
+
this.lines.push(t);
|
|
2725
2400
|
}
|
|
2726
|
-
pushDiffChangeLines(
|
|
2727
|
-
let n =
|
|
2728
|
-
(!n || this.deleteBuffer.isLineEmpty()) && this.deleteBuffer.pushDiff(
|
|
2729
|
-
|
|
2401
|
+
pushDiffChangeLines(t) {
|
|
2402
|
+
let n = t[1].length === 0;
|
|
2403
|
+
(!n || this.deleteBuffer.isLineEmpty()) && this.deleteBuffer.pushDiff(t), (!n || this.insertBuffer.isLineEmpty()) && this.insertBuffer.pushDiff(
|
|
2404
|
+
t);
|
|
2730
2405
|
}
|
|
2731
2406
|
flushChangeLines() {
|
|
2732
2407
|
this.deleteBuffer.moveLinesTo(this.lines), this.insertBuffer.moveLinesTo(this.lines);
|
|
2733
2408
|
}
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
let n = e[0], r = e[1];
|
|
2409
|
+
align(t) {
|
|
2410
|
+
let n = t[0], r = t[1];
|
|
2737
2411
|
if (r.includes(`
|
|
2738
2412
|
`)) {
|
|
2739
2413
|
let o = r.split(`
|
|
@@ -2746,16 +2420,15 @@ var Jt = class {
|
|
|
2746
2420
|
} else a < s ? this.pushDiffCommonLine(new I(n, i)) : i.length !== 0 && this.pushDiffChangeLines(new I(n, i));
|
|
2747
2421
|
});
|
|
2748
2422
|
} else
|
|
2749
|
-
this.pushDiffChangeLines(
|
|
2423
|
+
this.pushDiffChangeLines(t);
|
|
2750
2424
|
}
|
|
2751
|
-
// Output from buffer.
|
|
2752
2425
|
getLines() {
|
|
2753
2426
|
return this.flushChangeLines(), this.lines;
|
|
2754
2427
|
}
|
|
2755
2428
|
};
|
|
2756
|
-
function Fs(
|
|
2757
|
-
let n = new
|
|
2758
|
-
return
|
|
2429
|
+
function Fs(e, t) {
|
|
2430
|
+
let n = new Je(U, t), r = new Je(k, t), o = new Ot(n, r);
|
|
2431
|
+
return e.forEach((s) => {
|
|
2759
2432
|
switch (s[0]) {
|
|
2760
2433
|
case U:
|
|
2761
2434
|
n.align(s);
|
|
@@ -2769,310 +2442,284 @@ function Fs(t, e) {
|
|
|
2769
2442
|
}), o.getLines();
|
|
2770
2443
|
}
|
|
2771
2444
|
c(Fs, "getAlignedDiffs");
|
|
2772
|
-
function Ds(
|
|
2773
|
-
if (
|
|
2774
|
-
let n =
|
|
2775
|
-
return
|
|
2776
|
-
|
|
2777
|
-
`)
|
|
2778
|
-
);
|
|
2445
|
+
function Ds(e, t) {
|
|
2446
|
+
if (t) {
|
|
2447
|
+
let n = e.length - 1;
|
|
2448
|
+
return e.some((r, o) => r[0] === x && (o !== n || r[1] !== `
|
|
2449
|
+
`));
|
|
2779
2450
|
}
|
|
2780
|
-
return
|
|
2451
|
+
return e.some((n) => n[0] === x);
|
|
2781
2452
|
}
|
|
2782
2453
|
c(Ds, "hasCommonDiff");
|
|
2783
|
-
function js(
|
|
2784
|
-
if (
|
|
2785
|
-
let r =
|
|
2786
|
-
`) ||
|
|
2787
|
-
`), [o, s] =
|
|
2788
|
-
|
|
2789
|
-
` : t,
|
|
2790
|
-
r ? `${e}
|
|
2791
|
-
` : e,
|
|
2792
|
-
!0,
|
|
2793
|
-
// cleanupSemantic
|
|
2794
|
-
n
|
|
2795
|
-
);
|
|
2454
|
+
function js(e, t, n) {
|
|
2455
|
+
if (e !== t && e.length !== 0 && t.length !== 0) {
|
|
2456
|
+
let r = e.includes(`
|
|
2457
|
+
`) || t.includes(`
|
|
2458
|
+
`), [o, s] = er(r ? `${e}
|
|
2459
|
+
` : e, r ? `${t}
|
|
2460
|
+
` : t, !0, n);
|
|
2796
2461
|
if (Ds(o, r)) {
|
|
2797
|
-
let i =
|
|
2798
|
-
return
|
|
2462
|
+
let i = he(n), a = Fs(o, i.changeColor);
|
|
2463
|
+
return Nt(a, s, i);
|
|
2799
2464
|
}
|
|
2800
2465
|
}
|
|
2801
|
-
return
|
|
2802
|
-
`),
|
|
2466
|
+
return Xe(e.split(`
|
|
2467
|
+
`), t.split(`
|
|
2803
2468
|
`), n);
|
|
2804
2469
|
}
|
|
2805
2470
|
c(js, "diffStringsUnified");
|
|
2806
|
-
function
|
|
2807
|
-
let [o, s] = Ls(
|
|
2471
|
+
function er(e, t, n, r) {
|
|
2472
|
+
let [o, s] = Ls(e, t, r);
|
|
2808
2473
|
return n && ys(o), [o, s];
|
|
2809
2474
|
}
|
|
2810
|
-
c(
|
|
2811
|
-
function $e
|
|
2812
|
-
let { commonColor: n } =
|
|
2813
|
-
return n(
|
|
2814
|
-
}
|
|
2815
|
-
c($
|
|
2816
|
-
var {
|
|
2817
|
-
AsymmetricMatcher: Bs,
|
|
2818
|
-
DOMCollection: ks,
|
|
2819
|
-
DOMElement: zs,
|
|
2820
|
-
Immutable: Ys,
|
|
2821
|
-
ReactElement: Us,
|
|
2822
|
-
ReactTestComponent: Ws
|
|
2823
|
-
} = $t, er = [
|
|
2475
|
+
c(er, "diffStringsRaw");
|
|
2476
|
+
function $t(e, t) {
|
|
2477
|
+
let { commonColor: n } = he(t);
|
|
2478
|
+
return n(e);
|
|
2479
|
+
}
|
|
2480
|
+
c($t, "getCommonMessage");
|
|
2481
|
+
var { AsymmetricMatcher: Bs, DOMCollection: ks, DOMElement: zs, Immutable: Ys, ReactElement: Us, ReactTestComponent: Ws } = $e, tr = [
|
|
2824
2482
|
Ws,
|
|
2825
2483
|
Us,
|
|
2826
2484
|
zs,
|
|
2827
2485
|
ks,
|
|
2828
2486
|
Ys,
|
|
2829
2487
|
Bs,
|
|
2830
|
-
$
|
|
2831
|
-
],
|
|
2832
|
-
|
|
2488
|
+
$e.Error
|
|
2489
|
+
], wt = {
|
|
2490
|
+
maxDepth: 20,
|
|
2491
|
+
plugins: tr
|
|
2833
2492
|
}, nr = {
|
|
2834
2493
|
callToJSON: !1,
|
|
2835
2494
|
maxDepth: 8,
|
|
2836
|
-
plugins:
|
|
2495
|
+
plugins: tr
|
|
2837
2496
|
};
|
|
2838
|
-
function Vs(
|
|
2839
|
-
if (Object.is(
|
|
2497
|
+
function Vs(e, t, n) {
|
|
2498
|
+
if (Object.is(e, t))
|
|
2840
2499
|
return "";
|
|
2841
|
-
let r = Dn(
|
|
2842
|
-
if (r === "object" && typeof
|
|
2843
|
-
if (
|
|
2500
|
+
let r = Dn(e), o = r, s = !1;
|
|
2501
|
+
if (r === "object" && typeof e.asymmetricMatch == "function") {
|
|
2502
|
+
if (e.$$typeof !== Symbol.for("jest.asymmetricMatcher") || typeof e.getExpectedType != "function")
|
|
2844
2503
|
return;
|
|
2845
|
-
o =
|
|
2846
|
-
}
|
|
2847
|
-
if (o !== Dn(
|
|
2848
|
-
let
|
|
2849
|
-
return O.length <=
|
|
2850
|
-
}
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
${
|
|
2856
|
-
|
|
2504
|
+
o = e.getExpectedType(), s = o === "string";
|
|
2505
|
+
}
|
|
2506
|
+
if (o !== Dn(t)) {
|
|
2507
|
+
let h = function(O) {
|
|
2508
|
+
return O.length <= u ? O : `${O.slice(0, u)}...`;
|
|
2509
|
+
};
|
|
2510
|
+
c(h, "truncate");
|
|
2511
|
+
let { aAnnotation: i, aColor: a, aIndicator: l, bAnnotation: m, bColor: p, bIndicator: f } = he(n), b = At(nr, n), y = Q(e, b), g = Q(t,
|
|
2512
|
+
b), u = 1e5;
|
|
2513
|
+
y = h(y), g = h(g);
|
|
2514
|
+
let S = `${a(`${l} ${i}:`)}
|
|
2515
|
+
${y}`, _ = `${p(`${f} ${m}:`)}
|
|
2516
|
+
${g}`;
|
|
2517
|
+
return `${S}
|
|
2857
2518
|
|
|
2858
2519
|
${_}`;
|
|
2859
2520
|
}
|
|
2860
2521
|
if (!s)
|
|
2861
2522
|
switch (r) {
|
|
2862
2523
|
case "string":
|
|
2863
|
-
return
|
|
2864
|
-
`),
|
|
2524
|
+
return Xe(e.split(`
|
|
2525
|
+
`), t.split(`
|
|
2865
2526
|
`), n);
|
|
2866
2527
|
case "boolean":
|
|
2867
2528
|
case "number":
|
|
2868
|
-
return qs(
|
|
2529
|
+
return qs(e, t, n);
|
|
2869
2530
|
case "map":
|
|
2870
|
-
return
|
|
2531
|
+
return Ct(Bn(e), Bn(t), n);
|
|
2871
2532
|
case "set":
|
|
2872
|
-
return
|
|
2533
|
+
return Ct(kn(e), kn(t), n);
|
|
2873
2534
|
default:
|
|
2874
|
-
return
|
|
2535
|
+
return Ct(e, t, n);
|
|
2875
2536
|
}
|
|
2876
2537
|
}
|
|
2877
2538
|
c(Vs, "diff");
|
|
2878
|
-
function qs(
|
|
2879
|
-
let r =
|
|
2880
|
-
return r === o ? "" :
|
|
2539
|
+
function qs(e, t, n) {
|
|
2540
|
+
let r = Q(e, wt), o = Q(t, wt);
|
|
2541
|
+
return r === o ? "" : Xe(r.split(`
|
|
2881
2542
|
`), o.split(`
|
|
2882
2543
|
`), n);
|
|
2883
2544
|
}
|
|
2884
2545
|
c(qs, "comparePrimitive");
|
|
2885
|
-
function Bn(
|
|
2886
|
-
return new Map(Array.from(
|
|
2546
|
+
function Bn(e) {
|
|
2547
|
+
return new Map(Array.from(e.entries()).sort());
|
|
2887
2548
|
}
|
|
2888
2549
|
c(Bn, "sortMap");
|
|
2889
|
-
function kn(
|
|
2890
|
-
return new Set(Array.from(
|
|
2550
|
+
function kn(e) {
|
|
2551
|
+
return new Set(Array.from(e.values()).sort());
|
|
2891
2552
|
}
|
|
2892
2553
|
c(kn, "sortSet");
|
|
2893
|
-
function
|
|
2554
|
+
function Ct(e, t, n) {
|
|
2894
2555
|
let r, o = !1;
|
|
2895
2556
|
try {
|
|
2896
|
-
let i =
|
|
2897
|
-
r = zn(
|
|
2557
|
+
let i = At(wt, n);
|
|
2558
|
+
r = zn(e, t, i, n);
|
|
2898
2559
|
} catch {
|
|
2899
2560
|
o = !0;
|
|
2900
2561
|
}
|
|
2901
|
-
let s = $
|
|
2562
|
+
let s = $t(Gn, n);
|
|
2902
2563
|
if (r === void 0 || r === s) {
|
|
2903
|
-
let i =
|
|
2904
|
-
r = zn(
|
|
2905
|
-
Es,
|
|
2906
|
-
n
|
|
2907
|
-
)}
|
|
2564
|
+
let i = At(nr, n);
|
|
2565
|
+
r = zn(e, t, i, n), r !== s && !o && (r = `${$t(Es, n)}
|
|
2908
2566
|
|
|
2909
2567
|
${r}`);
|
|
2910
2568
|
}
|
|
2911
2569
|
return r;
|
|
2912
2570
|
}
|
|
2913
|
-
c(
|
|
2914
|
-
function
|
|
2915
|
-
let { compareKeys: n, printBasicPrototype: r } =
|
|
2571
|
+
c(Ct, "compareObjects");
|
|
2572
|
+
function At(e, t) {
|
|
2573
|
+
let { compareKeys: n, printBasicPrototype: r, maxDepth: o } = he(t);
|
|
2916
2574
|
return {
|
|
2917
|
-
...
|
|
2575
|
+
...e,
|
|
2918
2576
|
compareKeys: n,
|
|
2919
|
-
printBasicPrototype: r
|
|
2577
|
+
printBasicPrototype: r,
|
|
2578
|
+
maxDepth: o ?? e.maxDepth
|
|
2920
2579
|
};
|
|
2921
2580
|
}
|
|
2922
|
-
c(
|
|
2923
|
-
function zn(
|
|
2924
|
-
let o = {
|
|
2581
|
+
c(At, "getFormatOptions");
|
|
2582
|
+
function zn(e, t, n, r) {
|
|
2583
|
+
let o = {
|
|
2584
|
+
...n,
|
|
2585
|
+
indent: 0
|
|
2586
|
+
}, s = Q(e, o), i = Q(t, o);
|
|
2925
2587
|
if (s === i)
|
|
2926
|
-
return $
|
|
2588
|
+
return $t(Gn, r);
|
|
2927
2589
|
{
|
|
2928
|
-
let a =
|
|
2929
|
-
return Ms(
|
|
2930
|
-
|
|
2931
|
-
`),
|
|
2932
|
-
|
|
2933
|
-
`),
|
|
2934
|
-
s.split(`
|
|
2935
|
-
`),
|
|
2936
|
-
i.split(`
|
|
2937
|
-
`),
|
|
2938
|
-
r
|
|
2939
|
-
);
|
|
2590
|
+
let a = Q(e, n), l = Q(t, n);
|
|
2591
|
+
return Ms(a.split(`
|
|
2592
|
+
`), l.split(`
|
|
2593
|
+
`), s.split(`
|
|
2594
|
+
`), i.split(`
|
|
2595
|
+
`), r);
|
|
2940
2596
|
}
|
|
2941
2597
|
}
|
|
2942
2598
|
c(zn, "getObjectsDifference");
|
|
2943
2599
|
var Yn = 2e4;
|
|
2944
|
-
function Un(
|
|
2945
|
-
return
|
|
2600
|
+
function Un(e) {
|
|
2601
|
+
return Ke(e) === "Object" && typeof e.asymmetricMatch == "function";
|
|
2946
2602
|
}
|
|
2947
2603
|
c(Un, "isAsymmetricMatcher");
|
|
2948
|
-
function Wn(
|
|
2949
|
-
let n =
|
|
2604
|
+
function Wn(e, t) {
|
|
2605
|
+
let n = Ke(e), r = Ke(t);
|
|
2950
2606
|
return n === r && (n === "Object" || n === "Array");
|
|
2951
2607
|
}
|
|
2952
2608
|
c(Wn, "isReplaceable");
|
|
2953
|
-
function rr(
|
|
2954
|
-
let { aAnnotation: r, bAnnotation: o } =
|
|
2955
|
-
if (typeof
|
|
2956
|
-
if (
|
|
2957
|
-
`) ||
|
|
2609
|
+
function rr(e, t, n) {
|
|
2610
|
+
let { aAnnotation: r, bAnnotation: o } = he(n);
|
|
2611
|
+
if (typeof t == "string" && typeof e == "string" && t.length > 0 && e.length > 0 && t.length <= Yn && e.length <= Yn && t !== e) {
|
|
2612
|
+
if (t.includes(`
|
|
2613
|
+
`) || e.includes(`
|
|
2958
2614
|
`))
|
|
2959
|
-
return js(
|
|
2960
|
-
let [p] =
|
|
2961
|
-
Vn(p, U, f)
|
|
2962
|
-
), g = S(o) + Hs(
|
|
2963
|
-
Vn(p, k, f)
|
|
2964
|
-
);
|
|
2615
|
+
return js(t, e, n);
|
|
2616
|
+
let [p] = er(t, e, !0), f = p.some((u) => u[0] === x), b = Ks(r, o), y = b(r) + Js(Vn(p, U, f)), g = b(o) + Hs(Vn(p, k, f));
|
|
2965
2617
|
return `${y}
|
|
2966
2618
|
${g}`;
|
|
2967
2619
|
}
|
|
2968
|
-
let s =
|
|
2620
|
+
let s = _t(t, { forceWritable: !0 }), i = _t(e, { forceWritable: !0 }), { replacedExpected: a, replacedActual: l } = or(i, s);
|
|
2969
2621
|
return Vs(a, l, n);
|
|
2970
2622
|
}
|
|
2971
2623
|
c(rr, "printDiffOrStringify");
|
|
2972
|
-
function or(
|
|
2973
|
-
return
|
|
2974
|
-
replacedActual:
|
|
2975
|
-
replacedExpected:
|
|
2976
|
-
}) : Wn(
|
|
2977
|
-
|
|
2624
|
+
function or(e, t, n = /* @__PURE__ */ new WeakSet(), r = /* @__PURE__ */ new WeakSet()) {
|
|
2625
|
+
return e instanceof Error && t instanceof Error && typeof e.cause < "u" && typeof t.cause > "u" ? (delete e.cause, {
|
|
2626
|
+
replacedActual: e,
|
|
2627
|
+
replacedExpected: t
|
|
2628
|
+
}) : Wn(e, t) ? n.has(e) || r.has(t) ? {
|
|
2629
|
+
replacedActual: e,
|
|
2630
|
+
replacedExpected: t
|
|
2631
|
+
} : (n.add(e), r.add(t), Et(t).forEach((o) => {
|
|
2632
|
+
let s = t[o], i = e[o];
|
|
2978
2633
|
if (Un(s))
|
|
2979
|
-
s.asymmetricMatch(i) && (
|
|
2634
|
+
s.asymmetricMatch(i) && (e[o] = s);
|
|
2980
2635
|
else if (Un(i))
|
|
2981
|
-
i.asymmetricMatch(s) && (
|
|
2636
|
+
i.asymmetricMatch(s) && (t[o] = i);
|
|
2982
2637
|
else if (Wn(i, s)) {
|
|
2983
|
-
let a = or(
|
|
2984
|
-
|
|
2985
|
-
s,
|
|
2986
|
-
n,
|
|
2987
|
-
r
|
|
2988
|
-
);
|
|
2989
|
-
t[o] = a.replacedActual, e[o] = a.replacedExpected;
|
|
2638
|
+
let a = or(i, s, n, r);
|
|
2639
|
+
e[o] = a.replacedActual, t[o] = a.replacedExpected;
|
|
2990
2640
|
}
|
|
2991
2641
|
}), {
|
|
2992
|
-
replacedActual:
|
|
2993
|
-
replacedExpected:
|
|
2994
|
-
}) : {
|
|
2642
|
+
replacedActual: e,
|
|
2643
|
+
replacedExpected: t
|
|
2644
|
+
}) : {
|
|
2645
|
+
replacedActual: e,
|
|
2646
|
+
replacedExpected: t
|
|
2647
|
+
};
|
|
2995
2648
|
}
|
|
2996
2649
|
c(or, "replaceAsymmetricMatcher");
|
|
2997
|
-
function Ks(...
|
|
2998
|
-
let
|
|
2999
|
-
|
|
3000
|
-
0
|
|
3001
|
-
);
|
|
3002
|
-
return (n) => `${n}: ${" ".repeat(e - n.length)}`;
|
|
2650
|
+
function Ks(...e) {
|
|
2651
|
+
let t = e.reduce((n, r) => r.length > n ? r.length : n, 0);
|
|
2652
|
+
return (n) => `${n}: ${" ".repeat(t - n.length)}`;
|
|
3003
2653
|
}
|
|
3004
2654
|
c(Ks, "getLabelPrinter");
|
|
3005
2655
|
var Gs = "\xB7";
|
|
3006
|
-
function sr(
|
|
3007
|
-
return
|
|
2656
|
+
function sr(e) {
|
|
2657
|
+
return e.replace(/\s+$/gm, (t) => Gs.repeat(t.length));
|
|
3008
2658
|
}
|
|
3009
2659
|
c(sr, "replaceTrailingSpaces");
|
|
3010
|
-
function Hs(
|
|
3011
|
-
return
|
|
2660
|
+
function Hs(e) {
|
|
2661
|
+
return ne.red(sr(ge(e)));
|
|
3012
2662
|
}
|
|
3013
2663
|
c(Hs, "printReceived");
|
|
3014
|
-
function Js(
|
|
3015
|
-
return
|
|
2664
|
+
function Js(e) {
|
|
2665
|
+
return ne.green(sr(ge(e)));
|
|
3016
2666
|
}
|
|
3017
2667
|
c(Js, "printExpected");
|
|
3018
|
-
function Vn(
|
|
3019
|
-
return
|
|
3020
|
-
(r, o) => r + (o[0] === x ? o[1] : o[0] === e ? n ? nt.inverse(o[1]) : o[1] : ""),
|
|
3021
|
-
""
|
|
3022
|
-
);
|
|
2668
|
+
function Vn(e, t, n) {
|
|
2669
|
+
return e.reduce((r, o) => r + (o[0] === x ? o[1] : o[0] === t ? n ? ne.inverse(o[1]) : o[1] : ""), "");
|
|
3023
2670
|
}
|
|
3024
2671
|
c(Vn, "getCommonAndChangedSubstrings");
|
|
3025
2672
|
|
|
3026
2673
|
// ../node_modules/@vitest/utils/dist/error.js
|
|
3027
2674
|
var Xs = "@@__IMMUTABLE_RECORD__@@", Zs = "@@__IMMUTABLE_ITERABLE__@@";
|
|
3028
|
-
function
|
|
3029
|
-
return
|
|
2675
|
+
function vs(e) {
|
|
2676
|
+
return e && (e[Zs] || e[Xs]);
|
|
3030
2677
|
}
|
|
3031
|
-
c(
|
|
3032
|
-
var
|
|
3033
|
-
function ir(
|
|
3034
|
-
return
|
|
2678
|
+
c(vs, "isImmutable");
|
|
2679
|
+
var Qs = Object.getPrototypeOf({});
|
|
2680
|
+
function ir(e) {
|
|
2681
|
+
return e instanceof Error ? `<unserializable>: ${e.message}` : typeof e == "string" ? `<unserializable>: ${e}` : "<unserializable>";
|
|
3035
2682
|
}
|
|
3036
2683
|
c(ir, "getUnserializableMessage");
|
|
3037
|
-
function
|
|
3038
|
-
if (!
|
|
3039
|
-
return
|
|
3040
|
-
if (typeof
|
|
3041
|
-
return `Function<${
|
|
3042
|
-
if (typeof
|
|
3043
|
-
return
|
|
3044
|
-
if (typeof
|
|
3045
|
-
return
|
|
3046
|
-
if (
|
|
3047
|
-
return
|
|
3048
|
-
if (
|
|
2684
|
+
function _e(e, t = /* @__PURE__ */ new WeakMap()) {
|
|
2685
|
+
if (!e || typeof e == "string")
|
|
2686
|
+
return e;
|
|
2687
|
+
if (typeof e == "function")
|
|
2688
|
+
return `Function<${e.name || "anonymous"}>`;
|
|
2689
|
+
if (typeof e == "symbol")
|
|
2690
|
+
return e.toString();
|
|
2691
|
+
if (typeof e != "object")
|
|
2692
|
+
return e;
|
|
2693
|
+
if (vs(e))
|
|
2694
|
+
return _e(e.toJSON(), t);
|
|
2695
|
+
if (e instanceof Promise || e.constructor && e.constructor.prototype === "AsyncFunction")
|
|
3049
2696
|
return "Promise";
|
|
3050
|
-
if (typeof Element < "u" &&
|
|
3051
|
-
return
|
|
3052
|
-
if (typeof
|
|
3053
|
-
return `${
|
|
3054
|
-
if (typeof
|
|
3055
|
-
return
|
|
3056
|
-
if (
|
|
3057
|
-
return
|
|
3058
|
-
if (Array.isArray(
|
|
3059
|
-
let n = new Array(
|
|
3060
|
-
return
|
|
2697
|
+
if (typeof Element < "u" && e instanceof Element)
|
|
2698
|
+
return e.tagName;
|
|
2699
|
+
if (typeof e.asymmetricMatch == "function")
|
|
2700
|
+
return `${e.toString()} ${An(e.sample)}`;
|
|
2701
|
+
if (typeof e.toJSON == "function")
|
|
2702
|
+
return _e(e.toJSON(), t);
|
|
2703
|
+
if (t.has(e))
|
|
2704
|
+
return t.get(e);
|
|
2705
|
+
if (Array.isArray(e)) {
|
|
2706
|
+
let n = new Array(e.length);
|
|
2707
|
+
return t.set(e, n), e.forEach((r, o) => {
|
|
3061
2708
|
try {
|
|
3062
|
-
n[o] =
|
|
2709
|
+
n[o] = _e(r, t);
|
|
3063
2710
|
} catch (s) {
|
|
3064
2711
|
n[o] = ir(s);
|
|
3065
2712
|
}
|
|
3066
2713
|
}), n;
|
|
3067
2714
|
} else {
|
|
3068
2715
|
let n = /* @__PURE__ */ Object.create(null);
|
|
3069
|
-
|
|
3070
|
-
let r =
|
|
3071
|
-
for (; r && r !==
|
|
2716
|
+
t.set(e, n);
|
|
2717
|
+
let r = e;
|
|
2718
|
+
for (; r && r !== Qs; )
|
|
3072
2719
|
Object.getOwnPropertyNames(r).forEach((o) => {
|
|
3073
2720
|
if (!(o in n))
|
|
3074
2721
|
try {
|
|
3075
|
-
n[o] =
|
|
2722
|
+
n[o] = _e(e[o], t);
|
|
3076
2723
|
} catch (s) {
|
|
3077
2724
|
delete n[o], n[o] = ir(s);
|
|
3078
2725
|
}
|
|
@@ -3080,43 +2727,39 @@ function _t(t, e = /* @__PURE__ */ new WeakMap()) {
|
|
|
3080
2727
|
return n;
|
|
3081
2728
|
}
|
|
3082
2729
|
}
|
|
3083
|
-
c(
|
|
3084
|
-
function
|
|
3085
|
-
return
|
|
2730
|
+
c(_e, "serializeValue");
|
|
2731
|
+
function ei(e) {
|
|
2732
|
+
return e.replace(/__(vite_ssr_import|vi_import)_\d+__\./g, "");
|
|
3086
2733
|
}
|
|
3087
|
-
c(
|
|
3088
|
-
function
|
|
3089
|
-
if (!
|
|
3090
|
-
return { message: String(
|
|
3091
|
-
let r =
|
|
2734
|
+
c(ei, "normalizeErrorMessage");
|
|
2735
|
+
function Pt(e, t, n = /* @__PURE__ */ new WeakSet()) {
|
|
2736
|
+
if (!e || typeof e != "object")
|
|
2737
|
+
return { message: String(e) };
|
|
2738
|
+
let r = e;
|
|
3092
2739
|
r.stack && (r.stackStr = String(r.stack)), r.name && (r.nameStr = String(r.name)), (r.showDiff || r.showDiff === void 0 && r.expected !== void 0 &&
|
|
3093
2740
|
r.actual !== void 0) && (r.diff = rr(r.actual, r.expected, {
|
|
3094
|
-
...
|
|
2741
|
+
...t,
|
|
3095
2742
|
...r.diffOptions
|
|
3096
|
-
})), typeof r.expected != "string" && (r.expected =
|
|
2743
|
+
})), typeof r.expected != "string" && (r.expected = ge(r.expected, 10)), typeof r.actual != "string" && (r.actual = ge(r.actual, 10));
|
|
3097
2744
|
try {
|
|
3098
|
-
typeof r.message == "string" && (r.message =
|
|
2745
|
+
typeof r.message == "string" && (r.message = ei(r.message));
|
|
3099
2746
|
} catch {
|
|
3100
2747
|
}
|
|
3101
2748
|
try {
|
|
3102
|
-
!n.has(r) && typeof r.cause == "object" && (n.add(r), r.cause =
|
|
2749
|
+
!n.has(r) && typeof r.cause == "object" && (n.add(r), r.cause = Pt(r.cause, t, n));
|
|
3103
2750
|
} catch {
|
|
3104
2751
|
}
|
|
3105
2752
|
try {
|
|
3106
|
-
return
|
|
2753
|
+
return _e(r);
|
|
3107
2754
|
} catch (o) {
|
|
3108
|
-
return
|
|
3109
|
-
|
|
3110
|
-
`Failed to fully serialize error: ${o?.message}
|
|
3111
|
-
Inner error message: ${r?.message}`
|
|
3112
|
-
)
|
|
3113
|
-
);
|
|
2755
|
+
return _e(new Error(`Failed to fully serialize error: ${o?.message}
|
|
2756
|
+
Inner error message: ${r?.message}`));
|
|
3114
2757
|
}
|
|
3115
2758
|
}
|
|
3116
|
-
c(
|
|
2759
|
+
c(Pt, "processError");
|
|
3117
2760
|
|
|
3118
2761
|
// src/instrumenter/EVENTS.ts
|
|
3119
|
-
var
|
|
2762
|
+
var ee = {
|
|
3120
2763
|
CALL: "storybook/instrumenter/call",
|
|
3121
2764
|
SYNC: "storybook/instrumenter/sync",
|
|
3122
2765
|
START: "storybook/instrumenter/start",
|
|
@@ -3127,7 +2770,7 @@ var tt = {
|
|
|
3127
2770
|
};
|
|
3128
2771
|
|
|
3129
2772
|
// src/instrumenter/preview-api.ts
|
|
3130
|
-
var
|
|
2773
|
+
var Ze = globalThis.__STORYBOOK_ADDONS_PREVIEW;
|
|
3131
2774
|
|
|
3132
2775
|
// src/instrumenter/types.ts
|
|
3133
2776
|
var cr = /* @__PURE__ */ ((o) => (o.DONE = "done", o.ERROR = "error", o.ACTIVE = "active", o.WAITING = "waiting", o))(cr || {});
|
|
@@ -3139,23 +2782,23 @@ var ur = {
|
|
|
3139
2782
|
goto: !1,
|
|
3140
2783
|
next: !1,
|
|
3141
2784
|
end: !1
|
|
3142
|
-
},
|
|
2785
|
+
}, ti = new Error(
|
|
3143
2786
|
"This function ran after the play function completed. Did you forget to `await` it?"
|
|
3144
|
-
), lr = /* @__PURE__ */ c((
|
|
3145
|
-
prototype.toString.call(
|
|
3146
|
-
if (!lr(
|
|
2787
|
+
), lr = /* @__PURE__ */ c((e) => Object.prototype.toString.call(e) === "[object Object]", "isObject"), ni = /* @__PURE__ */ c((e) => Object.
|
|
2788
|
+
prototype.toString.call(e) === "[object Module]", "isModule"), ri = /* @__PURE__ */ c((e) => {
|
|
2789
|
+
if (!lr(e) && !ni(e))
|
|
3147
2790
|
return !1;
|
|
3148
|
-
if (
|
|
2791
|
+
if (e.constructor === void 0)
|
|
3149
2792
|
return !0;
|
|
3150
|
-
let
|
|
3151
|
-
return !!lr(
|
|
3152
|
-
}, "isInstrumentable"), oi = /* @__PURE__ */ c((
|
|
2793
|
+
let t = e.constructor.prototype;
|
|
2794
|
+
return !!lr(t);
|
|
2795
|
+
}, "isInstrumentable"), oi = /* @__PURE__ */ c((e) => {
|
|
3153
2796
|
try {
|
|
3154
|
-
return new
|
|
2797
|
+
return new e.constructor();
|
|
3155
2798
|
} catch {
|
|
3156
2799
|
return {};
|
|
3157
2800
|
}
|
|
3158
|
-
}, "construct"),
|
|
2801
|
+
}, "construct"), It = /* @__PURE__ */ c(() => ({
|
|
3159
2802
|
renderPhase: void 0,
|
|
3160
2803
|
isDebugging: !1,
|
|
3161
2804
|
isPlaying: !1,
|
|
@@ -3169,26 +2812,26 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3169
2812
|
playUntil: void 0,
|
|
3170
2813
|
resolvers: {},
|
|
3171
2814
|
syncTimeout: void 0
|
|
3172
|
-
}), "getInitialState"), ar = /* @__PURE__ */ c((
|
|
3173
|
-
let n = (
|
|
2815
|
+
}), "getInitialState"), ar = /* @__PURE__ */ c((e, t = !1) => {
|
|
2816
|
+
let n = (t ? e.shadowCalls : e.calls).filter((o) => o.retain);
|
|
3174
2817
|
if (!n.length)
|
|
3175
2818
|
return;
|
|
3176
2819
|
let r = new Map(
|
|
3177
|
-
Array.from(
|
|
2820
|
+
Array.from(e.callRefsByResult.entries()).filter(([, o]) => o.retain)
|
|
3178
2821
|
);
|
|
3179
2822
|
return { cursor: n.length, calls: n, callRefsByResult: r };
|
|
3180
|
-
}, "getRetainedState"),
|
|
2823
|
+
}, "getRetainedState"), Mt = class {
|
|
3181
2824
|
constructor() {
|
|
3182
2825
|
this.initialized = !1;
|
|
3183
2826
|
this.state = W.global.window?.parent?.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__ || {};
|
|
3184
|
-
let
|
|
2827
|
+
let t = /* @__PURE__ */ c(({
|
|
3185
2828
|
storyId: l,
|
|
3186
2829
|
isPlaying: m = !0,
|
|
3187
2830
|
isDebugging: p = !1
|
|
3188
2831
|
}) => {
|
|
3189
2832
|
let f = this.getState(l);
|
|
3190
2833
|
this.setState(l, {
|
|
3191
|
-
...
|
|
2834
|
+
...It(),
|
|
3192
2835
|
...ar(f, p),
|
|
3193
2836
|
shadowCalls: p ? f.shadowCalls : [],
|
|
3194
2837
|
chainedCallIds: p ? f.chainedCallIds : /* @__PURE__ */ new Set(),
|
|
@@ -3197,29 +2840,29 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3197
2840
|
isDebugging: p
|
|
3198
2841
|
}), this.sync(l);
|
|
3199
2842
|
}, "resetState"), n = /* @__PURE__ */ c((l) => ({ storyId: m, playUntil: p }) => {
|
|
3200
|
-
this.getState(m).isDebugging || this.setState(m, ({ calls:
|
|
2843
|
+
this.getState(m).isDebugging || this.setState(m, ({ calls: b }) => ({
|
|
3201
2844
|
calls: [],
|
|
3202
|
-
shadowCalls:
|
|
2845
|
+
shadowCalls: b.map((y) => ({ ...y, status: "waiting" })),
|
|
3203
2846
|
isDebugging: !0
|
|
3204
2847
|
}));
|
|
3205
2848
|
let f = this.getLog(m);
|
|
3206
|
-
this.setState(m, ({ shadowCalls:
|
|
2849
|
+
this.setState(m, ({ shadowCalls: b }) => {
|
|
3207
2850
|
if (p || !f.length)
|
|
3208
2851
|
return { playUntil: p };
|
|
3209
|
-
let y =
|
|
2852
|
+
let y = b.findIndex((g) => g.id === f[0].callId);
|
|
3210
2853
|
return {
|
|
3211
|
-
playUntil:
|
|
2854
|
+
playUntil: b.slice(0, y).filter((g) => g.interceptable && !g.ancestors?.length).slice(-1)[0]?.id
|
|
3212
2855
|
};
|
|
3213
|
-
}), l.emit(
|
|
2856
|
+
}), l.emit(ye.FORCE_REMOUNT, { storyId: m, isDebugging: !0 });
|
|
3214
2857
|
}, "start"), r = /* @__PURE__ */ c((l) => ({ storyId: m }) => {
|
|
3215
|
-
let p = this.getLog(m).filter((
|
|
2858
|
+
let p = this.getLog(m).filter((b) => !b.ancestors?.length), f = p.reduceRight((b, y, g) => b >= 0 || y.status === "waiting" ? b : g, -1);
|
|
3216
2859
|
n(l)({ storyId: m, playUntil: p[f - 1]?.callId });
|
|
3217
2860
|
}, "back"), o = /* @__PURE__ */ c((l) => ({ storyId: m, callId: p }) => {
|
|
3218
|
-
let { calls: f, shadowCalls:
|
|
2861
|
+
let { calls: f, shadowCalls: b, resolvers: y } = this.getState(m), g = f.find(({ id: h }) => h === p), u = b.find(({ id: h }) => h ===
|
|
3219
2862
|
p);
|
|
3220
2863
|
if (!g && u && Object.values(y).length > 0) {
|
|
3221
|
-
let h = this.getLog(m).find((
|
|
3222
|
-
u.id !== h && this.setState(m, { playUntil: u.id }), Object.values(y).forEach((
|
|
2864
|
+
let h = this.getLog(m).find((S) => S.status === "waiting")?.callId;
|
|
2865
|
+
u.id !== h && this.setState(m, { playUntil: u.id }), Object.values(y).forEach((S) => S());
|
|
3223
2866
|
} else
|
|
3224
2867
|
n(l)({ storyId: m, playUntil: p });
|
|
3225
2868
|
}, "goto"), s = /* @__PURE__ */ c((l) => ({ storyId: m }) => {
|
|
@@ -3227,14 +2870,14 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3227
2870
|
if (Object.values(p).length > 0)
|
|
3228
2871
|
Object.values(p).forEach((f) => f());
|
|
3229
2872
|
else {
|
|
3230
|
-
let f = this.getLog(m).find((
|
|
2873
|
+
let f = this.getLog(m).find((b) => b.status === "waiting")?.callId;
|
|
3231
2874
|
f ? n(l)({ storyId: m, playUntil: f }) : i({ storyId: m });
|
|
3232
2875
|
}
|
|
3233
2876
|
}, "next"), i = /* @__PURE__ */ c(({ storyId: l }) => {
|
|
3234
2877
|
this.setState(l, { playUntil: void 0, isDebugging: !1 }), Object.values(this.getState(l).resolvers).forEach((m) => m());
|
|
3235
2878
|
}, "end"), a = /* @__PURE__ */ c(({ storyId: l, newPhase: m }) => {
|
|
3236
2879
|
let { isDebugging: p } = this.getState(l);
|
|
3237
|
-
this.setState(l, { renderPhase: m }), m === "preparing" && p &&
|
|
2880
|
+
this.setState(l, { renderPhase: m }), m === "preparing" && p && t({ storyId: l }), m === "playing" && t({ storyId: l, isDebugging: p }),
|
|
3238
2881
|
m === "played" && this.setState(l, {
|
|
3239
2882
|
isLocked: !1,
|
|
3240
2883
|
isPlaying: !1,
|
|
@@ -3244,39 +2887,39 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3244
2887
|
isPlaying: !1
|
|
3245
2888
|
});
|
|
3246
2889
|
}, "renderPhaseChanged");
|
|
3247
|
-
|
|
3248
|
-
this.channel =
|
|
3249
|
-
on(
|
|
2890
|
+
Ze && Ze.ready().then(() => {
|
|
2891
|
+
this.channel = Ze.getChannel(), this.channel.on(ye.FORCE_REMOUNT, t), this.channel.on(ye.STORY_RENDER_PHASE_CHANGED, a), this.channel.
|
|
2892
|
+
on(ye.SET_CURRENT_STORY, () => {
|
|
3250
2893
|
this.initialized ? this.cleanup() : this.initialized = !0;
|
|
3251
|
-
}), this.channel.on(
|
|
3252
|
-
channel.on(
|
|
2894
|
+
}), this.channel.on(ee.START, n(this.channel)), this.channel.on(ee.BACK, r(this.channel)), this.channel.on(ee.GOTO, o(this.channel)), this.
|
|
2895
|
+
channel.on(ee.NEXT, s(this.channel)), this.channel.on(ee.END, i);
|
|
3253
2896
|
});
|
|
3254
2897
|
}
|
|
3255
2898
|
static {
|
|
3256
2899
|
c(this, "Instrumenter");
|
|
3257
2900
|
}
|
|
3258
|
-
getState(
|
|
3259
|
-
return this.state[
|
|
2901
|
+
getState(t) {
|
|
2902
|
+
return this.state[t] || It();
|
|
3260
2903
|
}
|
|
3261
|
-
setState(
|
|
3262
|
-
let r = this.getState(
|
|
3263
|
-
this.state = { ...this.state, [
|
|
2904
|
+
setState(t, n) {
|
|
2905
|
+
let r = this.getState(t), o = typeof n == "function" ? n(r) : n;
|
|
2906
|
+
this.state = { ...this.state, [t]: { ...r, ...o } }, W.global.window?.parent && (W.global.window.parent.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__ =
|
|
3264
2907
|
this.state);
|
|
3265
2908
|
}
|
|
3266
2909
|
cleanup() {
|
|
3267
2910
|
this.state = Object.entries(this.state).reduce(
|
|
3268
2911
|
(n, [r, o]) => {
|
|
3269
2912
|
let s = ar(o);
|
|
3270
|
-
return s && (n[r] = Object.assign(
|
|
2913
|
+
return s && (n[r] = Object.assign(It(), s)), n;
|
|
3271
2914
|
},
|
|
3272
2915
|
{}
|
|
3273
2916
|
);
|
|
3274
|
-
let
|
|
3275
|
-
this.channel?.emit(
|
|
2917
|
+
let t = { controlStates: ur, logItems: [] };
|
|
2918
|
+
this.channel?.emit(ee.SYNC, t), W.global.window?.parent && (W.global.window.parent.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__ =
|
|
3276
2919
|
this.state);
|
|
3277
2920
|
}
|
|
3278
|
-
getLog(
|
|
3279
|
-
let { calls: n, shadowCalls: r } = this.getState(
|
|
2921
|
+
getLog(t) {
|
|
2922
|
+
let { calls: n, shadowCalls: r } = this.getState(t), o = [...r];
|
|
3280
2923
|
n.forEach((i, a) => {
|
|
3281
2924
|
o[a] = i;
|
|
3282
2925
|
});
|
|
@@ -3291,48 +2934,48 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3291
2934
|
// Traverses the object structure to recursively patch all function properties.
|
|
3292
2935
|
// Returns the original object, or a new object with the same constructor,
|
|
3293
2936
|
// depending on whether it should mutate.
|
|
3294
|
-
instrument(
|
|
3295
|
-
if (!ri(
|
|
3296
|
-
return
|
|
3297
|
-
let { mutate: o = !1, path: s = [] } = n, i = n.getKeys ? n.getKeys(
|
|
2937
|
+
instrument(t, n, r = 0) {
|
|
2938
|
+
if (!ri(t))
|
|
2939
|
+
return t;
|
|
2940
|
+
let { mutate: o = !1, path: s = [] } = n, i = n.getKeys ? n.getKeys(t, r) : Object.keys(t);
|
|
3298
2941
|
return r += 1, i.reduce(
|
|
3299
2942
|
(a, l) => {
|
|
3300
|
-
let m = si(
|
|
2943
|
+
let m = si(t, l);
|
|
3301
2944
|
if (typeof m?.get == "function") {
|
|
3302
2945
|
if (m.configurable) {
|
|
3303
|
-
let f = /* @__PURE__ */ c(() => m?.get?.bind(
|
|
2946
|
+
let f = /* @__PURE__ */ c(() => m?.get?.bind(t)?.(), "getter");
|
|
3304
2947
|
Object.defineProperty(a, l, {
|
|
3305
2948
|
get: /* @__PURE__ */ c(() => this.instrument(f(), { ...n, path: s.concat(l) }, r), "get")
|
|
3306
2949
|
});
|
|
3307
2950
|
}
|
|
3308
2951
|
return a;
|
|
3309
2952
|
}
|
|
3310
|
-
let p =
|
|
2953
|
+
let p = t[l];
|
|
3311
2954
|
return typeof p != "function" ? (a[l] = this.instrument(p, { ...n, path: s.concat(l) }, r), a) : "__originalFn__" in p && typeof p.__originalFn__ ==
|
|
3312
|
-
"function" ? (a[l] = p, a) : (a[l] = (...f) => this.track(l, p,
|
|
2955
|
+
"function" ? (a[l] = p, a) : (a[l] = (...f) => this.track(l, p, t, f, n), a[l].__originalFn__ = p, Object.defineProperty(a[l], "name",
|
|
3313
2956
|
{ value: l, writable: !1 }), Object.keys(p).length > 0 && Object.assign(
|
|
3314
2957
|
a[l],
|
|
3315
2958
|
this.instrument({ ...p }, { ...n, path: s.concat(l) }, r)
|
|
3316
2959
|
), a);
|
|
3317
2960
|
},
|
|
3318
|
-
o ?
|
|
2961
|
+
o ? t : oi(t)
|
|
3319
2962
|
);
|
|
3320
2963
|
}
|
|
3321
2964
|
// Monkey patch an object method to record calls.
|
|
3322
2965
|
// Returns a function that invokes the original function, records the invocation ("call") and
|
|
3323
2966
|
// returns the original result.
|
|
3324
|
-
track(
|
|
2967
|
+
track(t, n, r, o, s) {
|
|
3325
2968
|
let i = o?.[0]?.__storyId__ || W.global.__STORYBOOK_PREVIEW__?.selectionStore?.selection?.storyId, { cursor: a, ancestors: l } = this.getState(
|
|
3326
2969
|
i);
|
|
3327
2970
|
this.setState(i, { cursor: a + 1 });
|
|
3328
|
-
let m = `${l.slice(-1)[0] || i} [${a}] ${
|
|
3329
|
-
p) : f, g = { id: m, cursor: a, storyId: i, ancestors: l, path: p, method:
|
|
2971
|
+
let m = `${l.slice(-1)[0] || i} [${a}] ${t}`, { path: p = [], intercept: f = !1, retain: b = !1 } = s, y = typeof f == "function" ? f(t,
|
|
2972
|
+
p) : f, g = { id: m, cursor: a, storyId: i, ancestors: l, path: p, method: t, args: o, interceptable: y, retain: b }, h = (y && !l.length ?
|
|
3330
2973
|
this.intercept : this.invoke).call(this, n, r, g, s);
|
|
3331
2974
|
return this.instrument(h, { ...s, mutate: !0, path: [{ __callId__: g.id }] });
|
|
3332
2975
|
}
|
|
3333
|
-
intercept(
|
|
2976
|
+
intercept(t, n, r, o) {
|
|
3334
2977
|
let { chainedCallIds: s, isDebugging: i, playUntil: a } = this.getState(r.storyId), l = s.has(r.id);
|
|
3335
|
-
return !i || l || a ? (a === r.id && this.setState(r.storyId, { playUntil: void 0 }), this.invoke(
|
|
2978
|
+
return !i || l || a ? (a === r.id && this.setState(r.storyId, { playUntil: void 0 }), this.invoke(t, n, r, o)) : new Promise((m) => {
|
|
3336
2979
|
this.setState(r.storyId, ({ resolvers: p }) => ({
|
|
3337
2980
|
isLocked: !1,
|
|
3338
2981
|
resolvers: { ...p, [r.id]: m }
|
|
@@ -3340,18 +2983,18 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3340
2983
|
}).then(() => (this.setState(r.storyId, (m) => {
|
|
3341
2984
|
let { [r.id]: p, ...f } = m.resolvers;
|
|
3342
2985
|
return { isLocked: !0, resolvers: f };
|
|
3343
|
-
}), this.invoke(
|
|
2986
|
+
}), this.invoke(t, n, r, o)));
|
|
3344
2987
|
}
|
|
3345
|
-
invoke(
|
|
3346
|
-
let { callRefsByResult: s, renderPhase: i } = this.getState(r.storyId), a = 25, l = /* @__PURE__ */ c((f,
|
|
2988
|
+
invoke(t, n, r, o) {
|
|
2989
|
+
let { callRefsByResult: s, renderPhase: i } = this.getState(r.storyId), a = 25, l = /* @__PURE__ */ c((f, b, y) => {
|
|
3347
2990
|
if (y.includes(f))
|
|
3348
2991
|
return "[Circular]";
|
|
3349
|
-
if (y = [...y, f],
|
|
2992
|
+
if (y = [...y, f], b > a)
|
|
3350
2993
|
return "...";
|
|
3351
2994
|
if (s.has(f))
|
|
3352
2995
|
return s.get(f);
|
|
3353
2996
|
if (f instanceof Array)
|
|
3354
|
-
return f.map((g) => l(g, ++
|
|
2997
|
+
return f.map((g) => l(g, ++b, y));
|
|
3355
2998
|
if (f instanceof Date)
|
|
3356
2999
|
return { __date__: { value: f.toISOString() } };
|
|
3357
3000
|
if (f instanceof Error) {
|
|
@@ -3363,32 +3006,32 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3363
3006
|
return { __regexp__: { flags: g, source: u } };
|
|
3364
3007
|
}
|
|
3365
3008
|
if (f instanceof W.global.window?.HTMLElement) {
|
|
3366
|
-
let { prefix: g, localName: u, id: h, classList:
|
|
3009
|
+
let { prefix: g, localName: u, id: h, classList: S, innerText: _ } = f, O = Array.from(S);
|
|
3367
3010
|
return { __element__: { prefix: g, localName: u, id: h, classNames: O, innerText: _ } };
|
|
3368
3011
|
}
|
|
3369
3012
|
return typeof f == "function" ? {
|
|
3370
3013
|
__function__: { name: "getMockName" in f ? f.getMockName() : f.name }
|
|
3371
3014
|
} : typeof f == "symbol" ? { __symbol__: { description: f.description } } : typeof f == "object" && f?.constructor?.name && f?.constructor?.
|
|
3372
3015
|
name !== "Object" ? { __class__: { name: f.constructor.name } } : Object.prototype.toString.call(f) === "[object Object]" ? Object.fromEntries(
|
|
3373
|
-
Object.entries(f).map(([g, u]) => [g, l(u, ++
|
|
3016
|
+
Object.entries(f).map(([g, u]) => [g, l(u, ++b, y)])
|
|
3374
3017
|
) : f;
|
|
3375
3018
|
}, "serializeValues"), m = {
|
|
3376
3019
|
...r,
|
|
3377
3020
|
args: r.args.map((f) => l(f, 0, []))
|
|
3378
3021
|
};
|
|
3379
3022
|
r.path.forEach((f) => {
|
|
3380
|
-
f?.__callId__ && this.setState(r.storyId, ({ chainedCallIds:
|
|
3381
|
-
chainedCallIds: new Set(Array.from(
|
|
3023
|
+
f?.__callId__ && this.setState(r.storyId, ({ chainedCallIds: b }) => ({
|
|
3024
|
+
chainedCallIds: new Set(Array.from(b).concat(f.__callId__))
|
|
3382
3025
|
}));
|
|
3383
3026
|
});
|
|
3384
3027
|
let p = /* @__PURE__ */ c((f) => {
|
|
3385
3028
|
if (f instanceof Error) {
|
|
3386
|
-
let { name:
|
|
3029
|
+
let { name: b, message: y, stack: g, callId: u = r.id } = f, {
|
|
3387
3030
|
showDiff: h = void 0,
|
|
3388
|
-
diff:
|
|
3031
|
+
diff: S = void 0,
|
|
3389
3032
|
actual: _ = void 0,
|
|
3390
3033
|
expected: O = void 0
|
|
3391
|
-
} = f.name === "AssertionError" ?
|
|
3034
|
+
} = f.name === "AssertionError" ? Pt(f) : f, d = { name: b, message: y, stack: g, callId: u, showDiff: h, diff: S, actual: _, expected: O };
|
|
3392
3035
|
if (this.update({ ...m, status: "error", exception: d }), this.setState(r.storyId, (E) => ({
|
|
3393
3036
|
callRefsByResult: new Map([
|
|
3394
3037
|
...Array.from(E.callRefsByResult.entries()),
|
|
@@ -3401,19 +3044,19 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3401
3044
|
}, "handleException");
|
|
3402
3045
|
try {
|
|
3403
3046
|
if (i === "played" && !r.retain)
|
|
3404
|
-
throw
|
|
3405
|
-
let
|
|
3047
|
+
throw ti;
|
|
3048
|
+
let b = (o.getArgs ? o.getArgs(r, this.getState(r.storyId)) : r.args).map((g) => typeof g != "function" || ii(g) || Object.keys(g).length ?
|
|
3406
3049
|
g : (...u) => {
|
|
3407
|
-
let { cursor: h, ancestors:
|
|
3408
|
-
this.setState(r.storyId, { cursor: 0, ancestors: [...
|
|
3409
|
-
let _ = /* @__PURE__ */ c(() => this.setState(r.storyId, { cursor: h, ancestors:
|
|
3050
|
+
let { cursor: h, ancestors: S } = this.getState(r.storyId);
|
|
3051
|
+
this.setState(r.storyId, { cursor: 0, ancestors: [...S, r.id] });
|
|
3052
|
+
let _ = /* @__PURE__ */ c(() => this.setState(r.storyId, { cursor: h, ancestors: S }), "restore"), O = !1;
|
|
3410
3053
|
try {
|
|
3411
3054
|
let d = g(...u);
|
|
3412
3055
|
return d instanceof Promise ? (O = !0, d.finally(_)) : d;
|
|
3413
3056
|
} finally {
|
|
3414
3057
|
O || _();
|
|
3415
3058
|
}
|
|
3416
|
-
}), y =
|
|
3059
|
+
}), y = t.apply(n, b);
|
|
3417
3060
|
return y && ["object", "function", "symbol"].includes(typeof y) && this.setState(r.storyId, (g) => ({
|
|
3418
3061
|
callRefsByResult: new Map([
|
|
3419
3062
|
...Array.from(g.callRefsByResult.entries()),
|
|
@@ -3428,26 +3071,26 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3428
3071
|
}
|
|
3429
3072
|
}
|
|
3430
3073
|
// Sends the call info to the manager and synchronizes the log.
|
|
3431
|
-
update(
|
|
3432
|
-
this.channel?.emit(
|
|
3433
|
-
let r = n.concat(
|
|
3074
|
+
update(t) {
|
|
3075
|
+
this.channel?.emit(ee.CALL, t), this.setState(t.storyId, ({ calls: n }) => {
|
|
3076
|
+
let r = n.concat(t).reduce((o, s) => Object.assign(o, { [s.id]: s }), {});
|
|
3434
3077
|
return {
|
|
3435
3078
|
// Calls are sorted to ensure parent calls always come before calls in their callback.
|
|
3436
3079
|
calls: Object.values(r).sort(
|
|
3437
3080
|
(o, s) => o.id.localeCompare(s.id, void 0, { numeric: !0 })
|
|
3438
3081
|
)
|
|
3439
3082
|
};
|
|
3440
|
-
}), this.sync(
|
|
3083
|
+
}), this.sync(t.storyId);
|
|
3441
3084
|
}
|
|
3442
3085
|
// Builds a log of interceptable calls and control states and sends it to the manager.
|
|
3443
3086
|
// Uses a 0ms debounce because this might get called many times in one tick.
|
|
3444
|
-
sync(
|
|
3087
|
+
sync(t) {
|
|
3445
3088
|
let n = /* @__PURE__ */ c(() => {
|
|
3446
|
-
let { isLocked: r, isPlaying: o } = this.getState(
|
|
3089
|
+
let { isLocked: r, isPlaying: o } = this.getState(t), s = this.getLog(t), i = s.filter(({ ancestors: f }) => !f.length).find((f) => f.
|
|
3447
3090
|
status === "waiting")?.callId, a = s.some((f) => f.status === "active");
|
|
3448
3091
|
if (r || a || s.length === 0) {
|
|
3449
3092
|
let f = { controlStates: ur, logItems: s };
|
|
3450
|
-
this.channel?.emit(
|
|
3093
|
+
this.channel?.emit(ee.SYNC, f);
|
|
3451
3094
|
return;
|
|
3452
3095
|
}
|
|
3453
3096
|
let l = s.some(
|
|
@@ -3459,37 +3102,37 @@ prototype.toString.call(t) === "[object Module]", "isModule"), ri = /* @__PURE__
|
|
|
3459
3102
|
next: o,
|
|
3460
3103
|
end: o
|
|
3461
3104
|
}, logItems: s, pausedAt: i };
|
|
3462
|
-
this.channel?.emit(
|
|
3105
|
+
this.channel?.emit(ee.SYNC, p);
|
|
3463
3106
|
}, "synchronize");
|
|
3464
|
-
this.setState(
|
|
3107
|
+
this.setState(t, ({ syncTimeout: r }) => (clearTimeout(r), { syncTimeout: setTimeout(n, 0) }));
|
|
3465
3108
|
}
|
|
3466
3109
|
};
|
|
3467
|
-
function mr(
|
|
3110
|
+
function mr(e, t = {}) {
|
|
3468
3111
|
try {
|
|
3469
3112
|
let n = !1, r = !1;
|
|
3470
3113
|
return W.global.window?.location?.search?.includes("instrument=true") ? n = !0 : W.global.window?.location?.search?.includes("instrument\
|
|
3471
|
-
=false") && (r = !0), W.global.window?.parent === W.global.window && !n || r ?
|
|
3472
|
-
(W.global.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__ = new
|
|
3473
|
-
instrument(
|
|
3114
|
+
=false") && (r = !0), W.global.window?.parent === W.global.window && !n || r ? e : (W.global.window && !W.global.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__ &&
|
|
3115
|
+
(W.global.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__ = new Mt()), (W.global.window?.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__).
|
|
3116
|
+
instrument(e, t));
|
|
3474
3117
|
} catch (n) {
|
|
3475
|
-
return fr.once.warn(n),
|
|
3118
|
+
return fr.once.warn(n), e;
|
|
3476
3119
|
}
|
|
3477
3120
|
}
|
|
3478
3121
|
c(mr, "instrument");
|
|
3479
|
-
function si(
|
|
3480
|
-
let n =
|
|
3122
|
+
function si(e, t) {
|
|
3123
|
+
let n = e;
|
|
3481
3124
|
for (; n != null; ) {
|
|
3482
|
-
let r = Object.getOwnPropertyDescriptor(n,
|
|
3125
|
+
let r = Object.getOwnPropertyDescriptor(n, t);
|
|
3483
3126
|
if (r)
|
|
3484
3127
|
return r;
|
|
3485
3128
|
n = Object.getPrototypeOf(n);
|
|
3486
3129
|
}
|
|
3487
3130
|
}
|
|
3488
3131
|
c(si, "getPropertyDescriptor");
|
|
3489
|
-
function ii(
|
|
3490
|
-
if (typeof
|
|
3132
|
+
function ii(e) {
|
|
3133
|
+
if (typeof e != "function")
|
|
3491
3134
|
return !1;
|
|
3492
|
-
let
|
|
3493
|
-
return
|
|
3135
|
+
let t = Object.getOwnPropertyDescriptor(e, "prototype");
|
|
3136
|
+
return t ? !t.writable : !1;
|
|
3494
3137
|
}
|
|
3495
3138
|
c(ii, "isClass");
|