storybook 9.1.0-alpha.6 → 9.1.0-alpha.7
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/assets/browser/favicon-wrapper.svg +46 -0
- package/assets/browser/favicon.svg +1 -1
- package/dist/bin/index.cjs +43 -43
- package/dist/bin/index.js +43 -43
- package/dist/cli/bin/index.cjs +513 -513
- package/dist/cli/bin/index.js +535 -535
- package/dist/cli/index.cjs +2454 -2453
- package/dist/cli/index.d.ts +10 -3
- package/dist/cli/index.js +2436 -2435
- package/dist/common/index.cjs +64 -61
- package/dist/common/index.d.ts +9 -3
- package/dist/common/index.js +64 -61
- package/dist/components/index.cjs +1459 -1447
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +407 -394
- package/dist/core-server/index.cjs +5833 -5819
- package/dist/core-server/index.d.ts +4 -1
- package/dist/core-server/index.js +4848 -4835
- package/dist/core-server/presets/common-manager.js +3403 -3332
- package/dist/core-server/presets/common-preset.cjs +1831 -1837
- package/dist/core-server/presets/common-preset.js +1787 -1792
- package/dist/csf/index.cjs +2536 -736
- package/dist/csf/index.d.ts +250 -9
- package/dist/csf/index.js +2558 -749
- package/dist/instrumenter/index.cjs +1150 -1099
- package/dist/instrumenter/index.d.ts +1 -0
- package/dist/instrumenter/index.js +1261 -1214
- package/dist/manager/globals-runtime.js +21313 -23957
- package/dist/manager/runtime.js +3713 -3534
- package/dist/manager-api/index.cjs +3 -3
- package/dist/manager-api/index.d.ts +8 -531
- package/dist/manager-api/index.js +3 -3
- package/dist/node-logger/index.cjs +1620 -1620
- package/dist/node-logger/index.js +1619 -1619
- package/dist/preview/runtime.js +13337 -16032
- package/dist/preview-api/index.cjs +273 -271
- package/dist/preview-api/index.d.ts +4 -1
- package/dist/preview-api/index.js +14 -12
- package/dist/telemetry/index.cjs +500 -500
- package/dist/telemetry/index.js +478 -478
- package/dist/test/index.cjs +9136 -9815
- package/dist/test/index.js +8339 -9025
- package/dist/types/index.d.ts +12 -12
- package/package.json +5 -196
- package/dist/actions/preview.cjs +0 -159
- package/dist/actions/preview.d.ts +0 -45
- package/dist/actions/preview.js +0 -149
- package/dist/backgrounds/index.cjs +0 -16
- package/dist/backgrounds/index.d.ts +0 -2
- package/dist/backgrounds/index.js +0 -0
- package/dist/backgrounds/preview.cjs +0 -143
- package/dist/backgrounds/preview.d.ts +0 -53
- package/dist/backgrounds/preview.js +0 -127
- package/dist/component-testing/index.cjs +0 -23
- package/dist/component-testing/index.d.ts +0 -3
- package/dist/component-testing/index.js +0 -5
- package/dist/component-testing/preview.cjs +0 -40
- package/dist/component-testing/preview.d.ts +0 -5
- package/dist/component-testing/preview.js +0 -25
- package/dist/controls/preview.cjs +0 -26
- package/dist/controls/preview.d.ts +0 -43
- package/dist/controls/preview.js +0 -9
- package/dist/highlight/preview.cjs +0 -590
- package/dist/highlight/preview.d.ts +0 -20
- package/dist/highlight/preview.js +0 -575
- package/dist/measure/index.cjs +0 -16
- package/dist/measure/index.d.ts +0 -2
- package/dist/measure/index.js +0 -0
- package/dist/measure/preview.cjs +0 -466
- package/dist/measure/preview.d.ts +0 -25
- package/dist/measure/preview.js +0 -450
- package/dist/outline/index.cjs +0 -16
- package/dist/outline/index.d.ts +0 -2
- package/dist/outline/index.js +0 -0
- package/dist/outline/preview.cjs +0 -518
- package/dist/outline/preview.d.ts +0 -25
- package/dist/outline/preview.js +0 -486
- package/dist/test/preview.cjs +0 -73
- package/dist/test/preview.d.ts +0 -17
- package/dist/test/preview.js +0 -66
- package/dist/viewport/preview.cjs +0 -35
- package/dist/viewport/preview.d.ts +0 -62
- package/dist/viewport/preview.js +0 -19
package/dist/telemetry/index.js
CHANGED
|
@@ -4,12 +4,12 @@ import { dirname as ESM_COMPAT_dirname } from 'node:path';
|
|
|
4
4
|
const __filename = ESM_COMPAT_fileURLToPath(import.meta.url);
|
|
5
5
|
const __dirname = ESM_COMPAT_dirname(__filename);
|
|
6
6
|
const require = ESM_COMPAT_Module.createRequire(import.meta.url);
|
|
7
|
-
var
|
|
7
|
+
var ji = Object.create;
|
|
8
8
|
var Gt = Object.defineProperty;
|
|
9
9
|
var Ri = Object.getOwnPropertyDescriptor;
|
|
10
10
|
var Ni = Object.getOwnPropertyNames;
|
|
11
11
|
var Zi = Object.getPrototypeOf, Mi = Object.prototype.hasOwnProperty;
|
|
12
|
-
var i = (t, e) => Gt(t, "name", { value: e, configurable: !0 }),
|
|
12
|
+
var i = (t, e) => Gt(t, "name", { value: e, configurable: !0 }), j = /* @__PURE__ */ ((t) => typeof require < "u" ? require : typeof Proxy <
|
|
13
13
|
"u" ? new Proxy(t, {
|
|
14
14
|
get: (e, r) => (typeof require < "u" ? require : e)[r]
|
|
15
15
|
}) : t)(function(t) {
|
|
@@ -24,7 +24,7 @@ var Di = (t, e, r, n) => {
|
|
|
24
24
|
!Mi.call(t, s) && s !== r && Gt(t, s, { get: () => e[s], enumerable: !(n = Ri(e, s)) || n.enumerable });
|
|
25
25
|
return t;
|
|
26
26
|
};
|
|
27
|
-
var z = (t, e, r) => (r = t != null ?
|
|
27
|
+
var z = (t, e, r) => (r = t != null ? ji(Zi(t)) : {}, Di(
|
|
28
28
|
// If the importer is in node compatibility mode or this is not an ESM
|
|
29
29
|
// file that has been converted to a CommonJS file using a Babel-
|
|
30
30
|
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
@@ -34,7 +34,7 @@ var z = (t, e, r) => (r = t != null ? Oi(Zi(t)) : {}, Di(
|
|
|
34
34
|
));
|
|
35
35
|
|
|
36
36
|
// ../node_modules/picocolors/picocolors.js
|
|
37
|
-
var dn = I((
|
|
37
|
+
var dn = I((Al, zt) => {
|
|
38
38
|
var tt = process || {}, an = tt.argv || [], et = tt.env || {}, Li = !(et.NO_COLOR || an.includes("--no-color")) && (!!et.FORCE_COLOR || an.
|
|
39
39
|
includes("--color") || tt.platform === "win32" || (tt.stdout || {}).isTTY && et.TERM !== "dumb" || !!et.CI), Ui = /* @__PURE__ */ i((t, e, r = t) => (n) => {
|
|
40
40
|
let s = "" + n, o = s.indexOf(e, t.length);
|
|
@@ -97,11 +97,11 @@ var dn = I((jl, zt) => {
|
|
|
97
97
|
});
|
|
98
98
|
|
|
99
99
|
// ../node_modules/walk-up-path/dist/cjs/index.js
|
|
100
|
-
var
|
|
100
|
+
var xn = I((st) => {
|
|
101
101
|
"use strict";
|
|
102
102
|
Object.defineProperty(st, "__esModule", { value: !0 });
|
|
103
103
|
st.walkUp = void 0;
|
|
104
|
-
var gn =
|
|
104
|
+
var gn = j("path"), Fi = /* @__PURE__ */ i(function* (t) {
|
|
105
105
|
for (t = (0, gn.resolve)(t); t; ) {
|
|
106
106
|
yield t;
|
|
107
107
|
let e = (0, gn.dirname)(t);
|
|
@@ -309,51 +309,51 @@ var it = I((K) => {
|
|
|
309
309
|
var tr = I((er) => {
|
|
310
310
|
"use strict";
|
|
311
311
|
Object.defineProperty(er, "__esModule", { value: !0 });
|
|
312
|
-
var ee = Ne(),
|
|
312
|
+
var ee = Ne(), O = it(), ta = /* @__PURE__ */ i((t, e) => {
|
|
313
313
|
let r;
|
|
314
314
|
switch (t.code) {
|
|
315
|
-
case
|
|
315
|
+
case O.ZodIssueCode.invalid_type:
|
|
316
316
|
t.received === ee.ZodParsedType.undefined ? r = "Required" : r = `Expected ${t.expected}, received ${t.received}`;
|
|
317
317
|
break;
|
|
318
|
-
case
|
|
318
|
+
case O.ZodIssueCode.invalid_literal:
|
|
319
319
|
r = `Invalid literal value, expected ${JSON.stringify(t.expected, ee.util.jsonStringifyReplacer)}`;
|
|
320
320
|
break;
|
|
321
|
-
case
|
|
321
|
+
case O.ZodIssueCode.unrecognized_keys:
|
|
322
322
|
r = `Unrecognized key(s) in object: ${ee.util.joinValues(t.keys, ", ")}`;
|
|
323
323
|
break;
|
|
324
|
-
case
|
|
324
|
+
case O.ZodIssueCode.invalid_union:
|
|
325
325
|
r = "Invalid input";
|
|
326
326
|
break;
|
|
327
|
-
case
|
|
327
|
+
case O.ZodIssueCode.invalid_union_discriminator:
|
|
328
328
|
r = `Invalid discriminator value. Expected ${ee.util.joinValues(t.options)}`;
|
|
329
329
|
break;
|
|
330
|
-
case
|
|
330
|
+
case O.ZodIssueCode.invalid_enum_value:
|
|
331
331
|
r = `Invalid enum value. Expected ${ee.util.joinValues(t.options)}, received '${t.received}'`;
|
|
332
332
|
break;
|
|
333
|
-
case
|
|
333
|
+
case O.ZodIssueCode.invalid_arguments:
|
|
334
334
|
r = "Invalid function arguments";
|
|
335
335
|
break;
|
|
336
|
-
case
|
|
336
|
+
case O.ZodIssueCode.invalid_return_type:
|
|
337
337
|
r = "Invalid function return type";
|
|
338
338
|
break;
|
|
339
|
-
case
|
|
339
|
+
case O.ZodIssueCode.invalid_date:
|
|
340
340
|
r = "Invalid date";
|
|
341
341
|
break;
|
|
342
|
-
case
|
|
342
|
+
case O.ZodIssueCode.invalid_string:
|
|
343
343
|
typeof t.validation == "object" ? "includes" in t.validation ? (r = `Invalid input: must include "${t.validation.includes}"`, typeof t.
|
|
344
344
|
validation.position == "number" && (r = `${r} at one or more positions greater than or equal to ${t.validation.position}`)) : "start\
|
|
345
345
|
sWith" in t.validation ? r = `Invalid input: must start with "${t.validation.startsWith}"` : "endsWith" in t.validation ? r = `Invalid input\
|
|
346
346
|
: must end with "${t.validation.endsWith}"` : ee.util.assertNever(t.validation) : t.validation !== "regex" ? r = `Invalid ${t.validation}` :
|
|
347
347
|
r = "Invalid";
|
|
348
348
|
break;
|
|
349
|
-
case
|
|
349
|
+
case O.ZodIssueCode.too_small:
|
|
350
350
|
t.type === "array" ? r = `Array must contain ${t.exact ? "exactly" : t.inclusive ? "at least" : "more than"} ${t.minimum} element(s)` :
|
|
351
351
|
t.type === "string" ? r = `String must contain ${t.exact ? "exactly" : t.inclusive ? "at least" : "over"} ${t.minimum} character(s)` :
|
|
352
352
|
t.type === "number" ? r = `Number must be ${t.exact ? "exactly equal to " : t.inclusive ? "greater than or equal to " : "greater tha\
|
|
353
353
|
n "}${t.minimum}` : t.type === "date" ? r = `Date must be ${t.exact ? "exactly equal to " : t.inclusive ? "greater than or equal to " : "gre\
|
|
354
354
|
ater than "}${new Date(Number(t.minimum))}` : r = "Invalid input";
|
|
355
355
|
break;
|
|
356
|
-
case
|
|
356
|
+
case O.ZodIssueCode.too_big:
|
|
357
357
|
t.type === "array" ? r = `Array must contain ${t.exact ? "exactly" : t.inclusive ? "at most" : "less than"} ${t.maximum} element(s)` :
|
|
358
358
|
t.type === "string" ? r = `String must contain ${t.exact ? "exactly" : t.inclusive ? "at most" : "under"} ${t.maximum} character(s)` :
|
|
359
359
|
t.type === "number" ? r = `Number must be ${t.exact ? "exactly" : t.inclusive ? "less than or equal to" : "less than"} ${t.maximum}` :
|
|
@@ -361,16 +361,16 @@ ater than "}${new Date(Number(t.minimum))}` : r = "Invalid input";
|
|
|
361
361
|
t.type === "date" ? r = `Date must be ${t.exact ? "exactly" : t.inclusive ? "smaller than or equal to" : "smaller than"} ${new Date(
|
|
362
362
|
Number(t.maximum))}` : r = "Invalid input";
|
|
363
363
|
break;
|
|
364
|
-
case
|
|
364
|
+
case O.ZodIssueCode.custom:
|
|
365
365
|
r = "Invalid input";
|
|
366
366
|
break;
|
|
367
|
-
case
|
|
367
|
+
case O.ZodIssueCode.invalid_intersection_types:
|
|
368
368
|
r = "Intersection results could not be merged";
|
|
369
369
|
break;
|
|
370
|
-
case
|
|
370
|
+
case O.ZodIssueCode.not_multiple_of:
|
|
371
371
|
r = `Number must be a multiple of ${t.multipleOf}`;
|
|
372
372
|
break;
|
|
373
|
-
case
|
|
373
|
+
case O.ZodIssueCode.not_finite:
|
|
374
374
|
r = "Number must be finite";
|
|
375
375
|
break;
|
|
376
376
|
default:
|
|
@@ -519,24 +519,24 @@ var nr = I((T) => {
|
|
|
519
519
|
});
|
|
520
520
|
|
|
521
521
|
// ../node_modules/zod/lib/helpers/typeAliases.js
|
|
522
|
-
var
|
|
522
|
+
var An = I((Pn) => {
|
|
523
523
|
"use strict";
|
|
524
524
|
Object.defineProperty(Pn, "__esModule", { value: !0 });
|
|
525
525
|
});
|
|
526
526
|
|
|
527
527
|
// ../node_modules/zod/lib/helpers/errorUtil.js
|
|
528
|
-
var
|
|
528
|
+
var jn = I((ct) => {
|
|
529
529
|
"use strict";
|
|
530
530
|
Object.defineProperty(ct, "__esModule", { value: !0 });
|
|
531
531
|
ct.errorUtil = void 0;
|
|
532
|
-
var
|
|
532
|
+
var On;
|
|
533
533
|
(function(t) {
|
|
534
534
|
t.errToObj = (e) => typeof e == "string" ? { message: e } : e || {}, t.toString = (e) => typeof e == "string" ? e : e?.message;
|
|
535
|
-
})(
|
|
535
|
+
})(On || (ct.errorUtil = On = {}));
|
|
536
536
|
});
|
|
537
537
|
|
|
538
538
|
// ../node_modules/zod/lib/types.js
|
|
539
|
-
var
|
|
539
|
+
var qn = I((d) => {
|
|
540
540
|
"use strict";
|
|
541
541
|
var ut = d && d.__classPrivateFieldGet || function(t, e, r, n) {
|
|
542
542
|
if (r === "a" && !n) throw new TypeError("Private accessor was defined without a getter");
|
|
@@ -560,7 +560,7 @@ t declare it");
|
|
|
560
560
|
d.promise = d.preprocess = d.pipeline = d.ostring = d.optional = d.onumber = d.oboolean = d.object = d.number = d.nullable = d.null = d.never =
|
|
561
561
|
d.nativeEnum = d.nan = d.map = d.literal = d.lazy = d.intersection = d.instanceof = d.function = d.enum = d.effect = d.discriminatedUnion =
|
|
562
562
|
d.date = void 0;
|
|
563
|
-
var dt = at(), y =
|
|
563
|
+
var dt = at(), y = jn(), u = nr(), h = Ne(), m = it(), D = class {
|
|
564
564
|
static {
|
|
565
565
|
i(this, "ParseInputLazyPath");
|
|
566
566
|
}
|
|
@@ -586,7 +586,7 @@ t declare it");
|
|
|
586
586
|
}
|
|
587
587
|
};
|
|
588
588
|
}, "handleResult");
|
|
589
|
-
function
|
|
589
|
+
function v(t) {
|
|
590
590
|
if (!t)
|
|
591
591
|
return {};
|
|
592
592
|
let { errorMap: e, invalid_type_error: r, required_error: n, description: s } = t;
|
|
@@ -600,8 +600,8 @@ t declare it");
|
|
|
600
600
|
p : c.defaultError };
|
|
601
601
|
}, "customMap"), description: s };
|
|
602
602
|
}
|
|
603
|
-
i(
|
|
604
|
-
var
|
|
603
|
+
i(v, "processCreateParams");
|
|
604
|
+
var _ = class {
|
|
605
605
|
static {
|
|
606
606
|
i(this, "ZodType");
|
|
607
607
|
}
|
|
@@ -782,7 +782,7 @@ eProperties");
|
|
|
782
782
|
}
|
|
783
783
|
transform(e) {
|
|
784
784
|
return new Z({
|
|
785
|
-
...
|
|
785
|
+
...v(this._def),
|
|
786
786
|
schema: this,
|
|
787
787
|
typeName: g.ZodEffects,
|
|
788
788
|
effect: { type: "transform", transform: e }
|
|
@@ -791,7 +791,7 @@ eProperties");
|
|
|
791
791
|
default(e) {
|
|
792
792
|
let r = typeof e == "function" ? e : () => e;
|
|
793
793
|
return new fe({
|
|
794
|
-
...
|
|
794
|
+
...v(this._def),
|
|
795
795
|
innerType: this,
|
|
796
796
|
defaultValue: r,
|
|
797
797
|
typeName: g.ZodDefault
|
|
@@ -801,13 +801,13 @@ eProperties");
|
|
|
801
801
|
return new Le({
|
|
802
802
|
typeName: g.ZodBranded,
|
|
803
803
|
type: this,
|
|
804
|
-
...
|
|
804
|
+
...v(this._def)
|
|
805
805
|
});
|
|
806
806
|
}
|
|
807
807
|
catch(e) {
|
|
808
808
|
let r = typeof e == "function" ? e : () => e;
|
|
809
809
|
return new me({
|
|
810
|
-
...
|
|
810
|
+
...v(this._def),
|
|
811
811
|
innerType: this,
|
|
812
812
|
catchValue: r,
|
|
813
813
|
typeName: g.ZodCatch
|
|
@@ -833,39 +833,39 @@ eProperties");
|
|
|
833
833
|
return this.safeParse(null).success;
|
|
834
834
|
}
|
|
835
835
|
};
|
|
836
|
-
d.ZodType =
|
|
837
|
-
d.Schema =
|
|
838
|
-
d.ZodSchema =
|
|
839
|
-
var ha = /^c[^\s-]{8,}$/i, ya = /^[0-9a-z]+$/, ga = /^[0-9A-HJKMNP-TV-Z]{26}$/i,
|
|
840
|
-
|
|
841
|
-
|
|
836
|
+
d.ZodType = _;
|
|
837
|
+
d.Schema = _;
|
|
838
|
+
d.ZodSchema = _;
|
|
839
|
+
var ha = /^c[^\s-]{8,}$/i, ya = /^[0-9a-z]+$/, ga = /^[0-9A-HJKMNP-TV-Z]{26}$/i, xa = /^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,
|
|
840
|
+
ba = /^[a-z0-9_-]{21}$/i, va = /^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/, _a = /^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,
|
|
841
|
+
wa = /^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i, ka = "^(\\p{Extended_Pictographic}|\\p{Emoji_Comp\
|
|
842
842
|
onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/, Ia = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,
|
|
843
843
|
Sa = /^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,
|
|
844
844
|
Ea = /^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,
|
|
845
845
|
Ca = /^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/, Pa = /^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,
|
|
846
846
|
Mn = "((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469\
|
|
847
|
-
]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",
|
|
847
|
+
]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))", Aa = new RegExp(`^${Mn}$`);
|
|
848
848
|
function Dn(t) {
|
|
849
849
|
let e = "([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";
|
|
850
850
|
return t.precision ? e = `${e}\\.\\d{${t.precision}}` : t.precision == null && (e = `${e}(\\.\\d+)?`), e;
|
|
851
851
|
}
|
|
852
852
|
i(Dn, "timeRegexSource");
|
|
853
|
-
function
|
|
853
|
+
function Oa(t) {
|
|
854
854
|
return new RegExp(`^${Dn(t)}$`);
|
|
855
855
|
}
|
|
856
|
-
i(
|
|
856
|
+
i(Oa, "timeRegex");
|
|
857
857
|
function Ln(t) {
|
|
858
858
|
let e = `${Mn}T${Dn(t)}`, r = [];
|
|
859
859
|
return r.push(t.local ? "Z?" : "Z"), t.offset && r.push("([+-]\\d{2}:?\\d{2})"), e = `${e}(${r.join("|")})`, new RegExp(`^${e}$`);
|
|
860
860
|
}
|
|
861
861
|
i(Ln, "datetimeRegex");
|
|
862
862
|
d.datetimeRegex = Ln;
|
|
863
|
-
function
|
|
863
|
+
function ja(t, e) {
|
|
864
864
|
return !!((e === "v4" || !e) && Ta.test(t) || (e === "v6" || !e) && Sa.test(t));
|
|
865
865
|
}
|
|
866
|
-
i(
|
|
866
|
+
i(ja, "isValidIP");
|
|
867
867
|
function Ra(t, e) {
|
|
868
|
-
if (!
|
|
868
|
+
if (!va.test(t))
|
|
869
869
|
return !1;
|
|
870
870
|
try {
|
|
871
871
|
let [r] = t.split("."), n = r.replace(/-/g, "+").replace(/_/g, "/").padEnd(r.length + (4 - r.length % 4) % 4, "="), s = JSON.parse(atob(
|
|
@@ -880,7 +880,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
880
880
|
return !!((e === "v4" || !e) && Ia.test(t) || (e === "v6" || !e) && Ea.test(t));
|
|
881
881
|
}
|
|
882
882
|
i(Na, "isValidCidr");
|
|
883
|
-
var J = class t extends
|
|
883
|
+
var J = class t extends _ {
|
|
884
884
|
static {
|
|
885
885
|
i(this, "ZodString");
|
|
886
886
|
}
|
|
@@ -931,7 +931,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
931
931
|
message: o.message
|
|
932
932
|
}), n.dirty());
|
|
933
933
|
} else if (o.kind === "email")
|
|
934
|
-
|
|
934
|
+
wa.test(e.data) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
935
935
|
validation: "email",
|
|
936
936
|
code: m.ZodIssueCode.invalid_string,
|
|
937
937
|
message: o.message
|
|
@@ -943,13 +943,13 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
943
943
|
message: o.message
|
|
944
944
|
}), n.dirty());
|
|
945
945
|
else if (o.kind === "uuid")
|
|
946
|
-
|
|
946
|
+
xa.test(e.data) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
947
947
|
validation: "uuid",
|
|
948
948
|
code: m.ZodIssueCode.invalid_string,
|
|
949
949
|
message: o.message
|
|
950
950
|
}), n.dirty());
|
|
951
951
|
else if (o.kind === "nanoid")
|
|
952
|
-
|
|
952
|
+
ba.test(e.data) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
953
953
|
validation: "nanoid",
|
|
954
954
|
code: m.ZodIssueCode.invalid_string,
|
|
955
955
|
message: o.message
|
|
@@ -1005,19 +1005,19 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1005
1005
|
code: m.ZodIssueCode.invalid_string,
|
|
1006
1006
|
validation: "datetime",
|
|
1007
1007
|
message: o.message
|
|
1008
|
-
}), n.dirty()) : o.kind === "date" ?
|
|
1008
|
+
}), n.dirty()) : o.kind === "date" ? Aa.test(e.data) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
1009
1009
|
code: m.ZodIssueCode.invalid_string,
|
|
1010
1010
|
validation: "date",
|
|
1011
1011
|
message: o.message
|
|
1012
|
-
}), n.dirty()) : o.kind === "time" ?
|
|
1012
|
+
}), n.dirty()) : o.kind === "time" ? Oa(o).test(e.data) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
1013
1013
|
code: m.ZodIssueCode.invalid_string,
|
|
1014
1014
|
validation: "time",
|
|
1015
1015
|
message: o.message
|
|
1016
|
-
}), n.dirty()) : o.kind === "duration" ?
|
|
1016
|
+
}), n.dirty()) : o.kind === "duration" ? _a.test(e.data) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
1017
1017
|
validation: "duration",
|
|
1018
1018
|
code: m.ZodIssueCode.invalid_string,
|
|
1019
1019
|
message: o.message
|
|
1020
|
-
}), n.dirty()) : o.kind === "ip" ?
|
|
1020
|
+
}), n.dirty()) : o.kind === "ip" ? ja(e.data, o.version) || (s = this._getOrReturnCtx(e, s), (0, u.addIssueToContext)(s, {
|
|
1021
1021
|
validation: "ip",
|
|
1022
1022
|
code: m.ZodIssueCode.invalid_string,
|
|
1023
1023
|
message: o.message
|
|
@@ -1270,7 +1270,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1270
1270
|
checks: [],
|
|
1271
1271
|
typeName: g.ZodString,
|
|
1272
1272
|
coerce: (e = t?.coerce) !== null && e !== void 0 ? e : !1,
|
|
1273
|
-
...
|
|
1273
|
+
...v(t)
|
|
1274
1274
|
});
|
|
1275
1275
|
};
|
|
1276
1276
|
function Za(t, e) {
|
|
@@ -1279,7 +1279,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1279
1279
|
return o % a / Math.pow(10, s);
|
|
1280
1280
|
}
|
|
1281
1281
|
i(Za, "floatSafeRemainder");
|
|
1282
|
-
var te = class t extends
|
|
1282
|
+
var te = class t extends _ {
|
|
1283
1283
|
static {
|
|
1284
1284
|
i(this, "ZodNumber");
|
|
1285
1285
|
}
|
|
@@ -1455,9 +1455,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1455
1455
|
checks: [],
|
|
1456
1456
|
typeName: g.ZodNumber,
|
|
1457
1457
|
coerce: t?.coerce || !1,
|
|
1458
|
-
...
|
|
1458
|
+
...v(t)
|
|
1459
1459
|
});
|
|
1460
|
-
var re = class t extends
|
|
1460
|
+
var re = class t extends _ {
|
|
1461
1461
|
static {
|
|
1462
1462
|
i(this, "ZodBigInt");
|
|
1463
1463
|
}
|
|
@@ -1596,10 +1596,10 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1596
1596
|
checks: [],
|
|
1597
1597
|
typeName: g.ZodBigInt,
|
|
1598
1598
|
coerce: (e = t?.coerce) !== null && e !== void 0 ? e : !1,
|
|
1599
|
-
...
|
|
1599
|
+
...v(t)
|
|
1600
1600
|
});
|
|
1601
1601
|
};
|
|
1602
|
-
var ne = class extends
|
|
1602
|
+
var ne = class extends _ {
|
|
1603
1603
|
static {
|
|
1604
1604
|
i(this, "ZodBoolean");
|
|
1605
1605
|
}
|
|
@@ -1619,9 +1619,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1619
1619
|
ne.create = (t) => new ne({
|
|
1620
1620
|
typeName: g.ZodBoolean,
|
|
1621
1621
|
coerce: t?.coerce || !1,
|
|
1622
|
-
...
|
|
1622
|
+
...v(t)
|
|
1623
1623
|
});
|
|
1624
|
-
var se = class t extends
|
|
1624
|
+
var se = class t extends _ {
|
|
1625
1625
|
static {
|
|
1626
1626
|
i(this, "ZodDate");
|
|
1627
1627
|
}
|
|
@@ -1700,9 +1700,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1700
1700
|
checks: [],
|
|
1701
1701
|
coerce: t?.coerce || !1,
|
|
1702
1702
|
typeName: g.ZodDate,
|
|
1703
|
-
...
|
|
1703
|
+
...v(t)
|
|
1704
1704
|
});
|
|
1705
|
-
var
|
|
1705
|
+
var ve = class extends _ {
|
|
1706
1706
|
static {
|
|
1707
1707
|
i(this, "ZodSymbol");
|
|
1708
1708
|
}
|
|
@@ -1718,12 +1718,12 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1718
1718
|
return (0, u.OK)(e.data);
|
|
1719
1719
|
}
|
|
1720
1720
|
};
|
|
1721
|
-
d.ZodSymbol =
|
|
1722
|
-
|
|
1721
|
+
d.ZodSymbol = ve;
|
|
1722
|
+
ve.create = (t) => new ve({
|
|
1723
1723
|
typeName: g.ZodSymbol,
|
|
1724
|
-
...
|
|
1724
|
+
...v(t)
|
|
1725
1725
|
});
|
|
1726
|
-
var oe = class extends
|
|
1726
|
+
var oe = class extends _ {
|
|
1727
1727
|
static {
|
|
1728
1728
|
i(this, "ZodUndefined");
|
|
1729
1729
|
}
|
|
@@ -1742,9 +1742,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1742
1742
|
d.ZodUndefined = oe;
|
|
1743
1743
|
oe.create = (t) => new oe({
|
|
1744
1744
|
typeName: g.ZodUndefined,
|
|
1745
|
-
...
|
|
1745
|
+
...v(t)
|
|
1746
1746
|
});
|
|
1747
|
-
var ie = class extends
|
|
1747
|
+
var ie = class extends _ {
|
|
1748
1748
|
static {
|
|
1749
1749
|
i(this, "ZodNull");
|
|
1750
1750
|
}
|
|
@@ -1763,9 +1763,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1763
1763
|
d.ZodNull = ie;
|
|
1764
1764
|
ie.create = (t) => new ie({
|
|
1765
1765
|
typeName: g.ZodNull,
|
|
1766
|
-
...
|
|
1766
|
+
...v(t)
|
|
1767
1767
|
});
|
|
1768
|
-
var H = class extends
|
|
1768
|
+
var H = class extends _ {
|
|
1769
1769
|
static {
|
|
1770
1770
|
i(this, "ZodAny");
|
|
1771
1771
|
}
|
|
@@ -1779,9 +1779,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1779
1779
|
d.ZodAny = H;
|
|
1780
1780
|
H.create = (t) => new H({
|
|
1781
1781
|
typeName: g.ZodAny,
|
|
1782
|
-
...
|
|
1782
|
+
...v(t)
|
|
1783
1783
|
});
|
|
1784
|
-
var
|
|
1784
|
+
var q = class extends _ {
|
|
1785
1785
|
static {
|
|
1786
1786
|
i(this, "ZodUnknown");
|
|
1787
1787
|
}
|
|
@@ -1792,12 +1792,12 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1792
1792
|
return (0, u.OK)(e.data);
|
|
1793
1793
|
}
|
|
1794
1794
|
};
|
|
1795
|
-
d.ZodUnknown =
|
|
1796
|
-
|
|
1795
|
+
d.ZodUnknown = q;
|
|
1796
|
+
q.create = (t) => new q({
|
|
1797
1797
|
typeName: g.ZodUnknown,
|
|
1798
|
-
...
|
|
1798
|
+
...v(t)
|
|
1799
1799
|
});
|
|
1800
|
-
var U = class extends
|
|
1800
|
+
var U = class extends _ {
|
|
1801
1801
|
static {
|
|
1802
1802
|
i(this, "ZodNever");
|
|
1803
1803
|
}
|
|
@@ -1813,9 +1813,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1813
1813
|
d.ZodNever = U;
|
|
1814
1814
|
U.create = (t) => new U({
|
|
1815
1815
|
typeName: g.ZodNever,
|
|
1816
|
-
...
|
|
1816
|
+
...v(t)
|
|
1817
1817
|
});
|
|
1818
|
-
var
|
|
1818
|
+
var _e = class extends _ {
|
|
1819
1819
|
static {
|
|
1820
1820
|
i(this, "ZodVoid");
|
|
1821
1821
|
}
|
|
@@ -1831,12 +1831,12 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1831
1831
|
return (0, u.OK)(e.data);
|
|
1832
1832
|
}
|
|
1833
1833
|
};
|
|
1834
|
-
d.ZodVoid =
|
|
1835
|
-
|
|
1834
|
+
d.ZodVoid = _e;
|
|
1835
|
+
_e.create = (t) => new _e({
|
|
1836
1836
|
typeName: g.ZodVoid,
|
|
1837
|
-
...
|
|
1837
|
+
...v(t)
|
|
1838
1838
|
});
|
|
1839
|
-
var G = class t extends
|
|
1839
|
+
var G = class t extends _ {
|
|
1840
1840
|
static {
|
|
1841
1841
|
i(this, "ZodArray");
|
|
1842
1842
|
}
|
|
@@ -1911,14 +1911,14 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1911
1911
|
maxLength: null,
|
|
1912
1912
|
exactLength: null,
|
|
1913
1913
|
typeName: g.ZodArray,
|
|
1914
|
-
...
|
|
1914
|
+
...v(e)
|
|
1915
1915
|
});
|
|
1916
|
-
function
|
|
1916
|
+
function be(t) {
|
|
1917
1917
|
if (t instanceof R) {
|
|
1918
1918
|
let e = {};
|
|
1919
1919
|
for (let r in t.shape) {
|
|
1920
1920
|
let n = t.shape[r];
|
|
1921
|
-
e[r] = M.create(
|
|
1921
|
+
e[r] = M.create(be(n));
|
|
1922
1922
|
}
|
|
1923
1923
|
return new R({
|
|
1924
1924
|
...t._def,
|
|
@@ -1926,12 +1926,12 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1926
1926
|
});
|
|
1927
1927
|
} else return t instanceof G ? new G({
|
|
1928
1928
|
...t._def,
|
|
1929
|
-
type:
|
|
1930
|
-
}) : t instanceof M ? M.create(
|
|
1929
|
+
type: be(t.element)
|
|
1930
|
+
}) : t instanceof M ? M.create(be(t.unwrap())) : t instanceof B ? B.create(be(t.unwrap())) : t instanceof F ? F.create(t.items.map((e) => be(
|
|
1931
1931
|
e))) : t;
|
|
1932
1932
|
}
|
|
1933
|
-
i(
|
|
1934
|
-
var R = class t extends
|
|
1933
|
+
i(be, "deepPartialify");
|
|
1934
|
+
var R = class t extends _ {
|
|
1935
1935
|
static {
|
|
1936
1936
|
i(this, "ZodObject");
|
|
1937
1937
|
}
|
|
@@ -1959,10 +1959,10 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1959
1959
|
a.includes(p) || c.push(p);
|
|
1960
1960
|
let l = [];
|
|
1961
1961
|
for (let p of a) {
|
|
1962
|
-
let f = o[p],
|
|
1962
|
+
let f = o[p], x = s.data[p];
|
|
1963
1963
|
l.push({
|
|
1964
1964
|
key: { status: "valid", value: p },
|
|
1965
|
-
value: f._parse(new D(s,
|
|
1965
|
+
value: f._parse(new D(s, x, s.path, p)),
|
|
1966
1966
|
alwaysSet: p in s.data
|
|
1967
1967
|
});
|
|
1968
1968
|
}
|
|
@@ -1984,11 +1984,11 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1984
1984
|
} else {
|
|
1985
1985
|
let p = this._def.catchall;
|
|
1986
1986
|
for (let f of c) {
|
|
1987
|
-
let
|
|
1987
|
+
let x = s.data[f];
|
|
1988
1988
|
l.push({
|
|
1989
1989
|
key: { status: "valid", value: f },
|
|
1990
1990
|
value: p._parse(
|
|
1991
|
-
new D(s,
|
|
1991
|
+
new D(s, x, s.path, f)
|
|
1992
1992
|
//, ctx.child(key), value, getParsedType(value)
|
|
1993
1993
|
),
|
|
1994
1994
|
alwaysSet: f in s.data
|
|
@@ -1998,9 +1998,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
1998
1998
|
return s.common.async ? Promise.resolve().then(async () => {
|
|
1999
1999
|
let p = [];
|
|
2000
2000
|
for (let f of l) {
|
|
2001
|
-
let
|
|
2001
|
+
let x = await f.key, k = await f.value;
|
|
2002
2002
|
p.push({
|
|
2003
|
-
key:
|
|
2003
|
+
key: x,
|
|
2004
2004
|
value: k,
|
|
2005
2005
|
alwaysSet: f.alwaysSet
|
|
2006
2006
|
});
|
|
@@ -2170,7 +2170,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2170
2170
|
* @deprecated
|
|
2171
2171
|
*/
|
|
2172
2172
|
deepPartial() {
|
|
2173
|
-
return
|
|
2173
|
+
return be(this);
|
|
2174
2174
|
}
|
|
2175
2175
|
partial(e) {
|
|
2176
2176
|
let r = {};
|
|
@@ -2208,23 +2208,23 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2208
2208
|
unknownKeys: "strip",
|
|
2209
2209
|
catchall: U.create(),
|
|
2210
2210
|
typeName: g.ZodObject,
|
|
2211
|
-
...
|
|
2211
|
+
...v(e)
|
|
2212
2212
|
});
|
|
2213
2213
|
R.strictCreate = (t, e) => new R({
|
|
2214
2214
|
shape: /* @__PURE__ */ i(() => t, "shape"),
|
|
2215
2215
|
unknownKeys: "strict",
|
|
2216
2216
|
catchall: U.create(),
|
|
2217
2217
|
typeName: g.ZodObject,
|
|
2218
|
-
...
|
|
2218
|
+
...v(e)
|
|
2219
2219
|
});
|
|
2220
2220
|
R.lazycreate = (t, e) => new R({
|
|
2221
2221
|
shape: t,
|
|
2222
2222
|
unknownKeys: "strip",
|
|
2223
2223
|
catchall: U.create(),
|
|
2224
2224
|
typeName: g.ZodObject,
|
|
2225
|
-
...
|
|
2225
|
+
...v(e)
|
|
2226
2226
|
});
|
|
2227
|
-
var ae = class extends
|
|
2227
|
+
var ae = class extends _ {
|
|
2228
2228
|
static {
|
|
2229
2229
|
i(this, "ZodUnion");
|
|
2230
2230
|
}
|
|
@@ -2298,12 +2298,12 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2298
2298
|
ae.create = (t, e) => new ae({
|
|
2299
2299
|
options: t,
|
|
2300
2300
|
typeName: g.ZodUnion,
|
|
2301
|
-
...
|
|
2301
|
+
...v(e)
|
|
2302
2302
|
});
|
|
2303
|
-
var
|
|
2304
|
-
le ? t.options : t instanceof pe ? h.util.objectValues(t.enum) : t instanceof fe ?
|
|
2305
|
-
ie ? [null] : t instanceof M ? [void 0, ...
|
|
2306
|
-
|
|
2303
|
+
var W = /* @__PURE__ */ i((t) => t instanceof de ? W(t.schema) : t instanceof Z ? W(t.innerType()) : t instanceof ue ? [t.value] : t instanceof
|
|
2304
|
+
le ? t.options : t instanceof pe ? h.util.objectValues(t.enum) : t instanceof fe ? W(t._def.innerType) : t instanceof oe ? [void 0] : t instanceof
|
|
2305
|
+
ie ? [null] : t instanceof M ? [void 0, ...W(t.unwrap())] : t instanceof B ? [null, ...W(t.unwrap())] : t instanceof Le || t instanceof he ?
|
|
2306
|
+
W(t.unwrap()) : t instanceof me ? W(t._def.innerType) : [], "getDiscriminator"), lt = class t extends _ {
|
|
2307
2307
|
static {
|
|
2308
2308
|
i(this, "ZodDiscriminatedUnion");
|
|
2309
2309
|
}
|
|
@@ -2350,7 +2350,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2350
2350
|
static create(e, r, n) {
|
|
2351
2351
|
let s = /* @__PURE__ */ new Map();
|
|
2352
2352
|
for (let o of r) {
|
|
2353
|
-
let a =
|
|
2353
|
+
let a = W(o.shape[e]);
|
|
2354
2354
|
if (!a.length)
|
|
2355
2355
|
throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);
|
|
2356
2356
|
for (let c of a) {
|
|
@@ -2364,7 +2364,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2364
2364
|
discriminator: e,
|
|
2365
2365
|
options: r,
|
|
2366
2366
|
optionsMap: s,
|
|
2367
|
-
...
|
|
2367
|
+
...v(n)
|
|
2368
2368
|
});
|
|
2369
2369
|
}
|
|
2370
2370
|
};
|
|
@@ -2396,7 +2396,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2396
2396
|
} else return r === h.ZodParsedType.date && n === h.ZodParsedType.date && +t == +e ? { valid: !0, data: t } : { valid: !1 };
|
|
2397
2397
|
}
|
|
2398
2398
|
i(or, "mergeValues");
|
|
2399
|
-
var ce = class extends
|
|
2399
|
+
var ce = class extends _ {
|
|
2400
2400
|
static {
|
|
2401
2401
|
i(this, "ZodIntersection");
|
|
2402
2402
|
}
|
|
@@ -2437,9 +2437,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2437
2437
|
left: t,
|
|
2438
2438
|
right: e,
|
|
2439
2439
|
typeName: g.ZodIntersection,
|
|
2440
|
-
...
|
|
2440
|
+
...v(r)
|
|
2441
2441
|
});
|
|
2442
|
-
var F = class t extends
|
|
2442
|
+
var F = class t extends _ {
|
|
2443
2443
|
static {
|
|
2444
2444
|
i(this, "ZodTuple");
|
|
2445
2445
|
}
|
|
@@ -2490,10 +2490,10 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2490
2490
|
items: t,
|
|
2491
2491
|
typeName: g.ZodTuple,
|
|
2492
2492
|
rest: null,
|
|
2493
|
-
...
|
|
2493
|
+
...v(e)
|
|
2494
2494
|
});
|
|
2495
2495
|
};
|
|
2496
|
-
var pt = class t extends
|
|
2496
|
+
var pt = class t extends _ {
|
|
2497
2497
|
static {
|
|
2498
2498
|
i(this, "ZodRecord");
|
|
2499
2499
|
}
|
|
@@ -2524,21 +2524,21 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2524
2524
|
return this._def.valueType;
|
|
2525
2525
|
}
|
|
2526
2526
|
static create(e, r, n) {
|
|
2527
|
-
return r instanceof
|
|
2527
|
+
return r instanceof _ ? new t({
|
|
2528
2528
|
keyType: e,
|
|
2529
2529
|
valueType: r,
|
|
2530
2530
|
typeName: g.ZodRecord,
|
|
2531
|
-
...
|
|
2531
|
+
...v(n)
|
|
2532
2532
|
}) : new t({
|
|
2533
2533
|
keyType: J.create(),
|
|
2534
2534
|
valueType: e,
|
|
2535
2535
|
typeName: g.ZodRecord,
|
|
2536
|
-
...
|
|
2536
|
+
...v(r)
|
|
2537
2537
|
});
|
|
2538
2538
|
}
|
|
2539
2539
|
};
|
|
2540
2540
|
d.ZodRecord = pt;
|
|
2541
|
-
var
|
|
2541
|
+
var we = class extends _ {
|
|
2542
2542
|
static {
|
|
2543
2543
|
i(this, "ZodMap");
|
|
2544
2544
|
}
|
|
@@ -2583,14 +2583,14 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2583
2583
|
}
|
|
2584
2584
|
}
|
|
2585
2585
|
};
|
|
2586
|
-
d.ZodMap =
|
|
2587
|
-
|
|
2586
|
+
d.ZodMap = we;
|
|
2587
|
+
we.create = (t, e, r) => new we({
|
|
2588
2588
|
valueType: e,
|
|
2589
2589
|
keyType: t,
|
|
2590
2590
|
typeName: g.ZodMap,
|
|
2591
|
-
...
|
|
2591
|
+
...v(r)
|
|
2592
2592
|
});
|
|
2593
|
-
var ke = class t extends
|
|
2593
|
+
var ke = class t extends _ {
|
|
2594
2594
|
static {
|
|
2595
2595
|
i(this, "ZodSet");
|
|
2596
2596
|
}
|
|
@@ -2657,9 +2657,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2657
2657
|
minSize: null,
|
|
2658
2658
|
maxSize: null,
|
|
2659
2659
|
typeName: g.ZodSet,
|
|
2660
|
-
...
|
|
2660
|
+
...v(e)
|
|
2661
2661
|
});
|
|
2662
|
-
var ft = class t extends
|
|
2662
|
+
var ft = class t extends _ {
|
|
2663
2663
|
static {
|
|
2664
2664
|
i(this, "ZodFunction");
|
|
2665
2665
|
}
|
|
@@ -2712,11 +2712,11 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2712
2712
|
if (this._def.returns instanceof Y) {
|
|
2713
2713
|
let c = this;
|
|
2714
2714
|
return (0, u.OK)(async function(...l) {
|
|
2715
|
-
let p = new m.ZodError([]), f = await c._def.args.parseAsync(l, o).catch((
|
|
2716
|
-
throw p.addIssue(n(l,
|
|
2717
|
-
}),
|
|
2718
|
-
return await c._def.returns._def.type.parseAsync(
|
|
2719
|
-
throw p.addIssue(s(
|
|
2715
|
+
let p = new m.ZodError([]), f = await c._def.args.parseAsync(l, o).catch((w) => {
|
|
2716
|
+
throw p.addIssue(n(l, w)), p;
|
|
2717
|
+
}), x = await Reflect.apply(a, this, f);
|
|
2718
|
+
return await c._def.returns._def.type.parseAsync(x, o).catch((w) => {
|
|
2719
|
+
throw p.addIssue(s(x, w)), p;
|
|
2720
2720
|
});
|
|
2721
2721
|
});
|
|
2722
2722
|
} else {
|
|
@@ -2725,10 +2725,10 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2725
2725
|
let p = c._def.args.safeParse(l, o);
|
|
2726
2726
|
if (!p.success)
|
|
2727
2727
|
throw new m.ZodError([n(l, p.error)]);
|
|
2728
|
-
let f = Reflect.apply(a, this, p.data),
|
|
2729
|
-
if (!
|
|
2730
|
-
throw new m.ZodError([s(f,
|
|
2731
|
-
return
|
|
2728
|
+
let f = Reflect.apply(a, this, p.data), x = c._def.returns.safeParse(f, o);
|
|
2729
|
+
if (!x.success)
|
|
2730
|
+
throw new m.ZodError([s(f, x.error)]);
|
|
2731
|
+
return x.data;
|
|
2732
2732
|
});
|
|
2733
2733
|
}
|
|
2734
2734
|
}
|
|
@@ -2741,7 +2741,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2741
2741
|
args(...e) {
|
|
2742
2742
|
return new t({
|
|
2743
2743
|
...this._def,
|
|
2744
|
-
args: F.create(e).rest(
|
|
2744
|
+
args: F.create(e).rest(q.create())
|
|
2745
2745
|
});
|
|
2746
2746
|
}
|
|
2747
2747
|
returns(e) {
|
|
@@ -2758,15 +2758,15 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2758
2758
|
}
|
|
2759
2759
|
static create(e, r, n) {
|
|
2760
2760
|
return new t({
|
|
2761
|
-
args: e || F.create([]).rest(
|
|
2762
|
-
returns: r ||
|
|
2761
|
+
args: e || F.create([]).rest(q.create()),
|
|
2762
|
+
returns: r || q.create(),
|
|
2763
2763
|
typeName: g.ZodFunction,
|
|
2764
|
-
...
|
|
2764
|
+
...v(n)
|
|
2765
2765
|
});
|
|
2766
2766
|
}
|
|
2767
2767
|
};
|
|
2768
2768
|
d.ZodFunction = ft;
|
|
2769
|
-
var de = class extends
|
|
2769
|
+
var de = class extends _ {
|
|
2770
2770
|
static {
|
|
2771
2771
|
i(this, "ZodLazy");
|
|
2772
2772
|
}
|
|
@@ -2782,9 +2782,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2782
2782
|
de.create = (t, e) => new de({
|
|
2783
2783
|
getter: t,
|
|
2784
2784
|
typeName: g.ZodLazy,
|
|
2785
|
-
...
|
|
2785
|
+
...v(e)
|
|
2786
2786
|
});
|
|
2787
|
-
var ue = class extends
|
|
2787
|
+
var ue = class extends _ {
|
|
2788
2788
|
static {
|
|
2789
2789
|
i(this, "ZodLiteral");
|
|
2790
2790
|
}
|
|
@@ -2807,17 +2807,17 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2807
2807
|
ue.create = (t, e) => new ue({
|
|
2808
2808
|
value: t,
|
|
2809
2809
|
typeName: g.ZodLiteral,
|
|
2810
|
-
...
|
|
2810
|
+
...v(e)
|
|
2811
2811
|
});
|
|
2812
2812
|
function Un(t, e) {
|
|
2813
2813
|
return new le({
|
|
2814
2814
|
values: t,
|
|
2815
2815
|
typeName: g.ZodEnum,
|
|
2816
|
-
...
|
|
2816
|
+
...v(e)
|
|
2817
2817
|
});
|
|
2818
2818
|
}
|
|
2819
2819
|
i(Un, "createZodEnum");
|
|
2820
|
-
var le = class t extends
|
|
2820
|
+
var le = class t extends _ {
|
|
2821
2821
|
static {
|
|
2822
2822
|
i(this, "ZodEnum");
|
|
2823
2823
|
}
|
|
@@ -2880,7 +2880,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2880
2880
|
d.ZodEnum = le;
|
|
2881
2881
|
Me = /* @__PURE__ */ new WeakMap();
|
|
2882
2882
|
le.create = Un;
|
|
2883
|
-
var pe = class extends
|
|
2883
|
+
var pe = class extends _ {
|
|
2884
2884
|
static {
|
|
2885
2885
|
i(this, "ZodNativeEnum");
|
|
2886
2886
|
}
|
|
@@ -2916,9 +2916,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2916
2916
|
pe.create = (t, e) => new pe({
|
|
2917
2917
|
values: t,
|
|
2918
2918
|
typeName: g.ZodNativeEnum,
|
|
2919
|
-
...
|
|
2919
|
+
...v(e)
|
|
2920
2920
|
});
|
|
2921
|
-
var Y = class extends
|
|
2921
|
+
var Y = class extends _ {
|
|
2922
2922
|
static {
|
|
2923
2923
|
i(this, "ZodPromise");
|
|
2924
2924
|
}
|
|
@@ -2944,9 +2944,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
2944
2944
|
Y.create = (t, e) => new Y({
|
|
2945
2945
|
type: t,
|
|
2946
2946
|
typeName: g.ZodPromise,
|
|
2947
|
-
...
|
|
2947
|
+
...v(e)
|
|
2948
2948
|
});
|
|
2949
|
-
var Z = class extends
|
|
2949
|
+
var Z = class extends _ {
|
|
2950
2950
|
static {
|
|
2951
2951
|
i(this, "ZodEffects");
|
|
2952
2952
|
}
|
|
@@ -3034,15 +3034,15 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3034
3034
|
schema: t,
|
|
3035
3035
|
typeName: g.ZodEffects,
|
|
3036
3036
|
effect: e,
|
|
3037
|
-
...
|
|
3037
|
+
...v(r)
|
|
3038
3038
|
});
|
|
3039
3039
|
Z.createWithPreprocess = (t, e, r) => new Z({
|
|
3040
3040
|
schema: e,
|
|
3041
3041
|
effect: { type: "preprocess", transform: t },
|
|
3042
3042
|
typeName: g.ZodEffects,
|
|
3043
|
-
...
|
|
3043
|
+
...v(r)
|
|
3044
3044
|
});
|
|
3045
|
-
var M = class extends
|
|
3045
|
+
var M = class extends _ {
|
|
3046
3046
|
static {
|
|
3047
3047
|
i(this, "ZodOptional");
|
|
3048
3048
|
}
|
|
@@ -3057,9 +3057,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3057
3057
|
M.create = (t, e) => new M({
|
|
3058
3058
|
innerType: t,
|
|
3059
3059
|
typeName: g.ZodOptional,
|
|
3060
|
-
...
|
|
3060
|
+
...v(e)
|
|
3061
3061
|
});
|
|
3062
|
-
var B = class extends
|
|
3062
|
+
var B = class extends _ {
|
|
3063
3063
|
static {
|
|
3064
3064
|
i(this, "ZodNullable");
|
|
3065
3065
|
}
|
|
@@ -3074,9 +3074,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3074
3074
|
B.create = (t, e) => new B({
|
|
3075
3075
|
innerType: t,
|
|
3076
3076
|
typeName: g.ZodNullable,
|
|
3077
|
-
...
|
|
3077
|
+
...v(e)
|
|
3078
3078
|
});
|
|
3079
|
-
var fe = class extends
|
|
3079
|
+
var fe = class extends _ {
|
|
3080
3080
|
static {
|
|
3081
3081
|
i(this, "ZodDefault");
|
|
3082
3082
|
}
|
|
@@ -3097,9 +3097,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3097
3097
|
innerType: t,
|
|
3098
3098
|
typeName: g.ZodDefault,
|
|
3099
3099
|
defaultValue: typeof e.default == "function" ? e.default : () => e.default,
|
|
3100
|
-
...
|
|
3100
|
+
...v(e)
|
|
3101
3101
|
});
|
|
3102
|
-
var me = class extends
|
|
3102
|
+
var me = class extends _ {
|
|
3103
3103
|
static {
|
|
3104
3104
|
i(this, "ZodCatch");
|
|
3105
3105
|
}
|
|
@@ -3144,9 +3144,9 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3144
3144
|
innerType: t,
|
|
3145
3145
|
typeName: g.ZodCatch,
|
|
3146
3146
|
catchValue: typeof e.catch == "function" ? e.catch : () => e.catch,
|
|
3147
|
-
...
|
|
3147
|
+
...v(e)
|
|
3148
3148
|
});
|
|
3149
|
-
var Te = class extends
|
|
3149
|
+
var Te = class extends _ {
|
|
3150
3150
|
static {
|
|
3151
3151
|
i(this, "ZodNaN");
|
|
3152
3152
|
}
|
|
@@ -3165,10 +3165,10 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3165
3165
|
d.ZodNaN = Te;
|
|
3166
3166
|
Te.create = (t) => new Te({
|
|
3167
3167
|
typeName: g.ZodNaN,
|
|
3168
|
-
...
|
|
3168
|
+
...v(t)
|
|
3169
3169
|
});
|
|
3170
3170
|
d.BRAND = Symbol("zod_brand");
|
|
3171
|
-
var Le = class extends
|
|
3171
|
+
var Le = class extends _ {
|
|
3172
3172
|
static {
|
|
3173
3173
|
i(this, "ZodBranded");
|
|
3174
3174
|
}
|
|
@@ -3185,7 +3185,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3185
3185
|
}
|
|
3186
3186
|
};
|
|
3187
3187
|
d.ZodBranded = Le;
|
|
3188
|
-
var Ue = class t extends
|
|
3188
|
+
var Ue = class t extends _ {
|
|
3189
3189
|
static {
|
|
3190
3190
|
i(this, "ZodPipeline");
|
|
3191
3191
|
}
|
|
@@ -3230,7 +3230,7 @@ onent})+$", sr, Ta = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.
|
|
|
3230
3230
|
}
|
|
3231
3231
|
};
|
|
3232
3232
|
d.ZodPipeline = Ue;
|
|
3233
|
-
var he = class extends
|
|
3233
|
+
var he = class extends _ {
|
|
3234
3234
|
static {
|
|
3235
3235
|
i(this, "ZodReadonly");
|
|
3236
3236
|
}
|
|
@@ -3247,7 +3247,7 @@ eze");
|
|
|
3247
3247
|
he.create = (t, e) => new he({
|
|
3248
3248
|
innerType: t,
|
|
3249
3249
|
typeName: g.ZodReadonly,
|
|
3250
|
-
...
|
|
3250
|
+
...v(e)
|
|
3251
3251
|
});
|
|
3252
3252
|
function Nn(t, e) {
|
|
3253
3253
|
let r = typeof t == "function" ? t(e) : typeof t == "string" ? { message: t } : t;
|
|
@@ -3262,8 +3262,8 @@ eze");
|
|
|
3262
3262
|
return c.then((l) => {
|
|
3263
3263
|
var p, f;
|
|
3264
3264
|
if (!l) {
|
|
3265
|
-
let
|
|
3266
|
-
s.addIssue({ code: "custom", ...
|
|
3265
|
+
let x = Nn(e, n), k = (f = (p = x.fatal) !== null && p !== void 0 ? p : r) !== null && f !== void 0 ? f : !0;
|
|
3266
|
+
s.addIssue({ code: "custom", ...x, fatal: k });
|
|
3267
3267
|
}
|
|
3268
3268
|
});
|
|
3269
3269
|
if (!c) {
|
|
@@ -3304,7 +3304,7 @@ adonly";
|
|
|
3304
3304
|
d.boolean = Bn;
|
|
3305
3305
|
var Ua = se.create;
|
|
3306
3306
|
d.date = Ua;
|
|
3307
|
-
var $a =
|
|
3307
|
+
var $a = ve.create;
|
|
3308
3308
|
d.symbol = $a;
|
|
3309
3309
|
var Va = oe.create;
|
|
3310
3310
|
d.undefined = Va;
|
|
@@ -3312,11 +3312,11 @@ adonly";
|
|
|
3312
3312
|
d.null = Fa;
|
|
3313
3313
|
var Ba = H.create;
|
|
3314
3314
|
d.any = Ba;
|
|
3315
|
-
var
|
|
3316
|
-
d.unknown =
|
|
3317
|
-
var
|
|
3318
|
-
d.never =
|
|
3319
|
-
var Ga =
|
|
3315
|
+
var Wa = q.create;
|
|
3316
|
+
d.unknown = Wa;
|
|
3317
|
+
var qa = U.create;
|
|
3318
|
+
d.never = qa;
|
|
3319
|
+
var Ga = _e.create;
|
|
3320
3320
|
d.void = Ga;
|
|
3321
3321
|
var za = G.create;
|
|
3322
3322
|
d.array = za;
|
|
@@ -3334,7 +3334,7 @@ adonly";
|
|
|
3334
3334
|
d.tuple = Qa;
|
|
3335
3335
|
var ec = pt.create;
|
|
3336
3336
|
d.record = ec;
|
|
3337
|
-
var tc =
|
|
3337
|
+
var tc = we.create;
|
|
3338
3338
|
d.map = tc;
|
|
3339
3339
|
var rc = ke.create;
|
|
3340
3340
|
d.set = rc;
|
|
@@ -3350,9 +3350,9 @@ adonly";
|
|
|
3350
3350
|
d.nativeEnum = ac;
|
|
3351
3351
|
var cc = Y.create;
|
|
3352
3352
|
d.promise = cc;
|
|
3353
|
-
var
|
|
3354
|
-
d.effect =
|
|
3355
|
-
d.transformer =
|
|
3353
|
+
var Wn = Z.create;
|
|
3354
|
+
d.effect = Wn;
|
|
3355
|
+
d.transformer = Wn;
|
|
3356
3356
|
var dc = M.create;
|
|
3357
3357
|
d.optional = dc;
|
|
3358
3358
|
var uc = B.create;
|
|
@@ -3397,9 +3397,9 @@ var ir = I((L) => {
|
|
|
3397
3397
|
Object.defineProperty(L, "__esModule", { value: !0 });
|
|
3398
3398
|
Ie(at(), L);
|
|
3399
3399
|
Ie(nr(), L);
|
|
3400
|
-
Ie(
|
|
3400
|
+
Ie(An(), L);
|
|
3401
3401
|
Ie(Ne(), L);
|
|
3402
|
-
Ie(
|
|
3402
|
+
Ie(qn(), L);
|
|
3403
3403
|
Ie(it(), L);
|
|
3404
3404
|
});
|
|
3405
3405
|
|
|
@@ -3418,19 +3418,19 @@ var Kn = I((N) => {
|
|
|
3418
3418
|
Object.defineProperty(t, "default", { enumerable: !0, value: e });
|
|
3419
3419
|
} : function(t, e) {
|
|
3420
3420
|
t.default = e;
|
|
3421
|
-
}),
|
|
3421
|
+
}), xc = N && N.__importStar || function(t) {
|
|
3422
3422
|
if (t && t.__esModule) return t;
|
|
3423
3423
|
var e = {};
|
|
3424
3424
|
if (t != null) for (var r in t) r !== "default" && Object.prototype.hasOwnProperty.call(t, r) && Gn(e, t, r);
|
|
3425
3425
|
return gc(e, t), e;
|
|
3426
|
-
},
|
|
3426
|
+
}, bc = N && N.__exportStar || function(t, e) {
|
|
3427
3427
|
for (var r in t) r !== "default" && !Object.prototype.hasOwnProperty.call(e, r) && Gn(e, t, r);
|
|
3428
3428
|
};
|
|
3429
3429
|
Object.defineProperty(N, "__esModule", { value: !0 });
|
|
3430
3430
|
N.z = void 0;
|
|
3431
|
-
var zn =
|
|
3431
|
+
var zn = xc(ir());
|
|
3432
3432
|
N.z = zn;
|
|
3433
|
-
|
|
3433
|
+
bc(ir(), N);
|
|
3434
3434
|
N.default = zn;
|
|
3435
3435
|
});
|
|
3436
3436
|
|
|
@@ -3447,8 +3447,8 @@ var Hn = I(($e) => {
|
|
|
3447
3447
|
var s = n.reduce(function(c, l) {
|
|
3448
3448
|
var p = l.match(/\n([\t ]+|(?!\s).)/g);
|
|
3449
3449
|
return p ? c.concat(p.map(function(f) {
|
|
3450
|
-
var
|
|
3451
|
-
return (k = (
|
|
3450
|
+
var x, k;
|
|
3451
|
+
return (k = (x = f.match(/[\t ]/g)) === null || x === void 0 ? void 0 : x.length) !== null && k !== void 0 ? k : 0;
|
|
3452
3452
|
})) : c;
|
|
3453
3453
|
}, []);
|
|
3454
3454
|
if (s.length) {
|
|
@@ -3462,13 +3462,13 @@ var Hn = I(($e) => {
|
|
|
3462
3462
|
n[0] = n[0].replace(/^\r?\n/, "");
|
|
3463
3463
|
var a = n[0];
|
|
3464
3464
|
return e.forEach(function(c, l) {
|
|
3465
|
-
var p = a.match(/(?:^|\n)( *)$/), f = p ? p[1] : "",
|
|
3465
|
+
var p = a.match(/(?:^|\n)( *)$/), f = p ? p[1] : "", x = c;
|
|
3466
3466
|
typeof c == "string" && c.includes(`
|
|
3467
|
-
`) && (
|
|
3468
|
-
`).map(function(k,
|
|
3469
|
-
return
|
|
3467
|
+
`) && (x = String(c).split(`
|
|
3468
|
+
`).map(function(k, w) {
|
|
3469
|
+
return w === 0 ? k : "" + f + k;
|
|
3470
3470
|
}).join(`
|
|
3471
|
-
`)), a +=
|
|
3471
|
+
`)), a += x + n[l + 1];
|
|
3472
3472
|
}), a;
|
|
3473
3473
|
}
|
|
3474
3474
|
i(Jn, "dedent");
|
|
@@ -3480,7 +3480,7 @@ var Hn = I(($e) => {
|
|
|
3480
3480
|
var ss = I((Up, ns) => {
|
|
3481
3481
|
ns.exports = rs;
|
|
3482
3482
|
rs.sync = Ec;
|
|
3483
|
-
var es =
|
|
3483
|
+
var es = j("fs");
|
|
3484
3484
|
function Sc(t, e) {
|
|
3485
3485
|
var r = e.pathExt !== void 0 ? e.pathExt : process.env.PATHEXT;
|
|
3486
3486
|
if (!r || (r = r.split(";"), r.indexOf("") !== -1))
|
|
@@ -3513,7 +3513,7 @@ var ss = I((Up, ns) => {
|
|
|
3513
3513
|
var ds = I((Vp, cs) => {
|
|
3514
3514
|
cs.exports = is;
|
|
3515
3515
|
is.sync = Cc;
|
|
3516
|
-
var os =
|
|
3516
|
+
var os = j("fs");
|
|
3517
3517
|
function is(t, e, r) {
|
|
3518
3518
|
os.stat(t, function(n, s) {
|
|
3519
3519
|
r(n, n ? !1 : as(s, e));
|
|
@@ -3530,19 +3530,19 @@ var ds = I((Vp, cs) => {
|
|
|
3530
3530
|
i(as, "checkStat");
|
|
3531
3531
|
function Pc(t, e) {
|
|
3532
3532
|
var r = t.mode, n = t.uid, s = t.gid, o = e.uid !== void 0 ? e.uid : process.getuid && process.getuid(), a = e.gid !== void 0 ? e.gid : process.
|
|
3533
|
-
getgid && process.getgid(), c = parseInt("100", 8), l = parseInt("010", 8), p = parseInt("001", 8), f = c | l,
|
|
3533
|
+
getgid && process.getgid(), c = parseInt("100", 8), l = parseInt("010", 8), p = parseInt("001", 8), f = c | l, x = r & p || r & l && s ===
|
|
3534
3534
|
a || r & c && n === o || r & f && o === 0;
|
|
3535
|
-
return
|
|
3535
|
+
return x;
|
|
3536
3536
|
}
|
|
3537
3537
|
i(Pc, "checkMode");
|
|
3538
3538
|
});
|
|
3539
3539
|
|
|
3540
3540
|
// ../node_modules/isexe/index.js
|
|
3541
|
-
var ls = I((
|
|
3542
|
-
var Bp =
|
|
3541
|
+
var ls = I((Wp, us) => {
|
|
3542
|
+
var Bp = j("fs"), gt;
|
|
3543
3543
|
process.platform === "win32" || global.TESTING_WINDOWS ? gt = ss() : gt = ds();
|
|
3544
3544
|
us.exports = cr;
|
|
3545
|
-
cr.sync =
|
|
3545
|
+
cr.sync = Ac;
|
|
3546
3546
|
function cr(t, e, r) {
|
|
3547
3547
|
if (typeof e == "function" && (r = e, e = {}), !r) {
|
|
3548
3548
|
if (typeof Promise != "function")
|
|
@@ -3558,7 +3558,7 @@ var ls = I((qp, us) => {
|
|
|
3558
3558
|
});
|
|
3559
3559
|
}
|
|
3560
3560
|
i(cr, "isexe");
|
|
3561
|
-
function
|
|
3561
|
+
function Ac(t, e) {
|
|
3562
3562
|
try {
|
|
3563
3563
|
return gt.sync(t, e || {});
|
|
3564
3564
|
} catch (r) {
|
|
@@ -3567,15 +3567,15 @@ var ls = I((qp, us) => {
|
|
|
3567
3567
|
throw r;
|
|
3568
3568
|
}
|
|
3569
3569
|
}
|
|
3570
|
-
i(
|
|
3570
|
+
i(Ac, "sync");
|
|
3571
3571
|
});
|
|
3572
3572
|
|
|
3573
3573
|
// ../node_modules/which/which.js
|
|
3574
|
-
var
|
|
3575
|
-
var Ce = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys", ps =
|
|
3574
|
+
var xs = I((Gp, gs) => {
|
|
3575
|
+
var Ce = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys", ps = j("path"), Oc = Ce ? ";" :
|
|
3576
3576
|
":", fs = ls(), ms = /* @__PURE__ */ i((t) => Object.assign(new Error(`not found: ${t}`), { code: "ENOENT" }), "getNotFoundError"), hs = /* @__PURE__ */ i(
|
|
3577
3577
|
(t, e) => {
|
|
3578
|
-
let r = e.colon ||
|
|
3578
|
+
let r = e.colon || Oc, n = t.match(/\//) || Ce && t.match(/\\/) ? [""] : [
|
|
3579
3579
|
// windows always checks the cwd first
|
|
3580
3580
|
...Ce ? [process.cwd()] : [],
|
|
3581
3581
|
...(e.path || process.env.PATH || /* istanbul ignore next: very unusual */
|
|
@@ -3588,32 +3588,32 @@ var vs = I((Gp, gs) => {
|
|
|
3588
3588
|
};
|
|
3589
3589
|
}, "getPathInfo"), ys = /* @__PURE__ */ i((t, e, r) => {
|
|
3590
3590
|
typeof e == "function" && (r = e, e = {}), e || (e = {});
|
|
3591
|
-
let { pathEnv: n, pathExt: s, pathExtExe: o } = hs(t, e), a = [], c = /* @__PURE__ */ i((p) => new Promise((f,
|
|
3591
|
+
let { pathEnv: n, pathExt: s, pathExtExe: o } = hs(t, e), a = [], c = /* @__PURE__ */ i((p) => new Promise((f, x) => {
|
|
3592
3592
|
if (p === n.length)
|
|
3593
|
-
return e.all && a.length ? f(a) :
|
|
3594
|
-
let k = n[p],
|
|
3593
|
+
return e.all && a.length ? f(a) : x(ms(t));
|
|
3594
|
+
let k = n[p], w = /^".*"$/.test(k) ? k.slice(1, -1) : k, C = ps.join(w, t), S = !w && /^\.[\\\/]/.test(t) ? t.slice(0, 2) + C : C;
|
|
3595
3595
|
f(l(S, p, 0));
|
|
3596
|
-
}), "step"), l = /* @__PURE__ */ i((p, f,
|
|
3597
|
-
if (
|
|
3596
|
+
}), "step"), l = /* @__PURE__ */ i((p, f, x) => new Promise((k, w) => {
|
|
3597
|
+
if (x === s.length)
|
|
3598
3598
|
return k(c(f + 1));
|
|
3599
|
-
let C = s[
|
|
3599
|
+
let C = s[x];
|
|
3600
3600
|
fs(p + C, { pathExt: o }, (S, P) => {
|
|
3601
3601
|
if (!S && P)
|
|
3602
3602
|
if (e.all)
|
|
3603
3603
|
a.push(p + C);
|
|
3604
3604
|
else
|
|
3605
3605
|
return k(p + C);
|
|
3606
|
-
return k(l(p, f,
|
|
3606
|
+
return k(l(p, f, x + 1));
|
|
3607
3607
|
});
|
|
3608
3608
|
}), "subStep");
|
|
3609
3609
|
return r ? c(0).then((p) => r(null, p), r) : c(0);
|
|
3610
|
-
}, "which"),
|
|
3610
|
+
}, "which"), jc = /* @__PURE__ */ i((t, e) => {
|
|
3611
3611
|
e = e || {};
|
|
3612
3612
|
let { pathEnv: r, pathExt: n, pathExtExe: s } = hs(t, e), o = [];
|
|
3613
3613
|
for (let a = 0; a < r.length; a++) {
|
|
3614
3614
|
let c = r[a], l = /^".*"$/.test(c) ? c.slice(1, -1) : c, p = ps.join(l, t), f = !l && /^\.[\\\/]/.test(t) ? t.slice(0, 2) + p : p;
|
|
3615
|
-
for (let
|
|
3616
|
-
let k = f + n[
|
|
3615
|
+
for (let x = 0; x < n.length; x++) {
|
|
3616
|
+
let k = f + n[x];
|
|
3617
3617
|
try {
|
|
3618
3618
|
if (fs.sync(k, { pathExt: s }))
|
|
3619
3619
|
if (e.all)
|
|
@@ -3631,25 +3631,25 @@ var vs = I((Gp, gs) => {
|
|
|
3631
3631
|
throw ms(t);
|
|
3632
3632
|
}, "whichSync");
|
|
3633
3633
|
gs.exports = ys;
|
|
3634
|
-
ys.sync =
|
|
3634
|
+
ys.sync = jc;
|
|
3635
3635
|
});
|
|
3636
3636
|
|
|
3637
3637
|
// ../node_modules/path-key/index.js
|
|
3638
|
-
var
|
|
3638
|
+
var vs = I((Kp, dr) => {
|
|
3639
3639
|
"use strict";
|
|
3640
|
-
var
|
|
3640
|
+
var bs = /* @__PURE__ */ i((t = {}) => {
|
|
3641
3641
|
let e = t.env || process.env;
|
|
3642
3642
|
return (t.platform || process.platform) !== "win32" ? "PATH" : Object.keys(e).reverse().find((n) => n.toUpperCase() === "PATH") || "Path";
|
|
3643
3643
|
}, "pathKey");
|
|
3644
|
-
dr.exports =
|
|
3645
|
-
dr.exports.default =
|
|
3644
|
+
dr.exports = bs;
|
|
3645
|
+
dr.exports.default = bs;
|
|
3646
3646
|
});
|
|
3647
3647
|
|
|
3648
3648
|
// ../node_modules/cross-spawn/lib/util/resolveCommand.js
|
|
3649
3649
|
var Ts = I((Hp, ks) => {
|
|
3650
3650
|
"use strict";
|
|
3651
|
-
var
|
|
3652
|
-
function
|
|
3651
|
+
var _s = j("path"), Rc = xs(), Nc = vs();
|
|
3652
|
+
function ws(t, e) {
|
|
3653
3653
|
let r = t.options.env || process.env, n = process.cwd(), s = t.options.cwd != null, o = s && process.chdir !== void 0 && !process.chdir.
|
|
3654
3654
|
disabled;
|
|
3655
3655
|
if (o)
|
|
@@ -3661,17 +3661,17 @@ var Ts = I((Hp, ks) => {
|
|
|
3661
3661
|
try {
|
|
3662
3662
|
a = Rc.sync(t.command, {
|
|
3663
3663
|
path: r[Nc({ env: r })],
|
|
3664
|
-
pathExt: e ?
|
|
3664
|
+
pathExt: e ? _s.delimiter : void 0
|
|
3665
3665
|
});
|
|
3666
3666
|
} catch {
|
|
3667
3667
|
} finally {
|
|
3668
3668
|
o && process.chdir(n);
|
|
3669
3669
|
}
|
|
3670
|
-
return a && (a =
|
|
3670
|
+
return a && (a = _s.resolve(s ? t.options.cwd : "", a)), a;
|
|
3671
3671
|
}
|
|
3672
|
-
i(
|
|
3672
|
+
i(ws, "resolveCommandAttempt");
|
|
3673
3673
|
function Zc(t) {
|
|
3674
|
-
return
|
|
3674
|
+
return ws(t) || ws(t, !0);
|
|
3675
3675
|
}
|
|
3676
3676
|
i(Zc, "resolveCommand");
|
|
3677
3677
|
ks.exports = Zc;
|
|
@@ -3714,9 +3714,9 @@ var Ps = I((tf, Cs) => {
|
|
|
3714
3714
|
});
|
|
3715
3715
|
|
|
3716
3716
|
// ../node_modules/cross-spawn/lib/util/readShebang.js
|
|
3717
|
-
var
|
|
3717
|
+
var Os = I((rf, As) => {
|
|
3718
3718
|
"use strict";
|
|
3719
|
-
var pr =
|
|
3719
|
+
var pr = j("fs"), Uc = Ps();
|
|
3720
3720
|
function $c(t) {
|
|
3721
3721
|
let r = Buffer.alloc(150), n;
|
|
3722
3722
|
try {
|
|
@@ -3726,25 +3726,25 @@ var As = I((rf, js) => {
|
|
|
3726
3726
|
return Uc(r.toString());
|
|
3727
3727
|
}
|
|
3728
3728
|
i($c, "readShebang");
|
|
3729
|
-
|
|
3729
|
+
As.exports = $c;
|
|
3730
3730
|
});
|
|
3731
3731
|
|
|
3732
3732
|
// ../node_modules/cross-spawn/lib/parse.js
|
|
3733
3733
|
var Zs = I((sf, Ns) => {
|
|
3734
3734
|
"use strict";
|
|
3735
|
-
var Vc =
|
|
3735
|
+
var Vc = j("path"), js = Ts(), Rs = Is(), Fc = Os(), Bc = process.platform === "win32", Wc = /\.(?:com|exe)$/i, qc = /node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;
|
|
3736
3736
|
function Gc(t) {
|
|
3737
|
-
t.file =
|
|
3737
|
+
t.file = js(t);
|
|
3738
3738
|
let e = t.file && Fc(t.file);
|
|
3739
|
-
return e ? (t.args.unshift(t.file), t.command = e,
|
|
3739
|
+
return e ? (t.args.unshift(t.file), t.command = e, js(t)) : t.file;
|
|
3740
3740
|
}
|
|
3741
3741
|
i(Gc, "detectShebang");
|
|
3742
3742
|
function zc(t) {
|
|
3743
3743
|
if (!Bc)
|
|
3744
3744
|
return t;
|
|
3745
|
-
let e = Gc(t), r = !
|
|
3745
|
+
let e = Gc(t), r = !Wc.test(e);
|
|
3746
3746
|
if (t.options.forceShell || r) {
|
|
3747
|
-
let n =
|
|
3747
|
+
let n = qc.test(e);
|
|
3748
3748
|
t.command = Vc.normalize(t.command), t.command = Rs.command(t.command), t.args = t.args.map((o) => Rs.argument(o, n));
|
|
3749
3749
|
let s = [t.command].concat(t.args).join(" ");
|
|
3750
3750
|
t.args = ["/d", "/s", "/c", `"${s}"`], t.command = process.env.comspec || "cmd.exe", t.options.windowsVerbatimArguments = !0;
|
|
@@ -3817,7 +3817,7 @@ var Ls = I((af, Ds) => {
|
|
|
3817
3817
|
// ../node_modules/cross-spawn/index.js
|
|
3818
3818
|
var Vs = I((df, Pe) => {
|
|
3819
3819
|
"use strict";
|
|
3820
|
-
var Us =
|
|
3820
|
+
var Us = j("child_process"), hr = Zs(), yr = Ls();
|
|
3821
3821
|
function $s(t, e, r) {
|
|
3822
3822
|
let n = hr(t, e, r), s = Us.spawn(n.command, n.args, n.options);
|
|
3823
3823
|
return yr.hookChildProcess(s, n), s;
|
|
@@ -3838,7 +3838,7 @@ var Vs = I((df, Pe) => {
|
|
|
3838
3838
|
// ../node_modules/merge-stream/index.js
|
|
3839
3839
|
var ho = I((Zm, mo) => {
|
|
3840
3840
|
"use strict";
|
|
3841
|
-
var { PassThrough: Jd } =
|
|
3841
|
+
var { PassThrough: Jd } = j("stream");
|
|
3842
3842
|
mo.exports = function() {
|
|
3843
3843
|
var t = [], e = new Jd({ objectMode: !0 });
|
|
3844
3844
|
return e.setMaxListeners(0), e.add = r, e.isEmpty = n, e.on("unpipe", s), Array.prototype.slice.call(arguments).forEach(r), e;
|
|
@@ -3869,9 +3869,9 @@ var Zo = on(() => {
|
|
|
3869
3869
|
});
|
|
3870
3870
|
|
|
3871
3871
|
// ../node_modules/common-path-prefix/index.js
|
|
3872
|
-
var Fo = I((
|
|
3872
|
+
var Fo = I((Oh, Vo) => {
|
|
3873
3873
|
"use strict";
|
|
3874
|
-
var { sep: Iu } =
|
|
3874
|
+
var { sep: Iu } = j("path"), Su = /* @__PURE__ */ i((t) => {
|
|
3875
3875
|
for (let e of t) {
|
|
3876
3876
|
let r = /(\/|\\)/.exec(e);
|
|
3877
3877
|
if (r !== null) return r[0];
|
|
@@ -3894,8 +3894,8 @@ var Fo = I((Ah, Vo) => {
|
|
|
3894
3894
|
});
|
|
3895
3895
|
|
|
3896
3896
|
// ../node_modules/yocto-queue/index.js
|
|
3897
|
-
var
|
|
3898
|
-
|
|
3897
|
+
var qr, Ge, Bo = on(() => {
|
|
3898
|
+
qr = class {
|
|
3899
3899
|
static {
|
|
3900
3900
|
i(this, "Node");
|
|
3901
3901
|
}
|
|
@@ -3915,7 +3915,7 @@ var Wr, Ge, Bo = on(() => {
|
|
|
3915
3915
|
this.clear();
|
|
3916
3916
|
}
|
|
3917
3917
|
enqueue(e) {
|
|
3918
|
-
let r = new
|
|
3918
|
+
let r = new qr(e);
|
|
3919
3919
|
this.#r ? (this.#t.next = r, this.#t = r) : (this.#r = r, this.#t = r), this.#e++;
|
|
3920
3920
|
}
|
|
3921
3921
|
dequeue() {
|
|
@@ -3946,9 +3946,9 @@ var Wr, Ge, Bo = on(() => {
|
|
|
3946
3946
|
});
|
|
3947
3947
|
|
|
3948
3948
|
// ../node_modules/fetch-retry/index.js
|
|
3949
|
-
var
|
|
3949
|
+
var vi = I((Ix, bi) => {
|
|
3950
3950
|
"use strict";
|
|
3951
|
-
|
|
3951
|
+
bi.exports = function(t, e) {
|
|
3952
3952
|
if (e = e || {}, typeof t != "function")
|
|
3953
3953
|
throw new X("fetch must be a function");
|
|
3954
3954
|
if (typeof e != "object")
|
|
@@ -3982,42 +3982,42 @@ var bi = I((Iv, xi) => {
|
|
|
3982
3982
|
else
|
|
3983
3983
|
throw new X("retryOn property expects an array or function");
|
|
3984
3984
|
return new Promise(function(p, f) {
|
|
3985
|
-
var
|
|
3985
|
+
var x = /* @__PURE__ */ i(function(w) {
|
|
3986
3986
|
var C = typeof Request < "u" && s instanceof Request ? s.clone() : s;
|
|
3987
3987
|
t(C, o).then(function(S) {
|
|
3988
3988
|
if (Array.isArray(l) && l.indexOf(S.status) === -1)
|
|
3989
3989
|
p(S);
|
|
3990
3990
|
else if (typeof l == "function")
|
|
3991
3991
|
try {
|
|
3992
|
-
return Promise.resolve(l(
|
|
3993
|
-
P ? k(
|
|
3992
|
+
return Promise.resolve(l(w, null, S)).then(function(P) {
|
|
3993
|
+
P ? k(w, null, S) : p(S);
|
|
3994
3994
|
}).catch(f);
|
|
3995
3995
|
} catch (P) {
|
|
3996
3996
|
f(P);
|
|
3997
3997
|
}
|
|
3998
3998
|
else
|
|
3999
|
-
|
|
3999
|
+
w < a ? k(w, null, S) : p(S);
|
|
4000
4000
|
}).catch(function(S) {
|
|
4001
4001
|
if (typeof l == "function")
|
|
4002
4002
|
try {
|
|
4003
|
-
Promise.resolve(l(
|
|
4004
|
-
P ? k(
|
|
4003
|
+
Promise.resolve(l(w, S, null)).then(function(P) {
|
|
4004
|
+
P ? k(w, S, null) : f(S);
|
|
4005
4005
|
}).catch(function(P) {
|
|
4006
4006
|
f(P);
|
|
4007
4007
|
});
|
|
4008
4008
|
} catch (P) {
|
|
4009
4009
|
f(P);
|
|
4010
4010
|
}
|
|
4011
|
-
else
|
|
4011
|
+
else w < a ? k(w, S, null) : f(S);
|
|
4012
4012
|
});
|
|
4013
4013
|
}, "wrappedFetch");
|
|
4014
|
-
function k(
|
|
4015
|
-
var P = typeof c == "function" ? c(
|
|
4014
|
+
function k(w, C, S) {
|
|
4015
|
+
var P = typeof c == "function" ? c(w, C, S) : c;
|
|
4016
4016
|
setTimeout(function() {
|
|
4017
|
-
|
|
4017
|
+
x(++w);
|
|
4018
4018
|
}, P);
|
|
4019
4019
|
}
|
|
4020
|
-
i(k, "retry"),
|
|
4020
|
+
i(k, "retry"), x(0);
|
|
4021
4021
|
});
|
|
4022
4022
|
}, "fetchRetry");
|
|
4023
4023
|
};
|
|
@@ -4032,7 +4032,7 @@ var bi = I((Iv, xi) => {
|
|
|
4032
4032
|
});
|
|
4033
4033
|
|
|
4034
4034
|
// src/telemetry/index.ts
|
|
4035
|
-
import { logger as
|
|
4035
|
+
import { logger as Oi } from "storybook/internal/node-logger";
|
|
4036
4036
|
|
|
4037
4037
|
// src/telemetry/notify.ts
|
|
4038
4038
|
var pn = z(dn(), 1);
|
|
@@ -4099,20 +4099,20 @@ import {
|
|
|
4099
4099
|
import { readConfig as al } from "storybook/internal/csf-tools";
|
|
4100
4100
|
|
|
4101
4101
|
// ../node_modules/fd-package-json/dist/esm/main.js
|
|
4102
|
-
var
|
|
4102
|
+
var bn = z(xn(), 1);
|
|
4103
4103
|
import { resolve as Bi } from "node:path";
|
|
4104
|
-
import { stat as
|
|
4105
|
-
import { statSync as
|
|
4104
|
+
import { stat as Wi, readFile as qi } from "node:fs/promises";
|
|
4105
|
+
import { statSync as Wl, readFileSync as ql } from "node:fs";
|
|
4106
4106
|
async function Gi(t) {
|
|
4107
4107
|
try {
|
|
4108
|
-
return (await
|
|
4108
|
+
return (await Wi(t)).isFile();
|
|
4109
4109
|
} catch {
|
|
4110
4110
|
return !1;
|
|
4111
4111
|
}
|
|
4112
4112
|
}
|
|
4113
4113
|
i(Gi, "fileExists");
|
|
4114
4114
|
async function Kt(t) {
|
|
4115
|
-
for (let e of (0,
|
|
4115
|
+
for (let e of (0, bn.walkUp)(t)) {
|
|
4116
4116
|
let r = Bi(e, "package.json");
|
|
4117
4117
|
if (await Gi(r))
|
|
4118
4118
|
return r;
|
|
@@ -4120,21 +4120,21 @@ async function Kt(t) {
|
|
|
4120
4120
|
return null;
|
|
4121
4121
|
}
|
|
4122
4122
|
i(Kt, "findPackagePath");
|
|
4123
|
-
async function
|
|
4123
|
+
async function vn(t) {
|
|
4124
4124
|
let e = await Kt(t);
|
|
4125
4125
|
if (!e)
|
|
4126
4126
|
return null;
|
|
4127
4127
|
try {
|
|
4128
|
-
let r = await
|
|
4128
|
+
let r = await qi(e, { encoding: "utf8" });
|
|
4129
4129
|
return JSON.parse(r);
|
|
4130
4130
|
} catch {
|
|
4131
4131
|
return null;
|
|
4132
4132
|
}
|
|
4133
4133
|
}
|
|
4134
|
-
i(
|
|
4134
|
+
i(vn, "findPackage");
|
|
4135
4135
|
|
|
4136
4136
|
// ../node_modules/package-manager-detector/dist/constants.mjs
|
|
4137
|
-
var
|
|
4137
|
+
var _n = [
|
|
4138
4138
|
"npm",
|
|
4139
4139
|
"yarn",
|
|
4140
4140
|
"yarn@berry",
|
|
@@ -4186,10 +4186,10 @@ function* Ki(t = zi.cwd()) {
|
|
|
4186
4186
|
yield e, e = Q.dirname(e);
|
|
4187
4187
|
}
|
|
4188
4188
|
i(Ki, "lookup");
|
|
4189
|
-
async function
|
|
4189
|
+
async function wn(t, e) {
|
|
4190
4190
|
return !t || !Yt(t, "file") ? null : await Hi(t, e);
|
|
4191
4191
|
}
|
|
4192
|
-
i(
|
|
4192
|
+
i(wn, "parsePackageJson");
|
|
4193
4193
|
async function Xt(t = {}) {
|
|
4194
4194
|
let { cwd: e, strategies: r = ["lockfile", "packageManager-field", "devEngines-field"], onUnknown: n } = t;
|
|
4195
4195
|
for (let s of Ki(e))
|
|
@@ -4198,14 +4198,14 @@ async function Xt(t = {}) {
|
|
|
4198
4198
|
case "lockfile": {
|
|
4199
4199
|
for (let a of Object.keys(Jt))
|
|
4200
4200
|
if (await Yt(Q.join(s, a), "file")) {
|
|
4201
|
-
let c = Jt[a], l = await
|
|
4201
|
+
let c = Jt[a], l = await wn(Q.join(s, "package.json"), n);
|
|
4202
4202
|
return l || { name: c, agent: c };
|
|
4203
4203
|
}
|
|
4204
4204
|
break;
|
|
4205
4205
|
}
|
|
4206
4206
|
case "packageManager-field":
|
|
4207
4207
|
case "devEngines-field": {
|
|
4208
|
-
let a = await
|
|
4208
|
+
let a = await wn(Q.join(s, "package.json"), n);
|
|
4209
4209
|
if (a)
|
|
4210
4210
|
return a;
|
|
4211
4211
|
break;
|
|
@@ -4243,7 +4243,7 @@ async function Hi(t, e) {
|
|
|
4243
4243
|
if (s) {
|
|
4244
4244
|
let o = s.name, a = s.ver, c = a;
|
|
4245
4245
|
return o === "yarn" && a && Number.parseInt(a) > 1 ? (n = "yarn@berry", c = "berry", { name: o, agent: n, version: c }) : o === "pnpm" &&
|
|
4246
|
-
a && Number.parseInt(a) < 7 ? (n = "pnpm@6", { name: o, agent: n, version: c }) :
|
|
4246
|
+
a && Number.parseInt(a) < 7 ? (n = "pnpm@6", { name: o, agent: n, version: c }) : _n.includes(o) ? (n = o, { name: o, agent: n, version: c }) :
|
|
4247
4247
|
e?.(r.packageManager) ?? null;
|
|
4248
4248
|
}
|
|
4249
4249
|
} catch {
|
|
@@ -4262,13 +4262,13 @@ import "node:path";
|
|
|
4262
4262
|
import "node:process";
|
|
4263
4263
|
|
|
4264
4264
|
// package.json
|
|
4265
|
-
var ot = "9.1.0-alpha.
|
|
4265
|
+
var ot = "9.1.0-alpha.7";
|
|
4266
4266
|
|
|
4267
4267
|
// src/cli/globalSettings.ts
|
|
4268
4268
|
var Ee = z(Kn(), 1);
|
|
4269
4269
|
import ar from "node:fs/promises";
|
|
4270
|
-
import { homedir as
|
|
4271
|
-
import { dirname as
|
|
4270
|
+
import { homedir as vc } from "node:os";
|
|
4271
|
+
import { dirname as _c, join as wc } from "node:path";
|
|
4272
4272
|
|
|
4273
4273
|
// src/server-errors.ts
|
|
4274
4274
|
var Xn = z(Hn(), 1);
|
|
@@ -4341,7 +4341,7 @@ var ht = class extends mt {
|
|
|
4341
4341
|
};
|
|
4342
4342
|
|
|
4343
4343
|
// src/cli/globalSettings.ts
|
|
4344
|
-
var kc =
|
|
4344
|
+
var kc = wc(vc(), ".storybook", "settings.json"), Tc = 1, Ic = Ee.z.object({
|
|
4345
4345
|
version: Ee.z.number(),
|
|
4346
4346
|
// NOTE: every key (and subkey) below must be optional, for forwards compatibility reasons
|
|
4347
4347
|
// (we can remove keys once they are deprecated)
|
|
@@ -4376,7 +4376,7 @@ var yt = class {
|
|
|
4376
4376
|
/** Save settings to the file */
|
|
4377
4377
|
async save() {
|
|
4378
4378
|
try {
|
|
4379
|
-
await ar.mkdir(
|
|
4379
|
+
await ar.mkdir(_c(this.filePath), { recursive: !0 }), await ar.writeFile(this.filePath, JSON.stringify(this.value, null, 2));
|
|
4380
4380
|
} catch (e) {
|
|
4381
4381
|
throw new ht({
|
|
4382
4382
|
filePath: this.filePath,
|
|
@@ -4390,14 +4390,14 @@ var yt = class {
|
|
|
4390
4390
|
import { sep as Vu } from "node:path";
|
|
4391
4391
|
|
|
4392
4392
|
// src/telemetry/exec-command-count-lines.ts
|
|
4393
|
-
import { createInterface as
|
|
4393
|
+
import { createInterface as xu } from "node:readline";
|
|
4394
4394
|
|
|
4395
4395
|
// node_modules/execa/index.js
|
|
4396
|
-
var
|
|
4396
|
+
var Ao = z(Vs(), 1);
|
|
4397
4397
|
import { Buffer as pu } from "node:buffer";
|
|
4398
4398
|
import fu from "node:path";
|
|
4399
4399
|
import Vr from "node:child_process";
|
|
4400
|
-
import
|
|
4400
|
+
import Ot from "node:process";
|
|
4401
4401
|
|
|
4402
4402
|
// ../node_modules/strip-final-newline/index.js
|
|
4403
4403
|
function gr(t) {
|
|
@@ -4408,26 +4408,26 @@ function gr(t) {
|
|
|
4408
4408
|
i(gr, "stripFinalNewline");
|
|
4409
4409
|
|
|
4410
4410
|
// node_modules/npm-run-path/index.js
|
|
4411
|
-
import
|
|
4411
|
+
import bt from "node:process";
|
|
4412
4412
|
import Ve from "node:path";
|
|
4413
4413
|
import { fileURLToPath as Fs } from "node:url";
|
|
4414
4414
|
|
|
4415
4415
|
// node_modules/path-key/index.js
|
|
4416
|
-
function
|
|
4416
|
+
function xt(t = {}) {
|
|
4417
4417
|
let {
|
|
4418
4418
|
env: e = process.env,
|
|
4419
4419
|
platform: r = process.platform
|
|
4420
4420
|
} = t;
|
|
4421
4421
|
return r !== "win32" ? "PATH" : Object.keys(e).reverse().find((n) => n.toUpperCase() === "PATH") || "Path";
|
|
4422
4422
|
}
|
|
4423
|
-
i(
|
|
4423
|
+
i(xt, "pathKey");
|
|
4424
4424
|
|
|
4425
4425
|
// node_modules/npm-run-path/index.js
|
|
4426
4426
|
var Xc = /* @__PURE__ */ i(({
|
|
4427
|
-
cwd: t =
|
|
4428
|
-
path: e =
|
|
4427
|
+
cwd: t = bt.cwd(),
|
|
4428
|
+
path: e = bt.env[xt()],
|
|
4429
4429
|
preferLocal: r = !0,
|
|
4430
|
-
execPath: n =
|
|
4430
|
+
execPath: n = bt.execPath,
|
|
4431
4431
|
addExecPath: s = !0
|
|
4432
4432
|
} = {}) => {
|
|
4433
4433
|
let o = t instanceof URL ? Fs(t) : t, a = Ve.resolve(o), c = [];
|
|
@@ -4439,9 +4439,9 @@ var Xc = /* @__PURE__ */ i(({
|
|
|
4439
4439
|
}, "applyPreferLocal"), ed = /* @__PURE__ */ i((t, e, r) => {
|
|
4440
4440
|
let n = e instanceof URL ? Fs(e) : e;
|
|
4441
4441
|
t.push(Ve.resolve(r, n, ".."));
|
|
4442
|
-
}, "applyExecPath"), Bs = /* @__PURE__ */ i(({ env: t =
|
|
4442
|
+
}, "applyExecPath"), Bs = /* @__PURE__ */ i(({ env: t = bt.env, ...e } = {}) => {
|
|
4443
4443
|
t = { ...t };
|
|
4444
|
-
let r =
|
|
4444
|
+
let r = xt({ env: t });
|
|
4445
4445
|
return e.path = t[r], t[r] = Xc(e), t;
|
|
4446
4446
|
}, "npmRunPathEnv");
|
|
4447
4447
|
|
|
@@ -4463,33 +4463,33 @@ prototype.toString, "name"), ad = /* @__PURE__ */ i((t, e, r) => {
|
|
|
4463
4463
|
let n = r === "" ? "" : `with ${r.trim()}() `, s = sd.bind(null, n, e.toString());
|
|
4464
4464
|
Object.defineProperty(s, "name", id), Object.defineProperty(t, "toString", { ...od, value: s });
|
|
4465
4465
|
}, "changeToString");
|
|
4466
|
-
function
|
|
4466
|
+
function xr(t, e, { ignoreNonConfigurable: r = !1 } = {}) {
|
|
4467
4467
|
let { name: n } = t;
|
|
4468
4468
|
for (let s of Reflect.ownKeys(e))
|
|
4469
4469
|
td(t, e, s, r);
|
|
4470
4470
|
return nd(t, e), ad(t, e, n), t;
|
|
4471
4471
|
}
|
|
4472
|
-
i(
|
|
4472
|
+
i(xr, "mimicFunction");
|
|
4473
4473
|
|
|
4474
4474
|
// node_modules/onetime/index.js
|
|
4475
|
-
var
|
|
4475
|
+
var vt = /* @__PURE__ */ new WeakMap(), Ws = /* @__PURE__ */ i((t, e = {}) => {
|
|
4476
4476
|
if (typeof t != "function")
|
|
4477
4477
|
throw new TypeError("Expected a function");
|
|
4478
4478
|
let r, n = 0, s = t.displayName || t.name || "<anonymous>", o = /* @__PURE__ */ i(function(...a) {
|
|
4479
|
-
if (
|
|
4479
|
+
if (vt.set(o, ++n), n === 1)
|
|
4480
4480
|
r = t.apply(this, a), t = null;
|
|
4481
4481
|
else if (e.throw === !0)
|
|
4482
4482
|
throw new Error(`Function \`${s}\` can only be called once`);
|
|
4483
4483
|
return r;
|
|
4484
4484
|
}, "onetime");
|
|
4485
|
-
return
|
|
4485
|
+
return xr(o, t), vt.set(o, n), o;
|
|
4486
4486
|
}, "onetime");
|
|
4487
|
-
|
|
4488
|
-
if (!
|
|
4487
|
+
Ws.callCount = (t) => {
|
|
4488
|
+
if (!vt.has(t))
|
|
4489
4489
|
throw new Error(`The given function \`${t.name}\` is not wrapped by the \`onetime\` package`);
|
|
4490
|
-
return
|
|
4490
|
+
return vt.get(t);
|
|
4491
4491
|
};
|
|
4492
|
-
var
|
|
4492
|
+
var qs = Ws;
|
|
4493
4493
|
|
|
4494
4494
|
// node_modules/execa/lib/error.js
|
|
4495
4495
|
import gd from "node:process";
|
|
@@ -4499,7 +4499,7 @@ import { constants as ld } from "node:os";
|
|
|
4499
4499
|
|
|
4500
4500
|
// node_modules/human-signals/build/src/realtime.js
|
|
4501
4501
|
var Gs = /* @__PURE__ */ i(() => {
|
|
4502
|
-
let t =
|
|
4502
|
+
let t = br - zs + 1;
|
|
4503
4503
|
return Array.from({ length: t }, cd);
|
|
4504
4504
|
}, "getRealtimeSignals"), cd = /* @__PURE__ */ i((t, e) => ({
|
|
4505
4505
|
name: `SIGRT${e + 1}`,
|
|
@@ -4507,7 +4507,7 @@ var Gs = /* @__PURE__ */ i(() => {
|
|
|
4507
4507
|
action: "terminate",
|
|
4508
4508
|
description: "Application-specific signal (realtime)",
|
|
4509
4509
|
standard: "posix"
|
|
4510
|
-
}), "getRealtimeSignal"), zs = 34,
|
|
4510
|
+
}), "getRealtimeSignal"), zs = 34, br = 64;
|
|
4511
4511
|
|
|
4512
4512
|
// node_modules/human-signals/build/src/signals.js
|
|
4513
4513
|
import { constants as dd } from "node:os";
|
|
@@ -4786,7 +4786,7 @@ var Ks = [
|
|
|
4786
4786
|
];
|
|
4787
4787
|
|
|
4788
4788
|
// node_modules/human-signals/build/src/signals.js
|
|
4789
|
-
var
|
|
4789
|
+
var vr = /* @__PURE__ */ i(() => {
|
|
4790
4790
|
let t = Gs();
|
|
4791
4791
|
return [...Ks, ...t].map(ud);
|
|
4792
4792
|
}, "getSignals"), ud = /* @__PURE__ */ i(({
|
|
@@ -4805,7 +4805,7 @@ var br = /* @__PURE__ */ i(() => {
|
|
|
4805
4805
|
|
|
4806
4806
|
// node_modules/human-signals/build/src/main.js
|
|
4807
4807
|
var pd = /* @__PURE__ */ i(() => {
|
|
4808
|
-
let t =
|
|
4808
|
+
let t = vr();
|
|
4809
4809
|
return Object.fromEntries(t.map(fd));
|
|
4810
4810
|
}, "getSignalsByName"), fd = /* @__PURE__ */ i(({
|
|
4811
4811
|
name: t,
|
|
@@ -4817,7 +4817,7 @@ var pd = /* @__PURE__ */ i(() => {
|
|
|
4817
4817
|
standard: a
|
|
4818
4818
|
}) => [t, { name: t, number: e, description: r, supported: n, action: s, forced: o, standard: a }], "getSignalByName"), Js = pd(), md = /* @__PURE__ */ i(
|
|
4819
4819
|
() => {
|
|
4820
|
-
let t =
|
|
4820
|
+
let t = vr(), e = br + 1, r = Array.from(
|
|
4821
4821
|
{ length: e },
|
|
4822
4822
|
(n, s) => hd(s, t)
|
|
4823
4823
|
);
|
|
@@ -4844,7 +4844,7 @@ var pd = /* @__PURE__ */ i(() => {
|
|
|
4844
4844
|
}, "findSignalByNumber"), Df = md();
|
|
4845
4845
|
|
|
4846
4846
|
// node_modules/execa/lib/error.js
|
|
4847
|
-
var
|
|
4847
|
+
var xd = /* @__PURE__ */ i(({ timedOut: t, timeout: e, errorCode: r, signal: n, signalDescription: s, exitCode: o, isCanceled: a }) => t ? `\
|
|
4848
4848
|
timed out after ${e} milliseconds` : a ? "was canceled" : r !== void 0 ? `failed with ${r}` : n !== void 0 ? `was killed with ${n} (${s})` :
|
|
4849
4849
|
o !== void 0 ? `failed with exit code ${o}` : "failed", "getErrorPrefix"), Fe = /* @__PURE__ */ i(({
|
|
4850
4850
|
stdout: t,
|
|
@@ -4858,37 +4858,37 @@ o !== void 0 ? `failed with exit code ${o}` : "failed", "getErrorPrefix"), Fe =
|
|
|
4858
4858
|
timedOut: l,
|
|
4859
4859
|
isCanceled: p,
|
|
4860
4860
|
killed: f,
|
|
4861
|
-
parsed: { options: { timeout:
|
|
4861
|
+
parsed: { options: { timeout: x, cwd: k = gd.cwd() } }
|
|
4862
4862
|
}) => {
|
|
4863
4863
|
o = o === null ? void 0 : o, s = s === null ? void 0 : s;
|
|
4864
|
-
let
|
|
4865
|
-
exitCode: o, isCanceled: p })}: ${a}`, $ = Object.prototype.toString.call(n) === "[object Error]",
|
|
4866
|
-
${n.message}` : P,
|
|
4864
|
+
let w = s === void 0 ? void 0 : Js[s].description, C = n && n.code, P = `Command ${xd({ timedOut: l, timeout: x, errorCode: C, signal: s, signalDescription: w,
|
|
4865
|
+
exitCode: o, isCanceled: p })}: ${a}`, $ = Object.prototype.toString.call(n) === "[object Error]", Oe = $ ? `${P}
|
|
4866
|
+
${n.message}` : P, xe = [Oe, e, t].filter(Boolean).join(`
|
|
4867
4867
|
`);
|
|
4868
|
-
return $ ? (n.originalMessage = n.message, n.message =
|
|
4869
|
-
exitCode = o, n.signal = s, n.signalDescription =
|
|
4868
|
+
return $ ? (n.originalMessage = n.message, n.message = xe) : n = new Error(xe), n.shortMessage = Oe, n.command = a, n.escapedCommand = c, n.
|
|
4869
|
+
exitCode = o, n.signal = s, n.signalDescription = w, n.stdout = t, n.stderr = e, n.cwd = k, r !== void 0 && (n.all = r), "bufferedData" in
|
|
4870
4870
|
n && delete n.bufferedData, n.failed = !0, n.timedOut = !!l, n.isCanceled = p, n.killed = f && !l, n;
|
|
4871
4871
|
}, "makeError");
|
|
4872
4872
|
|
|
4873
4873
|
// node_modules/execa/lib/stdio.js
|
|
4874
|
-
var
|
|
4874
|
+
var _t = ["stdin", "stdout", "stderr"], bd = /* @__PURE__ */ i((t) => _t.some((e) => t[e] !== void 0), "hasAlias"), Hs = /* @__PURE__ */ i((t) => {
|
|
4875
4875
|
if (!t)
|
|
4876
4876
|
return;
|
|
4877
4877
|
let { stdio: e } = t;
|
|
4878
4878
|
if (e === void 0)
|
|
4879
|
-
return
|
|
4880
|
-
if (
|
|
4881
|
-
throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${
|
|
4879
|
+
return _t.map((n) => t[n]);
|
|
4880
|
+
if (bd(t))
|
|
4881
|
+
throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${_t.map((n) => `\`${n}\``).join(", ")}`);
|
|
4882
4882
|
if (typeof e == "string")
|
|
4883
4883
|
return e;
|
|
4884
4884
|
if (!Array.isArray(e))
|
|
4885
4885
|
throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof e}\``);
|
|
4886
|
-
let r = Math.max(e.length,
|
|
4886
|
+
let r = Math.max(e.length, _t.length);
|
|
4887
4887
|
return Array.from({ length: r }, (n, s) => e[s]);
|
|
4888
4888
|
}, "normalizeStdio");
|
|
4889
4889
|
|
|
4890
4890
|
// node_modules/execa/lib/kill.js
|
|
4891
|
-
import
|
|
4891
|
+
import wd from "node:os";
|
|
4892
4892
|
|
|
4893
4893
|
// node_modules/signal-exit/dist/mjs/signals.js
|
|
4894
4894
|
var ye = [];
|
|
@@ -4911,9 +4911,9 @@ process.platform !== "win32" && ye.push(
|
|
|
4911
4911
|
process.platform === "linux" && ye.push("SIGIO", "SIGPOLL", "SIGPWR", "SIGSTKFLT");
|
|
4912
4912
|
|
|
4913
4913
|
// node_modules/signal-exit/dist/mjs/index.js
|
|
4914
|
-
var
|
|
4914
|
+
var wt = /* @__PURE__ */ i((t) => !!t && typeof t == "object" && typeof t.removeListener == "function" && typeof t.emit == "function" && typeof t.
|
|
4915
4915
|
reallyExit == "function" && typeof t.listeners == "function" && typeof t.kill == "function" && typeof t.pid == "number" && typeof t.on == "f\
|
|
4916
|
-
unction", "processOk"),
|
|
4916
|
+
unction", "processOk"), _r = Symbol.for("signal-exit emitter"), wr = globalThis, vd = Object.defineProperty.bind(Object), kr = class {
|
|
4917
4917
|
static {
|
|
4918
4918
|
i(this, "Emitter");
|
|
4919
4919
|
}
|
|
@@ -4928,9 +4928,9 @@ unction", "processOk"), wr = Symbol.for("signal-exit emitter"), _r = globalThis,
|
|
|
4928
4928
|
count = 0;
|
|
4929
4929
|
id = Math.random();
|
|
4930
4930
|
constructor() {
|
|
4931
|
-
if (_r
|
|
4932
|
-
return _r
|
|
4933
|
-
|
|
4931
|
+
if (wr[_r])
|
|
4932
|
+
return wr[_r];
|
|
4933
|
+
vd(wr, _r, {
|
|
4934
4934
|
value: this,
|
|
4935
4935
|
writable: !1,
|
|
4936
4936
|
enumerable: !1,
|
|
@@ -4957,7 +4957,7 @@ unction", "processOk"), wr = Symbol.for("signal-exit emitter"), _r = globalThis,
|
|
|
4957
4957
|
static {
|
|
4958
4958
|
i(this, "SignalExitBase");
|
|
4959
4959
|
}
|
|
4960
|
-
},
|
|
4960
|
+
}, _d = /* @__PURE__ */ i((t) => ({
|
|
4961
4961
|
onExit(e, r) {
|
|
4962
4962
|
return t.onExit(e, r);
|
|
4963
4963
|
},
|
|
@@ -5009,7 +5009,7 @@ unction", "processOk"), wr = Symbol.for("signal-exit emitter"), _r = globalThis,
|
|
|
5009
5009
|
this.#i = e.reallyExit, this.#o = e.emit;
|
|
5010
5010
|
}
|
|
5011
5011
|
onExit(e, r) {
|
|
5012
|
-
if (!
|
|
5012
|
+
if (!wt(this.#e))
|
|
5013
5013
|
return () => {
|
|
5014
5014
|
};
|
|
5015
5015
|
this.#n === !1 && this.load();
|
|
@@ -5042,12 +5042,12 @@ unction", "processOk"), wr = Symbol.for("signal-exit emitter"), _r = globalThis,
|
|
|
5042
5042
|
}), this.#e.emit = this.#o, this.#e.reallyExit = this.#i, this.#t.count -= 1);
|
|
5043
5043
|
}
|
|
5044
5044
|
#a(e) {
|
|
5045
|
-
return
|
|
5045
|
+
return wt(this.#e) ? (this.#e.exitCode = e || 0, this.#t.emit("exit", this.#e.exitCode, null), this.#i.call(this.#e, this.#e.exitCode)) :
|
|
5046
5046
|
0;
|
|
5047
5047
|
}
|
|
5048
5048
|
#c(e, ...r) {
|
|
5049
5049
|
let n = this.#o;
|
|
5050
|
-
if (e === "exit" &&
|
|
5050
|
+
if (e === "exit" && wt(this.#e)) {
|
|
5051
5051
|
typeof r[0] == "number" && (this.#e.exitCode = r[0]);
|
|
5052
5052
|
let s = n.call(this.#e, e, ...r);
|
|
5053
5053
|
return this.#t.emit("exit", this.#e.exitCode, null), s;
|
|
@@ -5081,7 +5081,7 @@ unction", "processOk"), wr = Symbol.for("signal-exit emitter"), _r = globalThis,
|
|
|
5081
5081
|
* @internal
|
|
5082
5082
|
*/
|
|
5083
5083
|
unload: Jf
|
|
5084
|
-
} =
|
|
5084
|
+
} = _d(wt(Sr) ? new Ir(Sr) : new Tr());
|
|
5085
5085
|
|
|
5086
5086
|
// node_modules/execa/lib/kill.js
|
|
5087
5087
|
var kd = 1e3 * 5, Xs = /* @__PURE__ */ i((t, e = "SIGTERM", r = {}) => {
|
|
@@ -5095,7 +5095,7 @@ var kd = 1e3 * 5, Xs = /* @__PURE__ */ i((t, e = "SIGTERM", r = {}) => {
|
|
|
5095
5095
|
}, s);
|
|
5096
5096
|
o.unref && o.unref();
|
|
5097
5097
|
}, "setKillTimeout"), Id = /* @__PURE__ */ i((t, { forceKillAfterTimeout: e }, r) => Sd(t) && e !== !1 && r, "shouldForceKill"), Sd = /* @__PURE__ */ i(
|
|
5098
|
-
(t) => t ===
|
|
5098
|
+
(t) => t === wd.constants.signals.SIGTERM || typeof t == "string" && t.toUpperCase() === "SIGTERM", "isSigterm"), Ed = /* @__PURE__ */ i(({ forceKillAfterTimeout: t = !0 }) => {
|
|
5099
5099
|
if (t === !0)
|
|
5100
5100
|
return kd;
|
|
5101
5101
|
if (!Number.isFinite(t) || t < 0)
|
|
@@ -5132,7 +5132,7 @@ var kd = 1e3 * 5, Xs = /* @__PURE__ */ i((t, e = "SIGTERM", r = {}) => {
|
|
|
5132
5132
|
|
|
5133
5133
|
// node_modules/execa/lib/pipe.js
|
|
5134
5134
|
import { createWriteStream as Pd } from "node:fs";
|
|
5135
|
-
import { ChildProcess as
|
|
5135
|
+
import { ChildProcess as Ad } from "node:child_process";
|
|
5136
5136
|
|
|
5137
5137
|
// node_modules/is-stream/index.js
|
|
5138
5138
|
function Tt(t) {
|
|
@@ -5145,12 +5145,12 @@ function Er(t) {
|
|
|
5145
5145
|
i(Er, "isWritableStream");
|
|
5146
5146
|
|
|
5147
5147
|
// node_modules/execa/lib/pipe.js
|
|
5148
|
-
var
|
|
5148
|
+
var Od = /* @__PURE__ */ i((t) => t instanceof Ad && typeof t.then == "function", "isExecaChildProcess"), Cr = /* @__PURE__ */ i((t, e, r) => {
|
|
5149
5149
|
if (typeof r == "string")
|
|
5150
5150
|
return t[e].pipe(Pd(r)), t;
|
|
5151
5151
|
if (Er(r))
|
|
5152
5152
|
return t[e].pipe(r), t;
|
|
5153
|
-
if (!
|
|
5153
|
+
if (!Od(r))
|
|
5154
5154
|
throw new TypeError("The second argument must be a string, a stream or an Execa child process.");
|
|
5155
5155
|
if (!Er(r.stdin))
|
|
5156
5156
|
throw new TypeError("The target child process's stdin must be available.");
|
|
@@ -5173,14 +5173,14 @@ maxBuffer: l = Number.POSITIVE_INFINITY } = {}) => {
|
|
|
5173
5173
|
p.length = 0;
|
|
5174
5174
|
try {
|
|
5175
5175
|
for await (let f of t) {
|
|
5176
|
-
let
|
|
5176
|
+
let x = Nd(f), k = r[x](f, p);
|
|
5177
5177
|
io({ convertedChunk: k, state: p, getSize: n, truncateChunk: s, addChunk: o, maxBuffer: l });
|
|
5178
5178
|
}
|
|
5179
|
-
return
|
|
5179
|
+
return jd({ state: p, convertChunk: r, getSize: n, truncateChunk: s, addChunk: o, getFinalChunk: a, maxBuffer: l }), c(p);
|
|
5180
5180
|
} catch (f) {
|
|
5181
5181
|
throw f.bufferedData = c(p), f;
|
|
5182
5182
|
}
|
|
5183
|
-
}, "getStreamContents"),
|
|
5183
|
+
}, "getStreamContents"), jd = /* @__PURE__ */ i(({ state: t, getSize: e, truncateChunk: r, addChunk: n, getFinalChunk: s, maxBuffer: o }) => {
|
|
5184
5184
|
let a = s(t);
|
|
5185
5185
|
a !== void 0 && io({ convertedChunk: a, state: t, getSize: e, truncateChunk: r, addChunk: n, maxBuffer: o });
|
|
5186
5186
|
}, "appendFinalChunk"), io = /* @__PURE__ */ i(({ convertedChunk: t, state: e, getSize: r, truncateChunk: n, addChunk: s, maxBuffer: o }) => {
|
|
@@ -5216,16 +5216,16 @@ cIterable"), Nd = /* @__PURE__ */ i((t) => {
|
|
|
5216
5216
|
};
|
|
5217
5217
|
|
|
5218
5218
|
// node_modules/get-stream/source/utils.js
|
|
5219
|
-
var Pr = /* @__PURE__ */ i((t) => t, "identity"),
|
|
5220
|
-
}, "noop"),
|
|
5219
|
+
var Pr = /* @__PURE__ */ i((t) => t, "identity"), Ar = /* @__PURE__ */ i(() => {
|
|
5220
|
+
}, "noop"), Or = /* @__PURE__ */ i(({ contents: t }) => t, "getContentsProp"), St = /* @__PURE__ */ i((t) => {
|
|
5221
5221
|
throw new Error(`Streams in object mode are not supported: ${String(t)}`);
|
|
5222
5222
|
}, "throwObjectStream"), Et = /* @__PURE__ */ i((t) => t.length, "getLengthProp");
|
|
5223
5223
|
|
|
5224
5224
|
// node_modules/get-stream/source/array-buffer.js
|
|
5225
|
-
async function
|
|
5225
|
+
async function jr(t, e) {
|
|
5226
5226
|
return Be(t, Bd, e);
|
|
5227
5227
|
}
|
|
5228
|
-
i(
|
|
5228
|
+
i(jr, "getStreamAsArrayBuffer");
|
|
5229
5229
|
var Zd = /* @__PURE__ */ i(() => ({ contents: new ArrayBuffer(0) }), "initArrayBuffer"), Md = /* @__PURE__ */ i((t) => Dd.encode(t), "useTex\
|
|
5230
5230
|
tEncoder"), Dd = new TextEncoder(), ao = /* @__PURE__ */ i((t) => new Uint8Array(t), "useUint8Array"), co = /* @__PURE__ */ i((t) => new Uint8Array(
|
|
5231
5231
|
t.buffer, t.byteOffset, t.byteLength), "useUint8ArrayWithOffset"), Ld = /* @__PURE__ */ i((t, e) => t.slice(0, e), "truncateArrayBufferChunk"),
|
|
@@ -5257,7 +5257,7 @@ Ud = /* @__PURE__ */ i((t, { contents: e, length: r }, n) => {
|
|
|
5257
5257
|
getSize: Et,
|
|
5258
5258
|
truncateChunk: Ld,
|
|
5259
5259
|
addChunk: Ud,
|
|
5260
|
-
getFinalChunk:
|
|
5260
|
+
getFinalChunk: Ar,
|
|
5261
5261
|
finalize: Fd
|
|
5262
5262
|
};
|
|
5263
5263
|
|
|
@@ -5266,7 +5266,7 @@ async function Ct(t, e) {
|
|
|
5266
5266
|
if (!("Buffer" in globalThis))
|
|
5267
5267
|
throw new Error("getStreamAsBuffer() is only supported in Node.js");
|
|
5268
5268
|
try {
|
|
5269
|
-
return fo(await
|
|
5269
|
+
return fo(await jr(t, e));
|
|
5270
5270
|
} catch (r) {
|
|
5271
5271
|
throw r.bufferedData !== void 0 && (r.bufferedData = fo(r.bufferedData)), r;
|
|
5272
5272
|
}
|
|
@@ -5279,13 +5279,13 @@ async function Rr(t, e) {
|
|
|
5279
5279
|
return Be(t, Kd, e);
|
|
5280
5280
|
}
|
|
5281
5281
|
i(Rr, "getStreamAsString");
|
|
5282
|
-
var
|
|
5283
|
-
decode(t, { stream: !0 }), "useTextDecoder"),
|
|
5282
|
+
var Wd = /* @__PURE__ */ i(() => ({ contents: "", textDecoder: new TextDecoder() }), "initString"), Pt = /* @__PURE__ */ i((t, { textDecoder: e }) => e.
|
|
5283
|
+
decode(t, { stream: !0 }), "useTextDecoder"), qd = /* @__PURE__ */ i((t, { contents: e }) => e + t, "addStringChunk"), Gd = /* @__PURE__ */ i(
|
|
5284
5284
|
(t, e) => t.slice(0, e), "truncateStringChunk"), zd = /* @__PURE__ */ i(({ textDecoder: t }) => {
|
|
5285
5285
|
let e = t.decode();
|
|
5286
5286
|
return e === "" ? void 0 : e;
|
|
5287
5287
|
}, "getFinalStringChunk"), Kd = {
|
|
5288
|
-
init:
|
|
5288
|
+
init: Wd,
|
|
5289
5289
|
convertChunk: {
|
|
5290
5290
|
string: Pr,
|
|
5291
5291
|
buffer: Pt,
|
|
@@ -5296,9 +5296,9 @@ decode(t, { stream: !0 }), "useTextDecoder"), Wd = /* @__PURE__ */ i((t, { conte
|
|
|
5296
5296
|
},
|
|
5297
5297
|
getSize: Et,
|
|
5298
5298
|
truncateChunk: Gd,
|
|
5299
|
-
addChunk:
|
|
5299
|
+
addChunk: qd,
|
|
5300
5300
|
getFinalChunk: zd,
|
|
5301
|
-
finalize:
|
|
5301
|
+
finalize: Or
|
|
5302
5302
|
};
|
|
5303
5303
|
|
|
5304
5304
|
// node_modules/execa/lib/stream.js
|
|
@@ -5307,16 +5307,16 @@ var go = /* @__PURE__ */ i((t) => {
|
|
|
5307
5307
|
if (t !== void 0)
|
|
5308
5308
|
throw new TypeError("The `input` and `inputFile` options cannot be both set.");
|
|
5309
5309
|
}, "validateInputOptions"), Qd = /* @__PURE__ */ i(({ input: t, inputFile: e }) => typeof e != "string" ? t : (go(t), Yd(e)), "getInputSync"),
|
|
5310
|
-
|
|
5310
|
+
xo = /* @__PURE__ */ i((t) => {
|
|
5311
5311
|
let e = Qd(t);
|
|
5312
5312
|
if (Tt(e))
|
|
5313
5313
|
throw new TypeError("The `input` option cannot be a stream in sync mode");
|
|
5314
5314
|
return e;
|
|
5315
|
-
}, "handleInputSync"), eu = /* @__PURE__ */ i(({ input: t, inputFile: e }) => typeof e != "string" ? t : (go(t), Hd(e)), "getInput"),
|
|
5315
|
+
}, "handleInputSync"), eu = /* @__PURE__ */ i(({ input: t, inputFile: e }) => typeof e != "string" ? t : (go(t), Hd(e)), "getInput"), bo = /* @__PURE__ */ i(
|
|
5316
5316
|
(t, e) => {
|
|
5317
5317
|
let r = eu(e);
|
|
5318
5318
|
r !== void 0 && (Tt(r) ? r.pipe(t.stdin) : t.stdin.end(r));
|
|
5319
|
-
}, "handleInput"),
|
|
5319
|
+
}, "handleInput"), vo = /* @__PURE__ */ i((t, { all: e }) => {
|
|
5320
5320
|
if (!e || !t.stdout && !t.stderr)
|
|
5321
5321
|
return;
|
|
5322
5322
|
let r = (0, yo.default)();
|
|
@@ -5333,7 +5333,7 @@ vo = /* @__PURE__ */ i((t) => {
|
|
|
5333
5333
|
}, "getBufferedData"), Zr = /* @__PURE__ */ i((t, { encoding: e, buffer: r, maxBuffer: n }) => {
|
|
5334
5334
|
if (!(!t || !r))
|
|
5335
5335
|
return e === "utf8" || e === "utf-8" ? Rr(t, { maxBuffer: n }) : e === null || e === "buffer" ? Ct(t, { maxBuffer: n }) : tu(t, n, e);
|
|
5336
|
-
}, "getStreamPromise"), tu = /* @__PURE__ */ i(async (t, e, r) => (await Ct(t, { maxBuffer: e })).toString(r), "applyEncoding"),
|
|
5336
|
+
}, "getStreamPromise"), tu = /* @__PURE__ */ i(async (t, e, r) => (await Ct(t, { maxBuffer: e })).toString(r), "applyEncoding"), _o = /* @__PURE__ */ i(
|
|
5337
5337
|
async ({ stdout: t, stderr: e, all: r }, { encoding: n, buffer: s, maxBuffer: o }, a) => {
|
|
5338
5338
|
let c = Zr(t, { encoding: n, buffer: s, maxBuffer: o }), l = Zr(e, { encoding: n, buffer: s, maxBuffer: o }), p = Zr(r, { encoding: n, buffer: s,
|
|
5339
5339
|
maxBuffer: o * 2 });
|
|
@@ -5359,7 +5359,7 @@ var ru = (async () => {
|
|
|
5359
5359
|
let s = typeof e == "function" ? (...o) => Reflect.apply(n.value, e(), o) : n.value.bind(e);
|
|
5360
5360
|
Reflect.defineProperty(t, r, { ...n, value: s });
|
|
5361
5361
|
}
|
|
5362
|
-
}, "mergePromise"),
|
|
5362
|
+
}, "mergePromise"), wo = /* @__PURE__ */ i((t) => new Promise((e, r) => {
|
|
5363
5363
|
t.on("exit", (n, s) => {
|
|
5364
5364
|
e({ exitCode: n, signal: s });
|
|
5365
5365
|
}), t.on("error", (n) => {
|
|
@@ -5424,9 +5424,9 @@ d"), Lr = /* @__PURE__ */ i((t, e) => Io(t, e).map((r) => au(r)).join(" "), "get
|
|
|
5424
5424
|
// node_modules/execa/lib/verbose.js
|
|
5425
5425
|
import { debuglog as du } from "node:util";
|
|
5426
5426
|
import uu from "node:process";
|
|
5427
|
-
var Co = du("execa").enabled,
|
|
5427
|
+
var Co = du("execa").enabled, At = /* @__PURE__ */ i((t, e) => String(t).padStart(e, "0"), "padField"), lu = /* @__PURE__ */ i(() => {
|
|
5428
5428
|
let t = /* @__PURE__ */ new Date();
|
|
5429
|
-
return `${
|
|
5429
|
+
return `${At(t.getHours(), 2)}:${At(t.getMinutes(), 2)}:${At(t.getSeconds(), 2)}.${At(t.getMilliseconds(), 3)}`;
|
|
5430
5430
|
}, "getTimestamp"), $r = /* @__PURE__ */ i((t, { verbose: e }) => {
|
|
5431
5431
|
e && uu.stderr.write(`[${lu()}] ${t}
|
|
5432
5432
|
`);
|
|
@@ -5434,18 +5434,18 @@ var Co = du("execa").enabled, jt = /* @__PURE__ */ i((t, e) => String(t).padStar
|
|
|
5434
5434
|
|
|
5435
5435
|
// node_modules/execa/index.js
|
|
5436
5436
|
var mu = 1e3 * 1e3 * 100, hu = /* @__PURE__ */ i(({ env: t, extendEnv: e, preferLocal: r, localDir: n, execPath: s }) => {
|
|
5437
|
-
let o = e ? { ...
|
|
5437
|
+
let o = e ? { ...Ot.env, ...t } : t;
|
|
5438
5438
|
return r ? Bs({ env: o, cwd: n, execPath: s }) : o;
|
|
5439
|
-
}, "getEnv"),
|
|
5440
|
-
let n =
|
|
5439
|
+
}, "getEnv"), Oo = /* @__PURE__ */ i((t, e, r = {}) => {
|
|
5440
|
+
let n = Ao.default._parse(t, e, r);
|
|
5441
5441
|
return t = n.command, e = n.args, r = n.options, r = {
|
|
5442
5442
|
maxBuffer: mu,
|
|
5443
5443
|
buffer: !0,
|
|
5444
5444
|
stripFinalNewline: !0,
|
|
5445
5445
|
extendEnv: !0,
|
|
5446
5446
|
preferLocal: !1,
|
|
5447
|
-
localDir: r.cwd ||
|
|
5448
|
-
execPath:
|
|
5447
|
+
localDir: r.cwd || Ot.cwd(),
|
|
5448
|
+
execPath: Ot.execPath,
|
|
5449
5449
|
encoding: "utf8",
|
|
5450
5450
|
reject: !0,
|
|
5451
5451
|
cleanup: !0,
|
|
@@ -5453,19 +5453,19 @@ var mu = 1e3 * 1e3 * 100, hu = /* @__PURE__ */ i(({ env: t, extendEnv: e, prefer
|
|
|
5453
5453
|
windowsHide: !0,
|
|
5454
5454
|
verbose: Co,
|
|
5455
5455
|
...r
|
|
5456
|
-
}, r.env = hu(r), r.stdio = Hs(r),
|
|
5456
|
+
}, r.env = hu(r), r.stdio = Hs(r), Ot.platform === "win32" && fu.basename(t, ".exe") === "cmd" && e.unshift("/q"), { file: t, args: e, options: r,
|
|
5457
5457
|
parsed: n };
|
|
5458
|
-
}, "handleArguments"),
|
|
5458
|
+
}, "handleArguments"), We = /* @__PURE__ */ i((t, e, r) => typeof e != "string" && !pu.isBuffer(e) ? r === void 0 ? void 0 : "" : t.stripFinalNewline ?
|
|
5459
5459
|
gr(e) : e, "handleOutput");
|
|
5460
|
-
function
|
|
5461
|
-
let n =
|
|
5460
|
+
function jo(t, e, r) {
|
|
5461
|
+
let n = Oo(t, e, r), s = Dr(t, e), o = Lr(t, e);
|
|
5462
5462
|
$r(o, n.options), to(n.options);
|
|
5463
5463
|
let a;
|
|
5464
5464
|
try {
|
|
5465
5465
|
a = Vr.spawn(n.file, n.args, n.options);
|
|
5466
|
-
} catch (
|
|
5466
|
+
} catch (w) {
|
|
5467
5467
|
let C = new Vr.ChildProcess(), S = Promise.reject(Fe({
|
|
5468
|
-
error:
|
|
5468
|
+
error: w,
|
|
5469
5469
|
stdout: "",
|
|
5470
5470
|
stderr: "",
|
|
5471
5471
|
all: "",
|
|
@@ -5478,17 +5478,17 @@ function Oo(t, e, r) {
|
|
|
5478
5478
|
}));
|
|
5479
5479
|
return Mr(C, S), C;
|
|
5480
5480
|
}
|
|
5481
|
-
let c =
|
|
5481
|
+
let c = wo(a), l = eo(a, n.options, c), p = ro(a, n.options, l), f = { isCanceled: !1 };
|
|
5482
5482
|
a.kill = Xs.bind(null, a.kill.bind(a)), a.cancel = Qs.bind(null, a, f);
|
|
5483
|
-
let k =
|
|
5484
|
-
let [{ error:
|
|
5485
|
-
|
|
5486
|
-
if (
|
|
5487
|
-
let
|
|
5488
|
-
error:
|
|
5483
|
+
let k = qs(/* @__PURE__ */ i(async () => {
|
|
5484
|
+
let [{ error: w, exitCode: C, signal: S, timedOut: P }, $, Oe, xe] = await _o(a, n.options, p), je = We(n.options, $), Ye = We(n.options,
|
|
5485
|
+
Oe), Xe = We(n.options, xe);
|
|
5486
|
+
if (w || C !== 0 || S !== null) {
|
|
5487
|
+
let b = Fe({
|
|
5488
|
+
error: w,
|
|
5489
5489
|
exitCode: C,
|
|
5490
5490
|
signal: S,
|
|
5491
|
-
stdout:
|
|
5491
|
+
stdout: je,
|
|
5492
5492
|
stderr: Ye,
|
|
5493
5493
|
all: Xe,
|
|
5494
5494
|
command: s,
|
|
@@ -5499,14 +5499,14 @@ function Oo(t, e, r) {
|
|
|
5499
5499
|
killed: a.killed
|
|
5500
5500
|
});
|
|
5501
5501
|
if (!n.options.reject)
|
|
5502
|
-
return
|
|
5503
|
-
throw
|
|
5502
|
+
return b;
|
|
5503
|
+
throw b;
|
|
5504
5504
|
}
|
|
5505
5505
|
return {
|
|
5506
5506
|
command: s,
|
|
5507
5507
|
escapedCommand: o,
|
|
5508
5508
|
exitCode: 0,
|
|
5509
|
-
stdout:
|
|
5509
|
+
stdout: je,
|
|
5510
5510
|
stderr: Ye,
|
|
5511
5511
|
all: Xe,
|
|
5512
5512
|
failed: !1,
|
|
@@ -5515,13 +5515,13 @@ function Oo(t, e, r) {
|
|
|
5515
5515
|
killed: !1
|
|
5516
5516
|
};
|
|
5517
5517
|
}, "handlePromise"));
|
|
5518
|
-
return
|
|
5518
|
+
return bo(a, n.options), a.all = vo(a, n.options), no(a), Mr(a, k), a;
|
|
5519
5519
|
}
|
|
5520
|
-
i(
|
|
5520
|
+
i(jo, "execa");
|
|
5521
5521
|
function yu(t, e, r) {
|
|
5522
|
-
let n =
|
|
5522
|
+
let n = Oo(t, e, r), s = Dr(t, e), o = Lr(t, e);
|
|
5523
5523
|
$r(o, n.options);
|
|
5524
|
-
let a =
|
|
5524
|
+
let a = xo(n.options), c;
|
|
5525
5525
|
try {
|
|
5526
5526
|
c = Vr.spawnSync(n.file, n.args, { ...n.options, input: a });
|
|
5527
5527
|
} catch (f) {
|
|
@@ -5538,7 +5538,7 @@ function yu(t, e, r) {
|
|
|
5538
5538
|
killed: !1
|
|
5539
5539
|
});
|
|
5540
5540
|
}
|
|
5541
|
-
let l =
|
|
5541
|
+
let l = We(n.options, c.stdout, c.error), p = We(n.options, c.stderr, c.error);
|
|
5542
5542
|
if (c.error || c.status !== 0 || c.signal !== null) {
|
|
5543
5543
|
let f = Fe({
|
|
5544
5544
|
stdout: l,
|
|
@@ -5581,7 +5581,7 @@ function Ro(t) {
|
|
|
5581
5581
|
if (!Array.isArray(r))
|
|
5582
5582
|
return Ro({ ...t, ...r });
|
|
5583
5583
|
let [s, ...o] = Ur(r, n);
|
|
5584
|
-
return
|
|
5584
|
+
return jo(s, o, Po(t));
|
|
5585
5585
|
}
|
|
5586
5586
|
return i(e, "$"), e.sync = (r, ...n) => {
|
|
5587
5587
|
if (!Array.isArray(r))
|
|
@@ -5594,38 +5594,38 @@ i(Ro, "create$");
|
|
|
5594
5594
|
var hh = Ro();
|
|
5595
5595
|
function No(t, e) {
|
|
5596
5596
|
let [r, ...n] = Eo(t);
|
|
5597
|
-
return
|
|
5597
|
+
return jo(r, n, e);
|
|
5598
5598
|
}
|
|
5599
5599
|
i(No, "execaCommand");
|
|
5600
5600
|
|
|
5601
5601
|
// src/telemetry/exec-command-count-lines.ts
|
|
5602
|
-
async function
|
|
5602
|
+
async function jt(t, e) {
|
|
5603
5603
|
let r = No(t, { shell: !0, buffer: !1, ...e });
|
|
5604
5604
|
if (!r.stdout)
|
|
5605
5605
|
throw new Error("Unexpected missing stdout");
|
|
5606
|
-
let n = 0, s =
|
|
5606
|
+
let n = 0, s = xu(r.stdout);
|
|
5607
5607
|
return s.on("line", () => {
|
|
5608
5608
|
n += 1;
|
|
5609
5609
|
}), await r, s.close(), n;
|
|
5610
5610
|
}
|
|
5611
|
-
i(
|
|
5611
|
+
i(jt, "execCommandCountLines");
|
|
5612
5612
|
|
|
5613
5613
|
// src/common/utils/file-cache.ts
|
|
5614
|
-
import { createHash as Mo, randomBytes as
|
|
5615
|
-
import { mkdirSync as Br, readFileSync as
|
|
5614
|
+
import { createHash as Mo, randomBytes as bu } from "node:crypto";
|
|
5615
|
+
import { mkdirSync as Br, readFileSync as vu, readdirSync as _u, rmSync as Do, writeFileSync as wu } from "node:fs";
|
|
5616
5616
|
import { readFile as Lo, readdir as Uo, rm as $o, writeFile as ku } from "node:fs/promises";
|
|
5617
5617
|
import { tmpdir as Tu } from "node:os";
|
|
5618
|
-
import { join as
|
|
5618
|
+
import { join as qe } from "node:path";
|
|
5619
5619
|
var Rt = class {
|
|
5620
5620
|
static {
|
|
5621
5621
|
i(this, "FileSystemCache");
|
|
5622
5622
|
}
|
|
5623
5623
|
constructor(e = {}) {
|
|
5624
|
-
this.prefix = (e.ns || e.prefix || "") + "-", this.hash_alg = e.hash_alg || "
|
|
5624
|
+
this.prefix = (e.ns || e.prefix || "") + "-", this.hash_alg = e.hash_alg || "sha256", this.cache_dir = e.basePath || qe(Tu(), bu(15).toString(
|
|
5625
5625
|
"base64").replace(/\//g, "-")), this.ttl = e.ttl || 0, Mo(this.hash_alg), Br(this.cache_dir, { recursive: !0 });
|
|
5626
5626
|
}
|
|
5627
5627
|
generateHash(e) {
|
|
5628
|
-
return
|
|
5628
|
+
return qe(this.cache_dir, this.prefix + Mo(this.hash_alg).update(e).digest("hex"));
|
|
5629
5629
|
}
|
|
5630
5630
|
isExpired(e, r) {
|
|
5631
5631
|
return e.ttl != null && r > e.ttl;
|
|
@@ -5648,7 +5648,7 @@ var Rt = class {
|
|
|
5648
5648
|
}
|
|
5649
5649
|
getSync(e, r) {
|
|
5650
5650
|
try {
|
|
5651
|
-
let n =
|
|
5651
|
+
let n = vu(this.generateHash(e), "utf8");
|
|
5652
5652
|
return this.parseCacheData(n, r);
|
|
5653
5653
|
} catch {
|
|
5654
5654
|
return r;
|
|
@@ -5662,7 +5662,7 @@ var Rt = class {
|
|
|
5662
5662
|
}
|
|
5663
5663
|
setSync(e, r, n = {}) {
|
|
5664
5664
|
let s = typeof n == "number" ? { ttl: n } : n;
|
|
5665
|
-
Br(this.cache_dir, { recursive: !0 }),
|
|
5665
|
+
Br(this.cache_dir, { recursive: !0 }), wu(this.generateHash(e), this.parseSetData(e, r, s), {
|
|
5666
5666
|
encoding: s.encoding || "utf8"
|
|
5667
5667
|
});
|
|
5668
5668
|
}
|
|
@@ -5681,16 +5681,16 @@ var Rt = class {
|
|
|
5681
5681
|
async clear() {
|
|
5682
5682
|
let e = await Uo(this.cache_dir);
|
|
5683
5683
|
await Promise.all(
|
|
5684
|
-
e.filter((r) => r.startsWith(this.prefix)).map((r) => $o(
|
|
5684
|
+
e.filter((r) => r.startsWith(this.prefix)).map((r) => $o(qe(this.cache_dir, r), { force: !0 }))
|
|
5685
5685
|
);
|
|
5686
5686
|
}
|
|
5687
5687
|
clearSync() {
|
|
5688
|
-
|
|
5688
|
+
_u(this.cache_dir).filter((e) => e.startsWith(this.prefix)).forEach((e) => Do(qe(this.cache_dir, e), { force: !0 }));
|
|
5689
5689
|
}
|
|
5690
5690
|
async getAll() {
|
|
5691
5691
|
let e = Date.now(), r = await Uo(this.cache_dir);
|
|
5692
5692
|
return (await Promise.all(
|
|
5693
|
-
r.filter((s) => s.startsWith(this.prefix)).map((s) => Lo(
|
|
5693
|
+
r.filter((s) => s.startsWith(this.prefix)).map((s) => Lo(qe(this.cache_dir, s), "utf8"))
|
|
5694
5694
|
)).map((s) => JSON.parse(s)).filter((s) => s.content && !this.isExpired(s, e));
|
|
5695
5695
|
}
|
|
5696
5696
|
async load() {
|
|
@@ -5703,10 +5703,10 @@ var Rt = class {
|
|
|
5703
5703
|
};
|
|
5704
5704
|
}
|
|
5705
5705
|
};
|
|
5706
|
-
function
|
|
5706
|
+
function Wr(t) {
|
|
5707
5707
|
return new Rt(t);
|
|
5708
5708
|
}
|
|
5709
|
-
i(
|
|
5709
|
+
i(Wr, "createFileSystemCache");
|
|
5710
5710
|
|
|
5711
5711
|
// src/common/utils/resolve-path-in-sb-cache.ts
|
|
5712
5712
|
import { join as ni } from "node:path";
|
|
@@ -5722,12 +5722,12 @@ import Nu from "node:path";
|
|
|
5722
5722
|
|
|
5723
5723
|
// ../node_modules/pkg-dir/node_modules/find-up/index.js
|
|
5724
5724
|
import Lt from "node:path";
|
|
5725
|
-
import { fileURLToPath as
|
|
5725
|
+
import { fileURLToPath as Au } from "node:url";
|
|
5726
5726
|
|
|
5727
5727
|
// ../node_modules/locate-path/index.js
|
|
5728
5728
|
import Go from "node:process";
|
|
5729
5729
|
import zo from "node:path";
|
|
5730
|
-
import
|
|
5730
|
+
import Wo, { promises as qo } from "node:fs";
|
|
5731
5731
|
import { fileURLToPath as Pu } from "node:url";
|
|
5732
5732
|
|
|
5733
5733
|
// ../node_modules/locate-path/node_modules/p-limit/index.js
|
|
@@ -5815,7 +5815,7 @@ async function Mt(t, {
|
|
|
5815
5815
|
preserveOrder: o
|
|
5816
5816
|
} = {}) {
|
|
5817
5817
|
Jo(r), e = Yo(e);
|
|
5818
|
-
let a = n ?
|
|
5818
|
+
let a = n ? qo.stat : qo.lstat;
|
|
5819
5819
|
return Gr(t, async (c) => {
|
|
5820
5820
|
try {
|
|
5821
5821
|
let l = await a(zo.resolve(e, c));
|
|
@@ -5832,7 +5832,7 @@ function Dt(t, {
|
|
|
5832
5832
|
allowSymlinks: n = !0
|
|
5833
5833
|
} = {}) {
|
|
5834
5834
|
Jo(r), e = Yo(e);
|
|
5835
|
-
let s = n ?
|
|
5835
|
+
let s = n ? Wo.statSync : Wo.lstatSync;
|
|
5836
5836
|
for (let o of t)
|
|
5837
5837
|
try {
|
|
5838
5838
|
let a = s(zo.resolve(e, o), {
|
|
@@ -5851,9 +5851,9 @@ i(Dt, "locatePathSync");
|
|
|
5851
5851
|
import Jh, { promises as Hh } from "node:fs";
|
|
5852
5852
|
|
|
5853
5853
|
// ../node_modules/pkg-dir/node_modules/find-up/index.js
|
|
5854
|
-
var
|
|
5854
|
+
var Ou = /* @__PURE__ */ i((t) => t instanceof URL ? Au(t) : t, "toPath"), ju = Symbol("findUpStop");
|
|
5855
5855
|
function Ru(t, e = {}) {
|
|
5856
|
-
let r = Lt.resolve(
|
|
5856
|
+
let r = Lt.resolve(Ou(e.cwd) || ""), { root: n } = Lt.parse(r), s = e.stopAt || n, o = e.limit || Number.POSITIVE_INFINITY, a = [t].flat(),
|
|
5857
5857
|
c = /* @__PURE__ */ i((p) => {
|
|
5858
5858
|
if (typeof t != "function")
|
|
5859
5859
|
return Dt(a, p);
|
|
@@ -5862,7 +5862,7 @@ function Ru(t, e = {}) {
|
|
|
5862
5862
|
}, "runMatcher"), l = [];
|
|
5863
5863
|
for (; ; ) {
|
|
5864
5864
|
let p = c({ ...e, cwd: r });
|
|
5865
|
-
if (p ===
|
|
5865
|
+
if (p === ju || (p && l.push(Lt.resolve(r, p)), r === s || l.length >= o))
|
|
5866
5866
|
break;
|
|
5867
5867
|
r = Lt.dirname(r);
|
|
5868
5868
|
}
|
|
@@ -5958,7 +5958,7 @@ async function oi(t, e = {}) {
|
|
|
5958
5958
|
i(oi, "findUp");
|
|
5959
5959
|
|
|
5960
5960
|
// src/telemetry/run-telemetry-operation.ts
|
|
5961
|
-
var ii =
|
|
5961
|
+
var ii = Wr({
|
|
5962
5962
|
basePath: si("telemetry"),
|
|
5963
5963
|
ns: "storybook",
|
|
5964
5964
|
ttl: 24 * 60 * 60 * 1e3
|
|
@@ -5969,7 +5969,7 @@ var ii = qr({
|
|
|
5969
5969
|
}, "runTelemetryOperation");
|
|
5970
5970
|
|
|
5971
5971
|
// src/telemetry/get-application-file-count.ts
|
|
5972
|
-
var Fu = ["page", "screen"], Bu = ["js", "jsx", "ts", "tsx"],
|
|
5972
|
+
var Fu = ["page", "screen"], Bu = ["js", "jsx", "ts", "tsx"], Wu = /* @__PURE__ */ i(async (t) => {
|
|
5973
5973
|
let r = Fu.flatMap((n) => [
|
|
5974
5974
|
n,
|
|
5975
5975
|
[n[0].toUpperCase(), ...n.slice(1)].join("")
|
|
@@ -5978,13 +5978,13 @@ var Fu = ["page", "screen"], Bu = ["js", "jsx", "ts", "tsx"], qu = /* @__PURE__
|
|
|
5978
5978
|
);
|
|
5979
5979
|
try {
|
|
5980
5980
|
let n = `git ls-files -- ${r.join(" ")}`;
|
|
5981
|
-
return await
|
|
5981
|
+
return await jt(n);
|
|
5982
5982
|
} catch {
|
|
5983
5983
|
return;
|
|
5984
5984
|
}
|
|
5985
5985
|
}, "getApplicationFilesCountUncached"), ai = /* @__PURE__ */ i(async (t) => $t(
|
|
5986
5986
|
"applicationFiles",
|
|
5987
|
-
async () =>
|
|
5987
|
+
async () => Wu(t)
|
|
5988
5988
|
), "getApplicationFileCount");
|
|
5989
5989
|
|
|
5990
5990
|
// src/telemetry/get-chromatic-version.ts
|
|
@@ -5999,7 +5999,7 @@ import { normalize as zu } from "node:path";
|
|
|
5999
5999
|
import { frameworkPackages as Ku } from "storybook/internal/common";
|
|
6000
6000
|
|
|
6001
6001
|
// src/telemetry/package-json.ts
|
|
6002
|
-
import { readFile as
|
|
6002
|
+
import { readFile as qu } from "node:fs/promises";
|
|
6003
6003
|
import { join as Gu } from "node:path";
|
|
6004
6004
|
var Hr = /* @__PURE__ */ i(async (t) => {
|
|
6005
6005
|
let e = Object.keys(t);
|
|
@@ -6019,10 +6019,10 @@ var Hr = /* @__PURE__ */ i(async (t) => {
|
|
|
6019
6019
|
}
|
|
6020
6020
|
}, "getActualPackageVersion"), Yr = /* @__PURE__ */ i(async (t) => {
|
|
6021
6021
|
try {
|
|
6022
|
-
let e = await oi("package.json", { cwd:
|
|
6023
|
-
return e || (e =
|
|
6022
|
+
let e = await oi("package.json", { cwd: j.resolve(t) });
|
|
6023
|
+
return e || (e = j.resolve(Gu(t, "package.json"), {
|
|
6024
6024
|
paths: [process.cwd()]
|
|
6025
|
-
})), JSON.parse(await
|
|
6025
|
+
})), JSON.parse(await qu(e, { encoding: "utf8" }));
|
|
6026
6026
|
} catch {
|
|
6027
6027
|
return;
|
|
6028
6028
|
}
|
|
@@ -6137,7 +6137,7 @@ var fi = {
|
|
|
6137
6137
|
var el = /* @__PURE__ */ i(async (t) => {
|
|
6138
6138
|
try {
|
|
6139
6139
|
let e = "git grep -l composeStor" + (t ? ` -- ${t}` : "");
|
|
6140
|
-
return await
|
|
6140
|
+
return await jt(e);
|
|
6141
6141
|
} catch (e) {
|
|
6142
6142
|
return e.exitCode === 1 ? 0 : void 0;
|
|
6143
6143
|
}
|
|
@@ -6174,13 +6174,13 @@ var yi = {
|
|
|
6174
6174
|
...e?.dependencies,
|
|
6175
6175
|
...e?.devDependencies,
|
|
6176
6176
|
...e?.peerDependencies
|
|
6177
|
-
}, c = Object.keys(a).find((
|
|
6177
|
+
}, c = Object.keys(a).find((b) => !!yi[b]);
|
|
6178
6178
|
if (c) {
|
|
6179
|
-
let { version:
|
|
6179
|
+
let { version: b } = await Vt(c);
|
|
6180
6180
|
o.metaFramework = {
|
|
6181
6181
|
name: yi[c],
|
|
6182
6182
|
packageName: c,
|
|
6183
|
-
version:
|
|
6183
|
+
version: b || "unknown"
|
|
6184
6184
|
};
|
|
6185
6185
|
}
|
|
6186
6186
|
let l = [
|
|
@@ -6203,69 +6203,69 @@ var yi = {
|
|
|
6203
6203
|
"sinon",
|
|
6204
6204
|
"chromatic"
|
|
6205
6205
|
], p = Object.keys(a).filter(
|
|
6206
|
-
(
|
|
6206
|
+
(b) => l.find((A) => b.includes(A))
|
|
6207
6207
|
);
|
|
6208
6208
|
o.testPackages = Object.fromEntries(
|
|
6209
6209
|
await Promise.all(
|
|
6210
|
-
p.map(async (
|
|
6210
|
+
p.map(async (b) => [b, (await Vt(b))?.version])
|
|
6211
6211
|
)
|
|
6212
6212
|
), o.hasRouterPackage = li(e);
|
|
6213
6213
|
let f = mi();
|
|
6214
6214
|
f && (o.monorepo = f);
|
|
6215
6215
|
try {
|
|
6216
|
-
let
|
|
6217
|
-
|
|
6218
|
-
type:
|
|
6219
|
-
version:
|
|
6220
|
-
agent:
|
|
6216
|
+
let b = await Xt({ cwd: rl() });
|
|
6217
|
+
b && (o.packageManager = {
|
|
6218
|
+
type: b.name,
|
|
6219
|
+
version: b.version,
|
|
6220
|
+
agent: b.agent
|
|
6221
6221
|
});
|
|
6222
6222
|
} catch {
|
|
6223
6223
|
}
|
|
6224
|
-
let
|
|
6224
|
+
let x = a.typescript ? "typescript" : "javascript";
|
|
6225
6225
|
if (!r)
|
|
6226
6226
|
return {
|
|
6227
6227
|
...o,
|
|
6228
6228
|
storybookVersionSpecifier: il.storybook,
|
|
6229
|
-
language:
|
|
6229
|
+
language: x
|
|
6230
6230
|
};
|
|
6231
6231
|
o.hasCustomBabel = !!r.babel, o.hasCustomWebpack = !!r.webpackFinal, o.hasStaticDirs = !!r.staticDirs, typeof r.typescript == "object" && (o.
|
|
6232
6232
|
typescriptOptions = r.typescript);
|
|
6233
6233
|
let k = await ui(r);
|
|
6234
6234
|
typeof r.refs == "object" && (o.refCount = Object.keys(r.refs).length), typeof r.features == "object" && (o.features = r.features);
|
|
6235
|
-
let
|
|
6236
|
-
r.addons && r.addons.forEach((
|
|
6237
|
-
let
|
|
6238
|
-
typeof
|
|
6235
|
+
let w = {};
|
|
6236
|
+
r.addons && r.addons.forEach((b) => {
|
|
6237
|
+
let A, Qe;
|
|
6238
|
+
typeof b == "string" ? A = gi(b) : (b.name.includes("addon-essentials") && (Qe = b.options), A = gi(b.name)), w[A] = {
|
|
6239
6239
|
options: Qe,
|
|
6240
6240
|
version: void 0
|
|
6241
6241
|
};
|
|
6242
6242
|
});
|
|
6243
6243
|
let C = ci(e);
|
|
6244
|
-
C && (
|
|
6244
|
+
C && (w.chromatic = {
|
|
6245
6245
|
version: void 0,
|
|
6246
6246
|
versionSpecifier: C,
|
|
6247
6247
|
options: void 0
|
|
6248
|
-
}), (await Hr(
|
|
6249
|
-
|
|
6250
|
-
name:
|
|
6251
|
-
version:
|
|
6252
|
-
},
|
|
6248
|
+
}), (await Hr(w)).forEach(({ name: b, version: A }) => {
|
|
6249
|
+
w[b] = w[b] || {
|
|
6250
|
+
name: b,
|
|
6251
|
+
version: A
|
|
6252
|
+
}, w[b].version = A || void 0;
|
|
6253
6253
|
});
|
|
6254
|
-
let P = Object.keys(
|
|
6255
|
-
...
|
|
6256
|
-
[
|
|
6254
|
+
let P = Object.keys(w), $ = Object.keys(a).filter((b) => b.includes("storybook") && !P.includes(b)).reduce((b, A) => ({
|
|
6255
|
+
...b,
|
|
6256
|
+
[A]: { version: void 0 }
|
|
6257
6257
|
}), {});
|
|
6258
|
-
(await Hr($)).forEach(({ name:
|
|
6259
|
-
$[
|
|
6260
|
-
name:
|
|
6261
|
-
version:
|
|
6262
|
-
}, $[
|
|
6258
|
+
(await Hr($)).forEach(({ name: b, version: A }) => {
|
|
6259
|
+
$[b] = $[b] || {
|
|
6260
|
+
name: b,
|
|
6261
|
+
version: A
|
|
6262
|
+
}, $[b].version = A || void 0;
|
|
6263
6263
|
});
|
|
6264
|
-
let
|
|
6264
|
+
let xe = !!a["eslint-plugin-storybook"], je = sl(n);
|
|
6265
6265
|
try {
|
|
6266
|
-
let { previewConfigPath:
|
|
6267
|
-
if (
|
|
6268
|
-
let
|
|
6266
|
+
let { previewConfigPath: b } = je;
|
|
6267
|
+
if (b) {
|
|
6268
|
+
let A = await al(b), Qe = !!(A.getFieldNode(["globals"]) || A.getFieldNode(["globalTypes"]));
|
|
6269
6269
|
o.preview = { ...o.preview, usesGlobals: Qe };
|
|
6270
6270
|
}
|
|
6271
6271
|
} catch {
|
|
@@ -6277,25 +6277,25 @@ var yi = {
|
|
|
6277
6277
|
portableStoriesFileCount: Ye,
|
|
6278
6278
|
applicationFileCount: Xe,
|
|
6279
6279
|
storybookVersion: ot,
|
|
6280
|
-
storybookVersionSpecifier:
|
|
6281
|
-
language:
|
|
6280
|
+
storybookVersionSpecifier: je.version,
|
|
6281
|
+
language: x,
|
|
6282
6282
|
storybookPackages: $,
|
|
6283
|
-
addons:
|
|
6284
|
-
hasStorybookEslint:
|
|
6283
|
+
addons: w,
|
|
6284
|
+
hasStorybookEslint: xe
|
|
6285
6285
|
};
|
|
6286
6286
|
}, "computeStorybookMetadata");
|
|
6287
6287
|
async function dl() {
|
|
6288
6288
|
let t = await Kt(process.cwd());
|
|
6289
6289
|
return t ? {
|
|
6290
6290
|
packageJsonPath: t,
|
|
6291
|
-
packageJson: await
|
|
6291
|
+
packageJson: await vn(t) || {}
|
|
6292
6292
|
} : {
|
|
6293
6293
|
packageJsonPath: process.cwd(),
|
|
6294
6294
|
packageJson: {}
|
|
6295
6295
|
};
|
|
6296
6296
|
}
|
|
6297
6297
|
i(dl, "getPackageJsonDetails");
|
|
6298
|
-
var Ft,
|
|
6298
|
+
var Ft, xi = /* @__PURE__ */ i(async (t) => {
|
|
6299
6299
|
if (Ft)
|
|
6300
6300
|
return Ft;
|
|
6301
6301
|
let { packageJson: e, packageJsonPath: r } = await dl(), n = (t || nl(
|
|
@@ -6313,24 +6313,24 @@ var Ft, vi = /* @__PURE__ */ i(async (t) => {
|
|
|
6313
6313
|
}, "getStorybookMetadata");
|
|
6314
6314
|
|
|
6315
6315
|
// src/telemetry/telemetry.ts
|
|
6316
|
-
var Pi = z(
|
|
6316
|
+
var Pi = z(vi(), 1);
|
|
6317
6317
|
import * as Ci from "node:os";
|
|
6318
6318
|
|
|
6319
6319
|
// ../node_modules/nanoid/index.js
|
|
6320
|
-
import { randomFillSync as
|
|
6320
|
+
import { randomFillSync as wi } from "crypto";
|
|
6321
6321
|
|
|
6322
6322
|
// ../node_modules/nanoid/url-alphabet/index.js
|
|
6323
|
-
var
|
|
6323
|
+
var _i = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
6324
6324
|
|
|
6325
6325
|
// ../node_modules/nanoid/index.js
|
|
6326
|
-
var ul = 128, ge,
|
|
6327
|
-
!ge || ge.length < t ? (ge = Buffer.allocUnsafe(t * ul),
|
|
6326
|
+
var ul = 128, ge, Ae, ll = /* @__PURE__ */ i((t) => {
|
|
6327
|
+
!ge || ge.length < t ? (ge = Buffer.allocUnsafe(t * ul), wi(ge), Ae = 0) : Ae + t > ge.length && (wi(ge), Ae = 0), Ae += t;
|
|
6328
6328
|
}, "fillPool");
|
|
6329
6329
|
var Je = /* @__PURE__ */ i((t = 21) => {
|
|
6330
6330
|
ll(t -= 0);
|
|
6331
6331
|
let e = "";
|
|
6332
|
-
for (let r =
|
|
6333
|
-
e +=
|
|
6332
|
+
for (let r = Ae - t; r < Ae; r++)
|
|
6333
|
+
e += _i[ge[r] & 63];
|
|
6334
6334
|
return e;
|
|
6335
6335
|
}, "nanoid");
|
|
6336
6336
|
|
|
@@ -6357,27 +6357,27 @@ function gl(t, e) {
|
|
|
6357
6357
|
return `${yl(t)}${Fr(e)}`;
|
|
6358
6358
|
}
|
|
6359
6359
|
i(gl, "unhashedProjectId");
|
|
6360
|
-
var
|
|
6361
|
-
if (
|
|
6362
|
-
return
|
|
6360
|
+
var Wt, ki = /* @__PURE__ */ i(() => {
|
|
6361
|
+
if (Wt)
|
|
6362
|
+
return Wt;
|
|
6363
6363
|
try {
|
|
6364
6364
|
let t = fl(ml(), process.cwd()), e = hl("git config --local --get remote.origin.url", {
|
|
6365
6365
|
timeout: 1e3,
|
|
6366
6366
|
stdio: "pipe"
|
|
6367
6367
|
});
|
|
6368
|
-
|
|
6368
|
+
Wt = en(gl(String(e), t));
|
|
6369
6369
|
} catch {
|
|
6370
6370
|
}
|
|
6371
|
-
return
|
|
6371
|
+
return Wt;
|
|
6372
6372
|
}, "getAnonymousProjectId");
|
|
6373
6373
|
|
|
6374
6374
|
// src/telemetry/event-cache.ts
|
|
6375
6375
|
import { cache as rn } from "storybook/internal/common";
|
|
6376
|
-
var tn = Promise.resolve(),
|
|
6376
|
+
var tn = Promise.resolve(), xl = /* @__PURE__ */ i(async (t, e) => {
|
|
6377
6377
|
let r = await rn.get("lastEvents") || {};
|
|
6378
6378
|
r[t] = { body: e, timestamp: Date.now() }, await rn.set("lastEvents", r);
|
|
6379
|
-
}, "setHelper"), Ii = /* @__PURE__ */ i(async (t, e) => (await tn, tn =
|
|
6380
|
-
var
|
|
6379
|
+
}, "setHelper"), Ii = /* @__PURE__ */ i(async (t, e) => (await tn, tn = xl(t, e), tn), "set");
|
|
6380
|
+
var bl = /* @__PURE__ */ i((t) => {
|
|
6381
6381
|
let { body: e, timestamp: r } = t;
|
|
6382
6382
|
return {
|
|
6383
6383
|
timestamp: r,
|
|
@@ -6385,13 +6385,13 @@ var xl = /* @__PURE__ */ i((t) => {
|
|
|
6385
6385
|
eventId: e?.eventId,
|
|
6386
6386
|
sessionId: e?.sessionId
|
|
6387
6387
|
};
|
|
6388
|
-
}, "upgradeFields"),
|
|
6388
|
+
}, "upgradeFields"), vl = ["init", "upgrade"], _l = ["build", "dev", "error"], Ti = /* @__PURE__ */ i((t, e) => {
|
|
6389
6389
|
let r = e.map((n) => t?.[n]).filter(Boolean).sort((n, s) => s.timestamp - n.timestamp);
|
|
6390
6390
|
return r.length > 0 ? r[0] : void 0;
|
|
6391
|
-
}, "lastEvent"),
|
|
6392
|
-
let e = t || await rn.get("lastEvents") || {}, r = Ti(e,
|
|
6391
|
+
}, "lastEvent"), wl = /* @__PURE__ */ i(async (t = void 0) => {
|
|
6392
|
+
let e = t || await rn.get("lastEvents") || {}, r = Ti(e, vl), n = Ti(e, _l);
|
|
6393
6393
|
if (r)
|
|
6394
|
-
return !n?.timestamp || r.timestamp > n.timestamp ?
|
|
6394
|
+
return !n?.timestamp || r.timestamp > n.timestamp ? bl(r) : void 0;
|
|
6395
6395
|
}, "getPrecedingUpgrade");
|
|
6396
6396
|
|
|
6397
6397
|
// src/telemetry/fetch.ts
|
|
@@ -6410,7 +6410,7 @@ var nn = /* @__PURE__ */ i(async () => {
|
|
|
6410
6410
|
}, "getSessionId");
|
|
6411
6411
|
|
|
6412
6412
|
// src/telemetry/telemetry.ts
|
|
6413
|
-
var Tl = (0, Pi.default)(Si), Il = process.env.STORYBOOK_TELEMETRY_URL || "https://storybook.js.org/event-log",
|
|
6413
|
+
var Tl = (0, Pi.default)(Si), Il = process.env.STORYBOOK_TELEMETRY_URL || "https://storybook.js.org/event-log", qt = [], Sl = /* @__PURE__ */ i(
|
|
6414
6414
|
(t, e) => {
|
|
6415
6415
|
sn[t] = e;
|
|
6416
6416
|
}, "addToGlobalContext"), El = /* @__PURE__ */ i(() => {
|
|
@@ -6439,51 +6439,51 @@ var Tl = (0, Pi.default)(Si), Il = process.env.STORYBOOK_TELEMETRY_URL || "https
|
|
|
6439
6439
|
retryDelay")
|
|
6440
6440
|
});
|
|
6441
6441
|
}, "prepareRequest");
|
|
6442
|
-
async function
|
|
6442
|
+
async function Ai(t, e = { retryDelay: 1e3, immediate: !1 }) {
|
|
6443
6443
|
let { eventType: r, payload: n, metadata: s, ...o } = t, a = e.stripMetadata ? sn : {
|
|
6444
6444
|
...sn,
|
|
6445
6445
|
anonymousId: ki()
|
|
6446
6446
|
}, c;
|
|
6447
6447
|
try {
|
|
6448
|
-
c = Cl(t, a, e),
|
|
6448
|
+
c = Cl(t, a, e), qt.push(c), e.immediate ? await Promise.all(qt) : await c;
|
|
6449
6449
|
let l = await nn(), p = Je(), f = { ...o, eventType: r, eventId: p, sessionId: l, metadata: s, payload: n, context: a };
|
|
6450
6450
|
await Ii(r, f);
|
|
6451
6451
|
} catch {
|
|
6452
6452
|
} finally {
|
|
6453
|
-
|
|
6453
|
+
qt = qt.filter((l) => l !== c);
|
|
6454
6454
|
}
|
|
6455
6455
|
}
|
|
6456
|
-
i(
|
|
6456
|
+
i(Ai, "sendTelemetry");
|
|
6457
6457
|
|
|
6458
6458
|
// src/telemetry/index.ts
|
|
6459
|
-
var
|
|
6460
|
-
sExampleStoryId"),
|
|
6459
|
+
var db = /* @__PURE__ */ i((t) => t.startsWith("example-button--") || t.startsWith("example-header--") || t.startsWith("example-page--"), "i\
|
|
6460
|
+
sExampleStoryId"), ub = /* @__PURE__ */ i(async (t, e = {}, r = {}) => {
|
|
6461
6461
|
t !== "boot" && r.notify !== !1 && await fn();
|
|
6462
6462
|
let n = {
|
|
6463
6463
|
eventType: t,
|
|
6464
6464
|
payload: e
|
|
6465
6465
|
};
|
|
6466
6466
|
try {
|
|
6467
|
-
r?.stripMetadata || (n.metadata = await
|
|
6467
|
+
r?.stripMetadata || (n.metadata = await xi(r?.configDir));
|
|
6468
6468
|
} catch (s) {
|
|
6469
6469
|
n.payload.metadataErrorMessage = nt(s).message, r?.enableCrashReports && (n.payload.metadataError = nt(s));
|
|
6470
6470
|
} finally {
|
|
6471
6471
|
let { error: s } = n.payload;
|
|
6472
|
-
s && (n.payload.error = nt(s)), (!n.payload.error || r?.enableCrashReports) && (process.env?.STORYBOOK_TELEMETRY_DEBUG && (
|
|
6473
|
-
[telemetry]`),
|
|
6472
|
+
s && (n.payload.error = nt(s)), (!n.payload.error || r?.enableCrashReports) && (process.env?.STORYBOOK_TELEMETRY_DEBUG && (Oi.info(`
|
|
6473
|
+
[telemetry]`), Oi.info(JSON.stringify(n, null, 2))), await Ai(n, r));
|
|
6474
6474
|
}
|
|
6475
6475
|
}, "telemetry");
|
|
6476
6476
|
export {
|
|
6477
6477
|
Sl as addToGlobalContext,
|
|
6478
6478
|
Re as cleanPaths,
|
|
6479
6479
|
cl as computeStorybookMetadata,
|
|
6480
|
-
|
|
6481
|
-
|
|
6482
|
-
|
|
6480
|
+
wl as getPrecedingUpgrade,
|
|
6481
|
+
xi as getStorybookMetadata,
|
|
6482
|
+
db as isExampleStoryId,
|
|
6483
6483
|
yi as metaFrameworks,
|
|
6484
6484
|
en as oneWayHash,
|
|
6485
6485
|
hn as removeAnsiEscapeCodes,
|
|
6486
6486
|
gi as sanitizeAddonName,
|
|
6487
6487
|
nt as sanitizeError,
|
|
6488
|
-
|
|
6488
|
+
ub as telemetry
|
|
6489
6489
|
};
|