storybook 9.0.0-alpha.18 → 9.0.0-alpha.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/index.cjs +42 -42
- package/dist/bin/index.js +42 -42
- package/dist/cli/bin/index.cjs +1 -1
- package/dist/cli/bin/index.js +1 -1
- package/dist/common/index.cjs +42 -42
- package/dist/common/index.js +42 -42
- package/dist/core-server/index.cjs +122 -119
- package/dist/core-server/index.js +1596 -1593
- package/dist/core-server/presets/common-manager.js +1 -2
- package/dist/manager/globals-runtime.js +1 -1
- package/dist/manager/runtime.js +4 -2
- package/dist/manager-api/index.cjs +1 -1
- package/dist/manager-api/index.js +1 -1
- package/package.json +1 -1
|
@@ -441,11 +441,11 @@ var $l = P((CX, t0) => {
|
|
|
441
441
|
|
|
442
442
|
// ../node_modules/json5/lib/parse.js
|
|
443
443
|
var o0 = P((wX, s0) => {
|
|
444
|
-
var at = $l(), Ul,
|
|
444
|
+
var at = $l(), Ul, vt, Xr, Ho, xi, pr, lt, Hl, Fs;
|
|
445
445
|
s0.exports = /* @__PURE__ */ s(function(t, r) {
|
|
446
|
-
Ul = String(t),
|
|
446
|
+
Ul = String(t), vt = "start", Xr = [], Ho = 0, xi = 1, pr = 0, lt = void 0, Hl = void 0, Fs = void 0;
|
|
447
447
|
do
|
|
448
|
-
lt = CB(), SB[
|
|
448
|
+
lt = CB(), SB[vt]();
|
|
449
449
|
while (lt.type !== "eof");
|
|
450
450
|
return typeof r == "function" ? Wl({ "": Fs }, "", r) : Fs;
|
|
451
451
|
}, "parse");
|
|
@@ -522,7 +522,7 @@ var o0 = P((wX, s0) => {
|
|
|
522
522
|
J();
|
|
523
523
|
return;
|
|
524
524
|
}
|
|
525
|
-
return i0[
|
|
525
|
+
return i0[vt]();
|
|
526
526
|
},
|
|
527
527
|
comment() {
|
|
528
528
|
switch (Ce) {
|
|
@@ -982,7 +982,7 @@ var o0 = P((wX, s0) => {
|
|
|
982
982
|
switch (lt.type) {
|
|
983
983
|
case "identifier":
|
|
984
984
|
case "string":
|
|
985
|
-
Hl = lt.value,
|
|
985
|
+
Hl = lt.value, vt = "afterPropertyName";
|
|
986
986
|
return;
|
|
987
987
|
case "punctuator":
|
|
988
988
|
zo();
|
|
@@ -994,7 +994,7 @@ var o0 = P((wX, s0) => {
|
|
|
994
994
|
afterPropertyName() {
|
|
995
995
|
if (lt.type === "eof")
|
|
996
996
|
throw Ji();
|
|
997
|
-
|
|
997
|
+
vt = "beforePropertyValue";
|
|
998
998
|
},
|
|
999
999
|
beforePropertyValue() {
|
|
1000
1000
|
if (lt.type === "eof")
|
|
@@ -1015,7 +1015,7 @@ var o0 = P((wX, s0) => {
|
|
|
1015
1015
|
throw Ji();
|
|
1016
1016
|
switch (lt.value) {
|
|
1017
1017
|
case ",":
|
|
1018
|
-
|
|
1018
|
+
vt = "beforePropertyName";
|
|
1019
1019
|
return;
|
|
1020
1020
|
case "}":
|
|
1021
1021
|
zo();
|
|
@@ -1026,7 +1026,7 @@ var o0 = P((wX, s0) => {
|
|
|
1026
1026
|
throw Ji();
|
|
1027
1027
|
switch (lt.value) {
|
|
1028
1028
|
case ",":
|
|
1029
|
-
|
|
1029
|
+
vt = "beforeArrayValue";
|
|
1030
1030
|
return;
|
|
1031
1031
|
case "]":
|
|
1032
1032
|
zo();
|
|
@@ -1067,17 +1067,17 @@ var o0 = P((wX, s0) => {
|
|
|
1067
1067
|
});
|
|
1068
1068
|
}
|
|
1069
1069
|
if (e !== null && typeof e == "object")
|
|
1070
|
-
Xr.push(e), Array.isArray(e) ?
|
|
1070
|
+
Xr.push(e), Array.isArray(e) ? vt = "beforeArrayValue" : vt = "beforePropertyName";
|
|
1071
1071
|
else {
|
|
1072
1072
|
let t = Xr[Xr.length - 1];
|
|
1073
|
-
t == null ?
|
|
1073
|
+
t == null ? vt = "end" : Array.isArray(t) ? vt = "afterArrayValue" : vt = "afterPropertyValue";
|
|
1074
1074
|
}
|
|
1075
1075
|
}
|
|
1076
1076
|
s(Vl, "push");
|
|
1077
1077
|
function zo() {
|
|
1078
1078
|
Xr.pop();
|
|
1079
1079
|
let e = Xr[Xr.length - 1];
|
|
1080
|
-
e == null ?
|
|
1080
|
+
e == null ? vt = "end" : Array.isArray(e) ? vt = "afterArrayValue" : vt = "afterPropertyValue";
|
|
1081
1081
|
}
|
|
1082
1082
|
s(zo, "pop");
|
|
1083
1083
|
function qe(e) {
|
|
@@ -3169,7 +3169,7 @@ var ZD = P((jY, QD) => {
|
|
|
3169
3169
|
return;
|
|
3170
3170
|
}
|
|
3171
3171
|
Z.prev = M, u.push(Z), M = Z;
|
|
3172
|
-
}, "push"),
|
|
3172
|
+
}, "push"), Et = /* @__PURE__ */ s((Z, fe) => {
|
|
3173
3173
|
let G = { ...p[fe], conditions: 1, inner: "" };
|
|
3174
3174
|
G.prev = M, G.parens = O.parens, G.output = O.output;
|
|
3175
3175
|
let ee = (r.capture ? "(" : "") + G.open;
|
|
@@ -3352,7 +3352,7 @@ var ZD = P((jY, QD) => {
|
|
|
3352
3352
|
}
|
|
3353
3353
|
if (R === "?") {
|
|
3354
3354
|
if (!(M && M.value === "(") && r.noextglob !== !0 && Y() === "(" && Y(2) !== "?") {
|
|
3355
|
-
|
|
3355
|
+
Et("qmark", R);
|
|
3356
3356
|
continue;
|
|
3357
3357
|
}
|
|
3358
3358
|
if (M && M.type === "paren") {
|
|
@@ -3372,7 +3372,7 @@ var ZD = P((jY, QD) => {
|
|
|
3372
3372
|
}
|
|
3373
3373
|
if (R === "!") {
|
|
3374
3374
|
if (r.noextglob !== !0 && Y() === "(" && (Y(2) !== "?" || !/[!=<:]/.test(Y(3)))) {
|
|
3375
|
-
|
|
3375
|
+
Et("negate", R);
|
|
3376
3376
|
continue;
|
|
3377
3377
|
}
|
|
3378
3378
|
if (r.nonegate !== !0 && O.index === 0) {
|
|
@@ -3382,7 +3382,7 @@ var ZD = P((jY, QD) => {
|
|
|
3382
3382
|
}
|
|
3383
3383
|
if (R === "+") {
|
|
3384
3384
|
if (r.noextglob !== !0 && Y() === "(" && Y(2) !== "?") {
|
|
3385
|
-
|
|
3385
|
+
Et("plus", R);
|
|
3386
3386
|
continue;
|
|
3387
3387
|
}
|
|
3388
3388
|
if (M && M.value === "(" || r.regex === !1) {
|
|
@@ -3416,7 +3416,7 @@ var ZD = P((jY, QD) => {
|
|
|
3416
3416
|
}
|
|
3417
3417
|
let Z = I();
|
|
3418
3418
|
if (r.noextglob !== !0 && /^\([^?]/.test(Z)) {
|
|
3419
|
-
|
|
3419
|
+
Et("star", R);
|
|
3420
3420
|
continue;
|
|
3421
3421
|
}
|
|
3422
3422
|
if (M.type === "star") {
|
|
@@ -8153,7 +8153,7 @@ function x1(e) {
|
|
|
8153
8153
|
return typeof BigInt != "function" ? null : BigInt(e.replace(/_/g, ""));
|
|
8154
8154
|
}
|
|
8155
8155
|
var $9, jE, V9, qE, xh, Eh, U9, W9, z9, H9, Fe, Zt, It, Sh, A, rr, J9, VE, er, UE, G9, X9, Rn, OE, RE, Y9, Ms, ju, Ch, NE, js, Nn, Fh, zE, HE,
|
|
8156
|
-
JE, _h, GE, qs, kh, Ru, Bh, ii, XE, YE, KE, nt, Or,
|
|
8156
|
+
JE, _h, GE, qs, kh, Ru, Bh, ii, XE, YE, KE, nt, Or, Ct, Z9, qu, ie, Ih, eR, tR, Ls, wh, QE, ir, gr, Ue, Ln, he, iR, Lu, _i, nR, $u, $s, sR, t1,
|
|
8157
8157
|
r1, i1, n1, s1, oR, uR, aR, lR, LE, o1, u1, a1, l1, c1, cR, pR, p1, ME, Ou, bh, re, Mu, Rr, d1, ri, tr, Ph, we, E1, wR, b1 = dt(() => {
|
|
8158
8158
|
$9 = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 574, 3, 9, 9, 7, 9, 32, 4, 318, 1, 80, 3, 71, 10, 50, 3, 123,
|
|
8159
8159
|
2, 54, 14, 32, 10, 3, 1, 11, 3, 46, 10, 8, 0, 46, 9, 7, 2, 37, 13, 2, 9, 6, 1, 45, 0, 13, 2, 49, 13, 9, 3, 2, 11, 83, 11, 7, 0, 3, 0, 158,
|
|
@@ -8505,8 +8505,8 @@ odule" : 5]);
|
|
|
8505
8505
|
return new this(r, t);
|
|
8506
8506
|
}, "tokenizer");
|
|
8507
8507
|
Object.defineProperties(nt.prototype, Or);
|
|
8508
|
-
|
|
8509
|
-
|
|
8508
|
+
Ct = nt.prototype, Z9 = /^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;
|
|
8509
|
+
Ct.strictDirective = function(e) {
|
|
8510
8510
|
if (this.options.ecmaVersion < 5)
|
|
8511
8511
|
return !1;
|
|
8512
8512
|
for (; ; ) {
|
|
@@ -8522,49 +8522,49 @@ odule" : 5]);
|
|
|
8522
8522
|
e += t[0].length, er.lastIndex = e, e += er.exec(this.input)[0].length, this.input[e] === ";" && e++;
|
|
8523
8523
|
}
|
|
8524
8524
|
};
|
|
8525
|
-
|
|
8525
|
+
Ct.eat = function(e) {
|
|
8526
8526
|
return this.type === e ? (this.next(), !0) : !1;
|
|
8527
8527
|
};
|
|
8528
|
-
|
|
8528
|
+
Ct.isContextual = function(e) {
|
|
8529
8529
|
return this.type === A.name && this.value === e && !this.containsEsc;
|
|
8530
8530
|
};
|
|
8531
|
-
|
|
8531
|
+
Ct.eatContextual = function(e) {
|
|
8532
8532
|
return this.isContextual(e) ? (this.next(), !0) : !1;
|
|
8533
8533
|
};
|
|
8534
|
-
|
|
8534
|
+
Ct.expectContextual = function(e) {
|
|
8535
8535
|
this.eatContextual(e) || this.unexpected();
|
|
8536
8536
|
};
|
|
8537
|
-
|
|
8537
|
+
Ct.canInsertSemicolon = function() {
|
|
8538
8538
|
return this.type === A.eof || this.type === A.braceR || rr.test(this.input.slice(this.lastTokEnd, this.start));
|
|
8539
8539
|
};
|
|
8540
|
-
|
|
8540
|
+
Ct.insertSemicolon = function() {
|
|
8541
8541
|
if (this.canInsertSemicolon())
|
|
8542
8542
|
return this.options.onInsertedSemicolon && this.options.onInsertedSemicolon(this.lastTokEnd, this.lastTokEndLoc), !0;
|
|
8543
8543
|
};
|
|
8544
|
-
|
|
8544
|
+
Ct.semicolon = function() {
|
|
8545
8545
|
!this.eat(A.semi) && !this.insertSemicolon() && this.unexpected();
|
|
8546
8546
|
};
|
|
8547
|
-
|
|
8547
|
+
Ct.afterTrailingComma = function(e, t) {
|
|
8548
8548
|
if (this.type === e)
|
|
8549
8549
|
return this.options.onTrailingComma && this.options.onTrailingComma(this.lastTokStart, this.lastTokStartLoc), t || this.next(), !0;
|
|
8550
8550
|
};
|
|
8551
|
-
|
|
8551
|
+
Ct.expect = function(e) {
|
|
8552
8552
|
this.eat(e) || this.unexpected();
|
|
8553
8553
|
};
|
|
8554
|
-
|
|
8554
|
+
Ct.unexpected = function(e) {
|
|
8555
8555
|
this.raise(e ?? this.start, "Unexpected token");
|
|
8556
8556
|
};
|
|
8557
8557
|
qu = /* @__PURE__ */ s(function() {
|
|
8558
8558
|
this.shorthandAssign = this.trailingComma = this.parenthesizedAssign = this.parenthesizedBind = this.doubleProto = -1;
|
|
8559
8559
|
}, "DestructuringErrors");
|
|
8560
|
-
|
|
8560
|
+
Ct.checkPatternErrors = function(e, t) {
|
|
8561
8561
|
if (e) {
|
|
8562
8562
|
e.trailingComma > -1 && this.raiseRecoverable(e.trailingComma, "Comma is not permitted after the rest element");
|
|
8563
8563
|
var r = t ? e.parenthesizedAssign : e.parenthesizedBind;
|
|
8564
8564
|
r > -1 && this.raiseRecoverable(r, t ? "Assigning to rvalue" : "Parenthesized pattern");
|
|
8565
8565
|
}
|
|
8566
8566
|
};
|
|
8567
|
-
|
|
8567
|
+
Ct.checkExpressionErrors = function(e, t) {
|
|
8568
8568
|
if (!e)
|
|
8569
8569
|
return !1;
|
|
8570
8570
|
var r = e.shorthandAssign, i = e.doubleProto;
|
|
@@ -8573,11 +8573,11 @@ odule" : 5]);
|
|
|
8573
8573
|
r >= 0 && this.raise(r, "Shorthand property assignments are valid only in destructuring patterns"), i >= 0 && this.raiseRecoverable(i, "\
|
|
8574
8574
|
Redefinition of __proto__ property");
|
|
8575
8575
|
};
|
|
8576
|
-
|
|
8576
|
+
Ct.checkYieldAwaitInDefaultParams = function() {
|
|
8577
8577
|
this.yieldPos && (!this.awaitPos || this.yieldPos < this.awaitPos) && this.raise(this.yieldPos, "Yield expression cannot be a default va\
|
|
8578
8578
|
lue"), this.awaitPos && this.raise(this.awaitPos, "Await expression cannot be a default value");
|
|
8579
8579
|
};
|
|
8580
|
-
|
|
8580
|
+
Ct.isSimpleAssignTarget = function(e) {
|
|
8581
8581
|
return e.type === "ParenthesizedExpression" ? this.isSimpleAssignTarget(e.expression) : e.type === "Identifier" || e.type === "MemberExp\
|
|
8582
8582
|
ression";
|
|
8583
8583
|
};
|
|
@@ -12567,11 +12567,11 @@ r the end of the tag");
|
|
|
12567
12567
|
}))
|
|
12568
12568
|
return e.consume(E), ce;
|
|
12569
12569
|
if (E === 46 || E === 47 || E === 62 || E === 123 || tt(E) || ni(E))
|
|
12570
|
-
return e.exit(m), U =
|
|
12570
|
+
return e.exit(m), U = Et, x(E);
|
|
12571
12571
|
B(E, "in member name", "a name character such as letters, digits, `$`, or `_`; whitespace before attributes; or the end of the tag" + (E ===
|
|
12572
12572
|
64 ? " (note: to create a link in MDX, use `[text](url)`)" : ""));
|
|
12573
12573
|
}
|
|
12574
|
-
function
|
|
12574
|
+
function Et(E) {
|
|
12575
12575
|
if (E === 46)
|
|
12576
12576
|
return e.enter(d), e.consume(E), e.exit(d), U = Ie, x;
|
|
12577
12577
|
if (E === 47 || E === 62 || E === 123 || E !== null && E >= 0 && Kt(E))
|
|
@@ -14679,21 +14679,21 @@ function d7(e, t, r) {
|
|
|
14679
14679
|
return Z;
|
|
14680
14680
|
function Z(fe) {
|
|
14681
14681
|
return Me = O(), se = Te, Te.partial || (p.currentConstruct = Te), Te.name && p.parser.constructs.disable.null.includes(Te.name) ?
|
|
14682
|
-
|
|
14682
|
+
Et(fe) : Te.tokenize.call(
|
|
14683
14683
|
// If we do have fields, create an object w/ `context` as its
|
|
14684
14684
|
// prototype.
|
|
14685
14685
|
// This allows a “live binding”, which is needed for `interrupt`.
|
|
14686
14686
|
X ? Object.assign(Object.create(p), X) : p,
|
|
14687
14687
|
c,
|
|
14688
14688
|
ce,
|
|
14689
|
-
|
|
14689
|
+
Et
|
|
14690
14690
|
)(fe);
|
|
14691
14691
|
}
|
|
14692
14692
|
}
|
|
14693
14693
|
function ce(Te) {
|
|
14694
14694
|
return l = !0, V(se, Me), U;
|
|
14695
14695
|
}
|
|
14696
|
-
function
|
|
14696
|
+
function Et(Te) {
|
|
14697
14697
|
return l = !0, Me.restore(), ++I < te.length ? Ie(te[I]) : Y;
|
|
14698
14698
|
}
|
|
14699
14699
|
}
|
|
@@ -14910,7 +14910,7 @@ function P7(e) {
|
|
|
14910
14910
|
atxHeadingSequence: L,
|
|
14911
14911
|
autolink: l(),
|
|
14912
14912
|
autolinkEmail: Te,
|
|
14913
|
-
autolinkProtocol:
|
|
14913
|
+
autolinkProtocol: Et,
|
|
14914
14914
|
blockQuote: l(),
|
|
14915
14915
|
characterEscapeValue: q,
|
|
14916
14916
|
characterReferenceMarkerHexadecimal: Ie,
|
|
@@ -15270,7 +15270,7 @@ function P7(e) {
|
|
|
15270
15270
|
let j = this.stack.pop();
|
|
15271
15271
|
j.value += E, j.position.end = ki(y.end);
|
|
15272
15272
|
}
|
|
15273
|
-
function
|
|
15273
|
+
function Et(y) {
|
|
15274
15274
|
q.call(this, y);
|
|
15275
15275
|
let F = this.stack[this.stack.length - 1];
|
|
15276
15276
|
F.url = this.sliceSerialize(y);
|
|
@@ -17496,7 +17496,7 @@ function eL(e, t, r, i) {
|
|
|
17496
17496
|
e.write(r + n[o].trim());
|
|
17497
17497
|
}
|
|
17498
17498
|
}
|
|
17499
|
-
function
|
|
17499
|
+
function wt(e, t, r, i) {
|
|
17500
17500
|
let { length: n } = t;
|
|
17501
17501
|
for (let o = 0; o < n; o++) {
|
|
17502
17502
|
let u = t[o];
|
|
@@ -22630,7 +22630,7 @@ times with `settings`, but this has neither"
|
|
|
22630
22630
|
s(sv, "expressionNeedsParenthesis");
|
|
22631
22631
|
s(Ju, "formatExpression");
|
|
22632
22632
|
s(eL, "reindent");
|
|
22633
|
-
s(
|
|
22633
|
+
s(wt, "formatComments");
|
|
22634
22634
|
s(tL, "hasCallExpression");
|
|
22635
22635
|
s(Gh, "formatVariableDeclaration");
|
|
22636
22636
|
ov = {
|
|
@@ -22639,29 +22639,29 @@ times with `settings`, but this has neither"
|
|
|
22639
22639
|
*/
|
|
22640
22640
|
Program(e, t) {
|
|
22641
22641
|
let r = t.indent.repeat(t.indentLevel), { lineEnd: i, writeComments: n } = t;
|
|
22642
|
-
n && e.comments != null &&
|
|
22642
|
+
n && e.comments != null && wt(t, e.comments, r, i);
|
|
22643
22643
|
let o = e.body, { length: u } = o;
|
|
22644
22644
|
for (let a = 0; a < u; a++) {
|
|
22645
22645
|
let l = o[a];
|
|
22646
|
-
n && l.comments != null &&
|
|
22646
|
+
n && l.comments != null && wt(t, l.comments, r, i), t.write(r), this[l.type](l, t), t.write(i);
|
|
22647
22647
|
}
|
|
22648
|
-
n && e.trailingComments != null &&
|
|
22648
|
+
n && e.trailingComments != null && wt(t, e.trailingComments, r, i);
|
|
22649
22649
|
},
|
|
22650
22650
|
BlockStatement: Db = /* @__PURE__ */ s(function(e, t) {
|
|
22651
22651
|
let r = t.indent.repeat(t.indentLevel++), { lineEnd: i, writeComments: n } = t, o = r + t.indent;
|
|
22652
22652
|
t.write("{");
|
|
22653
22653
|
let u = e.body;
|
|
22654
22654
|
if (u != null && u.length > 0) {
|
|
22655
|
-
t.write(i), n && e.comments != null &&
|
|
22655
|
+
t.write(i), n && e.comments != null && wt(t, e.comments, o, i);
|
|
22656
22656
|
let { length: a } = u;
|
|
22657
22657
|
for (let l = 0; l < a; l++) {
|
|
22658
22658
|
let c = u[l];
|
|
22659
|
-
n && c.comments != null &&
|
|
22659
|
+
n && c.comments != null && wt(t, c.comments, o, i), t.write(o), this[c.type](c, t), t.write(i);
|
|
22660
22660
|
}
|
|
22661
22661
|
t.write(r);
|
|
22662
22662
|
} else
|
|
22663
|
-
n && e.comments != null && (t.write(i),
|
|
22664
|
-
n && e.trailingComments != null &&
|
|
22663
|
+
n && e.comments != null && (t.write(i), wt(t, e.comments, o, i), t.write(r));
|
|
22664
|
+
n && e.trailingComments != null && wt(t, e.trailingComments, o, i), t.write("}"), t.indentLevel--;
|
|
22665
22665
|
}, "BlockStatement"),
|
|
22666
22666
|
ClassBody: Db,
|
|
22667
22667
|
StaticBlock(e, t) {
|
|
@@ -22699,12 +22699,12 @@ times with `settings`, but this has neither"
|
|
|
22699
22699
|
let { cases: a } = e, { length: l } = a;
|
|
22700
22700
|
for (let c = 0; c < l; c++) {
|
|
22701
22701
|
let p = a[c];
|
|
22702
|
-
n && p.comments != null &&
|
|
22702
|
+
n && p.comments != null && wt(t, p.comments, o, i), p.test ? (t.write(o + "case "), this[p.test.type](p.test, t), t.write(":" + i)) :
|
|
22703
22703
|
t.write(o + "default:" + i);
|
|
22704
22704
|
let { consequent: h } = p, { length: f } = h;
|
|
22705
22705
|
for (let d = 0; d < f; d++) {
|
|
22706
22706
|
let m = h[d];
|
|
22707
|
-
n && m.comments != null &&
|
|
22707
|
+
n && m.comments != null && wt(t, m.comments, u, i), t.write(u), this[m.type](m, t), t.write(i);
|
|
22708
22708
|
}
|
|
22709
22709
|
}
|
|
22710
22710
|
t.indentLevel -= 2, t.write(r + "}");
|
|
@@ -22893,18 +22893,18 @@ times with `settings`, but this has neither"
|
|
|
22893
22893
|
ObjectExpression(e, t) {
|
|
22894
22894
|
let r = t.indent.repeat(t.indentLevel++), { lineEnd: i, writeComments: n } = t, o = r + t.indent;
|
|
22895
22895
|
if (t.write("{"), e.properties.length > 0) {
|
|
22896
|
-
t.write(i), n && e.comments != null &&
|
|
22896
|
+
t.write(i), n && e.comments != null && wt(t, e.comments, o, i);
|
|
22897
22897
|
let u = "," + i, { properties: a } = e, { length: l } = a;
|
|
22898
22898
|
for (let c = 0; ; ) {
|
|
22899
22899
|
let p = a[c];
|
|
22900
|
-
if (n && p.comments != null &&
|
|
22900
|
+
if (n && p.comments != null && wt(t, p.comments, o, i), t.write(o), this[p.type](p, t), ++c < l)
|
|
22901
22901
|
t.write(u);
|
|
22902
22902
|
else
|
|
22903
22903
|
break;
|
|
22904
22904
|
}
|
|
22905
|
-
t.write(i), n && e.trailingComments != null &&
|
|
22906
|
-
} else n ? e.comments != null ? (t.write(i),
|
|
22907
|
-
write(r + "}")) : e.trailingComments != null ? (t.write(i),
|
|
22905
|
+
t.write(i), n && e.trailingComments != null && wt(t, e.trailingComments, o, i), t.write(r + "}");
|
|
22906
|
+
} else n ? e.comments != null ? (t.write(i), wt(t, e.comments, o, i), e.trailingComments != null && wt(t, e.trailingComments, o, i), t.
|
|
22907
|
+
write(r + "}")) : e.trailingComments != null ? (t.write(i), wt(t, e.trailingComments, o, i), t.write(r + "}")) : t.write("}") : t.write(
|
|
22908
22908
|
"}");
|
|
22909
22909
|
t.indentLevel--;
|
|
22910
22910
|
},
|
|
@@ -29999,7 +29999,7 @@ t Symbol]")
|
|
|
29999
29999
|
"%WeakMapPrototype%": ["WeakMap", "prototype"],
|
|
30000
30000
|
"%WeakSetPrototype%": ["WeakSet", "prototype"]
|
|
30001
30001
|
}, I = Ja(), se = yF(), Me = I.call(V, Array.prototype.concat), N = I.call($, Array.prototype.splice), Oe = I.call(V, String.prototype.
|
|
30002
|
-
replace), Ie = I.call(V, String.prototype.slice), ce = I.call(V, RegExp.prototype.exec),
|
|
30002
|
+
replace), Ie = I.call(V, String.prototype.slice), ce = I.call(V, RegExp.prototype.exec), Et = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,
|
|
30003
30003
|
Te = /\\(\\)?/g, Z = /* @__PURE__ */ s(function(ee) {
|
|
30004
30004
|
var pe = Ie(ee, 0, 1), de = Ie(ee, -1);
|
|
30005
30005
|
if (pe === "%" && de !== "%")
|
|
@@ -30007,7 +30007,7 @@ t Symbol]")
|
|
|
30007
30007
|
if (de === "%" && pe !== "%")
|
|
30008
30008
|
throw new l("invalid intrinsic syntax, expected opening `%`");
|
|
30009
30009
|
var ge = [];
|
|
30010
|
-
return Oe(ee,
|
|
30010
|
+
return Oe(ee, Et, function(He, ht, Re, Wt) {
|
|
30011
30011
|
ge[ge.length] = Re ? Oe(Wt, Te, "$1") : ht || He;
|
|
30012
30012
|
}), ge;
|
|
30013
30013
|
}, "stringToPath3"), fe = /* @__PURE__ */ s(function(ee, pe) {
|
|
@@ -31328,9 +31328,9 @@ var HF = P((rne, Ka) => {
|
|
|
31328
31328
|
return y ^ F;
|
|
31329
31329
|
});
|
|
31330
31330
|
}, p.prototype.xor = c.prototype.xor = l.prototype.xor;
|
|
31331
|
-
var ce = 1 << 30,
|
|
31331
|
+
var ce = 1 << 30, Et = (t & -t) * (t & -t) | ce;
|
|
31332
31332
|
function Te(x) {
|
|
31333
|
-
var y = x.value, F = typeof y == "number" ? y | ce : typeof y == "bigint" ? y | BigInt(ce) : y[0] + y[1] * t |
|
|
31333
|
+
var y = x.value, F = typeof y == "number" ? y | ce : typeof y == "bigint" ? y | BigInt(ce) : y[0] + y[1] * t | Et;
|
|
31334
31334
|
return F & -F;
|
|
31335
31335
|
}
|
|
31336
31336
|
s(Te, "roughLOB");
|
|
@@ -33160,23 +33160,23 @@ var z_ = P((Gse, W_) => {
|
|
|
33160
33160
|
|
|
33161
33161
|
// ../node_modules/cli-table3/src/debug.js
|
|
33162
33162
|
var ml = P((moe, ak) => {
|
|
33163
|
-
var gg = [], uk = 0,
|
|
33163
|
+
var gg = [], uk = 0, xt = /* @__PURE__ */ s((e, t) => {
|
|
33164
33164
|
uk >= t && gg.push(e);
|
|
33165
33165
|
}, "debug");
|
|
33166
|
-
|
|
33167
|
-
|
|
33168
|
-
|
|
33169
|
-
|
|
33166
|
+
xt.WARN = 1;
|
|
33167
|
+
xt.INFO = 2;
|
|
33168
|
+
xt.DEBUG = 3;
|
|
33169
|
+
xt.reset = () => {
|
|
33170
33170
|
gg = [];
|
|
33171
33171
|
};
|
|
33172
|
-
|
|
33172
|
+
xt.setDebugLevel = (e) => {
|
|
33173
33173
|
uk = e;
|
|
33174
33174
|
};
|
|
33175
|
-
|
|
33176
|
-
|
|
33177
|
-
|
|
33178
|
-
|
|
33179
|
-
ak.exports =
|
|
33175
|
+
xt.warn = (e) => xt(e, xt.WARN);
|
|
33176
|
+
xt.info = (e) => xt(e, xt.INFO);
|
|
33177
|
+
xt.debug = (e) => xt(e, xt.DEBUG);
|
|
33178
|
+
xt.debugMessages = () => gg;
|
|
33179
|
+
ak.exports = xt;
|
|
33180
33180
|
});
|
|
33181
33181
|
|
|
33182
33182
|
// ../node_modules/cli-table3/src/utils.js
|
|
@@ -34508,7 +34508,7 @@ gi(TG, {
|
|
|
34508
34508
|
buildIndexStandalone: () => Tg,
|
|
34509
34509
|
buildStaticStandalone: () => Zf,
|
|
34510
34510
|
experimental_MockUniversalStore: () => vl,
|
|
34511
|
-
experimental_UniversalStore: () =>
|
|
34511
|
+
experimental_UniversalStore: () => yt,
|
|
34512
34512
|
experimental_getStatusStore: () => RT,
|
|
34513
34513
|
experimental_getTestProviderStore: () => qT,
|
|
34514
34514
|
experimental_loadStorybook: () => bl,
|
|
@@ -34719,7 +34719,7 @@ gn();
|
|
|
34719
34719
|
|
|
34720
34720
|
// ../node_modules/tiny-invariant/dist/esm/tiny-invariant.js
|
|
34721
34721
|
var iB = process.env.NODE_ENV === "production", Pl = "Invariant failed";
|
|
34722
|
-
function
|
|
34722
|
+
function bt(e, t) {
|
|
34723
34723
|
if (!e) {
|
|
34724
34724
|
if (iB)
|
|
34725
34725
|
throw new Error(Pl);
|
|
@@ -34727,7 +34727,7 @@ function Et(e, t) {
|
|
|
34727
34727
|
throw new Error(i);
|
|
34728
34728
|
}
|
|
34729
34729
|
}
|
|
34730
|
-
s(
|
|
34730
|
+
s(bt, "invariant");
|
|
34731
34731
|
|
|
34732
34732
|
// src/core-server/utils/StoryIndexGenerator.ts
|
|
34733
34733
|
var Df = K(kt(), 1), ia = K(w0(), 1);
|
|
@@ -34927,7 +34927,7 @@ e)))) : e, "makeAbsolute"), Lr = class {
|
|
|
34927
34927
|
await Promise.all(
|
|
34928
34928
|
this.specifiers.map(async (i) => {
|
|
34929
34929
|
let n = this.specifierToCache.get(i);
|
|
34930
|
-
return
|
|
34930
|
+
return bt(
|
|
34931
34931
|
n,
|
|
34932
34932
|
`specifier does not have a matching cache entry in specifierToCache: ${JSON.stringify(
|
|
34933
34933
|
i
|
|
@@ -34967,7 +34967,7 @@ e)))) : e, "makeAbsolute"), Lr = class {
|
|
|
34967
34967
|
let r = {};
|
|
34968
34968
|
return { entries: this.specifiers.flatMap((n) => {
|
|
34969
34969
|
let o = this.specifierToCache.get(n);
|
|
34970
|
-
return
|
|
34970
|
+
return bt(
|
|
34971
34971
|
o,
|
|
34972
34972
|
`specifier does not have a matching cache entry in specifierToCache: ${JSON.stringify(
|
|
34973
34973
|
n
|
|
@@ -35010,12 +35010,12 @@ e)))) : e, "makeAbsolute"), Lr = class {
|
|
|
35010
35010
|
async extractStories(t, r, i = []) {
|
|
35011
35011
|
let n = (0, Pe.relative)(this.options.workingDir, r), o = Ze((0, rn.normalizeStoryPath)(n)), u = /* @__PURE__ */ s((g) => {
|
|
35012
35012
|
let b = Kl(o, t, g);
|
|
35013
|
-
return
|
|
35013
|
+
return bt(
|
|
35014
35014
|
b,
|
|
35015
35015
|
"makeTitle created an undefined title. This happens when the fileName doesn't match any specifier from main.js"
|
|
35016
35016
|
), b;
|
|
35017
35017
|
}, "defaultMakeTitle"), a = this.options.indexers.find((g) => g.test.exec(r));
|
|
35018
|
-
|
|
35018
|
+
bt(a, `No matching indexer found for ${r}`);
|
|
35019
35019
|
let l = await a.createIndex(r, { makeTitle: u }), c = await Vg("tsconfig.json", { cwd: this.options.workingDir }), p = ia.loadConfig(c),
|
|
35020
35020
|
h;
|
|
35021
35021
|
p.resultType === "success" && (h = ia.createMatchPath(p.absoluteBaseUrl, p.paths, [
|
|
@@ -35080,7 +35080,7 @@ e)))) : e, "makeAbsolute"), Lr = class {
|
|
|
35080
35080
|
) && (d = C);
|
|
35081
35081
|
}
|
|
35082
35082
|
f = [L, ...h.filter((C) => C !== L)];
|
|
35083
|
-
}),
|
|
35083
|
+
}), bt(
|
|
35084
35084
|
d,
|
|
35085
35085
|
Df.dedent`
|
|
35086
35086
|
Could not find or load CSF file at path "${c.of}" referenced by \`of={}\` in docs file "${n}".
|
|
@@ -35096,7 +35096,7 @@ e)))) : e, "makeAbsolute"), Lr = class {
|
|
|
35096
35096
|
k.dependents.push(r);
|
|
35097
35097
|
});
|
|
35098
35098
|
let m = d?.title || Kl(u, t, c.title);
|
|
35099
|
-
|
|
35099
|
+
bt(
|
|
35100
35100
|
m,
|
|
35101
35101
|
"makeTitle created an undefined title. This happens when a specifier's doesn't have any matches in its fileName"
|
|
35102
35102
|
);
|
|
@@ -35207,7 +35207,7 @@ Consider changing the story name.`,
|
|
|
35207
35207
|
entries: l
|
|
35208
35208
|
}, { storyIndex: this.lastIndex, stats: this.lastStats };
|
|
35209
35209
|
} catch (o) {
|
|
35210
|
-
throw this.lastError = o == null || o instanceof Error ? o : void 0,
|
|
35210
|
+
throw this.lastError = o == null || o instanceof Error ? o : void 0, bt(this.lastError), nn.logger.warn(`\u{1F6A8} ${this.lastError.toString()}`),
|
|
35211
35211
|
this.lastError;
|
|
35212
35212
|
}
|
|
35213
35213
|
}
|
|
@@ -35220,7 +35220,7 @@ Consider changing the story name.`,
|
|
|
35220
35220
|
}
|
|
35221
35221
|
invalidate(t, r, i) {
|
|
35222
35222
|
let n = Ze((0, Pe.resolve)(this.options.workingDir, r)), o = this.specifierToCache.get(t);
|
|
35223
|
-
|
|
35223
|
+
bt(
|
|
35224
35224
|
o,
|
|
35225
35225
|
`specifier does not have a matching cache entry in specifierToCache: ${JSON.stringify(
|
|
35226
35226
|
t
|
|
@@ -35301,45 +35301,48 @@ var Vv = require("node:fs/promises"), Xs = require("node:path"), Uv = require("s
|
|
|
35301
35301
|
Af = K(Fr(), 1);
|
|
35302
35302
|
|
|
35303
35303
|
// src/core-server/utils/server-statics.ts
|
|
35304
|
-
var Gs = require("node:fs"),
|
|
35304
|
+
var Gs = require("node:fs"), Dt = require("node:path"), Lv = require("storybook/internal/common"), vf = require("storybook/internal/node-logger"),
|
|
35305
35305
|
oa = K(Fr(), 1), Mv = K(Nv(), 1), jv = K(kt(), 1);
|
|
35306
35306
|
async function qv(e, t) {
|
|
35307
35307
|
let r = await t.presets.apply("staticDirs") ?? [], i = await t.presets.apply("favicon");
|
|
35308
|
-
r.map((
|
|
35308
|
+
r.map((u) => {
|
|
35309
35309
|
try {
|
|
35310
|
-
let { staticDir:
|
|
35311
|
-
if (
|
|
35312
|
-
`=> Serving static files from ${oa.default.cyan(
|
|
35313
|
-
), (0, Gs.existsSync)(
|
|
35314
|
-
let
|
|
35315
|
-
e.use(
|
|
35316
|
-
|
|
35310
|
+
let { staticDir: a, staticPath: l, targetEndpoint: c } = wf(u, t.configDir);
|
|
35311
|
+
if (c.startsWith("/sb-") || vf.logger.info(
|
|
35312
|
+
`=> Serving static files from ${oa.default.cyan(a)} at ${oa.default.cyan(c)}`
|
|
35313
|
+
), (0, Gs.existsSync)(l) && (0, Gs.statSync)(l).isFile()) {
|
|
35314
|
+
let p = (0, Dt.resolve)(l, ".."), h = (0, Dt.basename)(l);
|
|
35315
|
+
e.use(c, (f, d, m) => {
|
|
35316
|
+
f.url = `/${h}`, bf(p, {
|
|
35317
35317
|
dev: !0,
|
|
35318
35318
|
etag: !0,
|
|
35319
35319
|
extensions: []
|
|
35320
|
-
})(
|
|
35320
|
+
})(f, d, m);
|
|
35321
35321
|
});
|
|
35322
35322
|
return;
|
|
35323
35323
|
}
|
|
35324
35324
|
e.use(
|
|
35325
|
-
|
|
35326
|
-
bf(
|
|
35325
|
+
c,
|
|
35326
|
+
bf(l, {
|
|
35327
35327
|
dev: !0,
|
|
35328
35328
|
etag: !0,
|
|
35329
35329
|
extensions: []
|
|
35330
35330
|
})
|
|
35331
35331
|
);
|
|
35332
|
-
} catch (
|
|
35333
|
-
|
|
35334
|
-
}
|
|
35335
|
-
})
|
|
35336
|
-
|
|
35337
|
-
|
|
35338
|
-
|
|
35339
|
-
|
|
35340
|
-
|
|
35341
|
-
|
|
35342
|
-
|
|
35332
|
+
} catch (a) {
|
|
35333
|
+
a instanceof Error && vf.logger.warn(a.message);
|
|
35334
|
+
}
|
|
35335
|
+
});
|
|
35336
|
+
let n = (0, Dt.resolve)(i, ".."), o = (0, Dt.basename)(i);
|
|
35337
|
+
e.use("/", (u, a, l) => {
|
|
35338
|
+
if (u.url === `/${o}`)
|
|
35339
|
+
return bf(n, {
|
|
35340
|
+
dev: !0,
|
|
35341
|
+
etag: !0,
|
|
35342
|
+
extensions: []
|
|
35343
|
+
})(u, a, l);
|
|
35344
|
+
l();
|
|
35345
|
+
});
|
|
35343
35346
|
}
|
|
35344
35347
|
s(qv, "useStatics");
|
|
35345
35348
|
var bf = /* @__PURE__ */ s((...e) => (t, r, i) => {
|
|
@@ -35348,8 +35351,8 @@ var bf = /* @__PURE__ */ s((...e) => (t, r, i) => {
|
|
|
35348
35351
|
} : void 0;
|
|
35349
35352
|
(0, Mv.default)(...e)(t, r, o);
|
|
35350
35353
|
}, "sirvWorkaround"), Cf = /* @__PURE__ */ s((e) => {
|
|
35351
|
-
let t = e.lastIndexOf(":"), i =
|
|
35352
|
-
|
|
35354
|
+
let t = e.lastIndexOf(":"), i = Dt.win32.isAbsolute(e) && t === 1, n = t !== -1 && !i ? t : e.length, u = (e.substring(n + 1) || "/").split(
|
|
35355
|
+
Dt.sep).join(Dt.posix.sep), a = e.substring(0, n), l = (0, Dt.isAbsolute)(a) ? a : `./${a}`, c = (0, Dt.resolve)(l), p = u.replace(/^\/?/,
|
|
35353
35356
|
"./"), h = p.substring(1);
|
|
35354
35357
|
if (!(0, Gs.existsSync)(c))
|
|
35355
35358
|
throw new Error(
|
|
@@ -35360,7 +35363,7 @@ var bf = /* @__PURE__ */ s((...e) => (t, r, i) => {
|
|
|
35360
35363
|
);
|
|
35361
35364
|
return { staticDir: l, staticPath: c, targetDir: p, targetEndpoint: h };
|
|
35362
35365
|
}, "parseStaticDir"), wf = /* @__PURE__ */ s((e, t) => {
|
|
35363
|
-
let r = typeof e == "string" ? e : `${e.from}:${e.to}`, i = (0,
|
|
35366
|
+
let r = typeof e == "string" ? e : `${e.from}:${e.to}`, i = (0, Dt.isAbsolute)(r) ? r : (0, Lv.getDirectoryFromWorkingDir)({ configDir: t,
|
|
35364
35367
|
workingDir: process.cwd(), directory: r });
|
|
35365
35368
|
return Cf(i);
|
|
35366
35369
|
}, "mapStaticDir");
|
|
@@ -36057,7 +36060,7 @@ async function rF(e, t, r, i) {
|
|
|
36057
36060
|
return;
|
|
36058
36061
|
}
|
|
36059
36062
|
let { versionCheck: u, versionUpdates: a } = i;
|
|
36060
|
-
|
|
36063
|
+
bt(
|
|
36061
36064
|
!a || a && u,
|
|
36062
36065
|
"versionCheck should be defined when versionUpdates is true"
|
|
36063
36066
|
);
|
|
@@ -36095,7 +36098,7 @@ var qz = "UNIVERSAL_STORE:", ur = {
|
|
|
36095
36098
|
PENDING: "PENDING",
|
|
36096
36099
|
RESOLVED: "RESOLVED",
|
|
36097
36100
|
REJECTED: "REJECTED"
|
|
36098
|
-
},
|
|
36101
|
+
}, yt = class e {
|
|
36099
36102
|
constructor(t, r) {
|
|
36100
36103
|
/** Enable debug logs for this store */
|
|
36101
36104
|
this.debugging = !1;
|
|
@@ -36520,7 +36523,7 @@ var Tm = class {
|
|
|
36520
36523
|
};
|
|
36521
36524
|
function OF(e) {
|
|
36522
36525
|
let t = [new Tm(e)], r = new Ya.Channel({ transports: t, async: !0 });
|
|
36523
|
-
return
|
|
36526
|
+
return yt.__prepare(r, yt.Environment.SERVER), r;
|
|
36524
36527
|
}
|
|
36525
36528
|
s(OF, "getServerChannel");
|
|
36526
36529
|
|
|
@@ -36644,7 +36647,7 @@ async function p_(e) {
|
|
|
36644
36647
|
i.use(hm({ level: 1 })), typeof e.extendServer == "function" && e.extendServer(t), i.use(RF(r?.crossOriginIsolated ?? !1)), i.use(iF()), qF(
|
|
36645
36648
|
e.configDir)(i);
|
|
36646
36649
|
let { port: a, host: l, initialPath: c } = e;
|
|
36647
|
-
|
|
36650
|
+
bt(a, "expected options to have a port");
|
|
36648
36651
|
let p = e.https ? "https" : "http", { address: h, networkAddress: f } = i_(a, l, p, c);
|
|
36649
36652
|
if (!r?.builder)
|
|
36650
36653
|
throw new c_.MissingBuilderError();
|
|
@@ -37809,7 +37812,7 @@ s(gT, "warnWhenUsingArgTypesRegex");
|
|
|
37809
37812
|
// src/core-server/build-dev.ts
|
|
37810
37813
|
async function kg(e) {
|
|
37811
37814
|
let { packageJson: t, versionUpdates: r } = e, { storybookVersion: i, previewConfigPath: n } = e, o = (0, Wi.resolve)(e.configDir);
|
|
37812
|
-
t ? (
|
|
37815
|
+
t ? (bt(
|
|
37813
37816
|
t.version !== void 0,
|
|
37814
37817
|
`Expected package.json#version to be defined in the "${t.name}" package}`
|
|
37815
37818
|
), i = t.version, n = (0, ut.getConfigInfo)(t, o).previewConfig ?? void 0) : i || (i = ut.versions.storybook);
|
|
@@ -38008,15 +38011,15 @@ var _T = AG;
|
|
|
38008
38011
|
|
|
38009
38012
|
// src/shared/universal-store/mock.ts
|
|
38010
38013
|
var kT = require("storybook/internal/channels"), TT = K(kt(), 1);
|
|
38011
|
-
var vl = class e extends
|
|
38014
|
+
var vl = class e extends yt {
|
|
38012
38015
|
static {
|
|
38013
38016
|
s(this, "MockUniversalStore");
|
|
38014
38017
|
}
|
|
38015
38018
|
constructor(t, r) {
|
|
38016
|
-
|
|
38019
|
+
yt.isInternalConstructing = !0, super(
|
|
38017
38020
|
{ ...t, leader: !0 },
|
|
38018
|
-
{ channel: new kT.Channel({}), environment:
|
|
38019
|
-
),
|
|
38021
|
+
{ channel: new kT.Channel({}), environment: yt.Environment.MOCK }
|
|
38022
|
+
), yt.isInternalConstructing = !1, typeof r?.fn == "function" && (this.testUtils = r, this.getState = r.fn(this.getState), this.setState =
|
|
38020
38023
|
r.fn(this.setState), this.subscribe = r.fn(this.subscribe), this.onStateChange = r.fn(this.onStateChange), this.send = r.fn(this.send));
|
|
38021
38024
|
}
|
|
38022
38025
|
/** Create a mock universal store. This is just an alias for the constructor */
|
|
@@ -38262,7 +38265,7 @@ s(PT, "createStatusStore");
|
|
|
38262
38265
|
|
|
38263
38266
|
// src/core-server/stores/status.ts
|
|
38264
38267
|
var _G = PT({
|
|
38265
|
-
universalStatusStore:
|
|
38268
|
+
universalStatusStore: yt.create({
|
|
38266
38269
|
...IT,
|
|
38267
38270
|
/*
|
|
38268
38271
|
This is a temporary workaround, to ensure that the store is not created in the
|
|
@@ -38344,7 +38347,7 @@ s(MT, "createTestProviderStore");
|
|
|
38344
38347
|
|
|
38345
38348
|
// src/core-server/stores/test-provider.ts
|
|
38346
38349
|
var kG = MT({
|
|
38347
|
-
universalTestProviderStore:
|
|
38350
|
+
universalTestProviderStore: yt.create({
|
|
38348
38351
|
...LT,
|
|
38349
38352
|
/*
|
|
38350
38353
|
This is a temporary workaround, to ensure that the store is not created in the
|