jaml-ui 6.0.1 → 7.0.0

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.
@@ -1,16 +1,16 @@
1
- import { jsx as a, jsxs as _, Fragment as Xe } from "react/jsx-runtime";
2
- import z, { useState as T, useRef as J, useEffect as W, useId as He, useCallback as Q, useLayoutEffect as Ae, useSyncExternalStore as Ze, useMemo as Pe, Children as Ve } from "react";
3
- import { resolveJamlAssetUrl as qe } from "../assets.js";
4
- import { JOKERS as Qe, JOKER_FACES as et, TAROTS_AND_PLANETS as tt, CONSUMABLE_FACES as nt, VOUCHERS as rt, BOSSES as ot, TAGS as at, BOOSTER_PACKS as it } from "../sprites.js";
5
- const $ = z.forwardRef(
1
+ import { jsx as a, jsxs as _, Fragment as Ve } from "react/jsx-runtime";
2
+ import z, { useState as L, useRef as $, useEffect as G, useId as qe, useCallback as H, useLayoutEffect as Pe, useMemo as te, useSyncExternalStore as Qe, Children as et } from "react";
3
+ import { resolveJamlAssetUrl as tt } from "../assets.js";
4
+ import { JOKERS as nt, JOKER_FACES as rt, TAROTS_AND_PLANETS as ot, CONSUMABLE_FACES as at, VOUCHERS as it, BOSSES as st, TAGS as lt, BOOSTER_PACKS as ct } from "../sprites.js";
5
+ const D = z.forwardRef(
6
6
  function({ as: t = "div", children: n, ...r }, o) {
7
7
  return /* @__PURE__ */ a(t, { ref: o, ...r, children: n });
8
8
  }
9
- ), Cn = z.forwardRef(
9
+ ), Mn = z.forwardRef(
10
10
  function({ children: t, ...n }, r) {
11
11
  return /* @__PURE__ */ a("canvas", { ref: r, ...n, children: t });
12
12
  }
13
- ), st = {
13
+ ), ut = {
14
14
  red: "j-section-header__tag--red",
15
15
  orange: "j-section-header__tag--orange",
16
16
  blue: "j-section-header__tag--blue",
@@ -18,7 +18,7 @@ const $ = z.forwardRef(
18
18
  purple: "j-section-header__tag--purple",
19
19
  gold: "j-section-header__tag--gold",
20
20
  grey: "j-section-header__tag--grey"
21
- }, lt = {
21
+ }, dt = {
22
22
  red: "j-section-header__rule--red",
23
23
  orange: "j-section-header__rule--orange",
24
24
  blue: "j-section-header__rule--blue",
@@ -27,7 +27,7 @@ const $ = z.forwardRef(
27
27
  gold: "j-section-header__rule--gold",
28
28
  grey: "j-section-header__rule--grey"
29
29
  };
30
- function ct({
30
+ function pt({
31
31
  label: e,
32
32
  tone: t = "blue",
33
33
  className: n,
@@ -35,11 +35,11 @@ function ct({
35
35
  }) {
36
36
  const o = ["j-section-header", n].filter(Boolean).join(" ");
37
37
  return /* @__PURE__ */ _("div", { className: o, ...r, children: [
38
- /* @__PURE__ */ a("span", { className: `j-section-header__tag ${st[t]}`, children: e }),
39
- /* @__PURE__ */ a("span", { className: `j-section-header__rule ${lt[t]}`, "aria-hidden": !0 })
38
+ /* @__PURE__ */ a("span", { className: `j-section-header__tag ${ut[t]}`, children: e }),
39
+ /* @__PURE__ */ a("span", { className: `j-section-header__rule ${dt[t]}`, "aria-hidden": !0 })
40
40
  ] });
41
41
  }
42
- function Ln({
42
+ function On({
43
43
  title: e,
44
44
  tone: t = "blue",
45
45
  body: n,
@@ -49,11 +49,11 @@ function Ln({
49
49
  }) {
50
50
  const s = ["j-panel", r].filter(Boolean).join(" "), u = n ?? !!e;
51
51
  return /* @__PURE__ */ _("div", { className: s, ...i, children: [
52
- e != null && e !== !1 ? /* @__PURE__ */ a(ct, { label: e, tone: t }) : null,
52
+ e != null && e !== !1 ? /* @__PURE__ */ a(pt, { label: e, tone: t }) : null,
53
53
  u ? /* @__PURE__ */ a("div", { className: "j-panel__body", children: o }) : o
54
54
  ] });
55
55
  }
56
- const ut = {
56
+ const ft = {
57
57
  micro: "j-text--micro",
58
58
  xs: "j-text--xs",
59
59
  sm: "j-text--sm",
@@ -61,7 +61,7 @@ const ut = {
61
61
  lg: "j-text--lg",
62
62
  xl: "j-text--xl",
63
63
  display: "j-text--display"
64
- }, dt = {
64
+ }, ht = {
65
65
  white: "j-text--white",
66
66
  grey: "j-text--grey",
67
67
  gold: "j-text--gold",
@@ -71,11 +71,11 @@ const ut = {
71
71
  orange: "j-text--orange",
72
72
  purple: "j-text--purple"
73
73
  };
74
- function K({ size: e = "md", tone: t = "white", className: n, children: r, ...o }) {
75
- const i = ["j-text", ut[e], dt[t], n].filter(Boolean).join(" ");
74
+ function U({ size: e = "md", tone: t = "white", className: n, children: r, ...o }) {
75
+ const i = ["j-text", ft[e], ht[t], n].filter(Boolean).join(" ");
76
76
  return /* @__PURE__ */ a("span", { className: i, ...o, children: r });
77
77
  }
78
- const pt = {
78
+ const mt = {
79
79
  "j-stack": {
80
80
  gap: {
81
81
  xs: "j-stack--gap-xs",
@@ -119,8 +119,8 @@ const pt = {
119
119
  }
120
120
  }
121
121
  };
122
- function Te(e, { gap: t = "md", align: n, justify: r }, o, i) {
123
- const s = pt[e];
122
+ function Re(e, { gap: t = "md", align: n, justify: r }, o, i) {
123
+ const s = mt[e];
124
124
  return [
125
125
  e,
126
126
  s.gap[t],
@@ -130,7 +130,7 @@ function Te(e, { gap: t = "md", align: n, justify: r }, o, i) {
130
130
  o
131
131
  ].filter(Boolean).join(" ");
132
132
  }
133
- function An({
133
+ function gt({
134
134
  gap: e,
135
135
  align: t,
136
136
  justify: n,
@@ -138,9 +138,9 @@ function An({
138
138
  children: o,
139
139
  ...i
140
140
  }) {
141
- return /* @__PURE__ */ a("div", { className: Te("j-stack", { gap: e, align: t, justify: n }, r), ...i, children: o });
141
+ return /* @__PURE__ */ a("div", { className: Re("j-stack", { gap: e, align: t, justify: n }, r), ...i, children: o });
142
142
  }
143
- function ft({
143
+ function Be({
144
144
  gap: e,
145
145
  align: t = "center",
146
146
  justify: n,
@@ -152,7 +152,7 @@ function ft({
152
152
  return /* @__PURE__ */ a(
153
153
  "div",
154
154
  {
155
- className: Te(
155
+ className: Re(
156
156
  "j-row",
157
157
  { gap: e, align: t, justify: n },
158
158
  o,
@@ -163,23 +163,23 @@ function ft({
163
163
  }
164
164
  );
165
165
  }
166
- var Re = {
166
+ var Me = {
167
167
  color: void 0,
168
168
  size: void 0,
169
169
  className: void 0,
170
170
  style: void 0,
171
171
  attr: void 0
172
- }, je = z.createContext && /* @__PURE__ */ z.createContext(Re), mt = ["attr", "size", "title"];
173
- function ht(e, t) {
172
+ }, _e = z.createContext && /* @__PURE__ */ z.createContext(Me), bt = ["attr", "size", "title"];
173
+ function vt(e, t) {
174
174
  if (e == null) return {};
175
- var n, r, o = gt(e, t);
175
+ var n, r, o = jt(e, t);
176
176
  if (Object.getOwnPropertySymbols) {
177
177
  var i = Object.getOwnPropertySymbols(e);
178
178
  for (r = 0; r < i.length; r++) n = i[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (o[n] = e[n]);
179
179
  }
180
180
  return o;
181
181
  }
182
- function gt(e, t) {
182
+ function jt(e, t) {
183
183
  if (e == null) return {};
184
184
  var n = {};
185
185
  for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -188,16 +188,16 @@ function gt(e, t) {
188
188
  }
189
189
  return n;
190
190
  }
191
- function se() {
192
- return se = Object.assign ? Object.assign.bind() : function(e) {
191
+ function le() {
192
+ return le = Object.assign ? Object.assign.bind() : function(e) {
193
193
  for (var t = 1; t < arguments.length; t++) {
194
194
  var n = arguments[t];
195
195
  for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
196
196
  }
197
197
  return e;
198
- }, se.apply(null, arguments);
198
+ }, le.apply(null, arguments);
199
199
  }
200
- function ve(e, t) {
200
+ function ye(e, t) {
201
201
  var n = Object.keys(e);
202
202
  if (Object.getOwnPropertySymbols) {
203
203
  var r = Object.getOwnPropertySymbols(e);
@@ -207,25 +207,25 @@ function ve(e, t) {
207
207
  }
208
208
  return n;
209
209
  }
210
- function le(e) {
210
+ function ce(e) {
211
211
  for (var t = 1; t < arguments.length; t++) {
212
212
  var n = arguments[t] != null ? arguments[t] : {};
213
- t % 2 ? ve(Object(n), !0).forEach(function(r) {
214
- bt(e, r, n[r]);
215
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : ve(Object(n)).forEach(function(r) {
213
+ t % 2 ? ye(Object(n), !0).forEach(function(r) {
214
+ _t(e, r, n[r]);
215
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : ye(Object(n)).forEach(function(r) {
216
216
  Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(n, r));
217
217
  });
218
218
  }
219
219
  return e;
220
220
  }
221
- function bt(e, t, n) {
222
- return (t = jt(t)) in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = n, e;
221
+ function _t(e, t, n) {
222
+ return (t = yt(t)) in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = n, e;
223
223
  }
224
- function jt(e) {
225
- var t = vt(e, "string");
224
+ function yt(e) {
225
+ var t = xt(e, "string");
226
226
  return typeof t == "symbol" ? t : t + "";
227
227
  }
228
- function vt(e, t) {
228
+ function xt(e, t) {
229
229
  if (typeof e != "object" || !e) return e;
230
230
  var n = e[Symbol.toPrimitive];
231
231
  if (n !== void 0) {
@@ -235,26 +235,26 @@ function vt(e, t) {
235
235
  }
236
236
  return (t === "string" ? String : Number)(e);
237
237
  }
238
- function Be(e) {
239
- return e && e.map((t, n) => /* @__PURE__ */ z.createElement(t.tag, le({
238
+ function Oe(e) {
239
+ return e && e.map((t, n) => /* @__PURE__ */ z.createElement(t.tag, ce({
240
240
  key: n
241
- }, t.attr), Be(t.child)));
241
+ }, t.attr), Oe(t.child)));
242
242
  }
243
243
  function I(e) {
244
- return (t) => /* @__PURE__ */ z.createElement(_t, se({
245
- attr: le({}, e.attr)
246
- }, t), Be(e.child));
244
+ return (t) => /* @__PURE__ */ z.createElement(St, le({
245
+ attr: ce({}, e.attr)
246
+ }, t), Oe(e.child));
247
247
  }
248
- function _t(e) {
248
+ function St(e) {
249
249
  var t = (n) => {
250
- var r = e.attr, o = e.size, i = e.title, s = ht(e, mt), u = o || n.size || "1em", p;
251
- return n.className && (p = n.className), e.className && (p = (p ? p + " " : "") + e.className), /* @__PURE__ */ z.createElement("svg", se({
250
+ var r = e.attr, o = e.size, i = e.title, s = vt(e, bt), u = o || n.size || "1em", f;
251
+ return n.className && (f = n.className), e.className && (f = (f ? f + " " : "") + e.className), /* @__PURE__ */ z.createElement("svg", le({
252
252
  stroke: "currentColor",
253
253
  fill: "currentColor",
254
254
  strokeWidth: "0"
255
255
  }, n.attr, r, s, {
256
- className: p,
257
- style: le(le({
256
+ className: f,
257
+ style: ce(ce({
258
258
  color: e.color || n.color
259
259
  }, n.style), e.style),
260
260
  height: u,
@@ -262,56 +262,56 @@ function _t(e) {
262
262
  xmlns: "http://www.w3.org/2000/svg"
263
263
  }), i && /* @__PURE__ */ z.createElement("title", null, i), e.children);
264
264
  };
265
- return je !== void 0 ? /* @__PURE__ */ z.createElement(je.Consumer, null, (n) => t(n)) : t(Re);
265
+ return _e !== void 0 ? /* @__PURE__ */ z.createElement(_e.Consumer, null, (n) => t(n)) : t(Me);
266
266
  }
267
- function Me(e) {
267
+ function De(e) {
268
268
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "line", attr: { x1: "18", y1: "6", x2: "6", y2: "18" }, child: [] }, { tag: "line", attr: { x1: "6", y1: "6", x2: "18", y2: "18" }, child: [] }] })(e);
269
269
  }
270
- function Pn(e) {
270
+ function Dn(e) {
271
271
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polygon", attr: { points: "12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2" }, child: [] }] })(e);
272
272
  }
273
- function Tn(e) {
273
+ function In(e) {
274
274
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "circle", attr: { cx: "11", cy: "11", r: "8" }, child: [] }, { tag: "line", attr: { x1: "21", y1: "21", x2: "16.65", y2: "16.65" }, child: [] }] })(e);
275
275
  }
276
- function yt(e) {
276
+ function kt(e) {
277
277
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "1 4 1 10 7 10" }, child: [] }, { tag: "path", attr: { d: "M3.51 15a9 9 0 1 0 2.13-9.36L1 10" }, child: [] }] })(e);
278
278
  }
279
- function Rn(e) {
279
+ function Jn(e) {
280
280
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polygon", attr: { points: "5 3 19 12 5 21 5 3" }, child: [] }] })(e);
281
281
  }
282
- function xt(e) {
282
+ function wt(e) {
283
283
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "5 9 2 12 5 15" }, child: [] }, { tag: "polyline", attr: { points: "9 5 12 2 15 5" }, child: [] }, { tag: "polyline", attr: { points: "15 19 12 22 9 19" }, child: [] }, { tag: "polyline", attr: { points: "19 9 22 12 19 15" }, child: [] }, { tag: "line", attr: { x1: "2", y1: "12", x2: "22", y2: "12" }, child: [] }, { tag: "line", attr: { x1: "12", y1: "2", x2: "12", y2: "22" }, child: [] }] })(e);
284
284
  }
285
- function kt(e) {
285
+ function Et(e) {
286
286
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "4 14 10 14 10 20" }, child: [] }, { tag: "polyline", attr: { points: "20 10 14 10 14 4" }, child: [] }, { tag: "line", attr: { x1: "14", y1: "10", x2: "21", y2: "3" }, child: [] }, { tag: "line", attr: { x1: "3", y1: "21", x2: "10", y2: "14" }, child: [] }] })(e);
287
287
  }
288
- function St(e) {
288
+ function Nt(e) {
289
289
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "15 3 21 3 21 9" }, child: [] }, { tag: "polyline", attr: { points: "9 21 3 21 3 15" }, child: [] }, { tag: "line", attr: { x1: "21", y1: "3", x2: "14", y2: "10" }, child: [] }, { tag: "line", attr: { x1: "3", y1: "21", x2: "10", y2: "14" }, child: [] }] })(e);
290
290
  }
291
- function Bn(e) {
291
+ function $n(e) {
292
292
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" }, child: [] }, { tag: "polyline", attr: { points: "7 10 12 15 17 10" }, child: [] }, { tag: "line", attr: { x1: "12", y1: "15", x2: "12", y2: "3" }, child: [] }] })(e);
293
293
  }
294
- function wt(e) {
294
+ function At(e) {
295
295
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "rect", attr: { x: "9", y: "9", width: "13", height: "13", rx: "2", ry: "2" }, child: [] }, { tag: "path", attr: { d: "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1" }, child: [] }] })(e);
296
296
  }
297
- function Mn(e) {
297
+ function Fn(e) {
298
298
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "16 18 22 12 16 6" }, child: [] }, { tag: "polyline", attr: { points: "8 6 2 12 8 18" }, child: [] }] })(e);
299
299
  }
300
- function Nt(e) {
300
+ function Ct(e) {
301
301
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "9 18 15 12 9 6" }, child: [] }] })(e);
302
302
  }
303
- function Et(e) {
303
+ function Tt(e) {
304
304
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "15 18 9 12 15 6" }, child: [] }] })(e);
305
305
  }
306
- function Oe(e) {
306
+ function Ie(e) {
307
307
  return I({ attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "20 6 9 17 4 12" }, child: [] }] })(e);
308
308
  }
309
- const Ct = {
309
+ const Lt = {
310
310
  xs: "j-btn--xs",
311
311
  sm: "j-btn--sm",
312
312
  md: "j-btn--md",
313
313
  lg: "j-btn--lg"
314
- }, Lt = {
314
+ }, Pt = {
315
315
  orange: "j-btn--orange",
316
316
  red: "j-btn--red",
317
317
  blue: "j-btn--blue",
@@ -319,7 +319,7 @@ const Ct = {
319
319
  purple: "j-btn--purple",
320
320
  grey: "j-btn--grey"
321
321
  };
322
- function Y({
322
+ function W({
323
323
  size: e = "md",
324
324
  tone: t = "orange",
325
325
  fullWidth: n = !1,
@@ -329,17 +329,17 @@ function Y({
329
329
  disabled: s,
330
330
  ...u
331
331
  }) {
332
- const p = [
332
+ const f = [
333
333
  "j-btn",
334
- Ct[e],
335
- Lt[t],
334
+ Lt[e],
335
+ Pt[t],
336
336
  n ? "j-btn--full" : "",
337
337
  s ? "j-btn--disabled" : "",
338
338
  o
339
339
  ].filter(Boolean).join(" ");
340
- return /* @__PURE__ */ a("button", { className: p, disabled: s, ...u, children: /* @__PURE__ */ a("span", { className: "j-btn__face", children: r ?? i }) });
340
+ return /* @__PURE__ */ a("button", { className: f, disabled: s, ...u, children: /* @__PURE__ */ a("span", { className: "j-btn__face", children: r ?? i }) });
341
341
  }
342
- function On({
342
+ function zn({
343
343
  value: e,
344
344
  placeholder: t = "--------",
345
345
  disabled: n = !1,
@@ -349,46 +349,46 @@ function On({
349
349
  className: s = "",
350
350
  style: u
351
351
  }) {
352
- const [p, j] = T(!1), l = J(null), c = e.trim(), f = !n && c.length > 0;
353
- W(
352
+ const [f, v] = L(!1), c = $(null), l = e.trim(), d = !n && l.length > 0;
353
+ G(
354
354
  () => () => {
355
- l.current && clearTimeout(l.current);
355
+ c.current && clearTimeout(c.current);
356
356
  },
357
357
  []
358
358
  );
359
- const y = async () => {
360
- var k;
361
- if (f) {
359
+ const x = async () => {
360
+ var S;
361
+ if (d) {
362
362
  try {
363
- typeof navigator < "u" && ((k = navigator.clipboard) != null && k.writeText) && await navigator.clipboard.writeText(c);
363
+ typeof navigator < "u" && ((S = navigator.clipboard) != null && S.writeText) && await navigator.clipboard.writeText(l);
364
364
  } catch {
365
365
  }
366
- j(!0), i == null || i(c), l.current && clearTimeout(l.current), l.current = setTimeout(() => j(!1), o);
366
+ v(!0), i == null || i(l), c.current && clearTimeout(c.current), c.current = setTimeout(() => v(!1), o);
367
367
  }
368
- }, x = ["j-seed-copy", p ? "j-seed-copy--copied" : "", s].filter(Boolean).join(" ");
368
+ }, y = ["j-seed-copy", f ? "j-seed-copy--copied" : "", s].filter(Boolean).join(" ");
369
369
  return /* @__PURE__ */ _(
370
- Y,
370
+ W,
371
371
  {
372
- className: x,
372
+ className: y,
373
373
  style: u,
374
- onClick: y,
375
- disabled: !f,
374
+ onClick: x,
375
+ disabled: !d,
376
376
  fullWidth: !0,
377
- "aria-label": f ? `Copy seed ${c}` : "Seed unavailable",
377
+ "aria-label": d ? `Copy seed ${l}` : "Seed unavailable",
378
378
  children: [
379
- /* @__PURE__ */ a("span", { className: "j-seed-copy__icon", "aria-hidden": !0, children: p ? /* @__PURE__ */ a(Oe, { size: 18 }) : /* @__PURE__ */ a(wt, { size: 18 }) }),
380
- /* @__PURE__ */ a("span", { className: "j-seed-copy__text", children: p ? r : c || t })
379
+ /* @__PURE__ */ a("span", { className: "j-seed-copy__icon", "aria-hidden": !0, children: f ? /* @__PURE__ */ a(Ie, { size: 18 }) : /* @__PURE__ */ a(At, { size: 18 }) }),
380
+ /* @__PURE__ */ a("span", { className: "j-seed-copy__text", children: f ? r : l || t })
381
381
  ]
382
382
  }
383
383
  );
384
384
  }
385
- function In({ className: e, children: t, ...n }) {
385
+ function Un({ className: e, children: t, ...n }) {
386
386
  const r = ["j-inner-panel", e].filter(Boolean).join(" ");
387
387
  return /* @__PURE__ */ a("div", { className: r, ...n, children: t });
388
388
  }
389
- function Dn({ open: e, onClose: t, title: n, className: r, children: o }) {
390
- const i = He();
391
- return W(() => {
389
+ function Wn({ open: e, onClose: t, title: n, className: r, children: o }) {
390
+ const i = qe();
391
+ return G(() => {
392
392
  if (!e || !t) return;
393
393
  const s = (u) => {
394
394
  u.key === "Escape" && t();
@@ -409,7 +409,7 @@ function Dn({ open: e, onClose: t, title: n, className: r, children: o }) {
409
409
  }
410
410
  ) }) : null;
411
411
  }
412
- function Jn({
412
+ function Kn({
413
413
  value: e,
414
414
  label: t,
415
415
  onPrev: n,
@@ -419,10 +419,10 @@ function Jn({
419
419
  className: s = ""
420
420
  }) {
421
421
  return /* @__PURE__ */ _("div", { className: `j-spinner-wrap ${s}`, children: [
422
- t && /* @__PURE__ */ a("div", { className: "j-spinner__label", children: /* @__PURE__ */ a(K, { size: "sm", tone: "white", children: t }) }),
422
+ t && /* @__PURE__ */ a("div", { className: "j-spinner__label", children: /* @__PURE__ */ a(U, { size: "sm", tone: "white", children: t }) }),
423
423
  /* @__PURE__ */ _("div", { className: "j-spinner", children: [
424
424
  /* @__PURE__ */ a(
425
- Y,
425
+ W,
426
426
  {
427
427
  tone: "red",
428
428
  size: "sm",
@@ -432,9 +432,9 @@ function Jn({
432
432
  children: "<"
433
433
  }
434
434
  ),
435
- /* @__PURE__ */ a("div", { className: "j-spinner__value", children: /* @__PURE__ */ a(K, { size: "sm", tone: "white", children: e }) }),
435
+ /* @__PURE__ */ a("div", { className: "j-spinner__value", children: /* @__PURE__ */ a(U, { size: "sm", tone: "white", children: e }) }),
436
436
  /* @__PURE__ */ a(
437
- Y,
437
+ W,
438
438
  {
439
439
  tone: "red",
440
440
  size: "sm",
@@ -447,7 +447,7 @@ function Jn({
447
447
  ] })
448
448
  ] });
449
449
  }
450
- const At = {
450
+ const Rt = {
451
451
  RED: "#fe5148",
452
452
  BLUE: "#0093ff",
453
453
  GREEN: "#429f79",
@@ -476,24 +476,24 @@ const At = {
476
476
  /** Same decision as GOLD — kept so CodeMirror / old callers don't grow a second gold. */
477
477
  GOLD_TEXT: "#e4b643"
478
478
  };
479
- function Fn(e, t) {
479
+ function Gn(e, t) {
480
480
  const n = e.replace("#", ""), r = parseInt(n.slice(0, 2), 16), o = parseInt(n.slice(2, 4), 16), i = parseInt(n.slice(4, 6), 16);
481
481
  return `rgba(${r}, ${o}, ${i}, ${t})`;
482
482
  }
483
- const $n = {
483
+ const Yn = {
484
484
  JUICE_UP_SCALE: 1.05,
485
485
  JUICE_EASING: "cubic-bezier(0.16, 1, 0.3, 1)",
486
486
  SWAY_AMOUNT: 1.5,
487
487
  SWAY_DURATION: 4e3
488
- }, Z = At, Pt = {
488
+ }, V = Rt, Bt = {
489
489
  xs: 22,
490
490
  sm: 26,
491
491
  md: 30
492
- }, Tt = {
493
- default: { rest: Z.DARKEST, hover: Z.DARK_GREY, border: Z.PANEL_EDGE },
494
- destructive: { rest: Z.RED, hover: Z.ORANGE, border: Z.BLACK }
492
+ }, Mt = {
493
+ default: { rest: V.DARKEST, hover: V.DARK_GREY, border: V.PANEL_EDGE },
494
+ destructive: { rest: V.RED, hover: V.ORANGE, border: V.BLACK }
495
495
  };
496
- function te({
496
+ function ne({
497
497
  onClick: e,
498
498
  onMouseDown: t,
499
499
  onTouchStart: n,
@@ -502,29 +502,29 @@ function te({
502
502
  disabled: i = !1,
503
503
  size: s = "md",
504
504
  tone: u = "default",
505
- children: p
505
+ children: f
506
506
  }) {
507
- const [j, l] = T(!1), c = Pt[s], f = Tt[u], y = u === "destructive" ? 2 : 1, x = u === "destructive" ? `inset 0 1px 0 rgba(255,255,255,.2), 0 2px 0 ${Z.BLACK}` : void 0;
507
+ const [v, c] = L(!1), l = Bt[s], d = Mt[u], x = u === "destructive" ? 2 : 1, y = u === "destructive" ? `inset 0 1px 0 rgba(255,255,255,.2), 0 2px 0 ${V.BLACK}` : void 0;
508
508
  return /* @__PURE__ */ a(
509
509
  "button",
510
510
  {
511
511
  "aria-label": o ?? r,
512
512
  disabled: i,
513
- onClick: (k) => !i && (e == null ? void 0 : e(k)),
513
+ onClick: (S) => !i && (e == null ? void 0 : e(S)),
514
514
  onMouseDown: t,
515
515
  onTouchStart: n,
516
- onMouseEnter: () => l(!0),
517
- onMouseLeave: () => l(!1),
516
+ onMouseEnter: () => c(!0),
517
+ onMouseLeave: () => c(!1),
518
518
  style: {
519
- width: c,
520
- height: c,
519
+ width: l,
520
+ height: l,
521
521
  display: "inline-grid",
522
522
  placeItems: "center",
523
- background: j && !i ? f.hover : f.rest,
524
- color: Z.WHITE,
525
- border: `${y}px solid ${f.border}`,
523
+ background: v && !i ? d.hover : d.rest,
524
+ color: V.WHITE,
525
+ border: `${x}px solid ${d.border}`,
526
526
  borderRadius: 4,
527
- boxShadow: x,
527
+ boxShadow: y,
528
528
  cursor: i ? "not-allowed" : "pointer",
529
529
  opacity: i ? 0.55 : 1,
530
530
  padding: 0,
@@ -534,54 +534,54 @@ function te({
534
534
  },
535
535
  title: r,
536
536
  type: "button",
537
- children: p
537
+ children: f
538
538
  }
539
539
  );
540
540
  }
541
- const Rt = 280, Bt = 260;
542
- function zn({ children: e, className: t, onNearEnd: n, snap: r = !1 }) {
543
- const o = J(null), i = J(null), [s, u] = T(!1), p = Q(() => {
544
- const c = o.current;
545
- !c || !n || c.scrollWidth - (c.scrollLeft + c.clientWidth) <= Rt && n();
541
+ const Ot = 280, Dt = 260;
542
+ function Hn({ children: e, className: t, onNearEnd: n, snap: r = !1 }) {
543
+ const o = $(null), i = $(null), [s, u] = L(!1), f = H(() => {
544
+ const l = o.current;
545
+ !l || !n || l.scrollWidth - (l.scrollLeft + l.clientWidth) <= Ot && n();
546
546
  }, [n]);
547
- W(() => {
548
- const c = o.current;
549
- if (!c) return;
550
- const f = (y) => {
551
- if (c.scrollWidth <= c.clientWidth) return;
552
- const x = Math.abs(y.deltaY) > Math.abs(y.deltaX) ? y.deltaY : y.deltaX;
553
- x !== 0 && (c.scrollLeft += x, y.preventDefault(), p());
547
+ G(() => {
548
+ const l = o.current;
549
+ if (!l) return;
550
+ const d = (x) => {
551
+ if (l.scrollWidth <= l.clientWidth) return;
552
+ const y = Math.abs(x.deltaY) > Math.abs(x.deltaX) ? x.deltaY : x.deltaX;
553
+ y !== 0 && (l.scrollLeft += y, x.preventDefault(), f());
554
554
  };
555
- return c.addEventListener("wheel", f, { passive: !1 }), () => c.removeEventListener("wheel", f);
556
- }, [p]);
557
- const j = (c) => {
558
- var f;
559
- (f = o.current) == null || f.scrollBy({ left: c * Bt, behavior: "smooth" }), c > 0 && p();
560
- }, l = [
555
+ return l.addEventListener("wheel", d, { passive: !1 }), () => l.removeEventListener("wheel", d);
556
+ }, [f]);
557
+ const v = (l) => {
558
+ var d;
559
+ (d = o.current) == null || d.scrollBy({ left: l * Dt, behavior: "smooth" }), l > 0 && f();
560
+ }, c = [
561
561
  "j-shop-belt",
562
562
  "j-shop-belt--grab",
563
563
  r ? "j-shop-belt--snap" : "",
564
564
  s ? "j-shop-belt--grabbing" : "",
565
565
  t
566
566
  ].filter(Boolean).join(" ");
567
- return /* @__PURE__ */ _($, { className: "j-shop-belt-wrap", children: [
568
- /* @__PURE__ */ a(te, { size: "sm", "aria-label": "Scroll left", onClick: () => j(-1), children: /* @__PURE__ */ a(Et, {}) }),
567
+ return /* @__PURE__ */ _(D, { className: "j-shop-belt-wrap", children: [
568
+ /* @__PURE__ */ a(ne, { size: "sm", "aria-label": "Scroll left", onClick: () => v(-1), children: /* @__PURE__ */ a(Tt, {}) }),
569
569
  /* @__PURE__ */ a(
570
- $,
570
+ D,
571
571
  {
572
572
  ref: o,
573
- className: l,
574
- onScroll: p,
575
- onPointerDown: (c) => {
576
- c.button === 0 && (i.current = { id: c.pointerId, x: c.clientX, left: c.currentTarget.scrollLeft }, c.currentTarget.setPointerCapture(c.pointerId), u(!0));
573
+ className: c,
574
+ onScroll: f,
575
+ onPointerDown: (l) => {
576
+ l.button === 0 && (i.current = { id: l.pointerId, x: l.clientX, left: l.currentTarget.scrollLeft }, l.currentTarget.setPointerCapture(l.pointerId), u(!0));
577
577
  },
578
- onPointerMove: (c) => {
579
- const f = i.current;
580
- !f || f.id !== c.pointerId || (c.currentTarget.scrollLeft = f.left - (c.clientX - f.x));
578
+ onPointerMove: (l) => {
579
+ const d = i.current;
580
+ !d || d.id !== l.pointerId || (l.currentTarget.scrollLeft = d.left - (l.clientX - d.x));
581
581
  },
582
- onPointerUp: (c) => {
583
- var f;
584
- ((f = i.current) == null ? void 0 : f.id) === c.pointerId && (c.currentTarget.hasPointerCapture(c.pointerId) && c.currentTarget.releasePointerCapture(c.pointerId), i.current = null, u(!1), p());
582
+ onPointerUp: (l) => {
583
+ var d;
584
+ ((d = i.current) == null ? void 0 : d.id) === l.pointerId && (l.currentTarget.hasPointerCapture(l.pointerId) && l.currentTarget.releasePointerCapture(l.pointerId), i.current = null, u(!1), f());
585
585
  },
586
586
  onPointerCancel: () => {
587
587
  i.current = null, u(!1);
@@ -589,13 +589,13 @@ function zn({ children: e, className: t, onNearEnd: n, snap: r = !1 }) {
589
589
  children: e
590
590
  }
591
591
  ),
592
- /* @__PURE__ */ a(te, { size: "sm", "aria-label": "Scroll right", onClick: () => j(1), children: /* @__PURE__ */ a(Nt, {}) })
592
+ /* @__PURE__ */ a(ne, { size: "sm", "aria-label": "Scroll right", onClick: () => v(1), children: /* @__PURE__ */ a(Ct, {}) })
593
593
  ] });
594
594
  }
595
- const Mt = {
595
+ const It = {
596
596
  sm: "j-badge--sm",
597
597
  md: "j-badge--md"
598
- }, Ot = {
598
+ }, Jt = {
599
599
  dark: "j-badge--dark",
600
600
  blue: "j-badge--blue",
601
601
  red: "j-badge--red",
@@ -604,21 +604,21 @@ const Mt = {
604
604
  orange: "j-badge--orange",
605
605
  purple: "j-badge--purple"
606
606
  };
607
- function Un({ size: e = "sm", tone: t = "dark", className: n, children: r, ...o }) {
608
- const i = ["j-badge", Mt[e], Ot[t], n].filter(Boolean).join(" ");
607
+ function fe({ size: e = "sm", tone: t = "dark", className: n, children: r, ...o }) {
608
+ const i = ["j-badge", It[e], Jt[t], n].filter(Boolean).join(" ");
609
609
  return /* @__PURE__ */ a("span", { className: i, ...o, children: r });
610
610
  }
611
- function Wn({ children: e, ...t }) {
611
+ function Xn({ children: e, ...t }) {
612
612
  return /* @__PURE__ */ a("span", { ...t, children: e });
613
613
  }
614
- function Gn({ children: e, ...t }) {
614
+ function Zn({ children: e, ...t }) {
615
615
  return /* @__PURE__ */ a("a", { ...t, children: e });
616
616
  }
617
- function Kn({ className: e, ref: t, ...n }) {
617
+ function Vn({ className: e, ref: t, ...n }) {
618
618
  const r = ["j-text-input", e].filter(Boolean).join(" ");
619
619
  return /* @__PURE__ */ a("input", { ref: t, className: r, ...n });
620
620
  }
621
- function Yn({
621
+ function qn({
622
622
  onPrev: e,
623
623
  onNext: t,
624
624
  canPrev: n = !0,
@@ -627,15 +627,15 @@ function Yn({
627
627
  nextLabel: i = "Next",
628
628
  children: s,
629
629
  className: u = "",
630
- style: p
630
+ style: f
631
631
  }) {
632
- return /* @__PURE__ */ _("div", { className: `j-flank ${u}`, style: p, children: [
633
- /* @__PURE__ */ a(_e, { direction: "left", onClick: e, disabled: !n, "aria-label": o }),
632
+ return /* @__PURE__ */ _("div", { className: `j-flank ${u}`, style: f, children: [
633
+ /* @__PURE__ */ a(xe, { direction: "left", onClick: e, disabled: !n, "aria-label": o }),
634
634
  /* @__PURE__ */ a("div", { className: "j-flank__content", children: s }),
635
- /* @__PURE__ */ a(_e, { direction: "right", onClick: t, disabled: !r, "aria-label": i })
635
+ /* @__PURE__ */ a(xe, { direction: "right", onClick: t, disabled: !r, "aria-label": i })
636
636
  ] });
637
637
  }
638
- function _e({
638
+ function xe({
639
639
  direction: e,
640
640
  onClick: t,
641
641
  disabled: n,
@@ -657,14 +657,14 @@ function _e({
657
657
  onMouseLeave: () => i(!1),
658
658
  onTouchStart: () => !n && i(!0),
659
659
  onTouchEnd: () => i(!1),
660
- children: /* @__PURE__ */ a(It, { direction: e })
660
+ children: /* @__PURE__ */ a($t, { direction: e })
661
661
  }
662
662
  );
663
663
  }
664
- function It({ direction: e }) {
664
+ function $t({ direction: e }) {
665
665
  return /* @__PURE__ */ a("svg", { width: 28, height: 28, viewBox: "0 0 28 28", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": !0, children: /* @__PURE__ */ a("polyline", { points: e === "left" ? "18,4 8,14 18,24" : "10,4 20,14 10,24" }) });
666
666
  }
667
- function Xn({
667
+ function Qn({
668
668
  label: e,
669
669
  title: t,
670
670
  description: n,
@@ -673,13 +673,13 @@ function Xn({
673
673
  onNext: i,
674
674
  canPrev: s = !0,
675
675
  canNext: u = !0,
676
- className: p = ""
676
+ className: f = ""
677
677
  }) {
678
- return /* @__PURE__ */ _("div", { className: ["j-panel-spinner", p].filter(Boolean).join(" "), children: [
679
- e ? /* @__PURE__ */ a("div", { className: "j-panel-spinner__label", children: /* @__PURE__ */ a(K, { size: "sm", tone: "white", children: e }) }) : null,
678
+ return /* @__PURE__ */ _("div", { className: ["j-panel-spinner", f].filter(Boolean).join(" "), children: [
679
+ e ? /* @__PURE__ */ a("div", { className: "j-panel-spinner__label", children: /* @__PURE__ */ a(U, { size: "sm", tone: "white", children: e }) }) : null,
680
680
  /* @__PURE__ */ _("div", { className: "j-panel-spinner__row", children: [
681
681
  /* @__PURE__ */ a(
682
- Y,
682
+ W,
683
683
  {
684
684
  tone: "red",
685
685
  size: "sm",
@@ -692,11 +692,11 @@ function Xn({
692
692
  ),
693
693
  /* @__PURE__ */ _("div", { className: "j-panel-spinner__panel", children: [
694
694
  r ? /* @__PURE__ */ a("div", { className: "j-panel-spinner__media", children: r }) : null,
695
- /* @__PURE__ */ a("div", { className: "j-panel-spinner__title", children: /* @__PURE__ */ a(K, { size: "md", tone: "white", children: t }) }),
696
- n ? /* @__PURE__ */ a("div", { className: "j-panel-spinner__description", children: /* @__PURE__ */ a(K, { size: "xs", tone: "grey", children: n }) }) : null
695
+ /* @__PURE__ */ a("div", { className: "j-panel-spinner__title", children: /* @__PURE__ */ a(U, { size: "md", tone: "white", children: t }) }),
696
+ n ? /* @__PURE__ */ a("div", { className: "j-panel-spinner__description", children: /* @__PURE__ */ a(U, { size: "xs", tone: "grey", children: n }) }) : null
697
697
  ] }),
698
698
  /* @__PURE__ */ a(
699
- Y,
699
+ W,
700
700
  {
701
701
  tone: "red",
702
702
  size: "sm",
@@ -710,7 +710,7 @@ function Xn({
710
710
  ] })
711
711
  ] });
712
712
  }
713
- const Dt = {
713
+ const Ft = {
714
714
  Jokers: { cols: 10, rows: 16, assetKey: "jokers" },
715
715
  Tarots: { cols: 10, rows: 6, assetKey: "tarots" },
716
716
  Vouchers: { cols: 9, rows: 4, assetKey: "vouchers" },
@@ -721,23 +721,23 @@ const Dt = {
721
721
  Editions: { cols: 5, rows: 1, assetKey: "editions" },
722
722
  Stakes: { cols: 5, rows: 2, assetKey: "stakes" },
723
723
  Decks: { cols: 13, rows: 4, assetKey: "deck" }
724
- }, fe = (e) => e.toLowerCase().replace(/\s+/g, ""), Jt = (e) => e.replace(/^(Joker|Tarot|Planet|Voucher|Pack|Edition|Tag) [|:] /i, "").trim(), ce = /* @__PURE__ */ new Map();
725
- function V(e, t) {
724
+ }, me = (e) => e.toLowerCase().replace(/\s+/g, ""), zt = (e) => e.replace(/^(Joker|Tarot|Planet|Voucher|Pack|Edition|Tag) [|:] /i, "").trim(), ue = /* @__PURE__ */ new Map();
725
+ function q(e, t) {
726
726
  for (const n of e) {
727
727
  if (!n.name || !n.pos) continue;
728
- const r = fe(n.name);
729
- ce.has(r) || ce.set(r, { pos: n.pos, type: t });
728
+ const r = me(n.name);
729
+ ue.has(r) || ue.set(r, { pos: n.pos, type: t });
730
730
  }
731
731
  }
732
- V(Qe, "Jokers");
733
- V(et, "Jokers");
734
- V(tt, "Tarots");
735
- V(nt ?? [], "Tarots");
736
- V(rt, "Vouchers");
737
- V(ot, "BlindChips");
738
- V(at, "tags");
739
- V(it ?? [], "Boosters");
740
- const Ft = {
732
+ q(nt, "Jokers");
733
+ q(rt, "Jokers");
734
+ q(ot, "Tarots");
735
+ q(at ?? [], "Tarots");
736
+ q(it, "Vouchers");
737
+ q(st, "BlindChips");
738
+ q(lt, "tags");
739
+ q(ct ?? [], "Boosters");
740
+ const Ut = {
741
741
  Jokers: { x: 9, y: 9 },
742
742
  // grey card back (legendary face row)
743
743
  Tarots: { x: 4, y: 2 },
@@ -751,18 +751,18 @@ const Ft = {
751
751
  BlindChips: { x: 0, y: 30 }
752
752
  // grey ? blind
753
753
  };
754
- function $t(e) {
755
- return { pos: Ft[e] ?? { x: 0, y: 0 }, type: e };
754
+ function Wt(e) {
755
+ return { pos: Ut[e] ?? { x: 0, y: 0 }, type: e };
756
756
  }
757
- function zt(e) {
758
- return ce.get(fe(Jt(e))) ?? ce.get(fe(e)) ?? null;
757
+ function Kt(e) {
758
+ return ue.get(me(zt(e))) ?? ue.get(me(e)) ?? null;
759
759
  }
760
- function Ut(e, t = "Jokers") {
761
- return zt(e) ?? $t(t);
760
+ function Gt(e, t = "Jokers") {
761
+ return Kt(e) ?? Wt(t);
762
762
  }
763
- const Wt = /* @__PURE__ */ new Set(["Jokers", "Tarots", "Vouchers", "Boosters"]);
764
- function Hn({ name: e, sheet: t, width: n, className: r, style: o }) {
765
- const { pos: i, type: s } = Ut(e, t), u = Dt[s], p = Wt.has(s) ? Math.round(n * (95 / 71)) : n;
763
+ const Yt = /* @__PURE__ */ new Set(["Jokers", "Tarots", "Vouchers", "Boosters"]);
764
+ function er({ name: e, sheet: t, width: n, className: r, style: o }) {
765
+ const { pos: i, type: s } = Gt(e, t), u = Ft[s], f = Yt.has(s) ? Math.round(n * (95 / 71)) : n;
766
766
  return /* @__PURE__ */ a(
767
767
  "div",
768
768
  {
@@ -771,7 +771,7 @@ function Hn({ name: e, sheet: t, width: n, className: r, style: o }) {
771
771
  position: "relative",
772
772
  display: "inline-block",
773
773
  width: n,
774
- height: p,
774
+ height: f,
775
775
  overflow: "hidden",
776
776
  imageRendering: "pixelated",
777
777
  ...o
@@ -783,7 +783,7 @@ function Hn({ name: e, sheet: t, width: n, className: r, style: o }) {
783
783
  style: {
784
784
  position: "absolute",
785
785
  inset: 0,
786
- backgroundImage: `url(${qe(u.assetKey)})`,
786
+ backgroundImage: `url(${tt(u.assetKey)})`,
787
787
  backgroundSize: `${u.cols * 100}% ${u.rows * 100}%`,
788
788
  backgroundPosition: `${i.x / (u.cols - 1) * 100}% ${i.y / (u.rows - 1) * 100}%`,
789
789
  backgroundRepeat: "no-repeat"
@@ -793,39 +793,39 @@ function Hn({ name: e, sheet: t, width: n, className: r, style: o }) {
793
793
  }
794
794
  );
795
795
  }
796
- function Zn({ className: e, children: t, ...n }) {
796
+ function tr({ className: e, children: t, ...n }) {
797
797
  return /* @__PURE__ */ a("div", { className: ["j-picker", e].filter(Boolean).join(" "), ...n, children: t });
798
798
  }
799
- function Vn({ className: e, children: t, ...n }) {
799
+ function nr({ className: e, children: t, ...n }) {
800
800
  return /* @__PURE__ */ a("div", { className: ["j-picker__section", e].filter(Boolean).join(" "), ...n, children: t });
801
801
  }
802
- function qn({ className: e, children: t, ...n }) {
802
+ function rr({ className: e, children: t, ...n }) {
803
803
  return /* @__PURE__ */ a("div", { className: ["j-picker__search", e].filter(Boolean).join(" "), ...n, children: t });
804
804
  }
805
- function Qn({ className: e, children: t, ...n }) {
805
+ function or({ className: e, children: t, ...n }) {
806
806
  return /* @__PURE__ */ a("div", { className: ["j-picker__hint", e].filter(Boolean).join(" "), ...n, children: t });
807
807
  }
808
- function er({ legendary: e, className: t, children: n, ...r }) {
808
+ function ar({ legendary: e, className: t, children: n, ...r }) {
809
809
  const o = ["j-picker__grid", e ? "j-picker__grid--legendary" : "", t].filter(Boolean).join(" ");
810
810
  return /* @__PURE__ */ a("div", { className: o, ...r, children: n });
811
811
  }
812
- function tr({ muted: e, className: t, children: n, ...r }) {
812
+ function ir({ muted: e, className: t, children: n, ...r }) {
813
813
  const o = ["j-picker__item", t].filter(Boolean).join(" ");
814
814
  return /* @__PURE__ */ a("button", { type: "button", className: o, "data-muted": e, ...r, children: n });
815
815
  }
816
- function nr({ className: e, children: t, ...n }) {
816
+ function sr({ className: e, children: t, ...n }) {
817
817
  return /* @__PURE__ */ a("div", { className: ["j-picker__pair", e].filter(Boolean).join(" "), ...n, children: t });
818
818
  }
819
- function rr({ className: e, children: t, ...n }) {
819
+ function lr({ className: e, children: t, ...n }) {
820
820
  return /* @__PURE__ */ a("div", { className: ["j-picker__empty", e].filter(Boolean).join(" "), ...n, children: t });
821
821
  }
822
- function or({ tabs: e, activeTab: t, onTabChange: n }) {
822
+ function cr({ tabs: e, activeTab: t, onTabChange: n }) {
823
823
  return /* @__PURE__ */ a("div", { className: "j-tabs", children: e.map((r) => {
824
824
  const o = r.id === t;
825
825
  return /* @__PURE__ */ _("div", { className: "j-tab", children: [
826
826
  /* @__PURE__ */ a("div", { className: "j-tab__indicator", "data-active": o, children: /* @__PURE__ */ a("svg", { width: "10", height: "8", viewBox: "0 0 10 8", children: /* @__PURE__ */ a("path", { d: "M5 8 L0 0 L10 0 Z" }) }) }),
827
827
  /* @__PURE__ */ a(
828
- Y,
828
+ W,
829
829
  {
830
830
  size: "sm",
831
831
  tone: "red",
@@ -836,45 +836,45 @@ function or({ tabs: e, activeTab: t, onTabChange: n }) {
836
836
  ] }, r.id);
837
837
  }) });
838
838
  }
839
- function ar({ active: e, className: t, children: n, ...r }) {
839
+ function ur({ active: e, className: t, children: n, ...r }) {
840
840
  const o = ["j-list-item", t].filter(Boolean).join(" ");
841
841
  return /* @__PURE__ */ a("button", { type: "button", className: o, "data-active": e, ...r, children: n });
842
842
  }
843
- const ye = "data-j-motion", me = "jimbo-motion", xe = "(prefers-reduced-motion: reduce)";
844
- function Gt(e) {
843
+ const Se = "data-j-motion", ge = "jimbo-motion", ke = "(prefers-reduced-motion: reduce)";
844
+ function Ht(e) {
845
845
  const t = document.documentElement;
846
- e === "auto" ? t.removeAttribute(ye) : t.setAttribute(ye, e);
846
+ e === "auto" ? t.removeAttribute(Se) : t.setAttribute(Se, e);
847
847
  }
848
- function Kt() {
848
+ function Xt() {
849
849
  try {
850
- const e = window.localStorage.getItem(me);
850
+ const e = window.localStorage.getItem(ge);
851
851
  if (e === "full" || e === "reduced") return e;
852
852
  } catch {
853
853
  }
854
854
  return "auto";
855
855
  }
856
- function ir() {
857
- const [e, t] = T(
858
- () => typeof document > "u" ? "auto" : Kt()
859
- ), [n, r] = T(
860
- () => typeof window > "u" ? !1 : window.matchMedia(xe).matches
856
+ function dr() {
857
+ const [e, t] = L(
858
+ () => typeof document > "u" ? "auto" : Xt()
859
+ ), [n, r] = L(
860
+ () => typeof window > "u" ? !1 : window.matchMedia(ke).matches
861
861
  );
862
- W(() => {
863
- Gt(e);
864
- }, [e]), W(() => {
865
- const s = window.matchMedia(xe), u = () => r(s.matches);
862
+ G(() => {
863
+ Ht(e);
864
+ }, [e]), G(() => {
865
+ const s = window.matchMedia(ke), u = () => r(s.matches);
866
866
  return s.addEventListener("change", u), () => s.removeEventListener("change", u);
867
867
  }, []);
868
- const o = Q((s) => {
868
+ const o = H((s) => {
869
869
  t(s);
870
870
  try {
871
- s === "auto" ? window.localStorage.removeItem(me) : window.localStorage.setItem(me, s);
871
+ s === "auto" ? window.localStorage.removeItem(ge) : window.localStorage.setItem(ge, s);
872
872
  } catch {
873
873
  }
874
874
  }, []);
875
875
  return { setting: e, setSetting: o, osPrefersReduced: n, effectiveReducedMotion: e === "reduced" ? !0 : e === "full" ? !1 : n };
876
876
  }
877
- const D = {
877
+ const J = {
878
878
  primary: [1, 0.2, 0.2],
879
879
  // red
880
880
  secondary: [0, 0.5, 1],
@@ -897,11 +897,11 @@ function ee(e, t) {
897
897
  const r = parseInt(n, 16);
898
898
  return Number.isNaN(r) ? t : [(r >> 16 & 255) / 255, (r >> 8 & 255) / 255, (r & 255) / 255];
899
899
  }
900
- function Yt(e = {}) {
901
- const t = J(null), n = J(e);
902
- return Ae(() => {
900
+ function Zt(e = {}) {
901
+ const t = $(null), n = $(e);
902
+ return Pe(() => {
903
903
  n.current = e;
904
- }), W(() => {
904
+ }), G(() => {
905
905
  const r = t.current;
906
906
  if (!r) return;
907
907
  const o = r.getContext("webgl");
@@ -958,20 +958,20 @@ function Yt(e = {}) {
958
958
  vec3 base = (0.3/u_contrast)*u_color1 + (1.0 - 0.3/u_contrast)*(u_color1*c1p + u_color2*c2p + c3p*u_color3) + vec3(light);
959
959
  gl_FragColor = vec4(base, 1.0);
960
960
  }
961
- `, u = (B, ne) => {
961
+ `, u = (B, re) => {
962
962
  const O = o.createShader(B);
963
- return O ? (o.shaderSource(O, ne), o.compileShader(O), o.getShaderParameter(O, o.COMPILE_STATUS) ? O : (console.error("[JimboBackground] shader compile error:", o.getShaderInfoLog(O)), o.deleteShader(O), null)) : null;
964
- }, p = u(o.VERTEX_SHADER, i), j = u(o.FRAGMENT_SHADER, s);
965
- if (!p || !j) return;
966
- const l = o.createProgram();
967
- if (!l) return;
968
- if (o.attachShader(l, p), o.attachShader(l, j), o.linkProgram(l), !o.getProgramParameter(l, o.LINK_STATUS)) {
969
- console.error("[JimboBackground] program link error:", o.getProgramInfoLog(l));
963
+ return O ? (o.shaderSource(O, re), o.compileShader(O), o.getShaderParameter(O, o.COMPILE_STATUS) ? O : (console.error("[JimboBackground] shader compile error:", o.getShaderInfoLog(O)), o.deleteShader(O), null)) : null;
964
+ }, f = u(o.VERTEX_SHADER, i), v = u(o.FRAGMENT_SHADER, s);
965
+ if (!f || !v) return;
966
+ const c = o.createProgram();
967
+ if (!c) return;
968
+ if (o.attachShader(c, f), o.attachShader(c, v), o.linkProgram(c), !o.getProgramParameter(c, o.LINK_STATUS)) {
969
+ console.error("[JimboBackground] program link error:", o.getProgramInfoLog(c));
970
970
  return;
971
971
  }
972
- o.useProgram(l);
973
- const c = o.createBuffer();
974
- o.bindBuffer(o.ARRAY_BUFFER, c), o.bufferData(
972
+ o.useProgram(c);
973
+ const l = o.createBuffer();
974
+ o.bindBuffer(o.ARRAY_BUFFER, l), o.bufferData(
975
975
  o.ARRAY_BUFFER,
976
976
  new Float32Array([
977
977
  -1,
@@ -989,134 +989,134 @@ function Yt(e = {}) {
989
989
  ]),
990
990
  o.STATIC_DRAW
991
991
  );
992
- const f = o.getAttribLocation(l, "position");
993
- o.enableVertexAttribArray(f), o.vertexAttribPointer(f, 2, o.FLOAT, !1, 0, 0);
994
- const y = o.getUniformLocation(l, "u_time"), x = o.getUniformLocation(l, "u_resolution"), k = o.getUniformLocation(l, "u_color1"), b = o.getUniformLocation(l, "u_color2"), d = o.getUniformLocation(l, "u_color3"), g = o.getUniformLocation(l, "u_spinRotation"), h = o.getUniformLocation(l, "u_spinSpeed"), m = o.getUniformLocation(l, "u_spinAmount"), v = o.getUniformLocation(l, "u_pixelFilter"), S = o.getUniformLocation(l, "u_contrast"), E = o.getUniformLocation(l, "u_lighting"), M = (B) => ({
995
- spinRotation: B.spinRotation ?? D.spinRotation,
996
- spinSpeed: 4.5 * (B.speed ?? D.speed),
997
- spinAmount: B.spinAmount ?? D.spinAmount,
998
- pixelFilter: B.pixelFilter ?? D.pixelFilter,
999
- contrast: B.contrast ?? D.contrast,
1000
- lighting: B.lighting ?? D.lighting
992
+ const d = o.getAttribLocation(c, "position");
993
+ o.enableVertexAttribArray(d), o.vertexAttribPointer(d, 2, o.FLOAT, !1, 0, 0);
994
+ const x = o.getUniformLocation(c, "u_time"), y = o.getUniformLocation(c, "u_resolution"), S = o.getUniformLocation(c, "u_color1"), j = o.getUniformLocation(c, "u_color2"), p = o.getUniformLocation(c, "u_color3"), g = o.getUniformLocation(c, "u_spinRotation"), b = o.getUniformLocation(c, "u_spinSpeed"), h = o.getUniformLocation(c, "u_spinAmount"), m = o.getUniformLocation(c, "u_pixelFilter"), k = o.getUniformLocation(c, "u_contrast"), N = o.getUniformLocation(c, "u_lighting"), M = (B) => ({
995
+ spinRotation: B.spinRotation ?? J.spinRotation,
996
+ spinSpeed: 4.5 * (B.speed ?? J.speed),
997
+ spinAmount: B.spinAmount ?? J.spinAmount,
998
+ pixelFilter: B.pixelFilter ?? J.pixelFilter,
999
+ contrast: B.contrast ?? J.contrast,
1000
+ lighting: B.lighting ?? J.lighting
1001
1001
  }), R = n.current, w = [
1002
- ee(R.primary, D.primary),
1003
- ee(R.secondary, D.secondary),
1004
- ee(R.dark, D.dark)
1005
- ], P = M(R), N = performance.now();
1006
- let L = N, C = 0;
1007
- const U = () => {
1008
- const B = performance.now(), ne = Math.max(0, B - L);
1009
- L = B;
1010
- const O = n.current, ae = [
1011
- ee(O.primary, D.primary),
1012
- ee(O.secondary, D.secondary),
1013
- ee(O.dark, D.dark)
1014
- ], A = M(O), X = Math.max(1, O.transitionMs ?? D.transitionMs), q = 1 - Math.exp(-ne / X);
1015
- for (let G = 0; G < 3; G++)
1016
- for (let re = 0; re < 3; re++)
1017
- w[G][re] += (ae[G][re] - w[G][re]) * q;
1018
- const H = (G) => {
1019
- P[G] += (A[G] - P[G]) * q;
1002
+ ee(R.primary, J.primary),
1003
+ ee(R.secondary, J.secondary),
1004
+ ee(R.dark, J.dark)
1005
+ ], P = M(R), E = performance.now();
1006
+ let C = E, A = 0;
1007
+ const K = () => {
1008
+ const B = performance.now(), re = Math.max(0, B - C);
1009
+ C = B;
1010
+ const O = n.current, ie = [
1011
+ ee(O.primary, J.primary),
1012
+ ee(O.secondary, J.secondary),
1013
+ ee(O.dark, J.dark)
1014
+ ], T = M(O), X = Math.max(1, O.transitionMs ?? J.transitionMs), Q = 1 - Math.exp(-re / X);
1015
+ for (let Y = 0; Y < 3; Y++)
1016
+ for (let oe = 0; oe < 3; oe++)
1017
+ w[Y][oe] += (ie[Y][oe] - w[Y][oe]) * Q;
1018
+ const Z = (Y) => {
1019
+ P[Y] += (T[Y] - P[Y]) * Q;
1020
1020
  };
1021
- H("spinRotation"), H("spinSpeed"), H("spinAmount"), H("pixelFilter"), H("contrast"), H("lighting");
1022
- const ge = r.clientWidth, be = r.clientHeight;
1023
- (r.width !== ge || r.height !== be) && (r.width = ge, r.height = be, o.viewport(0, 0, o.drawingBufferWidth, o.drawingBufferHeight)), o.uniform1f(y, (B - N) / 1e3), o.uniform2f(x, r.width, r.height), o.uniform3f(k, w[0][0], w[0][1], w[0][2]), o.uniform3f(b, w[1][0], w[1][1], w[1][2]), o.uniform3f(d, w[2][0], w[2][1], w[2][2]), o.uniform1f(g, P.spinRotation), o.uniform1f(h, P.spinSpeed), o.uniform1f(m, P.spinAmount), o.uniform1f(v, P.pixelFilter), o.uniform1f(S, P.contrast), o.uniform1f(E, P.lighting), o.drawArrays(o.TRIANGLES, 0, 6), C = requestAnimationFrame(U);
1021
+ Z("spinRotation"), Z("spinSpeed"), Z("spinAmount"), Z("pixelFilter"), Z("contrast"), Z("lighting");
1022
+ const ve = r.clientWidth, je = r.clientHeight;
1023
+ (r.width !== ve || r.height !== je) && (r.width = ve, r.height = je, o.viewport(0, 0, o.drawingBufferWidth, o.drawingBufferHeight)), o.uniform1f(x, (B - E) / 1e3), o.uniform2f(y, r.width, r.height), o.uniform3f(S, w[0][0], w[0][1], w[0][2]), o.uniform3f(j, w[1][0], w[1][1], w[1][2]), o.uniform3f(p, w[2][0], w[2][1], w[2][2]), o.uniform1f(g, P.spinRotation), o.uniform1f(b, P.spinSpeed), o.uniform1f(h, P.spinAmount), o.uniform1f(m, P.pixelFilter), o.uniform1f(k, P.contrast), o.uniform1f(N, P.lighting), o.drawArrays(o.TRIANGLES, 0, 6), A = requestAnimationFrame(K);
1024
1024
  };
1025
- return C = requestAnimationFrame(U), () => {
1026
- cancelAnimationFrame(C), o.deleteProgram(l), o.deleteShader(p), o.deleteShader(j), o.deleteBuffer(c);
1025
+ return A = requestAnimationFrame(K), () => {
1026
+ cancelAnimationFrame(A), o.deleteProgram(c), o.deleteShader(f), o.deleteShader(v), o.deleteBuffer(l);
1027
1027
  };
1028
1028
  }, []), t;
1029
1029
  }
1030
- function sr(e, t, n) {
1031
- const [r, o] = T(null), [i, s] = T(null), [u, p] = T(null), j = Q(
1032
- (b, d, g) => {
1033
- const h = "touches" in b ? b.touches[0] : b, m = b.currentTarget.getBoundingClientRect();
1030
+ function pr(e, t, n) {
1031
+ const [r, o] = L(null), [i, s] = L(null), [u, f] = L(null), v = H(
1032
+ (j, p, g) => {
1033
+ const b = "touches" in j ? j.touches[0] : j, h = j.currentTarget.getBoundingClientRect();
1034
1034
  s({
1035
- clause: d,
1035
+ clause: p,
1036
1036
  fromZone: g,
1037
- x: h.clientX,
1038
- y: h.clientY,
1039
- offX: h.clientX - m.left,
1040
- offY: h.clientY - m.top
1041
- }), p(null);
1037
+ x: b.clientX,
1038
+ y: b.clientY,
1039
+ offX: b.clientX - h.left,
1040
+ offY: b.clientY - h.top
1041
+ }), f(null);
1042
1042
  },
1043
1043
  []
1044
- ), l = J(r), c = J(i), f = J(u), y = J(e), x = J(t);
1045
- Ae(() => {
1046
- l.current = r, c.current = i, f.current = u, y.current = e, x.current = t;
1044
+ ), c = $(r), l = $(i), d = $(u), x = $(e), y = $(t);
1045
+ Pe(() => {
1046
+ c.current = r, l.current = i, d.current = u, x.current = e, y.current = t;
1047
1047
  });
1048
- const k = r !== null || i !== null;
1049
- return W(() => {
1050
- if (!k) return;
1051
- const b = (g) => {
1048
+ const S = r !== null || i !== null;
1049
+ return G(() => {
1050
+ if (!S) return;
1051
+ const j = (g) => {
1052
1052
  var M;
1053
- const h = "touches" in g ? g : null, m = h ? h.touches[0] : g;
1054
- if (!m) return;
1055
- let v = l.current;
1056
- if (!v && c.current) {
1057
- const R = m.clientX - c.current.x, w = m.clientY - c.current.y;
1053
+ const b = "touches" in g ? g : null, h = b ? b.touches[0] : g;
1054
+ if (!h) return;
1055
+ let m = c.current;
1056
+ if (!m && l.current) {
1057
+ const R = h.clientX - l.current.x, w = h.clientY - l.current.y;
1058
1058
  if (Math.hypot(R, w) < 8) return;
1059
- v = {
1060
- ...c.current,
1061
- x: m.clientX,
1062
- y: m.clientY
1063
- }, s(null), o(v);
1064
- } else v && (v = { ...v, x: m.clientX, y: m.clientY }, o(v));
1065
- if (!v) return;
1066
- h != null && h.cancelable && h.preventDefault();
1067
- const S = ((M = n.current) == null ? void 0 : M.querySelectorAll("[data-zone]")) ?? [];
1068
- let E = null;
1069
- for (const R of S) {
1059
+ m = {
1060
+ ...l.current,
1061
+ x: h.clientX,
1062
+ y: h.clientY
1063
+ }, s(null), o(m);
1064
+ } else m && (m = { ...m, x: h.clientX, y: h.clientY }, o(m));
1065
+ if (!m) return;
1066
+ b != null && b.cancelable && b.preventDefault();
1067
+ const k = ((M = n.current) == null ? void 0 : M.querySelectorAll("[data-zone]")) ?? [];
1068
+ let N = null;
1069
+ for (const R of k) {
1070
1070
  const w = R.getBoundingClientRect();
1071
- if (m.clientX >= w.left && m.clientX <= w.right && m.clientY >= w.top && m.clientY <= w.bottom) {
1072
- E = R.getAttribute("data-zone");
1071
+ if (h.clientX >= w.left && h.clientX <= w.right && h.clientY >= w.top && h.clientY <= w.bottom) {
1072
+ N = R.getAttribute("data-zone");
1073
1073
  break;
1074
1074
  }
1075
1075
  }
1076
- p(E);
1077
- }, d = () => {
1078
- const g = l.current, h = f.current;
1079
- if (g && h && h !== g.fromZone) {
1080
- const m = h, v = y.current;
1081
- x.current({
1082
- ...v,
1083
- [g.fromZone]: v[g.fromZone].filter((S) => S.id !== g.clause.id),
1084
- [m]: [...v[m], { ...g.clause }]
1076
+ f(N);
1077
+ }, p = () => {
1078
+ const g = c.current, b = d.current;
1079
+ if (g && b && b !== g.fromZone) {
1080
+ const h = b, m = x.current;
1081
+ y.current({
1082
+ ...m,
1083
+ [g.fromZone]: m[g.fromZone].filter((k) => k.id !== g.clause.id),
1084
+ [h]: [...m[h], { ...g.clause }]
1085
1085
  });
1086
1086
  }
1087
- s(null), o(null), p(null);
1087
+ s(null), o(null), f(null);
1088
1088
  };
1089
- return window.addEventListener("mousemove", b), window.addEventListener("mouseup", d), window.addEventListener("touchmove", b, { passive: !1 }), window.addEventListener("touchend", d), () => {
1090
- window.removeEventListener("mousemove", b), window.removeEventListener("mouseup", d), window.removeEventListener("touchmove", b), window.removeEventListener("touchend", d);
1089
+ return window.addEventListener("mousemove", j), window.addEventListener("mouseup", p), window.addEventListener("touchmove", j, { passive: !1 }), window.addEventListener("touchend", p), () => {
1090
+ window.removeEventListener("mousemove", j), window.removeEventListener("mouseup", p), window.removeEventListener("touchmove", j), window.removeEventListener("touchend", p);
1091
1091
  };
1092
- }, [k, n]), {
1092
+ }, [S, n]), {
1093
1093
  drag: r,
1094
1094
  hoverZone: u,
1095
- onDragStart: j
1095
+ onDragStart: v
1096
1096
  };
1097
1097
  }
1098
- const Xt = {
1098
+ const Vt = {
1099
1099
  xs: "j-inline-edit--xs",
1100
1100
  sm: "j-inline-edit--sm",
1101
1101
  md: "j-inline-edit--md",
1102
1102
  lg: "j-inline-edit--lg"
1103
- }, Ht = {
1103
+ }, qt = {
1104
1104
  white: "j-inline-edit--white",
1105
1105
  gold: "j-inline-edit--gold",
1106
1106
  grey: "j-inline-edit--grey"
1107
- }, lr = z.forwardRef(
1107
+ }, fr = z.forwardRef(
1108
1108
  function({ size: t = "md", tone: n = "white", dim: r = !1, className: o = "", ...i }, s) {
1109
1109
  const u = [
1110
1110
  "j-inline-edit",
1111
- Xt[t],
1112
- Ht[n],
1111
+ Vt[t],
1112
+ qt[n],
1113
1113
  r ? "j-inline-edit--dim" : null,
1114
1114
  o || null
1115
1115
  ].filter(Boolean).join(" ");
1116
1116
  return /* @__PURE__ */ a("input", { ref: s, type: "text", className: u, ...i });
1117
1117
  }
1118
1118
  );
1119
- function cr({
1119
+ function hr({
1120
1120
  className: e,
1121
1121
  minHeight: t = 320,
1122
1122
  style: n,
@@ -1129,7 +1129,7 @@ function cr({
1129
1129
  };
1130
1130
  return /* @__PURE__ */ a("div", { ref: r, className: i, style: s, ...o });
1131
1131
  }
1132
- const Zt = {
1132
+ const Qt = {
1133
1133
  blue: "j-outer-tab--blue",
1134
1134
  red: "j-outer-tab--red",
1135
1135
  orange: "j-outer-tab--orange",
@@ -1137,7 +1137,7 @@ const Zt = {
1137
1137
  purple: "j-outer-tab--purple",
1138
1138
  gold: "j-outer-tab--gold"
1139
1139
  };
1140
- function Vt({
1140
+ function en({
1141
1141
  label: e,
1142
1142
  tone: t,
1143
1143
  active: n = !1,
@@ -1147,14 +1147,14 @@ function Vt({
1147
1147
  children: s,
1148
1148
  ...u
1149
1149
  }) {
1150
- const p = [
1150
+ const f = [
1151
1151
  "j-outer-tab",
1152
- t ? Zt[t] : "",
1152
+ t ? Qt[t] : "",
1153
1153
  n ? "j-outer-tab--active" : "",
1154
1154
  i
1155
1155
  ].filter(Boolean).join(" ");
1156
- return /* @__PURE__ */ _("div", { className: p, ...u, children: [
1157
- /* @__PURE__ */ a("span", { className: "j-outer-tab__grip", "aria-hidden": !0, children: /* @__PURE__ */ a(xt, {}) }),
1156
+ return /* @__PURE__ */ _("div", { className: f, ...u, children: [
1157
+ /* @__PURE__ */ a("span", { className: "j-outer-tab__grip", "aria-hidden": !0, children: /* @__PURE__ */ a(wt, {}) }),
1158
1158
  /* @__PURE__ */ a("span", { className: "j-outer-tab__label", children: e }),
1159
1159
  /* @__PURE__ */ a("span", { className: "j-outer-tab__space", children: s }),
1160
1160
  o ? /* @__PURE__ */ a(
@@ -1163,19 +1163,19 @@ function Vt({
1163
1163
  type: "button",
1164
1164
  className: "j-outer-tab__fs",
1165
1165
  "aria-label": r ? "Restore pane" : "Fullscreen pane",
1166
- onClick: (j) => {
1167
- j.stopPropagation(), o();
1166
+ onClick: (v) => {
1167
+ v.stopPropagation(), o();
1168
1168
  },
1169
- children: r ? /* @__PURE__ */ a(kt, {}) : /* @__PURE__ */ a(St, {})
1169
+ children: r ? /* @__PURE__ */ a(Et, {}) : /* @__PURE__ */ a(Nt, {})
1170
1170
  }
1171
1171
  ) : null
1172
1172
  ] });
1173
1173
  }
1174
- let qt = 0;
1175
- function ke(e) {
1176
- return `${e}${++qt}-${Date.now().toString(36)}`;
1174
+ let tn = 0;
1175
+ function we(e) {
1176
+ return `${e}${++tn}-${Date.now().toString(36)}`;
1177
1177
  }
1178
- function Qt(e) {
1178
+ function nn(e) {
1179
1179
  return {
1180
1180
  type: "split",
1181
1181
  id: "s-root",
@@ -1201,206 +1201,336 @@ function Qt(e) {
1201
1201
  ]
1202
1202
  };
1203
1203
  }
1204
- function Ie(e, t) {
1204
+ function Je(e, t) {
1205
1205
  if (e.type === "group") {
1206
1206
  if (!e.panes.includes(t)) return e;
1207
1207
  const r = e.panes.filter((i) => i !== t), o = e.active === t ? r[0] ?? null : e.active;
1208
1208
  return { ...e, panes: r, active: o };
1209
1209
  }
1210
- const n = e.children.map((r) => Ie(r, t)).filter((r) => !(r.type === "group" && r.panes.length === 0));
1210
+ const n = e.children.map((r) => Je(r, t)).filter((r) => !(r.type === "group" && r.panes.length === 0));
1211
1211
  return n.length === 1 ? n[0] : { ...e, children: n };
1212
1212
  }
1213
- function he(e, t, n) {
1214
- return e.type === "group" ? e.id === t ? n(e) : e : { ...e, children: e.children.map((r) => he(r, t, n)) };
1213
+ function be(e, t, n) {
1214
+ return e.type === "group" ? e.id === t ? n(e) : e : { ...e, children: e.children.map((r) => be(r, t, n)) };
1215
1215
  }
1216
- function De(e, t, n, r) {
1216
+ function $e(e, t, n, r) {
1217
1217
  if (r === "center") return e;
1218
1218
  if (e.type === "group") {
1219
1219
  if (e.id !== t) return e;
1220
- const o = { type: "group", id: ke("g"), panes: [n], active: n }, i = r === "left" || r === "right" ? "row" : "column", s = r === "left" || r === "top" ? [o, e] : [e, o];
1221
- return { type: "split", id: ke("s"), dir: i, ratio: 0.5, children: s };
1220
+ const o = { type: "group", id: we("g"), panes: [n], active: n }, i = r === "left" || r === "right" ? "row" : "column", s = r === "left" || r === "top" ? [o, e] : [e, o];
1221
+ return { type: "split", id: we("s"), dir: i, ratio: 0.5, children: s };
1222
1222
  }
1223
- return { ...e, children: e.children.map((o) => De(o, t, n, r)) };
1223
+ return { ...e, children: e.children.map((o) => $e(o, t, n, r)) };
1224
1224
  }
1225
- function Je(e, t = []) {
1226
- return e.type === "group" ? (t.push(e), t) : (e.children.forEach((n) => Je(n, t)), t);
1225
+ function Fe(e, t = []) {
1226
+ return e.type === "group" ? (t.push(e), t) : (e.children.forEach((n) => Fe(n, t)), t);
1227
1227
  }
1228
- function en(e, t) {
1229
- return e.type === "group" ? e.panes.includes(t) ? { ...e, active: t } : e : { ...e, children: e.children.map((n) => en(n, t)) };
1228
+ function rn(e, t) {
1229
+ return e.type === "group" ? e.panes.includes(t) ? { ...e, active: t } : e : { ...e, children: e.children.map((n) => rn(n, t)) };
1230
1230
  }
1231
- function tn(e, t) {
1232
- const n = Je(e);
1231
+ function on(e, t) {
1232
+ const n = Fe(e);
1233
1233
  if (!n.length) return !1;
1234
1234
  const r = n.flatMap((o) => o.panes);
1235
1235
  return r.length > 0 && r.every((o) => t.includes(o)) && n.every((o) => o.panes.length > 0);
1236
1236
  }
1237
- function nn(e, t, n) {
1237
+ function an(e, t, n) {
1238
1238
  try {
1239
1239
  const r = localStorage.getItem(e);
1240
1240
  if (!r) return t;
1241
1241
  const o = JSON.parse(r);
1242
- return tn(o, n) ? o : t;
1242
+ return on(o, n) ? o : t;
1243
1243
  } catch {
1244
1244
  return t;
1245
1245
  }
1246
1246
  }
1247
- function rn(e, t) {
1247
+ function sn(e, t) {
1248
1248
  try {
1249
1249
  localStorage.setItem(e, JSON.stringify(t));
1250
1250
  } catch {
1251
1251
  }
1252
1252
  }
1253
- function ur({
1253
+ function mr({
1254
1254
  panes: e,
1255
1255
  pyramid: t,
1256
1256
  storageKey: n,
1257
1257
  className: r
1258
1258
  }) {
1259
- const o = Object.keys(e), i = t && o.includes(t.filter) ? Qt(t) : {
1259
+ const o = Object.keys(e), i = t && o.includes(t.filter) ? nn(t) : {
1260
1260
  type: "group",
1261
1261
  id: "g-all",
1262
1262
  panes: o,
1263
1263
  active: o[0] ?? null
1264
- }, [s, u] = T(
1265
- () => n && typeof localStorage < "u" ? nn(n, i, o) : i
1266
- ), [p, j] = T(null), [l, c] = T(null);
1267
- W(() => {
1268
- n && rn(n, s);
1264
+ }, [s, u] = L(
1265
+ () => n && typeof localStorage < "u" ? an(n, i, o) : i
1266
+ ), [f, v] = L(null), [c, l] = L(null);
1267
+ G(() => {
1268
+ n && sn(n, s);
1269
1269
  }, [n, s]);
1270
- const f = (d) => {
1271
- if (d.target.closest(".j-dock-tabs")) return "center";
1272
- const h = d.currentTarget.getBoundingClientRect(), m = (d.clientX - h.left) / h.width, v = (d.clientY - h.top) / h.height;
1273
- return m < 0.25 ? "left" : m > 0.75 ? "right" : v < 0.25 ? "top" : v > 0.75 ? "bottom" : "center";
1274
- }, y = (d, g, h) => {
1275
- e[d] && (g.panes.length === 1 && g.panes[0] === d || u((m) => {
1276
- const v = Ie(m, d);
1277
- return h === "center" ? he(v, g.id, (S) => ({
1278
- ...S,
1279
- panes: [...S.panes, d],
1280
- active: d
1281
- })) : De(v, g.id, d, h);
1270
+ const d = (p) => {
1271
+ if (p.target.closest(".j-dock-tabs")) return "center";
1272
+ const b = p.currentTarget.getBoundingClientRect(), h = (p.clientX - b.left) / b.width, m = (p.clientY - b.top) / b.height;
1273
+ return h < 0.25 ? "left" : h > 0.75 ? "right" : m < 0.25 ? "top" : m > 0.75 ? "bottom" : "center";
1274
+ }, x = (p, g, b) => {
1275
+ e[p] && (g.panes.length === 1 && g.panes[0] === p || u((h) => {
1276
+ const m = Je(h, p);
1277
+ return b === "center" ? be(m, g.id, (k) => ({
1278
+ ...k,
1279
+ panes: [...k.panes, p],
1280
+ active: p
1281
+ })) : $e(m, g.id, p, b);
1282
1282
  }));
1283
- }, x = (d, g) => {
1284
- const h = e[d];
1285
- return h ? /* @__PURE__ */ a(
1286
- Vt,
1283
+ }, y = (p, g) => {
1284
+ const b = e[p];
1285
+ return b ? /* @__PURE__ */ a(
1286
+ en,
1287
1287
  {
1288
- label: h.label,
1289
- tone: h.tone,
1288
+ label: b.label,
1289
+ tone: b.tone,
1290
1290
  active: g,
1291
- fullscreen: l === d,
1292
- onToggleFullscreen: () => c((m) => m === d ? null : d),
1291
+ fullscreen: c === p,
1292
+ onToggleFullscreen: () => l((h) => h === p ? null : p),
1293
1293
  draggable: !0,
1294
- onDragStart: (m) => m.dataTransfer.setData("text/plain", d)
1294
+ onDragStart: (h) => h.dataTransfer.setData("text/plain", p)
1295
1295
  },
1296
- d
1296
+ p
1297
1297
  ) : null;
1298
- }, k = (d) => {
1299
- const g = p && p.groupId === d.id ? p.zone : null, h = g && g !== "center" ? ` j-dock-pane--drop-${g}` : "";
1298
+ }, S = (p) => {
1299
+ const g = f && f.groupId === p.id ? f.zone : null, b = g && g !== "center" ? ` j-dock-pane--drop-${g}` : "";
1300
1300
  return /* @__PURE__ */ _(
1301
- $,
1301
+ D,
1302
1302
  {
1303
- className: `j-dock-pane${h}`,
1304
- onDragOver: (m) => {
1305
- m.preventDefault();
1306
- const v = f(m);
1307
- j(
1308
- (S) => S && S.groupId === d.id && S.zone === v ? S : { groupId: d.id, zone: v }
1303
+ className: `j-dock-pane${b}`,
1304
+ onDragOver: (h) => {
1305
+ h.preventDefault();
1306
+ const m = d(h);
1307
+ v(
1308
+ (k) => k && k.groupId === p.id && k.zone === m ? k : { groupId: p.id, zone: m }
1309
1309
  );
1310
1310
  },
1311
- onDragLeave: () => j((m) => m && m.groupId === d.id ? null : m),
1312
- onDrop: (m) => {
1313
- m.preventDefault();
1314
- const v = m.dataTransfer.getData("text/plain"), S = f(m);
1315
- j(null), y(v, d, S);
1311
+ onDragLeave: () => v((h) => h && h.groupId === p.id ? null : h),
1312
+ onDrop: (h) => {
1313
+ h.preventDefault();
1314
+ const m = h.dataTransfer.getData("text/plain"), k = d(h);
1315
+ v(null), x(m, p, k);
1316
1316
  },
1317
1317
  children: [
1318
1318
  /* @__PURE__ */ a(
1319
- $,
1319
+ D,
1320
1320
  {
1321
1321
  className: `j-dock-tabs${g === "center" ? " j-dock-tabs--drop" : ""}`,
1322
- children: d.panes.map((m) => /* @__PURE__ */ a(
1323
- $,
1322
+ children: p.panes.map((h) => /* @__PURE__ */ a(
1323
+ D,
1324
1324
  {
1325
- onClick: () => u((v) => he(v, d.id, (S) => ({ ...S, active: m }))),
1326
- children: x(m, d.active === m)
1325
+ onClick: () => u((m) => be(m, p.id, (k) => ({ ...k, active: h }))),
1326
+ children: y(h, p.active === h)
1327
1327
  },
1328
- m
1328
+ h
1329
1329
  ))
1330
1330
  }
1331
1331
  ),
1332
- /* @__PURE__ */ a($, { className: "j-dock-body", children: d.active && e[d.active] ? e[d.active].content : null })
1332
+ /* @__PURE__ */ a(D, { className: "j-dock-body", children: p.active && e[p.active] ? e[p.active].content : null })
1333
1333
  ]
1334
1334
  },
1335
- d.id
1335
+ p.id
1336
1336
  );
1337
- }, b = (d) => {
1338
- if (d.type === "group") return k(d);
1339
- const [g, h] = d.children;
1337
+ }, j = (p) => {
1338
+ if (p.type === "group") return S(p);
1339
+ const [g, b] = p.children;
1340
1340
  return /* @__PURE__ */ _(
1341
- $,
1341
+ D,
1342
1342
  {
1343
- className: `j-dock-split j-dock-split--${d.dir}`,
1343
+ className: `j-dock-split j-dock-split--${p.dir}`,
1344
1344
  style: {
1345
- "--j-dock-a": `${d.ratio}fr`,
1346
- "--j-dock-b": `${1 - d.ratio}fr`
1345
+ "--j-dock-a": `${p.ratio}fr`,
1346
+ "--j-dock-b": `${1 - p.ratio}fr`
1347
1347
  },
1348
1348
  children: [
1349
- b(g),
1350
- /* @__PURE__ */ a($, { className: `j-dock-gutter j-dock-gutter--${d.dir}` }),
1351
- b(h)
1349
+ j(g),
1350
+ /* @__PURE__ */ a(D, { className: `j-dock-gutter j-dock-gutter--${p.dir}` }),
1351
+ j(b)
1352
1352
  ]
1353
1353
  },
1354
- d.id
1354
+ p.id
1355
1355
  );
1356
1356
  };
1357
- return l && e[l] ? /* @__PURE__ */ _($, { className: `j-dock j-dock--fs ${r ?? ""}`.trim(), children: [
1358
- /* @__PURE__ */ a($, { className: "j-dock-tabs", children: x(l, !0) }),
1359
- /* @__PURE__ */ a($, { className: "j-dock-body", children: e[l].content })
1360
- ] }) : /* @__PURE__ */ a($, { className: `j-dock ${r ?? ""}`.trim(), children: b(s) });
1357
+ return c && e[c] ? /* @__PURE__ */ _(D, { className: `j-dock j-dock--fs ${r ?? ""}`.trim(), children: [
1358
+ /* @__PURE__ */ a(D, { className: "j-dock-tabs", children: y(c, !0) }),
1359
+ /* @__PURE__ */ a(D, { className: "j-dock-body", children: e[c].content })
1360
+ ] }) : /* @__PURE__ */ a(D, { className: `j-dock ${r ?? ""}`.trim(), children: j(s) });
1361
1361
  }
1362
- const on = {
1362
+ const ln = {
1363
1363
  idle: "j-status-pill--idle",
1364
1364
  running: "j-status-pill--running",
1365
1365
  ok: "j-status-pill--ok",
1366
1366
  error: "j-status-pill--error",
1367
1367
  paused: "j-status-pill--paused"
1368
1368
  };
1369
- function an({ status: e = "idle", label: t, className: n, children: r, ...o }) {
1370
- const i = ["j-status-pill", on[e], n].filter(Boolean).join(" ");
1369
+ function cn({ status: e = "idle", label: t, className: n, children: r, ...o }) {
1370
+ const i = ["j-status-pill", ln[e], n].filter(Boolean).join(" ");
1371
1371
  return /* @__PURE__ */ _("span", { className: i, ...o, children: [
1372
1372
  /* @__PURE__ */ a("span", { className: "j-status-pill__dot", "aria-hidden": !0 }),
1373
1373
  t ?? r ?? e
1374
1374
  ] });
1375
1375
  }
1376
- const dr = z.forwardRef(
1377
- function({ onValueChange: t, className: n, value: r, min: o = 0, max: i = 100, style: s, ...u }, p) {
1378
- const j = Number(r ?? 0), l = Number(o), c = Number(i), f = c > l ? Math.min(100, Math.max(0, (j - l) / (c - l) * 100)) : 0, y = ["j-slider", n].filter(Boolean).join(" ");
1376
+ const gr = z.forwardRef(
1377
+ function({ onValueChange: t, className: n, value: r, min: o = 0, max: i = 100, style: s, ...u }, f) {
1378
+ const v = Number(r ?? 0), c = Number(o), l = Number(i), d = l > c ? Math.min(100, Math.max(0, (v - c) / (l - c) * 100)) : 0, x = ["j-slider", n].filter(Boolean).join(" ");
1379
1379
  return /* @__PURE__ */ a(
1380
1380
  "input",
1381
1381
  {
1382
- ref: p,
1382
+ ref: f,
1383
1383
  type: "range",
1384
- className: y,
1384
+ className: x,
1385
1385
  value: r,
1386
1386
  min: o,
1387
1387
  max: i,
1388
- style: { ...s ?? {}, "--j-slider-fill": `${f}%` },
1389
- onChange: (x) => t == null ? void 0 : t(Number(x.currentTarget.value)),
1388
+ style: { ...s ?? {}, "--j-slider-fill": `${d}%` },
1389
+ onChange: (y) => t == null ? void 0 : t(Number(y.currentTarget.value)),
1390
1390
  ...u
1391
1391
  }
1392
1392
  );
1393
1393
  }
1394
1394
  );
1395
- function pr({ className: e, style: t, ...n }) {
1395
+ function un({ className: e, style: t, ...n }) {
1396
1396
  const r = ["j-textarea", e].filter(Boolean).join(" ");
1397
1397
  return /* @__PURE__ */ a("textarea", { className: r, style: t, ...n });
1398
1398
  }
1399
- function fr({ className: e, style: t, ...n } = {}) {
1400
- const r = Yt(n), o = ["j-background-canvas", e].filter(Boolean).join(" ");
1399
+ const ze = /^[1-9A-Z]{1,8}$/, dn = /* @__PURE__ */ new Set([
1400
+ "SEED",
1401
+ "SEEDS",
1402
+ "SCORE",
1403
+ "SCORES",
1404
+ "DECK",
1405
+ "STAKE",
1406
+ "NAME",
1407
+ "ANTE",
1408
+ "ANTES",
1409
+ "TRUE",
1410
+ "FALSE",
1411
+ "NULL",
1412
+ "NAN",
1413
+ "HTTP",
1414
+ "HTTPS",
1415
+ "WWW",
1416
+ "COM",
1417
+ "APP",
1418
+ "MUST",
1419
+ "SHOULD",
1420
+ "JOKER",
1421
+ "TAG",
1422
+ "BOSS",
1423
+ "PACK",
1424
+ "SHOP",
1425
+ "CARD",
1426
+ "TALLY",
1427
+ "TALLIES"
1428
+ ]);
1429
+ function pn(e) {
1430
+ if (!e || typeof e != "string") return [];
1431
+ const n = e.toUpperCase().replace(/[A-Z]+:\/\/\S*/g, " ").replace(/0/g, "O").split(/[^0-9A-Z]+/).filter((i) => ze.test(i)), r = n.filter((i) => i.length === 8), o = r.length ? r : n.filter((i) => i.length >= 4 && !dn.has(i));
1432
+ return [...new Set(o)];
1433
+ }
1434
+ function fn(e) {
1435
+ if (!e) return [];
1436
+ const t = e.split(/\r?\n/), n = [];
1437
+ for (let r = 0; r < t.length; r++) {
1438
+ const o = t[r].trim();
1439
+ if (!o) continue;
1440
+ const i = o.split(/[^0-9A-Za-z]+/).filter(Boolean);
1441
+ for (const s of i) {
1442
+ const u = s.toUpperCase().replace(/0/g, "O");
1443
+ (!ze.test(u) || u.length < 4) && n.push({ line: r + 1, text: s });
1444
+ }
1445
+ }
1446
+ return n.slice(0, 8);
1447
+ }
1448
+ function br({
1449
+ onAnalyze: e,
1450
+ onInjectIntoJaml: t,
1451
+ ready: n = !1,
1452
+ running: r = !1,
1453
+ defaultText: o = "",
1454
+ className: i,
1455
+ style: s
1456
+ }) {
1457
+ const [u, f] = L(o), [v, c] = L(!1), l = te(() => pn(u), [u]), d = te(() => l.filter((m) => m.length === 8), [l]), x = te(() => l.filter((m) => m.length >= 4 && m.length < 8), [l]), y = te(() => fn(u), [u]), S = H(() => {
1458
+ !d.length || r || e(d);
1459
+ }, [d, r, e]), j = H(() => {
1460
+ d.length && (t == null || t(d));
1461
+ }, [d, t]), p = d.length === 0 ? "No valid 8-character seeds yet." : d.length === 1 ? "1 valid seed." : `${d.length} valid seeds.`, g = x.length > 0 ? `${x.length} partial (${x.join(", ")}) — might be typos.` : null, b = n && !r && d.length > 0, h = r ? "Cannot start: a search is already running." : n ? d.length === 0 ? "Cannot start: paste at least one 8-character seed." : null : "Cannot start: the engine is still booting.";
1462
+ return /* @__PURE__ */ _(gt, { gap: "md", align: "stretch", className: i, style: s, children: [
1463
+ /* @__PURE__ */ a(D, { children: /* @__PURE__ */ a(U, { size: "sm", tone: "white", children: "Paste a list of seeds here — one per line, comma-separated, from a spreadsheet, a chat message, or a share link. The field finds every 8-character code automatically." }) }),
1464
+ /* @__PURE__ */ a(
1465
+ un,
1466
+ {
1467
+ value: u,
1468
+ onChange: (m) => f(m.target.value),
1469
+ placeholder: `WEEJOKER
1470
+ 18Z47K9Q
1471
+ Q1J3A11E
1472
+ …`,
1473
+ spellCheck: !1,
1474
+ autoComplete: "off",
1475
+ style: { minHeight: 120, fontFamily: "m6x11, monospace", fontSize: 14 }
1476
+ }
1477
+ ),
1478
+ /* @__PURE__ */ _(Be, { gap: "sm", wrap: !0, align: "center", children: [
1479
+ /* @__PURE__ */ a(fe, { tone: d.length > 0 ? "green" : "grey", size: "sm", children: p }),
1480
+ g ? /* @__PURE__ */ _(fe, { tone: "orange", size: "sm", title: g, children: [
1481
+ x.length,
1482
+ " partial"
1483
+ ] }) : null,
1484
+ y.length > 0 ? /* @__PURE__ */ _(
1485
+ fe,
1486
+ {
1487
+ tone: "red",
1488
+ size: "sm",
1489
+ title: y.map((m) => `line ${m.line}: "${m.text}"`).join("; "),
1490
+ children: [
1491
+ y.length,
1492
+ " unrecognised"
1493
+ ]
1494
+ }
1495
+ ) : null
1496
+ ] }),
1497
+ y.length > 0 && v ? /* @__PURE__ */ a(D, { children: y.map((m) => /* @__PURE__ */ _(U, { size: "xs", tone: "red", children: [
1498
+ "Line ",
1499
+ m.line,
1500
+ ': "',
1501
+ m.text,
1502
+ '" — not a valid seed character.'
1503
+ ] }, `${m.line}-${m.text}`)) }) : null,
1504
+ y.length > 0 ? /* @__PURE__ */ a(W, { size: "xs", tone: "grey", onClick: () => c((m) => !m), children: v ? "Hide unrecognised tokens" : "Show unrecognised tokens" }) : null,
1505
+ /* @__PURE__ */ a(
1506
+ W,
1507
+ {
1508
+ fullWidth: !0,
1509
+ tone: "blue",
1510
+ disabled: !b,
1511
+ onClick: S,
1512
+ title: h || "Score every seed against the current filter",
1513
+ children: r ? "Searching…" : `Analyze ${d.length || ""} seed${d.length === 1 ? "" : "s"}`
1514
+ }
1515
+ ),
1516
+ t && d.length > 0 ? /* @__PURE__ */ a(
1517
+ W,
1518
+ {
1519
+ fullWidth: !0,
1520
+ tone: "grey",
1521
+ onClick: j,
1522
+ title: "Add these seeds to the JAML document so they are saved with the filter",
1523
+ children: "Save seeds to filter document"
1524
+ }
1525
+ ) : null,
1526
+ h && !r ? /* @__PURE__ */ a(U, { size: "xs", tone: "grey", children: h }) : null
1527
+ ] });
1528
+ }
1529
+ function vr({ className: e, style: t, ...n } = {}) {
1530
+ const r = Zt(n), o = ["j-background-canvas", e].filter(Boolean).join(" ");
1401
1531
  return /* @__PURE__ */ a("canvas", { ref: r, className: o, style: t, "aria-hidden": !0 });
1402
1532
  }
1403
- function mr({
1533
+ function jr({
1404
1534
  variant: e = "embed",
1405
1535
  scroll: t = !0,
1406
1536
  footer: n,
@@ -1409,15 +1539,15 @@ function mr({
1409
1539
  ...i
1410
1540
  }) {
1411
1541
  if (e === "page") {
1412
- const p = ["j-page", "j-page--full", r].filter(Boolean).join(" ");
1413
- return /* @__PURE__ */ _("div", { className: p, ...i, children: [
1542
+ const f = ["j-page", "j-page--full", r].filter(Boolean).join(" ");
1543
+ return /* @__PURE__ */ _("div", { className: f, ...i, children: [
1414
1544
  /* @__PURE__ */ a("div", { className: "j-page__main", children: o }),
1415
1545
  n ? /* @__PURE__ */ a("div", { className: "j-page__footer", children: n }) : null
1416
1546
  ] });
1417
1547
  }
1418
1548
  if (e === "phone") {
1419
- const p = ["j-phone", r].filter(Boolean).join(" ");
1420
- return /* @__PURE__ */ _("div", { className: p, ...i, children: [
1549
+ const f = ["j-phone", r].filter(Boolean).join(" ");
1550
+ return /* @__PURE__ */ _("div", { className: f, ...i, children: [
1421
1551
  /* @__PURE__ */ a("div", { className: t ? "j-phone__scroll" : "j-phone__content", children: o }),
1422
1552
  n ? /* @__PURE__ */ a("div", { className: "j-phone__footer", children: n }) : null
1423
1553
  ] });
@@ -1428,25 +1558,25 @@ function mr({
1428
1558
  n ? /* @__PURE__ */ a("div", { className: "j-app__footer", children: n }) : null
1429
1559
  ] });
1430
1560
  }
1431
- function hr({ className: e, children: t, ...n }) {
1561
+ function _r({ className: e, children: t, ...n }) {
1432
1562
  const r = ["j-inset", e].filter(Boolean).join(" ");
1433
1563
  return /* @__PURE__ */ a("div", { className: r, ...n, children: t });
1434
1564
  }
1435
- function gr({ title: e, sub: t, className: n, ...r }) {
1565
+ function yr({ title: e, sub: t, className: n, ...r }) {
1436
1566
  const o = ["j-wordmark", n].filter(Boolean).join(" ");
1437
1567
  return /* @__PURE__ */ _("div", { className: o, ...r, children: [
1438
1568
  /* @__PURE__ */ a("div", { className: "j-wordmark__title", children: e }),
1439
1569
  t != null && t !== !1 ? /* @__PURE__ */ a("div", { className: "j-wordmark__sub", children: t }) : null
1440
1570
  ] });
1441
1571
  }
1442
- const sn = {
1572
+ const hn = {
1443
1573
  xs: "var(--j-space-xs)",
1444
1574
  sm: "var(--j-space-sm)",
1445
1575
  md: "var(--j-space-md)",
1446
1576
  lg: "var(--j-space-lg)",
1447
1577
  xl: "var(--j-space-xl)"
1448
1578
  };
1449
- function br({ columns: e = 3, minColWidth: t, gap: n = "md", style: r, ...o }) {
1579
+ function xr({ columns: e = 3, minColWidth: t, gap: n = "md", style: r, ...o }) {
1450
1580
  const i = t ? `repeat(auto-fit, minmax(${t}px, 1fr))` : `repeat(${e}, minmax(0, 1fr))`;
1451
1581
  return /* @__PURE__ */ a(
1452
1582
  "div",
@@ -1455,31 +1585,31 @@ function br({ columns: e = 3, minColWidth: t, gap: n = "md", style: r, ...o }) {
1455
1585
  ...r,
1456
1586
  display: "grid",
1457
1587
  gridTemplateColumns: i,
1458
- gap: sn[n],
1588
+ gap: hn[n],
1459
1589
  width: "100%"
1460
1590
  },
1461
1591
  ...o
1462
1592
  }
1463
1593
  );
1464
1594
  }
1465
- function jr({ size: e = 16, style: t, ...n }) {
1595
+ function Sr({ size: e = 16, style: t, ...n }) {
1466
1596
  return /* @__PURE__ */ a("div", { "aria-hidden": !0, style: { ...t, height: e, width: "100%" }, ...n });
1467
1597
  }
1468
- function vr({ vert: e = !1, className: t, ...n }) {
1598
+ function kr({ vert: e = !1, className: t, ...n }) {
1469
1599
  const r = ["j-divider", e ? "j-divider--vert" : "", t].filter(Boolean).join(" ");
1470
1600
  return /* @__PURE__ */ a("hr", { className: r, ...n });
1471
1601
  }
1472
- function _r({ title: e, onDismiss: t, className: n, children: r, ...o }) {
1473
- const [i, s] = T(!1);
1602
+ function wr({ title: e, onDismiss: t, className: n, children: r, ...o }) {
1603
+ const [i, s] = L(!1);
1474
1604
  if (i) return null;
1475
1605
  const u = ["j-error-block", n].filter(Boolean).join(" ");
1476
- return /* @__PURE__ */ a("div", { className: u, role: "alert", ...o, children: /* @__PURE__ */ _(ft, { justify: "between", align: "center", children: [
1606
+ return /* @__PURE__ */ a("div", { className: u, role: "alert", ...o, children: /* @__PURE__ */ _(Be, { justify: "between", align: "center", children: [
1477
1607
  /* @__PURE__ */ _("div", { children: [
1478
1608
  e != null && /* @__PURE__ */ a("div", { className: "j-error-block__title", children: e }),
1479
1609
  r
1480
1610
  ] }),
1481
1611
  t && /* @__PURE__ */ a(
1482
- te,
1612
+ ne,
1483
1613
  {
1484
1614
  size: "sm",
1485
1615
  tone: "destructive",
@@ -1487,64 +1617,64 @@ function _r({ title: e, onDismiss: t, className: n, children: r, ...o }) {
1487
1617
  onClick: () => {
1488
1618
  s(!0), t();
1489
1619
  },
1490
- children: /* @__PURE__ */ a(Me, {})
1620
+ children: /* @__PURE__ */ a(De, {})
1491
1621
  }
1492
1622
  )
1493
1623
  ] }) });
1494
1624
  }
1495
- const Fe = 2 * Math.PI, Se = Math.PI / 2, F = 16, $e = 10, ze = 148, ue = 4, de = 6, Ue = 22, We = 8;
1496
- function Ge(e, t) {
1625
+ const Ue = 2 * Math.PI, Ee = Math.PI / 2, F = 16, We = 10, Ke = 148, de = 4, pe = 6, Ge = 22, Ye = 8;
1626
+ function He(e, t) {
1497
1627
  return Math.min(200, Math.max(56, 32 + (t ? 15 : 0) + e.length * 6.6));
1498
1628
  }
1499
- function ln(e, t) {
1500
- return e + $e + Math.hypot(t, F);
1629
+ function mn(e, t) {
1630
+ return e + We + Math.hypot(t, F);
1501
1631
  }
1502
- function cn(e, t, n, r, o, i, s) {
1632
+ function gn(e, t, n, r, o, i, s) {
1503
1633
  if (e.length === 0) return [];
1504
1634
  const u = Math.max(0, i) / 2;
1505
- return e.map((p, j) => {
1506
- const l = r + j * o, c = Math.cos(l) * t, f = Math.sin(l) * n, y = Math.hypot(c, f), { label: x, hasToggleDot: k } = s(p), b = ln(u, Ge(x, k) / 2);
1507
- if (y < 1e-4) return { item: p, x: b, y: 0 };
1508
- const d = Math.max(1, b / y);
1509
- return { item: p, x: c * d, y: f * d };
1635
+ return e.map((f, v) => {
1636
+ const c = r + v * o, l = Math.cos(c) * t, d = Math.sin(c) * n, x = Math.hypot(l, d), { label: y, hasToggleDot: S } = s(f), j = mn(u, He(y, S) / 2);
1637
+ if (x < 1e-4) return { item: f, x: j, y: 0 };
1638
+ const p = Math.max(1, j / x);
1639
+ return { item: f, x: l * p, y: d * p };
1510
1640
  });
1511
1641
  }
1512
- function un(e, t, n, r, o) {
1642
+ function bn(e, t, n, r, o) {
1513
1643
  if (e.length === 0) return [];
1514
- const i = t / 2, s = n / 2, u = -s + F, p = Math.min(s - F, r - F - de), j = Math.ceil(e.length / 2), l = e.length - j, c = 2 * F + de, f = (k, b) => {
1515
- if (b <= 1) return u;
1516
- const d = p - u, h = c * (b - 1) <= d ? c : d / (b - 1);
1517
- return p - k * h;
1644
+ const i = t / 2, s = n / 2, u = -s + F, f = Math.min(s - F, r - F - pe), v = Math.ceil(e.length / 2), c = e.length - v, l = 2 * F + pe, d = (S, j) => {
1645
+ if (j <= 1) return u;
1646
+ const p = f - u, b = l * (j - 1) <= p ? l : p / (j - 1);
1647
+ return f - S * b;
1518
1648
  };
1519
- let y = 0, x = 0;
1520
- return e.map((k, b) => {
1521
- const d = b < j ? -1 : 1, g = d < 0 ? f(y++, j) : f(x++, l), { label: h, hasToggleDot: m } = o(k), v = Ge(h, m) / 2;
1522
- return { item: k, x: d * Math.max(0, i - v - ue), y: g };
1649
+ let x = 0, y = 0;
1650
+ return e.map((S, j) => {
1651
+ const p = j < v ? -1 : 1, g = p < 0 ? d(x++, v) : d(y++, c), { label: b, hasToggleDot: h } = o(S), m = He(b, h) / 2;
1652
+ return { item: S, x: p * Math.max(0, i - m - de), y: g };
1523
1653
  });
1524
1654
  }
1525
- function dn(e) {
1655
+ function vn(e) {
1526
1656
  if (!Number.isFinite(e) || e <= 0) return 2;
1527
- const t = e / 2, n = -t + F, o = t - F - ue - Ue - F - F - de, i = 2 * F + de;
1657
+ const t = e / 2, n = -t + F, o = t - F - de - Ge - F - F - pe, i = 2 * F + pe;
1528
1658
  return 2 * Math.max(1, Math.floor((o - n) / i) + 1);
1529
1659
  }
1530
- function pn(e, t, n) {
1531
- const r = e <= 1 ? Math.round(2 * t * 1.05) : Math.round(2 * t * Math.sin(Fe / e / 2) * 1.28);
1532
- return Math.max(ze, Math.min(r, n - 16));
1660
+ function jn(e, t, n) {
1661
+ const r = e <= 1 ? Math.round(2 * t * 1.05) : Math.round(2 * t * Math.sin(Ue / e / 2) * 1.28);
1662
+ return Math.max(Ke, Math.min(r, n - 16));
1533
1663
  }
1534
- function fn(e, t, n) {
1664
+ function _n(e, t, n) {
1535
1665
  return Math.max(84, n + t * 3, e / 2 + 42);
1536
1666
  }
1537
- function yr(e, t) {
1538
- return Math.max(0, Math.min(e, t) / 2 - F - We);
1667
+ function Er(e, t) {
1668
+ return Math.max(0, Math.min(e, t) / 2 - F - Ye);
1539
1669
  }
1540
- function mn(e, t, n) {
1541
- return n == null || !Number.isFinite(n) || n <= 0 ? e : Math.max(t / 2 + $e, Math.min(e, n));
1670
+ function yn(e, t, n) {
1671
+ return n == null || !Number.isFinite(n) || n <= 0 ? e : Math.max(t / 2 + We, Math.min(e, n));
1542
1672
  }
1543
- const Ke = (e) => typeof e.active == "boolean", we = (e) => ({
1673
+ const Xe = (e) => typeof e.active == "boolean", Ne = (e) => ({
1544
1674
  label: e.label,
1545
- hasToggleDot: Ke(e)
1675
+ hasToggleDot: Xe(e)
1546
1676
  });
1547
- function hn({
1677
+ function xn({
1548
1678
  items: e,
1549
1679
  onAction: t,
1550
1680
  onNavigate: n,
@@ -1553,83 +1683,83 @@ function hn({
1553
1683
  closing: i = !1,
1554
1684
  mascotSize: s = 96,
1555
1685
  radius: u = 90,
1556
- radiusY: p,
1557
- boxHeight: j,
1558
- translateY: l = 0,
1559
- breadcrumb: c,
1560
- showPageControls: f = !1,
1561
- onPagePrev: y,
1562
- onPageNext: x,
1563
- center: k,
1564
- className: b,
1565
- "aria-label": d = "Orbital menu"
1686
+ radiusY: f,
1687
+ boxHeight: v,
1688
+ translateY: c = 0,
1689
+ breadcrumb: l,
1690
+ showPageControls: d = !1,
1691
+ onPagePrev: x,
1692
+ onPageNext: y,
1693
+ center: S,
1694
+ className: j,
1695
+ "aria-label": p = "Orbital menu"
1566
1696
  }) {
1567
- const g = J(null), [h, m] = T(375);
1568
- if (W(() => {
1569
- const A = g.current;
1570
- if (!A) return;
1571
- const X = () => m(Math.max(1, A.clientWidth));
1697
+ const g = $(null), [b, h] = L(375);
1698
+ if (G(() => {
1699
+ const T = g.current;
1700
+ if (!T) return;
1701
+ const X = () => h(Math.max(1, T.clientWidth));
1572
1702
  X();
1573
- const q = new ResizeObserver(X);
1574
- return q.observe(A), () => q.disconnect();
1703
+ const Q = new ResizeObserver(X);
1704
+ return Q.observe(T), () => Q.disconnect();
1575
1705
  }, []), e.length === 0)
1576
- return k ? /* @__PURE__ */ a(
1706
+ return S ? /* @__PURE__ */ a(
1577
1707
  "div",
1578
1708
  {
1579
1709
  ref: g,
1580
- className: ["j-orbital-menu", b].filter(Boolean).join(" "),
1581
- style: { transform: `translateY(${l}px)` },
1582
- children: /* @__PURE__ */ a("div", { className: "j-orbital-menu__center", children: k })
1710
+ className: ["j-orbital-menu", j].filter(Boolean).join(" "),
1711
+ style: { transform: `translateY(${c}px)` },
1712
+ children: /* @__PURE__ */ a("div", { className: "j-orbital-menu__center", children: S })
1583
1713
  }
1584
1714
  ) : null;
1585
- const v = u, S = p ?? u, E = e.find((A) => A.south) ?? null, M = e.filter((A) => !A.south), R = M.length + (E ? 1 : 0), w = Fe / R, P = E ? Se + w : Se, N = j != null && Number.isFinite(j) && j > 0, L = N ? Math.max(ze, h - ue * 2) : pn(R, v, h), C = N ? j / 2 - F - ue : S + We, U = Math.min(96, Math.max(56, Math.floor(L * 0.5))), B = C - Ue, ne = (f && E ? B : C) - F, O = N && j != null ? un(M, h, j, ne, we) : cn(M, v, S, P, w, s, we), ae = (A) => (X) => {
1586
- X.stopPropagation(), A.south ? r == null || r() : A.submenu ? n == null || n(A.submenu) : A.action && (t == null || t(A.action, A));
1715
+ const m = u, k = f ?? u, N = e.find((T) => T.south) ?? null, M = e.filter((T) => !T.south), R = M.length + (N ? 1 : 0), w = Ue / R, P = N ? Ee + w : Ee, E = v != null && Number.isFinite(v) && v > 0, C = E ? Math.max(Ke, b - de * 2) : jn(R, m, b), A = E ? v / 2 - F - de : k + Ye, K = Math.min(96, Math.max(56, Math.floor(C * 0.5))), B = A - Ge, re = (d && N ? B : A) - F, O = E && v != null ? bn(M, b, v, re, Ne) : gn(M, m, k, P, w, s, Ne), ie = (T) => (X) => {
1716
+ X.stopPropagation(), T.south ? r == null || r() : T.submenu ? n == null || n(T.submenu) : T.action && (t == null || t(T.action, T));
1587
1717
  };
1588
1718
  return /* @__PURE__ */ _(
1589
1719
  "div",
1590
1720
  {
1591
1721
  ref: g,
1592
- className: ["j-orbital-menu", b].filter(Boolean).join(" "),
1593
- style: { transform: `translateY(${l}px)` },
1722
+ className: ["j-orbital-menu", j].filter(Boolean).join(" "),
1723
+ style: { transform: `translateY(${c}px)` },
1594
1724
  children: [
1595
- k ? /* @__PURE__ */ a("div", { className: "j-orbital-menu__center", children: k }) : null,
1596
- /* @__PURE__ */ _("div", { className: "j-orbital-menu__anchor", role: "menu", "aria-label": d, children: [
1597
- c ? /* @__PURE__ */ a(oe, { x: 0, y: C - 46, hiding: i, interactive: !1, children: c }) : null,
1598
- O.map(({ item: A, x: X, y: q }, H) => /* @__PURE__ */ a(
1599
- oe,
1725
+ S ? /* @__PURE__ */ a("div", { className: "j-orbital-menu__center", children: S }) : null,
1726
+ /* @__PURE__ */ _("div", { className: "j-orbital-menu__anchor", role: "menu", "aria-label": p, children: [
1727
+ l ? /* @__PURE__ */ a(ae, { x: 0, y: A - 46, hiding: i, interactive: !1, children: l }) : null,
1728
+ O.map(({ item: T, x: X, y: Q }, Z) => /* @__PURE__ */ a(
1729
+ ae,
1600
1730
  {
1601
1731
  x: X,
1602
- y: q,
1732
+ y: Q,
1603
1733
  hiding: i,
1604
- dim: A.dim,
1605
- children: /* @__PURE__ */ a(gn, { item: A, onClick: ae(A) })
1734
+ dim: T.dim,
1735
+ children: /* @__PURE__ */ a(Sn, { item: T, onClick: ie(T) })
1606
1736
  },
1607
- `${o}-${A.label}-${H}`
1737
+ `${o}-${T.label}-${Z}`
1608
1738
  )),
1609
- E ? /* @__PURE__ */ a(oe, { x: 0, y: C, hiding: i, children: /* @__PURE__ */ a(
1610
- Y,
1739
+ N ? /* @__PURE__ */ a(ae, { x: 0, y: A, hiding: i, children: /* @__PURE__ */ a(
1740
+ W,
1611
1741
  {
1612
- tone: E.tone ?? "orange",
1742
+ tone: N.tone ?? "orange",
1613
1743
  size: "sm",
1614
1744
  fullWidth: !0,
1615
1745
  className: "j-orbital-btn j-orbital-btn--south",
1616
- style: { width: L },
1617
- title: E.tooltip ?? E.label,
1618
- onClick: ae(E),
1746
+ style: { width: C },
1747
+ title: N.tooltip ?? N.label,
1748
+ onClick: ie(N),
1619
1749
  role: "menuitem",
1620
- children: E.label
1750
+ children: N.label
1621
1751
  }
1622
1752
  ) }) : null,
1623
- E && f ? /* @__PURE__ */ _(Xe, { children: [
1624
- /* @__PURE__ */ a(oe, { x: -(L / 2) + U / 2, y: B, hiding: i, children: /* @__PURE__ */ a(Ne, { label: "<", title: "Previous page", width: U, onClick: y }) }),
1625
- /* @__PURE__ */ a(oe, { x: L / 2 - U / 2, y: B, hiding: i, children: /* @__PURE__ */ a(Ne, { label: ">", title: "Next page", width: U, onClick: x }) })
1753
+ N && d ? /* @__PURE__ */ _(Ve, { children: [
1754
+ /* @__PURE__ */ a(ae, { x: -(C / 2) + K / 2, y: B, hiding: i, children: /* @__PURE__ */ a(Ae, { label: "<", title: "Previous page", width: K, onClick: x }) }),
1755
+ /* @__PURE__ */ a(ae, { x: C / 2 - K / 2, y: B, hiding: i, children: /* @__PURE__ */ a(Ae, { label: ">", title: "Next page", width: K, onClick: y }) })
1626
1756
  ] }) : null
1627
1757
  ] })
1628
1758
  ]
1629
1759
  }
1630
1760
  );
1631
1761
  }
1632
- function oe({
1762
+ function ae({
1633
1763
  x: e,
1634
1764
  y: t,
1635
1765
  hiding: n,
@@ -1652,15 +1782,15 @@ function oe({
1652
1782
  }
1653
1783
  );
1654
1784
  }
1655
- function gn({
1785
+ function Sn({
1656
1786
  item: e,
1657
1787
  onClick: t
1658
1788
  }) {
1659
1789
  if (e.badge)
1660
- return /* @__PURE__ */ a(an, { status: e.badge.status, label: e.badge.label, title: e.tooltip });
1661
- const n = Ke(e);
1790
+ return /* @__PURE__ */ a(cn, { status: e.badge.status, label: e.badge.label, title: e.tooltip });
1791
+ const n = Xe(e);
1662
1792
  return /* @__PURE__ */ _(
1663
- Y,
1793
+ W,
1664
1794
  {
1665
1795
  tone: e.tone ?? (n ? "orange" : "red"),
1666
1796
  size: "sm",
@@ -1679,14 +1809,14 @@ function gn({
1679
1809
  }
1680
1810
  );
1681
1811
  }
1682
- function Ne({
1812
+ function Ae({
1683
1813
  label: e,
1684
1814
  title: t,
1685
1815
  width: n,
1686
1816
  onClick: r
1687
1817
  }) {
1688
1818
  return /* @__PURE__ */ a(
1689
- Y,
1819
+ W,
1690
1820
  {
1691
1821
  tone: "blue",
1692
1822
  size: "sm",
@@ -1701,70 +1831,70 @@ function Ne({
1701
1831
  }
1702
1832
  );
1703
1833
  }
1704
- const Ee = 200, bn = 320, ie = { stack: [], page: 0, breadcrumb: [], closing: !1 };
1705
- function Ye() {
1706
- let e = ie, t = -1, n = 0, r = null;
1707
- const o = /* @__PURE__ */ new Set(), i = () => o.forEach((l) => l()), s = (l) => {
1708
- e = { ...e, ...l }, i();
1834
+ const Ce = 200, kn = 320, se = { stack: [], page: 0, breadcrumb: [], closing: !1 };
1835
+ function Ze() {
1836
+ let e = se, t = -1, n = 0, r = null;
1837
+ const o = /* @__PURE__ */ new Set(), i = () => o.forEach((c) => c()), s = (c) => {
1838
+ e = { ...e, ...c }, i();
1709
1839
  }, u = () => {
1710
1840
  r !== null && (clearTimeout(r), r = null);
1711
- }, p = (l, c) => {
1841
+ }, f = (c, l) => {
1712
1842
  u(), r = setTimeout(() => {
1713
- r = null, l();
1714
- }, c);
1715
- }, j = () => {
1716
- u(), s({ closing: !0 }), p(() => s({ ...ie }), bn);
1843
+ r = null, c();
1844
+ }, l);
1845
+ }, v = () => {
1846
+ u(), s({ closing: !0 }), f(() => s({ ...se }), kn);
1717
1847
  };
1718
1848
  return {
1719
- subscribe: (l) => (o.add(l), () => o.delete(l)),
1849
+ subscribe: (c) => (o.add(c), () => o.delete(c)),
1720
1850
  getState: () => e,
1721
- open: (l = "main") => {
1722
- e.stack.length === 1 && e.stack[0] === l && e.page === 0 || (u(), s({ stack: [l], page: 0, breadcrumb: [], closing: !1 }));
1851
+ open: (c = "main") => {
1852
+ e.stack.length === 1 && e.stack[0] === c && e.page === 0 || (u(), s({ stack: [c], page: 0, breadcrumb: [], closing: !1 }));
1723
1853
  },
1724
- close: j,
1854
+ close: v,
1725
1855
  back: () => {
1726
1856
  if (e.stack.length <= 1) {
1727
- s({ breadcrumb: [] }), j();
1857
+ s({ breadcrumb: [] }), v();
1728
1858
  return;
1729
1859
  }
1730
- u(), s({ breadcrumb: e.breadcrumb.slice(0, -1), closing: !0 }), p(
1860
+ u(), s({ breadcrumb: e.breadcrumb.slice(0, -1), closing: !0 }), f(
1731
1861
  () => s({ stack: e.stack.slice(0, -1), page: 0, closing: !1 }),
1732
- Ee
1862
+ Ce
1733
1863
  );
1734
1864
  },
1735
- navigateTo: (l) => {
1736
- u(), s({ breadcrumb: [...e.breadcrumb, l], closing: !0 }), p(
1737
- () => s({ stack: [...e.stack, l], page: 0, closing: !1 }),
1738
- Ee
1865
+ navigateTo: (c) => {
1866
+ u(), s({ breadcrumb: [...e.breadcrumb, c], closing: !0 }), f(
1867
+ () => s({ stack: [...e.stack, c], page: 0, closing: !1 }),
1868
+ Ce
1739
1869
  );
1740
1870
  },
1741
- nextPage: (l) => {
1742
- const c = Math.max(1, l);
1743
- s({ page: c <= 1 ? 0 : (e.page + 1) % c });
1871
+ nextPage: (c) => {
1872
+ const l = Math.max(1, c);
1873
+ s({ page: l <= 1 ? 0 : (e.page + 1) % l });
1744
1874
  },
1745
- prevPage: (l) => {
1746
- const c = Math.max(1, l);
1747
- s({ page: c <= 1 ? 0 : (e.page - 1 + c) % c });
1875
+ prevPage: (c) => {
1876
+ const l = Math.max(1, c);
1877
+ s({ page: l <= 1 ? 0 : (e.page - 1 + l) % l });
1748
1878
  },
1749
1879
  reset: () => {
1750
- u(), t = -1, n = 0, s({ ...ie });
1880
+ u(), t = -1, n = 0, s({ ...se });
1751
1881
  },
1752
- signalIncomingResults: ({ count: l, topScore: c }) => {
1753
- let f = !1;
1754
- l > 0 && c !== void 0 && c > t && (f = e.stack.length > 1), l > 0 && l > n && (f = f || e.stack.length > 0), t = l > 0 && c !== void 0 ? c : -1, n = l, f && j();
1882
+ signalIncomingResults: ({ count: c, topScore: l }) => {
1883
+ let d = !1;
1884
+ c > 0 && l !== void 0 && l > t && (d = e.stack.length > 1), c > 0 && c > n && (d = d || e.stack.length > 0), t = c > 0 && l !== void 0 ? l : -1, n = c, d && v();
1755
1885
  }
1756
1886
  };
1757
1887
  }
1758
- const jn = Ye();
1759
- function vn({
1888
+ const wn = Ze();
1889
+ function En({
1760
1890
  root: e = "main",
1761
- store: t = jn
1891
+ store: t = wn
1762
1892
  } = {}) {
1763
- const n = Ze(t.subscribe, t.getState, () => ie), r = Q(() => t.open(e), [t, e]), o = Q(() => {
1893
+ const n = Qe(t.subscribe, t.getState, () => se), r = H(() => t.open(e), [t, e]), o = H(() => {
1764
1894
  const { stack: i, closing: s } = t.getState();
1765
1895
  i.length === 0 && !s ? t.open(e) : t.close();
1766
1896
  }, [t, e]);
1767
- return Pe(
1897
+ return te(
1768
1898
  () => ({
1769
1899
  ...n,
1770
1900
  currentMenu: n.stack.at(-1) ?? e,
@@ -1782,17 +1912,17 @@ function vn({
1782
1912
  [n, e, r, o, t]
1783
1913
  );
1784
1914
  }
1785
- const _n = new URL("../assets/jammy-seed-mascot-BdoW3O33.png", import.meta.url).href, yn = _n;
1786
- function xn(e) {
1915
+ const Nn = new URL("../assets/jammy-seed-mascot-BdoW3O33.png", import.meta.url).href, An = Nn;
1916
+ function Cn(e) {
1787
1917
  return (t) => {
1788
1918
  (t.key === "Enter" || t.key === " ") && (t.preventDefault(), e());
1789
1919
  };
1790
1920
  }
1791
- const Ce = 14;
1792
- function kn(e) {
1793
- return e == null || !Number.isFinite(e) || e <= 0 ? Ce : Math.max(2, Math.min(Ce, dn(e)));
1921
+ const Te = 14;
1922
+ function Tn(e) {
1923
+ return e == null || !Number.isFinite(e) || e <= 0 ? Te : Math.max(2, Math.min(Te, vn(e)));
1794
1924
  }
1795
- function xr({
1925
+ function Nr({
1796
1926
  mood: e = "idle",
1797
1927
  size: t = 96,
1798
1928
  menuItems: n,
@@ -1801,48 +1931,48 @@ function xr({
1801
1931
  maxOrbitRadius: i,
1802
1932
  orbitBoxHeight: s,
1803
1933
  orbitBoxWidth: u,
1804
- baseOrbitRadius: p = 90,
1805
- menuHidden: j = !1,
1806
- closeLabel: l = "Close",
1807
- orbitalStore: c,
1808
- renderImage: f,
1809
- className: y = "",
1810
- ...x
1934
+ baseOrbitRadius: f = 90,
1935
+ menuHidden: v = !1,
1936
+ closeLabel: c = "Close",
1937
+ orbitalStore: l,
1938
+ renderImage: d,
1939
+ className: x = "",
1940
+ ...y
1811
1941
  }) {
1812
- const [k] = T(Ye), b = vn({ store: c ?? k }), d = Pe(
1942
+ const [S] = L(Ze), j = En({ store: l ?? S }), p = te(
1813
1943
  () => r ?? (n ? () => n : null),
1814
1944
  [r, n]
1815
- ), g = d != null && !j, h = () => {
1816
- g && b.toggle();
1817
- }, m = e === "happy" ? "jammy-happy" : e === "surprised" ? "jammy-shake" : "jammy-idle", v = g && (b.isOpen || b.isClosing), S = v && d ? d(b.stack) : [], E = kn(s), M = Math.max(1, Math.ceil(S.length / E)), R = Math.min(Math.max(0, b.page), M - 1), w = S.slice(R * E, (R + 1) * E), P = {
1818
- label: b.canGoBack ? "Back" : l,
1945
+ ), g = p != null && !v, b = () => {
1946
+ g && j.toggle();
1947
+ }, h = e === "happy" ? "jammy-happy" : e === "surprised" ? "jammy-shake" : "jammy-idle", m = g && (j.isOpen || j.isClosing), k = m && p ? p(j.stack) : [], N = Tn(s), M = Math.max(1, Math.ceil(k.length / N)), R = Math.min(Math.max(0, j.page), M - 1), w = k.slice(R * N, (R + 1) * N), P = {
1948
+ label: j.canGoBack ? "Back" : c,
1819
1949
  south: !0
1820
- }, N = v ? [...w, P] : [], L = mn(
1821
- fn(t, w.length, p),
1950
+ }, E = m ? [...w, P] : [], C = yn(
1951
+ _n(t, w.length, f),
1822
1952
  t,
1823
1953
  i
1824
- ), C = /* @__PURE__ */ a(
1954
+ ), A = /* @__PURE__ */ a(
1825
1955
  "div",
1826
1956
  {
1827
1957
  role: g ? "button" : void 0,
1828
1958
  tabIndex: g ? 0 : void 0,
1829
- onClick: h,
1830
- onKeyDown: g ? xn(h) : void 0,
1959
+ onClick: b,
1960
+ onKeyDown: g ? Cn(b) : void 0,
1831
1961
  "aria-label": "Jammy mascot",
1832
- "aria-expanded": g ? b.isOpen : void 0,
1962
+ "aria-expanded": g ? j.isOpen : void 0,
1833
1963
  className: g ? "j-mascot__hit j-mascot__hit--interactive" : "j-mascot__hit",
1834
- children: f ? f({ size: t }) : /* @__PURE__ */ a("img", { src: yn, alt: "Jammy", draggable: !1, className: "j-mascot__img" })
1964
+ children: d ? d({ size: t }) : /* @__PURE__ */ a("img", { src: An, alt: "Jammy", draggable: !1, className: "j-mascot__img" })
1835
1965
  }
1836
1966
  );
1837
1967
  return /* @__PURE__ */ _(
1838
1968
  "div",
1839
1969
  {
1840
- className: ["j-mascot", m, y].filter(Boolean).join(" "),
1970
+ className: ["j-mascot", h, x].filter(Boolean).join(" "),
1841
1971
  style: { "--j-mascot-size": `${t}px` },
1842
- ...x,
1972
+ ...y,
1843
1973
  children: [
1844
- C,
1845
- v ? /* @__PURE__ */ a(
1974
+ A,
1975
+ m ? /* @__PURE__ */ a(
1846
1976
  "div",
1847
1977
  {
1848
1978
  className: "j-mascot__orbit",
@@ -1851,22 +1981,22 @@ function xr({
1851
1981
  "--j-orbit-h": s != null ? `${s}px` : void 0
1852
1982
  },
1853
1983
  children: /* @__PURE__ */ a(
1854
- hn,
1984
+ xn,
1855
1985
  {
1856
- items: N,
1857
- currentMenu: b.currentMenu,
1858
- closing: b.isClosing,
1986
+ items: E,
1987
+ currentMenu: j.currentMenu,
1988
+ closing: j.isClosing,
1859
1989
  mascotSize: t,
1860
- radius: L,
1990
+ radius: C,
1861
1991
  boxHeight: s,
1862
- showPageControls: S.length > E,
1863
- onPagePrev: () => b.prevPage(M),
1864
- onPageNext: () => b.nextPage(M),
1865
- breadcrumb: b.breadcrumb.length > 0 ? /* @__PURE__ */ a(K, { size: "xs", tone: "grey", children: b.breadcrumb.join(" / ") }) : null,
1866
- onNavigate: b.navigateTo,
1867
- onBack: b.back,
1868
- onAction: (U, B) => {
1869
- o == null || o(U, B), b.close();
1992
+ showPageControls: k.length > N,
1993
+ onPagePrev: () => j.prevPage(M),
1994
+ onPageNext: () => j.nextPage(M),
1995
+ breadcrumb: j.breadcrumb.length > 0 ? /* @__PURE__ */ a(U, { size: "xs", tone: "grey", children: j.breadcrumb.join(" / ") }) : null,
1996
+ onNavigate: j.navigateTo,
1997
+ onBack: j.back,
1998
+ onAction: (K, B) => {
1999
+ o == null || o(K, B), j.close();
1870
2000
  }
1871
2001
  }
1872
2002
  )
@@ -1876,43 +2006,43 @@ function xr({
1876
2006
  }
1877
2007
  );
1878
2008
  }
1879
- const Le = 3, pe = 220;
1880
- function kr({
2009
+ const Le = 3, he = 220;
2010
+ function Ar({
1881
2011
  children: e,
1882
2012
  onDecide: t,
1883
2013
  width: n = 300,
1884
2014
  height: r = 420,
1885
2015
  threshold: o = 90
1886
2016
  }) {
1887
- const i = Ve.toArray(e), [s, u] = T(0), [p, j] = T(0), [l, c] = T(!1), [f, y] = T(null), [x, k] = T([]), b = J(0), d = J(null);
1888
- W(
2017
+ const i = et.toArray(e), [s, u] = L(0), [f, v] = L(0), [c, l] = L(!1), [d, x] = L(null), [y, S] = L([]), j = $(0), p = $(null);
2018
+ G(
1889
2019
  () => () => {
1890
- d.current && clearTimeout(d.current);
2020
+ p.current && clearTimeout(p.current);
1891
2021
  },
1892
2022
  []
1893
2023
  );
1894
- const g = i.length - s, h = Q(
1895
- (N) => {
1896
- if (f || s >= i.length) return;
1897
- const L = s;
1898
- y(N), c(!1), t == null || t(L, N), d.current = setTimeout(() => {
1899
- k((C) => [...C, { index: L, direction: N }]), u(L + 1), y(null), j(0);
1900
- }, pe);
2024
+ const g = i.length - s, b = H(
2025
+ (E) => {
2026
+ if (d || s >= i.length) return;
2027
+ const C = s;
2028
+ x(E), l(!1), t == null || t(C, E), p.current = setTimeout(() => {
2029
+ S((A) => [...A, { index: C, direction: E }]), u(C + 1), x(null), v(0);
2030
+ }, he);
1901
2031
  },
1902
- [i.length, s, f, t]
1903
- ), m = Q(() => {
1904
- if (f || x.length === 0) return;
1905
- const N = x[x.length - 1];
1906
- k((L) => L.slice(0, -1)), u(N.index), j(0);
1907
- }, [f, x]), v = (N) => {
1908
- f || (N.currentTarget.setPointerCapture(N.pointerId), b.current = N.clientX, c(!0));
1909
- }, S = (N) => {
1910
- !l || f || j(N.clientX - b.current);
1911
- }, E = () => {
1912
- !l || f || (c(!1), Math.abs(p) >= o ? h(p > 0 ? "keep" : "pass") : j(0));
1913
- }, M = (N) => {
1914
- N.key === "ArrowRight" && h("keep"), N.key === "ArrowLeft" && h("pass"), N.key === "Backspace" && m();
1915
- }, R = f ? f === "keep" ? n * 2 : -n * 2 : p, w = Math.max(-14, Math.min(14, R * 0.05)), P = Math.abs(p) >= o ? p > 0 ? "keep" : "pass" : null;
2032
+ [i.length, s, d, t]
2033
+ ), h = H(() => {
2034
+ if (d || y.length === 0) return;
2035
+ const E = y[y.length - 1];
2036
+ S((C) => C.slice(0, -1)), u(E.index), v(0);
2037
+ }, [d, y]), m = (E) => {
2038
+ d || (E.currentTarget.setPointerCapture(E.pointerId), j.current = E.clientX, l(!0));
2039
+ }, k = (E) => {
2040
+ !c || d || v(E.clientX - j.current);
2041
+ }, N = () => {
2042
+ !c || d || (l(!1), Math.abs(f) >= o ? b(f > 0 ? "keep" : "pass") : v(0));
2043
+ }, M = (E) => {
2044
+ E.key === "ArrowRight" && b("keep"), E.key === "ArrowLeft" && b("pass"), E.key === "Backspace" && h();
2045
+ }, R = d ? d === "keep" ? n * 2 : -n * 2 : f, w = Math.max(-14, Math.min(14, R * 0.05)), P = Math.abs(f) >= o ? f > 0 ? "keep" : "pass" : null;
1916
2046
  return /* @__PURE__ */ _(
1917
2047
  "div",
1918
2048
  {
@@ -1938,29 +2068,29 @@ function kr({
1938
2068
  outline: "none"
1939
2069
  },
1940
2070
  children: [
1941
- g === 0 ? /* @__PURE__ */ a("div", { style: { position: "absolute", inset: 0, display: "grid", placeItems: "center" }, children: /* @__PURE__ */ a(K, { size: "sm", tone: "grey", children: "No seeds left" }) }) : null,
1942
- i.slice(s, s + Le).map((N, L) => {
1943
- const C = L === 0, U = C ? `translate3d(${R}px, 0, 0) rotate(${w}deg)` : `translate3d(0, ${L * 9}px, 0) scale(${1 - L * 0.045})`;
2071
+ g === 0 ? /* @__PURE__ */ a("div", { style: { position: "absolute", inset: 0, display: "grid", placeItems: "center" }, children: /* @__PURE__ */ a(U, { size: "sm", tone: "grey", children: "No seeds left" }) }) : null,
2072
+ i.slice(s, s + Le).map((E, C) => {
2073
+ const A = C === 0, K = A ? `translate3d(${R}px, 0, 0) rotate(${w}deg)` : `translate3d(0, ${C * 9}px, 0) scale(${1 - C * 0.045})`;
1944
2074
  return /* @__PURE__ */ _(
1945
2075
  "div",
1946
2076
  {
1947
- onPointerDown: C ? v : void 0,
1948
- onPointerMove: C ? S : void 0,
1949
- onPointerUp: C ? E : void 0,
1950
- onPointerCancel: C ? E : void 0,
2077
+ onPointerDown: A ? m : void 0,
2078
+ onPointerMove: A ? k : void 0,
2079
+ onPointerUp: A ? N : void 0,
2080
+ onPointerCancel: A ? N : void 0,
1951
2081
  style: {
1952
2082
  position: "absolute",
1953
2083
  inset: 0,
1954
- zIndex: Le - L,
1955
- transform: U,
1956
- transition: l && C ? "none" : `transform ${pe}ms ease-out, opacity ${pe}ms ease-out`,
1957
- opacity: C && f ? 0 : 1,
1958
- cursor: C ? l ? "grabbing" : "grab" : "default",
2084
+ zIndex: Le - C,
2085
+ transform: K,
2086
+ transition: c && A ? "none" : `transform ${he}ms ease-out, opacity ${he}ms ease-out`,
2087
+ opacity: A && d ? 0 : 1,
2088
+ cursor: A ? c ? "grabbing" : "grab" : "default",
1959
2089
  overflow: "hidden"
1960
2090
  },
1961
2091
  children: [
1962
- N,
1963
- C && P ? /* @__PURE__ */ a(
2092
+ E,
2093
+ A && P ? /* @__PURE__ */ a(
1964
2094
  "div",
1965
2095
  {
1966
2096
  style: {
@@ -1974,12 +2104,12 @@ function kr({
1974
2104
  transform: `rotate(${P === "keep" ? -8 : 8}deg)`,
1975
2105
  pointerEvents: "none"
1976
2106
  },
1977
- children: /* @__PURE__ */ a(K, { size: "xs", tone: P === "keep" ? "green" : "red", children: P === "keep" ? "Keep" : "Pass" })
2107
+ children: /* @__PURE__ */ a(U, { size: "xs", tone: P === "keep" ? "green" : "red", children: P === "keep" ? "Keep" : "Pass" })
1978
2108
  }
1979
2109
  ) : null
1980
2110
  ]
1981
2111
  },
1982
- s + L
2112
+ s + C
1983
2113
  );
1984
2114
  })
1985
2115
  ]
@@ -1987,39 +2117,39 @@ function kr({
1987
2117
  ),
1988
2118
  /* @__PURE__ */ _("div", { style: { display: "grid", gridAutoFlow: "column", gap: 16, alignItems: "center" }, children: [
1989
2119
  /* @__PURE__ */ a(
1990
- te,
2120
+ ne,
1991
2121
  {
1992
2122
  "aria-label": "Pass",
1993
2123
  title: "Pass (left arrow)",
1994
2124
  tone: "destructive",
1995
- onClick: () => h("pass"),
2125
+ onClick: () => b("pass"),
1996
2126
  disabled: g === 0,
1997
- children: /* @__PURE__ */ a(Me, {})
2127
+ children: /* @__PURE__ */ a(De, {})
1998
2128
  }
1999
2129
  ),
2000
2130
  /* @__PURE__ */ a(
2001
- te,
2131
+ ne,
2002
2132
  {
2003
2133
  "aria-label": "Undo",
2004
2134
  title: "Undo (backspace)",
2005
2135
  size: "sm",
2006
- onClick: m,
2007
- disabled: x.length === 0,
2008
- children: /* @__PURE__ */ a(yt, {})
2136
+ onClick: h,
2137
+ disabled: y.length === 0,
2138
+ children: /* @__PURE__ */ a(kt, {})
2009
2139
  }
2010
2140
  ),
2011
2141
  /* @__PURE__ */ a(
2012
- te,
2142
+ ne,
2013
2143
  {
2014
2144
  "aria-label": "Keep",
2015
2145
  title: "Keep (right arrow)",
2016
- onClick: () => h("keep"),
2146
+ onClick: () => b("keep"),
2017
2147
  disabled: g === 0,
2018
- children: /* @__PURE__ */ a(Oe, {})
2148
+ children: /* @__PURE__ */ a(Ie, {})
2019
2149
  }
2020
2150
  )
2021
2151
  ] }),
2022
- /* @__PURE__ */ _(K, { size: "micro", tone: "grey", children: [
2152
+ /* @__PURE__ */ _(U, { size: "micro", tone: "grey", children: [
2023
2153
  g,
2024
2154
  " of ",
2025
2155
  i.length,
@@ -2030,93 +2160,94 @@ function kr({
2030
2160
  );
2031
2161
  }
2032
2162
  export {
2033
- $e as $,
2034
- de as A,
2035
- Zn as B,
2036
- rr as C,
2037
- er as D,
2038
- Qn as E,
2039
- Fe as F,
2040
- tr as G,
2041
- nr as H,
2042
- qn as I,
2043
- $n as J,
2044
- Vn as K,
2045
- ft as L,
2046
- ct as M,
2047
- On as N,
2163
+ yr as $,
2164
+ pe as A,
2165
+ tr as B,
2166
+ lr as C,
2167
+ ar as D,
2168
+ or as E,
2169
+ Ue as F,
2170
+ ir as G,
2171
+ sr as H,
2172
+ rr as I,
2173
+ Yn as J,
2174
+ nr as K,
2175
+ Be as L,
2176
+ pt as M,
2177
+ br as N,
2048
2178
  zn as O,
2049
- dr as P,
2050
- jr as Q,
2051
- Jn as R,
2052
- Hn as S,
2053
- An as T,
2054
- an as U,
2055
- kr as V,
2056
- or as W,
2057
- K as X,
2058
- pr as Y,
2059
- Kn as Z,
2060
- gr as _,
2061
- mr as a,
2062
- ze as a0,
2063
- bn as a1,
2064
- Ee as a2,
2065
- Ue as a3,
2066
- F as a4,
2067
- Se as a5,
2068
- ue as a6,
2069
- We as a7,
2070
- dn as a8,
2071
- mn as a9,
2072
- Ye as aa,
2073
- Qt as ab,
2074
- en as ac,
2075
- Ge as ad,
2076
- jn as ae,
2077
- un as af,
2078
- cn as ag,
2079
- yr as ah,
2080
- ln as ai,
2081
- fn as aj,
2082
- pn as ak,
2083
- vn as al,
2084
- ir as am,
2085
- Fn as an,
2086
- I as ao,
2087
- Pn as ap,
2088
- Oe as aq,
2089
- Bn as ar,
2090
- Tn as as,
2091
- Me as at,
2092
- Rn as au,
2093
- Mn as av,
2094
- wt as aw,
2095
- sr as ax,
2096
- fr as b,
2097
- Un as c,
2098
- $ as d,
2099
- Y as e,
2100
- Cn as f,
2101
- cr as g,
2102
- At as h,
2103
- vr as i,
2104
- ur as j,
2105
- _r as k,
2106
- Yn as l,
2107
- br as m,
2108
- te as n,
2109
- Wn as o,
2110
- lr as p,
2111
- In as q,
2112
- hr as r,
2113
- Gn as s,
2114
- ar as t,
2115
- xr as u,
2116
- Dn as v,
2117
- hn as w,
2118
- Vt as x,
2119
- Ln as y,
2120
- Xn as z
2179
+ Hn as P,
2180
+ gr as Q,
2181
+ Sr as R,
2182
+ Kn as S,
2183
+ er as T,
2184
+ gt as U,
2185
+ cn as V,
2186
+ Ar as W,
2187
+ cr as X,
2188
+ U as Y,
2189
+ un as Z,
2190
+ Vn as _,
2191
+ jr as a,
2192
+ We as a0,
2193
+ Ke as a1,
2194
+ kn as a2,
2195
+ Ce as a3,
2196
+ Ge as a4,
2197
+ F as a5,
2198
+ Ee as a6,
2199
+ de as a7,
2200
+ Ye as a8,
2201
+ vn as a9,
2202
+ yn as aa,
2203
+ Ze as ab,
2204
+ nn as ac,
2205
+ rn as ad,
2206
+ He as ae,
2207
+ wn as af,
2208
+ bn as ag,
2209
+ gn as ah,
2210
+ Er as ai,
2211
+ mn as aj,
2212
+ _n as ak,
2213
+ jn as al,
2214
+ En as am,
2215
+ dr as an,
2216
+ Gn as ao,
2217
+ I as ap,
2218
+ Dn as aq,
2219
+ Ie as ar,
2220
+ $n as as,
2221
+ In as at,
2222
+ De as au,
2223
+ Jn as av,
2224
+ Fn as aw,
2225
+ At as ax,
2226
+ pr as ay,
2227
+ vr as b,
2228
+ fe as c,
2229
+ D as d,
2230
+ W as e,
2231
+ Mn as f,
2232
+ hr as g,
2233
+ Rt as h,
2234
+ kr as i,
2235
+ mr as j,
2236
+ wr as k,
2237
+ qn as l,
2238
+ xr as m,
2239
+ ne as n,
2240
+ Xn as o,
2241
+ fr as p,
2242
+ Un as q,
2243
+ _r as r,
2244
+ Zn as s,
2245
+ ur as t,
2246
+ Nr as u,
2247
+ Wn as v,
2248
+ xn as w,
2249
+ en as x,
2250
+ On as y,
2251
+ Qn as z
2121
2252
  };
2122
- //# sourceMappingURL=JimboSwipeDeck-DUwjKBbo.js.map
2253
+ //# sourceMappingURL=JimboSwipeDeck-BYXDxmy7.js.map