storybook 9.0.0-beta.5 → 9.0.0-beta.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.
Files changed (36) hide show
  1. package/dist/bin/index.cjs +44 -44
  2. package/dist/bin/index.js +44 -44
  3. package/dist/builder-manager/index.cjs +15 -5
  4. package/dist/builder-manager/index.js +15 -4
  5. package/dist/cli/bin/index.cjs +1 -1
  6. package/dist/cli/bin/index.js +1 -1
  7. package/dist/cli/index.cjs +1 -1
  8. package/dist/cli/index.js +1 -1
  9. package/dist/client-logger/index.d.ts +2 -1
  10. package/dist/common/index.cjs +445 -445
  11. package/dist/common/index.d.ts +1 -1
  12. package/dist/common/index.js +424 -424
  13. package/dist/core-server/index.cjs +15 -11
  14. package/dist/core-server/index.d.ts +22 -22
  15. package/dist/core-server/index.js +15 -10
  16. package/dist/core-server/presets/common-manager.js +8 -8
  17. package/dist/core-server/presets/common-preset.cjs +4 -4
  18. package/dist/core-server/presets/common-preset.js +4 -4
  19. package/dist/manager/globals-runtime.js +9190 -9167
  20. package/dist/manager/runtime.js +1151 -1149
  21. package/dist/manager-api/index.cjs +1046 -1023
  22. package/dist/manager-api/index.d.ts +12 -1
  23. package/dist/manager-api/index.js +649 -626
  24. package/dist/preview/runtime.js +1832 -1832
  25. package/dist/preview-api/index.cjs +8 -8
  26. package/dist/preview-api/index.js +8 -8
  27. package/dist/test/index.d.ts +2 -6
  28. package/dist/test/index.js +2818 -2818
  29. package/dist/test/preview.cjs +648 -648
  30. package/dist/test/preview.js +837 -837
  31. package/dist/test/spy.cjs +112 -112
  32. package/dist/test/spy.d.ts +2 -6
  33. package/dist/test/spy.js +104 -104
  34. package/dist/types/index.cjs +4 -4
  35. package/dist/types/index.d.ts +2687 -2594
  36. package/package.json +7 -6
@@ -49,11 +49,11 @@ var Va = we((p_, Wa) => {
49
49
  Wa.exports = function() {
50
50
  function e(i, r, n, l, u, c) {
51
51
  if (c !== ey) {
52
- var p = new Error(
52
+ var d = new Error(
53
53
  "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. \
54
54
  Read more at http://fb.me/use-check-prop-types"
55
55
  );
56
- throw p.name = "Invariant Violation", p;
56
+ throw d.name = "Invariant Violation", d;
57
57
  }
58
58
  }
59
59
  a(e, "shim"), e.isRequired = e;
@@ -169,10 +169,10 @@ var Ga = we((b_, Ua) => {
169
169
  "Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings."
170
170
  );
171
171
  else {
172
- var p = [o, i, r, n, l, u], d = 0;
172
+ var d = [o, i, r, n, l, u], p = 0;
173
173
  c = new Error(
174
174
  t.replace(/%s/g, function() {
175
- return p[d++];
175
+ return d[p++];
176
176
  })
177
177
  ), c.name = "Invariant Violation";
178
178
  }
@@ -195,12 +195,12 @@ var Ya = we((x_, qa) => {
195
195
  var l = Object.keys(t), u = Object.keys(o);
196
196
  if (l.length !== u.length)
197
197
  return !1;
198
- for (var c = Object.prototype.hasOwnProperty.bind(o), p = 0; p < l.length; p++) {
199
- var d = l[p];
200
- if (!c(d))
198
+ for (var c = Object.prototype.hasOwnProperty.bind(o), d = 0; d < l.length; d++) {
199
+ var p = l[d];
200
+ if (!c(p))
201
201
  return !1;
202
- var m = t[d], g = o[d];
203
- if (n = i ? i.call(r, m, g, d) : void 0, n === !1 || n === void 0 && m !== g)
202
+ var m = t[p], h = o[p];
203
+ if (n = i ? i.call(r, m, h, p) : void 0, n === !1 || n === void 0 && m !== h)
204
204
  return !1;
205
205
  }
206
206
  return !0;
@@ -221,25 +221,25 @@ var ki = we((zl, _i) => {
221
221
  })(function() {
222
222
  var e, t, o;
223
223
  return (/* @__PURE__ */ a(function i(r, n, l) {
224
- function u(d, m) {
225
- if (!n[d]) {
226
- if (!r[d]) {
227
- var g = typeof mo == "function" && mo;
228
- if (!m && g) return g(d, !0);
229
- if (c) return c(d, !0);
230
- var b = new Error("Cannot find module '" + d + "'");
224
+ function u(p, m) {
225
+ if (!n[p]) {
226
+ if (!r[p]) {
227
+ var h = typeof mo == "function" && mo;
228
+ if (!m && h) return h(p, !0);
229
+ if (c) return c(p, !0);
230
+ var b = new Error("Cannot find module '" + p + "'");
231
231
  throw b.code = "MODULE_NOT_FOUND", b;
232
232
  }
233
- var f = n[d] = { exports: {} };
234
- r[d][0].call(f.exports, function(y) {
235
- var S = r[d][1][y];
236
- return u(S || y);
233
+ var f = n[p] = { exports: {} };
234
+ r[p][0].call(f.exports, function(y) {
235
+ var I = r[p][1][y];
236
+ return u(I || y);
237
237
  }, f, f.exports, i, r, n, l);
238
238
  }
239
- return n[d].exports;
239
+ return n[p].exports;
240
240
  }
241
241
  a(u, "s");
242
- for (var c = typeof mo == "function" && mo, p = 0; p < l.length; p++) u(l[p]);
242
+ for (var c = typeof mo == "function" && mo, d = 0; d < l.length; d++) u(l[d]);
243
243
  return u;
244
244
  }, "e"))({ 1: [function(i, r, n) {
245
245
  r.exports = function(l) {
@@ -260,9 +260,9 @@ var ki = we((zl, _i) => {
260
260
  if (c = this.indexOf(u), c >= 0)
261
261
  return this.lastItem = this.list[c], this.list[c].val;
262
262
  }, l.prototype.set = function(u, c) {
263
- var p;
264
- return this.lastItem && this.isEqual(this.lastItem.key, u) ? (this.lastItem.val = c, this) : (p = this.indexOf(u), p >= 0 ? (this.lastItem =
265
- this.list[p], this.list[p].val = c, this) : (this.lastItem = { key: u, val: c }, this.list.push(this.lastItem), this.size++, this));
263
+ var d;
264
+ return this.lastItem && this.isEqual(this.lastItem.key, u) ? (this.lastItem.val = c, this) : (d = this.indexOf(u), d >= 0 ? (this.lastItem =
265
+ this.list[d], this.list[d].val = c, this) : (this.lastItem = { key: u, val: c }, this.list.push(this.lastItem), this.size++, this));
266
266
  }, l.prototype.delete = function(u) {
267
267
  var c;
268
268
  if (this.lastItem && this.isEqual(this.lastItem.key, u) && (this.lastItem = void 0), c = this.indexOf(u), c >= 0)
@@ -272,9 +272,9 @@ var ki = we((zl, _i) => {
272
272
  return this.lastItem && this.isEqual(this.lastItem.key, u) ? !0 : (c = this.indexOf(u), c >= 0 ? (this.lastItem = this.list[c], !0) :
273
273
  !1);
274
274
  }, l.prototype.forEach = function(u, c) {
275
- var p;
276
- for (p = 0; p < this.size; p++)
277
- u.call(c || this, this.list[p].val, this.list[p].key, this);
275
+ var d;
276
+ for (d = 0; d < this.size; d++)
277
+ u.call(c || this, this.list[d].val, this.list[d].key, this);
278
278
  }, l.prototype.indexOf = function(u) {
279
279
  var c;
280
280
  for (c = 0; c < this.size; c++)
@@ -286,14 +286,14 @@ var ki = we((zl, _i) => {
286
286
  }, r.exports = l;
287
287
  }, {}], 3: [function(i, r, n) {
288
288
  var l = i("map-or-similar");
289
- r.exports = function(d) {
290
- var m = new l(!1), g = [];
289
+ r.exports = function(p) {
290
+ var m = new l(!1), h = [];
291
291
  return function(b) {
292
292
  var f = /* @__PURE__ */ a(function() {
293
- var y = m, S, E, h = arguments.length - 1, v = Array(h + 1), I = !0, w;
294
- if ((f.numArgs || f.numArgs === 0) && f.numArgs !== h + 1)
293
+ var y = m, I, E, g = arguments.length - 1, v = Array(g + 1), S = !0, w;
294
+ if ((f.numArgs || f.numArgs === 0) && f.numArgs !== g + 1)
295
295
  throw new Error("Memoizerific functions should always be called with the same number of arguments");
296
- for (w = 0; w < h; w++) {
296
+ for (w = 0; w < g; w++) {
297
297
  if (v[w] = {
298
298
  cacheItem: y,
299
299
  arg: arguments[w]
@@ -301,41 +301,41 @@ var ki = we((zl, _i) => {
301
301
  y = y.get(arguments[w]);
302
302
  continue;
303
303
  }
304
- I = !1, S = new l(!1), y.set(arguments[w], S), y = S;
304
+ S = !1, I = new l(!1), y.set(arguments[w], I), y = I;
305
305
  }
306
- return I && (y.has(arguments[h]) ? E = y.get(arguments[h]) : I = !1), I || (E = b.apply(null, arguments), y.set(arguments[h], E)),
307
- d > 0 && (v[h] = {
306
+ return S && (y.has(arguments[g]) ? E = y.get(arguments[g]) : S = !1), S || (E = b.apply(null, arguments), y.set(arguments[g], E)),
307
+ p > 0 && (v[g] = {
308
308
  cacheItem: y,
309
- arg: arguments[h]
310
- }, I ? u(g, v) : g.push(v), g.length > d && c(g.shift())), f.wasMemoized = I, f.numArgs = h + 1, E;
309
+ arg: arguments[g]
310
+ }, S ? u(h, v) : h.push(v), h.length > p && c(h.shift())), f.wasMemoized = S, f.numArgs = g + 1, E;
311
311
  }, "memoizerific");
312
- return f.limit = d, f.wasMemoized = !1, f.cache = m, f.lru = g, f;
312
+ return f.limit = p, f.wasMemoized = !1, f.cache = m, f.lru = h, f;
313
313
  };
314
314
  };
315
- function u(d, m) {
316
- var g = d.length, b = m.length, f, y, S;
317
- for (y = 0; y < g; y++) {
318
- for (f = !0, S = 0; S < b; S++)
319
- if (!p(d[y][S].arg, m[S].arg)) {
315
+ function u(p, m) {
316
+ var h = p.length, b = m.length, f, y, I;
317
+ for (y = 0; y < h; y++) {
318
+ for (f = !0, I = 0; I < b; I++)
319
+ if (!d(p[y][I].arg, m[I].arg)) {
320
320
  f = !1;
321
321
  break;
322
322
  }
323
323
  if (f)
324
324
  break;
325
325
  }
326
- d.push(d.splice(y, 1)[0]);
326
+ p.push(p.splice(y, 1)[0]);
327
327
  }
328
328
  a(u, "moveToMostRecentLru");
329
- function c(d) {
330
- var m = d.length, g = d[m - 1], b, f;
331
- for (g.cacheItem.delete(g.arg), f = m - 2; f >= 0 && (g = d[f], b = g.cacheItem.get(g.arg), !b || !b.size); f--)
332
- g.cacheItem.delete(g.arg);
329
+ function c(p) {
330
+ var m = p.length, h = p[m - 1], b, f;
331
+ for (h.cacheItem.delete(h.arg), f = m - 2; f >= 0 && (h = p[f], b = h.cacheItem.get(h.arg), !b || !b.size); f--)
332
+ h.cacheItem.delete(h.arg);
333
333
  }
334
334
  a(c, "removeCachedResult");
335
- function p(d, m) {
336
- return d === m || d !== d && m !== m;
335
+ function d(p, m) {
336
+ return p === m || p !== p && m !== m;
337
337
  }
338
- a(p, "isEqual");
338
+ a(d, "isEqual");
339
339
  }, { "map-or-similar": 1 }] }, {}, [3])(3);
340
340
  });
341
341
  });
@@ -563,17 +563,17 @@ var Di = we((Cr) => {
563
563
  var qb = 20, Yb = "[]", Qb = "[", Xb = "]", Zb = ".";
564
564
  function jl(e, t, o = 0, i, r) {
565
565
  let { nestingSyntax: n = Rt.defaultOptions.nestingSyntax, arrayRepeat: l = Rt.defaultOptions.arrayRepeat, arrayRepeatSyntax: u = Rt.defaultOptions.
566
- arrayRepeatSyntax, nesting: c = Rt.defaultOptions.nesting, delimiter: p = Rt.defaultOptions.delimiter, valueSerializer: d = Rt.defaultOptions.
567
- valueSerializer, shouldSerializeObject: m = Rt.defaultOptions.shouldSerializeObject } = t, g = typeof p == "number" ? String.fromCharCode(
568
- p) : p, b = r === !0 && l, f = n === "dot" || n === "js" && !r;
566
+ arrayRepeatSyntax, nesting: c = Rt.defaultOptions.nesting, delimiter: d = Rt.defaultOptions.delimiter, valueSerializer: p = Rt.defaultOptions.
567
+ valueSerializer, shouldSerializeObject: m = Rt.defaultOptions.shouldSerializeObject } = t, h = typeof d == "number" ? String.fromCharCode(
568
+ d) : d, b = r === !0 && l, f = n === "dot" || n === "js" && !r;
569
569
  if (o > qb)
570
570
  return "";
571
- let y = "", S = !0, E = !1;
572
- for (let h in e) {
573
- let v = e[h], I;
574
- i ? (I = i, b ? u === "bracket" && (I += Yb) : f ? (I += Zb, I += h) : (I += Qb, I += h, I += Xb)) : I = h, S || (y += g), typeof v ==
575
- "object" && v !== null && !m(v) ? (E = v.pop !== void 0, (c || l && E) && (y += jl(v, t, o + 1, I, E))) : (y += (0, $b.encodeString)(I),
576
- y += "=", y += d(v, h)), S && (S = !1);
571
+ let y = "", I = !0, E = !1;
572
+ for (let g in e) {
573
+ let v = e[g], S;
574
+ i ? (S = i, b ? u === "bracket" && (S += Yb) : f ? (S += Zb, S += g) : (S += Qb, S += g, S += Xb)) : S = g, I || (y += h), typeof v ==
575
+ "object" && v !== null && !m(v) ? (E = v.pop !== void 0, (c || l && E) && (y += jl(v, t, o + 1, S, E))) : (y += (0, $b.encodeString)(S),
576
+ y += "=", y += p(v, g)), I && (I = !1);
577
577
  }
578
578
  return y;
579
579
  }
@@ -581,7 +581,7 @@ var Di = we((Cr) => {
581
581
  });
582
582
 
583
583
  // ../node_modules/fast-decode-uri-component/index.js
584
- var Gl = we((rA, Ul) => {
584
+ var Gl = we((nA, Ul) => {
585
585
  "use strict";
586
586
  var Kl = 12, Jb = 0, Mi = [
587
587
  // The first part of the table maps bytes to character to a transition.
@@ -970,8 +970,8 @@ var Gl = we((rA, Ul) => {
970
970
  var t = e.indexOf("%");
971
971
  if (t === -1) return e;
972
972
  for (var o = e.length, i = "", r = 0, n = 0, l = t, u = Kl; t > -1 && t < o; ) {
973
- var c = $l(e[t + 1], 4), p = $l(e[t + 2], 0), d = c | p, m = Mi[d];
974
- if (u = Mi[256 + u + m], n = n << 6 | d & Mi[364 + m], u === Kl)
973
+ var c = $l(e[t + 1], 4), d = $l(e[t + 2], 0), p = c | d, m = Mi[p];
974
+ if (u = Mi[256 + u + m], n = n << 6 | p & Mi[364 + m], u === Kl)
975
975
  i += e.slice(r, l), i += n <= 65535 ? String.fromCharCode(n) : String.fromCharCode(
976
976
  55232 + (n >> 10),
977
977
  56320 + (n & 1023)
@@ -1048,16 +1048,16 @@ var Xl = we((dt) => {
1048
1048
  function iv(e, t) {
1049
1049
  let { valueDeserializer: o = Bt.defaultOptions.valueDeserializer, keyDeserializer: i = Bt.defaultOptions.keyDeserializer, arrayRepeatSyntax: r = Bt.
1050
1050
  defaultOptions.arrayRepeatSyntax, nesting: n = Bt.defaultOptions.nesting, arrayRepeat: l = Bt.defaultOptions.arrayRepeat, nestingSyntax: u = Bt.
1051
- defaultOptions.nestingSyntax, delimiter: c = Bt.defaultOptions.delimiter } = t ?? {}, p = typeof c == "string" ? c.charCodeAt(0) : c, d = u ===
1051
+ defaultOptions.nestingSyntax, delimiter: c = Bt.defaultOptions.delimiter } = t ?? {}, d = typeof c == "string" ? c.charCodeAt(0) : c, p = u ===
1052
1052
  "js", m = new Ql();
1053
1053
  if (typeof e != "string")
1054
1054
  return m;
1055
- let g = e.length, b = "", f = -1, y = -1, S = -1, E = m, h, v = "", I = "", w = !1, O = !1, _ = !1, k = !1, T = !1, C = !1, P = !1, D = 0,
1055
+ let h = e.length, b = "", f = -1, y = -1, I = -1, E = m, g, v = "", S = "", w = !1, O = !1, _ = !1, k = !1, T = !1, C = !1, P = !1, D = 0,
1056
1056
  M = -1, N = -1, Z = -1;
1057
- for (let W = 0; W < g + 1; W++) {
1058
- if (D = W !== g ? e.charCodeAt(W) : p, D === p) {
1059
- if (P = y > f, P || (y = W), S !== y - 1 && (I = kr(e, S + 1, M > -1 ? M : y, _, w), v = i(I), h !== void 0 && (E = (0, _r.getDeepObject)(
1060
- E, h, v, d && T, d && C))), P || v !== "") {
1057
+ for (let W = 0; W < h + 1; W++) {
1058
+ if (D = W !== h ? e.charCodeAt(W) : d, D === d) {
1059
+ if (P = y > f, P || (y = W), I !== y - 1 && (S = kr(e, I + 1, M > -1 ? M : y, _, w), v = i(S), g !== void 0 && (E = (0, _r.getDeepObject)(
1060
+ E, g, v, p && T, p && C))), P || v !== "") {
1061
1061
  P && (b = e.slice(y + 1, W), k && (b = b.replace(Yl, " ")), O && (b = (0, ql.default)(b) || b));
1062
1062
  let Q = o(b, v);
1063
1063
  if (l) {
@@ -1066,12 +1066,12 @@ var Xl = we((dt) => {
1066
1066
  } else
1067
1067
  E[v] = Q;
1068
1068
  }
1069
- b = "", f = W, y = W, w = !1, O = !1, _ = !1, k = !1, T = !1, C = !1, M = -1, S = W, E = m, h = void 0, v = "";
1070
- } else D === 93 ? (l && r === "bracket" && Z === 91 && (M = N), n && (u === "index" || d) && y <= f && (S !== N && (I = kr(e, S + 1, W,
1071
- _, w), v = i(I), h !== void 0 && (E = (0, _r.getDeepObject)(E, h, v, void 0, d)), h = v, _ = !1, w = !1), S = W, C = !0, T = !1)) : D ===
1072
- 46 ? n && (u === "dot" || d) && y <= f && (S !== N && (I = kr(e, S + 1, W, _, w), v = i(I), h !== void 0 && (E = (0, _r.getDeepObject)(
1073
- E, h, v, d)), h = v, _ = !1, w = !1), T = !0, C = !1, S = W) : D === 91 ? n && (u === "index" || d) && y <= f && (S !== N && (I = kr(e,
1074
- S + 1, W, _, w), v = i(I), d && h !== void 0 && (E = (0, _r.getDeepObject)(E, h, v, d)), h = v, _ = !1, w = !1, T = !1, C = !0), S = W) :
1069
+ b = "", f = W, y = W, w = !1, O = !1, _ = !1, k = !1, T = !1, C = !1, M = -1, I = W, E = m, g = void 0, v = "";
1070
+ } else D === 93 ? (l && r === "bracket" && Z === 91 && (M = N), n && (u === "index" || p) && y <= f && (I !== N && (S = kr(e, I + 1, W,
1071
+ _, w), v = i(S), g !== void 0 && (E = (0, _r.getDeepObject)(E, g, v, void 0, p)), g = v, _ = !1, w = !1), I = W, C = !0, T = !1)) : D ===
1072
+ 46 ? n && (u === "dot" || p) && y <= f && (I !== N && (S = kr(e, I + 1, W, _, w), v = i(S), g !== void 0 && (E = (0, _r.getDeepObject)(
1073
+ E, g, v, p)), g = v, _ = !1, w = !1), T = !0, C = !1, I = W) : D === 91 ? n && (u === "index" || p) && y <= f && (I !== N && (S = kr(e,
1074
+ I + 1, W, _, w), v = i(S), p && g !== void 0 && (E = (0, _r.getDeepObject)(E, g, v, p)), g = v, _ = !1, w = !1, T = !1, C = !0), I = W) :
1075
1075
  D === 61 ? y <= f ? y = W : O = !0 : D === 43 ? y > f ? k = !0 : _ = !0 : D === 37 && (y > f ? O = !0 : w = !0);
1076
1076
  N = W, Z = D;
1077
1077
  }
@@ -1123,7 +1123,7 @@ var Jl = we((Ze) => {
1123
1123
  });
1124
1124
 
1125
1125
  // ../node_modules/toggle-selection/index.js
1126
- var iu = we((_A, nu) => {
1126
+ var iu = we((kA, nu) => {
1127
1127
  nu.exports = function() {
1128
1128
  var e = document.getSelection();
1129
1129
  if (!e.rangeCount)
@@ -1150,7 +1150,7 @@ var iu = we((_A, nu) => {
1150
1150
  });
1151
1151
 
1152
1152
  // ../node_modules/copy-to-clipboard/index.js
1153
- var lu = we((kA, au) => {
1153
+ var lu = we((OA, au) => {
1154
1154
  "use strict";
1155
1155
  var yv = iu(), su = {
1156
1156
  "text/plain": "Text",
@@ -1169,22 +1169,22 @@ var lu = we((kA, au) => {
1169
1169
  r = yv(), n = document.createRange(), l = document.getSelection(), u = document.createElement("span"), u.textContent = e, u.ariaHidden =
1170
1170
  "true", u.style.all = "unset", u.style.position = "fixed", u.style.top = 0, u.style.clip = "rect(0, 0, 0, 0)", u.style.whiteSpace = "p\
1171
1171
  re", u.style.webkitUserSelect = "text", u.style.MozUserSelect = "text", u.style.msUserSelect = "text", u.style.userSelect = "text", u.addEventListener(
1172
- "copy", function(d) {
1173
- if (d.stopPropagation(), t.format)
1174
- if (d.preventDefault(), typeof d.clipboardData > "u") {
1172
+ "copy", function(p) {
1173
+ if (p.stopPropagation(), t.format)
1174
+ if (p.preventDefault(), typeof p.clipboardData > "u") {
1175
1175
  o && console.warn("unable to use e.clipboardData"), o && console.warn("trying IE specific stuff"), window.clipboardData.clearData();
1176
1176
  var m = su[t.format] || su.default;
1177
1177
  window.clipboardData.setData(m, e);
1178
1178
  } else
1179
- d.clipboardData.clearData(), d.clipboardData.setData(t.format, e);
1180
- t.onCopy && (d.preventDefault(), t.onCopy(d.clipboardData));
1179
+ p.clipboardData.clearData(), p.clipboardData.setData(t.format, e);
1180
+ t.onCopy && (p.preventDefault(), t.onCopy(p.clipboardData));
1181
1181
  }), document.body.appendChild(u), n.selectNodeContents(u), l.addRange(n);
1182
- var p = document.execCommand("copy");
1183
- if (!p)
1182
+ var d = document.execCommand("copy");
1183
+ if (!d)
1184
1184
  throw new Error("copy command was unsuccessful");
1185
1185
  c = !0;
1186
- } catch (d) {
1187
- o && console.error("unable to copy using execCommand: ", d), o && console.warn("trying IE specific stuff");
1186
+ } catch (p) {
1187
+ o && console.error("unable to copy using execCommand: ", p), o && console.warn("trying IE specific stuff");
1188
1188
  try {
1189
1189
  window.clipboardData.setData(t.format || "text", e), t.onCopy && t.onCopy(window.clipboardData), c = !0;
1190
1190
  } catch (m) {
@@ -1302,7 +1302,7 @@ context"), Gr = Symbol.for("react.forward_ref"), qr = Symbol.for("react.suspense
1302
1302
  });
1303
1303
 
1304
1304
  // ../node_modules/downshift/node_modules/react-is/index.js
1305
- var mp = we((aR, fp) => {
1305
+ var mp = we((lR, fp) => {
1306
1306
  "use strict";
1307
1307
  fp.exports = dp();
1308
1308
  });
@@ -1344,25 +1344,25 @@ var Sd = we((jo, Fs) => {
1344
1344
  return Object.prototype.hasOwnProperty.call(i, r);
1345
1345
  }, o.p = "", o(o.s = 0);
1346
1346
  }([function(e, t, o) {
1347
- function i(d) {
1347
+ function i(p) {
1348
1348
  return (i = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(m) {
1349
1349
  return typeof m;
1350
1350
  } : function(m) {
1351
1351
  return m && typeof Symbol == "function" && m.constructor === Symbol && m !== Symbol.prototype ? "symbol" : typeof m;
1352
- })(d);
1352
+ })(p);
1353
1353
  }
1354
1354
  a(i, "n");
1355
- function r(d, m) {
1356
- for (var g = 0; g < m.length; g++) {
1357
- var b = m[g];
1358
- b.enumerable = b.enumerable || !1, b.configurable = !0, "value" in b && (b.writable = !0), Object.defineProperty(d, b.key, b);
1355
+ function r(p, m) {
1356
+ for (var h = 0; h < m.length; h++) {
1357
+ var b = m[h];
1358
+ b.enumerable = b.enumerable || !1, b.configurable = !0, "value" in b && (b.writable = !0), Object.defineProperty(p, b.key, b);
1359
1359
  }
1360
1360
  }
1361
1361
  a(r, "o");
1362
- var n = o(1), l = o(7), u = l.get, c = (l.deepValue, l.isArray), p = function() {
1363
- function d(f, y) {
1364
- var S = y.location, E = S === void 0 ? 0 : S, h = y.distance, v = h === void 0 ? 100 : h, I = y.threshold, w = I === void 0 ? 0.6 :
1365
- I, O = y.maxPatternLength, _ = O === void 0 ? 32 : O, k = y.caseSensitive, T = k !== void 0 && k, C = y.tokenSeparator, P = C === void 0 ?
1362
+ var n = o(1), l = o(7), u = l.get, c = (l.deepValue, l.isArray), d = function() {
1363
+ function p(f, y) {
1364
+ var I = y.location, E = I === void 0 ? 0 : I, g = y.distance, v = g === void 0 ? 100 : g, S = y.threshold, w = S === void 0 ? 0.6 :
1365
+ S, O = y.maxPatternLength, _ = O === void 0 ? 32 : O, k = y.caseSensitive, T = k !== void 0 && k, C = y.tokenSeparator, P = C === void 0 ?
1366
1366
  / +/g : C, D = y.findAllMatches, M = D !== void 0 && D, N = y.minMatchCharLength, Z = N === void 0 ? 1 : N, W = y.id, Q = W === void 0 ?
1367
1367
  null : W, B = y.keys, G = B === void 0 ? [] : B, H = y.shouldSort, re = H === void 0 || H, F = y.getFn, R = F === void 0 ? u : F, L = y.
1368
1368
  sortFn, $ = L === void 0 ? function(fe, Se) {
@@ -1371,103 +1371,103 @@ var Sd = we((jo, Fs) => {
1371
1371
  void 0 && ae, ue = y.includeScore, Ie = ue !== void 0 && ue, ye = y.verbose, Oe = ye !== void 0 && ye;
1372
1372
  (function(fe, Se) {
1373
1373
  if (!(fe instanceof Se)) throw new TypeError("Cannot call a class as a function");
1374
- })(this, d), this.options = { location: E, distance: v, threshold: w, maxPatternLength: _, isCaseSensitive: T, tokenSeparator: P, findAllMatches: M,
1374
+ })(this, p), this.options = { location: E, distance: v, threshold: w, maxPatternLength: _, isCaseSensitive: T, tokenSeparator: P, findAllMatches: M,
1375
1375
  minMatchCharLength: Z, id: Q, keys: G, includeMatches: ce, includeScore: Ie, shouldSort: re, getFn: R, sortFn: $, verbose: Oe, tokenize: ie,
1376
1376
  matchAllTokens: de }, this.setCollection(f), this._processKeys(G);
1377
1377
  }
1378
- a(d, "e");
1379
- var m, g, b;
1380
- return m = d, (g = [{ key: "setCollection", value: /* @__PURE__ */ a(function(f) {
1378
+ a(p, "e");
1379
+ var m, h, b;
1380
+ return m = p, (h = [{ key: "setCollection", value: /* @__PURE__ */ a(function(f) {
1381
1381
  return this.list = f, f;
1382
1382
  }, "value") }, { key: "_processKeys", value: /* @__PURE__ */ a(function(f) {
1383
- if (this._keyWeights = {}, this._keyNames = [], f.length && typeof f[0] == "string") for (var y = 0, S = f.length; y < S; y += 1) {
1383
+ if (this._keyWeights = {}, this._keyNames = [], f.length && typeof f[0] == "string") for (var y = 0, I = f.length; y < I; y += 1) {
1384
1384
  var E = f[y];
1385
1385
  this._keyWeights[E] = 1, this._keyNames.push(E);
1386
1386
  }
1387
1387
  else {
1388
- for (var h = null, v = null, I = 0, w = 0, O = f.length; w < O; w += 1) {
1388
+ for (var g = null, v = null, S = 0, w = 0, O = f.length; w < O; w += 1) {
1389
1389
  var _ = f[w];
1390
1390
  if (!_.hasOwnProperty("name")) throw new Error('Missing "name" property in key object');
1391
1391
  var k = _.name;
1392
1392
  if (this._keyNames.push(k), !_.hasOwnProperty("weight")) throw new Error('Missing "weight" property in key object');
1393
1393
  var T = _.weight;
1394
1394
  if (T < 0 || T > 1) throw new Error('"weight" property in key must bein the range of [0, 1)');
1395
- v = v == null ? T : Math.max(v, T), h = h == null ? T : Math.min(h, T), this._keyWeights[k] = T, I += T;
1395
+ v = v == null ? T : Math.max(v, T), g = g == null ? T : Math.min(g, T), this._keyWeights[k] = T, S += T;
1396
1396
  }
1397
- if (I > 1) throw new Error("Total of weights cannot exceed 1");
1397
+ if (S > 1) throw new Error("Total of weights cannot exceed 1");
1398
1398
  }
1399
1399
  }, "value") }, { key: "search", value: /* @__PURE__ */ a(function(f) {
1400
1400
  var y = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : { limit: !1 };
1401
1401
  this._log(`---------
1402
1402
  Search pattern: "`.concat(f, '"'));
1403
- var S = this._prepareSearchers(f), E = S.tokenSearchers, h = S.fullSearcher, v = this._search(E, h);
1403
+ var I = this._prepareSearchers(f), E = I.tokenSearchers, g = I.fullSearcher, v = this._search(E, g);
1404
1404
  return this._computeScore(v), this.options.shouldSort && this._sort(v), y.limit && typeof y.limit == "number" && (v = v.slice(0, y.
1405
1405
  limit)), this._format(v);
1406
1406
  }, "value") }, { key: "_prepareSearchers", value: /* @__PURE__ */ a(function() {
1407
1407
  var f = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "", y = [];
1408
- if (this.options.tokenize) for (var S = f.split(this.options.tokenSeparator), E = 0, h = S.length; E < h; E += 1) y.push(new n(S[E],
1408
+ if (this.options.tokenize) for (var I = f.split(this.options.tokenSeparator), E = 0, g = I.length; E < g; E += 1) y.push(new n(I[E],
1409
1409
  this.options));
1410
1410
  return { tokenSearchers: y, fullSearcher: new n(f, this.options) };
1411
1411
  }, "value") }, { key: "_search", value: /* @__PURE__ */ a(function() {
1412
- var f = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], y = arguments.length > 1 ? arguments[1] : void 0, S = this.
1413
- list, E = {}, h = [];
1414
- if (typeof S[0] == "string") {
1415
- for (var v = 0, I = S.length; v < I; v += 1) this._analyze({ key: "", value: S[v], record: v, index: v }, { resultMap: E, results: h,
1412
+ var f = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], y = arguments.length > 1 ? arguments[1] : void 0, I = this.
1413
+ list, E = {}, g = [];
1414
+ if (typeof I[0] == "string") {
1415
+ for (var v = 0, S = I.length; v < S; v += 1) this._analyze({ key: "", value: I[v], record: v, index: v }, { resultMap: E, results: g,
1416
1416
  tokenSearchers: f, fullSearcher: y });
1417
- return h;
1417
+ return g;
1418
1418
  }
1419
- for (var w = 0, O = S.length; w < O; w += 1) for (var _ = S[w], k = 0, T = this._keyNames.length; k < T; k += 1) {
1419
+ for (var w = 0, O = I.length; w < O; w += 1) for (var _ = I[w], k = 0, T = this._keyNames.length; k < T; k += 1) {
1420
1420
  var C = this._keyNames[k];
1421
- this._analyze({ key: C, value: this.options.getFn(_, C), record: _, index: w }, { resultMap: E, results: h, tokenSearchers: f, fullSearcher: y });
1421
+ this._analyze({ key: C, value: this.options.getFn(_, C), record: _, index: w }, { resultMap: E, results: g, tokenSearchers: f, fullSearcher: y });
1422
1422
  }
1423
- return h;
1423
+ return g;
1424
1424
  }, "value") }, { key: "_analyze", value: /* @__PURE__ */ a(function(f, y) {
1425
- var S = this, E = f.key, h = f.arrayIndex, v = h === void 0 ? -1 : h, I = f.value, w = f.record, O = f.index, _ = y.tokenSearchers,
1425
+ var I = this, E = f.key, g = f.arrayIndex, v = g === void 0 ? -1 : g, S = f.value, w = f.record, O = f.index, _ = y.tokenSearchers,
1426
1426
  k = _ === void 0 ? [] : _, T = y.fullSearcher, C = y.resultMap, P = C === void 0 ? {} : C, D = y.results, M = D === void 0 ? [] : D;
1427
1427
  (/* @__PURE__ */ a(function N(Z, W, Q, B) {
1428
1428
  if (W != null) {
1429
1429
  if (typeof W == "string") {
1430
1430
  var G = !1, H = -1, re = 0;
1431
- S._log(`
1431
+ I._log(`
1432
1432
  Key: `.concat(E === "" ? "--" : E));
1433
1433
  var F = T.search(W);
1434
- if (S._log('Full text: "'.concat(W, '", score: ').concat(F.score)), S.options.tokenize) {
1435
- for (var R = W.split(S.options.tokenSeparator), L = R.length, $ = [], J = 0, ie = k.length; J < ie; J += 1) {
1434
+ if (I._log('Full text: "'.concat(W, '", score: ').concat(F.score)), I.options.tokenize) {
1435
+ for (var R = W.split(I.options.tokenSeparator), L = R.length, $ = [], J = 0, ie = k.length; J < ie; J += 1) {
1436
1436
  var te = k[J];
1437
- S._log(`
1437
+ I._log(`
1438
1438
  Pattern: "`.concat(te.pattern, '"'));
1439
1439
  for (var de = !1, ae = 0; ae < L; ae += 1) {
1440
1440
  var ce = R[ae], ue = te.search(ce), Ie = {};
1441
- ue.isMatch ? (Ie[ce] = ue.score, G = !0, de = !0, $.push(ue.score)) : (Ie[ce] = 1, S.options.matchAllTokens || $.push(
1442
- 1)), S._log('Token: "'.concat(ce, '", score: ').concat(Ie[ce]));
1441
+ ue.isMatch ? (Ie[ce] = ue.score, G = !0, de = !0, $.push(ue.score)) : (Ie[ce] = 1, I.options.matchAllTokens || $.push(
1442
+ 1)), I._log('Token: "'.concat(ce, '", score: ').concat(Ie[ce]));
1443
1443
  }
1444
1444
  de && (re += 1);
1445
1445
  }
1446
1446
  H = $[0];
1447
1447
  for (var ye = $.length, Oe = 1; Oe < ye; Oe += 1) H += $[Oe];
1448
- H /= ye, S._log("Token score average:", H);
1448
+ H /= ye, I._log("Token score average:", H);
1449
1449
  }
1450
1450
  var fe = F.score;
1451
- H > -1 && (fe = (fe + H) / 2), S._log("Score average:", fe);
1452
- var Se = !S.options.tokenize || !S.options.matchAllTokens || re >= k.length;
1453
- if (S._log(`
1451
+ H > -1 && (fe = (fe + H) / 2), I._log("Score average:", fe);
1452
+ var Se = !I.options.tokenize || !I.options.matchAllTokens || re >= k.length;
1453
+ if (I._log(`
1454
1454
  Check Matches: `.concat(Se)), (G || F.isMatch) && Se) {
1455
1455
  var _e = { key: E, arrayIndex: Z, value: W, score: fe };
1456
- S.options.includeMatches && (_e.matchedIndices = F.matchedIndices);
1456
+ I.options.includeMatches && (_e.matchedIndices = F.matchedIndices);
1457
1457
  var De = P[B];
1458
1458
  De ? De.output.push(_e) : (P[B] = { item: Q, output: [_e] }, M.push(P[B]));
1459
1459
  }
1460
1460
  } else if (c(W)) for (var z = 0, Pe = W.length; z < Pe; z += 1) N(z, W[z], Q, B);
1461
1461
  }
1462
- }, "e"))(v, I, w, O);
1462
+ }, "e"))(v, S, w, O);
1463
1463
  }, "value") }, { key: "_computeScore", value: /* @__PURE__ */ a(function(f) {
1464
1464
  this._log(`
1465
1465
 
1466
1466
  Computing score:
1467
1467
  `);
1468
- for (var y = this._keyWeights, S = !!Object.keys(y).length, E = 0, h = f.length; E < h; E += 1) {
1469
- for (var v = f[E], I = v.output, w = I.length, O = 1, _ = 0; _ < w; _ += 1) {
1470
- var k = I[_], T = k.key, C = S ? y[T] : 1, P = k.score === 0 && y && y[T] > 0 ? Number.EPSILON : k.score;
1468
+ for (var y = this._keyWeights, I = !!Object.keys(y).length, E = 0, g = f.length; E < g; E += 1) {
1469
+ for (var v = f[E], S = v.output, w = S.length, O = 1, _ = 0; _ < w; _ += 1) {
1470
+ var k = S[_], T = k.key, C = I ? y[T] : 1, P = k.score === 0 && y && y[T] > 0 ? Number.EPSILON : k.score;
1471
1471
  O *= Math.pow(P, C);
1472
1472
  }
1473
1473
  v.score = O, this._log(v);
@@ -1479,18 +1479,18 @@ Sorting....`), f.sort(this.options.sortFn);
1479
1479
  }, "value") }, { key: "_format", value: /* @__PURE__ */ a(function(f) {
1480
1480
  var y = [];
1481
1481
  if (this.options.verbose) {
1482
- var S = [];
1482
+ var I = [];
1483
1483
  this._log(`
1484
1484
 
1485
1485
  Output:
1486
1486
 
1487
1487
  `, JSON.stringify(f, function(k, T) {
1488
1488
  if (i(T) === "object" && T !== null) {
1489
- if (S.indexOf(T) !== -1) return;
1490
- S.push(T);
1489
+ if (I.indexOf(T) !== -1) return;
1490
+ I.push(T);
1491
1491
  }
1492
1492
  return T;
1493
- }, 2)), S = null;
1493
+ }, 2)), I = null;
1494
1494
  }
1495
1495
  var E = [];
1496
1496
  this.options.includeMatches && E.push(function(k, T) {
@@ -1507,114 +1507,114 @@ Output:
1507
1507
  }), this.options.includeScore && E.push(function(k, T) {
1508
1508
  T.score = k.score;
1509
1509
  });
1510
- for (var h = 0, v = f.length; h < v; h += 1) {
1511
- var I = f[h];
1512
- if (this.options.id && (I.item = this.options.getFn(I.item, this.options.id)[0]), E.length) {
1513
- for (var w = { item: I.item }, O = 0, _ = E.length; O < _; O += 1) E[O](I, w);
1510
+ for (var g = 0, v = f.length; g < v; g += 1) {
1511
+ var S = f[g];
1512
+ if (this.options.id && (S.item = this.options.getFn(S.item, this.options.id)[0]), E.length) {
1513
+ for (var w = { item: S.item }, O = 0, _ = E.length; O < _; O += 1) E[O](S, w);
1514
1514
  y.push(w);
1515
- } else y.push(I.item);
1515
+ } else y.push(S.item);
1516
1516
  }
1517
1517
  return y;
1518
1518
  }, "value") }, { key: "_log", value: /* @__PURE__ */ a(function() {
1519
1519
  var f;
1520
1520
  this.options.verbose && (f = console).log.apply(f, arguments);
1521
- }, "value") }]) && r(m.prototype, g), b && r(m, b), d;
1521
+ }, "value") }]) && r(m.prototype, h), b && r(m, b), p;
1522
1522
  }();
1523
- e.exports = p;
1523
+ e.exports = d;
1524
1524
  }, function(e, t, o) {
1525
- function i(c, p) {
1526
- for (var d = 0; d < p.length; d++) {
1527
- var m = p[d];
1525
+ function i(c, d) {
1526
+ for (var p = 0; p < d.length; p++) {
1527
+ var m = d[p];
1528
1528
  m.enumerable = m.enumerable || !1, m.configurable = !0, "value" in m && (m.writable = !0), Object.defineProperty(c, m.key, m);
1529
1529
  }
1530
1530
  }
1531
1531
  a(i, "n");
1532
1532
  var r = o(2), n = o(3), l = o(6), u = function() {
1533
- function c(g, b) {
1534
- var f = b.location, y = f === void 0 ? 0 : f, S = b.distance, E = S === void 0 ? 100 : S, h = b.threshold, v = h === void 0 ? 0.6 :
1535
- h, I = b.maxPatternLength, w = I === void 0 ? 32 : I, O = b.isCaseSensitive, _ = O !== void 0 && O, k = b.tokenSeparator, T = k ===
1533
+ function c(h, b) {
1534
+ var f = b.location, y = f === void 0 ? 0 : f, I = b.distance, E = I === void 0 ? 100 : I, g = b.threshold, v = g === void 0 ? 0.6 :
1535
+ g, S = b.maxPatternLength, w = S === void 0 ? 32 : S, O = b.isCaseSensitive, _ = O !== void 0 && O, k = b.tokenSeparator, T = k ===
1536
1536
  void 0 ? / +/g : k, C = b.findAllMatches, P = C !== void 0 && C, D = b.minMatchCharLength, M = D === void 0 ? 1 : D, N = b.includeMatches,
1537
1537
  Z = N !== void 0 && N;
1538
1538
  (function(W, Q) {
1539
1539
  if (!(W instanceof Q)) throw new TypeError("Cannot call a class as a function");
1540
1540
  })(this, c), this.options = { location: y, distance: E, threshold: v, maxPatternLength: w, isCaseSensitive: _, tokenSeparator: T, findAllMatches: P,
1541
- includeMatches: Z, minMatchCharLength: M }, this.pattern = _ ? g : g.toLowerCase(), this.pattern.length <= w && (this.patternAlphabet =
1541
+ includeMatches: Z, minMatchCharLength: M }, this.pattern = _ ? h : h.toLowerCase(), this.pattern.length <= w && (this.patternAlphabet =
1542
1542
  l(this.pattern));
1543
1543
  }
1544
1544
  a(c, "e");
1545
- var p, d, m;
1546
- return p = c, (d = [{ key: "search", value: /* @__PURE__ */ a(function(g) {
1545
+ var d, p, m;
1546
+ return d = c, (p = [{ key: "search", value: /* @__PURE__ */ a(function(h) {
1547
1547
  var b = this.options, f = b.isCaseSensitive, y = b.includeMatches;
1548
- if (f || (g = g.toLowerCase()), this.pattern === g) {
1549
- var S = { isMatch: !0, score: 0 };
1550
- return y && (S.matchedIndices = [[0, g.length - 1]]), S;
1548
+ if (f || (h = h.toLowerCase()), this.pattern === h) {
1549
+ var I = { isMatch: !0, score: 0 };
1550
+ return y && (I.matchedIndices = [[0, h.length - 1]]), I;
1551
1551
  }
1552
- var E = this.options, h = E.maxPatternLength, v = E.tokenSeparator;
1553
- if (this.pattern.length > h) return r(g, this.pattern, v);
1554
- var I = this.options, w = I.location, O = I.distance, _ = I.threshold, k = I.findAllMatches, T = I.minMatchCharLength;
1555
- return n(g, this.pattern, this.patternAlphabet, { location: w, distance: O, threshold: _, findAllMatches: k, minMatchCharLength: T,
1552
+ var E = this.options, g = E.maxPatternLength, v = E.tokenSeparator;
1553
+ if (this.pattern.length > g) return r(h, this.pattern, v);
1554
+ var S = this.options, w = S.location, O = S.distance, _ = S.threshold, k = S.findAllMatches, T = S.minMatchCharLength;
1555
+ return n(h, this.pattern, this.patternAlphabet, { location: w, distance: O, threshold: _, findAllMatches: k, minMatchCharLength: T,
1556
1556
  includeMatches: y });
1557
- }, "value") }]) && i(p.prototype, d), m && i(p, m), c;
1557
+ }, "value") }]) && i(d.prototype, p), m && i(d, m), c;
1558
1558
  }();
1559
1559
  e.exports = u;
1560
1560
  }, function(e, t) {
1561
1561
  var o = /[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g;
1562
1562
  e.exports = function(i, r) {
1563
1563
  var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : / +/g, l = new RegExp(r.replace(o, "\\$&").replace(n, "|")),
1564
- u = i.match(l), c = !!u, p = [];
1565
- if (c) for (var d = 0, m = u.length; d < m; d += 1) {
1566
- var g = u[d];
1567
- p.push([i.indexOf(g), g.length - 1]);
1564
+ u = i.match(l), c = !!u, d = [];
1565
+ if (c) for (var p = 0, m = u.length; p < m; p += 1) {
1566
+ var h = u[p];
1567
+ d.push([i.indexOf(h), h.length - 1]);
1568
1568
  }
1569
- return { score: c ? 0.5 : 1, isMatch: c, matchedIndices: p };
1569
+ return { score: c ? 0.5 : 1, isMatch: c, matchedIndices: d };
1570
1570
  };
1571
1571
  }, function(e, t, o) {
1572
1572
  var i = o(4), r = o(5);
1573
1573
  e.exports = function(n, l, u, c) {
1574
- for (var p = c.location, d = p === void 0 ? 0 : p, m = c.distance, g = m === void 0 ? 100 : m, b = c.threshold, f = b === void 0 ? 0.6 :
1575
- b, y = c.findAllMatches, S = y !== void 0 && y, E = c.minMatchCharLength, h = E === void 0 ? 1 : E, v = c.includeMatches, I = v !== void 0 &&
1576
- v, w = d, O = n.length, _ = f, k = n.indexOf(l, w), T = l.length, C = [], P = 0; P < O; P += 1) C[P] = 0;
1574
+ for (var d = c.location, p = d === void 0 ? 0 : d, m = c.distance, h = m === void 0 ? 100 : m, b = c.threshold, f = b === void 0 ? 0.6 :
1575
+ b, y = c.findAllMatches, I = y !== void 0 && y, E = c.minMatchCharLength, g = E === void 0 ? 1 : E, v = c.includeMatches, S = v !== void 0 &&
1576
+ v, w = p, O = n.length, _ = f, k = n.indexOf(l, w), T = l.length, C = [], P = 0; P < O; P += 1) C[P] = 0;
1577
1577
  if (k !== -1) {
1578
- var D = i(l, { errors: 0, currentLocation: k, expectedLocation: w, distance: g });
1578
+ var D = i(l, { errors: 0, currentLocation: k, expectedLocation: w, distance: h });
1579
1579
  if (_ = Math.min(D, _), (k = n.lastIndexOf(l, w + T)) !== -1) {
1580
- var M = i(l, { errors: 0, currentLocation: k, expectedLocation: w, distance: g });
1580
+ var M = i(l, { errors: 0, currentLocation: k, expectedLocation: w, distance: h });
1581
1581
  _ = Math.min(M, _);
1582
1582
  }
1583
1583
  }
1584
1584
  k = -1;
1585
1585
  for (var N = [], Z = 1, W = T + O, Q = 1 << (T <= 31 ? T - 1 : 30), B = 0; B < T; B += 1) {
1586
1586
  for (var G = 0, H = W; G < H; )
1587
- i(l, { errors: B, currentLocation: w + H, expectedLocation: w, distance: g }) <= _ ? G = H : W = H, H = Math.floor((W - G) / 2 +
1587
+ i(l, { errors: B, currentLocation: w + H, expectedLocation: w, distance: h }) <= _ ? G = H : W = H, H = Math.floor((W - G) / 2 +
1588
1588
  G);
1589
1589
  W = H;
1590
- var re = Math.max(1, w - H + 1), F = S ? O : Math.min(w + H, O) + T, R = Array(F + 2);
1590
+ var re = Math.max(1, w - H + 1), F = I ? O : Math.min(w + H, O) + T, R = Array(F + 2);
1591
1591
  R[F + 1] = (1 << B) - 1;
1592
1592
  for (var L = F; L >= re; L -= 1) {
1593
1593
  var $ = L - 1, J = u[n.charAt($)];
1594
1594
  if (J && (C[$] = 1), R[L] = (R[L + 1] << 1 | 1) & J, B !== 0 && (R[L] |= (N[L + 1] | N[L]) << 1 | 1 | N[L + 1]), R[L] & Q && (Z =
1595
- i(l, { errors: B, currentLocation: $, expectedLocation: w, distance: g })) <= _) {
1595
+ i(l, { errors: B, currentLocation: $, expectedLocation: w, distance: h })) <= _) {
1596
1596
  if (_ = Z, (k = $) <= w) break;
1597
1597
  re = Math.max(1, 2 * w - k);
1598
1598
  }
1599
1599
  }
1600
- if (i(l, { errors: B + 1, currentLocation: w, expectedLocation: w, distance: g }) > _) break;
1600
+ if (i(l, { errors: B + 1, currentLocation: w, expectedLocation: w, distance: h }) > _) break;
1601
1601
  N = R;
1602
1602
  }
1603
1603
  var ie = { isMatch: k >= 0, score: Z === 0 ? 1e-3 : Z };
1604
- return I && (ie.matchedIndices = r(C, h)), ie;
1604
+ return S && (ie.matchedIndices = r(C, g)), ie;
1605
1605
  };
1606
1606
  }, function(e, t) {
1607
1607
  e.exports = function(o, i) {
1608
- var r = i.errors, n = r === void 0 ? 0 : r, l = i.currentLocation, u = l === void 0 ? 0 : l, c = i.expectedLocation, p = c === void 0 ?
1609
- 0 : c, d = i.distance, m = d === void 0 ? 100 : d, g = n / o.length, b = Math.abs(p - u);
1610
- return m ? g + b / m : b ? 1 : g;
1608
+ var r = i.errors, n = r === void 0 ? 0 : r, l = i.currentLocation, u = l === void 0 ? 0 : l, c = i.expectedLocation, d = c === void 0 ?
1609
+ 0 : c, p = i.distance, m = p === void 0 ? 100 : p, h = n / o.length, b = Math.abs(d - u);
1610
+ return m ? h + b / m : b ? 1 : h;
1611
1611
  };
1612
1612
  }, function(e, t) {
1613
1613
  e.exports = function() {
1614
1614
  for (var o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], i = arguments.length > 1 && arguments[1] !== void 0 ?
1615
1615
  arguments[1] : 1, r = [], n = -1, l = -1, u = 0, c = o.length; u < c; u += 1) {
1616
- var p = o[u];
1617
- p && n === -1 ? n = u : p || n === -1 || ((l = u - 1) - n + 1 >= i && r.push([n, l]), n = -1);
1616
+ var d = o[u];
1617
+ d && n === -1 ? n = u : d || n === -1 || ((l = u - 1) - n + 1 >= i && r.push([n, l]), n = -1);
1618
1618
  }
1619
1619
  return o[u - 1] && u - n >= i && r.push([n, u - 1]), r;
1620
1620
  };
@@ -1640,15 +1640,15 @@ Output:
1640
1640
  }, "i");
1641
1641
  e.exports = { get: /* @__PURE__ */ a(function(l, u) {
1642
1642
  var c = [];
1643
- return (/* @__PURE__ */ a(function p(d, m) {
1643
+ return (/* @__PURE__ */ a(function d(p, m) {
1644
1644
  if (m) {
1645
- var g = m.indexOf("."), b = m, f = null;
1646
- g !== -1 && (b = m.slice(0, g), f = m.slice(g + 1));
1647
- var y = d[b];
1648
- if (y != null) if (f || !r(y) && !n(y)) if (o(y)) for (var S = 0, E = y.length; S < E; S += 1) p(y[S], f);
1649
- else f && p(y, f);
1645
+ var h = m.indexOf("."), b = m, f = null;
1646
+ h !== -1 && (b = m.slice(0, h), f = m.slice(h + 1));
1647
+ var y = p[b];
1648
+ if (y != null) if (f || !r(y) && !n(y)) if (o(y)) for (var I = 0, E = y.length; I < E; I += 1) d(y[I], f);
1649
+ else f && d(y, f);
1650
1650
  else c.push(i(y));
1651
- } else c.push(d);
1651
+ } else c.push(p);
1652
1652
  }, "e"))(l, u), c;
1653
1653
  }, "get"), isArray: o, isString: r, isNum: n, toString: i };
1654
1654
  }]);
@@ -1705,9 +1705,9 @@ var Md = we((gn, yn) => {
1705
1705
  }, "clear"),
1706
1706
  // core functions
1707
1707
  Store: /* @__PURE__ */ a(function(r, n, l) {
1708
- var u = o.inherit(o.storeAPI, function(p, d, m) {
1709
- return arguments.length === 0 ? u.getAll() : typeof d == "function" ? u.transact(p, d, m) : d !== void 0 ? u.set(p, d, m) : typeof p ==
1710
- "string" || typeof p == "number" ? u.get(p) : typeof p == "function" ? u.each(p) : p ? u.setAll(p, d) : u.clear();
1708
+ var u = o.inherit(o.storeAPI, function(d, p, m) {
1709
+ return arguments.length === 0 ? u.getAll() : typeof p == "function" ? u.transact(d, p, m) : p !== void 0 ? u.set(d, p, m) : typeof d ==
1710
+ "string" || typeof d == "number" ? u.get(d) : typeof d == "function" ? u.each(d) : d ? u.setAll(d, p) : u.clear();
1711
1711
  });
1712
1712
  u._id = r;
1713
1713
  try {
@@ -1729,8 +1729,8 @@ var Md = we((gn, yn) => {
1729
1729
  return this._ns ? this._ns.substring(0, this._ns.length - l.length) : "";
1730
1730
  var u = r, c = this[u];
1731
1731
  if ((!c || !c.namespace) && (c = o.Store(this._id, this._area, this._ns + u + l), c._delim = l, this[u] || (this[u] = c), !n))
1732
- for (var p in o.areas)
1733
- c.area(p, o.areas[p]);
1732
+ for (var d in o.areas)
1733
+ c.area(d, o.areas[d]);
1734
1734
  return c;
1735
1735
  }, "namespace"),
1736
1736
  isFake: /* @__PURE__ */ a(function(r) {
@@ -1792,8 +1792,8 @@ var Md = we((gn, yn) => {
1792
1792
  else if (u !== null) {
1793
1793
  var c = typeof u;
1794
1794
  if (c === typeof n && c === "object") {
1795
- for (var p in n)
1796
- u[p] = n[p];
1795
+ for (var d in n)
1796
+ u[d] = n[d];
1797
1797
  n = u;
1798
1798
  } else
1799
1799
  n = u + n;
@@ -2257,24 +2257,24 @@ var Sa = /* @__PURE__ */ a((e) => /* @__PURE__ */ a((o) => {
2257
2257
  let {
2258
2258
  id: i,
2259
2259
  toolbar: { items: r, shortcuts: n }
2260
- } = o, l = oe(), [u, c] = er(), p = q([]), d = u[i], m = A(() => {
2260
+ } = o, l = oe(), [u, c] = er(), d = q([]), p = u[i], m = A(() => {
2261
2261
  c({ [i]: "" });
2262
- }, [c]), g = A(() => {
2263
- let f = p.current, y = f.indexOf(d), E = y === f.length - 1 ? 0 : y + 1, h = p.current[E];
2264
- c({ [i]: h });
2265
- }, [p, d, c]), b = A(() => {
2266
- let f = p.current, y = f.indexOf(d), S = y > -1 ? y : 0, h = S === 0 ? f.length - 1 : S - 1, v = p.current[h];
2262
+ }, [c]), h = A(() => {
2263
+ let f = d.current, y = f.indexOf(p), E = y === f.length - 1 ? 0 : y + 1, g = d.current[E];
2264
+ c({ [i]: g });
2265
+ }, [d, p, c]), b = A(() => {
2266
+ let f = d.current, y = f.indexOf(p), I = y > -1 ? y : 0, g = I === 0 ? f.length - 1 : I - 1, v = d.current[g];
2267
2267
  c({ [i]: v });
2268
- }, [p, d, c]);
2268
+ }, [d, p, c]);
2269
2269
  return V(() => {
2270
2270
  n && Ia(l, i, {
2271
- next: { ...n.next, action: g },
2271
+ next: { ...n.next, action: h },
2272
2272
  previous: { ...n.previous, action: b },
2273
2273
  reset: { ...n.reset, action: m }
2274
2274
  });
2275
- }, [l, i, n, g, b, m]), V(() => {
2276
- p.current = xa(r);
2277
- }, []), /* @__PURE__ */ s.createElement(e, { cycleValues: p.current, ...o });
2275
+ }, [l, i, n, h, b, m]), V(() => {
2276
+ d.current = xa(r);
2277
+ }, []), /* @__PURE__ */ s.createElement(e, { cycleValues: d.current, ...o });
2278
2278
  }, "WithKeyboardCycle"), "withKeyboardCycle");
2279
2279
 
2280
2280
  // src/toolbar/utils/get-selected.ts
@@ -2570,7 +2570,7 @@ var Oa = /* @__PURE__ */ a(({
2570
2570
  disabled: l,
2571
2571
  currentValue: u
2572
2572
  }) => {
2573
- let c = i && /* @__PURE__ */ s.createElement(ur, { style: { opacity: 1 }, icon: i, __suppressDeprecationWarning: !0 }), p = {
2573
+ let c = i && /* @__PURE__ */ s.createElement(ur, { style: { opacity: 1 }, icon: i, __suppressDeprecationWarning: !0 }), d = {
2574
2574
  id: o ?? "_reset",
2575
2575
  active: u === o,
2576
2576
  right: e,
@@ -2578,7 +2578,7 @@ var Oa = /* @__PURE__ */ a(({
2578
2578
  disabled: l,
2579
2579
  onClick: n
2580
2580
  };
2581
- return i && !r && (p.icon = c), p;
2581
+ return i && !r && (d.icon = c), d;
2582
2582
  }, "ToolbarMenuListItem");
2583
2583
 
2584
2584
  // src/toolbar/components/ToolbarMenuList.tsx
@@ -2589,21 +2589,21 @@ var Pa = Sa(
2589
2589
  description: o,
2590
2590
  toolbar: { icon: i, items: r, title: n, preventDynamicIcon: l, dynamicTitle: u }
2591
2591
  }) => {
2592
- let [c, p, d] = er(), [m, g] = K(!1), b = c[e], f = !!b, y = e in d, S = i, E = n;
2593
- l || (S = Ea({ currentValue: b, items: r }) || S), u && (E = Ta({ currentValue: b, items: r }) || E), !E && !S && console.warn(`Toolbar \
2592
+ let [c, d, p] = er(), [m, h] = K(!1), b = c[e], f = !!b, y = e in p, I = i, E = n;
2593
+ l || (I = Ea({ currentValue: b, items: r }) || I), u && (E = Ta({ currentValue: b, items: r }) || E), !E && !I && console.warn(`Toolbar \
2594
2594
  '${t}' has no title or icon`);
2595
- let h = A(
2595
+ let g = A(
2596
2596
  (v) => {
2597
- p({ [e]: v });
2597
+ d({ [e]: v });
2598
2598
  },
2599
- [e, p]
2599
+ [e, d]
2600
2600
  );
2601
2601
  return /* @__PURE__ */ s.createElement(
2602
2602
  ve,
2603
2603
  {
2604
2604
  placement: "top",
2605
2605
  tooltip: ({ onHide: v }) => {
2606
- let I = r.filter(({ type: w }) => {
2606
+ let S = r.filter(({ type: w }) => {
2607
2607
  let O = !0;
2608
2608
  return w === "reset" && !b && (O = !1), O;
2609
2609
  }).map((w) => Oa({
@@ -2611,13 +2611,13 @@ var Pa = Sa(
2611
2611
  currentValue: b,
2612
2612
  disabled: y,
2613
2613
  onClick: /* @__PURE__ */ a(() => {
2614
- h(w.value), v();
2614
+ g(w.value), v();
2615
2615
  }, "onClick")
2616
2616
  }));
2617
- return /* @__PURE__ */ s.createElement(ot, { links: I });
2617
+ return /* @__PURE__ */ s.createElement(ot, { links: S });
2618
2618
  },
2619
2619
  closeOnOutsideClick: !0,
2620
- onVisibleChange: g
2620
+ onVisibleChange: h
2621
2621
  },
2622
2622
  /* @__PURE__ */ s.createElement(
2623
2623
  ka,
@@ -2625,7 +2625,7 @@ var Pa = Sa(
2625
2625
  active: m || f,
2626
2626
  disabled: y,
2627
2627
  description: o || "",
2628
- icon: S,
2628
+ icon: I,
2629
2629
  title: E || ""
2630
2630
  }
2631
2631
  )
@@ -2737,20 +2737,20 @@ ld be of type "Array". Instead found type "' + typeof r[e] + '"'), !1);
2737
2737
  }).reverse().reduce(function(r, n) {
2738
2738
  var l = {};
2739
2739
  n.filter(function(m) {
2740
- for (var g, b = Object.keys(m), f = 0; f < b.length; f += 1) {
2741
- var y = b[f], S = y.toLowerCase();
2742
- t.indexOf(S) === -1 || g === "rel" && m[g].toLowerCase() === "canonical" || S === "rel" && m[S].toLowerCase() === "stylesheet" || (g =
2743
- S), t.indexOf(y) === -1 || y !== "innerHTML" && y !== "cssText" && y !== "itemprop" || (g = y);
2740
+ for (var h, b = Object.keys(m), f = 0; f < b.length; f += 1) {
2741
+ var y = b[f], I = y.toLowerCase();
2742
+ t.indexOf(I) === -1 || h === "rel" && m[h].toLowerCase() === "canonical" || I === "rel" && m[I].toLowerCase() === "stylesheet" || (h =
2743
+ I), t.indexOf(y) === -1 || y !== "innerHTML" && y !== "cssText" && y !== "itemprop" || (h = y);
2744
2744
  }
2745
- if (!g || !m[g]) return !1;
2746
- var E = m[g].toLowerCase();
2747
- return i[g] || (i[g] = {}), l[g] || (l[g] = {}), !i[g][E] && (l[g][E] = !0, !0);
2745
+ if (!h || !m[h]) return !1;
2746
+ var E = m[h].toLowerCase();
2747
+ return i[h] || (i[h] = {}), l[h] || (l[h] = {}), !i[h][E] && (l[h][E] = !0, !0);
2748
2748
  }).reverse().forEach(function(m) {
2749
2749
  return r.push(m);
2750
2750
  });
2751
2751
  for (var u = Object.keys(l), c = 0; c < u.length; c += 1) {
2752
- var p = u[c], d = xe({}, i[p], l[p]);
2753
- i[p] = d;
2752
+ var d = u[c], p = xe({}, i[d], l[d]);
2753
+ i[d] = p;
2754
2754
  }
2755
2755
  return r;
2756
2756
  }, []).reverse();
@@ -2819,35 +2819,35 @@ ld be of type "Array". Instead found type "' + typeof r[e] + '"'), !1);
2819
2819
  return r.reduce(function(l, u) {
2820
2820
  var c = Object.keys(u).filter(function(m) {
2821
2821
  return !(m === "innerHTML" || m === "cssText");
2822
- }).reduce(function(m, g) {
2823
- var b = u[g] === void 0 ? g : g + '="' + si(u[g], n) + '"';
2822
+ }).reduce(function(m, h) {
2823
+ var b = u[h] === void 0 ? h : h + '="' + si(u[h], n) + '"';
2824
2824
  return m ? m + " " + b : b;
2825
- }, ""), p = u.innerHTML || u.cssText || "", d = my.indexOf(i) === -1;
2826
- return l + "<" + i + ' data-rh="true" ' + c + (d ? "/>" : ">" + p + "</" + i + ">");
2825
+ }, ""), d = u.innerHTML || u.cssText || "", p = my.indexOf(i) === -1;
2826
+ return l + "<" + i + ' data-rh="true" ' + c + (p ? "/>" : ">" + d + "</" + i + ">");
2827
2827
  }, "");
2828
2828
  }(e, t, o);
2829
2829
  }, "toString") };
2830
2830
  }
2831
2831
  }, "M"), ci = /* @__PURE__ */ a(function(e) {
2832
2832
  var t = e.baseTag, o = e.bodyAttributes, i = e.encode, r = e.htmlAttributes, n = e.noscriptTags, l = e.styleTags, u = e.title, c = u === void 0 ?
2833
- "" : u, p = e.titleAttributes, d = e.linkTags, m = e.metaTags, g = e.scriptTags, b = { toComponent: /* @__PURE__ */ a(function() {
2833
+ "" : u, d = e.titleAttributes, p = e.linkTags, m = e.metaTags, h = e.scriptTags, b = { toComponent: /* @__PURE__ */ a(function() {
2834
2834
  }, "toComponent"), toString: /* @__PURE__ */ a(function() {
2835
2835
  return "";
2836
2836
  }, "toString") };
2837
2837
  if (e.prioritizeSeoTags) {
2838
2838
  var f = function(y) {
2839
- var S = y.linkTags, E = y.scriptTags, h = y.encode, v = ii(y.metaTags, ly), I = ii(S, sy), w = ii(E, ay);
2839
+ var I = y.linkTags, E = y.scriptTags, g = y.encode, v = ii(y.metaTags, ly), S = ii(I, sy), w = ii(E, ay);
2840
2840
  return { priorityMethods: { toComponent: /* @__PURE__ */ a(function() {
2841
- return [].concat(mr(X.META, v.priority), mr(X.LINK, I.priority), mr(X.SCRIPT, w.priority));
2841
+ return [].concat(mr(X.META, v.priority), mr(X.LINK, S.priority), mr(X.SCRIPT, w.priority));
2842
2842
  }, "toComponent"), toString: /* @__PURE__ */ a(function() {
2843
- return $e(X.META, v.priority, h) + " " + $e(X.LINK, I.priority, h) + " " + $e(X.SCRIPT, w.priority, h);
2844
- }, "toString") }, metaTags: v.default, linkTags: I.default, scriptTags: w.default };
2843
+ return $e(X.META, v.priority, g) + " " + $e(X.LINK, S.priority, g) + " " + $e(X.SCRIPT, w.priority, g);
2844
+ }, "toString") }, metaTags: v.default, linkTags: S.default, scriptTags: w.default };
2845
2845
  }(e);
2846
- b = f.priorityMethods, d = f.linkTags, m = f.metaTags, g = f.scriptTags;
2846
+ b = f.priorityMethods, p = f.linkTags, m = f.metaTags, h = f.scriptTags;
2847
2847
  }
2848
2848
  return { priority: b, base: $e(X.BASE, t, i), bodyAttributes: $e("bodyAttributes", o, i), htmlAttributes: $e("htmlAttributes", r, i), link: $e(
2849
- X.LINK, d, i), meta: $e(X.META, m, i), noscript: $e(X.NOSCRIPT, n, i), script: $e(X.SCRIPT, g, i), style: $e(X.STYLE, l, i), title: $e(X.TITLE,
2850
- { title: c, titleAttributes: p }, i) };
2849
+ X.LINK, p, i), meta: $e(X.META, m, i), noscript: $e(X.NOSCRIPT, n, i), script: $e(X.SCRIPT, h, i), style: $e(X.STYLE, l, i), title: $e(X.TITLE,
2850
+ { title: c, titleAttributes: d }, i) };
2851
2851
  }, "k"), fr = [], pi = /* @__PURE__ */ a(function(e, t) {
2852
2852
  var o = this;
2853
2853
  t === void 0 && (t = typeof document < "u"), this.instances = [], this.value = { setHelmet: /* @__PURE__ */ a(function(i) {
@@ -2877,10 +2877,10 @@ var oo = /* @__PURE__ */ a(function(e, t) {
2877
2877
  var o, i = document.head || document.querySelector(X.HEAD), r = i.querySelectorAll(e + "[data-rh]"), n = [].slice.call(r), l = [];
2878
2878
  return t && t.length && t.forEach(function(u) {
2879
2879
  var c = document.createElement(e);
2880
- for (var p in u) Object.prototype.hasOwnProperty.call(u, p) && (p === "innerHTML" ? c.innerHTML = u.innerHTML : p === "cssText" ? c.styleSheet ?
2881
- c.styleSheet.cssText = u.cssText : c.appendChild(document.createTextNode(u.cssText)) : c.setAttribute(p, u[p] === void 0 ? "" : u[p]));
2882
- c.setAttribute("data-rh", "true"), n.some(function(d, m) {
2883
- return o = m, c.isEqualNode(d);
2880
+ for (var d in u) Object.prototype.hasOwnProperty.call(u, d) && (d === "innerHTML" ? c.innerHTML = u.innerHTML : d === "cssText" ? c.styleSheet ?
2881
+ c.styleSheet.cssText = u.cssText : c.appendChild(document.createTextNode(u.cssText)) : c.setAttribute(d, u[d] === void 0 ? "" : u[d]));
2882
+ c.setAttribute("data-rh", "true"), n.some(function(p, m) {
2883
+ return o = m, c.isEqualNode(p);
2884
2884
  }) ? n.splice(o, 1) : l.push(c);
2885
2885
  }), n.forEach(function(u) {
2886
2886
  return u.parentNode.removeChild(u);
@@ -2891,25 +2891,25 @@ var oo = /* @__PURE__ */ a(function(e, t) {
2891
2891
  var o = document.getElementsByTagName(e)[0];
2892
2892
  if (o) {
2893
2893
  for (var i = o.getAttribute("data-rh"), r = i ? i.split(",") : [], n = [].concat(r), l = Object.keys(t), u = 0; u < l.length; u += 1) {
2894
- var c = l[u], p = t[c] || "";
2895
- o.getAttribute(c) !== p && o.setAttribute(c, p), r.indexOf(c) === -1 && r.push(c);
2896
- var d = n.indexOf(c);
2897
- d !== -1 && n.splice(d, 1);
2894
+ var c = l[u], d = t[c] || "";
2895
+ o.getAttribute(c) !== d && o.setAttribute(c, d), r.indexOf(c) === -1 && r.push(c);
2896
+ var p = n.indexOf(c);
2897
+ p !== -1 && n.splice(p, 1);
2898
2898
  }
2899
2899
  for (var m = n.length - 1; m >= 0; m -= 1) o.removeAttribute(n[m]);
2900
2900
  r.length === n.length ? o.removeAttribute("data-rh") : o.getAttribute("data-rh") !== l.join(",") && o.setAttribute("data-rh", l.join(","));
2901
2901
  }
2902
2902
  }, "B"), tl = /* @__PURE__ */ a(function(e, t) {
2903
- var o = e.baseTag, i = e.htmlAttributes, r = e.linkTags, n = e.metaTags, l = e.noscriptTags, u = e.onChangeClientState, c = e.scriptTags, p = e.
2904
- styleTags, d = e.title, m = e.titleAttributes;
2905
- ai(X.BODY, e.bodyAttributes), ai(X.HTML, i), function(y, S) {
2906
- y !== void 0 && document.title !== y && (document.title = nl(y)), ai(X.TITLE, S);
2907
- }(d, m);
2908
- var g = { baseTag: oo(X.BASE, o), linkTags: oo(X.LINK, r), metaTags: oo(X.META, n), noscriptTags: oo(X.NOSCRIPT, l), scriptTags: oo(X.SCRIPT,
2909
- c), styleTags: oo(X.STYLE, p) }, b = {}, f = {};
2910
- Object.keys(g).forEach(function(y) {
2911
- var S = g[y], E = S.newTags, h = S.oldTags;
2912
- E.length && (b[y] = E), h.length && (f[y] = g[y].oldTags);
2903
+ var o = e.baseTag, i = e.htmlAttributes, r = e.linkTags, n = e.metaTags, l = e.noscriptTags, u = e.onChangeClientState, c = e.scriptTags, d = e.
2904
+ styleTags, p = e.title, m = e.titleAttributes;
2905
+ ai(X.BODY, e.bodyAttributes), ai(X.HTML, i), function(y, I) {
2906
+ y !== void 0 && document.title !== y && (document.title = nl(y)), ai(X.TITLE, I);
2907
+ }(p, m);
2908
+ var h = { baseTag: oo(X.BASE, o), linkTags: oo(X.LINK, r), metaTags: oo(X.META, n), noscriptTags: oo(X.NOSCRIPT, l), scriptTags: oo(X.SCRIPT,
2909
+ c), styleTags: oo(X.STYLE, d) }, b = {}, f = {};
2910
+ Object.keys(h).forEach(function(y) {
2911
+ var I = h[y], E = I.newTags, g = I.oldTags;
2912
+ E.length && (b[y] = E), g.length && (f[y] = h[y].oldTags);
2913
2913
  }), t && t(), u(e, b, f);
2914
2914
  }, "K"), _o = null, gr = /* @__PURE__ */ function(e) {
2915
2915
  function t() {
@@ -2925,9 +2925,9 @@ var oo = /* @__PURE__ */ a(function(e, t) {
2925
2925
  }, o.componentWillUnmount = function() {
2926
2926
  this.props.context.helmetInstances.remove(this), this.emitChange();
2927
2927
  }, o.emitChange = function() {
2928
- var i, r, n = this.props.context, l = n.setHelmet, u = null, c = (i = n.helmetInstances.get().map(function(p) {
2929
- var d = xe({}, p.props);
2930
- return delete d.context, d;
2928
+ var i, r, n = this.props.context, l = n.setHelmet, u = null, c = (i = n.helmetInstances.get().map(function(d) {
2929
+ var p = xe({}, d.props);
2930
+ return delete p.context, p;
2931
2931
  }), { baseTag: dy(["href"], i), bodyAttributes: ni("bodyAttributes", i), defer: ro(i, "defer"), encode: ro(i, "encodeSpecialCharacters"),
2932
2932
  htmlAttributes: ni("htmlAttributes", i), linkTags: Co(X.LINK, ["rel", "href"], i), metaTags: Co(X.META, ["name", "charset", "http-equiv",
2933
2933
  "property", "itemprop"], i), noscriptTags: Co(X.NOSCRIPT, ["innerHTML"], i), onChangeClientState: py(i), scriptTags: Co(X.SCRIPT, ["src",
@@ -2969,10 +2969,10 @@ var yy = ["children"], by = ["children"], ko = /* @__PURE__ */ function(e) {
2969
2969
  return xe({}, l, ((r = {})[n.type] = [].concat(l[n.type] || [], [xe({}, i.newChildProps, this.mapNestedChildrenToProps(n, i.nestedChildren))]),
2970
2970
  r));
2971
2971
  }, o.mapObjectTypeChildren = function(i) {
2972
- var r, n, l = i.child, u = i.newProps, c = i.newChildProps, p = i.nestedChildren;
2972
+ var r, n, l = i.child, u = i.newProps, c = i.newChildProps, d = i.nestedChildren;
2973
2973
  switch (l.type) {
2974
2974
  case X.TITLE:
2975
- return xe({}, u, ((r = {})[l.type] = p, r.titleAttributes = xe({}, c), r));
2975
+ return xe({}, u, ((r = {})[l.type] = d, r.titleAttributes = xe({}, c), r));
2976
2976
  case X.BODY:
2977
2977
  return xe({}, u, { bodyAttributes: xe({}, c) });
2978
2978
  case X.HTML:
@@ -2999,22 +2999,22 @@ lements. Refer to our API for more information."), (0, li.default)(!r || typeof
2999
2999
  var n = this, l = {};
3000
3000
  return s.Children.forEach(i, function(u) {
3001
3001
  if (u && u.props) {
3002
- var c = u.props, p = c.children, d = Qa(c, yy), m = Object.keys(d).reduce(function(b, f) {
3003
- return b[uy[f] || f] = d[f], b;
3004
- }, {}), g = u.type;
3005
- switch (typeof g == "symbol" ? g = g.toString() : n.warnOnInvalidChildren(u, p), g) {
3002
+ var c = u.props, d = c.children, p = Qa(c, yy), m = Object.keys(p).reduce(function(b, f) {
3003
+ return b[uy[f] || f] = p[f], b;
3004
+ }, {}), h = u.type;
3005
+ switch (typeof h == "symbol" ? h = h.toString() : n.warnOnInvalidChildren(u, d), h) {
3006
3006
  case X.FRAGMENT:
3007
- r = n.mapChildrenToProps(p, r);
3007
+ r = n.mapChildrenToProps(d, r);
3008
3008
  break;
3009
3009
  case X.LINK:
3010
3010
  case X.META:
3011
3011
  case X.NOSCRIPT:
3012
3012
  case X.SCRIPT:
3013
3013
  case X.STYLE:
3014
- l = n.flattenArrayTypeChildren({ child: u, arrayTypeChildren: l, newChildProps: m, nestedChildren: p });
3014
+ l = n.flattenArrayTypeChildren({ child: u, arrayTypeChildren: l, newChildProps: m, nestedChildren: d });
3015
3015
  break;
3016
3016
  default:
3017
- r = n.mapObjectTypeChildren({ child: u, newProps: r, newChildProps: m, nestedChildren: p });
3017
+ r = n.mapObjectTypeChildren({ child: u, newProps: r, newChildProps: m, nestedChildren: d });
3018
3018
  }
3019
3019
  }
3020
3020
  }), this.mapArrayTypeChildrenToProps(l, r);
@@ -3065,7 +3065,7 @@ var al = Qt({
3065
3065
  isDesktop: !1,
3066
3066
  isMobile: !1
3067
3067
  }), ll = /* @__PURE__ */ a(({ children: e }) => {
3068
- let [t, o] = K(!1), [i, r] = K(!1), [n, l] = K(!1), u = sl(`(min-width: ${600}px)`), c = !u, p = U(
3068
+ let [t, o] = K(!1), [i, r] = K(!1), [n, l] = K(!1), u = sl(`(min-width: ${600}px)`), c = !u, d = U(
3069
3069
  () => ({
3070
3070
  isMobileMenuOpen: t,
3071
3071
  setMobileMenuOpen: o,
@@ -3087,7 +3087,7 @@ var al = Qt({
3087
3087
  c
3088
3088
  ]
3089
3089
  );
3090
- return /* @__PURE__ */ s.createElement(al.Provider, { value: p }, e);
3090
+ return /* @__PURE__ */ s.createElement(al.Provider, { value: d }, e);
3091
3091
  }, "LayoutProvider"), ge = /* @__PURE__ */ a(() => Go(al), "useLayout");
3092
3092
 
3093
3093
  // ../node_modules/@babel/runtime/helpers/esm/extends.js
@@ -3248,11 +3248,11 @@ a(Iy, "convertToInt");
3248
3248
  function Oo(e, t, o, i) {
3249
3249
  if (i === void 0 && (i = Iy), t === 0)
3250
3250
  return i(o, o, o);
3251
- var r = (e % 360 + 360) % 360 / 60, n = (1 - Math.abs(2 * o - 1)) * t, l = n * (1 - Math.abs(r % 2 - 1)), u = 0, c = 0, p = 0;
3252
- r >= 0 && r < 1 ? (u = n, c = l) : r >= 1 && r < 2 ? (u = l, c = n) : r >= 2 && r < 3 ? (c = n, p = l) : r >= 3 && r < 4 ? (c = l, p = n) :
3253
- r >= 4 && r < 5 ? (u = l, p = n) : r >= 5 && r < 6 && (u = n, p = l);
3254
- var d = o - n / 2, m = u + d, g = c + d, b = p + d;
3255
- return i(m, g, b);
3251
+ var r = (e % 360 + 360) % 360 / 60, n = (1 - Math.abs(2 * o - 1)) * t, l = n * (1 - Math.abs(r % 2 - 1)), u = 0, c = 0, d = 0;
3252
+ r >= 0 && r < 1 ? (u = n, c = l) : r >= 1 && r < 2 ? (u = l, c = n) : r >= 2 && r < 3 ? (c = n, d = l) : r >= 3 && r < 4 ? (c = l, d = n) :
3253
+ r >= 4 && r < 5 ? (u = l, d = n) : r >= 5 && r < 6 && (u = n, d = l);
3254
+ var p = o - n / 2, m = u + p, h = c + p, b = d + p;
3255
+ return i(m, h, b);
3256
3256
  }
3257
3257
  a(Oo, "hslToRgb");
3258
3258
  var ml = {
@@ -3465,27 +3465,27 @@ function io(e) {
3465
3465
  };
3466
3466
  var l = ky.exec(t);
3467
3467
  if (l) {
3468
- var u = parseInt("" + l[1], 10), c = parseInt("" + l[2], 10) / 100, p = parseInt("" + l[3], 10) / 100, d = "rgb(" + Oo(u, c, p) + ")", m = hi.
3469
- exec(d);
3468
+ var u = parseInt("" + l[1], 10), c = parseInt("" + l[2], 10) / 100, d = parseInt("" + l[3], 10) / 100, p = "rgb(" + Oo(u, c, d) + ")", m = hi.
3469
+ exec(p);
3470
3470
  if (!m)
3471
- throw new Re(4, t, d);
3471
+ throw new Re(4, t, p);
3472
3472
  return {
3473
3473
  red: parseInt("" + m[1], 10),
3474
3474
  green: parseInt("" + m[2], 10),
3475
3475
  blue: parseInt("" + m[3], 10)
3476
3476
  };
3477
3477
  }
3478
- var g = Oy.exec(t.substring(0, 50));
3479
- if (g) {
3480
- var b = parseInt("" + g[1], 10), f = parseInt("" + g[2], 10) / 100, y = parseInt("" + g[3], 10) / 100, S = "rgb(" + Oo(b, f, y) + ")", E = hi.
3481
- exec(S);
3478
+ var h = Oy.exec(t.substring(0, 50));
3479
+ if (h) {
3480
+ var b = parseInt("" + h[1], 10), f = parseInt("" + h[2], 10) / 100, y = parseInt("" + h[3], 10) / 100, I = "rgb(" + Oo(b, f, y) + ")", E = hi.
3481
+ exec(I);
3482
3482
  if (!E)
3483
- throw new Re(4, t, S);
3483
+ throw new Re(4, t, I);
3484
3484
  return {
3485
3485
  red: parseInt("" + E[1], 10),
3486
3486
  green: parseInt("" + E[2], 10),
3487
3487
  blue: parseInt("" + E[3], 10),
3488
- alpha: parseFloat("" + g[4]) > 1 ? parseFloat("" + g[4]) / 100 : parseFloat("" + g[4])
3488
+ alpha: parseFloat("" + h[4]) > 1 ? parseFloat("" + h[4]) / 100 : parseFloat("" + h[4])
3489
3489
  };
3490
3490
  }
3491
3491
  throw new Re(5);
@@ -3504,7 +3504,7 @@ function Py(e) {
3504
3504
  saturation: 0,
3505
3505
  lightness: l
3506
3506
  };
3507
- var u, c = r - n, p = l > 0.5 ? c / (2 - r - n) : c / (r + n);
3507
+ var u, c = r - n, d = l > 0.5 ? c / (2 - r - n) : c / (r + n);
3508
3508
  switch (r) {
3509
3509
  case t:
3510
3510
  u = (o - i) / c + (o < i ? 6 : 0);
@@ -3518,12 +3518,12 @@ function Py(e) {
3518
3518
  }
3519
3519
  return u *= 60, e.alpha !== void 0 ? {
3520
3520
  hue: u,
3521
- saturation: p,
3521
+ saturation: d,
3522
3522
  lightness: l,
3523
3523
  alpha: e.alpha
3524
3524
  } : {
3525
3525
  hue: u,
3526
- saturation: p,
3526
+ saturation: d,
3527
3527
  lightness: l
3528
3528
  };
3529
3529
  }
@@ -3668,10 +3668,10 @@ function $y(e, t, o) {
3668
3668
  alpha: typeof i.alpha == "number" ? i.alpha : 1
3669
3669
  }), n = io(o), l = j({}, n, {
3670
3670
  alpha: typeof n.alpha == "number" ? n.alpha : 1
3671
- }), u = r.alpha - l.alpha, c = parseFloat(e) * 2 - 1, p = c * u === -1 ? c : c + u, d = 1 + c * u, m = (p / d + 1) / 2, g = 1 - m, b = {
3672
- red: Math.floor(r.red * m + l.red * g),
3673
- green: Math.floor(r.green * m + l.green * g),
3674
- blue: Math.floor(r.blue * m + l.blue * g),
3671
+ }), u = r.alpha - l.alpha, c = parseFloat(e) * 2 - 1, d = c * u === -1 ? c : c + u, p = 1 + c * u, m = (d / p + 1) / 2, h = 1 - m, b = {
3672
+ red: Math.floor(r.red * m + l.red * h),
3673
+ green: Math.floor(r.green * m + l.green * h),
3674
+ blue: Math.floor(r.blue * m + l.blue * h),
3675
3675
  alpha: r.alpha * parseFloat(e) + l.alpha * (1 - parseFloat(e))
3676
3676
  };
3677
3677
  return so(b);
@@ -3857,15 +3857,15 @@ ent"), cb = x(ee)(({ theme: e }) => ({
3857
3857
  onDismissNotification: u,
3858
3858
  zIndex: c
3859
3859
  }) => {
3860
- let p = A(() => {
3860
+ let d = A(() => {
3861
3861
  u(n), i && i({ dismissed: !1, timeout: !0 });
3862
- }, [n, u, i]), d = q(null);
3862
+ }, [n, u, i]), p = q(null);
3863
3863
  V(() => {
3864
3864
  if (t)
3865
- return d.current = setTimeout(p, t), () => clearTimeout(d.current);
3866
- }, [t, p]);
3865
+ return p.current = setTimeout(d, t), () => clearTimeout(p.current);
3866
+ }, [t, d]);
3867
3867
  let m = A(() => {
3868
- clearTimeout(d.current), u(n), i && i({ dismissed: !0, timeout: !1 });
3868
+ clearTimeout(p.current), u(n), i && i({ dismissed: !0, timeout: !1 });
3869
3869
  }, [n, u, i]);
3870
3870
  return o ? /* @__PURE__ */ s.createElement(ib, { to: o, duration: t, style: { zIndex: c } }, /* @__PURE__ */ s.createElement(vi, { icon: l,
3871
3871
  content: e }), /* @__PURE__ */ s.createElement(xi, { onDismiss: m })) : r ? /* @__PURE__ */ s.createElement(
@@ -4012,23 +4012,23 @@ var Mo = "unmounted", Mt = "exited", Lt = "entering", uo = "entered", wi = "exit
4012
4012
  });
4013
4013
  }, "updateStatus"), o.performEnter = /* @__PURE__ */ a(function(r) {
4014
4014
  var n = this, l = this.props.enter, u = this.context ? this.context.isMounting : r, c = this.props.nodeRef ? [u] : [Ao.findDOMNode(this),
4015
- u], p = c[0], d = c[1], m = this.getTimeouts(), g = u ? m.appear : m.enter;
4015
+ u], d = c[0], p = c[1], m = this.getTimeouts(), h = u ? m.appear : m.enter;
4016
4016
  if (!r && !l || Ii.disabled) {
4017
4017
  this.safeSetState({
4018
4018
  status: uo
4019
4019
  }, function() {
4020
- n.props.onEntered(p);
4020
+ n.props.onEntered(d);
4021
4021
  });
4022
4022
  return;
4023
4023
  }
4024
- this.props.onEnter(p, d), this.safeSetState({
4024
+ this.props.onEnter(d, p), this.safeSetState({
4025
4025
  status: Lt
4026
4026
  }, function() {
4027
- n.props.onEntering(p, d), n.onTransitionEnd(g, function() {
4027
+ n.props.onEntering(d, p), n.onTransitionEnd(h, function() {
4028
4028
  n.safeSetState({
4029
4029
  status: uo
4030
4030
  }, function() {
4031
- n.props.onEntered(p, d);
4031
+ n.props.onEntered(d, p);
4032
4032
  });
4033
4033
  });
4034
4034
  });
@@ -4072,16 +4072,16 @@ var Mo = "unmounted", Mt = "exited", Lt = "entering", uo = "entered", wi = "exit
4072
4072
  return;
4073
4073
  }
4074
4074
  if (this.props.addEndListener) {
4075
- var c = this.props.nodeRef ? [this.nextCallback] : [l, this.nextCallback], p = c[0], d = c[1];
4076
- this.props.addEndListener(p, d);
4075
+ var c = this.props.nodeRef ? [this.nextCallback] : [l, this.nextCallback], d = c[0], p = c[1];
4076
+ this.props.addEndListener(d, p);
4077
4077
  }
4078
4078
  r != null && setTimeout(this.nextCallback, r);
4079
4079
  }, "onTransitionEnd"), o.render = /* @__PURE__ */ a(function() {
4080
4080
  var r = this.state.status;
4081
4081
  if (r === Mo)
4082
4082
  return null;
4083
- var n = this.props, l = n.children, u = n.in, c = n.mountOnEnter, p = n.unmountOnExit, d = n.appear, m = n.enter, g = n.exit, b = n.timeout,
4084
- f = n.addEndListener, y = n.onEnter, S = n.onEntering, E = n.onEntered, h = n.onExit, v = n.onExiting, I = n.onExited, w = n.nodeRef, O = ke(
4083
+ var n = this.props, l = n.children, u = n.in, c = n.mountOnEnter, d = n.unmountOnExit, p = n.appear, m = n.enter, h = n.exit, b = n.timeout,
4084
+ f = n.addEndListener, y = n.onEnter, I = n.onEntering, E = n.onEntered, g = n.onExit, v = n.onExiting, S = n.onExited, w = n.nodeRef, O = ke(
4085
4085
  n, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "\
4086
4086
  onEntered", "onExit", "onExiting", "onExited", "nodeRef"]);
4087
4087
  return (
@@ -4281,7 +4281,7 @@ var _l = /* @__PURE__ */ a(({ children: e }) => {
4281
4281
  in: !l,
4282
4282
  timeout: 300
4283
4283
  },
4284
- (p) => /* @__PURE__ */ s.createElement(wb, { ref: o, state: p }, e)
4284
+ (d) => /* @__PURE__ */ s.createElement(wb, { ref: o, state: d }, e)
4285
4285
  ), /* @__PURE__ */ s.createElement(Cl, null))
4286
4286
  ), /* @__PURE__ */ s.createElement(
4287
4287
  Nt,
@@ -4441,13 +4441,13 @@ function Ml({
4441
4441
  }) {
4442
4442
  let i = q(null), r = q(null);
4443
4443
  return V(() => {
4444
- let n = i.current, l = r.current, u = document.querySelector("#storybook-preview-wrapper"), c = null, p = /* @__PURE__ */ a((g) => {
4445
- g.preventDefault(), e((b) => ({
4444
+ let n = i.current, l = r.current, u = document.querySelector("#storybook-preview-wrapper"), c = null, d = /* @__PURE__ */ a((h) => {
4445
+ h.preventDefault(), e((b) => ({
4446
4446
  ...b,
4447
4447
  isDragging: !0
4448
- })), g.currentTarget === n ? c = n : g.currentTarget === l && (c = l), window.addEventListener("mousemove", m), window.addEventListener(
4449
- "mouseup", d), u && (u.style.pointerEvents = "none");
4450
- }, "onDragStart"), d = /* @__PURE__ */ a((g) => {
4448
+ })), h.currentTarget === n ? c = n : h.currentTarget === l && (c = l), window.addEventListener("mousemove", m), window.addEventListener(
4449
+ "mouseup", p), u && (u.style.pointerEvents = "none");
4450
+ }, "onDragStart"), p = /* @__PURE__ */ a((h) => {
4451
4451
  e((b) => c === l && b.navSize < wr && b.navSize > 0 ? {
4452
4452
  ...b,
4453
4453
  isDragging: !1,
@@ -4459,15 +4459,15 @@ function Ml({
4459
4459
  } : {
4460
4460
  ...b,
4461
4461
  isDragging: !1
4462
- }), window.removeEventListener("mousemove", m), window.removeEventListener("mouseup", d), u?.removeAttribute("style"), c = null;
4463
- }, "onDragEnd"), m = /* @__PURE__ */ a((g) => {
4464
- if (g.buttons === 0) {
4465
- d(g);
4462
+ }), window.removeEventListener("mousemove", m), window.removeEventListener("mouseup", p), u?.removeAttribute("style"), c = null;
4463
+ }, "onDragEnd"), m = /* @__PURE__ */ a((h) => {
4464
+ if (h.buttons === 0) {
4465
+ p(h);
4466
4466
  return;
4467
4467
  }
4468
4468
  e((b) => {
4469
4469
  if (c === l) {
4470
- let f = g.clientX;
4470
+ let f = h.clientX;
4471
4471
  return f === b.navSize ? b : f <= Ol ? {
4472
4472
  ...b,
4473
4473
  navSize: 0
@@ -4477,16 +4477,16 @@ function Ml({
4477
4477
  } : {
4478
4478
  ...b,
4479
4479
  // @ts-expect-error (non strict)
4480
- navSize: Al(f, 0, g.view.innerWidth)
4480
+ navSize: Al(f, 0, h.view.innerWidth)
4481
4481
  };
4482
4482
  }
4483
4483
  if (c === n) {
4484
4484
  let f = b.panelPosition === "bottom" ? "bottomPanelHeight" : "rightPanelWidth", y = b.panelPosition === "bottom" ? (
4485
4485
  // @ts-expect-error (non strict)
4486
- g.view.innerHeight - g.clientY
4486
+ h.view.innerHeight - h.clientY
4487
4487
  ) : (
4488
4488
  // @ts-expect-error (non strict)
4489
- g.view.innerWidth - g.clientX
4489
+ h.view.innerWidth - h.clientX
4490
4490
  );
4491
4491
  if (y === b[f])
4492
4492
  return b;
@@ -4504,20 +4504,20 @@ function Ml({
4504
4504
  Er
4505
4505
  )
4506
4506
  };
4507
- let S = (
4507
+ let I = (
4508
4508
  // @ts-expect-error (non strict)
4509
- b.panelPosition === "bottom" ? g.view.innerHeight : g.view.innerWidth
4509
+ b.panelPosition === "bottom" ? h.view.innerHeight : h.view.innerWidth
4510
4510
  );
4511
4511
  return {
4512
4512
  ...b,
4513
- [f]: Al(y, 0, S)
4513
+ [f]: Al(y, 0, I)
4514
4514
  };
4515
4515
  }
4516
4516
  return b;
4517
4517
  });
4518
4518
  }, "onDrag");
4519
- return n?.addEventListener("mousedown", p), l?.addEventListener("mousedown", p), () => {
4520
- n?.removeEventListener("mousedown", p), l?.removeEventListener("mousedown", p), u?.removeAttribute("style");
4519
+ return n?.addEventListener("mousedown", d), l?.addEventListener("mousedown", d), () => {
4520
+ n?.removeEventListener("mousedown", d), l?.removeEventListener("mousedown", d), u?.removeAttribute("style");
4521
4521
  };
4522
4522
  }, [
4523
4523
  // we need to rerun this effect when the panel is shown/hidden or when changing between mobile/desktop to re-attach the event listeners
@@ -4531,82 +4531,83 @@ a(Ml, "useDragging");
4531
4531
  // src/manager/components/layout/Layout.tsx
4532
4532
  var Ab = 100, Ll = /* @__PURE__ */ a((e, t) => e.navSize === t.navSize && e.bottomPanelHeight === t.bottomPanelHeight && e.rightPanelWidth ===
4533
4533
  t.rightPanelWidth && e.panelPosition === t.panelPosition, "layoutStateIsEqual"), Db = /* @__PURE__ */ a(({
4534
- managerLayoutState: e,
4535
- setManagerLayoutState: t,
4536
- isDesktop: o,
4537
- hasTab: i
4534
+ api: e,
4535
+ managerLayoutState: t,
4536
+ setManagerLayoutState: o,
4537
+ isDesktop: i,
4538
+ hasTab: r
4538
4539
  }) => {
4539
- let r = s.useRef(e), [n, l] = K({
4540
- ...e,
4540
+ let n = s.useRef(t), [l, u] = K({
4541
+ ...t,
4541
4542
  isDragging: !1
4542
4543
  });
4543
4544
  V(() => {
4544
- n.isDragging || // don't interrupt user's drag
4545
- Ll(e, r.current) || (r.current = e, l((f) => ({ ...f, ...e })));
4546
- }, [n.isDragging, e, l]), Xt(() => {
4547
- if (n.isDragging || // wait with syncing managerLayoutState until user is done dragging
4548
- Ll(e, n))
4545
+ l.isDragging || // don't interrupt user's drag
4546
+ Ll(t, n.current) || (n.current = t, u((I) => ({ ...I, ...t })));
4547
+ }, [l.isDragging, t, u]), Xt(() => {
4548
+ if (l.isDragging || // wait with syncing managerLayoutState until user is done dragging
4549
+ Ll(t, l))
4549
4550
  return;
4550
- let f = {
4551
- navSize: n.navSize,
4552
- bottomPanelHeight: n.bottomPanelHeight,
4553
- rightPanelWidth: n.rightPanelWidth
4551
+ let I = {
4552
+ navSize: l.navSize,
4553
+ bottomPanelHeight: l.bottomPanelHeight,
4554
+ rightPanelWidth: l.rightPanelWidth
4554
4555
  };
4555
- r.current = {
4556
- ...r.current,
4557
- ...f
4558
- }, t(f);
4559
- }, [n, t]);
4560
- let u = e.viewMode !== "story" && e.viewMode !== "docs", c = e.viewMode === "story" && !i, { panelResizerRef: p, sidebarResizerRef: d } = Ml(
4556
+ n.current = {
4557
+ ...n.current,
4558
+ ...I
4559
+ }, o(I);
4560
+ }, [l, o]);
4561
+ let c = t.viewMode !== "story" && t.viewMode !== "docs", d = t.viewMode === "story" && !r, { panelResizerRef: p, sidebarResizerRef: m } = Ml(
4561
4562
  {
4562
- setState: l,
4563
- isPanelShown: c,
4564
- isDesktop: o
4565
- }), { navSize: m, rightPanelWidth: g, bottomPanelHeight: b } = n.isDragging ? n : e;
4563
+ setState: u,
4564
+ isPanelShown: d,
4565
+ isDesktop: i
4566
+ }), { navSize: h, rightPanelWidth: b, bottomPanelHeight: f } = l.isDragging ? l : t;
4566
4567
  return {
4567
- navSize: m,
4568
- rightPanelWidth: g,
4569
- bottomPanelHeight: b,
4570
- panelPosition: e.panelPosition,
4568
+ navSize: e.getNavSizeWithCustomisations?.(h) ?? h,
4569
+ rightPanelWidth: b,
4570
+ bottomPanelHeight: f,
4571
+ panelPosition: t.panelPosition,
4571
4572
  panelResizerRef: p,
4572
- sidebarResizerRef: d,
4573
- showPages: u,
4574
- showPanel: c,
4575
- isDragging: n.isDragging
4573
+ sidebarResizerRef: m,
4574
+ showPages: c,
4575
+ showPanel: d,
4576
+ isDragging: l.isDragging
4576
4577
  };
4577
4578
  }, "useLayoutSyncingState"), Fl = /* @__PURE__ */ a(({ managerLayoutState: e, setManagerLayoutState: t, hasTab: o, ...i }) => {
4578
- let { isDesktop: r, isMobile: n } = ge(), {
4579
- navSize: l,
4580
- rightPanelWidth: u,
4581
- bottomPanelHeight: c,
4579
+ let { isDesktop: r, isMobile: n } = ge(), l = oe(), {
4580
+ navSize: u,
4581
+ rightPanelWidth: c,
4582
+ bottomPanelHeight: d,
4582
4583
  panelPosition: p,
4583
- panelResizerRef: d,
4584
- sidebarResizerRef: m,
4585
- showPages: g,
4586
- showPanel: b,
4587
- isDragging: f
4588
- } = Db({ managerLayoutState: e, setManagerLayoutState: t, isDesktop: r, hasTab: o });
4584
+ panelResizerRef: m,
4585
+ sidebarResizerRef: h,
4586
+ showPages: b,
4587
+ showPanel: f,
4588
+ isDragging: y
4589
+ } = Db({ api: l, managerLayoutState: e, setManagerLayoutState: t, isDesktop: r, hasTab: o });
4589
4590
  return /* @__PURE__ */ s.createElement(
4590
4591
  Mb,
4591
4592
  {
4592
- navSize: l,
4593
- rightPanelWidth: u,
4594
- bottomPanelHeight: c,
4593
+ navSize: u,
4594
+ rightPanelWidth: c,
4595
+ bottomPanelHeight: d,
4595
4596
  panelPosition: e.panelPosition,
4596
- isDragging: f,
4597
+ isDragging: y,
4597
4598
  viewMode: e.viewMode,
4598
- showPanel: b
4599
+ showPanel: f
4599
4600
  },
4600
- g && /* @__PURE__ */ s.createElement(Fb, null, i.slotPages),
4601
- /* @__PURE__ */ s.createElement(Na, { path: /(^\/story|docs|onboarding\/|^\/$)/, startsWith: !1 }, ({ match: y }) => /* @__PURE__ */ s.createElement(
4602
- Nb, { shown: !!y }, i.slotMain)),
4603
- r && /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.createElement(Lb, null, /* @__PURE__ */ s.createElement(Nl, { ref: m }),
4604
- i.slotSidebar), b && /* @__PURE__ */ s.createElement(Rb, { position: p }, /* @__PURE__ */ s.createElement(
4601
+ b && /* @__PURE__ */ s.createElement(Fb, null, i.slotPages),
4602
+ /* @__PURE__ */ s.createElement(Na, { path: /(^\/story|docs|onboarding\/|^\/$)/, startsWith: !1 }, ({ match: I }) => /* @__PURE__ */ s.createElement(
4603
+ Nb, { shown: !!I }, i.slotMain)),
4604
+ r && /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.createElement(Lb, null, /* @__PURE__ */ s.createElement(Nl, { ref: h }),
4605
+ i.slotSidebar), f && /* @__PURE__ */ s.createElement(Rb, { position: p }, /* @__PURE__ */ s.createElement(
4605
4606
  Nl,
4606
4607
  {
4607
4608
  orientation: p === "bottom" ? "horizontal" : "vertical",
4608
4609
  position: p === "bottom" ? "left" : "right",
4609
- ref: d
4610
+ ref: m
4610
4611
  }
4611
4612
  ), i.slotPanel)),
4612
4613
  n && /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.createElement(Il, null), /* @__PURE__ */ s.createElement(
@@ -4614,7 +4615,7 @@ t.rightPanelWidth && e.panelPosition === t.panelPosition, "layoutStateIsEqual"),
4614
4615
  {
4615
4616
  menu: i.slotSidebar,
4616
4617
  panel: i.slotPanel,
4617
- showPanel: b
4618
+ showPanel: f
4618
4619
  }
4619
4620
  ))
4620
4621
  );
@@ -4714,7 +4715,7 @@ t.rightPanelWidth && e.panelPosition === t.panelPosition, "layoutStateIsEqual"),
4714
4715
  );
4715
4716
 
4716
4717
  // global-externals:storybook/internal/types
4717
- var vO = __STORYBOOK_TYPES__, { Addon_TypesEnum: Ce } = __STORYBOOK_TYPES__;
4718
+ var xO = __STORYBOOK_TYPES__, { Addon_TypesEnum: Ce } = __STORYBOOK_TYPES__;
4718
4719
 
4719
4720
  // src/core-events/index.ts
4720
4721
  var Rl = /* @__PURE__ */ ((z) => (z.CHANNEL_WS_DISCONNECT = "channelWSDisconnect", z.CHANNEL_CREATED = "channelCreated", z.CONFIG_ERROR = "c\
@@ -4735,62 +4736,62 @@ eComponentSearchRequest", z.FILE_COMPONENT_SEARCH_RESPONSE = "fileComponentSearc
4735
4736
  "saveStoryResponse", z.ARGTYPES_INFO_REQUEST = "argtypesInfoRequest", z.ARGTYPES_INFO_RESPONSE = "argtypesInfoResponse", z.CREATE_NEW_STORYFILE_REQUEST =
4736
4737
  "createNewStoryfileRequest", z.CREATE_NEW_STORYFILE_RESPONSE = "createNewStoryfileResponse", z))(Rl || {});
4737
4738
  var {
4738
- CHANNEL_WS_DISCONNECT: IO,
4739
- CHANNEL_CREATED: SO,
4740
- CONFIG_ERROR: wO,
4741
- CREATE_NEW_STORYFILE_REQUEST: EO,
4742
- CREATE_NEW_STORYFILE_RESPONSE: TO,
4743
- CURRENT_STORY_WAS_SET: CO,
4744
- DOCS_PREPARED: _O,
4745
- DOCS_RENDERED: kO,
4746
- FILE_COMPONENT_SEARCH_REQUEST: OO,
4747
- FILE_COMPONENT_SEARCH_RESPONSE: PO,
4748
- FORCE_RE_RENDER: AO,
4749
- FORCE_REMOUNT: DO,
4750
- GLOBALS_UPDATED: MO,
4751
- NAVIGATE_URL: LO,
4752
- PLAY_FUNCTION_THREW_EXCEPTION: NO,
4753
- UNHANDLED_ERRORS_WHILE_PLAYING: FO,
4754
- PRELOAD_ENTRIES: RO,
4755
- PREVIEW_BUILDER_PROGRESS: BO,
4756
- PREVIEW_KEYDOWN: HO,
4757
- REGISTER_SUBSCRIPTION: zO,
4758
- RESET_STORY_ARGS: WO,
4759
- SELECT_STORY: VO,
4760
- SET_CONFIG: jO,
4761
- SET_CURRENT_STORY: KO,
4762
- SET_FILTER: $O,
4763
- SET_GLOBALS: UO,
4764
- SET_INDEX: GO,
4765
- SET_STORIES: qO,
4766
- SHARED_STATE_CHANGED: YO,
4767
- SHARED_STATE_SET: QO,
4768
- STORIES_COLLAPSE_ALL: XO,
4769
- STORIES_EXPAND_ALL: ZO,
4770
- STORY_ARGS_UPDATED: JO,
4771
- STORY_CHANGED: eP,
4772
- STORY_ERRORED: tP,
4773
- STORY_INDEX_INVALIDATED: oP,
4774
- STORY_MISSING: rP,
4739
+ CHANNEL_WS_DISCONNECT: SO,
4740
+ CHANNEL_CREATED: wO,
4741
+ CONFIG_ERROR: EO,
4742
+ CREATE_NEW_STORYFILE_REQUEST: TO,
4743
+ CREATE_NEW_STORYFILE_RESPONSE: CO,
4744
+ CURRENT_STORY_WAS_SET: _O,
4745
+ DOCS_PREPARED: kO,
4746
+ DOCS_RENDERED: OO,
4747
+ FILE_COMPONENT_SEARCH_REQUEST: PO,
4748
+ FILE_COMPONENT_SEARCH_RESPONSE: AO,
4749
+ FORCE_RE_RENDER: DO,
4750
+ FORCE_REMOUNT: MO,
4751
+ GLOBALS_UPDATED: LO,
4752
+ NAVIGATE_URL: NO,
4753
+ PLAY_FUNCTION_THREW_EXCEPTION: FO,
4754
+ UNHANDLED_ERRORS_WHILE_PLAYING: RO,
4755
+ PRELOAD_ENTRIES: BO,
4756
+ PREVIEW_BUILDER_PROGRESS: HO,
4757
+ PREVIEW_KEYDOWN: zO,
4758
+ REGISTER_SUBSCRIPTION: WO,
4759
+ RESET_STORY_ARGS: VO,
4760
+ SELECT_STORY: jO,
4761
+ SET_CONFIG: KO,
4762
+ SET_CURRENT_STORY: $O,
4763
+ SET_FILTER: UO,
4764
+ SET_GLOBALS: GO,
4765
+ SET_INDEX: qO,
4766
+ SET_STORIES: YO,
4767
+ SHARED_STATE_CHANGED: QO,
4768
+ SHARED_STATE_SET: XO,
4769
+ STORIES_COLLAPSE_ALL: ZO,
4770
+ STORIES_EXPAND_ALL: JO,
4771
+ STORY_ARGS_UPDATED: eP,
4772
+ STORY_CHANGED: tP,
4773
+ STORY_ERRORED: oP,
4774
+ STORY_INDEX_INVALIDATED: rP,
4775
+ STORY_MISSING: nP,
4775
4776
  STORY_PREPARED: Bl,
4776
- STORY_RENDER_PHASE_CHANGED: nP,
4777
- STORY_RENDERED: iP,
4778
- STORY_FINISHED: sP,
4779
- STORY_SPECIFIED: aP,
4780
- STORY_THREW_EXCEPTION: lP,
4781
- STORY_UNCHANGED: uP,
4782
- UPDATE_GLOBALS: cP,
4783
- UPDATE_QUERY_PARAMS: pP,
4784
- UPDATE_STORY_ARGS: dP,
4785
- REQUEST_WHATS_NEW_DATA: fP,
4786
- RESULT_WHATS_NEW_DATA: mP,
4787
- SET_WHATS_NEW_CACHE: hP,
4788
- TOGGLE_WHATS_NEW_NOTIFICATIONS: gP,
4789
- TELEMETRY_ERROR: yP,
4790
- SAVE_STORY_REQUEST: bP,
4791
- SAVE_STORY_RESPONSE: vP,
4792
- ARGTYPES_INFO_REQUEST: xP,
4793
- ARGTYPES_INFO_RESPONSE: IP
4777
+ STORY_RENDER_PHASE_CHANGED: iP,
4778
+ STORY_RENDERED: sP,
4779
+ STORY_FINISHED: aP,
4780
+ STORY_SPECIFIED: lP,
4781
+ STORY_THREW_EXCEPTION: uP,
4782
+ STORY_UNCHANGED: cP,
4783
+ UPDATE_GLOBALS: pP,
4784
+ UPDATE_QUERY_PARAMS: dP,
4785
+ UPDATE_STORY_ARGS: fP,
4786
+ REQUEST_WHATS_NEW_DATA: mP,
4787
+ RESULT_WHATS_NEW_DATA: hP,
4788
+ SET_WHATS_NEW_CACHE: gP,
4789
+ TOGGLE_WHATS_NEW_NOTIFICATIONS: yP,
4790
+ TELEMETRY_ERROR: bP,
4791
+ SAVE_STORY_REQUEST: vP,
4792
+ SAVE_STORY_RESPONSE: xP,
4793
+ ARGTYPES_INFO_REQUEST: IP,
4794
+ ARGTYPES_INFO_RESPONSE: SP
4794
4795
  } = Rl;
4795
4796
 
4796
4797
  // src/manager/components/panel/Panel.tsx
@@ -4858,10 +4859,10 @@ ock advanced features."),
4858
4859
  )) : /* @__PURE__ */ s.createElement(ee, { onClick: () => u(!1), title: "Close addon panel" }, /* @__PURE__ */ s.createElement(Ke, null))),
4859
4860
  id: "storybook-panel-root"
4860
4861
  },
4861
- Object.entries(e).map(([c, p]) => (
4862
+ Object.entries(e).map(([c, d]) => (
4862
4863
  // @ts-expect-error (we know this is broken)
4863
- /* @__PURE__ */ s.createElement(Ti, { key: c, id: c, title: typeof p.title == "function" ? /* @__PURE__ */ s.createElement(p.title, null) :
4864
- p.title }, p.render)
4864
+ /* @__PURE__ */ s.createElement(Ti, { key: c, id: c, title: typeof d.title == "function" ? /* @__PURE__ */ s.createElement(d.title, null) :
4865
+ d.title }, d.render)
4865
4866
  ))
4866
4867
  );
4867
4868
  }
@@ -4886,20 +4887,20 @@ var Hb = /* @__PURE__ */ a((e) => {
4886
4887
  );
4887
4888
  let { parameters: n, type: l } = i ?? {}, u = U(
4888
4889
  () => ({
4889
- onSelect: /* @__PURE__ */ a((p) => t.setSelectedPanel(p), "onSelect"),
4890
+ onSelect: /* @__PURE__ */ a((d) => t.setSelectedPanel(d), "onSelect"),
4890
4891
  toggleVisibility: /* @__PURE__ */ a(() => t.togglePanel(), "toggleVisibility"),
4891
4892
  togglePosition: /* @__PURE__ */ a(() => t.togglePanelPosition(), "togglePosition")
4892
4893
  }),
4893
4894
  [t]
4894
4895
  ), c = U(() => {
4895
- let p = t.getElements(Ce.PANEL);
4896
- if (!p || l !== "story")
4897
- return p;
4898
- let d = {};
4899
- return Object.entries(p).forEach(([m, g]) => {
4900
- let { paramKey: b } = g;
4901
- b && n && n[b] && n[b].disable || g.disabled === !0 || typeof g.disabled == "function" && g.disabled(n) || (d[m] = g);
4902
- }), d;
4896
+ let d = t.getElements(Ce.PANEL);
4897
+ if (!d || l !== "story")
4898
+ return d;
4899
+ let p = {};
4900
+ return Object.entries(d).forEach(([m, h]) => {
4901
+ let { paramKey: b } = h;
4902
+ b && n && n[b] && n[b].disable || h.disabled === !0 || typeof h.disabled == "function" && h.disabled(n) || (p[m] = h);
4903
+ }), p;
4903
4904
  }, [t, l, n]);
4904
4905
  return /* @__PURE__ */ s.createElement(
4905
4906
  Ci,
@@ -4936,7 +4937,7 @@ function Wl(e) {
4936
4937
  zb,
4937
4938
  {
4938
4939
  "data-is-storybook": t ? "true" : "false",
4939
- onLoad: (p) => p.currentTarget.setAttribute("data-is-loaded", "true"),
4940
+ onLoad: (d) => d.currentTarget.setAttribute("data-is-loaded", "true"),
4940
4941
  id: o,
4941
4942
  title: i,
4942
4943
  src: r,
@@ -4995,27 +4996,27 @@ var dv = /* @__PURE__ */ a((e, t) => e && t[e] ? `storybook-ref-${e}` : "storybo
4995
4996
  let u = e[i]?.version, c = tu({
4996
4997
  ...r,
4997
4998
  ...u && { version: u }
4998
- }), p = dv(i, e), { current: d } = q({}), m = Object.values(e).filter((g) => g.type === "auto-inject" || g.id === i, {});
4999
- return d["storybook-preview-iframe"] || (d["storybook-preview-iframe"] = to(n, l, {
4999
+ }), d = dv(i, e), { current: p } = q({}), m = Object.values(e).filter((h) => h.type === "auto-inject" || h.id === i, {});
5000
+ return p["storybook-preview-iframe"] || (p["storybook-preview-iframe"] = to(n, l, {
5000
5001
  ...r,
5001
5002
  ...u && { version: u },
5002
5003
  viewMode: o
5003
- })), m.forEach((g) => {
5004
- let b = `storybook-ref-${g.id}`, f = d[b]?.split("/iframe.html")[0];
5005
- if (!f || g.url !== f) {
5006
- let y = `${g.url}/iframe.html?id=${l}&viewMode=${o}&refId=${g.id}${c}`;
5007
- d[b] = y;
5004
+ })), m.forEach((h) => {
5005
+ let b = `storybook-ref-${h.id}`, f = p[b]?.split("/iframe.html")[0];
5006
+ if (!f || h.url !== f) {
5007
+ let y = `${h.url}/iframe.html?id=${l}&viewMode=${o}&refId=${h.id}${c}`;
5008
+ p[b] = y;
5008
5009
  }
5009
5010
  }), /* @__PURE__ */ s.createElement(Ee, null, /* @__PURE__ */ s.createElement(eo, { styles: hv }), /* @__PURE__ */ s.createElement(me, { filter: mv },
5010
- ({ isFullscreen: g, isNavShown: b, selectedStoryId: f }) => g || !b || !f ? null : /* @__PURE__ */ s.createElement(fv, { asChild: !0 }, /* @__PURE__ */ s.
5011
- createElement("a", { href: `#${f}`, tabIndex: 0, title: "Skip to sidebar" }, "Skip to sidebar"))), Object.entries(d).map(([g, b]) => /* @__PURE__ */ s.
5012
- createElement(Ee, { key: g }, /* @__PURE__ */ s.createElement(
5011
+ ({ isFullscreen: h, isNavShown: b, selectedStoryId: f }) => h || !b || !f ? null : /* @__PURE__ */ s.createElement(fv, { asChild: !0 }, /* @__PURE__ */ s.
5012
+ createElement("a", { href: `#${f}`, tabIndex: 0, title: "Skip to sidebar" }, "Skip to sidebar"))), Object.entries(p).map(([h, b]) => /* @__PURE__ */ s.
5013
+ createElement(Ee, { key: h }, /* @__PURE__ */ s.createElement(
5013
5014
  Wl,
5014
5015
  {
5015
- active: g === p,
5016
- key: g,
5017
- id: g,
5018
- title: g,
5016
+ active: h === d,
5017
+ key: h,
5018
+ id: h,
5019
+ title: h,
5019
5020
  src: b,
5020
5021
  allowFullScreen: !0,
5021
5022
  scale: t
@@ -5327,11 +5328,11 @@ var vu = x.main({
5327
5328
  height: "100%"
5328
5329
  },
5329
5330
  ({ show: e }) => ({ display: e ? "grid" : "none" })
5330
- ), hD = x(cr)({
5331
+ ), gD = x(cr)({
5331
5332
  color: "inherit",
5332
5333
  textDecoration: "inherit",
5333
5334
  display: "inline-block"
5334
- }), gD = x.span({
5335
+ }), yD = x.span({
5335
5336
  // Hides full screen icon at mobile breakpoint defined in app.js
5336
5337
  "@media (max-width: 599px)": {
5337
5338
  display: "none"
@@ -5402,24 +5403,25 @@ var Rv = /* @__PURE__ */ a(({ state: e, api: t }) => ({
5402
5403
  storyId: l,
5403
5404
  entry: u = void 0,
5404
5405
  description: c,
5405
- baseUrl: p,
5406
- withLoader: d = !0,
5406
+ baseUrl: d,
5407
+ withLoader: p = !0,
5407
5408
  tools: m,
5408
- toolsExtra: g,
5409
+ toolsExtra: h,
5409
5410
  tabs: b,
5410
5411
  wrappers: f,
5411
5412
  tabId: y
5412
- } = t, S = b.find((I) => I.id === y)?.render, E = n === "story", { showToolbar: h } = r, v = q(l);
5413
+ } = t, I = b.find((w) => w.id === y)?.render, E = n === "story", { showToolbar: g } = r, v = o.getShowToolbarWithCustomisations(g), S = q(
5414
+ l);
5413
5415
  return V(() => {
5414
5416
  if (u && n) {
5415
- if (l === v.current)
5417
+ if (l === S.current)
5416
5418
  return;
5417
- if (v.current = l, n.match(/docs|story/)) {
5418
- let { refId: I, id: w } = u;
5419
+ if (S.current = l, n.match(/docs|story/)) {
5420
+ let { refId: w, id: O } = u;
5419
5421
  o.emit(ia, {
5420
- storyId: w,
5422
+ storyId: O,
5421
5423
  viewMode: n,
5422
- options: { target: I }
5424
+ options: { target: w }
5423
5425
  });
5424
5426
  }
5425
5427
  }
@@ -5429,15 +5431,15 @@ var Rv = /* @__PURE__ */ a(({ state: e, api: t }) => ({
5429
5431
  yu,
5430
5432
  {
5431
5433
  key: "tools",
5432
- isShown: h,
5434
+ isShown: v,
5433
5435
  tabId: y,
5434
5436
  tabs: b,
5435
5437
  tools: m,
5436
- toolsExtra: g,
5438
+ toolsExtra: h,
5437
5439
  api: o
5438
5440
  }
5439
- ), /* @__PURE__ */ s.createElement(xu, { key: "frame" }, S && /* @__PURE__ */ s.createElement(Pr, null, S({ active: !0 })), /* @__PURE__ */ s.
5440
- createElement(Iu, { show: !y }, /* @__PURE__ */ s.createElement(Bv, { withLoader: d, baseUrl: p, wrappers: f }))))));
5441
+ ), /* @__PURE__ */ s.createElement(xu, { key: "frame" }, I && /* @__PURE__ */ s.createElement(Pr, null, I({ active: !0 })), /* @__PURE__ */ s.
5442
+ createElement(Iu, { show: !y }, /* @__PURE__ */ s.createElement(Bv, { withLoader: p, baseUrl: d, wrappers: f }))))));
5441
5443
  }, "Preview"));
5442
5444
  var Bv = /* @__PURE__ */ a(({ baseUrl: e, withLoader: t, wrappers: o }) => /* @__PURE__ */ s.createElement(me, { filter: Rv }, ({
5443
5445
  entry: i,
@@ -5446,10 +5448,10 @@ var Bv = /* @__PURE__ */ a(({ baseUrl: e, withLoader: t, wrappers: o }) => /* @_
5446
5448
  storyId: l,
5447
5449
  refId: u,
5448
5450
  viewMode: c,
5449
- queryParams: p,
5450
- previewInitialized: d
5451
+ queryParams: d,
5452
+ previewInitialized: p
5451
5453
  }) => {
5452
- let m = "canvas", [g, b] = K(void 0);
5454
+ let m = "canvas", [h, b] = K(void 0);
5453
5455
  V(() => {
5454
5456
  if (se.CONFIG_TYPE === "DEVELOPMENT")
5455
5457
  try {
@@ -5459,19 +5461,19 @@ var Bv = /* @__PURE__ */ a(({ baseUrl: e, withLoader: t, wrappers: o }) => /* @_
5459
5461
  } catch {
5460
5462
  }
5461
5463
  }, []);
5462
- let f = !!r[u] && !r[u].previewInitialized, y = !(g?.value === 1 || g === void 0), S = !u && (!d || y), E = i && f || S;
5463
- return /* @__PURE__ */ s.createElement(Ni, null, ({ value: h }) => /* @__PURE__ */ s.createElement(s.Fragment, null, t && E && /* @__PURE__ */ s.
5464
- createElement(Su, null, /* @__PURE__ */ s.createElement(rr, { id: "preview-loader", role: "progressbar", progress: g })), /* @__PURE__ */ s.
5465
- createElement(wu, { id: m, storyId: l, viewMode: c, wrappers: o }, n ? n(l, c, m, e, h, p) : /* @__PURE__ */ s.createElement(
5464
+ let f = !!r[u] && !r[u].previewInitialized, y = !(h?.value === 1 || h === void 0), I = !u && (!p || y), E = i && f || I;
5465
+ return /* @__PURE__ */ s.createElement(Ni, null, ({ value: g }) => /* @__PURE__ */ s.createElement(s.Fragment, null, t && E && /* @__PURE__ */ s.
5466
+ createElement(Su, null, /* @__PURE__ */ s.createElement(rr, { id: "preview-loader", role: "progressbar", progress: h })), /* @__PURE__ */ s.
5467
+ createElement(wu, { id: m, storyId: l, viewMode: c, wrappers: o }, n ? n(l, c, m, e, g, d) : /* @__PURE__ */ s.createElement(
5466
5468
  ou,
5467
5469
  {
5468
5470
  baseUrl: e,
5469
5471
  refs: r,
5470
- scale: h,
5472
+ scale: g,
5471
5473
  entry: i,
5472
5474
  viewMode: c,
5473
5475
  refId: u,
5474
- queryParams: p,
5476
+ queryParams: d,
5475
5477
  storyId: l
5476
5478
  }
5477
5479
  ))));
@@ -5488,9 +5490,9 @@ function _u(e, t) {
5488
5490
  let u = n.find((c) => c.id === l.id);
5489
5491
  return u === void 0 || u.id === "canvas" || !u.hidden;
5490
5492
  }).map((l, u) => ({ ...l, index: u })).sort((l, u) => {
5491
- let c = n.find((g) => g.id === l.id), p = c ? c.index : n.length + l.index, d = n.find((g) => g.id === u.id), m = d ? d.index : n.length +
5493
+ let c = n.find((h) => h.id === l.id), d = c ? c.index : n.length + l.index, p = n.find((h) => h.id === u.id), m = p ? p.index : n.length +
5492
5494
  u.index;
5493
- return p - m;
5495
+ return d - m;
5494
5496
  }).map((l) => {
5495
5497
  let u = n.find((c) => c.id === l.id);
5496
5498
  return u ? {
@@ -5543,10 +5545,10 @@ var zv = [Tu()], Wv = [ku, du, mu], Vv = [ru, gu, pu, cu], jv = [], Kv = (0, No.
5543
5545
  state: t
5544
5546
  // @ts-expect-error (non strict)
5545
5547
  }) => {
5546
- let { layout: o, location: i, customQueryParams: r, storyId: n, refs: l, viewMode: u, path: c, refId: p } = t, d = e.getData(n, p), m = Object.
5547
- values(e.getElements(Ce.TAB)), g = Object.values(e.getElements(Ce.PREVIEW)), b = Object.values(e.getElements(Ce.TOOL)), f = Object.values(
5548
- e.getElements(Ce.TOOLEXTRA)), y = e.getQueryParam("tab"), S = $v(b.length, e.getElements(Ce.TOOL), [
5549
- d,
5548
+ let { layout: o, location: i, customQueryParams: r, storyId: n, refs: l, viewMode: u, path: c, refId: d } = t, p = e.getData(n, d), m = Object.
5549
+ values(e.getElements(Ce.TAB)), h = Object.values(e.getElements(Ce.PREVIEW)), b = Object.values(e.getElements(Ce.TOOL)), f = Object.values(
5550
+ e.getElements(Ce.TOOLEXTRA)), y = e.getQueryParam("tab"), I = $v(b.length, e.getElements(Ce.TOOL), [
5551
+ p,
5550
5552
  u,
5551
5553
  i,
5552
5554
  c,
@@ -5556,28 +5558,28 @@ var zv = [Tu()], Wv = [ku, du, mu], Vv = [ru, gu, pu, cu], jv = [], Kv = (0, No.
5556
5558
  f.length,
5557
5559
  e.getElements(Ce.TOOLEXTRA),
5558
5560
  // @ts-expect-error (non strict)
5559
- [d, u, i, c, y]
5561
+ [p, u, i, c, y]
5560
5562
  );
5561
5563
  return {
5562
5564
  api: e,
5563
- entry: d,
5565
+ entry: p,
5564
5566
  options: o,
5565
- description: Qv(d),
5567
+ description: Qv(p),
5566
5568
  viewMode: u,
5567
5569
  refs: l,
5568
5570
  storyId: n,
5569
5571
  baseUrl: qv || "iframe.html",
5570
5572
  queryParams: r,
5571
- tools: S,
5573
+ tools: I,
5572
5574
  toolsExtra: E,
5573
5575
  tabs: Kv(
5574
5576
  m.length,
5575
5577
  e.getElements(Ce.TAB),
5576
- d ? d.parameters : void 0,
5578
+ p ? p.parameters : void 0,
5577
5579
  o.showTabs
5578
5580
  ),
5579
5581
  wrappers: Gv(
5580
- g.length,
5582
+ h.length,
5581
5583
  e.getElements(Ce.PREVIEW)
5582
5584
  ),
5583
5585
  tabId: y
@@ -5624,19 +5626,19 @@ a(Au, "useMeasure");
5624
5626
  function Ht(e, t, o) {
5625
5627
  let i = o.initialDeps ?? [], r;
5626
5628
  function n() {
5627
- var l, u, c, p;
5628
- let d;
5629
- o.key && ((l = o.debug) != null && l.call(o)) && (d = Date.now());
5629
+ var l, u, c, d;
5630
+ let p;
5631
+ o.key && ((l = o.debug) != null && l.call(o)) && (p = Date.now());
5630
5632
  let m = e();
5631
5633
  if (!(m.length !== i.length || m.some((f, y) => i[y] !== f)))
5632
5634
  return r;
5633
5635
  i = m;
5634
5636
  let b;
5635
5637
  if (o.key && ((u = o.debug) != null && u.call(o)) && (b = Date.now()), r = t(...m), o.key && ((c = o.debug) != null && c.call(o))) {
5636
- let f = Math.round((Date.now() - d) * 100) / 100, y = Math.round((Date.now() - b) * 100) / 100, S = y / 16, E = /* @__PURE__ */ a((h, v) => {
5637
- for (h = String(h); h.length < v; )
5638
- h = " " + h;
5639
- return h;
5638
+ let f = Math.round((Date.now() - p) * 100) / 100, y = Math.round((Date.now() - b) * 100) / 100, I = y / 16, E = /* @__PURE__ */ a((g, v) => {
5639
+ for (g = String(g); g.length < v; )
5640
+ g = " " + g;
5641
+ return g;
5640
5642
  }, "pad");
5641
5643
  console.info(
5642
5644
  `%c\u23F1 ${E(y, 5)} /${E(f, 5)} ms`,
@@ -5645,12 +5647,12 @@ function Ht(e, t, o) {
5645
5647
  font-weight: bold;
5646
5648
  color: hsl(${Math.max(
5647
5649
  0,
5648
- Math.min(120 - 120 * S, 120)
5650
+ Math.min(120 - 120 * I, 120)
5649
5651
  )}deg 100% 31%);`,
5650
5652
  o?.key
5651
5653
  );
5652
5654
  }
5653
- return (p = o?.onChange) == null || p.call(o, r), r;
5655
+ return (d = o?.onChange) == null || d.call(o, r), r;
5654
5656
  }
5655
5657
  return a(n, "memoizedFunction"), n.updateDeps = (l) => {
5656
5658
  i = l;
@@ -5694,9 +5696,9 @@ var Jv = /* @__PURE__ */ a((e) => e, "defaultKeyExtractor"), e0 = /* @__PURE__ *
5694
5696
  let u = /* @__PURE__ */ a(() => {
5695
5697
  let c = l[0];
5696
5698
  if (c?.borderBoxSize) {
5697
- let p = c.borderBoxSize[0];
5698
- if (p) {
5699
- r({ width: p.inlineSize, height: p.blockSize });
5699
+ let d = c.borderBoxSize[0];
5700
+ if (d) {
5701
+ r({ width: d.inlineSize, height: d.blockSize });
5700
5702
  return;
5701
5703
  }
5702
5704
  }
@@ -5724,14 +5726,14 @@ var Nu = typeof window > "u" ? !0 : "onscrollend" in window, Ru = /* @__PURE__ *
5724
5726
  t(r, !1);
5725
5727
  },
5726
5728
  e.options.isScrollingResetDelay
5727
- ), l = /* @__PURE__ */ a((d) => () => {
5728
- let { horizontal: m, isRtl: g } = e.options;
5729
- r = m ? o.scrollLeft * (g && -1 || 1) : o.scrollTop, n(), t(r, d);
5729
+ ), l = /* @__PURE__ */ a((p) => () => {
5730
+ let { horizontal: m, isRtl: h } = e.options;
5731
+ r = m ? o.scrollLeft * (h && -1 || 1) : o.scrollTop, n(), t(r, p);
5730
5732
  }, "createHandler"), u = l(!0), c = l(!1);
5731
5733
  c(), o.addEventListener("scroll", u, Lu);
5732
- let p = e.options.useScrollendEvent && Nu;
5733
- return p && o.addEventListener("scrollend", c, Lu), () => {
5734
- o.removeEventListener("scroll", u), p && o.removeEventListener("scrollend", c);
5734
+ let d = e.options.useScrollendEvent && Nu;
5735
+ return d && o.addEventListener("scrollend", c, Lu), () => {
5736
+ o.removeEventListener("scroll", u), d && o.removeEventListener("scrollend", c);
5735
5737
  };
5736
5738
  }, "observeElementOffset");
5737
5739
  var t0 = /* @__PURE__ */ a((e, t, o) => {
@@ -5909,25 +5911,25 @@ var Bu = /* @__PURE__ */ a((e, {
5909
5911
  if (!l)
5910
5912
  return this.measurementsCache = [], this.itemSizeCache.clear(), [];
5911
5913
  this.measurementsCache.length === 0 && (this.measurementsCache = this.options.initialMeasurementsCache, this.measurementsCache.forEach(
5912
- (d) => {
5913
- this.itemSizeCache.set(d.key, d.size);
5914
+ (p) => {
5915
+ this.itemSizeCache.set(p.key, p.size);
5914
5916
  }));
5915
5917
  let c = this.pendingMeasuredCacheIndexes.length > 0 ? Math.min(...this.pendingMeasuredCacheIndexes) : 0;
5916
5918
  this.pendingMeasuredCacheIndexes = [];
5917
- let p = this.measurementsCache.slice(0, c);
5918
- for (let d = c; d < o; d++) {
5919
- let m = n(d), g = this.options.lanes === 1 ? p[d - 1] : this.getFurthestMeasurement(p, d), b = g ? g.end + this.options.gap : i + r,
5920
- f = u.get(m), y = typeof f == "number" ? f : this.options.estimateSize(d), S = b + y, E = g ? g.lane : d % this.options.lanes;
5921
- p[d] = {
5922
- index: d,
5919
+ let d = this.measurementsCache.slice(0, c);
5920
+ for (let p = c; p < o; p++) {
5921
+ let m = n(p), h = this.options.lanes === 1 ? d[p - 1] : this.getFurthestMeasurement(d, p), b = h ? h.end + this.options.gap : i + r,
5922
+ f = u.get(m), y = typeof f == "number" ? f : this.options.estimateSize(p), I = b + y, E = h ? h.lane : p % this.options.lanes;
5923
+ d[p] = {
5924
+ index: p,
5923
5925
  start: b,
5924
5926
  size: y,
5925
- end: S,
5927
+ end: I,
5926
5928
  key: m,
5927
5929
  lane: E
5928
5930
  };
5929
5931
  }
5930
- return this.measurementsCache = p, p;
5932
+ return this.measurementsCache = d, d;
5931
5933
  },
5932
5934
  {
5933
5935
  key: !1,
@@ -6029,9 +6031,9 @@ var Bu = /* @__PURE__ */ a((e, {
6029
6031
  }, this.getOffsetForAlignment = (o, i, r = 0) => {
6030
6032
  let n = this.getSize(), l = this.getScrollOffset();
6031
6033
  i === "auto" && (i = o >= l + n ? "end" : "start"), i === "center" ? o += (r - n) / 2 : i === "end" && (o -= n);
6032
- let u = this.options.horizontal ? "scrollWidth" : "scrollHeight", p = (this.scrollElement ? "document" in this.scrollElement ? this.scrollElement.
6034
+ let u = this.options.horizontal ? "scrollWidth" : "scrollHeight", d = (this.scrollElement ? "document" in this.scrollElement ? this.scrollElement.
6033
6035
  document.documentElement[u] : this.scrollElement[u] : 0) - n;
6034
- return Math.max(Math.min(p, o), 0);
6036
+ return Math.max(Math.min(d, o), 0);
6035
6037
  }, this.getOffsetForIndex = (o, i = "auto") => {
6036
6038
  o = Math.max(0, Math.min(o, this.options.count - 1));
6037
6039
  let r = this.measurementsCache[o];
@@ -6072,10 +6074,10 @@ var Bu = /* @__PURE__ */ a((e, {
6072
6074
  if (this.scrollToIndexTimeoutId = null, this.elementsCache.has(
6073
6075
  this.options.getItemKey(o)
6074
6076
  )) {
6075
- let [p] = Ar(
6077
+ let [d] = Ar(
6076
6078
  this.getOffsetForIndex(o, u)
6077
6079
  );
6078
- Du(p, this.getScrollOffset()) || this.scrollToIndex(o, { align: u, behavior: r });
6080
+ Du(d, this.getScrollOffset()) || this.scrollToIndex(o, { align: u, behavior: r });
6079
6081
  } else
6080
6082
  this.scrollToIndex(o, { align: u, behavior: r });
6081
6083
  }));
@@ -6149,14 +6151,14 @@ function o0({
6149
6151
  u++;
6150
6152
  else if (i > 1) {
6151
6153
  let c = Array(i).fill(0);
6152
- for (; u < r && c.some((d) => d < o + t); ) {
6153
- let d = e[u];
6154
- c[d.lane] = d.end, u++;
6154
+ for (; u < r && c.some((p) => p < o + t); ) {
6155
+ let p = e[u];
6156
+ c[p.lane] = p.end, u++;
6155
6157
  }
6156
- let p = Array(i).fill(o + t);
6157
- for (; l >= 0 && p.some((d) => d >= o); ) {
6158
- let d = e[l];
6159
- p[d.lane] = d.start, l--;
6158
+ let d = Array(i).fill(o + t);
6159
+ for (; l >= 0 && d.some((p) => p >= o); ) {
6160
+ let p = e[l];
6161
+ d[p.lane] = p.start, l--;
6160
6162
  }
6161
6163
  l = Math.max(0, l - l % i), u = Math.min(r, u + (i - 1 - u % i));
6162
6164
  }
@@ -6200,18 +6202,18 @@ var Vu = /* @__PURE__ */ a(({
6200
6202
  if (!e.current)
6201
6203
  return;
6202
6204
  let n = t.options.count, l = document.activeElement, u = parseInt(l.getAttribute("data-index") || "-1", 10), c = l.tagName === "INPUT",
6203
- p = /* @__PURE__ */ a(() => document.querySelector('[data-index="0"]'), "getFirstElement"), d = /* @__PURE__ */ a(() => document.querySelector(
6205
+ d = /* @__PURE__ */ a(() => document.querySelector('[data-index="0"]'), "getFirstElement"), p = /* @__PURE__ */ a(() => document.querySelector(
6204
6206
  `[data-index="${n - 1}"]`), "getLastElement");
6205
6207
  if (r.code === "ArrowDown" && l) {
6206
6208
  if (r.stopPropagation(), c) {
6207
- p()?.focus();
6209
+ d()?.focus();
6208
6210
  return;
6209
6211
  }
6210
6212
  if (u === n - 1) {
6211
6213
  Do(() => {
6212
6214
  t.scrollToIndex(0, { align: "start" });
6213
6215
  }), setTimeout(() => {
6214
- p()?.focus();
6216
+ d()?.focus();
6215
6217
  }, 100);
6216
6218
  return;
6217
6219
  }
@@ -6234,7 +6236,7 @@ var Vu = /* @__PURE__ */ a(({
6234
6236
  Do(() => {
6235
6237
  t.scrollToIndex(n - 1, { align: "start" });
6236
6238
  }), setTimeout(() => {
6237
- d()?.focus();
6239
+ p()?.focus();
6238
6240
  }, 100);
6239
6241
  return;
6240
6242
  }
@@ -6456,11 +6458,11 @@ var sc = x(En)(({ theme: e }) => ({
6456
6458
  errorItemId: r
6457
6459
  }) {
6458
6460
  let [n, l] = K(null), u = s.useRef(), c = U(() => [...o ?? []].sort((f, y) => {
6459
- let S = f.exportedComponents === null || f.exportedComponents?.length === 0, E = f.storyFileExists, h = y.exportedComponents === null ||
6461
+ let I = f.exportedComponents === null || f.exportedComponents?.length === 0, E = f.storyFileExists, g = y.exportedComponents === null ||
6460
6462
  y.exportedComponents?.length === 0, v = y.storyFileExists;
6461
- return E && !v ? -1 : v && !E || S && !h ? 1 : !S && h ? -1 : 0;
6462
- }), [o]), p = o?.length || 0, d = Wu({
6463
- count: p,
6463
+ return E && !v ? -1 : v && !E || I && !g ? 1 : !I && g ? -1 : 0;
6464
+ }), [o]), d = o?.length || 0, p = Wu({
6465
+ count: d,
6464
6466
  // @ts-expect-error (non strict)
6465
6467
  getScrollElement: /* @__PURE__ */ a(() => u.current, "getScrollElement"),
6466
6468
  paddingStart: 16,
@@ -6468,37 +6470,37 @@ var sc = x(En)(({ theme: e }) => ({
6468
6470
  estimateSize: /* @__PURE__ */ a(() => 54, "estimateSize"),
6469
6471
  overscan: 2
6470
6472
  });
6471
- Vu({ rowVirtualizer: d, parentRef: u, selectedItem: n });
6473
+ Vu({ rowVirtualizer: p, parentRef: u, selectedItem: n });
6472
6474
  let m = A(
6473
- ({ virtualItem: f, searchResult: y, itemId: S }) => {
6475
+ ({ virtualItem: f, searchResult: y, itemId: I }) => {
6474
6476
  y?.exportedComponents?.length > 1 ? l((E) => E === f.index ? null : f.index) : y?.exportedComponents?.length === 1 && i({
6475
6477
  componentExportName: y.exportedComponents[0].name,
6476
6478
  componentFilePath: y.filepath,
6477
6479
  componentIsDefaultExport: y.exportedComponents[0].default,
6478
- selectedItemId: S,
6480
+ selectedItemId: I,
6479
6481
  componentExportCount: 1
6480
6482
  });
6481
6483
  },
6482
6484
  [i]
6483
- ), g = A(
6484
- ({ searchResult: f, component: y, id: S }) => {
6485
+ ), h = A(
6486
+ ({ searchResult: f, component: y, id: I }) => {
6485
6487
  i({
6486
6488
  componentExportName: y.name,
6487
6489
  componentFilePath: f.filepath,
6488
6490
  componentIsDefaultExport: y.default,
6489
- selectedItemId: S,
6491
+ selectedItemId: I,
6490
6492
  // @ts-expect-error (non strict)
6491
6493
  componentExportCount: f.exportedComponents.length
6492
6494
  });
6493
6495
  },
6494
6496
  [i]
6495
6497
  ), b = A(
6496
- ({ virtualItem: f, selected: y, searchResult: S }) => {
6497
- let E = r === S.filepath, h = y === f.index;
6498
+ ({ virtualItem: f, selected: y, searchResult: I }) => {
6499
+ let E = r === I.filepath, g = y === f.index;
6498
6500
  return /* @__PURE__ */ s.createElement(
6499
6501
  Lr,
6500
6502
  {
6501
- "aria-expanded": h,
6503
+ "aria-expanded": g,
6502
6504
  "aria-controls": `file-list-export-${f.index}`,
6503
6505
  id: `file-list-item-wrapper-${f.index}`
6504
6506
  },
@@ -6506,16 +6508,16 @@ var sc = x(En)(({ theme: e }) => ({
6506
6508
  $u,
6507
6509
  {
6508
6510
  className: "file-list-item",
6509
- selected: h,
6511
+ selected: g,
6510
6512
  error: E,
6511
- disabled: S.exportedComponents === null || S.exportedComponents?.length === 0
6513
+ disabled: I.exportedComponents === null || I.exportedComponents?.length === 0
6512
6514
  },
6513
6515
  /* @__PURE__ */ s.createElement(qu, { error: E }, /* @__PURE__ */ s.createElement(Qo, null)),
6514
- /* @__PURE__ */ s.createElement(Gu, null, /* @__PURE__ */ s.createElement(Yu, { error: E }, S.filepath.split("/").at(-1)), /* @__PURE__ */ s.
6515
- createElement(Qu, null, S.filepath)),
6516
- h ? /* @__PURE__ */ s.createElement(a0, null) : /* @__PURE__ */ s.createElement(sc, null)
6516
+ /* @__PURE__ */ s.createElement(Gu, null, /* @__PURE__ */ s.createElement(Yu, { error: E }, I.filepath.split("/").at(-1)), /* @__PURE__ */ s.
6517
+ createElement(Qu, null, I.filepath)),
6518
+ g ? /* @__PURE__ */ s.createElement(a0, null) : /* @__PURE__ */ s.createElement(sc, null)
6517
6519
  ),
6518
- S?.exportedComponents?.length > 1 && h && /* @__PURE__ */ s.createElement(
6520
+ I?.exportedComponents?.length > 1 && g && /* @__PURE__ */ s.createElement(
6519
6521
  Xu,
6520
6522
  {
6521
6523
  role: "region",
@@ -6528,10 +6530,10 @@ var sc = x(En)(({ theme: e }) => ({
6528
6530
  v.key === "Enter" && v.stopPropagation();
6529
6531
  }
6530
6532
  },
6531
- S.exportedComponents?.map((v, I) => {
6532
- let w = r === `${S.filepath}_${I}`, O = I === 0 ? "first" : (
6533
+ I.exportedComponents?.map((v, S) => {
6534
+ let w = r === `${I.filepath}_${S}`, O = S === 0 ? "first" : (
6533
6535
  // @ts-expect-error (non strict)
6534
- I === S.exportedComponents.length - 1 ? "last" : "middle"
6536
+ S === I.exportedComponents.length - 1 ? "last" : "middle"
6535
6537
  );
6536
6538
  return /* @__PURE__ */ s.createElement(
6537
6539
  Zu,
@@ -6541,22 +6543,22 @@ var sc = x(En)(({ theme: e }) => ({
6541
6543
  key: v.name,
6542
6544
  error: w,
6543
6545
  onClick: () => {
6544
- g({
6545
- searchResult: S,
6546
+ h({
6547
+ searchResult: I,
6546
6548
  component: v,
6547
- id: `${S.filepath}_${I}`
6549
+ id: `${I.filepath}_${S}`
6548
6550
  });
6549
6551
  },
6550
6552
  onKeyUp: (_) => {
6551
- _.key === "Enter" && g({
6552
- searchResult: S,
6553
+ _.key === "Enter" && h({
6554
+ searchResult: I,
6553
6555
  component: v,
6554
- id: `${S.filepath}_${I}`
6556
+ id: `${I.filepath}_${S}`
6555
6557
  });
6556
6558
  }
6557
6559
  },
6558
6560
  /* @__PURE__ */ s.createElement(Ju, null, /* @__PURE__ */ s.createElement(Qo, null), v.default ? /* @__PURE__ */ s.createElement(
6559
- s.Fragment, null, /* @__PURE__ */ s.createElement(ec, null, S.filepath.split("/").at(-1)?.split(".")?.at(0)), /* @__PURE__ */ s.
6561
+ s.Fragment, null, /* @__PURE__ */ s.createElement(ec, null, I.filepath.split("/").at(-1)?.split(".")?.at(0)), /* @__PURE__ */ s.
6560
6562
  createElement(tc, null, "Default export")) : v.name),
6561
6563
  /* @__PURE__ */ s.createElement(sc, null)
6562
6564
  );
@@ -6564,7 +6566,7 @@ var sc = x(En)(({ theme: e }) => ({
6564
6566
  )
6565
6567
  );
6566
6568
  },
6567
- [g, r]
6569
+ [h, r]
6568
6570
  );
6569
6571
  return t && (o === null || o?.length === 0) ? /* @__PURE__ */ s.createElement(ic, null) : o?.length === 0 ? /* @__PURE__ */ s.createElement(
6570
6572
  oc, null, /* @__PURE__ */ s.createElement("p", null, "We could not find any file with that name"), /* @__PURE__ */ s.createElement(rc, null,
@@ -6573,17 +6575,17 @@ var sc = x(En)(({ theme: e }) => ({
6573
6575
  Uu,
6574
6576
  {
6575
6577
  style: {
6576
- height: `${d.getTotalSize()}px`
6578
+ height: `${p.getTotalSize()}px`
6577
6579
  }
6578
6580
  },
6579
- d.getVirtualItems().map((f) => {
6580
- let y = c[f.index], S = y.exportedComponents === null || y.exportedComponents?.length === 0, E = {};
6581
+ p.getVirtualItems().map((f) => {
6582
+ let y = c[f.index], I = y.exportedComponents === null || y.exportedComponents?.length === 0, E = {};
6581
6583
  return /* @__PURE__ */ s.createElement(
6582
6584
  Ku,
6583
6585
  {
6584
6586
  key: f.key,
6585
6587
  "data-index": f.index,
6586
- ref: d.measureElement,
6588
+ ref: p.measureElement,
6587
6589
  onClick: () => {
6588
6590
  m({
6589
6591
  virtualItem: f,
@@ -6591,8 +6593,8 @@ var sc = x(En)(({ theme: e }) => ({
6591
6593
  searchResult: y
6592
6594
  });
6593
6595
  },
6594
- onKeyUp: (h) => {
6595
- h.key === "Enter" && m({
6596
+ onKeyUp: (g) => {
6597
+ g.key === "Enter" && m({
6596
6598
  virtualItem: f,
6597
6599
  itemId: y.filepath,
6598
6600
  searchResult: y
@@ -6607,7 +6609,7 @@ var sc = x(En)(({ theme: e }) => ({
6607
6609
  },
6608
6610
  tabIndex: 0
6609
6611
  },
6610
- S ? /* @__PURE__ */ s.createElement(
6612
+ I ? /* @__PURE__ */ s.createElement(
6611
6613
  ve,
6612
6614
  {
6613
6615
  ...E,
@@ -6617,7 +6619,7 @@ var sc = x(En)(({ theme: e }) => ({
6617
6619
  tooltip: /* @__PURE__ */ s.createElement(
6618
6620
  rt,
6619
6621
  {
6620
- note: S ? "We can't evaluate exports for this file. You can't create a story for it automatically" : null
6622
+ note: I ? "We can't evaluate exports for this file. You can't create a story for it automatically" : null
6621
6623
  }
6622
6624
  )
6623
6625
  },
@@ -6733,12 +6735,12 @@ var l0 = 418, u0 = x(At)(() => ({
6733
6735
  searchResults: l,
6734
6736
  onCreateNewStory: u,
6735
6737
  setError: c,
6736
- container: p
6738
+ container: d
6737
6739
  }) => {
6738
- let [d, m] = Au(), [g, b] = K(m.height), [, f] = Gs(), [y, S] = K(o);
6740
+ let [p, m] = Au(), [h, b] = K(m.height), [, f] = Gs(), [y, I] = K(o);
6739
6741
  return V(() => {
6740
- g < m.height && b(m.height);
6741
- }, [m.height, g]), /* @__PURE__ */ s.createElement(
6742
+ h < m.height && b(m.height);
6743
+ }, [m.height, h]), /* @__PURE__ */ s.createElement(
6742
6744
  u0,
6743
6745
  {
6744
6746
  height: l0,
@@ -6751,9 +6753,9 @@ var l0 = 418, u0 = x(At)(() => ({
6751
6753
  onInteractOutside: () => {
6752
6754
  t(!1);
6753
6755
  },
6754
- container: p
6756
+ container: d
6755
6757
  },
6756
- /* @__PURE__ */ s.createElement(c0, { height: o === "" ? m.height : g }, /* @__PURE__ */ s.createElement(p0, { ref: d }, /* @__PURE__ */ s.
6758
+ /* @__PURE__ */ s.createElement(c0, { height: o === "" ? m.height : h }, /* @__PURE__ */ s.createElement(p0, { ref: p }, /* @__PURE__ */ s.
6757
6759
  createElement(At.Header, null, /* @__PURE__ */ s.createElement(At.Title, null, "Add a new story"), /* @__PURE__ */ s.createElement(At.Description,
6758
6760
  null, "We will create a new story for your component")), /* @__PURE__ */ s.createElement(f0, null, /* @__PURE__ */ s.createElement(m0, null,
6759
6761
  /* @__PURE__ */ s.createElement(So, null)), /* @__PURE__ */ s.createElement(
@@ -6765,9 +6767,9 @@ var l0 = 418, u0 = x(At)(() => ({
6765
6767
  autoFocus: !0,
6766
6768
  value: y,
6767
6769
  onChange: (E) => {
6768
- let h = E.target.value;
6769
- S(h), f(() => {
6770
- i(h);
6770
+ let g = E.target.value;
6771
+ I(g), f(() => {
6772
+ i(g);
6771
6773
  });
6772
6774
  }
6773
6775
  }
@@ -6880,15 +6882,15 @@ a(Fr, "trySelectNewStory");
6880
6882
  // src/manager/components/sidebar/CreateNewStoryFileModal.tsx
6881
6883
  var b0 = /* @__PURE__ */ a((e) => JSON.stringify(e, (t, o) => typeof o == "function" ? "__sb_empty_function_arg__" : o), "stringifyArgs"), cc = /* @__PURE__ */ a(
6882
6884
  ({ open: e, onOpenChange: t }) => {
6883
- let [o, i] = K(!1), [r, n] = K(""), l = Pu(r, 600), u = Us(l), c = q(null), [p, d] = K(
6885
+ let [o, i] = K(!1), [r, n] = K(""), l = Pu(r, 600), u = Us(l), c = q(null), [d, p] = K(
6884
6886
  null
6885
- ), m = oe(), [g, b] = K(null), f = A(
6886
- (h) => {
6887
+ ), m = oe(), [h, b] = K(null), f = A(
6888
+ (g) => {
6887
6889
  m.addNotification({
6888
6890
  id: "create-new-story-file-success",
6889
6891
  content: {
6890
6892
  headline: "Story file created",
6891
- subHeadline: `${h} was created`
6893
+ subHeadline: `${g} was created`
6892
6894
  },
6893
6895
  duration: 8e3,
6894
6896
  icon: /* @__PURE__ */ s.createElement(He, null)
@@ -6905,33 +6907,33 @@ var b0 = /* @__PURE__ */ a((e) => JSON.stringify(e, (t, o) => typeof o == "funct
6905
6907
  duration: 8e3,
6906
6908
  icon: /* @__PURE__ */ s.createElement(He, null)
6907
6909
  }), t(!1);
6908
- }, [m, t]), S = A(() => {
6910
+ }, [m, t]), I = A(() => {
6909
6911
  i(!0);
6910
- let h = ze.getChannel(), v = /* @__PURE__ */ a((I) => {
6911
- I.id === u && (I.success ? b(I.payload.files) : d({ error: I.error }), h.off(qo, v), i(!1), c.current = null);
6912
+ let g = ze.getChannel(), v = /* @__PURE__ */ a((S) => {
6913
+ S.id === u && (S.success ? b(S.payload.files) : p({ error: S.error }), g.off(qo, v), i(!1), c.current = null);
6912
6914
  }, "set");
6913
- return h.on(qo, v), u !== "" && c.current !== u ? (c.current = u, h.emit(ta, {
6915
+ return g.on(qo, v), u !== "" && c.current !== u ? (c.current = u, g.emit(ta, {
6914
6916
  id: u,
6915
6917
  payload: {}
6916
6918
  })) : (b(null), i(!1)), () => {
6917
- h.off(qo, v);
6919
+ g.off(qo, v);
6918
6920
  };
6919
6921
  }, [u]), E = A(
6920
6922
  async ({
6921
- componentExportName: h,
6923
+ componentExportName: g,
6922
6924
  componentFilePath: v,
6923
- componentIsDefaultExport: I,
6925
+ componentIsDefaultExport: S,
6924
6926
  componentExportCount: w,
6925
6927
  selectedItemId: O
6926
6928
  }) => {
6927
6929
  try {
6928
6930
  let _ = ze.getChannel(), k = await Zo(_, Js, ea, {
6929
- componentExportName: h,
6931
+ componentExportName: g,
6930
6932
  componentFilePath: v,
6931
- componentIsDefaultExport: I,
6933
+ componentIsDefaultExport: S,
6932
6934
  componentExportCount: w
6933
6935
  });
6934
- d(null);
6936
+ p(null);
6935
6937
  let T = k.storyId;
6936
6938
  await Fr(m.selectStory, T);
6937
6939
  try {
@@ -6950,7 +6952,7 @@ var b0 = /* @__PURE__ */ a((e) => JSON.stringify(e, (t, o) => typeof o == "funct
6950
6952
  );
6951
6953
  } catch {
6952
6954
  }
6953
- f(h), S();
6955
+ f(g), I();
6954
6956
  } catch (_) {
6955
6957
  switch (_?.payload?.type) {
6956
6958
  case "STORY_FILE_EXISTS":
@@ -6958,27 +6960,27 @@ var b0 = /* @__PURE__ */ a((e) => JSON.stringify(e, (t, o) => typeof o == "funct
6958
6960
  await Fr(m.selectStory, k.payload.kind), y();
6959
6961
  break;
6960
6962
  default:
6961
- d({ selectedItemId: O, error: _?.message });
6963
+ p({ selectedItemId: O, error: _?.message });
6962
6964
  break;
6963
6965
  }
6964
6966
  }
6965
6967
  },
6966
- [m?.selectStory, f, S, y]
6968
+ [m?.selectStory, f, I, y]
6967
6969
  );
6968
6970
  return V(() => {
6969
- d(null);
6970
- }, [u]), V(() => S(), [S]), /* @__PURE__ */ s.createElement(
6971
+ p(null);
6972
+ }, [u]), V(() => I(), [I]), /* @__PURE__ */ s.createElement(
6971
6973
  lc,
6972
6974
  {
6973
- error: p,
6975
+ error: d,
6974
6976
  fileSearchQuery: r,
6975
6977
  fileSearchQueryDeferred: u,
6976
6978
  onCreateNewStory: E,
6977
6979
  isLoading: o,
6978
6980
  onOpenChange: t,
6979
6981
  open: e,
6980
- searchResults: g,
6981
- setError: d,
6982
+ searchResults: h,
6983
+ setError: p,
6982
6984
  setFileSearchQuery: n
6983
6985
  }
6984
6986
  );
@@ -7284,13 +7286,13 @@ ready" && /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.cr
7284
7286
  tooltip: (u) => /* @__PURE__ */ s.createElement(
7285
7287
  ot,
7286
7288
  {
7287
- links: Object.entries(t.versions).map(([c, p]) => ({
7288
- icon: p === t.url ? /* @__PURE__ */ s.createElement(He, null) : void 0,
7289
+ links: Object.entries(t.versions).map(([c, d]) => ({
7290
+ icon: d === t.url ? /* @__PURE__ */ s.createElement(He, null) : void 0,
7289
7291
  id: c,
7290
7292
  title: c,
7291
- href: p,
7292
- onClick: /* @__PURE__ */ a((d, m) => {
7293
- d.preventDefault(), i.changeRefVersion(t.id, m.href), u.onHide();
7293
+ href: d,
7294
+ onClick: /* @__PURE__ */ a((p, m) => {
7295
+ p.preventDefault(), i.changeRefVersion(t.id, m.href), u.onHide();
7294
7296
  }, "onClick")
7295
7297
  }))
7296
7298
  }
@@ -7545,35 +7547,35 @@ var K0 = {
7545
7547
  }), Hc = /* @__PURE__ */ a((e, t, o) => {
7546
7548
  let [i, r] = K(0), [n, l] = K(!1), u = U(() => ({
7547
7549
  onMouseEnter: /* @__PURE__ */ a(() => {
7548
- r((d) => d + 1);
7550
+ r((p) => p + 1);
7549
7551
  }, "onMouseEnter"),
7550
- onOpen: /* @__PURE__ */ a((d) => {
7551
- d.stopPropagation(), l(!0);
7552
+ onOpen: /* @__PURE__ */ a((p) => {
7553
+ p.stopPropagation(), l(!0);
7552
7554
  }, "onOpen"),
7553
7555
  onClose: /* @__PURE__ */ a(() => {
7554
7556
  l(!1);
7555
7557
  }, "onClose")
7556
- }), []), p = U(() => {
7557
- let d = o.getElements(Ce.experimental_TEST_PROVIDER);
7558
- return i ? zc(d, e) : [];
7558
+ }), []), d = U(() => {
7559
+ let p = o.getElements(Ce.experimental_TEST_PROVIDER);
7560
+ return i ? zc(p, e) : [];
7559
7561
  }, [o, e, i]).length > 0 || t.length > 0;
7560
7562
  return U(() => globalThis.CONFIG_TYPE !== "DEVELOPMENT" ? K0 : {
7561
7563
  onMouseEnter: u.onMouseEnter,
7562
- node: p ? /* @__PURE__ */ s.createElement(
7564
+ node: d ? /* @__PURE__ */ s.createElement(
7563
7565
  $0,
7564
7566
  {
7565
7567
  "data-displayed": n ? "on" : "off",
7566
7568
  closeOnOutsideClick: !0,
7567
7569
  placement: "bottom-end",
7568
7570
  "data-testid": "context-menu",
7569
- onVisibleChange: (d) => {
7570
- d ? l(!0) : u.onClose();
7571
+ onVisibleChange: (p) => {
7572
+ p ? l(!0) : u.onClose();
7571
7573
  },
7572
7574
  tooltip: /* @__PURE__ */ s.createElement(G0, { context: e, links: t })
7573
7575
  },
7574
7576
  /* @__PURE__ */ s.createElement(U0, { type: "button", status: "status-value:pending" }, /* @__PURE__ */ s.createElement(kn, null))
7575
7577
  ) : null
7576
- }, [e, u, n, p, t]);
7578
+ }, [e, u, n, d, t]);
7577
7579
  }, "useContextMenu"), G0 = /* @__PURE__ */ a(({
7578
7580
  context: e,
7579
7581
  links: t,
@@ -7737,23 +7739,23 @@ onent" }, /* @__PURE__ */ s.createElement(Le, { type: "component" }))), o);
7737
7739
  function zr(e, t, { signal: o, edges: i } = {}) {
7738
7740
  let r, n = null, l = i != null && i.includes("leading"), u = i == null || i.includes("trailing"), c = /* @__PURE__ */ a(() => {
7739
7741
  n !== null && (e.apply(r, n), r = void 0, n = null);
7740
- }, "invoke"), p = /* @__PURE__ */ a(() => {
7742
+ }, "invoke"), d = /* @__PURE__ */ a(() => {
7741
7743
  u && c(), b();
7742
- }, "onTimerEnd"), d = null, m = /* @__PURE__ */ a(() => {
7743
- d != null && clearTimeout(d), d = setTimeout(() => {
7744
- d = null, p();
7744
+ }, "onTimerEnd"), p = null, m = /* @__PURE__ */ a(() => {
7745
+ p != null && clearTimeout(p), p = setTimeout(() => {
7746
+ p = null, d();
7745
7747
  }, t);
7746
- }, "schedule"), g = /* @__PURE__ */ a(() => {
7747
- d !== null && (clearTimeout(d), d = null);
7748
+ }, "schedule"), h = /* @__PURE__ */ a(() => {
7749
+ p !== null && (clearTimeout(p), p = null);
7748
7750
  }, "cancelTimer"), b = /* @__PURE__ */ a(() => {
7749
- g(), r = void 0, n = null;
7751
+ h(), r = void 0, n = null;
7750
7752
  }, "cancel"), f = /* @__PURE__ */ a(() => {
7751
- g(), c();
7752
- }, "flush"), y = /* @__PURE__ */ a(function(...S) {
7753
+ h(), c();
7754
+ }, "flush"), y = /* @__PURE__ */ a(function(...I) {
7753
7755
  if (o?.aborted)
7754
7756
  return;
7755
- r = this, n = S;
7756
- let E = d == null;
7757
+ r = this, n = I;
7758
+ let E = p == null;
7757
7759
  m(), l && E && c();
7758
7760
  }, "debounced");
7759
7761
  return y.schedule = m, y.cancel = b, y.flush = f, o?.addEventListener("abort", b, { once: !0 }), y;
@@ -7774,18 +7776,18 @@ function Vi(e, t = 0, o = {}) {
7774
7776
  typeof o != "object" && (o = {});
7775
7777
  let { signal: i, leading: r = !1, trailing: n = !0, maxWait: l } = o, u = Array(2);
7776
7778
  r && (u[0] = "leading"), n && (u[1] = "trailing");
7777
- let c, p = null, d = zr(function(...b) {
7778
- c = e.apply(this, b), p = null;
7779
+ let c, d = null, p = zr(function(...b) {
7780
+ c = e.apply(this, b), d = null;
7779
7781
  }, t, { signal: i, edges: u }), m = /* @__PURE__ */ a(function(...b) {
7780
7782
  if (l != null) {
7781
- if (p === null)
7782
- p = Date.now();
7783
- else if (Date.now() - p >= l)
7784
- return c = e.apply(this, b), p = Date.now(), d.cancel(), d.schedule(), c;
7783
+ if (d === null)
7784
+ d = Date.now();
7785
+ else if (Date.now() - d >= l)
7786
+ return c = e.apply(this, b), d = Date.now(), p.cancel(), p.schedule(), c;
7785
7787
  }
7786
- return d.apply(this, b), c;
7787
- }, "debounced"), g = /* @__PURE__ */ a(() => (d.flush(), c), "flush");
7788
- return m.cancel = d.cancel, m.flush = g, m;
7788
+ return p.apply(this, b), c;
7789
+ }, "debounced"), h = /* @__PURE__ */ a(() => (p.flush(), c), "flush");
7790
+ return m.cancel = p.cancel, m.flush = h, m;
7789
7791
  }
7790
7792
  a(Vi, "debounce");
7791
7793
 
@@ -7831,56 +7833,56 @@ var { document: ji } = se, X0 = /* @__PURE__ */ a(({
7831
7833
  highlightedRef: l,
7832
7834
  setHighlightedItemId: u,
7833
7835
  selectedStoryId: c,
7834
- onSelectStoryId: p
7836
+ onSelectStoryId: d
7835
7837
  }) => {
7836
- let d = oe(), [m, g] = Zt(
7837
- (h, { ids: v, value: I }) => v.reduce((w, O) => Object.assign(w, { [O]: I }), { ...h }),
7838
+ let p = oe(), [m, h] = Zt(
7839
+ (g, { ids: v, value: S }) => v.reduce((w, O) => Object.assign(w, { [O]: S }), { ...g }),
7838
7840
  // @ts-expect-error (non strict)
7839
7841
  { refId: o, data: i, highlightedRef: l, rootIds: n, initialExpanded: r },
7840
7842
  X0
7841
7843
  ), b = A(
7842
- (h) => e.current?.querySelector(`[data-item-id="${h}"]`),
7844
+ (g) => e.current?.querySelector(`[data-item-id="${g}"]`),
7843
7845
  [e]
7844
7846
  ), f = A(
7845
- (h) => {
7846
- u(h.getAttribute("data-item-id")), zt(h);
7847
+ (g) => {
7848
+ u(g.getAttribute("data-item-id")), zt(g);
7847
7849
  },
7848
7850
  [u]
7849
7851
  ), y = A(
7850
- ({ ids: h, value: v }) => {
7851
- if (g({ ids: h, value: v }), h.length === 1) {
7852
- let I = e.current?.querySelector(
7853
- `[data-item-id="${h[0]}"][data-ref-id="${o}"]`
7852
+ ({ ids: g, value: v }) => {
7853
+ if (h({ ids: g, value: v }), g.length === 1) {
7854
+ let S = e.current?.querySelector(
7855
+ `[data-item-id="${g[0]}"][data-ref-id="${o}"]`
7854
7856
  );
7855
- I && f(I);
7857
+ S && f(S);
7856
7858
  }
7857
7859
  },
7858
7860
  [e, f, o]
7859
7861
  );
7860
7862
  V(() => {
7861
- g({ ids: Fo(i, c), value: !0 });
7863
+ h({ ids: Fo(i, c), value: !0 });
7862
7864
  }, [i, c]);
7863
- let S = A(() => {
7864
- let h = Object.keys(i).filter((v) => !n.includes(v));
7865
- g({ ids: h, value: !1 });
7865
+ let I = A(() => {
7866
+ let g = Object.keys(i).filter((v) => !n.includes(v));
7867
+ h({ ids: g, value: !1 });
7866
7868
  }, [i, n]), E = A(() => {
7867
- g({ ids: Object.keys(i), value: !0 });
7869
+ h({ ids: Object.keys(i), value: !0 });
7868
7870
  }, [i]);
7869
- return V(() => d ? (d.on(ho, S), d.on(In, E), () => {
7870
- d.off(ho, S), d.off(In, E);
7871
- }) : Z0, [d, S, E]), V(() => {
7872
- let h = ji.getElementById("storybook-explorer-menu"), v = Wi((I) => {
7871
+ return V(() => p ? (p.on(ho, I), p.on(In, E), () => {
7872
+ p.off(ho, I), p.off(In, E);
7873
+ }) : Z0, [p, I, E]), V(() => {
7874
+ let g = ji.getElementById("storybook-explorer-menu"), v = Wi((S) => {
7873
7875
  let w = l.current?.refId === o && l.current?.itemId;
7874
- if (!t || !e.current || !w || I.repeat || !St(!1, I))
7876
+ if (!t || !e.current || !w || S.repeat || !St(!1, S))
7875
7877
  return;
7876
- let O = Ue("Enter", I), _ = Ue("Space", I), k = Ue("ArrowLeft", I), T = Ue("ArrowRight", I);
7878
+ let O = Ue("Enter", S), _ = Ue("Space", S), k = Ue("ArrowLeft", S), T = Ue("ArrowRight", S);
7877
7879
  if (!(O || _ || k || T))
7878
7880
  return;
7879
7881
  let C = b(w);
7880
7882
  if (!C || C.getAttribute("data-ref-id") !== o)
7881
7883
  return;
7882
- let P = I.target;
7883
- if (!Wt(h, P) && !Wt(P, h))
7884
+ let P = S.target;
7885
+ if (!Wt(g, P) && !Wt(P, g))
7884
7886
  return;
7885
7887
  if (P.hasAttribute("data-action")) {
7886
7888
  if (O || _)
@@ -7888,11 +7890,11 @@ var { document: ji } = se, X0 = /* @__PURE__ */ a(({
7888
7890
  P.blur();
7889
7891
  }
7890
7892
  let D = C.getAttribute("data-nodetype");
7891
- (O || _) && ["component", "story", "document"].includes(D) && p(w);
7893
+ (O || _) && ["component", "story", "document"].includes(D) && d(w);
7892
7894
  let M = C.getAttribute("aria-expanded");
7893
7895
  if (k) {
7894
7896
  if (M === "true") {
7895
- g({ ids: [w], value: !1 });
7897
+ h({ ids: [w], value: !1 });
7896
7898
  return;
7897
7899
  }
7898
7900
  let N = C.getAttribute("data-parent-id"), Z = N && b(N);
@@ -7900,7 +7902,7 @@ var { document: ji } = se, X0 = /* @__PURE__ */ a(({
7900
7902
  f(Z);
7901
7903
  return;
7902
7904
  }
7903
- g({ ids: st(i, w, !0), value: !1 });
7905
+ h({ ids: st(i, w, !0), value: !1 });
7904
7906
  return;
7905
7907
  }
7906
7908
  T && (M === "false" ? y({ ids: [w], value: !0 }) : M === "true" && y({ ids: st(i, w, !0), value: !0 }));
@@ -7913,7 +7915,7 @@ var { document: ji } = se, X0 = /* @__PURE__ */ a(({
7913
7915
  i,
7914
7916
  l,
7915
7917
  u,
7916
- p
7918
+ d
7917
7919
  ]), [m, y];
7918
7920
  }, "useExpanded");
7919
7921
 
@@ -8030,17 +8032,17 @@ var Xc = [
8030
8032
  isOrphan: l,
8031
8033
  isDisplayed: u,
8032
8034
  isSelected: c,
8033
- isFullyExpanded: p,
8034
- setFullyExpanded: d,
8035
+ isFullyExpanded: d,
8036
+ setFullyExpanded: p,
8035
8037
  isExpanded: m,
8036
- setExpanded: g,
8038
+ setExpanded: h,
8037
8039
  onSelectStoryId: b,
8038
8040
  api: f
8039
8041
  }) {
8040
- let { isDesktop: y, isMobile: S, setMobileMenuOpen: E } = ge(), { counts: h, statusesByValue: v } = Wc(t);
8042
+ let { isDesktop: y, isMobile: I, setMobileMenuOpen: E } = ge(), { counts: g, statusesByValue: v } = Wc(t);
8041
8043
  if (!u)
8042
8044
  return null;
8043
- let I = U(() => {
8045
+ let S = U(() => {
8044
8046
  if (t.type === "story" || t.type === "docs")
8045
8047
  return Object.entries(o).filter(([, _]) => _.sidebarContextMenu !== !1).sort((_, k) => Xc.indexOf(_[1].value) - Xc.indexOf(k[1].value)).
8046
8048
  map(([_, k]) => ({
@@ -8054,7 +8056,7 @@ var Xc = [
8054
8056
  }, "onClick")
8055
8057
  }));
8056
8058
  if (t.type === "component" || t.type === "group") {
8057
- let _ = [], k = h["status-value:error"], T = h["status-value:warning"];
8059
+ let _ = [], k = g["status-value:error"], T = g["status-value:warning"];
8058
8060
  return k && _.push({
8059
8061
  id: "errors",
8060
8062
  icon: Ki["status-value:error"],
@@ -8078,7 +8080,7 @@ var Xc = [
8078
8080
  }), _;
8079
8081
  }
8080
8082
  return [];
8081
- }, [h, t.id, t.type, b, o, v]), w = Rr(t.id, r), O = r === "storybook_internal" ? Hc(t, I, f) : { node: null, onMouseEnter: /* @__PURE__ */ a(
8083
+ }, [g, t.id, t.type, b, o, v]), w = Rr(t.id, r), O = r === "storybook_internal" ? Hc(t, S, f) : { node: null, onMouseEnter: /* @__PURE__ */ a(
8082
8084
  () => {
8083
8085
  }, "onMouseEnter") };
8084
8086
  if (t.type === "story" || t.type === "docs") {
@@ -8106,7 +8108,7 @@ var Xc = [
8106
8108
  id: w,
8107
8109
  depth: l ? t.depth : t.depth - 1,
8108
8110
  onClick: (P) => {
8109
- P.preventDefault(), b(t.id), S && E(!1);
8111
+ P.preventDefault(), b(t.id), I && E(!1);
8110
8112
  },
8111
8113
  ...t.type === "docs" && { docsMode: n }
8112
8114
  },
@@ -8145,7 +8147,7 @@ var Xc = [
8145
8147
  type: "button",
8146
8148
  "data-action": "collapse-root",
8147
8149
  onClick: (_) => {
8148
- _.preventDefault(), g({ ids: [t.id], value: !m });
8150
+ _.preventDefault(), h({ ids: [t.id], value: !m });
8149
8151
  },
8150
8152
  "aria-expanded": m
8151
8153
  },
@@ -8156,14 +8158,14 @@ var Xc = [
8156
8158
  ee,
8157
8159
  {
8158
8160
  className: "sidebar-subheading-action",
8159
- "aria-label": p ? "Expand" : "Collapse",
8161
+ "aria-label": d ? "Expand" : "Collapse",
8160
8162
  "data-action": "expand-all",
8161
- "data-expanded": p,
8163
+ "data-expanded": d,
8162
8164
  onClick: (_) => {
8163
- _.preventDefault(), d();
8165
+ _.preventDefault(), p();
8164
8166
  }
8165
8167
  },
8166
- p ? /* @__PURE__ */ s.createElement(_n, null) : /* @__PURE__ */ s.createElement(On, null)
8168
+ d ? /* @__PURE__ */ s.createElement(_n, null) : /* @__PURE__ */ s.createElement(On, null)
8167
8169
  )
8168
8170
  );
8169
8171
  if (t.type === "component" || t.type === "group") {
@@ -8192,7 +8194,7 @@ var Xc = [
8192
8194
  isExpandable: t.children && t.children.length > 0,
8193
8195
  isExpanded: m,
8194
8196
  onClick: (C) => {
8195
- C.preventDefault(), g({ ids: [t.id], value: !m }), t.type === "component" && !m && y && b(t.id);
8197
+ C.preventDefault(), h({ ids: [t.id], value: !m }), t.type === "component" && !m && y && b(t.id);
8196
8198
  },
8197
8199
  onMouseEnter: () => {
8198
8200
  t.type === "component" && f.emit(Ct, {
@@ -8238,10 +8240,10 @@ dot" })))
8238
8240
  docsMode: l,
8239
8241
  highlightedRef: u,
8240
8242
  setHighlightedItemId: c,
8241
- selectedStoryId: p,
8242
- onSelectStoryId: d
8243
+ selectedStoryId: d,
8244
+ onSelectStoryId: p
8243
8245
  }) {
8244
- let m = q(null), g = oe(), [b, f, y] = U(
8246
+ let m = q(null), h = oe(), [b, f, y] = U(
8245
8247
  () => Object.keys(r).reduce(
8246
8248
  (T, C) => {
8247
8249
  let P = r[C];
@@ -8250,7 +8252,7 @@ dot" })))
8250
8252
  [[], [], {}]
8251
8253
  ),
8252
8254
  [r]
8253
- ), { expandableDescendants: S } = U(() => [...f, ...b].reduce(
8255
+ ), { expandableDescendants: I } = U(() => [...f, ...b].reduce(
8254
8256
  (T, C) => (T.expandableDescendants[C] = st(r, C, !1).filter(
8255
8257
  (P) => !["story", "docs"].includes(r[P].type)
8256
8258
  ), T),
@@ -8264,7 +8266,7 @@ dot" })))
8264
8266
  return !1;
8265
8267
  let M = r[P[0]];
8266
8268
  return M.type === "docs" ? !0 : M.type === "story" ? vc(M.name, D) : !1;
8267
- }), [r]), h = U(
8269
+ }), [r]), g = U(
8268
8270
  () => Object.keys(r).filter((T) => !E.includes(T)),
8269
8271
  [E]
8270
8272
  ), v = U(() => E.reduce(
@@ -8282,10 +8284,10 @@ dot" })))
8282
8284
  }, T;
8283
8285
  },
8284
8286
  { ...r }
8285
- ), [r]), I = U(() => h.reduce(
8287
+ ), [r]), S = U(() => g.reduce(
8286
8288
  (T, C) => Object.assign(T, { [C]: Fo(v, C) }),
8287
8289
  {}
8288
- ), [h, v]), [w, O] = Yc({
8290
+ ), [g, v]), [w, O] = Yc({
8289
8291
  // @ts-expect-error (non strict)
8290
8292
  containerRef: m,
8291
8293
  isBrowsing: t,
@@ -8295,42 +8297,42 @@ dot" })))
8295
8297
  rootIds: b,
8296
8298
  highlightedRef: u,
8297
8299
  setHighlightedItemId: c,
8298
- selectedStoryId: p,
8299
- onSelectStoryId: d
8300
+ selectedStoryId: d,
8301
+ onSelectStoryId: p
8300
8302
  }), _ = U(
8301
8303
  () => Br(v, n ?? {}),
8302
8304
  [v, n]
8303
- ), k = U(() => h.map((T) => {
8305
+ ), k = U(() => g.map((T) => {
8304
8306
  let C = v[T], P = Rr(T, i);
8305
8307
  if (C.type === "root") {
8306
- let M = S[C.id], N = M.every((Z) => w[Z]);
8308
+ let M = I[C.id], N = M.every((Z) => w[Z]);
8307
8309
  return (
8308
8310
  // @ts-expect-error (TODO)
8309
8311
  /* @__PURE__ */ s.createElement(
8310
8312
  sx,
8311
8313
  {
8312
- api: g,
8314
+ api: h,
8313
8315
  key: P,
8314
8316
  item: C,
8315
8317
  refId: i,
8316
8318
  collapsedData: v,
8317
8319
  isOrphan: !1,
8318
8320
  isDisplayed: !0,
8319
- isSelected: p === T,
8321
+ isSelected: d === T,
8320
8322
  isExpanded: !!w[T],
8321
8323
  setExpanded: O,
8322
8324
  isFullyExpanded: N,
8323
8325
  expandableDescendants: M,
8324
- onSelectStoryId: d
8326
+ onSelectStoryId: p
8325
8327
  }
8326
8328
  )
8327
8329
  );
8328
8330
  }
8329
- let D = !C.parent || I[T].every((M) => w[M]);
8331
+ let D = !C.parent || S[T].every((M) => w[M]);
8330
8332
  return D === !1 ? null : /* @__PURE__ */ s.createElement(
8331
8333
  Zc,
8332
8334
  {
8333
- api: g,
8335
+ api: h,
8334
8336
  collapsedData: v,
8335
8337
  key: P,
8336
8338
  item: C,
@@ -8340,25 +8342,25 @@ dot" })))
8340
8342
  docsMode: l,
8341
8343
  isOrphan: f.some((M) => T === M || T.startsWith(`${M}-`)),
8342
8344
  isDisplayed: D,
8343
- isSelected: p === T,
8345
+ isSelected: d === T,
8344
8346
  isExpanded: !!w[T],
8345
8347
  setExpanded: O,
8346
- onSelectStoryId: d
8348
+ onSelectStoryId: p
8347
8349
  }
8348
8350
  );
8349
8351
  }), [
8350
- I,
8351
- g,
8352
- v,
8352
+ S,
8353
8353
  h,
8354
+ v,
8355
+ g,
8354
8356
  l,
8355
- S,
8357
+ I,
8356
8358
  w,
8357
8359
  _,
8358
- d,
8360
+ p,
8359
8361
  f,
8360
8362
  i,
8361
- p,
8363
+ d,
8362
8364
  O,
8363
8365
  n
8364
8366
  ]);
@@ -8413,29 +8415,29 @@ var ax = x.div(({ isMain: e }) => ({
8413
8415
  title: l = n,
8414
8416
  isLoading: u,
8415
8417
  isBrowsing: c,
8416
- selectedStoryId: p,
8417
- highlightedRef: d,
8418
+ selectedStoryId: d,
8419
+ highlightedRef: p,
8418
8420
  setHighlighted: m,
8419
- loginUrl: g,
8421
+ loginUrl: h,
8420
8422
  type: b,
8421
8423
  expanded: f = !0,
8422
8424
  indexError: y,
8423
- previewInitialized: S,
8425
+ previewInitialized: I,
8424
8426
  allStatuses: E
8425
- } = t, h = U(() => r ? Object.keys(r).length : 0, [r]), v = q(null), I = n === at, O = u || (b === "auto-inject" && !S || b === "server-ch\
8426
- ecked") || b === "unknown", C = bc(O, !!g && h === 0, !!y, !O && h === 0), [P, D] = K(f);
8427
+ } = t, g = U(() => r ? Object.keys(r).length : 0, [r]), v = q(null), S = n === at, O = u || (b === "auto-inject" && !I || b === "server-ch\
8428
+ ecked") || b === "unknown", C = bc(O, !!h && g === 0, !!y, !O && g === 0), [P, D] = K(f);
8427
8429
  V(() => {
8428
- r && p && r[p] && D(!0);
8429
- }, [D, r, p]);
8430
+ r && d && r[d] && D(!0);
8431
+ }, [D, r, d]);
8430
8432
  let M = A(() => D((W) => !W), [D]), N = A(
8431
8433
  (W) => m({ itemId: W, refId: n }),
8432
8434
  [m]
8433
8435
  ), Z = A(
8434
8436
  // @ts-expect-error (non strict)
8435
- (W) => i && i.selectStory(W, void 0, { ref: !I && n }),
8436
- [i, I, n]
8437
+ (W) => i && i.selectStory(W, void 0, { ref: !S && n }),
8438
+ [i, S, n]
8437
8439
  );
8438
- return /* @__PURE__ */ s.createElement(s.Fragment, null, I || /* @__PURE__ */ s.createElement(
8440
+ return /* @__PURE__ */ s.createElement(s.Fragment, null, S || /* @__PURE__ */ s.createElement(
8439
8441
  lx,
8440
8442
  {
8441
8443
  "aria-label": `${P ? "Hide" : "Show"} ${l} stories`,
@@ -8444,20 +8446,20 @@ ecked") || b === "unknown", C = bc(O, !!g && h === 0, !!y, !O && h === 0), [P, D
8444
8446
  /* @__PURE__ */ s.createElement(cx, { "data-action": "collapse-ref", onClick: M }, /* @__PURE__ */ s.createElement(Kt, { isExpanded: P }),
8445
8447
  /* @__PURE__ */ s.createElement(ux, { title: l }, l)),
8446
8448
  /* @__PURE__ */ s.createElement(_c, { ...t, state: C, ref: v })
8447
- ), P && /* @__PURE__ */ s.createElement(ax, { "data-title": l, isMain: I }, C === "auth" && /* @__PURE__ */ s.createElement(wc, { id: n, loginUrl: g }),
8448
- C === "error" && /* @__PURE__ */ s.createElement(Ec, { error: y }), C === "loading" && /* @__PURE__ */ s.createElement(Cc, { isMain: I }),
8449
- C === "empty" && /* @__PURE__ */ s.createElement(Tc, { isMain: I }), C === "ready" && /* @__PURE__ */ s.createElement(
8449
+ ), P && /* @__PURE__ */ s.createElement(ax, { "data-title": l, isMain: S }, C === "auth" && /* @__PURE__ */ s.createElement(wc, { id: n, loginUrl: h }),
8450
+ C === "error" && /* @__PURE__ */ s.createElement(Ec, { error: y }), C === "loading" && /* @__PURE__ */ s.createElement(Cc, { isMain: S }),
8451
+ C === "empty" && /* @__PURE__ */ s.createElement(Tc, { isMain: S }), C === "ready" && /* @__PURE__ */ s.createElement(
8450
8452
  Jc,
8451
8453
  {
8452
8454
  allStatuses: E,
8453
8455
  isBrowsing: c,
8454
- isMain: I,
8456
+ isMain: S,
8455
8457
  refId: n,
8456
8458
  data: r,
8457
8459
  docsMode: o.docsMode,
8458
- selectedStoryId: p,
8460
+ selectedStoryId: d,
8459
8461
  onSelectStoryId: Z,
8460
- highlightedRef: d,
8462
+ highlightedRef: p,
8461
8463
  setHighlightedItemId: N
8462
8464
  }
8463
8465
  )));
@@ -8474,43 +8476,43 @@ var { document: Wr, window: tp } = se, op = /* @__PURE__ */ a((e) => e ? { itemI
8474
8476
  isBrowsing: o,
8475
8477
  selected: i
8476
8478
  }) => {
8477
- let r = op(i), n = q(r), [l, u] = K(r), c = oe(), p = A(
8479
+ let r = op(i), n = q(r), [l, u] = K(r), c = oe(), d = A(
8478
8480
  (m) => {
8479
8481
  n.current = m, u(m);
8480
8482
  },
8481
8483
  [n]
8482
- ), d = A(
8483
- (m, g = !1) => {
8484
+ ), p = A(
8485
+ (m, h = !1) => {
8484
8486
  let b = m.getAttribute("data-item-id"), f = m.getAttribute("data-ref-id");
8485
- !b || !f || (p({ itemId: b, refId: f }), zt(m, g));
8487
+ !b || !f || (d({ itemId: b, refId: f }), zt(m, h));
8486
8488
  },
8487
- [p]
8489
+ [d]
8488
8490
  );
8489
8491
  return V(() => {
8490
8492
  let m = op(i);
8491
- p(m), m && rp(`[data-item-id="${m.itemId}"][data-ref-id="${m.refId}"]`, {
8493
+ d(m), m && rp(`[data-item-id="${m.itemId}"][data-ref-id="${m.refId}"]`, {
8492
8494
  containerRef: e,
8493
8495
  center: !0
8494
8496
  });
8495
- }, [e, i, p]), V(() => {
8496
- let m = Wr.getElementById("storybook-explorer-menu"), g, b = /* @__PURE__ */ a((f) => {
8497
+ }, [e, i, d]), V(() => {
8498
+ let m = Wr.getElementById("storybook-explorer-menu"), h, b = /* @__PURE__ */ a((f) => {
8497
8499
  if (t || !o || !e.current || !St(!1, f))
8498
8500
  return;
8499
- let y = Ue("ArrowUp", f), S = Ue("ArrowDown", f);
8500
- if (!(y || S))
8501
+ let y = Ue("ArrowUp", f), I = Ue("ArrowDown", f);
8502
+ if (!(y || I))
8501
8503
  return;
8502
8504
  let E = tp.requestAnimationFrame(() => {
8503
- tp.cancelAnimationFrame(g), g = E;
8504
- let h = f.target;
8505
- if (!Wt(m, h) && !Wt(h, m))
8505
+ tp.cancelAnimationFrame(h), h = E;
8506
+ let g = f.target;
8507
+ if (!Wt(m, g) && !Wt(g, m))
8506
8508
  return;
8507
- h.hasAttribute("data-action") && h.blur();
8509
+ g.hasAttribute("data-action") && g.blur();
8508
8510
  let v = Array.from(
8509
8511
  e.current?.querySelectorAll("[data-highlightable=true]") || []
8510
- ), I = v.findIndex(
8512
+ ), S = v.findIndex(
8511
8513
  (_) => _.getAttribute("data-item-id") === n.current?.itemId && _.getAttribute("data-ref-id") === n.current?.refId
8512
- ), w = yc(v, I, y ? -1 : 1), O = y ? w === v.length - 1 : w === 0;
8513
- if (d(v[w], O), v[w].getAttribute("data-nodetype") === "component") {
8514
+ ), w = yc(v, S, y ? -1 : 1), O = y ? w === v.length - 1 : w === 0;
8515
+ if (p(v[w], O), v[w].getAttribute("data-nodetype") === "component") {
8514
8516
  let { itemId: _, refId: k } = n.current, T = c.resolveStory(_, k === "storybook_internal" ? void 0 : k);
8515
8517
  T.type === "component" && c.emit(Ct, {
8516
8518
  // @ts-expect-error (non strict)
@@ -8521,7 +8523,7 @@ var { document: Wr, window: tp } = se, op = /* @__PURE__ */ a((e) => e ? { itemI
8521
8523
  });
8522
8524
  }, "navigateTree");
8523
8525
  return Wr.addEventListener("keydown", b), () => Wr.removeEventListener("keydown", b);
8524
- }, [t, o, n, d]), [l, p, n];
8526
+ }, [t, o, n, p]), [l, d, n];
8525
8527
  }, "useHighlighted");
8526
8528
 
8527
8529
  // src/manager/components/sidebar/Explorer.tsx
@@ -8546,14 +8548,14 @@ var ip = s.memo(/* @__PURE__ */ a(function({
8546
8548
  "data-highlighted-item-id": l?.itemId
8547
8549
  },
8548
8550
  l && /* @__PURE__ */ s.createElement(pc, { ...l }),
8549
- i.entries.map(([p, d]) => /* @__PURE__ */ s.createElement(
8551
+ i.entries.map(([d, p]) => /* @__PURE__ */ s.createElement(
8550
8552
  ep,
8551
8553
  {
8552
- ...d,
8553
- key: p,
8554
+ ...p,
8555
+ key: d,
8554
8556
  isLoading: t,
8555
8557
  isBrowsing: o,
8556
- selectedStoryId: r?.refId === d.id ? r.storyId : null,
8558
+ selectedStoryId: r?.refId === p.id ? r.storyId : null,
8557
8559
  highlightedRef: c,
8558
8560
  setHighlighted: u
8559
8561
  }
@@ -8761,38 +8763,38 @@ e - i : l > t && u < o || n < e && u > o ? l - t + r : 0, "o"), xx = /* @__PURE_
8761
8763
  }, "l"), yp = /* @__PURE__ */ a((e, t) => {
8762
8764
  var o, i, r, n;
8763
8765
  if (typeof document > "u") return [];
8764
- let { scrollMode: l, block: u, inline: c, boundary: p, skipOverflowHiddenElements: d } = t, m = typeof p == "function" ? p : (W) => W !== p;
8766
+ let { scrollMode: l, block: u, inline: c, boundary: d, skipOverflowHiddenElements: p } = t, m = typeof d == "function" ? d : (W) => W !== d;
8765
8767
  if (!hp(e)) throw new TypeError("Invalid target");
8766
- let g = document.scrollingElement || document.documentElement, b = [], f = e;
8768
+ let h = document.scrollingElement || document.documentElement, b = [], f = e;
8767
8769
  for (; hp(f) && m(f); ) {
8768
- if (f = xx(f), f === g) {
8770
+ if (f = xx(f), f === h) {
8769
8771
  b.push(f);
8770
8772
  break;
8771
8773
  }
8772
- f != null && f === document.body && Zr(f) && !Zr(document.documentElement) || f != null && Zr(f, d) && b.push(f);
8774
+ f != null && f === document.body && Zr(f) && !Zr(document.documentElement) || f != null && Zr(f, p) && b.push(f);
8773
8775
  }
8774
- let y = (i = (o = window.visualViewport) == null ? void 0 : o.width) != null ? i : innerWidth, S = (n = (r = window.visualViewport) == null ?
8775
- void 0 : r.height) != null ? n : innerHeight, { scrollX: E, scrollY: h } = window, { height: v, width: I, top: w, right: O, bottom: _, left: k } = e.
8776
+ let y = (i = (o = window.visualViewport) == null ? void 0 : o.width) != null ? i : innerWidth, I = (n = (r = window.visualViewport) == null ?
8777
+ void 0 : r.height) != null ? n : innerHeight, { scrollX: E, scrollY: g } = window, { height: v, width: S, top: w, right: O, bottom: _, left: k } = e.
8776
8778
  getBoundingClientRect(), { top: T, right: C, bottom: P, left: D } = ((W) => {
8777
8779
  let Q = window.getComputedStyle(W);
8778
8780
  return { top: parseFloat(Q.scrollMarginTop) || 0, right: parseFloat(Q.scrollMarginRight) || 0, bottom: parseFloat(Q.scrollMarginBottom) ||
8779
8781
  0, left: parseFloat(Q.scrollMarginLeft) || 0 };
8780
- })(e), M = u === "start" || u === "nearest" ? w - T : u === "end" ? _ + P : w + v / 2 - T + P, N = c === "center" ? k + I / 2 - D + C : c ===
8782
+ })(e), M = u === "start" || u === "nearest" ? w - T : u === "end" ? _ + P : w + v / 2 - T + P, N = c === "center" ? k + S / 2 - D + C : c ===
8781
8783
  "end" ? O + C : k - D, Z = [];
8782
8784
  for (let W = 0; W < b.length; W++) {
8783
8785
  let Q = b[W], { height: B, width: G, top: H, right: re, bottom: F, left: R } = Q.getBoundingClientRect();
8784
- if (l === "if-needed" && w >= 0 && k >= 0 && _ <= S && O <= y && (Q === g && !Zr(Q) || w >= H && _ <= F && k >= R && O <= re)) return Z;
8786
+ if (l === "if-needed" && w >= 0 && k >= 0 && _ <= I && O <= y && (Q === h && !Zr(Q) || w >= H && _ <= F && k >= R && O <= re)) return Z;
8785
8787
  let L = getComputedStyle(Q), $ = parseInt(L.borderLeftWidth, 10), J = parseInt(L.borderTopWidth, 10), ie = parseInt(L.borderRightWidth, 10),
8786
8788
  te = parseInt(L.borderBottomWidth, 10), de = 0, ae = 0, ce = "offsetWidth" in Q ? Q.offsetWidth - Q.clientWidth - $ - ie : 0, ue = "offs\
8787
8789
  etHeight" in Q ? Q.offsetHeight - Q.clientHeight - J - te : 0, Ie = "offsetWidth" in Q ? Q.offsetWidth === 0 ? 0 : G / Q.offsetWidth : 0, ye = "\
8788
8790
  offsetHeight" in Q ? Q.offsetHeight === 0 ? 0 : B / Q.offsetHeight : 0;
8789
- if (g === Q) de = u === "start" ? M : u === "end" ? M - S : u === "nearest" ? Jr(h, h + S, S, J, te, h + M, h + M + v, v) : M - S / 2, ae =
8790
- c === "start" ? N : c === "center" ? N - y / 2 : c === "end" ? N - y : Jr(E, E + y, y, $, ie, E + N, E + N + I, I), de = Math.max(0, de +
8791
- h), ae = Math.max(0, ae + E);
8791
+ if (h === Q) de = u === "start" ? M : u === "end" ? M - I : u === "nearest" ? Jr(g, g + I, I, J, te, g + M, g + M + v, v) : M - I / 2, ae =
8792
+ c === "start" ? N : c === "center" ? N - y / 2 : c === "end" ? N - y : Jr(E, E + y, y, $, ie, E + N, E + N + S, S), de = Math.max(0, de +
8793
+ g), ae = Math.max(0, ae + E);
8792
8794
  else {
8793
8795
  de = u === "start" ? M - H - J : u === "end" ? M - F + te + ue : u === "nearest" ? Jr(H, F, B, J, te + ue, M, M + v, v) : M - (H + B /
8794
8796
  2) + ue / 2, ae = c === "start" ? N - R - $ : c === "center" ? N - (R + G / 2) + ce / 2 : c === "end" ? N - re + ie + ce : Jr(R, re, G,
8795
- $, ie + ce, N, N + I, I);
8797
+ $, ie + ce, N, N + S, S);
8796
8798
  let { scrollLeft: Oe, scrollTop: fe } = Q;
8797
8799
  de = ye === 0 ? 0 : Math.max(0, Math.min(fe + de / ye, Q.scrollHeight - B / ye + ue)), ae = Ie === 0 ? 0 : Math.max(0, Math.min(Oe + ae /
8798
8800
  Ie, Q.scrollWidth - G / Ie + ce)), M += fe - de, N += Oe - ae;
@@ -9017,75 +9019,75 @@ Ox = /* @__PURE__ */ Object.freeze({
9017
9019
  function o(r) {
9018
9020
  var n;
9019
9021
  n = t.call(this, r) || this, n.id = n.props.id || "downshift-" + Cp(), n.menuId = n.props.menuId || n.id + "-menu", n.labelId = n.props.
9020
- labelId || n.id + "-label", n.inputId = n.props.inputId || n.id + "-input", n.getItemId = n.props.getItemId || function(h) {
9021
- return n.id + "-item-" + h;
9022
- }, n.items = [], n.itemCount = null, n.previousResultCount = 0, n.timeoutIds = [], n.internalSetTimeout = function(h, v) {
9023
- var I = setTimeout(function() {
9022
+ labelId || n.id + "-label", n.inputId = n.props.inputId || n.id + "-input", n.getItemId = n.props.getItemId || function(g) {
9023
+ return n.id + "-item-" + g;
9024
+ }, n.items = [], n.itemCount = null, n.previousResultCount = 0, n.timeoutIds = [], n.internalSetTimeout = function(g, v) {
9025
+ var S = setTimeout(function() {
9024
9026
  n.timeoutIds = n.timeoutIds.filter(function(w) {
9025
- return w !== I;
9026
- }), h();
9027
+ return w !== S;
9028
+ }), g();
9027
9029
  }, v);
9028
- n.timeoutIds.push(I);
9029
- }, n.setItemCount = function(h) {
9030
- n.itemCount = h;
9030
+ n.timeoutIds.push(S);
9031
+ }, n.setItemCount = function(g) {
9032
+ n.itemCount = g;
9031
9033
  }, n.unsetItemCount = function() {
9032
9034
  n.itemCount = null;
9033
- }, n.isItemDisabled = function(h, v) {
9034
- var I = n.getItemNodeFromIndex(v);
9035
- return I && I.hasAttribute("disabled");
9036
- }, n.setHighlightedIndex = function(h, v) {
9037
- h === void 0 && (h = n.props.defaultHighlightedIndex), v === void 0 && (v = {}), v = en(v), n.internalSetState(j({
9038
- highlightedIndex: h
9035
+ }, n.isItemDisabled = function(g, v) {
9036
+ var S = n.getItemNodeFromIndex(v);
9037
+ return S && S.hasAttribute("disabled");
9038
+ }, n.setHighlightedIndex = function(g, v) {
9039
+ g === void 0 && (g = n.props.defaultHighlightedIndex), v === void 0 && (v = {}), v = en(v), n.internalSetState(j({
9040
+ highlightedIndex: g
9039
9041
  }, v));
9040
- }, n.clearSelection = function(h) {
9042
+ }, n.clearSelection = function(g) {
9041
9043
  n.internalSetState({
9042
9044
  selectedItem: null,
9043
9045
  inputValue: "",
9044
9046
  highlightedIndex: n.props.defaultHighlightedIndex,
9045
9047
  isOpen: n.props.defaultIsOpen
9046
- }, h);
9047
- }, n.selectItem = function(h, v, I) {
9048
+ }, g);
9049
+ }, n.selectItem = function(g, v, S) {
9048
9050
  v = en(v), n.internalSetState(j({
9049
9051
  isOpen: n.props.defaultIsOpen,
9050
9052
  highlightedIndex: n.props.defaultHighlightedIndex,
9051
- selectedItem: h,
9052
- inputValue: n.props.itemToString(h)
9053
- }, v), I);
9054
- }, n.selectItemAtIndex = function(h, v, I) {
9055
- var w = n.items[h];
9056
- w != null && n.selectItem(w, v, I);
9057
- }, n.selectHighlightedItem = function(h, v) {
9058
- return n.selectItemAtIndex(n.getState().highlightedIndex, h, v);
9059
- }, n.internalSetState = function(h, v) {
9060
- var I, w, O = {}, _ = typeof h == "function";
9061
- return !_ && h.hasOwnProperty("inputValue") && n.props.onInputValueChange(h.inputValue, j({}, n.getStateAndHelpers(), h)), n.setState(
9053
+ selectedItem: g,
9054
+ inputValue: n.props.itemToString(g)
9055
+ }, v), S);
9056
+ }, n.selectItemAtIndex = function(g, v, S) {
9057
+ var w = n.items[g];
9058
+ w != null && n.selectItem(w, v, S);
9059
+ }, n.selectHighlightedItem = function(g, v) {
9060
+ return n.selectItemAtIndex(n.getState().highlightedIndex, g, v);
9061
+ }, n.internalSetState = function(g, v) {
9062
+ var S, w, O = {}, _ = typeof g == "function";
9063
+ return !_ && g.hasOwnProperty("inputValue") && n.props.onInputValueChange(g.inputValue, j({}, n.getStateAndHelpers(), g)), n.setState(
9062
9064
  function(k) {
9063
9065
  var T;
9064
9066
  k = n.getState(k);
9065
- var C = _ ? h(k) : h;
9066
- C = n.props.stateReducer(k, C), I = C.hasOwnProperty("selectedItem");
9067
+ var C = _ ? g(k) : g;
9068
+ C = n.props.stateReducer(k, C), S = C.hasOwnProperty("selectedItem");
9067
9069
  var P = {};
9068
- return I && C.selectedItem !== k.selectedItem && (w = C.selectedItem), (T = C).type || (T.type = Op), Object.keys(C).forEach(function(D) {
9070
+ return S && C.selectedItem !== k.selectedItem && (w = C.selectedItem), (T = C).type || (T.type = Op), Object.keys(C).forEach(function(D) {
9069
9071
  k[D] !== C[D] && (O[D] = C[D]), D !== "type" && (C[D], sn(n.props, D) || (P[D] = C[D]));
9070
9072
  }), _ && C.hasOwnProperty("inputValue") && n.props.onInputValueChange(C.inputValue, j({}, n.getStateAndHelpers(), C)), P;
9071
9073
  }, function() {
9072
9074
  bp(v)();
9073
9075
  var k = Object.keys(O).length > 1;
9074
- k && n.props.onStateChange(O, n.getStateAndHelpers()), I && n.props.onSelect(h.selectedItem, n.getStateAndHelpers()), w !== void 0 &&
9076
+ k && n.props.onStateChange(O, n.getStateAndHelpers()), S && n.props.onSelect(g.selectedItem, n.getStateAndHelpers()), w !== void 0 &&
9075
9077
  n.props.onChange(w, n.getStateAndHelpers()), n.props.onUserAction(O, n.getStateAndHelpers());
9076
9078
  });
9077
- }, n.rootRef = function(h) {
9078
- return n._rootNode = h;
9079
- }, n.getRootProps = function(h, v) {
9080
- var I, w = h === void 0 ? {} : h, O = w.refKey, _ = O === void 0 ? "ref" : O, k = w.ref, T = ke(w, Px), C = v === void 0 ? {} : v, P = C.
9079
+ }, n.rootRef = function(g) {
9080
+ return n._rootNode = g;
9081
+ }, n.getRootProps = function(g, v) {
9082
+ var S, w = g === void 0 ? {} : g, O = w.refKey, _ = O === void 0 ? "ref" : O, k = w.ref, T = ke(w, Px), C = v === void 0 ? {} : v, P = C.
9081
9083
  suppressRefError, D = P === void 0 ? !1 : P;
9082
9084
  n.getRootProps.called = !0, n.getRootProps.refKey = _, n.getRootProps.suppressRefError = D;
9083
9085
  var M = n.getState(), N = M.isOpen;
9084
- return j((I = {}, I[_] = Je(k, n.rootRef), I.role = "combobox", I["aria-expanded"] = N, I["aria-haspopup"] = "listbox", I["aria-owns"] =
9085
- N ? n.menuId : void 0, I["aria-labelledby"] = n.labelId, I), T);
9086
+ return j((S = {}, S[_] = Je(k, n.rootRef), S.role = "combobox", S["aria-expanded"] = N, S["aria-haspopup"] = "listbox", S["aria-owns"] =
9087
+ N ? n.menuId : void 0, S["aria-labelledby"] = n.labelId, S), T);
9086
9088
  }, n.keyDownHandlers = {
9087
9089
  ArrowDown: /* @__PURE__ */ a(function(v) {
9088
- var I = this;
9090
+ var S = this;
9089
9091
  if (v.preventDefault(), this.getState().isOpen) {
9090
9092
  var w = v.shiftKey ? 5 : 1;
9091
9093
  this.moveHighlightedIndex(w, {
@@ -9096,19 +9098,19 @@ Ox = /* @__PURE__ */ Object.freeze({
9096
9098
  isOpen: !0,
9097
9099
  type: on
9098
9100
  }, function() {
9099
- var O = I.getItemCount();
9101
+ var O = S.getItemCount();
9100
9102
  if (O > 0) {
9101
- var _ = I.getState(), k = _.highlightedIndex, T = et(k, 1, {
9103
+ var _ = S.getState(), k = _.highlightedIndex, T = et(k, 1, {
9102
9104
  length: O
9103
- }, I.isItemDisabled, !0);
9104
- I.setHighlightedIndex(T, {
9105
+ }, S.isItemDisabled, !0);
9106
+ S.setHighlightedIndex(T, {
9105
9107
  type: on
9106
9108
  });
9107
9109
  }
9108
9110
  });
9109
9111
  }, "ArrowDown"),
9110
9112
  ArrowUp: /* @__PURE__ */ a(function(v) {
9111
- var I = this;
9113
+ var S = this;
9112
9114
  if (v.preventDefault(), this.getState().isOpen) {
9113
9115
  var w = v.shiftKey ? -5 : -1;
9114
9116
  this.moveHighlightedIndex(w, {
@@ -9119,12 +9121,12 @@ Ox = /* @__PURE__ */ Object.freeze({
9119
9121
  isOpen: !0,
9120
9122
  type: tn
9121
9123
  }, function() {
9122
- var O = I.getItemCount();
9124
+ var O = S.getItemCount();
9123
9125
  if (O > 0) {
9124
- var _ = I.getState(), k = _.highlightedIndex, T = et(k, -1, {
9126
+ var _ = S.getState(), k = _.highlightedIndex, T = et(k, -1, {
9125
9127
  length: O
9126
- }, I.isItemDisabled, !0);
9127
- I.setHighlightedIndex(T, {
9128
+ }, S.isItemDisabled, !0);
9129
+ S.setHighlightedIndex(T, {
9128
9130
  type: tn
9129
9131
  });
9130
9132
  }
@@ -9132,7 +9134,7 @@ Ox = /* @__PURE__ */ Object.freeze({
9132
9134
  }, "ArrowUp"),
9133
9135
  Enter: /* @__PURE__ */ a(function(v) {
9134
9136
  if (v.which !== 229) {
9135
- var I = this.getState(), w = I.isOpen, O = I.highlightedIndex;
9137
+ var S = this.getState(), w = S.isOpen, O = S.highlightedIndex;
9136
9138
  if (w && O != null) {
9137
9139
  v.preventDefault();
9138
9140
  var _ = this.items[O], k = this.getItemNodeFromIndex(O);
@@ -9160,7 +9162,7 @@ Ox = /* @__PURE__ */ Object.freeze({
9160
9162
  }, "_")
9161
9163
  }), n.inputKeyDownHandlers = j({}, n.keyDownHandlers, {
9162
9164
  Home: /* @__PURE__ */ a(function(v) {
9163
- var I = this.getState(), w = I.isOpen;
9165
+ var S = this.getState(), w = S.isOpen;
9164
9166
  if (w) {
9165
9167
  v.preventDefault();
9166
9168
  var O = this.getItemCount();
@@ -9175,7 +9177,7 @@ Ox = /* @__PURE__ */ Object.freeze({
9175
9177
  }
9176
9178
  }, "Home"),
9177
9179
  End: /* @__PURE__ */ a(function(v) {
9178
- var I = this.getState(), w = I.isOpen;
9180
+ var S = this.getState(), w = S.isOpen;
9179
9181
  if (w) {
9180
9182
  v.preventDefault();
9181
9183
  var O = this.getItemCount();
@@ -9189,11 +9191,11 @@ Ox = /* @__PURE__ */ Object.freeze({
9189
9191
  }
9190
9192
  }
9191
9193
  }, "End")
9192
- }), n.getToggleButtonProps = function(h) {
9193
- var v = h === void 0 ? {} : h, I = v.onClick;
9194
+ }), n.getToggleButtonProps = function(g) {
9195
+ var v = g === void 0 ? {} : g, S = v.onClick;
9194
9196
  v.onPress;
9195
9197
  var w = v.onKeyDown, O = v.onKeyUp, _ = v.onBlur, k = ke(v, Ax), T = n.getState(), C = T.isOpen, P = {
9196
- onClick: le(I, n.buttonHandleClick),
9198
+ onClick: le(S, n.buttonHandleClick),
9197
9199
  onKeyDown: le(w, n.buttonHandleKeyDown),
9198
9200
  onKeyUp: le(O, n.buttonHandleKeyUp),
9199
9201
  onBlur: le(_, n.buttonHandleBlur)
@@ -9205,45 +9207,45 @@ Ox = /* @__PURE__ */ Object.freeze({
9205
9207
  "aria-haspopup": !0,
9206
9208
  "data-toggle": !0
9207
9209
  }, D, k);
9208
- }, n.buttonHandleKeyUp = function(h) {
9209
- h.preventDefault();
9210
- }, n.buttonHandleKeyDown = function(h) {
9211
- var v = po(h);
9212
- n.buttonKeyDownHandlers[v] && n.buttonKeyDownHandlers[v].call(n, h);
9213
- }, n.buttonHandleClick = function(h) {
9214
- if (h.preventDefault(), n.props.environment) {
9215
- var v = n.props.environment.document, I = v.body, w = v.activeElement;
9216
- I && I === w && h.target.focus();
9210
+ }, n.buttonHandleKeyUp = function(g) {
9211
+ g.preventDefault();
9212
+ }, n.buttonHandleKeyDown = function(g) {
9213
+ var v = po(g);
9214
+ n.buttonKeyDownHandlers[v] && n.buttonKeyDownHandlers[v].call(n, g);
9215
+ }, n.buttonHandleClick = function(g) {
9216
+ if (g.preventDefault(), n.props.environment) {
9217
+ var v = n.props.environment.document, S = v.body, w = v.activeElement;
9218
+ S && S === w && g.target.focus();
9217
9219
  }
9218
9220
  n.internalSetTimeout(function() {
9219
9221
  return n.toggleMenu({
9220
9222
  type: zp
9221
9223
  });
9222
9224
  });
9223
- }, n.buttonHandleBlur = function(h) {
9224
- var v = h.target;
9225
+ }, n.buttonHandleBlur = function(g) {
9226
+ var v = g.target;
9225
9227
  n.internalSetTimeout(function() {
9226
9228
  if (!(n.isMouseDown || !n.props.environment)) {
9227
- var I = n.props.environment.document.activeElement;
9228
- (I == null || I.id !== n.inputId) && I !== v && n.reset({
9229
+ var S = n.props.environment.document.activeElement;
9230
+ (S == null || S.id !== n.inputId) && S !== v && n.reset({
9229
9231
  type: Wp
9230
9232
  });
9231
9233
  }
9232
9234
  });
9233
- }, n.getLabelProps = function(h) {
9235
+ }, n.getLabelProps = function(g) {
9234
9236
  return j({
9235
9237
  htmlFor: n.inputId,
9236
9238
  id: n.labelId
9237
- }, h);
9238
- }, n.getInputProps = function(h) {
9239
- var v = h === void 0 ? {} : h, I = v.onKeyDown, w = v.onBlur, O = v.onChange, _ = v.onInput;
9239
+ }, g);
9240
+ }, n.getInputProps = function(g) {
9241
+ var v = g === void 0 ? {} : g, S = v.onKeyDown, w = v.onBlur, O = v.onChange, _ = v.onInput;
9240
9242
  v.onChangeText;
9241
9243
  var k = ke(v, Dx), T, C = {};
9242
9244
  T = "onChange";
9243
9245
  var P = n.getState(), D = P.inputValue, M = P.isOpen, N = P.highlightedIndex;
9244
9246
  if (!k.disabled) {
9245
9247
  var Z;
9246
- C = (Z = {}, Z[T] = le(O, _, n.inputHandleChange), Z.onKeyDown = le(I, n.inputHandleKeyDown), Z.onBlur = le(w, n.inputHandleBlur),
9248
+ C = (Z = {}, Z[T] = le(O, _, n.inputHandleChange), Z.onKeyDown = le(S, n.inputHandleKeyDown), Z.onBlur = le(w, n.inputHandleBlur),
9247
9249
  Z);
9248
9250
  }
9249
9251
  return j({
@@ -9257,41 +9259,41 @@ Ox = /* @__PURE__ */ Object.freeze({
9257
9259
  value: D,
9258
9260
  id: n.inputId
9259
9261
  }, C, k);
9260
- }, n.inputHandleKeyDown = function(h) {
9261
- var v = po(h);
9262
- v && n.inputKeyDownHandlers[v] && n.inputKeyDownHandlers[v].call(n, h);
9263
- }, n.inputHandleChange = function(h) {
9262
+ }, n.inputHandleKeyDown = function(g) {
9263
+ var v = po(g);
9264
+ v && n.inputKeyDownHandlers[v] && n.inputKeyDownHandlers[v].call(n, g);
9265
+ }, n.inputHandleChange = function(g) {
9264
9266
  n.internalSetState({
9265
9267
  type: Bp,
9266
9268
  isOpen: !0,
9267
- inputValue: h.target.value,
9269
+ inputValue: g.target.value,
9268
9270
  highlightedIndex: n.props.defaultHighlightedIndex
9269
9271
  });
9270
9272
  }, n.inputHandleBlur = function() {
9271
9273
  n.internalSetTimeout(function() {
9272
- var h;
9274
+ var g;
9273
9275
  if (!(n.isMouseDown || !n.props.environment)) {
9274
- var v = n.props.environment.document.activeElement, I = (v == null || (h = v.dataset) == null ? void 0 : h.toggle) && n._rootNode &&
9276
+ var v = n.props.environment.document.activeElement, S = (v == null || (g = v.dataset) == null ? void 0 : g.toggle) && n._rootNode &&
9275
9277
  n._rootNode.contains(v);
9276
- I || n.reset({
9278
+ S || n.reset({
9277
9279
  type: Rp
9278
9280
  });
9279
9281
  }
9280
9282
  });
9281
- }, n.menuRef = function(h) {
9282
- n._menuNode = h;
9283
- }, n.getMenuProps = function(h, v) {
9284
- var I, w = h === void 0 ? {} : h, O = w.refKey, _ = O === void 0 ? "ref" : O, k = w.ref, T = ke(w, Mx), C = v === void 0 ? {} : v, P = C.
9283
+ }, n.menuRef = function(g) {
9284
+ n._menuNode = g;
9285
+ }, n.getMenuProps = function(g, v) {
9286
+ var S, w = g === void 0 ? {} : g, O = w.refKey, _ = O === void 0 ? "ref" : O, k = w.ref, T = ke(w, Mx), C = v === void 0 ? {} : v, P = C.
9285
9287
  suppressRefError, D = P === void 0 ? !1 : P;
9286
- return n.getMenuProps.called = !0, n.getMenuProps.refKey = _, n.getMenuProps.suppressRefError = D, j((I = {}, I[_] = Je(k, n.menuRef),
9287
- I.role = "listbox", I["aria-labelledby"] = T && T["aria-label"] ? void 0 : n.labelId, I.id = n.menuId, I), T);
9288
- }, n.getItemProps = function(h) {
9289
- var v, I = h === void 0 ? {} : h, w = I.onMouseMove, O = I.onMouseDown, _ = I.onClick;
9290
- I.onPress;
9291
- var k = I.index, T = I.item, C = T === void 0 ? (
9288
+ return n.getMenuProps.called = !0, n.getMenuProps.refKey = _, n.getMenuProps.suppressRefError = D, j((S = {}, S[_] = Je(k, n.menuRef),
9289
+ S.role = "listbox", S["aria-labelledby"] = T && T["aria-label"] ? void 0 : n.labelId, S.id = n.menuId, S), T);
9290
+ }, n.getItemProps = function(g) {
9291
+ var v, S = g === void 0 ? {} : g, w = S.onMouseMove, O = S.onMouseDown, _ = S.onClick;
9292
+ S.onPress;
9293
+ var k = S.index, T = S.item, C = T === void 0 ? (
9292
9294
  /* istanbul ignore next */
9293
9295
  void 0
9294
- ) : T, P = ke(I, Lx);
9296
+ ) : T, P = ke(S, Lx);
9295
9297
  k === void 0 ? (n.items.push(C), k = n.items.indexOf(C)) : n.items[k] = C;
9296
9298
  var D = "onClick", M = _, N = (v = {
9297
9299
  // onMouseMove is used over onMouseEnter here. onMouseMove
@@ -9321,54 +9323,54 @@ Ox = /* @__PURE__ */ Object.freeze({
9321
9323
  }, Z, P);
9322
9324
  }, n.clearItems = function() {
9323
9325
  n.items = [];
9324
- }, n.reset = function(h, v) {
9325
- h === void 0 && (h = {}), h = en(h), n.internalSetState(function(I) {
9326
- var w = I.selectedItem;
9326
+ }, n.reset = function(g, v) {
9327
+ g === void 0 && (g = {}), g = en(g), n.internalSetState(function(S) {
9328
+ var w = S.selectedItem;
9327
9329
  return j({
9328
9330
  isOpen: n.props.defaultIsOpen,
9329
9331
  highlightedIndex: n.props.defaultHighlightedIndex,
9330
9332
  inputValue: n.props.itemToString(w)
9331
- }, h);
9333
+ }, g);
9332
9334
  }, v);
9333
- }, n.toggleMenu = function(h, v) {
9334
- h === void 0 && (h = {}), h = en(h), n.internalSetState(function(I) {
9335
- var w = I.isOpen;
9335
+ }, n.toggleMenu = function(g, v) {
9336
+ g === void 0 && (g = {}), g = en(g), n.internalSetState(function(S) {
9337
+ var w = S.isOpen;
9336
9338
  return j({
9337
9339
  isOpen: !w
9338
9340
  }, w && {
9339
9341
  highlightedIndex: n.props.defaultHighlightedIndex
9340
- }, h);
9342
+ }, g);
9341
9343
  }, function() {
9342
- var I = n.getState(), w = I.isOpen, O = I.highlightedIndex;
9343
- w && n.getItemCount() > 0 && typeof O == "number" && n.setHighlightedIndex(O, h), bp(v)();
9344
+ var S = n.getState(), w = S.isOpen, O = S.highlightedIndex;
9345
+ w && n.getItemCount() > 0 && typeof O == "number" && n.setHighlightedIndex(O, g), bp(v)();
9344
9346
  });
9345
- }, n.openMenu = function(h) {
9347
+ }, n.openMenu = function(g) {
9346
9348
  n.internalSetState({
9347
9349
  isOpen: !0
9348
- }, h);
9349
- }, n.closeMenu = function(h) {
9350
+ }, g);
9351
+ }, n.closeMenu = function(g) {
9350
9352
  n.internalSetState({
9351
9353
  isOpen: !1
9352
- }, h);
9354
+ }, g);
9353
9355
  }, n.updateStatus = fn(function() {
9354
- var h;
9355
- if ((h = n.props) != null && (h = h.environment) != null && h.document) {
9356
- var v = n.getState(), I = n.items[v.highlightedIndex], w = n.getItemCount(), O = n.props.getA11yStatusMessage(j({
9356
+ var g;
9357
+ if ((g = n.props) != null && (g = g.environment) != null && g.document) {
9358
+ var v = n.getState(), S = n.items[v.highlightedIndex], w = n.getItemCount(), O = n.props.getA11yStatusMessage(j({
9357
9359
  itemToString: n.props.itemToString,
9358
9360
  previousResultCount: n.previousResultCount,
9359
9361
  resultCount: w,
9360
- highlightedItem: I
9362
+ highlightedItem: S
9361
9363
  }, v));
9362
9364
  n.previousResultCount = w, kp(O, n.props.environment.document);
9363
9365
  }
9364
9366
  }, 200);
9365
- var l = n.props, u = l.defaultHighlightedIndex, c = l.initialHighlightedIndex, p = c === void 0 ? u : c, d = l.defaultIsOpen, m = l.initialIsOpen,
9366
- g = m === void 0 ? d : m, b = l.initialInputValue, f = b === void 0 ? "" : b, y = l.initialSelectedItem, S = y === void 0 ? null : y, E = n.
9367
+ var l = n.props, u = l.defaultHighlightedIndex, c = l.initialHighlightedIndex, d = c === void 0 ? u : c, p = l.defaultIsOpen, m = l.initialIsOpen,
9368
+ h = m === void 0 ? p : m, b = l.initialInputValue, f = b === void 0 ? "" : b, y = l.initialSelectedItem, I = y === void 0 ? null : y, E = n.
9367
9369
  getState({
9368
- highlightedIndex: p,
9369
- isOpen: g,
9370
+ highlightedIndex: d,
9371
+ isOpen: h,
9370
9372
  inputValue: f,
9371
- selectedItem: S
9373
+ selectedItem: I
9372
9374
  });
9373
9375
  return E.selectedItem != null && n.props.initialInputValue === void 0 && (E.inputValue = n.props.itemToString(E.selectedItem)), n.state =
9374
9376
  E, n;
@@ -9392,32 +9394,32 @@ Ox = /* @__PURE__ */ Object.freeze({
9392
9394
  this.props.scrollIntoView(n, this._menuNode);
9393
9395
  }
9394
9396
  }, "scrollHighlightedItemIntoView"), i.moveHighlightedIndex = /* @__PURE__ */ a(function(n, l) {
9395
- var u = this.getItemCount(), c = this.getState(), p = c.highlightedIndex;
9397
+ var u = this.getItemCount(), c = this.getState(), d = c.highlightedIndex;
9396
9398
  if (u > 0) {
9397
- var d = et(p, n, {
9399
+ var p = et(d, n, {
9398
9400
  length: u
9399
9401
  }, this.isItemDisabled, !0);
9400
- this.setHighlightedIndex(d, l);
9402
+ this.setHighlightedIndex(p, l);
9401
9403
  }
9402
9404
  }, "moveHighlightedIndex"), i.getStateAndHelpers = /* @__PURE__ */ a(function() {
9403
- var n = this.getState(), l = n.highlightedIndex, u = n.inputValue, c = n.selectedItem, p = n.isOpen, d = this.props.itemToString, m = this.
9404
- id, g = this.getRootProps, b = this.getToggleButtonProps, f = this.getLabelProps, y = this.getMenuProps, S = this.getInputProps, E = this.
9405
- getItemProps, h = this.openMenu, v = this.closeMenu, I = this.toggleMenu, w = this.selectItem, O = this.selectItemAtIndex, _ = this.selectHighlightedItem,
9405
+ var n = this.getState(), l = n.highlightedIndex, u = n.inputValue, c = n.selectedItem, d = n.isOpen, p = this.props.itemToString, m = this.
9406
+ id, h = this.getRootProps, b = this.getToggleButtonProps, f = this.getLabelProps, y = this.getMenuProps, I = this.getInputProps, E = this.
9407
+ getItemProps, g = this.openMenu, v = this.closeMenu, S = this.toggleMenu, w = this.selectItem, O = this.selectItemAtIndex, _ = this.selectHighlightedItem,
9406
9408
  k = this.setHighlightedIndex, T = this.clearSelection, C = this.clearItems, P = this.reset, D = this.setItemCount, M = this.unsetItemCount,
9407
9409
  N = this.internalSetState;
9408
9410
  return {
9409
9411
  // prop getters
9410
- getRootProps: g,
9412
+ getRootProps: h,
9411
9413
  getToggleButtonProps: b,
9412
9414
  getLabelProps: f,
9413
9415
  getMenuProps: y,
9414
- getInputProps: S,
9416
+ getInputProps: I,
9415
9417
  getItemProps: E,
9416
9418
  // actions
9417
9419
  reset: P,
9418
- openMenu: h,
9420
+ openMenu: g,
9419
9421
  closeMenu: v,
9420
- toggleMenu: I,
9422
+ toggleMenu: S,
9421
9423
  selectItem: w,
9422
9424
  selectItemAtIndex: O,
9423
9425
  selectHighlightedItem: _,
@@ -9428,13 +9430,13 @@ Ox = /* @__PURE__ */ Object.freeze({
9428
9430
  unsetItemCount: M,
9429
9431
  setState: N,
9430
9432
  // props
9431
- itemToString: d,
9433
+ itemToString: p,
9432
9434
  // derived
9433
9435
  id: m,
9434
9436
  // state
9435
9437
  highlightedIndex: l,
9436
9438
  inputValue: u,
9437
- isOpen: p,
9439
+ isOpen: d,
9438
9440
  selectedItem: c
9439
9441
  };
9440
9442
  }, "getStateAndHelpers"), i.componentDidMount = /* @__PURE__ */ a(function() {
@@ -9456,9 +9458,9 @@ Ox = /* @__PURE__ */ Object.freeze({
9456
9458
  });
9457
9459
  }, "onMouseUp"), c = /* @__PURE__ */ a(function() {
9458
9460
  n.isTouchMove = !1;
9459
- }, "onTouchStart"), p = /* @__PURE__ */ a(function() {
9461
+ }, "onTouchStart"), d = /* @__PURE__ */ a(function() {
9460
9462
  n.isTouchMove = !0;
9461
- }, "onTouchMove"), d = /* @__PURE__ */ a(function(b) {
9463
+ }, "onTouchMove"), p = /* @__PURE__ */ a(function(b) {
9462
9464
  var f = an(b.target, [n._rootNode, n._menuNode], n.props.environment, !1);
9463
9465
  !n.isTouchMove && !f && n.getState().isOpen && n.reset({
9464
9466
  type: jp
@@ -9467,15 +9469,15 @@ Ox = /* @__PURE__ */ Object.freeze({
9467
9469
  });
9468
9470
  }, "onTouchEnd"), m = this.props.environment;
9469
9471
  m.addEventListener("mousedown", l), m.addEventListener("mouseup", u), m.addEventListener("touchstart", c), m.addEventListener("touch\
9470
- move", p), m.addEventListener("touchend", d), this.cleanup = function() {
9472
+ move", d), m.addEventListener("touchend", p), this.cleanup = function() {
9471
9473
  n.internalClearTimeouts(), n.updateStatus.cancel(), m.removeEventListener("mousedown", l), m.removeEventListener("mouseup", u), m.
9472
- removeEventListener("touchstart", c), m.removeEventListener("touchmove", p), m.removeEventListener("touchend", d);
9474
+ removeEventListener("touchstart", c), m.removeEventListener("touchmove", d), m.removeEventListener("touchend", p);
9473
9475
  };
9474
9476
  }
9475
9477
  }, "componentDidMount"), i.shouldScroll = /* @__PURE__ */ a(function(n, l) {
9476
- var u = this.props.highlightedIndex === void 0 ? this.getState() : this.props, c = u.highlightedIndex, p = l.highlightedIndex === void 0 ?
9477
- n : l, d = p.highlightedIndex, m = c && this.getState().isOpen && !n.isOpen, g = c !== d;
9478
- return m || g;
9478
+ var u = this.props.highlightedIndex === void 0 ? this.getState() : this.props, c = u.highlightedIndex, d = l.highlightedIndex === void 0 ?
9479
+ n : l, p = d.highlightedIndex, m = c && this.getState().isOpen && !n.isOpen, h = c !== p;
9480
+ return m || h;
9479
9481
  }, "shouldScroll"), i.componentDidUpdate = /* @__PURE__ */ a(function(n, l) {
9480
9482
  sn(this.props, "selectedItem") && this.props.selectedItemChanged(n.selectedItem, this.props.selectedItem) && this.internalSetState({
9481
9483
  type: Vp,
@@ -9556,28 +9558,28 @@ var Ip = fn(function(e, t) {
9556
9558
  /* @__PURE__ */ a(function(t) {
9557
9559
  var o = t.id, i = t.labelId, r = t.menuId, n = t.getItemId, l = t.toggleButtonId, u = t.inputId, c = "downshift-" + s.useId();
9558
9560
  o || (o = c);
9559
- var p = q({
9561
+ var d = q({
9560
9562
  labelId: i || o + "-label",
9561
9563
  menuId: r || o + "-menu",
9562
- getItemId: n || function(d) {
9563
- return o + "-item-" + d;
9564
+ getItemId: n || function(p) {
9565
+ return o + "-item-" + p;
9564
9566
  },
9565
9567
  toggleButtonId: l || o + "-toggle-button",
9566
9568
  inputId: u || o + "-input"
9567
9569
  });
9568
- return p.current;
9570
+ return d.current;
9569
9571
  }, "useElementIds") : /* @__PURE__ */ a(function(t) {
9570
9572
  var o = t.id, i = o === void 0 ? "downshift-" + Cp() : o, r = t.labelId, n = t.menuId, l = t.getItemId, u = t.toggleButtonId, c = t.inputId,
9571
- p = q({
9573
+ d = q({
9572
9574
  labelId: r || i + "-label",
9573
9575
  menuId: n || i + "-menu",
9574
- getItemId: l || function(d) {
9575
- return i + "-item-" + d;
9576
+ getItemId: l || function(p) {
9577
+ return i + "-item-" + p;
9576
9578
  },
9577
9579
  toggleButtonId: u || i + "-toggle-button",
9578
9580
  inputId: c || i + "-input"
9579
9581
  });
9580
- return p.current;
9582
+ return d.current;
9581
9583
  }, "useElementIds");
9582
9584
  function qi(e, t, o, i) {
9583
9585
  var r, n;
@@ -9606,19 +9608,19 @@ a(mn, "useLatestRef");
9606
9608
  function Up(e, t, o, i) {
9607
9609
  var r = q(), n = q(), l = A(function(b, f) {
9608
9610
  n.current = f, b = Vo(b, f.props);
9609
- var y = e(b, f), S = f.props.stateReducer(b, j({}, f, {
9611
+ var y = e(b, f), I = f.props.stateReducer(b, j({}, f, {
9610
9612
  changes: y
9611
9613
  }));
9612
- return S;
9613
- }, [e]), u = Zt(l, t, o), c = u[0], p = u[1], d = mn(t), m = A(function(b) {
9614
- return p(j({
9615
- props: d.current
9614
+ return I;
9615
+ }, [e]), u = Zt(l, t, o), c = u[0], d = u[1], p = mn(t), m = A(function(b) {
9616
+ return d(j({
9617
+ props: p.current
9616
9618
  }, b));
9617
- }, [d]), g = n.current;
9619
+ }, [p]), h = n.current;
9618
9620
  return V(function() {
9619
- var b = Vo(r.current, g?.props), f = g && r.current && !i(b, c);
9620
- f && Nx(g, b, c), r.current = c;
9621
- }, [c, g, i]), [c, m];
9621
+ var b = Vo(r.current, h?.props), f = h && r.current && !i(b, c);
9622
+ f && Nx(h, b, c), r.current = c;
9623
+ }, [c, h, i]), [c, m];
9622
9624
  }
9623
9625
  a(Up, "useEnhancedReducer");
9624
9626
  function Gp(e, t, o, i) {
@@ -9668,10 +9670,10 @@ function qp(e) {
9668
9670
  }
9669
9671
  a(qp, "getInitialState$2");
9670
9672
  function Gt(e, t, o) {
9671
- var i = e.items, r = e.initialHighlightedIndex, n = e.defaultHighlightedIndex, l = e.isItemDisabled, u = e.itemToKey, c = t.selectedItem, p = t.
9673
+ var i = e.items, r = e.initialHighlightedIndex, n = e.defaultHighlightedIndex, l = e.isItemDisabled, u = e.itemToKey, c = t.selectedItem, d = t.
9672
9674
  highlightedIndex;
9673
- return i.length === 0 ? -1 : r !== void 0 && p === r && !l(i[r], r) ? r : n !== void 0 && !l(i[n], n) ? n : c ? i.findIndex(function(d) {
9674
- return u(c) === u(d);
9675
+ return i.length === 0 ? -1 : r !== void 0 && d === r && !l(i[r], r) ? r : n !== void 0 && !l(i[n], n) ? n : c ? i.findIndex(function(p) {
9676
+ return u(c) === u(p);
9675
9677
  }) : o < 0 && !l(i[i.length - 1], i.length - 1) ? i.length - 1 : o > 0 && !l(i[0], 0) ? 0 : -1;
9676
9678
  }
9677
9679
  a(Gt, "getHighlightedIndexOnOpen");
@@ -9684,15 +9686,15 @@ function Yp(e, t, o) {
9684
9686
  return V(function() {
9685
9687
  if (!e)
9686
9688
  return Be;
9687
- var r = o.map(function(d) {
9688
- return d.current;
9689
+ var r = o.map(function(p) {
9690
+ return p.current;
9689
9691
  });
9690
9692
  function n() {
9691
9693
  i.current.isTouchEnd = !1, i.current.isMouseDown = !0;
9692
9694
  }
9693
9695
  a(n, "onMouseDown");
9694
- function l(d) {
9695
- i.current.isMouseDown = !1, an(d.target, r, e) || t();
9696
+ function l(p) {
9697
+ i.current.isMouseDown = !1, an(p.target, r, e) || t();
9696
9698
  }
9697
9699
  a(l, "onMouseUp");
9698
9700
  function u() {
@@ -9703,13 +9705,13 @@ function Yp(e, t, o) {
9703
9705
  i.current.isTouchMove = !0;
9704
9706
  }
9705
9707
  a(c, "onTouchMove");
9706
- function p(d) {
9707
- i.current.isTouchEnd = !0, !i.current.isTouchMove && !an(d.target, r, e, !1) && t();
9708
+ function d(p) {
9709
+ i.current.isTouchEnd = !0, !i.current.isTouchMove && !an(p.target, r, e, !1) && t();
9708
9710
  }
9709
- return a(p, "onTouchEnd"), e.addEventListener("mousedown", n), e.addEventListener("mouseup", l), e.addEventListener("touchstart", u), e.
9710
- addEventListener("touchmove", c), e.addEventListener("touchend", p), /* @__PURE__ */ a(function() {
9711
+ return a(d, "onTouchEnd"), e.addEventListener("mousedown", n), e.addEventListener("mouseup", l), e.addEventListener("touchstart", u), e.
9712
+ addEventListener("touchmove", c), e.addEventListener("touchend", d), /* @__PURE__ */ a(function() {
9711
9713
  e.removeEventListener("mousedown", n), e.removeEventListener("mouseup", l), e.removeEventListener("touchstart", u), e.removeEventListener(
9712
- "touchmove", c), e.removeEventListener("touchend", p);
9714
+ "touchmove", c), e.removeEventListener("touchend", d);
9713
9715
  }, "cleanup");
9714
9716
  }, [o, e, t]), i.current;
9715
9717
  }
@@ -9874,14 +9876,14 @@ a(Jp, "downshiftCommonReducer");
9874
9876
  function Wx(e) {
9875
9877
  for (var t = e.keysSoFar, o = e.highlightedIndex, i = e.items, r = e.itemToString, n = e.isItemDisabled, l = t.toLowerCase(), u = 0; u < i.
9876
9878
  length; u++) {
9877
- var c = (u + o + (t.length < 2 ? 1 : 0)) % i.length, p = i[c];
9878
- if (p !== void 0 && r(p).toLowerCase().startsWith(l) && !n(p, c))
9879
+ var c = (u + o + (t.length < 2 ? 1 : 0)) % i.length, d = i[c];
9880
+ if (d !== void 0 && r(d).toLowerCase().startsWith(l) && !n(d, c))
9879
9881
  return c;
9880
9882
  }
9881
9883
  return o;
9882
9884
  }
9883
9885
  a(Wx, "getItemIndexByCharacterKey");
9884
- var bR = $t($t({}, Zp), { items: Y.default.array.isRequired, isItemDisabled: Y.default.func }), Vx = $t($t({}, Wo), { isItemDisabled: /* @__PURE__ */ a(
9886
+ var vR = $t($t({}, Zp), { items: Y.default.array.isRequired, isItemDisabled: Y.default.func }), Vx = $t($t({}, Wo), { isItemDisabled: /* @__PURE__ */ a(
9885
9887
  function() {
9886
9888
  return !1;
9887
9889
  }, "isItemDisabled") }), jx = Be, nn = 0, Ji = 1, es = 2, cn = 3, ts = 4, os = 5, rs = 6, ns = 7, is = 8, ss = 9, as = 10, pn = 11, ed = 12,
@@ -9922,18 +9924,18 @@ function Kx(e, t) {
9922
9924
  break;
9923
9925
  case cn:
9924
9926
  {
9925
- var u = t.key, c = "" + e.inputValue + u, p = !e.isOpen && e.selectedItem ? r.items.findIndex(function(b) {
9927
+ var u = t.key, c = "" + e.inputValue + u, d = !e.isOpen && e.selectedItem ? r.items.findIndex(function(b) {
9926
9928
  return r.itemToKey(b) === r.itemToKey(e.selectedItem);
9927
- }) : e.highlightedIndex, d = Wx({
9929
+ }) : e.highlightedIndex, p = Wx({
9928
9930
  keysSoFar: c,
9929
- highlightedIndex: p,
9931
+ highlightedIndex: d,
9930
9932
  items: r.items,
9931
9933
  itemToString: r.itemToString,
9932
9934
  isItemDisabled: r.isItemDisabled
9933
9935
  });
9934
9936
  l = {
9935
9937
  inputValue: c,
9936
- highlightedIndex: d,
9938
+ highlightedIndex: p,
9937
9939
  isOpen: !0
9938
9940
  };
9939
9941
  }
@@ -9951,9 +9953,9 @@ function Kx(e, t) {
9951
9953
  if (e.isOpen && n)
9952
9954
  l = ln(r, e.highlightedIndex, !1);
9953
9955
  else {
9954
- var g = e.isOpen ? et(e.highlightedIndex, -1, r.items, r.isItemDisabled) : Gt(r, e, -1);
9956
+ var h = e.isOpen ? et(e.highlightedIndex, -1, r.items, r.isItemDisabled) : Gt(r, e, -1);
9955
9957
  l = {
9956
- highlightedIndex: g,
9958
+ highlightedIndex: h,
9957
9959
  isOpen: !0
9958
9960
  };
9959
9961
  }
@@ -10016,21 +10018,21 @@ ld.stateChangeTypes = ad;
10016
10018
  function ld(e) {
10017
10019
  e === void 0 && (e = {}), jx(e, ld);
10018
10020
  var t = j({}, Vx, e), o = t.scrollIntoView, i = t.environment, r = t.getA11yStatusMessage, n = Gp(Kx, t, qp, Xp), l = n[0], u = n[1], c = l.
10019
- isOpen, p = l.highlightedIndex, d = l.selectedItem, m = l.inputValue, g = q(null), b = q(null), f = q({}), y = q(null), S = $p(t), E = mn(
10021
+ isOpen, d = l.highlightedIndex, p = l.selectedItem, m = l.inputValue, h = q(null), b = q(null), f = q({}), y = q(null), I = $p(t), E = mn(
10020
10022
  {
10021
10023
  state: l,
10022
10024
  props: t
10023
- }), h = A(function(B) {
10024
- return f.current[S.getItemId(B)];
10025
- }, [S]);
10026
- Xi(r, l, [c, p, d, m], i);
10025
+ }), g = A(function(B) {
10026
+ return f.current[I.getItemId(B)];
10027
+ }, [I]);
10028
+ Xi(r, l, [c, d, p, m], i);
10027
10029
  var v = Qp({
10028
10030
  menuElement: b.current,
10029
- highlightedIndex: p,
10031
+ highlightedIndex: d,
10030
10032
  isOpen: c,
10031
10033
  itemRefs: f,
10032
10034
  scrollIntoView: o,
10033
- getItemNodeFromIndex: h
10035
+ getItemNodeFromIndex: g
10034
10036
  });
10035
10037
  V(function() {
10036
10038
  return y.current = fn(function(B) {
@@ -10048,15 +10050,15 @@ function ld(e) {
10048
10050
  state: l
10049
10051
  }), V(function() {
10050
10052
  var B = Ut(t, "isOpen");
10051
- B && g.current && g.current.focus();
10053
+ B && h.current && h.current.focus();
10052
10054
  }, []);
10053
- var I = Yp(i, A(/* @__PURE__ */ a(function() {
10055
+ var S = Yp(i, A(/* @__PURE__ */ a(function() {
10054
10056
  E.current.state.isOpen && u({
10055
10057
  type: pn
10056
10058
  });
10057
10059
  }, "handleBlur"), [u, E]), U(function() {
10058
- return [b, g];
10059
- }, [b.current, g.current])), w = Qi("getMenuProps", "getToggleButtonProps");
10060
+ return [b, h];
10061
+ }, [b.current, h.current])), w = Qi("getMenuProps", "getToggleButtonProps");
10060
10062
  V(function() {
10061
10063
  c || (f.current = {});
10062
10064
  }, [c]);
@@ -10155,14 +10157,14 @@ function ld(e) {
10155
10157
  }, [u]), N = A(function(B) {
10156
10158
  var G = B === void 0 ? {} : B, H = G.onClick, re = ke(G, $x), F = /* @__PURE__ */ a(function() {
10157
10159
  var L;
10158
- (L = g.current) == null || L.focus();
10160
+ (L = h.current) == null || L.focus();
10159
10161
  }, "labelHandleClick");
10160
10162
  return j({
10161
- id: S.labelId,
10162
- htmlFor: S.toggleButtonId,
10163
+ id: I.labelId,
10164
+ htmlFor: I.toggleButtonId,
10163
10165
  onClick: le(H, F)
10164
10166
  }, re);
10165
- }, [S]), Z = A(function(B, G) {
10167
+ }, [I]), Z = A(function(B, G) {
10166
10168
  var H, re = B === void 0 ? {} : B, F = re.onMouseLeave, R = re.refKey, L = R === void 0 ? "ref" : R, $ = re.ref, J = ke(re, Ux), ie = G ===
10167
10169
  void 0 ? {} : G, te = ie.suppressRefError, de = te === void 0 ? !1 : te, ae = /* @__PURE__ */ a(function() {
10168
10170
  u({
@@ -10171,9 +10173,9 @@ function ld(e) {
10171
10173
  }, "menuHandleMouseLeave");
10172
10174
  return w("getMenuProps", de, L, b), j((H = {}, H[L] = Je($, function(ce) {
10173
10175
  b.current = ce;
10174
- }), H.id = S.menuId, H.role = "listbox", H["aria-labelledby"] = J && J["aria-label"] ? void 0 : "" + S.labelId, H.onMouseLeave = le(F, ae),
10176
+ }), H.id = I.menuId, H.role = "listbox", H["aria-labelledby"] = J && J["aria-label"] ? void 0 : "" + I.labelId, H.onMouseLeave = le(F, ae),
10175
10177
  H), J);
10176
- }, [u, w, S]), W = A(function(B, G) {
10178
+ }, [u, w, I]), W = A(function(B, G) {
10177
10179
  var H, re = B === void 0 ? {} : B, F = re.onBlur, R = re.onClick;
10178
10180
  re.onPress;
10179
10181
  var L = re.onKeyDown, $ = re.refKey, J = $ === void 0 ? "ref" : $, ie = re.ref, te = ke(re, Gx), de = G === void 0 ? {} : G, ae = de.suppressRefError,
@@ -10182,7 +10184,7 @@ function ld(e) {
10182
10184
  type: nn
10183
10185
  });
10184
10186
  }, "toggleButtonHandleClick"), ye = /* @__PURE__ */ a(function() {
10185
- ue.isOpen && !I.isMouseDown && u({
10187
+ ue.isOpen && !S.isMouseDown && u({
10186
10188
  type: pn
10187
10189
  });
10188
10190
  }, "toggleButtonHandleBlur"), Oe = /* @__PURE__ */ a(function(_e) {
@@ -10192,12 +10194,12 @@ function ld(e) {
10192
10194
  key: De
10193
10195
  });
10194
10196
  }, "toggleButtonHandleKeyDown"), fe = j((H = {}, H[J] = Je(ie, function(Se) {
10195
- g.current = Se;
10196
- }), H["aria-activedescendant"] = ue.isOpen && ue.highlightedIndex > -1 ? S.getItemId(ue.highlightedIndex) : "", H["aria-controls"] = S.menuId,
10197
+ h.current = Se;
10198
+ }), H["aria-activedescendant"] = ue.isOpen && ue.highlightedIndex > -1 ? I.getItemId(ue.highlightedIndex) : "", H["aria-controls"] = I.menuId,
10197
10199
  H["aria-expanded"] = E.current.state.isOpen, H["aria-haspopup"] = "listbox", H["aria-labelledby"] = te && te["aria-label"] ? void 0 : "" +
10198
- S.labelId, H.id = S.toggleButtonId, H.role = "combobox", H.tabIndex = 0, H.onBlur = le(F, ye), H), te);
10199
- return te.disabled || (fe.onClick = le(R, Ie), fe.onKeyDown = le(L, Oe)), w("getToggleButtonProps", ce, J, g), fe;
10200
- }, [u, S, E, I, w, O]), Q = A(function(B) {
10200
+ I.labelId, H.id = I.toggleButtonId, H.role = "combobox", H.tabIndex = 0, H.onBlur = le(F, ye), H), te);
10201
+ return te.disabled || (fe.onClick = le(R, Ie), fe.onKeyDown = le(L, Oe)), w("getToggleButtonProps", ce, J, h), fe;
10202
+ }, [u, I, E, S, w, O]), Q = A(function(B) {
10201
10203
  var G, H = B === void 0 ? {} : B, re = H.item, F = H.index, R = H.onMouseMove, L = H.onClick, $ = H.onMouseDown;
10202
10204
  H.onPress;
10203
10205
  var J = H.refKey, ie = J === void 0 ? "ref" : J, te = H.disabled, de = H.ref, ae = ke(H, qx);
@@ -10205,7 +10207,7 @@ function ld(e) {
10205
10207
  prop from useSelect.');
10206
10208
  var ce = E.current, ue = ce.state, Ie = ce.props, ye = qi(re, F, Ie.items, "Pass either item or index to getItemProps!"), Oe = ye[0], fe = ye[1],
10207
10209
  Se = Ie.isItemDisabled(Oe, fe), _e = /* @__PURE__ */ a(function() {
10208
- I.isTouchEnd || fe === ue.highlightedIndex || (v.current = !1, u({
10210
+ S.isTouchEnd || fe === ue.highlightedIndex || (v.current = !1, u({
10209
10211
  type: td,
10210
10212
  index: fe,
10211
10213
  disabled: Se
@@ -10218,10 +10220,10 @@ function ld(e) {
10218
10220
  }, "itemHandleClick"), z = /* @__PURE__ */ a(function(fo) {
10219
10221
  return fo.preventDefault();
10220
10222
  }, "itemHandleMouseDown"), Pe = j((G = {}, G[ie] = Je(de, function(qe) {
10221
- qe && (f.current[S.getItemId(fe)] = qe);
10222
- }), G["aria-disabled"] = Se, G["aria-selected"] = Oe === ue.selectedItem, G.id = S.getItemId(fe), G.role = "option", G), ae);
10223
+ qe && (f.current[I.getItemId(fe)] = qe);
10224
+ }), G["aria-disabled"] = Se, G["aria-selected"] = Oe === ue.selectedItem, G.id = I.getItemId(fe), G.role = "option", G), ae);
10223
10225
  return Se || (Pe.onClick = le(L, De)), Pe.onMouseMove = le(R, _e), Pe.onMouseDown = le($, z), Pe;
10224
- }, [E, S, I, v, u]);
10226
+ }, [E, I, S, v, u]);
10225
10227
  return {
10226
10228
  // prop getters.
10227
10229
  getToggleButtonProps: W,
@@ -10237,9 +10239,9 @@ function ld(e) {
10237
10239
  reset: D,
10238
10240
  setInputValue: M,
10239
10241
  // state.
10240
- highlightedIndex: p,
10242
+ highlightedIndex: d,
10241
10243
  isOpen: c,
10242
- selectedItem: d,
10244
+ selectedItem: p,
10243
10245
  inputValue: m
10244
10246
  };
10245
10247
  }
@@ -10279,7 +10281,7 @@ function Yx(e) {
10279
10281
  });
10280
10282
  }
10281
10283
  a(Yx, "getInitialState$1");
10282
- var vR = j({}, Zp, {
10284
+ var xR = j({}, Zp, {
10283
10285
  items: Y.default.array.isRequired,
10284
10286
  isItemDisabled: Y.default.func,
10285
10287
  inputValue: Y.default.string,
@@ -10293,8 +10295,8 @@ function Qx(e, t, o, i) {
10293
10295
  return V(function() {
10294
10296
  if (sn(t, "selectedItem")) {
10295
10297
  if (!c) {
10296
- var p = t.itemToKey(t.selectedItem) !== t.itemToKey(r.current);
10297
- p && u({
10298
+ var d = t.itemToKey(t.selectedItem) !== t.itemToKey(r.current);
10299
+ d && u({
10298
10300
  type: Ss,
10299
10301
  inputValue: t.itemToString(t.selectedItem)
10300
10302
  });
@@ -10414,18 +10416,18 @@ vd.stateChangeTypes = bd;
10414
10416
  function vd(e) {
10415
10417
  e === void 0 && (e = {}), Xx(e, vd);
10416
10418
  var t = j({}, Zx, e), o = t.items, i = t.scrollIntoView, r = t.environment, n = t.getA11yStatusMessage, l = Qx(Jx, t, Yx, Xp), u = l[0], c = l[1],
10417
- p = u.isOpen, d = u.highlightedIndex, m = u.selectedItem, g = u.inputValue, b = q(null), f = q({}), y = q(null), S = q(null), E = hn(), h = $p(
10418
- t), v = q(), I = mn({
10419
+ d = u.isOpen, p = u.highlightedIndex, m = u.selectedItem, h = u.inputValue, b = q(null), f = q({}), y = q(null), I = q(null), E = hn(), g = $p(
10420
+ t), v = q(), S = mn({
10419
10421
  state: u,
10420
10422
  props: t
10421
10423
  }), w = A(function(F) {
10422
- return f.current[h.getItemId(F)];
10423
- }, [h]);
10424
- Xi(n, u, [p, d, m, g], r);
10424
+ return f.current[g.getItemId(F)];
10425
+ }, [g]);
10426
+ Xi(n, u, [d, p, m, h], r);
10425
10427
  var O = Qp({
10426
10428
  menuElement: b.current,
10427
- highlightedIndex: d,
10428
- isOpen: p,
10429
+ highlightedIndex: p,
10430
+ isOpen: d,
10429
10431
  itemRefs: f,
10430
10432
  scrollIntoView: i,
10431
10433
  getItemNodeFromIndex: w
@@ -10440,20 +10442,20 @@ function vd(e) {
10440
10442
  E || (v.current = o.length);
10441
10443
  });
10442
10444
  var _ = Yp(r, A(/* @__PURE__ */ a(function() {
10443
- I.current.state.isOpen && c({
10445
+ S.current.state.isOpen && c({
10444
10446
  type: dn,
10445
10447
  selectItem: !1
10446
10448
  });
10447
- }, "handleBlur"), [c, I]), U(function() {
10448
- return [b, S, y];
10449
- }, [b.current, S.current, y.current])), k = Qi("getInputProps", "getMenuProps");
10449
+ }, "handleBlur"), [c, S]), U(function() {
10450
+ return [b, I, y];
10451
+ }, [b.current, I.current, y.current])), k = Qi("getInputProps", "getMenuProps");
10450
10452
  V(function() {
10451
- p || (f.current = {});
10452
- }, [p]), V(function() {
10453
+ d || (f.current = {});
10454
+ }, [d]), V(function() {
10453
10455
  var F;
10454
- !p || !(r != null && r.document) || !(y != null && (F = y.current) != null && F.focus) || r.document.activeElement !== y.current && y.current.
10456
+ !d || !(r != null && r.document) || !(y != null && (F = y.current) != null && F.focus) || r.document.activeElement !== y.current && y.current.
10455
10457
  focus();
10456
- }, [p, r]);
10458
+ }, [d, r]);
10457
10459
  var T = U(function() {
10458
10460
  return {
10459
10461
  ArrowDown: /* @__PURE__ */ a(function(R) {
@@ -10469,62 +10471,62 @@ function vd(e) {
10469
10471
  });
10470
10472
  }, "ArrowUp"),
10471
10473
  Home: /* @__PURE__ */ a(function(R) {
10472
- I.current.state.isOpen && (R.preventDefault(), c({
10474
+ S.current.state.isOpen && (R.preventDefault(), c({
10473
10475
  type: fs
10474
10476
  }));
10475
10477
  }, "Home"),
10476
10478
  End: /* @__PURE__ */ a(function(R) {
10477
- I.current.state.isOpen && (R.preventDefault(), c({
10479
+ S.current.state.isOpen && (R.preventDefault(), c({
10478
10480
  type: ms
10479
10481
  }));
10480
10482
  }, "End"),
10481
10483
  Escape: /* @__PURE__ */ a(function(R) {
10482
- var L = I.current.state;
10484
+ var L = S.current.state;
10483
10485
  (L.isOpen || L.inputValue || L.selectedItem || L.highlightedIndex > -1) && (R.preventDefault(), c({
10484
10486
  type: ds
10485
10487
  }));
10486
10488
  }, "Escape"),
10487
10489
  Enter: /* @__PURE__ */ a(function(R) {
10488
- var L = I.current.state;
10490
+ var L = S.current.state;
10489
10491
  !L.isOpen || R.which === 229 || (R.preventDefault(), c({
10490
10492
  type: ys
10491
10493
  }));
10492
10494
  }, "Enter"),
10493
10495
  PageUp: /* @__PURE__ */ a(function(R) {
10494
- I.current.state.isOpen && (R.preventDefault(), c({
10496
+ S.current.state.isOpen && (R.preventDefault(), c({
10495
10497
  type: hs
10496
10498
  }));
10497
10499
  }, "PageUp"),
10498
10500
  PageDown: /* @__PURE__ */ a(function(R) {
10499
- I.current.state.isOpen && (R.preventDefault(), c({
10501
+ S.current.state.isOpen && (R.preventDefault(), c({
10500
10502
  type: gs
10501
10503
  }));
10502
10504
  }, "PageDown")
10503
10505
  };
10504
- }, [c, I]), C = A(function(F) {
10506
+ }, [c, S]), C = A(function(F) {
10505
10507
  return j({
10506
- id: h.labelId,
10507
- htmlFor: h.inputId
10508
+ id: g.labelId,
10509
+ htmlFor: g.inputId
10508
10510
  }, F);
10509
- }, [h]), P = A(function(F, R) {
10511
+ }, [g]), P = A(function(F, R) {
10510
10512
  var L, $ = F === void 0 ? {} : F, J = $.onMouseLeave, ie = $.refKey, te = ie === void 0 ? "ref" : ie, de = $.ref, ae = ke($, eI), ce = R ===
10511
10513
  void 0 ? {} : R, ue = ce.suppressRefError, Ie = ue === void 0 ? !1 : ue;
10512
10514
  return k("getMenuProps", Ie, te, b), j((L = {}, L[te] = Je(de, function(ye) {
10513
10515
  b.current = ye;
10514
- }), L.id = h.menuId, L.role = "listbox", L["aria-labelledby"] = ae && ae["aria-label"] ? void 0 : "" + h.labelId, L.onMouseLeave = le(J,
10516
+ }), L.id = g.menuId, L.role = "listbox", L["aria-labelledby"] = ae && ae["aria-label"] ? void 0 : "" + g.labelId, L.onMouseLeave = le(J,
10515
10517
  function() {
10516
10518
  c({
10517
10519
  type: ud
10518
10520
  });
10519
10521
  }), L), ae);
10520
- }, [c, k, h]), D = A(function(F) {
10522
+ }, [c, k, g]), D = A(function(F) {
10521
10523
  var R, L, $ = F === void 0 ? {} : F, J = $.item, ie = $.index, te = $.refKey, de = te === void 0 ? "ref" : te, ae = $.ref, ce = $.onMouseMove,
10522
10524
  ue = $.onMouseDown, Ie = $.onClick;
10523
10525
  $.onPress;
10524
10526
  var ye = $.disabled, Oe = ke($, tI);
10525
10527
  ye !== void 0 && console.warn('Passing "disabled" as an argument to getItemProps is not supported anymore. Please use the isItemDisabled\
10526
10528
  prop from useCombobox.');
10527
- var fe = I.current, Se = fe.props, _e = fe.state, De = qi(J, ie, Se.items, "Pass either item or index to getItemProps!"), z = De[0], Pe = De[1],
10529
+ var fe = S.current, Se = fe.props, _e = fe.state, De = qi(J, ie, Se.items, "Pass either item or index to getItemProps!"), z = De[0], Pe = De[1],
10528
10530
  qe = Se.isItemDisabled(z, Pe), fo = "onClick", $o = Ie, ft = /* @__PURE__ */ a(function() {
10529
10531
  _.isTouchEnd || Pe === _e.highlightedIndex || (O.current = !1, c({
10530
10532
  type: cd,
@@ -10540,32 +10542,32 @@ function vd(e) {
10540
10542
  return Jd.preventDefault();
10541
10543
  }, "itemHandleMouseDown");
10542
10544
  return j((R = {}, R[de] = Je(ae, function(Ye) {
10543
- Ye && (f.current[h.getItemId(Pe)] = Ye);
10544
- }), R["aria-disabled"] = qe, R["aria-selected"] = Pe === _e.highlightedIndex, R.id = h.getItemId(Pe), R.role = "option", R), !qe && (L =
10545
+ Ye && (f.current[g.getItemId(Pe)] = Ye);
10546
+ }), R["aria-disabled"] = qe, R["aria-selected"] = Pe === _e.highlightedIndex, R.id = g.getItemId(Pe), R.role = "option", R), !qe && (L =
10545
10547
  {}, L[fo] = le($o, Et), L), {
10546
10548
  onMouseMove: le(ce, ft),
10547
10549
  onMouseDown: le(ue, mt)
10548
10550
  }, Oe);
10549
- }, [c, h, I, _, O]), M = A(function(F) {
10551
+ }, [c, g, S, _, O]), M = A(function(F) {
10550
10552
  var R, L = F === void 0 ? {} : F, $ = L.onClick;
10551
10553
  L.onPress;
10552
- var J = L.refKey, ie = J === void 0 ? "ref" : J, te = L.ref, de = ke(L, oI), ae = I.current.state, ce = /* @__PURE__ */ a(function() {
10554
+ var J = L.refKey, ie = J === void 0 ? "ref" : J, te = L.ref, de = ke(L, oI), ae = S.current.state, ce = /* @__PURE__ */ a(function() {
10553
10555
  c({
10554
10556
  type: pd
10555
10557
  });
10556
10558
  }, "toggleButtonHandleClick");
10557
10559
  return j((R = {}, R[ie] = Je(te, function(ue) {
10558
- S.current = ue;
10559
- }), R["aria-controls"] = h.menuId, R["aria-expanded"] = ae.isOpen, R.id = h.toggleButtonId, R.tabIndex = -1, R), !de.disabled && j({}, {
10560
+ I.current = ue;
10561
+ }), R["aria-controls"] = g.menuId, R["aria-expanded"] = ae.isOpen, R.id = g.toggleButtonId, R.tabIndex = -1, R), !de.disabled && j({}, {
10560
10562
  onClick: le($, ce)
10561
10563
  }), de);
10562
- }, [c, I, h]), N = A(function(F, R) {
10564
+ }, [c, S, g]), N = A(function(F, R) {
10563
10565
  var L, $ = F === void 0 ? {} : F, J = $.onKeyDown, ie = $.onChange, te = $.onInput, de = $.onBlur;
10564
10566
  $.onChangeText;
10565
10567
  var ae = $.onClick, ce = $.refKey, ue = ce === void 0 ? "ref" : ce, Ie = $.ref, ye = ke($, rI), Oe = R === void 0 ? {} : R, fe = Oe.suppressRefError,
10566
10568
  Se = fe === void 0 ? !1 : fe;
10567
10569
  k("getInputProps", Se, ue, y);
10568
- var _e = I.current.state, De = /* @__PURE__ */ a(function(mt) {
10570
+ var _e = S.current.state, De = /* @__PURE__ */ a(function(mt) {
10569
10571
  var Ye = po(mt);
10570
10572
  Ye && T[Ye] && T[Ye](mt);
10571
10573
  }, "inputHandleKeyDown"), z = /* @__PURE__ */ a(function(mt) {
@@ -10592,10 +10594,10 @@ function vd(e) {
10592
10594
  }
10593
10595
  return j((L = {}, L[ue] = Je(Ie, function(Et) {
10594
10596
  y.current = Et;
10595
- }), L["aria-activedescendant"] = _e.isOpen && _e.highlightedIndex > -1 ? h.getItemId(_e.highlightedIndex) : "", L["aria-autocomplete"] =
10596
- "list", L["aria-controls"] = h.menuId, L["aria-expanded"] = _e.isOpen, L["aria-labelledby"] = ye && ye["aria-label"] ? void 0 : h.labelId,
10597
- L.autoComplete = "off", L.id = h.inputId, L.role = "combobox", L.value = _e.inputValue, L), $o, ye);
10598
- }, [c, h, r, T, I, _, k]), Z = A(function() {
10597
+ }), L["aria-activedescendant"] = _e.isOpen && _e.highlightedIndex > -1 ? g.getItemId(_e.highlightedIndex) : "", L["aria-autocomplete"] =
10598
+ "list", L["aria-controls"] = g.menuId, L["aria-expanded"] = _e.isOpen, L["aria-labelledby"] = ye && ye["aria-label"] ? void 0 : g.labelId,
10599
+ L.autoComplete = "off", L.id = g.inputId, L.role = "combobox", L.value = _e.inputValue, L), $o, ye);
10600
+ }, [c, g, r, T, S, _, k]), Z = A(function() {
10599
10601
  c({
10600
10602
  type: dd
10601
10603
  });
@@ -10643,10 +10645,10 @@ function vd(e) {
10643
10645
  selectItem: G,
10644
10646
  reset: re,
10645
10647
  // state.
10646
- highlightedIndex: d,
10647
- isOpen: p,
10648
+ highlightedIndex: p,
10649
+ isOpen: d,
10648
10650
  selectedItem: m,
10649
- inputValue: g
10651
+ inputValue: h
10650
10652
  };
10651
10653
  }
10652
10654
  a(vd, "useCombobox");
@@ -10684,7 +10686,7 @@ function iI(e, t) {
10684
10686
  return e.selectedItems === t.selectedItems && e.activeIndex === t.activeIndex;
10685
10687
  }
10686
10688
  a(iI, "isStateEqual");
10687
- var xR = {
10689
+ var IR = {
10688
10690
  stateReducer: rn.stateReducer,
10689
10691
  itemToKey: rn.itemToKey,
10690
10692
  environment: rn.environment,
@@ -10744,11 +10746,11 @@ function uI(e, t) {
10744
10746
  case Es: {
10745
10747
  if (l < 0)
10746
10748
  break;
10747
- var p = l;
10748
- u.length === 1 ? p = -1 : l === u.length - 1 && (p = u.length - 2), c = j({
10749
+ var d = l;
10750
+ u.length === 1 ? d = -1 : l === u.length - 1 && (d = u.length - 2), c = j({
10749
10751
  selectedItems: [].concat(u.slice(0, l), u.slice(l + 1))
10750
10752
  }, {
10751
- activeIndex: p
10753
+ activeIndex: d
10752
10754
  });
10753
10755
  break;
10754
10756
  }
@@ -10773,21 +10775,21 @@ function uI(e, t) {
10773
10775
  };
10774
10776
  break;
10775
10777
  case Ds: {
10776
- var d = l, m = u.findIndex(function(f) {
10778
+ var p = l, m = u.findIndex(function(f) {
10777
10779
  return r.itemToKey(f) === r.itemToKey(n);
10778
10780
  });
10779
10781
  if (m < 0)
10780
10782
  break;
10781
- u.length === 1 ? d = -1 : m === u.length - 1 && (d = u.length - 2), c = {
10783
+ u.length === 1 ? p = -1 : m === u.length - 1 && (p = u.length - 2), c = {
10782
10784
  selectedItems: [].concat(u.slice(0, m), u.slice(m + 1)),
10783
- activeIndex: d
10785
+ activeIndex: p
10784
10786
  };
10785
10787
  break;
10786
10788
  }
10787
10789
  case Ms: {
10788
- var g = t.selectedItems;
10790
+ var h = t.selectedItems;
10789
10791
  c = {
10790
- selectedItems: g
10792
+ selectedItems: h
10791
10793
  };
10792
10794
  break;
10793
10795
  }
@@ -10816,19 +10818,19 @@ Id.stateChangeTypes = lI;
10816
10818
  function Id(e) {
10817
10819
  e === void 0 && (e = {}), aI(e, Id);
10818
10820
  var t = j({}, sI, e), o = t.getA11yStatusMessage, i = t.environment, r = t.keyNavigationNext, n = t.keyNavigationPrevious, l = Gp(uI, t, nI,
10819
- iI), u = l[0], c = l[1], p = u.activeIndex, d = u.selectedItems, m = hn(), g = q(null), b = q();
10821
+ iI), u = l[0], c = l[1], d = u.activeIndex, p = u.selectedItems, m = hn(), h = q(null), b = q();
10820
10822
  b.current = [];
10821
10823
  var f = mn({
10822
10824
  state: u,
10823
10825
  props: t
10824
10826
  });
10825
- Xi(o, u, [p, d], i), V(function() {
10826
- m || (p === -1 && g.current ? g.current.focus() : b.current[p] && b.current[p].focus());
10827
- }, [p]), Zi({
10827
+ Xi(o, u, [d, p], i), V(function() {
10828
+ m || (d === -1 && h.current ? h.current.focus() : b.current[d] && b.current[d].focus());
10829
+ }, [d]), Zi({
10828
10830
  props: t,
10829
10831
  state: u
10830
10832
  });
10831
- var y = Qi("getDropdownProps"), S = U(function() {
10833
+ var y = Qi("getDropdownProps"), I = U(function() {
10832
10834
  var T;
10833
10835
  return T = {}, T[n] = function() {
10834
10836
  c({
@@ -10858,7 +10860,7 @@ function Id(e) {
10858
10860
  type: Os
10859
10861
  });
10860
10862
  }, "Backspace"), T;
10861
- }, [c, n]), h = A(function(T) {
10863
+ }, [c, n]), g = A(function(T) {
10862
10864
  var C, P = T === void 0 ? {} : T, D = P.refKey, M = D === void 0 ? "ref" : D, N = P.ref, Z = P.onClick, W = P.onKeyDown, Q = P.selectedItem,
10863
10865
  B = P.index, G = ke(P, cI), H = f.current.state, re = qi(Q, B, H.selectedItems, "Pass either item or index to getSelectedItemProps!"), F = re[1],
10864
10866
  R = F > -1 && F === H.activeIndex, L = /* @__PURE__ */ a(function() {
@@ -10868,15 +10870,15 @@ function Id(e) {
10868
10870
  });
10869
10871
  }, "selectedItemHandleClick"), $ = /* @__PURE__ */ a(function(ie) {
10870
10872
  var te = po(ie);
10871
- te && S[te] && S[te](ie);
10873
+ te && I[te] && I[te](ie);
10872
10874
  }, "selectedItemHandleKeyDown");
10873
10875
  return j((C = {}, C[M] = Je(N, function(J) {
10874
10876
  J && b.current.push(J);
10875
10877
  }), C.tabIndex = R ? 0 : -1, C.onClick = le(Z, L), C.onKeyDown = le(W, $), C), G);
10876
- }, [c, f, S]), v = A(function(T, C) {
10878
+ }, [c, f, I]), v = A(function(T, C) {
10877
10879
  var P, D = T === void 0 ? {} : T, M = D.refKey, N = M === void 0 ? "ref" : M, Z = D.ref, W = D.onKeyDown, Q = D.onClick, B = D.preventKeyAction,
10878
10880
  G = B === void 0 ? !1 : B, H = ke(D, pI), re = C === void 0 ? {} : C, F = re.suppressRefError, R = F === void 0 ? !1 : F;
10879
- y("getDropdownProps", R, N, g);
10881
+ y("getDropdownProps", R, N, h);
10880
10882
  var L = /* @__PURE__ */ a(function(ie) {
10881
10883
  var te = po(ie);
10882
10884
  te && E[te] && E[te](ie);
@@ -10886,12 +10888,12 @@ function Id(e) {
10886
10888
  });
10887
10889
  }, "dropdownHandleClick");
10888
10890
  return j((P = {}, P[N] = Je(Z, function(J) {
10889
- J && (g.current = J);
10891
+ J && (h.current = J);
10890
10892
  }), P), !G && {
10891
10893
  onKeyDown: le(W, L),
10892
10894
  onClick: le(Q, $)
10893
10895
  }, H);
10894
- }, [c, E, y]), I = A(function(T) {
10896
+ }, [c, E, y]), S = A(function(T) {
10895
10897
  c({
10896
10898
  type: As,
10897
10899
  selectedItem: T
@@ -10917,15 +10919,15 @@ function Id(e) {
10917
10919
  });
10918
10920
  }, [c]);
10919
10921
  return {
10920
- getSelectedItemProps: h,
10922
+ getSelectedItemProps: g,
10921
10923
  getDropdownProps: v,
10922
- addSelectedItem: I,
10924
+ addSelectedItem: S,
10923
10925
  removeSelectedItem: w,
10924
10926
  setSelectedItems: O,
10925
10927
  setActiveIndex: _,
10926
10928
  reset: k,
10927
- selectedItems: d,
10928
- activeIndex: p
10929
+ selectedItems: p,
10930
+ activeIndex: d
10929
10931
  };
10930
10932
  }
10931
10933
  a(Id, "useMultipleSelection");
@@ -11053,7 +11055,7 @@ var { document: dI } = se, Bs = 50, fI = {
11053
11055
  searchBarContent: l,
11054
11056
  searchFieldContent: u
11055
11057
  }) {
11056
- let c = oe(), p = q(null), [d, m] = K("Find components"), [g, b] = K(!1), f = c ? Qe(c.getShortcutKeys().search) : "/", y = A(() => {
11058
+ let c = oe(), d = q(null), [p, m] = K("Find components"), [h, b] = K(!1), f = c ? Qe(c.getShortcutKeys().search) : "/", y = A(() => {
11057
11059
  let w = o.entries.reduce((O, [_, { index: k, allStatuses: T }]) => {
11058
11060
  let C = Br(k || {}, T ?? {});
11059
11061
  return k && O.push(
@@ -11067,7 +11069,7 @@ var { document: dI } = se, Bs = 50, fI = {
11067
11069
  ), O;
11068
11070
  }, []);
11069
11071
  return new wd.default(w, fI);
11070
- }, [o]), S = A(
11072
+ }, [o]), I = A(
11071
11073
  (w) => {
11072
11074
  let O = y();
11073
11075
  if (!w)
@@ -11075,24 +11077,24 @@ var { document: dI } = se, Bs = 50, fI = {
11075
11077
  let _ = [], k = /* @__PURE__ */ new Set(), T = O.search(w).filter(({ item: C }) => !(C.type === "component" || C.type === "docs" || C.
11076
11078
  type === "story") || // @ts-expect-error (non strict)
11077
11079
  k.has(C.parent) ? !1 : (k.add(C.id), !0));
11078
- return T.length && (_ = T.slice(0, g ? 1e3 : Bs), T.length > Bs && !g && _.push({
11080
+ return T.length && (_ = T.slice(0, h ? 1e3 : Bs), T.length > Bs && !h && _.push({
11079
11081
  showAll: /* @__PURE__ */ a(() => b(!0), "showAll"),
11080
11082
  totalCount: T.length,
11081
11083
  moreCount: T.length - Bs
11082
11084
  })), _;
11083
11085
  },
11084
- [g, y]
11086
+ [h, y]
11085
11087
  ), E = A(
11086
11088
  (w) => {
11087
11089
  if (Rs(w)) {
11088
11090
  let { id: O, refId: _ } = w.item;
11089
- c?.selectStory(O, void 0, { ref: _ !== at && _ }), p.current.blur(), b(!1);
11091
+ c?.selectStory(O, void 0, { ref: _ !== at && _ }), d.current.blur(), b(!1);
11090
11092
  return;
11091
11093
  }
11092
11094
  Ko(w) && w.showAll();
11093
11095
  },
11094
11096
  [c]
11095
- ), h = A((w, O) => {
11097
+ ), g = A((w, O) => {
11096
11098
  b(!1);
11097
11099
  }, []), v = A(
11098
11100
  (w, O) => {
@@ -11117,7 +11119,7 @@ var { document: dI } = se, Bs = 50, fI = {
11117
11119
  }
11118
11120
  },
11119
11121
  []
11120
- ), { isMobile: I } = ge();
11122
+ ), { isMobile: S } = ge();
11121
11123
  return (
11122
11124
  // @ts-expect-error (non strict)
11123
11125
  /* @__PURE__ */ s.createElement(
@@ -11128,7 +11130,7 @@ var { document: dI } = se, Bs = 50, fI = {
11128
11130
  itemToString: (w) => w?.item?.name || "",
11129
11131
  scrollIntoView: (w) => zt(w),
11130
11132
  onSelect: E,
11131
- onInputValueChange: h
11133
+ onInputValueChange: g
11132
11134
  },
11133
11135
  ({
11134
11136
  isOpen: w,
@@ -11143,7 +11145,7 @@ var { document: dI } = se, Bs = 50, fI = {
11143
11145
  getRootProps: N,
11144
11146
  highlightedIndex: Z
11145
11147
  }) => {
11146
- let W = k ? k.trim() : "", Q = W ? S(W) : [], B = !W && r();
11148
+ let W = k ? k.trim() : "", Q = W ? I(W) : [], B = !W && r();
11147
11149
  B && B.length && (Q = B.reduce((F, { storyId: R, refId: L }) => {
11148
11150
  let $ = o.hash[L];
11149
11151
  if ($ && $.index && $.index[R]) {
@@ -11154,16 +11156,16 @@ var { document: dI } = se, Bs = 50, fI = {
11154
11156
  }, []));
11155
11157
  let G = "storybook-explorer-searchfield", H = C({
11156
11158
  id: G,
11157
- ref: p,
11159
+ ref: d,
11158
11160
  required: !0,
11159
11161
  type: "search",
11160
- placeholder: d,
11162
+ placeholder: p,
11161
11163
  onFocus: /* @__PURE__ */ a(() => {
11162
11164
  O(), m("Type to find...");
11163
11165
  }, "onFocus"),
11164
11166
  onBlur: /* @__PURE__ */ a(() => m("Find components"), "onBlur"),
11165
11167
  onKeyDown: /* @__PURE__ */ a((F) => {
11166
- F.key === "Escape" && k.length === 0 && p.current.blur();
11168
+ F.key === "Escape" && k.length === 0 && d.current.blur();
11167
11169
  }, "onKeyDown")
11168
11170
  }), re = D({
11169
11171
  htmlFor: G
@@ -11177,14 +11179,14 @@ var { document: dI } = se, Bs = 50, fI = {
11177
11179
  },
11178
11180
  /* @__PURE__ */ s.createElement(yI, null, /* @__PURE__ */ s.createElement(So, null)),
11179
11181
  /* @__PURE__ */ s.createElement(bI, { ...H }),
11180
- !I && i && !w && /* @__PURE__ */ s.createElement(vI, null, f === "\u2318 K" ? /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.
11182
+ !S && i && !w && /* @__PURE__ */ s.createElement(vI, null, f === "\u2318 K" ? /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.
11181
11183
  createElement(xI, null, "\u2318"), "K") : f),
11182
11184
  /* @__PURE__ */ s.createElement(II, null, w && /* @__PURE__ */ s.createElement(ee, { onClick: () => T() }, /* @__PURE__ */ s.createElement(
11183
11185
  Ke, null)), u)
11184
11186
  ), l), /* @__PURE__ */ s.createElement(SI, { tabIndex: 0, id: "storybook-explorer-menu" }, t({
11185
11187
  query: W,
11186
11188
  results: Q,
11187
- isBrowsing: !w && dI.activeElement !== p.current,
11189
+ isBrowsing: !w && dI.activeElement !== d.current,
11188
11190
  closeMenu: _,
11189
11191
  getMenuProps: M,
11190
11192
  getItemProps: P,
@@ -11270,9 +11272,9 @@ var { document: Td } = se, wI = x.ol({
11270
11272
  if (!o)
11271
11273
  return t;
11272
11274
  let { value: i, indices: r } = o, { nodes: n } = r.reduce(
11273
- ({ cursor: l, nodes: u }, [c, p], d, { length: m }) => (u.push(/* @__PURE__ */ s.createElement("span", { key: `${d}-1` }, i.slice(l, c))),
11274
- u.push(/* @__PURE__ */ s.createElement(kI, { key: `${d}-2` }, i.slice(c, p + 1))), d === m - 1 && u.push(/* @__PURE__ */ s.createElement(
11275
- "span", { key: `${d}-3` }, i.slice(p + 1))), { cursor: p + 1, nodes: u }),
11275
+ ({ cursor: l, nodes: u }, [c, d], p, { length: m }) => (u.push(/* @__PURE__ */ s.createElement("span", { key: `${p}-1` }, i.slice(l, c))),
11276
+ u.push(/* @__PURE__ */ s.createElement(kI, { key: `${p}-2` }, i.slice(c, d + 1))), p === m - 1 && u.push(/* @__PURE__ */ s.createElement(
11277
+ "span", { key: `${p}-3` }, i.slice(d + 1))), { cursor: d + 1, nodes: u }),
11276
11278
  { cursor: 0, nodes: [] }
11277
11279
  );
11278
11280
  return /* @__PURE__ */ s.createElement("span", null, n);
@@ -11306,24 +11308,24 @@ var { document: Td } = se, wI = x.ol({
11306
11308
  }
11307
11309
  })), MI = s.memo(/* @__PURE__ */ a(function({ item: t, matches: o, onClick: i, ...r }) {
11308
11310
  let n = A(
11309
- (d) => {
11310
- d.preventDefault(), i?.(d);
11311
+ (p) => {
11312
+ p.preventDefault(), i?.(p);
11311
11313
  },
11312
11314
  [i]
11313
11315
  ), l = oe();
11314
11316
  V(() => {
11315
11317
  l && r.isHighlighted && t.type === "component" && l.emit(Ct, { ids: [t.children[0]] }, { options: { target: t.refId } });
11316
11318
  }, [r.isHighlighted, t]);
11317
- let u = o.find((d) => d.key === "name"), c = o.filter((d) => d.key === "path"), [p] = t.status ? Bo[t.status] : [];
11319
+ let u = o.find((p) => p.key === "name"), c = o.filter((p) => p.key === "path"), [d] = t.status ? Bo[t.status] : [];
11318
11320
  return /* @__PURE__ */ s.createElement(EI, { ...r, onClick: n }, /* @__PURE__ */ s.createElement(TI, null, t.type === "component" && /* @__PURE__ */ s.
11319
11321
  createElement(It, { viewBox: "0 0 14 14", width: "14", height: "14", type: "component" }, /* @__PURE__ */ s.createElement(Le, { type: "com\
11320
11322
  ponent" })), t.type === "story" && /* @__PURE__ */ s.createElement(It, { viewBox: "0 0 14 14", width: "14", height: "14", type: "story" }, /* @__PURE__ */ s.
11321
11323
  createElement(Le, { type: "story" })), !(t.type === "component" || t.type === "story") && /* @__PURE__ */ s.createElement(It, { viewBox: "\
11322
11324
  0 0 14 14", width: "14", height: "14", type: "document" }, /* @__PURE__ */ s.createElement(Le, { type: "document" }))), /* @__PURE__ */ s.createElement(
11323
11325
  CI, { className: "search-result-item--label" }, /* @__PURE__ */ s.createElement(AI, null, /* @__PURE__ */ s.createElement(Cd, { match: u },
11324
- t.name)), /* @__PURE__ */ s.createElement(DI, null, t.path.map((d, m) => /* @__PURE__ */ s.createElement("span", { key: m }, /* @__PURE__ */ s.
11325
- createElement(Cd, { match: c.find((g) => g.arrayIndex === m) }, d))))), t.status ? /* @__PURE__ */ s.createElement(Bc, { status: t.status },
11326
- p) : null);
11326
+ t.name)), /* @__PURE__ */ s.createElement(DI, null, t.path.map((p, m) => /* @__PURE__ */ s.createElement("span", { key: m }, /* @__PURE__ */ s.
11327
+ createElement(Cd, { match: c.find((h) => h.arrayIndex === m) }, p))))), t.status ? /* @__PURE__ */ s.createElement(Bc, { status: t.status },
11328
+ d) : null);
11327
11329
  }, "Result")), _d = s.memo(/* @__PURE__ */ a(function({
11328
11330
  query: t,
11329
11331
  results: o,
@@ -11333,9 +11335,9 @@ ponent" })), t.type === "story" && /* @__PURE__ */ s.createElement(It, { viewBox
11333
11335
  highlightedIndex: l,
11334
11336
  isLoading: u = !1,
11335
11337
  enableShortcuts: c = !0,
11336
- clearLastViewed: p
11338
+ clearLastViewed: d
11337
11339
  }) {
11338
- let d = oe();
11340
+ let p = oe();
11339
11341
  V(() => {
11340
11342
  let b = /* @__PURE__ */ a((f) => {
11341
11343
  if (!(!c || u || f.repeat) && St(!1, f) && Ue("Escape", f)) {
@@ -11347,42 +11349,42 @@ ponent" })), t.type === "story" && /* @__PURE__ */ s.createElement(It, { viewBox
11347
11349
  return Td.addEventListener("keydown", b), () => Td.removeEventListener("keydown", b);
11348
11350
  }, [i, c, u]);
11349
11351
  let m = A((b) => {
11350
- if (!d)
11352
+ if (!p)
11351
11353
  return;
11352
- let f = b.currentTarget, y = f.getAttribute("data-id"), S = f.getAttribute("data-refid"), E = d.resolveStory(y, S === "storybook_interna\
11353
- l" ? void 0 : S);
11354
- E?.type === "component" && d.emit(Ct, {
11354
+ let f = b.currentTarget, y = f.getAttribute("data-id"), I = f.getAttribute("data-refid"), E = p.resolveStory(y, I === "storybook_interna\
11355
+ l" ? void 0 : I);
11356
+ E?.type === "component" && p.emit(Ct, {
11355
11357
  // @ts-expect-error (TODO)
11356
11358
  ids: [E.isLeaf ? E.id : E.children[0]],
11357
- options: { target: S }
11359
+ options: { target: I }
11358
11360
  });
11359
- }, []), g = /* @__PURE__ */ a(() => {
11360
- p(), i();
11361
+ }, []), h = /* @__PURE__ */ a(() => {
11362
+ d(), i();
11361
11363
  }, "handleClearLastViewed");
11362
11364
  return /* @__PURE__ */ s.createElement(wI, { ...r(), key: "results-list" }, o.length > 0 && !t && /* @__PURE__ */ s.createElement(PI, { className: "\
11363
11365
  search-result-recentlyOpened" }, "Recently opened", /* @__PURE__ */ s.createElement(
11364
11366
  ee,
11365
11367
  {
11366
11368
  className: "search-result-recentlyOpened-clear",
11367
- onClick: g
11369
+ onClick: h
11368
11370
  },
11369
11371
  /* @__PURE__ */ s.createElement(qn, null)
11370
11372
  )), o.length === 0 && t && /* @__PURE__ */ s.createElement("li", null, /* @__PURE__ */ s.createElement(_I, null, /* @__PURE__ */ s.createElement(
11371
11373
  "strong", null, "No components found"), /* @__PURE__ */ s.createElement("br", null), /* @__PURE__ */ s.createElement("small", null, "Find \
11372
11374
  components by name or path."))), o.map((b, f) => {
11373
11375
  if (Ko(b)) {
11374
- let E = { ...o, ...n({ key: f, index: f, item: b }) }, { key: h, ...v } = E;
11375
- return /* @__PURE__ */ s.createElement(OI, { key: "search-result-expand" }, /* @__PURE__ */ s.createElement(he, { key: h, ...v, size: "\
11376
+ let E = { ...o, ...n({ key: f, index: f, item: b }) }, { key: g, ...v } = E;
11377
+ return /* @__PURE__ */ s.createElement(OI, { key: "search-result-expand" }, /* @__PURE__ */ s.createElement(he, { key: g, ...v, size: "\
11376
11378
  small" }, "Show ", b.moreCount, " more results"));
11377
11379
  }
11378
- let { item: y } = b, S = `${y.refId}::${y.id}`;
11380
+ let { item: y } = b, I = `${y.refId}::${y.id}`;
11379
11381
  return /* @__PURE__ */ s.createElement(
11380
11382
  MI,
11381
11383
  {
11382
11384
  ...b,
11383
- ...n({ key: S, index: f, item: b }),
11385
+ ...n({ key: I, index: f, item: b }),
11384
11386
  isHighlighted: l === f,
11385
- key: S,
11387
+ key: I,
11386
11388
  "data-id": b.item.id,
11387
11389
  "data-refid": b.item.refId,
11388
11390
  onMouseOver: m,
@@ -11513,36 +11515,36 @@ ow, 0 1px 2px 0 rgba(0, 0, 0, 0.05), 0px -5px 20px 10px ${r.background.app})`,
11513
11515
  errorsActive: l,
11514
11516
  setErrorsActive: u,
11515
11517
  warningCount: c,
11516
- warningsActive: p,
11517
- setWarningsActive: d
11518
+ warningsActive: d,
11519
+ setWarningsActive: p
11518
11520
  }) => {
11519
- let m = q(null), g = q(null), [b, f] = K(Hs), [y, S] = K(!0), [E, h] = K(!1), [v, I] = K(!1), w = q();
11521
+ let m = q(null), h = q(null), [b, f] = K(Hs), [y, I] = K(!0), [E, g] = K(!1), [v, S] = K(!1), w = q();
11520
11522
  V(() => {
11521
11523
  let C = Jt.onSettingsChanged(() => {
11522
- I(!0), clearTimeout(w.current), w.current = setTimeout(() => {
11523
- I(!1);
11524
+ S(!0), clearTimeout(w.current), w.current = setTimeout(() => {
11525
+ S(!1);
11524
11526
  }, 1e3);
11525
11527
  });
11526
11528
  return () => {
11527
11529
  C(), clearTimeout(w.current);
11528
11530
  };
11529
11531
  }, []), V(() => {
11530
- if (g.current) {
11531
- f(g.current?.getBoundingClientRect().height || Hs);
11532
+ if (h.current) {
11533
+ f(h.current?.getBoundingClientRect().height || Hs);
11532
11534
  let C = new ResizeObserver(() => {
11533
11535
  requestAnimationFrame(() => {
11534
- if (g.current && !y) {
11535
- let P = g.current?.getBoundingClientRect().height || Hs;
11536
+ if (h.current && !y) {
11537
+ let P = h.current?.getBoundingClientRect().height || Hs;
11536
11538
  f(P);
11537
11539
  }
11538
11540
  });
11539
11541
  });
11540
- return C.observe(g.current), () => C.disconnect();
11542
+ return C.observe(h.current), () => C.disconnect();
11541
11543
  }
11542
11544
  }, [y]);
11543
11545
  let O = A((C, P) => {
11544
- C?.stopPropagation(), h(!0), S((D) => P ?? !D), m.current && clearTimeout(m.current), m.current = setTimeout(() => {
11545
- h(!1);
11546
+ C?.stopPropagation(), g(!0), I((D) => P ?? !D), m.current && clearTimeout(m.current), m.current = setTimeout(() => {
11547
+ g(!1);
11546
11548
  }, 250);
11547
11549
  }, []), _ = Object.values(t).some(
11548
11550
  (C) => C === "test-provider-state:running"
@@ -11570,7 +11572,7 @@ ow, 0 1px 2px 0 rgba(0, 0, 0, 0.05), 0px -5px 20px 10px ${r.background.app})`,
11570
11572
  maxHeight: y ? 0 : b
11571
11573
  }
11572
11574
  },
11573
- /* @__PURE__ */ s.createElement(BI, { ref: g }, Object.values(e).map((C) => {
11575
+ /* @__PURE__ */ s.createElement(BI, { ref: h }, Object.values(e).map((C) => {
11574
11576
  let { render: P, id: D } = C;
11575
11577
  return P ? /* @__PURE__ */ s.createElement(KI, { key: D, "data-module-id": D }, /* @__PURE__ */ s.createElement(P, null)) : (_a.warn(
11576
11578
  `No render function found for test provider with id '${D}', skipping...`
@@ -11669,9 +11671,9 @@ ow, 0 1px 2px 0 rgba(0, 0, 0, 0.05), 0px -5px 20px 10px ${r.background.app})`,
11669
11671
  variant: "ghost",
11670
11672
  padding: c < 10 ? "medium" : "small",
11671
11673
  status: "warning",
11672
- active: p,
11674
+ active: d,
11673
11675
  onClick: (C) => {
11674
- C.stopPropagation(), d(!p);
11676
+ C.stopPropagation(), p(!d);
11675
11677
  },
11676
11678
  "aria-label": "Toggle warnings"
11677
11679
  },
@@ -11745,45 +11747,45 @@ e).some(({ value: t }) => t === "status-value:error"), "filterError"), QI = /* @
11745
11747
  registeredTestProviders: u,
11746
11748
  onRunAll: c
11747
11749
  }) => {
11748
- let p = q(null), d = q(null), [m, g] = K(!1), [b, f] = K(!1);
11750
+ let d = q(null), p = q(null), [m, h] = K(!1), [b, f] = K(!1);
11749
11751
  return V(() => {
11750
- if (p.current && d.current) {
11752
+ if (d.current && p.current) {
11751
11753
  let y = new ResizeObserver(() => {
11752
- p.current && d.current && (p.current.style.height = `${d.current.scrollHeight}px`);
11754
+ d.current && p.current && (d.current.style.height = `${p.current.scrollHeight}px`);
11753
11755
  });
11754
- return y.observe(d.current), () => y.disconnect();
11756
+ return y.observe(p.current), () => y.disconnect();
11755
11757
  }
11756
11758
  }, []), V(() => {
11757
11759
  let y = XI(i > 0 && m, o > 0 && b);
11758
11760
  e.experimental_setFilter("sidebar-bottom-filter", y);
11759
11761
  }, [e, i, o, m, b]), !i && !o && Object.values(u).length === 0 && t.length === 0 ? null : /* @__PURE__ */ s.createElement(Ee, null, /* @__PURE__ */ s.
11760
- createElement(ZI, { id: $I, ref: p }), /* @__PURE__ */ s.createElement(JI, { id: UI, ref: d }, /* @__PURE__ */ s.createElement(Ir, { notifications: t,
11762
+ createElement(ZI, { id: $I, ref: d }), /* @__PURE__ */ s.createElement(JI, { id: UI, ref: p }, /* @__PURE__ */ s.createElement(Ir, { notifications: t,
11761
11763
  clearNotification: e.clearNotification }), n && /* @__PURE__ */ s.createElement(
11762
11764
  Od,
11763
11765
  {
11764
11766
  registeredTestProviders: u,
11765
11767
  testProviderStates: l,
11766
11768
  onRunAll: /* @__PURE__ */ a(() => {
11767
- c(), f(!1), g(!1);
11769
+ c(), f(!1), h(!1);
11768
11770
  }, "onRunAll"),
11769
11771
  hasStatuses: r,
11770
11772
  clearStatuses: /* @__PURE__ */ a(() => {
11771
- Ot.unset(), Jt.clearAll(), f(!1), g(!1);
11773
+ Ot.unset(), Jt.clearAll(), f(!1), h(!1);
11772
11774
  }, "clearStatuses"),
11773
11775
  errorCount: o,
11774
11776
  errorsActive: b,
11775
11777
  setErrorsActive: f,
11776
11778
  warningCount: i,
11777
11779
  warningsActive: m,
11778
- setWarningsActive: g
11780
+ setWarningsActive: h
11779
11781
  }
11780
11782
  )));
11781
11783
  }, "SidebarBottomBase"), Pd = /* @__PURE__ */ a(({ isDevelopment: e }) => {
11782
11784
  let t = oe(), o = t.getElements(Ce.experimental_TEST_PROVIDER), { notifications: i } = Fe(), { hasStatuses: r, errorCount: n, warningCount: l } = Eo(
11783
11785
  (c) => Object.values(c).reduce(
11784
- (p, d) => (Object.values(d).forEach((m) => {
11785
- p.hasStatuses = !0, m.value === "status-value:error" && (p.errorCount += 1), m.value === "status-value:warning" && (p.warningCount += 1);
11786
- }), p),
11786
+ (d, p) => (Object.values(p).forEach((m) => {
11787
+ d.hasStatuses = !0, m.value === "status-value:error" && (d.errorCount += 1), m.value === "status-value:warning" && (d.warningCount += 1);
11788
+ }), d),
11787
11789
  { errorCount: 0, warningCount: 0, hasStatuses: !1 }
11788
11790
  )), u = ei();
11789
11791
  return /* @__PURE__ */ s.createElement(
@@ -11815,18 +11817,18 @@ var tS = /* @__PURE__ */ new Set(["play-fn"]), oS = x.div({
11815
11817
  }) => {
11816
11818
  let n = t.filter((c) => !tS.has(c)), l = e.getDocsUrl({ subpath: "writing-stories/tags#filtering-by-custom-tags" }), u = [
11817
11819
  t.map((c) => {
11818
- let p = o.includes(c), d = `tag-${c}`;
11820
+ let d = o.includes(c), p = `tag-${c}`;
11819
11821
  return {
11820
- id: d,
11822
+ id: p,
11821
11823
  title: c,
11822
11824
  right: /* @__PURE__ */ s.createElement(
11823
11825
  "input",
11824
11826
  {
11825
11827
  type: "checkbox",
11826
- id: d,
11827
- name: d,
11828
+ id: p,
11829
+ name: p,
11828
11830
  value: c,
11829
- checked: p,
11831
+ checked: d,
11830
11832
  onChange: () => {
11831
11833
  }
11832
11834
  }
@@ -11888,9 +11890,9 @@ var rS = "tags-filter", nS = /* @__PURE__ */ new Set([
11888
11890
  V(() => {
11889
11891
  e.experimental_setFilter(rS, (b) => r.length === 0 ? !0 : r.some((f) => b.tags?.includes(f)));
11890
11892
  }, [e, r]);
11891
- let p = Object.values(t.entries).reduce((b, f) => (f.tags?.forEach((y) => {
11893
+ let d = Object.values(t.entries).reduce((b, f) => (f.tags?.forEach((y) => {
11892
11894
  nS.has(y) || b.add(y);
11893
- }), b), /* @__PURE__ */ new Set()), d = A(
11895
+ }), b), /* @__PURE__ */ new Set()), p = A(
11894
11896
  (b) => {
11895
11897
  r.includes(b) ? n(r.filter((f) => f !== b)) : n([...r, b]);
11896
11898
  },
@@ -11901,10 +11903,10 @@ var rS = "tags-filter", nS = /* @__PURE__ */ new Set([
11901
11903
  },
11902
11904
  [l, u]
11903
11905
  );
11904
- if (p.size === 0 && !i)
11906
+ if (d.size === 0 && !i)
11905
11907
  return null;
11906
- let g = Array.from(p);
11907
- return g.sort(), /* @__PURE__ */ s.createElement(
11908
+ let h = Array.from(d);
11909
+ return h.sort(), /* @__PURE__ */ s.createElement(
11908
11910
  ve,
11909
11911
  {
11910
11912
  placement: "bottom",
@@ -11914,9 +11916,9 @@ var rS = "tags-filter", nS = /* @__PURE__ */ new Set([
11914
11916
  Ad,
11915
11917
  {
11916
11918
  api: e,
11917
- allTags: g,
11919
+ allTags: h,
11918
11920
  selectedTags: r,
11919
- toggleTag: d,
11921
+ toggleTag: p,
11920
11922
  isDevelopment: i
11921
11923
  }
11922
11924
  ),
@@ -12016,21 +12018,21 @@ var at = "storybook_internal", aS = x.nav(({ theme: e }) => ({
12016
12018
  allStatuses: l,
12017
12019
  previewInitialized: u,
12018
12020
  menu: c,
12019
- menuHighlighted: p = !1,
12020
- enableShortcuts: d = !0,
12021
+ menuHighlighted: d = !1,
12022
+ enableShortcuts: p = !0,
12021
12023
  isDevelopment: m = se.CONFIG_TYPE === "DEVELOPMENT",
12022
- refs: g = {},
12024
+ refs: h = {},
12023
12025
  onMenuClick: b,
12024
12026
  showCreateStoryButton: f = m && fS
12025
12027
  }) {
12026
- let [y, S] = K(!1), E = U(() => t && { storyId: t, refId: o }, [t, o]), h = dS(i, n, u, l, g), v = !i && !n, I = Nd(E), { isMobile: w } = ge(),
12028
+ let [y, I] = K(!1), E = U(() => t && { storyId: t, refId: o }, [t, o]), g = dS(i, n, u, l, h), v = !i && !n, S = Nd(E), { isMobile: w } = ge(),
12027
12029
  O = oe();
12028
12030
  return /* @__PURE__ */ s.createElement(aS, { className: "container sidebar-container" }, /* @__PURE__ */ s.createElement(nr, { vertical: !0,
12029
12031
  offset: 3, scrollbarSize: 6 }, /* @__PURE__ */ s.createElement(lS, { row: 1.6 }, /* @__PURE__ */ s.createElement(
12030
12032
  cp,
12031
12033
  {
12032
12034
  className: "sidebar-header",
12033
- menuHighlighted: p,
12035
+ menuHighlighted: d,
12034
12036
  menu: c,
12035
12037
  skipLinkHref: "#storybook-preview-wrapper",
12036
12038
  isLoading: v,
@@ -12039,8 +12041,8 @@ var at = "storybook_internal", aS = x.nav(({ theme: e }) => ({
12039
12041
  ), /* @__PURE__ */ s.createElement(
12040
12042
  Ed,
12041
12043
  {
12042
- dataset: h,
12043
- enableShortcuts: d,
12044
+ dataset: g,
12045
+ enableShortcuts: p,
12044
12046
  searchBarContent: f && /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.createElement(
12045
12047
  ve,
12046
12048
  {
@@ -12052,7 +12054,7 @@ var at = "storybook_internal", aS = x.nav(({ theme: e }) => ({
12052
12054
  cS,
12053
12055
  {
12054
12056
  onClick: () => {
12055
- S(!0);
12057
+ I(!0);
12056
12058
  },
12057
12059
  variant: "outline"
12058
12060
  },
@@ -12062,11 +12064,11 @@ var at = "storybook_internal", aS = x.nav(({ theme: e }) => ({
12062
12064
  cc,
12063
12065
  {
12064
12066
  open: y,
12065
- onOpenChange: S
12067
+ onOpenChange: I
12066
12068
  }
12067
12069
  )),
12068
12070
  searchFieldContent: r && /* @__PURE__ */ s.createElement(Dd, { api: O, indexJson: r, isDevelopment: m }),
12069
- ...I
12071
+ ...S
12070
12072
  },
12071
12073
  ({
12072
12074
  query: _,
@@ -12079,7 +12081,7 @@ var at = "storybook_internal", aS = x.nav(({ theme: e }) => ({
12079
12081
  }) => /* @__PURE__ */ s.createElement(pS, { condition: T }, /* @__PURE__ */ s.createElement(
12080
12082
  ip,
12081
12083
  {
12082
- dataset: h,
12084
+ dataset: g,
12083
12085
  selected: E,
12084
12086
  isLoading: v,
12085
12087
  isBrowsing: T
@@ -12093,9 +12095,9 @@ var at = "storybook_internal", aS = x.nav(({ theme: e }) => ({
12093
12095
  getMenuProps: P,
12094
12096
  getItemProps: D,
12095
12097
  highlightedIndex: M,
12096
- enableShortcuts: d,
12098
+ enableShortcuts: p,
12097
12099
  isLoading: v,
12098
- clearLastViewed: I.clearLastViewed
12100
+ clearLastViewed: S.clearLastViewed
12099
12101
  }
12100
12102
  ))
12101
12103
  )), w || v ? null : /* @__PURE__ */ s.createElement(Pd, { isDevelopment: m })));
@@ -12137,20 +12139,20 @@ var mS = {
12137
12139
  icon: /* @__PURE__ */ s.createElement(Fn, null)
12138
12140
  }),
12139
12141
  [t]
12140
- ), p = U(() => ({
12142
+ ), d = U(() => ({
12141
12143
  id: "documentation",
12142
12144
  title: "Documentation",
12143
12145
  href: t.getDocsUrl({ versioned: !0, renderer: !0 }),
12144
12146
  icon: /* @__PURE__ */ s.createElement(tt, null)
12145
- }), [t]), d = e.whatsNewData?.status === "SUCCESS" && !e.disableWhatsNewNotifications, m = t.isWhatsNewUnread(), g = U(
12147
+ }), [t]), p = e.whatsNewData?.status === "SUCCESS" && !e.disableWhatsNewNotifications, m = t.isWhatsNewUnread(), h = U(
12146
12148
  () => ({
12147
12149
  id: "whats-new",
12148
12150
  title: "What's new?",
12149
12151
  onClick: /* @__PURE__ */ a(() => t.changeSettingsTab("whats-new"), "onClick"),
12150
- right: d && m && /* @__PURE__ */ s.createElement(tr, { status: "positive" }, "Check it out"),
12152
+ right: p && m && /* @__PURE__ */ s.createElement(tr, { status: "positive" }, "Check it out"),
12151
12153
  icon: /* @__PURE__ */ s.createElement(Yn, null)
12152
12154
  }),
12153
- [t, d, m]
12155
+ [t, p, m]
12154
12156
  ), b = U(
12155
12157
  () => ({
12156
12158
  id: "shortcuts",
@@ -12179,7 +12181,7 @@ var mS = {
12179
12181
  icon: o ? /* @__PURE__ */ s.createElement(He, null) : null
12180
12182
  }),
12181
12183
  [t, l, u, o]
12182
- ), S = U(
12184
+ ), I = U(
12183
12185
  () => ({
12184
12186
  id: "A",
12185
12187
  title: "Show addons",
@@ -12197,7 +12199,7 @@ var mS = {
12197
12199
  right: l ? /* @__PURE__ */ s.createElement(Ve, { keys: u.panelPosition }) : null
12198
12200
  }),
12199
12201
  [t, l, u]
12200
- ), h = U(
12202
+ ), g = U(
12201
12203
  () => ({
12202
12204
  id: "F",
12203
12205
  title: "Go full screen",
@@ -12215,7 +12217,7 @@ var mS = {
12215
12217
  right: l ? /* @__PURE__ */ s.createElement(Ve, { keys: u.search }) : null
12216
12218
  }),
12217
12219
  [t, l, u]
12218
- ), I = U(
12220
+ ), S = U(
12219
12221
  () => ({
12220
12222
  id: "up",
12221
12223
  title: "Previous component",
@@ -12268,18 +12270,18 @@ var mS = {
12268
12270
  () => [
12269
12271
  [
12270
12272
  c,
12271
- ...e.whatsNewData?.status === "SUCCESS" ? [g] : [],
12272
- p,
12273
+ ...e.whatsNewData?.status === "SUCCESS" ? [h] : [],
12274
+ d,
12273
12275
  b
12274
12276
  ],
12275
12277
  [
12276
12278
  f,
12277
12279
  y,
12278
- S,
12280
+ I,
12279
12281
  E,
12280
- h,
12282
+ g,
12281
12283
  v,
12282
- I,
12284
+ S,
12283
12285
  w,
12284
12286
  O,
12285
12287
  _,
@@ -12290,16 +12292,16 @@ var mS = {
12290
12292
  [
12291
12293
  c,
12292
12294
  e,
12293
- g,
12294
- p,
12295
+ h,
12296
+ d,
12295
12297
  b,
12296
12298
  f,
12297
12299
  y,
12298
- S,
12300
+ I,
12299
12301
  E,
12300
- h,
12302
+ g,
12301
12303
  v,
12302
- I,
12304
+ S,
12303
12305
  w,
12304
12306
  O,
12305
12307
  _,
@@ -12315,16 +12317,16 @@ var yS = s.memo(/* @__PURE__ */ a(function({ onMenuClick: t }) {
12315
12317
  let {
12316
12318
  ui: { name: n, url: l, enableShortcuts: u },
12317
12319
  viewMode: c,
12318
- storyId: p,
12319
- refId: d,
12320
+ storyId: d,
12321
+ refId: p,
12320
12322
  layout: { showToolbar: m },
12321
12323
  // FIXME: This is the actual `index.json` index where the `index` below
12322
12324
  // is actually the stories hash. We should fix this up and make it consistent.
12323
- internal_index: g,
12325
+ internal_index: h,
12324
12326
  filteredIndex: b,
12325
12327
  indexError: f,
12326
12328
  previewInitialized: y,
12327
- refs: S
12329
+ refs: I
12328
12330
  } = i, E = Rd(
12329
12331
  i,
12330
12332
  r,
@@ -12333,20 +12335,20 @@ var yS = s.memo(/* @__PURE__ */ a(function({ onMenuClick: t }) {
12333
12335
  r.getIsPanelShown(),
12334
12336
  r.getIsNavShown(),
12335
12337
  u
12336
- ), h = i.whatsNewData?.status === "SUCCESS" && !i.disableWhatsNewNotifications;
12338
+ ), g = i.whatsNewData?.status === "SUCCESS" && !i.disableWhatsNewNotifications;
12337
12339
  return {
12338
12340
  title: n,
12339
12341
  url: l,
12340
- indexJson: g,
12342
+ indexJson: h,
12341
12343
  index: b,
12342
12344
  indexError: f,
12343
12345
  previewInitialized: y,
12344
- refs: S,
12345
- storyId: p,
12346
- refId: d,
12346
+ refs: I,
12347
+ storyId: d,
12348
+ refId: p,
12347
12349
  viewMode: c,
12348
12350
  menu: E,
12349
- menuHighlighted: h && r.isWhatsNewUnread(),
12351
+ menuHighlighted: g && r.isWhatsNewUnread(),
12350
12352
  enableShortcuts: u
12351
12353
  };
12352
12354
  }, "mapper") }, (i) => {