fictoan-react 2.0.0-beta.2 → 2.0.0-beta.3

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,9 +1,9 @@
1
1
  "use client";
2
2
  "use client;";
3
- import { jsx as o, jsxs as T, Fragment as $e } from "react/jsx-runtime";
4
- import b, { useCallback as _, useEffect as q, useRef as J, useState as j, useMemo as ve, createElement as xt, createRef as Rt, useImperativeHandle as Je, createContext as Se, useContext as be } from "react";
3
+ import { jsx as o, jsxs as T, Fragment as Ee } from "react/jsx-runtime";
4
+ import g, { useCallback as G, useEffect as U, useRef as Y, useState as j, useMemo as ye, createElement as xt, createRef as Rt, useImperativeHandle as Je, createContext as Oe, useContext as Ne } from "react";
5
5
  import { createRoot as Mt } from "react-dom/client";
6
- const Et = (e) => e.filter((t) => !!t).join(" "), I = b.forwardRef(
6
+ const Et = (e) => e.filter((t) => !!t).join(" "), A = g.forwardRef(
7
7
  ({
8
8
  as: e = "div",
9
9
  role: t,
@@ -19,60 +19,60 @@ const Et = (e) => e.filter((t) => !!t).join(" "), I = b.forwardRef(
19
19
  bgOpacity: d,
20
20
  borderColor: f,
21
21
  borderColour: p,
22
- borderOpacity: k,
23
- className: N,
24
- columns: $,
22
+ borderOpacity: $,
23
+ className: k,
24
+ columns: x,
25
25
  fillColor: h,
26
26
  fillColour: L,
27
- gap: y,
28
- hideOnDesktop: x,
29
- hideOnMobile: O,
27
+ gap: v,
28
+ hideOnDesktop: R,
29
+ hideOnMobile: S,
30
30
  hideOnTabletLandscape: E,
31
31
  hideOnTabletPortrait: D,
32
- horizontalMargin: g,
33
- horizontalPadding: B,
32
+ horizontalMargin: N,
33
+ horizontalPadding: W,
34
34
  horizontallyCenterThis: M,
35
35
  horizontallyCentreThis: V,
36
- isFullHeight: C,
36
+ isFullHeight: K,
37
37
  isFullWidth: P,
38
- layoutAsFlexbox: w,
38
+ layoutAsFlexbox: y,
39
39
  layoutAsGrid: H,
40
40
  stackVertically: F,
41
- stackHorizontally: S,
42
- marginLeft: m,
43
- marginBottom: v,
44
- margin: R,
45
- marginRight: A,
46
- marginTop: z,
47
- opacity: K,
41
+ stackHorizontally: O,
42
+ marginLeft: w,
43
+ marginBottom: m,
44
+ margin: b,
45
+ marginRight: I,
46
+ marginTop: B,
47
+ opacity: _,
48
48
  paddingBottom: Z,
49
- paddingLeft: ne,
49
+ paddingLeft: ie,
50
50
  padding: te,
51
51
  paddingRight: ae,
52
- paddingTop: W,
53
- pushItemsToEnds: X,
54
- shadow: Q,
55
- shape: ce,
56
- showOnlyOnDesktop: Me,
57
- showOnlyOnMobile: Ee,
58
- showOnlyOnTabletLandscape: Pe,
59
- showOnlyOnTabletPortrait: Ve,
60
- size: Te,
61
- strokeColor: U,
62
- strokeColour: me,
63
- textColor: ye,
64
- textColour: de,
65
- verticalMargin: we,
66
- verticalPadding: Ne,
52
+ paddingTop: re,
53
+ pushItemsToEnds: $e,
54
+ shadow: we,
55
+ shape: z,
56
+ showOnlyOnDesktop: X,
57
+ showOnlyOnMobile: Q,
58
+ showOnlyOnTabletLandscape: se,
59
+ showOnlyOnTabletPortrait: xe,
60
+ size: De,
61
+ strokeColor: q,
62
+ strokeColour: he,
63
+ textColor: be,
64
+ textColour: ue,
65
+ verticalMargin: ge,
66
+ verticalPadding: Re,
67
67
  verticallyCenterItems: gt,
68
68
  verticallyCentreItems: Nt,
69
69
  weight: Ge,
70
70
  style: kt,
71
71
  ...$t
72
- } = n, { className: Aa, classNames: La, ...Sa } = n, Ke = {
72
+ } = n, { className: Aa, classNames: La, ...Sa } = n, Ce = {
73
73
  ...kt,
74
74
  ...d && { "--bg-opacity": Number(d) / 100 },
75
- ...k && { "--border-opacity": Number(k) / 100 }
75
+ ...$ && { "--border-opacity": Number($) / 100 }
76
76
  };
77
77
  return /* @__PURE__ */ o(
78
78
  e,
@@ -83,56 +83,56 @@ const Et = (e) => e.filter((t) => !!t).join(" "), I = b.forwardRef(
83
83
  tabIndex: r,
84
84
  onKeyDown: c,
85
85
  ...$t,
86
- style: Object.keys(Ke).length > 0 ? Ke : void 0,
86
+ style: Object.keys(Ce).length > 0 ? Ce : void 0,
87
87
  className: Et(
88
88
  [
89
- N,
89
+ k,
90
90
  l && `bg-${l}`,
91
91
  u && `bg-${u}`,
92
92
  f && `border-${f}`,
93
93
  p && `border-${p}`,
94
94
  h && `fill-${h}`,
95
95
  L && `fill-${L}`,
96
- x && "hide-on-desktop",
97
- O && "hide-on-mobile",
96
+ R && "hide-on-desktop",
97
+ S && "hide-on-mobile",
98
98
  E && "hide-on-tablet-landscape",
99
99
  D && "hide-on-tablet-portrait",
100
- g && `margin-right-${g} margin-left-${g}`,
101
- B && `padding-right-${B} padding-left-${B}`,
100
+ N && `margin-right-${N} margin-left-${N}`,
101
+ W && `padding-right-${W} padding-left-${W}`,
102
102
  M && "horizontally-centre-this",
103
103
  V && "horizontally-centre-this",
104
- C && "full-height",
104
+ K && "full-height",
105
105
  P && "full-width",
106
- w && "layout-flexbox",
106
+ y && "layout-flexbox",
107
107
  H && "layout-grid",
108
108
  F && "stack-vertically",
109
- S && "stack-horizontally",
110
- y && `gap-${y}`,
111
- m && `margin-left-${m}`,
112
- v && `margin-bottom-${v}`,
113
- R && `margin-all-${R}`,
114
- A && `margin-right-${A}`,
115
- z && `margin-top-${z}`,
116
- K && `opacity-${K}`,
109
+ O && "stack-horizontally",
110
+ v && `gap-${v}`,
111
+ w && `margin-left-${w}`,
112
+ m && `margin-bottom-${m}`,
113
+ b && `margin-all-${b}`,
114
+ I && `margin-right-${I}`,
115
+ B && `margin-top-${B}`,
116
+ _ && `opacity-${_}`,
117
117
  Z && `padding-bottom-${Z}`,
118
- ne && `padding-left-${ne}`,
118
+ ie && `padding-left-${ie}`,
119
119
  te && `padding-all-${te}`,
120
120
  ae && `padding-right-${ae}`,
121
- W && `padding-top-${W}`,
122
- X && "push-to-ends",
123
- Q && `shadow-${Q}`,
124
- ce && `shape-${ce}`,
125
- Me && "show-only-on-desktop",
126
- Ee && "show-only-on-mobile",
127
- Pe && "show-only-on-tablet-landscape",
128
- Ve && "show-only-on-tablet-portrait",
129
- Te && `size-${Te}`,
130
- U && `stroke-${U}`,
131
- me && `stroke-${me}`,
132
- ye && `text-${ye}`,
133
- de && `text-${de}`,
134
- we && `margin-top-${we} margin-bottom-${we}`,
135
- Ne && `padding-top-${Ne} padding-bottom-${Ne}`,
121
+ re && `padding-top-${re}`,
122
+ $e && "push-to-ends",
123
+ we && `shadow-${we}`,
124
+ z && `shape-${z}`,
125
+ X && "show-only-on-desktop",
126
+ Q && "show-only-on-mobile",
127
+ se && "show-only-on-tablet-landscape",
128
+ xe && "show-only-on-tablet-portrait",
129
+ De && `size-${De}`,
130
+ q && `stroke-${q}`,
131
+ he && `stroke-${he}`,
132
+ be && `text-${be}`,
133
+ ue && `text-${ue}`,
134
+ ge && `margin-top-${ge} margin-bottom-${ge}`,
135
+ Re && `padding-top-${Re} padding-bottom-${Re}`,
136
136
  gt && "vertically-centre-items",
137
137
  Nt && "vertically-centre-items",
138
138
  Ge && `weight-${Ge}`
@@ -142,17 +142,17 @@ const Et = (e) => e.filter((t) => !!t).join(" "), I = b.forwardRef(
142
142
  );
143
143
  }
144
144
  );
145
- I.displayName = "Element";
146
- const ie = (e, t) => b.forwardRef(
145
+ A.displayName = "Element";
146
+ const ce = (e, t) => g.forwardRef(
147
147
  (a, r) => {
148
148
  const c = { ...t, ...a };
149
149
  if (e === "a" && "external" in c) {
150
150
  const { external: n } = c;
151
151
  n && (c.target = "_blank", c.rel = "noopener noreferrer");
152
152
  }
153
- return /* @__PURE__ */ o(I, { as: e, ref: r, ...c });
153
+ return /* @__PURE__ */ o(A, { as: e, ref: r, ...c });
154
154
  }
155
- ), Fa = ie("article"), Wa = ie("aside"), za = ie("body"), G = ie("div"), Ha = ie("footer"), _a = ie("header"), Ga = ie("main"), Pt = ie("nav"), Ka = ie("section"), Ca = ie("span"), ja = ie("a", {
155
+ ), Fa = ce("article"), Wa = ce("aside"), za = ce("body"), C = ce("div"), Ha = ce("footer"), _a = ce("header"), Ga = ce("main"), Pt = ce("nav"), Ca = ce("section"), Ka = ce("span"), ja = ce("a", {
156
156
  rel: "noopener noreferrer"
157
157
  // Default props for Hyperlink
158
158
  }), Tt = {
@@ -160,7 +160,7 @@ const ie = (e, t) => b.forwardRef(
160
160
  tick: /* @__PURE__ */ o("svg", { viewBox: "0 0 24 24", "aria-hidden": "true", children: /* @__PURE__ */ o("path", { d: "M5 12l5 5L20 7" }) }),
161
161
  plus: /* @__PURE__ */ o("svg", { viewBox: "0 0 24 24", "aria-hidden": "true", children: /* @__PURE__ */ o("path", { d: "M12 5v14M5 12h14" }) }),
162
162
  minus: /* @__PURE__ */ o("svg", { viewBox: "0 0 24 24", "aria-hidden": "true", children: /* @__PURE__ */ o("path", { d: "M5 12h14" }) })
163
- }, Oe = b.forwardRef(
163
+ }, Be = g.forwardRef(
164
164
  ({
165
165
  children: e,
166
166
  size: t = "medium",
@@ -176,7 +176,7 @@ const ie = (e, t) => b.forwardRef(
176
176
  f.stopPropagation(), c == null || c(f);
177
177
  }, d = !!r;
178
178
  return /* @__PURE__ */ T(
179
- I,
179
+ A,
180
180
  {
181
181
  "data-badge": !0,
182
182
  "data-has-action": d || void 0,
@@ -202,10 +202,10 @@ const ie = (e, t) => b.forwardRef(
202
202
  );
203
203
  }
204
204
  );
205
- Oe.displayName = "Badge";
205
+ Be.displayName = "Badge";
206
206
  const We = (e, t) => {
207
- const a = _(t, [t]);
208
- q(() => {
207
+ const a = G(t, [t]);
208
+ U(() => {
209
209
  const r = (c) => {
210
210
  !e.current || typeof a != "function" || e.current.contains(c.target) || a(c);
211
211
  };
@@ -213,7 +213,7 @@ const We = (e, t) => {
213
213
  document.removeEventListener("mousedown", r), document.removeEventListener("touchstart", r);
214
214
  };
215
215
  }, [e, a]);
216
- }, Dt = b.forwardRef(
216
+ }, Dt = g.forwardRef(
217
217
  ({
218
218
  id: e,
219
219
  children: t,
@@ -228,13 +228,13 @@ const We = (e, t) => {
228
228
  showOverlay: d = !0,
229
229
  blurOverlay: f = !1,
230
230
  closeOnClickOutside: p = !0,
231
- zIndex: k,
232
- label: N,
233
- description: $,
231
+ zIndex: $,
232
+ label: k,
233
+ description: x,
234
234
  classNames: h = [],
235
235
  ...L
236
- }, y) => {
237
- const x = `${e}`, O = $ ? `${x}-description` : void 0, E = J(null), D = y || E, g = [
236
+ }, v) => {
237
+ const R = `${e}`, S = x ? `${R}-description` : void 0, E = Y(null), D = v || E, N = [
238
238
  "drawer",
239
239
  c,
240
240
  n,
@@ -243,46 +243,46 @@ const We = (e, t) => {
243
243
  ...f ? ["blur-overlay"] : [],
244
244
  ...h
245
245
  ];
246
- return q(() => {
247
- const M = D.current, V = document.querySelector(`[data-drawer-overlay-for="${x}"]`);
246
+ return U(() => {
247
+ const M = D.current, V = document.querySelector(`[data-drawer-overlay-for="${R}"]`);
248
248
  return a ? (M == null || M.classList.add("open"), M == null || M.classList.remove("closing"), M == null || M.focus(), V && V.classList.add("visible"), document.body.style.overflow = "hidden") : M != null && M.classList.contains("open") && (M.classList.add("closing"), M.classList.remove("open"), V && V.classList.remove("visible"), document.body.style.overflow = ""), () => {
249
249
  document.body.style.overflow = "";
250
250
  };
251
- }, [a, x, D]), q(() => {
251
+ }, [a, R, D]), U(() => {
252
252
  const M = (V) => {
253
253
  V.key === "Escape" && u && a && r && r();
254
254
  };
255
255
  return document.addEventListener("keydown", M), () => document.removeEventListener("keydown", M);
256
256
  }, [u, a, r]), We(D, () => {
257
257
  p && u && a && r && r();
258
- }), /* @__PURE__ */ T($e, { children: [
258
+ }), /* @__PURE__ */ T(Ee, { children: [
259
259
  d && /* @__PURE__ */ o(
260
- G,
260
+ C,
261
261
  {
262
262
  className: `drawer-overlay ${f ? "blur" : ""} ${a ? "visible" : ""}`,
263
263
  "data-drawer-overlay-for": e,
264
264
  "aria-hidden": "true",
265
265
  onClick: p && u && r ? r : void 0,
266
- style: { zIndex: k ?? 9999 }
266
+ style: { zIndex: $ ?? 9999 }
267
267
  }
268
268
  ),
269
269
  /* @__PURE__ */ T(
270
- I,
270
+ A,
271
271
  {
272
272
  as: "div",
273
- id: x,
273
+ id: R,
274
274
  "data-drawer": !0,
275
275
  ref: D,
276
- classNames: g,
276
+ classNames: N,
277
277
  onAnimationEnd: (M) => {
278
278
  (M.animationName.includes("slide-out") || M.animationName.includes("fade-out")) && M.currentTarget.classList.remove("closing");
279
279
  },
280
280
  role: "dialog",
281
281
  "aria-modal": "true",
282
- "aria-label": N || "Drawer",
283
- "aria-describedby": O,
282
+ "aria-label": k || "Drawer",
283
+ "aria-describedby": S,
284
284
  tabIndex: -1,
285
- style: { zIndex: k ?? 1e4 },
285
+ style: { zIndex: $ ?? 1e4 },
286
286
  ...L,
287
287
  children: [
288
288
  u && r && /* @__PURE__ */ o(
@@ -296,14 +296,14 @@ const We = (e, t) => {
296
296
  }
297
297
  ),
298
298
  /* @__PURE__ */ T(
299
- G,
299
+ C,
300
300
  {
301
301
  className: "drawer-content",
302
302
  padding: s,
303
303
  bgColor: i,
304
304
  bgColour: l,
305
305
  children: [
306
- $ && /* @__PURE__ */ o("div", { id: O, className: "sr-only", children: $ }),
306
+ x && /* @__PURE__ */ o("div", { id: S, className: "sr-only", children: x }),
307
307
  /* @__PURE__ */ o("div", { role: "document", children: t })
308
308
  ]
309
309
  }
@@ -315,11 +315,11 @@ const We = (e, t) => {
315
315
  }
316
316
  );
317
317
  Dt.displayName = "Drawer";
318
- const ze = b.forwardRef(
318
+ const ze = g.forwardRef(
319
319
  ({ size: e = "medium", shape: t, kind: a, isLoading: r, label: c, ...n }, s) => {
320
320
  let i = [];
321
321
  return a && i.push(a), e && i.push(`size-${e}`), t && i.push(`shape-${t}`), r && i.push("is-loading"), /* @__PURE__ */ o(
322
- I,
322
+ A,
323
323
  {
324
324
  as: "button",
325
325
  "data-button": !0,
@@ -334,11 +334,11 @@ const ze = b.forwardRef(
334
334
  }
335
335
  );
336
336
  ze.displayName = "Button";
337
- const It = b.forwardRef(
337
+ const It = g.forwardRef(
338
338
  ({ isJoint: e = !0, spacing: t, equaliseWidth: a, children: r, ...c }, n) => {
339
339
  let s = [];
340
340
  return e && s.push("is-joint"), t && !e && s.push(`spacing-${t}`), a && s.push("equal-width"), /* @__PURE__ */ o(
341
- I,
341
+ A,
342
342
  {
343
343
  as: "div",
344
344
  "data-button-group": !0,
@@ -352,9 +352,9 @@ const It = b.forwardRef(
352
352
  }
353
353
  );
354
354
  It.displayName = "ButtonGroup";
355
- const Ce = b.forwardRef(
355
+ const Ke = g.forwardRef(
356
356
  ({ children: e, current: t, ...a }, r) => /* @__PURE__ */ o(
357
- I,
357
+ A,
358
358
  {
359
359
  as: "li",
360
360
  "data-breadcrumb-item": !0,
@@ -367,7 +367,7 @@ const Ce = b.forwardRef(
367
367
  }
368
368
  )
369
369
  ), At = ({ separator: e }) => /* @__PURE__ */ o(
370
- Y,
370
+ J,
371
371
  {
372
372
  className: "breadcrumb-separator",
373
373
  "aria-hidden": "true",
@@ -375,27 +375,27 @@ const Ce = b.forwardRef(
375
375
  margin: "none",
376
376
  children: e
377
377
  }
378
- ), Lt = b.forwardRef(
378
+ ), Lt = g.forwardRef(
379
379
  ({ children: e, separator: t = "/", spacing: a = "micro", ...r }, c) => {
380
380
  let n = [];
381
381
  a && n.push(`spacing-${a}`);
382
- const s = b.Children.toArray(e).filter(Boolean), i = s.reduce((l, u, d) => {
383
- if (!b.isValidElement(u)) return l;
382
+ const s = g.Children.toArray(e).filter(Boolean), i = s.reduce((l, u, d) => {
383
+ if (!g.isValidElement(u)) return l;
384
384
  const f = d === s.length - 1;
385
385
  let p;
386
- if (u.type === Ce) {
387
- const k = u;
388
- p = b.cloneElement(k, {
386
+ if (u.type === Ke) {
387
+ const $ = u;
388
+ p = g.cloneElement($, {
389
389
  current: f
390
390
  });
391
391
  } else
392
- p = /* @__PURE__ */ o(Ce, { current: f, children: u }, `item-${d}`);
392
+ p = /* @__PURE__ */ o(Ke, { current: f, children: u }, `item-${d}`);
393
393
  return l.push(p), f || l.push(
394
394
  /* @__PURE__ */ o(At, { separator: t }, `sep-${d}`)
395
395
  ), l;
396
396
  }, []);
397
397
  return /* @__PURE__ */ o("nav", { "aria-label": "Breadcrumb", ref: c, ...r, children: /* @__PURE__ */ o(
398
- I,
398
+ A,
399
399
  {
400
400
  as: "ul",
401
401
  "data-breadcrumbs-wrapper": !0,
@@ -407,9 +407,9 @@ const Ce = b.forwardRef(
407
407
  }
408
408
  );
409
409
  Lt.displayName = "Breadcrumbs";
410
- const Ze = b.forwardRef(
410
+ const Ze = g.forwardRef(
411
411
  ({ kind: e, children: t, title: a, ...r }, c) => /* @__PURE__ */ o(
412
- I,
412
+ A,
413
413
  {
414
414
  as: "div",
415
415
  "data-callout": !0,
@@ -429,10 +429,10 @@ const Ze = b.forwardRef(
429
429
  )
430
430
  );
431
431
  Ze.displayName = "Callout";
432
- const Qe = b.forwardRef(({ shape: e, heading: t, children: a, ...r }, c) => {
432
+ const Qe = g.forwardRef(({ shape: e, heading: t, children: a, ...r }, c) => {
433
433
  let n = [];
434
434
  return e && n.push(`shape-${e}`), /* @__PURE__ */ o(
435
- I,
435
+ A,
436
436
  {
437
437
  as: "div",
438
438
  "data-card": !0,
@@ -447,7 +447,7 @@ const Qe = b.forwardRef(({ shape: e, heading: t, children: a, ...r }, c) => {
447
447
  );
448
448
  });
449
449
  Qe.displayName = "Card";
450
- const St = b.forwardRef(({
450
+ const St = g.forwardRef(({
451
451
  children: e,
452
452
  source: t,
453
453
  language: a = "json",
@@ -460,22 +460,22 @@ const St = b.forwardRef(({
460
460
  shadow: u,
461
461
  ...d
462
462
  }, f) => {
463
- const [p, k] = j(!1), [N, $] = j(null), [h, L] = j(s), [y, x] = j(null), O = J(null);
464
- let E = typeof e == "string" ? e : b.Children.toArray(e).join("");
465
- e || (E = typeof t == "object" ? JSON.stringify(t, null, 2) : t ?? ""), q(() => {
463
+ const [p, $] = j(!1), [k, x] = j(null), [h, L] = j(s), [v, R] = j(null), S = Y(null);
464
+ let E = typeof e == "string" ? e : g.Children.toArray(e).join("");
465
+ e || (E = typeof t == "object" ? JSON.stringify(t, null, 2) : t ?? ""), U(() => {
466
466
  if (!s) return;
467
467
  (async () => {
468
468
  var H;
469
469
  L(!0);
470
470
  try {
471
- const S = (await import("prismjs")).default;
472
- if (typeof window < "u" && !window.Prism && (window.Prism = S), a !== "plain" && !S.languages[a])
471
+ const O = (await import("prismjs")).default;
472
+ if (typeof window < "u" && !window.Prism && (window.Prism = O), a !== "plain" && !O.languages[a])
473
473
  try {
474
474
  await import(`prismjs/components/prism-${a}`);
475
475
  } catch {
476
476
  console.warn(`Language "${a}" not available, falling back to plain text`);
477
477
  }
478
- $(S);
478
+ x(O);
479
479
  } catch (F) {
480
480
  (F == null ? void 0 : F.code) === "ERR_MODULE_NOT_FOUND" || (H = F == null ? void 0 : F.message) != null && H.includes("Cannot find module") ? console.warn(
481
481
  "PrismJS is not installed. To enable syntax highlighting, run: npm install prismjs"
@@ -485,92 +485,92 @@ const St = b.forwardRef(({
485
485
  }
486
486
  })();
487
487
  }, [s, a]);
488
- const D = _(() => {
489
- var v;
490
- const w = window.getSelection();
491
- if (!w || w.rangeCount === 0) return null;
492
- const H = w.getRangeAt(0), F = H.startContainer;
493
- let m = H.startOffset;
494
- if (F && F !== y && y) {
495
- const R = document.createTreeWalker(
496
- y,
488
+ const D = G(() => {
489
+ var m;
490
+ const y = window.getSelection();
491
+ if (!y || y.rangeCount === 0) return null;
492
+ const H = y.getRangeAt(0), F = H.startContainer;
493
+ let w = H.startOffset;
494
+ if (F && F !== v && v) {
495
+ const b = document.createTreeWalker(
496
+ v,
497
497
  NodeFilter.SHOW_TEXT,
498
498
  null
499
499
  );
500
- let A;
501
- for (; (A = R.nextNode()) && A !== F; )
502
- m += ((v = A.textContent) == null ? void 0 : v.length) || 0;
500
+ let I;
501
+ for (; (I = b.nextNode()) && I !== F; )
502
+ w += ((m = I.textContent) == null ? void 0 : m.length) || 0;
503
503
  }
504
- return m;
505
- }, [y]), g = _((w) => {
504
+ return w;
505
+ }, [v]), N = G((y) => {
506
506
  var H;
507
- if (!(!y || !s || !N))
507
+ if (!(!v || !s || !k))
508
508
  try {
509
- const F = i ? D() : null, S = N.highlight(
510
- w,
511
- N.languages[a] || N.languages.plain,
509
+ const F = i ? D() : null, O = k.highlight(
510
+ y,
511
+ k.languages[a] || k.languages.plain,
512
512
  a
513
513
  );
514
- if (y.innerHTML = S, i && F !== null) {
515
- const m = window.getSelection(), v = document.createRange(), R = document.createTreeWalker(
516
- y,
514
+ if (v.innerHTML = O, i && F !== null) {
515
+ const w = window.getSelection(), m = document.createRange(), b = document.createTreeWalker(
516
+ v,
517
517
  NodeFilter.SHOW_TEXT,
518
518
  null
519
519
  );
520
- let A = 0, z;
521
- for (; z = R.nextNode(); ) {
522
- const K = ((H = z.textContent) == null ? void 0 : H.length) || 0;
523
- if (A + K >= F) {
524
- v.setStart(z, F - A), v.setEnd(z, F - A), m == null || m.removeAllRanges(), m == null || m.addRange(v);
520
+ let I = 0, B;
521
+ for (; B = b.nextNode(); ) {
522
+ const _ = ((H = B.textContent) == null ? void 0 : H.length) || 0;
523
+ if (I + _ >= F) {
524
+ m.setStart(B, F - I), m.setEnd(B, F - I), w == null || w.removeAllRanges(), w == null || w.addRange(m);
525
525
  break;
526
526
  }
527
- A += K;
527
+ I += _;
528
528
  }
529
529
  }
530
530
  } catch (F) {
531
- console.warn("Error highlighting code:", F), y && (y.textContent = w);
531
+ console.warn("Error highlighting code:", F), v && (v.textContent = y);
532
532
  }
533
- }, [a, s, i, N, D, y]), B = _((w) => {
534
- if (!y) return;
535
- const H = y.textContent || "";
533
+ }, [a, s, i, k, D, v]), W = G((y) => {
534
+ if (!v) return;
535
+ const H = v.textContent || "";
536
536
  l == null || l(H), requestAnimationFrame(() => {
537
- g(H);
537
+ N(H);
538
538
  });
539
- }, [g, l, y]);
540
- q(() => {
541
- const w = y;
542
- if (!(!w || !i))
543
- return w.addEventListener("input", B), () => {
544
- w.removeEventListener("input", B);
539
+ }, [N, l, v]);
540
+ U(() => {
541
+ const y = v;
542
+ if (!(!y || !i))
543
+ return y.addEventListener("input", W), () => {
544
+ y.removeEventListener("input", W);
545
545
  };
546
- }, [i, B, y]), q(() => {
547
- !y || !N || g(E);
548
- }, [g, E, N, y]);
546
+ }, [i, W, v]), U(() => {
547
+ !v || !k || N(E);
548
+ }, [N, E, k, v]);
549
549
  const M = async () => {
550
550
  try {
551
- const w = y ? y.textContent || "" : E;
552
- await navigator.clipboard.writeText(w), k(!0), setTimeout(() => k(!1), 3e3);
553
- } catch (w) {
554
- console.error("Could not copy text: ", w);
551
+ const y = v ? v.textContent || "" : E;
552
+ await navigator.clipboard.writeText(y), $(!0), setTimeout(() => $(!1), 3e3);
553
+ } catch (y) {
554
+ console.error("Could not copy text: ", y);
555
555
  }
556
- }, V = async (w) => {
557
- (w.key === "Enter" || w.key === " ") && w.target === O.current && (w.preventDefault(), await M());
556
+ }, V = async (y) => {
557
+ (y.key === "Enter" || y.key === " ") && y.target === S.current && (y.preventDefault(), await M());
558
558
  };
559
- let C = [];
560
- c && C.push("show-line-numbers");
559
+ let K = [];
560
+ c && K.push("show-line-numbers");
561
561
  const P = E.split(/\r\n|\r|\n/gm);
562
562
  return /* @__PURE__ */ T(
563
- I,
563
+ A,
564
564
  {
565
565
  "data-code-block": !0,
566
566
  as: "div",
567
- classNames: C,
567
+ classNames: K,
568
568
  role: "region",
569
569
  "aria-label": n || `Code block in ${a}`,
570
570
  ...d,
571
571
  children: [
572
572
  r ? p ? /* @__PURE__ */ o(
573
- Oe,
573
+ Be,
574
574
  {
575
575
  className: "code-block-copied-badge",
576
576
  size: "tiny",
@@ -594,24 +594,24 @@ const St = b.forwardRef(({
594
594
  /* @__PURE__ */ T(
595
595
  "pre",
596
596
  {
597
- ref: O,
597
+ ref: S,
598
598
  className: `language-${a}${u ? ` shadow-${u}` : ""}`,
599
599
  tabIndex: 0,
600
600
  "aria-label": `Code in ${a}`,
601
601
  children: [
602
- c && Array.from(Array(P.length).keys()).map((w) => /* @__PURE__ */ o(
602
+ c && Array.from(Array(P.length).keys()).map((y) => /* @__PURE__ */ o(
603
603
  "span",
604
604
  {
605
605
  className: "line-numbers",
606
606
  "aria-hidden": "true",
607
- children: w + 1
607
+ children: y + 1
608
608
  },
609
- w
609
+ y
610
610
  )),
611
611
  /* @__PURE__ */ o(
612
612
  "code",
613
613
  {
614
- ref: x,
614
+ ref: R,
615
615
  contentEditable: i,
616
616
  suppressContentEditableWarning: !0,
617
617
  spellCheck: "false",
@@ -627,11 +627,11 @@ const St = b.forwardRef(({
627
627
  );
628
628
  });
629
629
  St.displayName = "CodeBlock";
630
- const et = b.forwardRef(
630
+ const et = g.forwardRef(
631
631
  ({ kind: e, height: t, label: a, ...r }, c) => {
632
632
  let n = [];
633
633
  return e && n.push(e), /* @__PURE__ */ o(
634
- I,
634
+ A,
635
635
  {
636
636
  as: "hr",
637
637
  "data-hrule": !0,
@@ -710,7 +710,7 @@ const Ot = [
710
710
  "weight",
711
711
  // Custom classes
712
712
  "classNames"
713
- ], le = (e) => {
713
+ ], de = (e) => {
714
714
  const t = {}, a = {};
715
715
  for (const r of Object.keys(e))
716
716
  Ot.includes(r) ? t[r] = e[r] : a[r] = e[r];
@@ -718,7 +718,7 @@ const Ot = [
718
718
  wrapperProps: t,
719
719
  inputProps: a
720
720
  };
721
- }, xe = b.forwardRef(
721
+ }, Pe = g.forwardRef(
722
722
  ({
723
723
  label: e,
724
724
  hideLabel: t,
@@ -727,7 +727,7 @@ const Ot = [
727
727
  }, c) => {
728
728
  let n = [];
729
729
  return t && n.push("visually-hidden"), /* @__PURE__ */ o(
730
- I,
730
+ A,
731
731
  {
732
732
  as: "label",
733
733
  ref: c,
@@ -739,14 +739,14 @@ const Ot = [
739
739
  );
740
740
  }
741
741
  );
742
- xe.displayName = "InputLabel";
743
- const Y = b.forwardRef(
742
+ Pe.displayName = "InputLabel";
743
+ const J = g.forwardRef(
744
744
  ({ weight: e, size: t, fontStyle: a = "sans-serif", align: r, isSubtext: c, ...n }, s) => {
745
745
  let i = [];
746
- return e && i.push(`weight-${e}`), t && i.push(`text-${t}`), a && i.push(`font-${a}`), c && i.push("sub-text"), r && i.push(`text-${r}`), /* @__PURE__ */ o(I, { as: "p", ref: s, classNames: i, ...n });
746
+ return e && i.push(`weight-${e}`), t && i.push(`text-${t}`), a && i.push(`font-${a}`), c && i.push("sub-text"), r && i.push(`text-${r}`), /* @__PURE__ */ o(A, { as: "p", ref: s, classNames: i, ...n });
747
747
  }
748
748
  );
749
- Y.displayName = "Text";
749
+ J.displayName = "Text";
750
750
  const Bt = ({ state: e }) => e === "valid" ? /* @__PURE__ */ o(
751
751
  "svg",
752
752
  {
@@ -803,7 +803,7 @@ const Bt = ({ state: e }) => e === "valid" ? /* @__PURE__ */ o(
803
803
  )
804
804
  ]
805
805
  }
806
- ), ee = b.forwardRef(
806
+ ), ee = g.forwardRef(
807
807
  ({
808
808
  label: e,
809
809
  customLabel: t,
@@ -817,9 +817,9 @@ const Bt = ({ state: e }) => e === "valid" ? /* @__PURE__ */ o(
817
817
  children: u,
818
818
  ...d
819
819
  }, f) => {
820
- const p = e || t, k = r || c;
820
+ const p = e || t, $ = r || c;
821
821
  return /* @__PURE__ */ T(
822
- I,
822
+ A,
823
823
  {
824
824
  as: "div",
825
825
  "data-form-item": !0,
@@ -829,14 +829,14 @@ const Bt = ({ state: e }) => e === "valid" ? /* @__PURE__ */ o(
829
829
  className: [i ? `size-${i}` : "", l ? "label-first" : ""].filter(Boolean).join(" ") || void 0,
830
830
  ...d,
831
831
  children: [
832
- p && /* @__PURE__ */ T(G, { "data-label-wrapper": !0, "data-has-validation": n ? "true" : void 0, children: [
833
- t || e && /* @__PURE__ */ o(xe, { label: e, htmlFor: a }),
832
+ p && /* @__PURE__ */ T(C, { "data-label-wrapper": !0, "data-has-validation": n ? "true" : void 0, children: [
833
+ t || e && /* @__PURE__ */ o(Pe, { label: e, htmlFor: a }),
834
834
  n && /* @__PURE__ */ o(Bt, { state: n })
835
835
  ] }),
836
- /* @__PURE__ */ o(G, { "data-input-wrapper": !0, children: u }),
837
- k && /* @__PURE__ */ T(G, { className: "info-section vertically-center-items", children: [
838
- r && /* @__PURE__ */ o(Y, { className: "help-text", children: r }),
839
- c && /* @__PURE__ */ o(Y, { className: "error-text", children: c })
836
+ /* @__PURE__ */ o(C, { "data-input-wrapper": !0, children: u }),
837
+ $ && /* @__PURE__ */ T(C, { className: "info-section vertically-center-items", children: [
838
+ r && /* @__PURE__ */ o(J, { className: "help-text", children: r }),
839
+ c && /* @__PURE__ */ o(J, { className: "error-text", children: c })
840
840
  ] })
841
841
  ]
842
842
  }
@@ -844,7 +844,7 @@ const Bt = ({ state: e }) => e === "valid" ? /* @__PURE__ */ o(
844
844
  }
845
845
  );
846
846
  ee.displayName = "FormItem";
847
- const He = b.forwardRef(
847
+ const He = g.forwardRef(
848
848
  ({
849
849
  id: e,
850
850
  name: t,
@@ -859,11 +859,11 @@ const He = b.forwardRef(
859
859
  required: d,
860
860
  size: f = "medium",
861
861
  labelFirst: p,
862
- ...k
863
- }, N) => {
864
- const $ = ve(() => t || e, [t, e]), h = (x) => {
865
- s == null || s(x.target.checked);
866
- }, { wrapperProps: L, inputProps: y } = le(k);
862
+ ...$
863
+ }, k) => {
864
+ const x = ye(() => t || e, [t, e]), h = (R) => {
865
+ s == null || s(R.target.checked);
866
+ }, { wrapperProps: L, inputProps: v } = de($);
867
867
  return /* @__PURE__ */ T(
868
868
  ee,
869
869
  {
@@ -877,23 +877,23 @@ const He = b.forwardRef(
877
877
  ...L,
878
878
  children: [
879
879
  /* @__PURE__ */ o(
880
- I,
880
+ A,
881
881
  {
882
882
  as: "input",
883
883
  type: "checkbox",
884
- ref: N,
884
+ ref: k,
885
885
  id: e,
886
- name: $,
886
+ name: x,
887
887
  checked: i,
888
888
  defaultChecked: l,
889
889
  disabled: u,
890
890
  required: d,
891
891
  onChange: h,
892
- ...y
892
+ ...v
893
893
  }
894
894
  ),
895
895
  /* @__PURE__ */ o(
896
- I,
896
+ A,
897
897
  {
898
898
  as: p ? "label" : "div",
899
899
  htmlFor: p ? e : void 0,
@@ -907,7 +907,7 @@ const He = b.forwardRef(
907
907
  }
908
908
  );
909
909
  He.displayName = "Checkbox";
910
- const _e = b.forwardRef(
910
+ const _e = g.forwardRef(
911
911
  ({
912
912
  id: e,
913
913
  name: t,
@@ -922,11 +922,11 @@ const _e = b.forwardRef(
922
922
  required: d,
923
923
  size: f = "medium",
924
924
  labelFirst: p,
925
- ...k
926
- }, N) => {
927
- const $ = ve(() => t || e, [t, e]), h = (x) => {
928
- s == null || s(x.target.checked);
929
- }, { wrapperProps: L, inputProps: y } = le(k);
925
+ ...$
926
+ }, k) => {
927
+ const x = ye(() => t || e, [t, e]), h = (R) => {
928
+ s == null || s(R.target.checked);
929
+ }, { wrapperProps: L, inputProps: v } = de($);
930
930
  return /* @__PURE__ */ T(
931
931
  ee,
932
932
  {
@@ -940,23 +940,23 @@ const _e = b.forwardRef(
940
940
  ...L,
941
941
  children: [
942
942
  /* @__PURE__ */ o(
943
- I,
943
+ A,
944
944
  {
945
945
  as: "input",
946
946
  type: "checkbox",
947
- ref: N,
947
+ ref: k,
948
948
  id: e,
949
- name: $,
949
+ name: x,
950
950
  checked: i,
951
951
  defaultChecked: l,
952
952
  disabled: u,
953
953
  required: d,
954
954
  onChange: h,
955
- ...y
955
+ ...v
956
956
  }
957
957
  ),
958
958
  /* @__PURE__ */ o(
959
- I,
959
+ A,
960
960
  {
961
961
  as: p ? "label" : "div",
962
962
  htmlFor: p ? e : void 0,
@@ -970,7 +970,7 @@ const _e = b.forwardRef(
970
970
  }
971
971
  );
972
972
  _e.displayName = "Switch";
973
- const Vt = b.forwardRef(
973
+ const Vt = g.forwardRef(
974
974
  ({
975
975
  id: e,
976
976
  name: t,
@@ -985,24 +985,24 @@ const Vt = b.forwardRef(
985
985
  equaliseWidth: d,
986
986
  equalizeWidth: f,
987
987
  required: p,
988
- disabled: k,
989
- size: N,
990
- columns: $,
988
+ disabled: $,
989
+ size: k,
990
+ columns: x,
991
991
  labelFirst: h,
992
992
  ...L
993
- }, y) => {
994
- const x = ve(() => t || e, [t, e]), [O, E] = b.useState(
993
+ }, v) => {
994
+ const R = ye(() => t || e, [t, e]), [S, E] = g.useState(
995
995
  s || i || []
996
996
  );
997
- b.useEffect(() => {
997
+ g.useEffect(() => {
998
998
  s !== void 0 && E(s);
999
999
  }, [s]);
1000
- const D = (B, M) => {
1000
+ const D = (W, M) => {
1001
1001
  let V;
1002
- M ? V = [...O, B] : V = O.filter((C) => C !== B), s === void 0 && E(V), l == null || l(V);
1002
+ M ? V = [...S, W] : V = S.filter((K) => K !== W), s === void 0 && E(V), l == null || l(V);
1003
1003
  };
1004
- let g = [];
1005
- return u && g.push(`align-${u}`), (d || f) && g.push("equalise-width"), $ && g.push("with-columns"), h && g.push("label-first"), /* @__PURE__ */ o(
1004
+ let N = [];
1005
+ return u && N.push(`align-${u}`), (d || f) && N.push("equalise-width"), x && N.push("with-columns"), h && N.push("label-first"), /* @__PURE__ */ o(
1006
1006
  ee,
1007
1007
  {
1008
1008
  label: a,
@@ -1011,30 +1011,30 @@ const Vt = b.forwardRef(
1011
1011
  errorText: c,
1012
1012
  required: p,
1013
1013
  children: /* @__PURE__ */ o(
1014
- I,
1014
+ A,
1015
1015
  {
1016
1016
  as: "div",
1017
1017
  "data-checkbox-group": !0,
1018
- ref: y,
1019
- classNames: g,
1018
+ ref: v,
1019
+ classNames: N,
1020
1020
  role: "group",
1021
1021
  "aria-label": a,
1022
- style: $ ? { gridTemplateColumns: `repeat(${$}, 1fr)` } : void 0,
1022
+ style: x ? { gridTemplateColumns: `repeat(${x}, 1fr)` } : void 0,
1023
1023
  ...L,
1024
- children: n.map((B, M) => {
1025
- const { id: V, value: C, label: P, ...w } = B, H = V || `${e}-option-${M}`, F = O.includes(C);
1024
+ children: n.map((W, M) => {
1025
+ const { id: V, value: K, label: P, ...y } = W, H = V || `${e}-option-${M}`, F = S.includes(K);
1026
1026
  return /* @__PURE__ */ o(
1027
1027
  He,
1028
1028
  {
1029
1029
  id: H,
1030
- name: x,
1030
+ name: R,
1031
1031
  label: P,
1032
1032
  checked: F,
1033
- disabled: k || B.disabled,
1034
- size: N,
1033
+ disabled: $ || W.disabled,
1034
+ size: k,
1035
1035
  labelFirst: h,
1036
- onChange: (S) => D(C, S),
1037
- ...w
1036
+ onChange: (O) => D(K, O),
1037
+ ...y
1038
1038
  },
1039
1039
  H
1040
1040
  );
@@ -1046,7 +1046,7 @@ const Vt = b.forwardRef(
1046
1046
  }
1047
1047
  );
1048
1048
  Vt.displayName = "CheckboxGroup";
1049
- const Ft = b.forwardRef(
1049
+ const Ft = g.forwardRef(
1050
1050
  ({
1051
1051
  id: e,
1052
1052
  name: t,
@@ -1061,24 +1061,24 @@ const Ft = b.forwardRef(
1061
1061
  equaliseWidth: d,
1062
1062
  equalizeWidth: f,
1063
1063
  required: p,
1064
- disabled: k,
1065
- size: N,
1066
- columns: $,
1064
+ disabled: $,
1065
+ size: k,
1066
+ columns: x,
1067
1067
  labelFirst: h,
1068
1068
  ...L
1069
- }, y) => {
1070
- const x = ve(() => t || e, [t, e]), [O, E] = b.useState(
1069
+ }, v) => {
1070
+ const R = ye(() => t || e, [t, e]), [S, E] = g.useState(
1071
1071
  s || i || []
1072
1072
  );
1073
- b.useEffect(() => {
1073
+ g.useEffect(() => {
1074
1074
  s !== void 0 && E(s);
1075
1075
  }, [s]);
1076
- const D = (B, M) => {
1076
+ const D = (W, M) => {
1077
1077
  let V;
1078
- M ? V = [...O, B] : V = O.filter((C) => C !== B), s === void 0 && E(V), l == null || l(V);
1078
+ M ? V = [...S, W] : V = S.filter((K) => K !== W), s === void 0 && E(V), l == null || l(V);
1079
1079
  };
1080
- let g = [];
1081
- return u && g.push(`align-${u}`), (d || f) && g.push("equalise-width"), $ && g.push("with-columns"), h && g.push("label-first"), /* @__PURE__ */ o(
1080
+ let N = [];
1081
+ return u && N.push(`align-${u}`), (d || f) && N.push("equalise-width"), x && N.push("with-columns"), h && N.push("label-first"), /* @__PURE__ */ o(
1082
1082
  ee,
1083
1083
  {
1084
1084
  label: a,
@@ -1087,30 +1087,30 @@ const Ft = b.forwardRef(
1087
1087
  errorText: c,
1088
1088
  required: p,
1089
1089
  children: /* @__PURE__ */ o(
1090
- I,
1090
+ A,
1091
1091
  {
1092
1092
  as: "div",
1093
1093
  "data-switch-group": !0,
1094
- ref: y,
1095
- classNames: g,
1094
+ ref: v,
1095
+ classNames: N,
1096
1096
  role: "group",
1097
1097
  "aria-label": a,
1098
- style: $ ? { gridTemplateColumns: `repeat(${$}, 1fr)` } : void 0,
1098
+ style: x ? { gridTemplateColumns: `repeat(${x}, 1fr)` } : void 0,
1099
1099
  ...L,
1100
- children: n.map((B, M) => {
1101
- const { id: V, value: C, label: P, ...w } = B, H = V || `${e}-option-${M}`, F = O.includes(C);
1100
+ children: n.map((W, M) => {
1101
+ const { id: V, value: K, label: P, ...y } = W, H = V || `${e}-option-${M}`, F = S.includes(K);
1102
1102
  return /* @__PURE__ */ o(
1103
1103
  _e,
1104
1104
  {
1105
1105
  id: H,
1106
- name: x,
1106
+ name: R,
1107
1107
  label: P,
1108
1108
  checked: F,
1109
- disabled: k || B.disabled,
1110
- size: N,
1109
+ disabled: $ || W.disabled,
1110
+ size: k,
1111
1111
  labelFirst: h,
1112
- onChange: (S) => D(C, S),
1113
- ...w
1112
+ onChange: (O) => D(K, O),
1113
+ ...y
1114
1114
  },
1115
1115
  H
1116
1116
  );
@@ -1122,7 +1122,7 @@ const Ft = b.forwardRef(
1122
1122
  }
1123
1123
  );
1124
1124
  Ft.displayName = "SwitchGroup";
1125
- const tt = b.forwardRef(
1125
+ const tt = g.forwardRef(
1126
1126
  ({
1127
1127
  "aria-label": e,
1128
1128
  "aria-invalid": t,
@@ -1137,107 +1137,109 @@ const tt = b.forwardRef(
1137
1137
  onChange: d,
1138
1138
  className: f = "",
1139
1139
  instructionMainText: p = "Drag and drop or click to upload",
1140
- instructionSubText: k = "You can add multiple files",
1141
- invalid: N,
1142
- id: $,
1140
+ instructionSubText: $ = "You can add multiple files",
1141
+ invalid: k,
1142
+ id: x,
1143
1143
  name: h,
1144
1144
  badgeBgColour: L,
1145
- badgeTextColour: y,
1146
- ...x
1147
- }, O) => {
1148
- const [E, D] = j([]), [g, B] = j(!1), M = J(null), V = (m) => {
1149
- m.preventDefault(), m.stopPropagation(), B(!0);
1150
- }, C = (m) => {
1151
- m.preventDefault(), m.stopPropagation(), B(!1);
1145
+ badgeTextColour: v,
1146
+ size: R,
1147
+ ...S
1148
+ }, E) => {
1149
+ const [D, N] = j([]), [W, M] = j(!1), V = Y(null), K = (m) => {
1150
+ m.preventDefault(), m.stopPropagation(), M(!0);
1152
1151
  }, P = (m) => {
1153
- m.preventDefault(), m.stopPropagation(), B(!1);
1154
- const v = Array.from(m.dataTransfer.files);
1155
- w(v);
1156
- }, w = (m) => {
1152
+ m.preventDefault(), m.stopPropagation(), M(!1);
1153
+ }, y = (m) => {
1154
+ m.preventDefault(), m.stopPropagation(), M(!1);
1155
+ const b = Array.from(m.dataTransfer.files);
1156
+ H(b);
1157
+ }, H = (m) => {
1157
1158
  if (i)
1158
- D((v) => [...v, ...m]), d == null || d([...E, ...m]);
1159
+ N((b) => [...b, ...m]), d == null || d([...D, ...m]);
1159
1160
  else {
1160
- const v = m[0];
1161
- D([v]), d == null || d([v]);
1161
+ const b = m[0];
1162
+ N([b]), d == null || d([b]);
1162
1163
  }
1163
- }, H = (m) => {
1164
+ }, F = (m) => {
1164
1165
  if (m.target.files) {
1165
- const v = Array.from(m.target.files);
1166
- w(v);
1166
+ const b = Array.from(m.target.files);
1167
+ H(b);
1167
1168
  }
1168
- }, F = (m) => {
1169
- const v = E.filter((R, A) => A !== m);
1170
- D(v), d == null || d(v);
1171
- }, S = () => {
1169
+ }, O = (m) => {
1170
+ const b = D.filter((I, B) => B !== m);
1171
+ N(b), d == null || d(b);
1172
+ }, w = () => {
1172
1173
  var m;
1173
- (m = M.current) == null || m.click();
1174
+ (m = V.current) == null || m.click();
1174
1175
  };
1175
1176
  return /* @__PURE__ */ o(
1176
1177
  ee,
1177
1178
  {
1178
1179
  label: a,
1179
- htmlFor: $,
1180
+ htmlFor: x,
1180
1181
  helpText: r,
1181
1182
  errorText: c,
1182
1183
  required: n,
1184
+ size: R,
1183
1185
  children: /* @__PURE__ */ T(
1184
- G,
1186
+ C,
1185
1187
  {
1186
1188
  "data-file-upload-area": !0,
1187
- ref: O,
1189
+ ref: E,
1188
1190
  className: [
1189
1191
  "file-upload-wrapper",
1190
- g ? "dragging" : "",
1192
+ W ? "dragging" : "",
1191
1193
  f
1192
1194
  ].filter(Boolean).join(" "),
1193
1195
  "aria-label": e || a,
1194
- "aria-invalid": t || N || void 0,
1196
+ "aria-invalid": t || k || void 0,
1195
1197
  "aria-required": n,
1196
1198
  children: [
1197
1199
  /* @__PURE__ */ T(
1198
- G,
1200
+ C,
1199
1201
  {
1200
1202
  className: "file-upload-area",
1201
- onDragOver: V,
1202
- onDragLeave: C,
1203
- onDrop: P,
1204
- onClick: S,
1203
+ onDragOver: K,
1204
+ onDragLeave: P,
1205
+ onDrop: y,
1206
+ onClick: w,
1205
1207
  style: { height: u },
1206
1208
  children: [
1207
1209
  /* @__PURE__ */ o(
1208
1210
  "input",
1209
1211
  {
1210
- ref: M,
1212
+ ref: V,
1211
1213
  type: "file",
1212
- id: $,
1214
+ id: x,
1213
1215
  name: h,
1214
- onChange: H,
1216
+ onChange: F,
1215
1217
  multiple: i,
1216
1218
  accept: s,
1217
1219
  capture: l,
1218
1220
  className: "file-input"
1219
1221
  }
1220
1222
  ),
1221
- p && /* @__PURE__ */ T(G, { className: "file-upload-content", children: [
1222
- /* @__PURE__ */ o(Y, { children: p }),
1223
- k && /* @__PURE__ */ o(Y, { isSubtext: !0, children: k })
1223
+ p && /* @__PURE__ */ T(C, { className: "file-upload-content", children: [
1224
+ /* @__PURE__ */ o(J, { children: p }),
1225
+ $ && /* @__PURE__ */ o(J, { isSubtext: !0, children: $ })
1224
1226
  ] })
1225
1227
  ]
1226
1228
  }
1227
1229
  ),
1228
- E.length > 0 && /* @__PURE__ */ o(G, { className: "uploaded-files", children: E.map((m, v) => /* @__PURE__ */ o(
1229
- Oe,
1230
+ D.length > 0 && /* @__PURE__ */ o(C, { className: "uploaded-files", children: D.map((m, b) => /* @__PURE__ */ o(
1231
+ Be,
1230
1232
  {
1231
1233
  size: "small",
1232
1234
  shape: "rounded",
1233
1235
  actionIcon: "cross",
1234
- onActionClick: () => F(v),
1236
+ onActionClick: () => O(b),
1235
1237
  actionAriaLabel: `Remove ${m.name}`,
1236
1238
  bgColour: L,
1237
- textColour: y,
1239
+ textColour: v,
1238
1240
  children: m.name
1239
1241
  },
1240
- `${m.name}-${v}`
1242
+ `${m.name}-${b}`
1241
1243
  )) })
1242
1244
  ]
1243
1245
  }
@@ -1247,7 +1249,7 @@ const tt = b.forwardRef(
1247
1249
  }
1248
1250
  );
1249
1251
  tt.displayName = "FileUpload";
1250
- const Re = b.forwardRef(
1252
+ const Te = g.forwardRef(
1251
1253
  ({
1252
1254
  // FormItem props
1253
1255
  label: e,
@@ -1265,130 +1267,130 @@ const Re = b.forwardRef(
1265
1267
  validateThis: d,
1266
1268
  valid: f,
1267
1269
  invalid: p,
1268
- validationState: k,
1270
+ validationState: $,
1269
1271
  // Handlers
1270
- onChange: N,
1271
- onBlur: $,
1272
+ onChange: k,
1273
+ onBlur: x,
1272
1274
  onFocus: h,
1273
1275
  // Aria
1274
1276
  "aria-label": L,
1275
- "aria-invalid": y,
1277
+ "aria-invalid": v,
1276
1278
  // Input props
1277
- id: x,
1278
- name: O,
1279
+ id: R,
1280
+ name: S,
1279
1281
  value: E,
1280
1282
  defaultValue: D,
1281
- type: g = "text",
1282
- placeholder: B,
1283
+ type: N = "text",
1284
+ placeholder: W,
1283
1285
  autoComplete: M,
1284
1286
  maxLength: V,
1285
- minLength: C,
1287
+ minLength: K,
1286
1288
  pattern: P,
1287
- readOnly: w,
1289
+ readOnly: y,
1288
1290
  disabled: H,
1289
1291
  className: F,
1290
- ...S
1291
- }, m) => {
1292
- const v = J(null), R = J(null), A = J(null), [z, K] = j(!1), [Z, ne] = j(null), te = k ?? (d ? Z : null), ae = b.useCallback(
1293
- (U) => {
1294
- A.current = U, typeof m == "function" ? m(U) : m && (m.current = U);
1292
+ ...O
1293
+ }, w) => {
1294
+ const m = Y(null), b = Y(null), I = Y(null), [B, _] = j(!1), [Z, ie] = j(null), te = $ ?? (d ? Z : null), ae = g.useCallback(
1295
+ (q) => {
1296
+ I.current = q, typeof w == "function" ? w(q) : w && (w.current = q);
1295
1297
  },
1296
- [m]
1297
- ), W = () => {
1298
- const U = A.current;
1299
- if (!U || U.value === "") {
1300
- ne(null);
1298
+ [w]
1299
+ ), re = () => {
1300
+ const q = I.current;
1301
+ if (!q || q.value === "") {
1302
+ ie(null);
1301
1303
  return;
1302
1304
  }
1303
- ne(U.validity.valid ? "valid" : "invalid");
1304
- }, X = (U) => {
1305
- N == null || N(U.target.value), z && d && W();
1306
- }, Q = (U) => {
1307
- K(!0), d && W(), $ == null || $(U);
1308
- }, ce = (U) => {
1309
- h == null || h(U);
1305
+ ie(q.validity.valid ? "valid" : "invalid");
1306
+ }, $e = (q) => {
1307
+ k == null || k(q.target.value), B && d && re();
1308
+ }, we = (q) => {
1309
+ _(!0), d && re(), x == null || x(q);
1310
+ }, z = (q) => {
1311
+ h == null || h(q);
1310
1312
  };
1311
- q(() => {
1312
- const U = (me, ye) => {
1313
- if (!me) return;
1314
- const de = me.closest("[data-form-item]");
1315
- de == null || de.style.setProperty(
1316
- `--side-element-${ye}-width`,
1317
- `${me.getBoundingClientRect().width}px`
1313
+ U(() => {
1314
+ const q = (he, be) => {
1315
+ if (!he) return;
1316
+ const ue = he.closest("[data-form-item]");
1317
+ ue == null || ue.style.setProperty(
1318
+ `--side-element-${be}-width`,
1319
+ `${he.getBoundingClientRect().width}px`
1318
1320
  );
1319
1321
  };
1320
- (l || s) && U(v.current, "left"), (u || i) && U(R.current, "right");
1322
+ (l || s) && q(m.current, "left"), (u || i) && q(b.current, "right");
1321
1323
  }, [l, u, s, i]);
1322
- const Me = (U, me, ye) => {
1323
- if (!U) return null;
1324
- const de = typeof U == "string", we = b.isValidElement(U) ? U.props : {}, Ne = !de && b.isValidElement(U) && (we.onClick || we.onKeyDown || U.type === "button" || U.type === "a");
1324
+ const X = (q, he, be) => {
1325
+ if (!q) return null;
1326
+ const ue = typeof q == "string", ge = g.isValidElement(q) ? q.props : {}, Re = !ue && g.isValidElement(q) && (ge.onClick || ge.onKeyDown || q.type === "button" || q.type === "a");
1325
1327
  return /* @__PURE__ */ o(
1326
- G,
1328
+ C,
1327
1329
  {
1328
- ref: ye,
1330
+ ref: be,
1329
1331
  "data-input-side-element": !0,
1330
- className: `${me} ${de ? "is-text" : "is-icon"} ${Ne ? "is-interactive" : ""}`,
1332
+ className: `${he} ${ue ? "is-text" : "is-icon"} ${Re ? "is-interactive" : ""}`,
1331
1333
  "aria-hidden": "true",
1332
- children: U
1334
+ children: q
1333
1335
  }
1334
1336
  );
1335
- }, Ee = !!(s || l), Pe = !!(i || u), { wrapperProps: Ve, inputProps: Te } = le(S);
1337
+ }, Q = !!(s || l), se = !!(i || u), { wrapperProps: xe, inputProps: De } = de(O);
1336
1338
  return /* @__PURE__ */ T(
1337
1339
  ee,
1338
1340
  {
1339
1341
  label: e,
1340
- htmlFor: x,
1342
+ htmlFor: R,
1341
1343
  helpText: a,
1342
1344
  errorText: r,
1343
1345
  validationState: te,
1344
1346
  required: n,
1345
1347
  size: c,
1346
- ...Ve,
1348
+ ...xe,
1347
1349
  children: [
1348
1350
  /* @__PURE__ */ o(
1349
- I,
1351
+ A,
1350
1352
  {
1351
1353
  as: "input",
1352
1354
  ref: ae,
1353
1355
  "data-input-field": !0,
1354
- id: x,
1355
- name: O,
1356
- type: g,
1356
+ id: R,
1357
+ name: S,
1358
+ type: N,
1357
1359
  value: E,
1358
1360
  defaultValue: D,
1359
- placeholder: B || " ",
1361
+ placeholder: W || " ",
1360
1362
  autoComplete: M,
1361
1363
  maxLength: V,
1362
- minLength: C,
1364
+ minLength: K,
1363
1365
  pattern: P,
1364
- readOnly: w,
1366
+ readOnly: y,
1365
1367
  disabled: H,
1366
1368
  required: n,
1367
1369
  className: [
1368
1370
  F,
1369
- Ee && "with-left-element",
1370
- Pe && "with-right-element"
1371
+ Q && "with-left-element",
1372
+ se && "with-right-element"
1371
1373
  ].filter(Boolean).join(" "),
1372
1374
  "aria-label": L || e,
1373
- "aria-invalid": y || p,
1375
+ "aria-invalid": v || p,
1374
1376
  "aria-required": n,
1375
- onChange: X,
1376
- onBlur: Q,
1377
- onFocus: ce,
1378
- ...Te
1377
+ onChange: $e,
1378
+ onBlur: we,
1379
+ onFocus: z,
1380
+ ...De
1379
1381
  }
1380
1382
  ),
1381
- (Ee || Pe) && /* @__PURE__ */ T(G, { "data-input-helper": !0, "aria-hidden": "true", children: [
1382
- Me(s || l, "left", v),
1383
- Me(i || u, "right", R)
1383
+ (Q || se) && /* @__PURE__ */ T(C, { "data-input-helper": !0, "aria-hidden": "true", children: [
1384
+ X(s || l, "left", m),
1385
+ X(i || u, "right", b)
1384
1386
  ] })
1385
1387
  ]
1386
1388
  }
1387
1389
  );
1388
1390
  }
1389
1391
  );
1390
- Re.displayName = "InputField";
1391
- const at = b.forwardRef(
1392
+ Te.displayName = "InputField";
1393
+ const at = g.forwardRef(
1392
1394
  ({
1393
1395
  desktopSpan: e,
1394
1396
  mobileSpan: t,
@@ -1400,7 +1402,7 @@ const at = b.forwardRef(
1400
1402
  }, i) => {
1401
1403
  let l = [];
1402
1404
  return e || a || r || t ? (e && l.push(`${e}`), a && l.push(`${a}-on-tablet-landscape`), r && l.push(`${r}-on-tablet-portrait`), t && l.push(`${t}-on-mobile`)) : l.push("whole"), c && l.push("horizontal"), /* @__PURE__ */ o(
1403
- I,
1405
+ A,
1404
1406
  {
1405
1407
  as: "div",
1406
1408
  "data-portion": !0,
@@ -1413,7 +1415,7 @@ const at = b.forwardRef(
1413
1415
  }
1414
1416
  );
1415
1417
  at.displayName = "Portion";
1416
- const rt = b.forwardRef(
1418
+ const rt = g.forwardRef(
1417
1419
  ({
1418
1420
  id: e,
1419
1421
  name: t,
@@ -1428,11 +1430,11 @@ const rt = b.forwardRef(
1428
1430
  labelFirst: d,
1429
1431
  ...f
1430
1432
  }, p) => {
1431
- const k = ve(() => t || e, [t, e]), N = (L) => {
1433
+ const $ = ye(() => t || e, [t, e]), k = (L) => {
1432
1434
  L.target.checked && s && s(a);
1433
- }, { wrapperProps: $, inputProps: h } = le(f);
1435
+ }, { wrapperProps: x, inputProps: h } = de(f);
1434
1436
  return /* @__PURE__ */ o(
1435
- I,
1437
+ A,
1436
1438
  {
1437
1439
  as: "div",
1438
1440
  "data-radio-button": !0,
@@ -1441,7 +1443,7 @@ const rt = b.forwardRef(
1441
1443
  "aria-checked": i,
1442
1444
  "aria-disabled": l,
1443
1445
  className: d ? "label-first" : void 0,
1444
- ...$,
1446
+ ...x,
1445
1447
  children: /* @__PURE__ */ T(
1446
1448
  ee,
1447
1449
  {
@@ -1453,22 +1455,22 @@ const rt = b.forwardRef(
1453
1455
  labelFirst: d,
1454
1456
  children: [
1455
1457
  /* @__PURE__ */ o(
1456
- I,
1458
+ A,
1457
1459
  {
1458
1460
  as: "input",
1459
1461
  type: "radio",
1460
1462
  id: e,
1461
- name: k,
1463
+ name: $,
1462
1464
  value: a,
1463
1465
  checked: i,
1464
1466
  disabled: l,
1465
1467
  required: u,
1466
- onChange: N,
1468
+ onChange: k,
1467
1469
  ...h
1468
1470
  }
1469
1471
  ),
1470
1472
  /* @__PURE__ */ o(
1471
- I,
1473
+ A,
1472
1474
  {
1473
1475
  as: d ? "label" : "div",
1474
1476
  htmlFor: d ? e : void 0,
@@ -1483,7 +1485,7 @@ const rt = b.forwardRef(
1483
1485
  }
1484
1486
  );
1485
1487
  rt.displayName = "RadioButton";
1486
- const st = b.forwardRef(
1488
+ const st = g.forwardRef(
1487
1489
  ({
1488
1490
  id: e,
1489
1491
  name: t,
@@ -1498,17 +1500,17 @@ const st = b.forwardRef(
1498
1500
  equaliseWidth: d,
1499
1501
  equalizeWidth: f,
1500
1502
  required: p,
1501
- disabled: k,
1502
- size: N,
1503
- columns: $,
1503
+ disabled: $,
1504
+ size: k,
1505
+ columns: x,
1504
1506
  labelFirst: h,
1505
1507
  ...L
1506
- }, y) => {
1507
- const x = ve(() => t || e, [t, e]), O = (D) => {
1508
+ }, v) => {
1509
+ const R = ye(() => t || e, [t, e]), S = (D) => {
1508
1510
  l == null || l(D.target.value);
1509
1511
  };
1510
1512
  let E = [];
1511
- return u && E.push(`align-${u}`), (d || f) && E.push("equalise-width"), $ && E.push("with-columns"), h && E.push("label-first"), /* @__PURE__ */ o(
1513
+ return u && E.push(`align-${u}`), (d || f) && E.push("equalise-width"), x && E.push("with-columns"), h && E.push("label-first"), /* @__PURE__ */ o(
1512
1514
  ee,
1513
1515
  {
1514
1516
  label: a,
@@ -1516,26 +1518,26 @@ const st = b.forwardRef(
1516
1518
  helpText: r,
1517
1519
  errorText: c,
1518
1520
  required: p,
1519
- size: N,
1521
+ size: k,
1520
1522
  children: /* @__PURE__ */ o(
1521
- I,
1523
+ A,
1522
1524
  {
1523
1525
  as: "div",
1524
1526
  "data-radio-group": !0,
1525
- ref: y,
1527
+ ref: v,
1526
1528
  classNames: E,
1527
1529
  role: "radiogroup",
1528
1530
  "aria-label": a,
1529
- style: $ ? { gridTemplateColumns: `repeat(${$}, 1fr)` } : void 0,
1531
+ style: x ? { gridTemplateColumns: `repeat(${x}, 1fr)` } : void 0,
1530
1532
  ...L,
1531
- children: n.map((D, g) => {
1532
- const { id: B, value: M, label: V, ...C } = D, P = B || `${e}-option-${g}`, w = s ? s === M : i === M;
1533
+ children: n.map((D, N) => {
1534
+ const { id: W, value: M, label: V, ...K } = D, P = W || `${e}-option-${N}`, y = s ? s === M : i === M;
1533
1535
  return /* @__PURE__ */ T(
1534
- G,
1536
+ C,
1535
1537
  {
1536
1538
  "data-radio-button": !0,
1537
1539
  role: "radio",
1538
- "aria-checked": w,
1540
+ "aria-checked": y,
1539
1541
  className: h ? "label-first" : void 0,
1540
1542
  children: [
1541
1543
  /* @__PURE__ */ o(
@@ -1543,16 +1545,16 @@ const st = b.forwardRef(
1543
1545
  {
1544
1546
  type: "radio",
1545
1547
  id: P,
1546
- name: x,
1548
+ name: R,
1547
1549
  value: M,
1548
- checked: w,
1549
- disabled: k,
1550
- onChange: O,
1551
- ...C
1550
+ checked: y,
1551
+ disabled: $,
1552
+ onChange: S,
1553
+ ...K
1552
1554
  }
1553
1555
  ),
1554
1556
  /* @__PURE__ */ o("label", { htmlFor: P, children: V }),
1555
- h ? /* @__PURE__ */ o("label", { htmlFor: P, "data-radio": !0 }) : /* @__PURE__ */ o(G, { "data-radio": !0 })
1557
+ h ? /* @__PURE__ */ o("label", { htmlFor: P, "data-radio": !0 }) : /* @__PURE__ */ o(C, { "data-radio": !0 })
1556
1558
  ]
1557
1559
  },
1558
1560
  P
@@ -1565,7 +1567,7 @@ const st = b.forwardRef(
1565
1567
  }
1566
1568
  );
1567
1569
  st.displayName = "RadioGroup";
1568
- const nt = b.forwardRef(
1570
+ const nt = g.forwardRef(
1569
1571
  ({
1570
1572
  layout: e = "grid",
1571
1573
  gutters: t = "medium",
@@ -1581,7 +1583,7 @@ const nt = b.forwardRef(
1581
1583
  return e && d.push(`layout-${e}`), t && d.push(t === "none" ? "no-gutters" : `${t}-gutters`), a && d.push("retain-layout-on-tablet-landscape"), r && d.push("retain-layout-on-tablet-portrait"), c && d.push("retain-layout-on-mobile"), n && d.push(
1582
1584
  "retain-layout-on-tablet-landscape retain-layout-on-tablet-portrait retain-layout-on-mobile"
1583
1585
  ), s && d.push("allow-ultra-wide"), /* @__PURE__ */ o(
1584
- I,
1586
+ A,
1585
1587
  {
1586
1588
  as: "div",
1587
1589
  "data-row": !0,
@@ -1596,7 +1598,7 @@ const nt = b.forwardRef(
1596
1598
  }
1597
1599
  );
1598
1600
  nt.displayName = "Row";
1599
- const ot = b.forwardRef(
1601
+ const ot = g.forwardRef(
1600
1602
  ({
1601
1603
  // FormItem props
1602
1604
  label: e,
@@ -1613,26 +1615,26 @@ const ot = b.forwardRef(
1613
1615
  className: d,
1614
1616
  ...f
1615
1617
  }, p) => {
1616
- const k = ve(() => s || n, [s, n]), N = (x) => /* @__PURE__ */ o(
1617
- I,
1618
+ const $ = ye(() => s || n, [s, n]), k = (R) => /* @__PURE__ */ o(
1619
+ A,
1618
1620
  {
1619
1621
  as: "option",
1620
- value: x.value,
1621
- disabled: x.disabled,
1622
- children: x.label
1622
+ value: R.value,
1623
+ disabled: R.disabled,
1624
+ children: R.label
1623
1625
  },
1624
- x.value
1625
- ), $ = (x) => /* @__PURE__ */ o(
1626
- I,
1626
+ R.value
1627
+ ), x = (R) => /* @__PURE__ */ o(
1628
+ A,
1627
1629
  {
1628
1630
  as: "optgroup",
1629
- label: x.label,
1630
- children: x.options.map(N)
1631
+ label: R.label,
1632
+ children: R.options.map(k)
1631
1633
  },
1632
- x.label
1633
- ), h = (x) => {
1634
- l == null || l(x.target.value);
1635
- }, { wrapperProps: L, inputProps: y } = le(f);
1634
+ R.label
1635
+ ), h = (R) => {
1636
+ l == null || l(R.target.value);
1637
+ }, { wrapperProps: L, inputProps: v } = de(f);
1636
1638
  return /* @__PURE__ */ o(
1637
1639
  ee,
1638
1640
  {
@@ -1643,19 +1645,19 @@ const ot = b.forwardRef(
1643
1645
  required: r,
1644
1646
  size: c,
1645
1647
  ...L,
1646
- children: /* @__PURE__ */ o(G, { "data-select": !0, className: d, disabled: u, children: /* @__PURE__ */ o(
1647
- I,
1648
+ children: /* @__PURE__ */ o(C, { "data-select": !0, className: d, disabled: u, children: /* @__PURE__ */ o(
1649
+ A,
1648
1650
  {
1649
1651
  as: "select",
1650
1652
  ref: p,
1651
1653
  id: n,
1652
- name: k,
1654
+ name: $,
1653
1655
  disabled: u,
1654
1656
  required: r,
1655
1657
  onChange: h,
1656
- ...y,
1658
+ ...v,
1657
1659
  children: i.map(
1658
- (x) => "options" in x ? $(x) : N(x)
1660
+ (R) => "options" in R ? x(R) : k(R)
1659
1661
  )
1660
1662
  }
1661
1663
  ) })
@@ -1664,7 +1666,7 @@ const ot = b.forwardRef(
1664
1666
  }
1665
1667
  );
1666
1668
  ot.displayName = "Select";
1667
- const je = (e, t) => e > t ? "exceeded" : e >= t * 0.9 ? "warning" : "normal", De = (e, t, a) => Math.abs(e) === 1 ? t : a, it = b.forwardRef(
1669
+ const je = (e, t) => e > t ? "exceeded" : e >= t * 0.9 ? "warning" : "normal", Ie = (e, t, a) => Math.abs(e) === 1 ? t : a, it = g.forwardRef(
1668
1670
  ({
1669
1671
  // FormItem props
1670
1672
  label: e,
@@ -1682,59 +1684,59 @@ const je = (e, t) => e > t ? "exceeded" : e >= t * 0.9 ? "warning" : "normal", D
1682
1684
  id: d,
1683
1685
  name: f,
1684
1686
  rows: p,
1685
- cols: k,
1686
- minLength: N,
1687
- maxLength: $,
1687
+ cols: $,
1688
+ minLength: k,
1689
+ maxLength: x,
1688
1690
  placeholder: h,
1689
1691
  readOnly: L,
1690
- disabled: y,
1691
- autoComplete: x,
1692
+ disabled: v,
1693
+ autoComplete: R,
1692
1694
  // Validation (unused but destructured to not pass to DOM)
1693
- validateThis: O,
1695
+ validateThis: S,
1694
1696
  valid: E,
1695
1697
  invalid: D,
1696
- ...g
1697
- }, B) => {
1698
- const M = J(null), V = (F) => {
1698
+ ...N
1699
+ }, W) => {
1700
+ const M = Y(null), V = (F) => {
1699
1701
  s == null || s(F.target.value);
1700
- }, C = () => {
1702
+ }, K = () => {
1701
1703
  const F = [];
1702
1704
  if (l) {
1703
- const S = i.length, m = je(S, l), v = Math.max(0, S - l), R = l - S;
1705
+ const O = i.length, w = je(O, l), m = Math.max(0, O - l), b = l - O;
1704
1706
  F.push(
1705
- /* @__PURE__ */ o("span", { className: `limit-${m}`, children: v > 0 ? `${v} ${De(v, "char", "chars")} over limit` : `${R} ${De(R, "char", "chars")} left` }, "char-limit")
1707
+ /* @__PURE__ */ o("span", { className: `limit-${w}`, children: m > 0 ? `${m} ${Ie(m, "char", "chars")} over limit` : `${b} ${Ie(b, "char", "chars")} left` }, "char-limit")
1706
1708
  );
1707
1709
  }
1708
1710
  if (u) {
1709
- const S = i.trim().split(/\s+/).filter(Boolean).length, m = je(S, u), v = Math.max(0, S - u), R = u - S;
1711
+ const O = i.trim().split(/\s+/).filter(Boolean).length, w = je(O, u), m = Math.max(0, O - u), b = u - O;
1710
1712
  F.push(
1711
- /* @__PURE__ */ o("span", { className: `limit-${m}`, children: v > 0 ? `${v} ${De(v, "word", "words")} over limit` : `${R} ${De(R, "word", "words")} left` }, "word-limit")
1713
+ /* @__PURE__ */ o("span", { className: `limit-${w}`, children: m > 0 ? `${m} ${Ie(m, "word", "words")} over limit` : `${b} ${Ie(b, "word", "words")} left` }, "word-limit")
1712
1714
  );
1713
1715
  }
1714
1716
  if (!(!F.length && !a))
1715
- return /* @__PURE__ */ T($e, { children: [
1717
+ return /* @__PURE__ */ T(Ee, { children: [
1716
1718
  a,
1717
1719
  a && F.length > 0 && /* @__PURE__ */ o("span", { className: "separator", children: " • " }),
1718
- F.map((S, m) => /* @__PURE__ */ T(b.Fragment, { children: [
1719
- m > 0 && /* @__PURE__ */ o("span", { className: "separator", children: " • " }),
1720
- S
1721
- ] }, m))
1720
+ F.map((O, w) => /* @__PURE__ */ T(g.Fragment, { children: [
1721
+ w > 0 && /* @__PURE__ */ o("span", { className: "separator", children: " • " }),
1722
+ O
1723
+ ] }, w))
1722
1724
  ] });
1723
1725
  }, P = (F) => {
1724
- M.current = F, typeof B == "function" ? B(F) : B && (B.current = F);
1725
- }, { wrapperProps: w, inputProps: H } = le(g);
1726
+ M.current = F, typeof W == "function" ? W(F) : W && (W.current = F);
1727
+ }, { wrapperProps: y, inputProps: H } = de(N);
1726
1728
  return /* @__PURE__ */ o(
1727
1729
  ee,
1728
1730
  {
1729
1731
  label: e,
1730
1732
  htmlFor: d,
1731
- helpText: C(),
1733
+ helpText: K(),
1732
1734
  errorText: r,
1733
1735
  required: n,
1734
1736
  size: c,
1735
- ...w,
1737
+ ...y,
1736
1738
  children: /* @__PURE__ */ o(
1737
- I,
1739
+ A,
1738
1740
  {
1739
1741
  as: "textarea",
1740
1742
  ref: P,
@@ -1743,14 +1745,14 @@ const je = (e, t) => e > t ? "exceeded" : e >= t * 0.9 ? "warning" : "normal", D
1743
1745
  name: f,
1744
1746
  value: i,
1745
1747
  rows: p,
1746
- cols: k,
1747
- minLength: N,
1748
- maxLength: $,
1748
+ cols: $,
1749
+ minLength: k,
1750
+ maxLength: x,
1749
1751
  placeholder: h,
1750
1752
  readOnly: L,
1751
- disabled: y,
1753
+ disabled: v,
1752
1754
  required: n,
1753
- autoComplete: x,
1755
+ autoComplete: R,
1754
1756
  onChange: V,
1755
1757
  ...H
1756
1758
  }
@@ -1763,9 +1765,9 @@ it.displayName = "TextArea";
1763
1765
  const Wt = {
1764
1766
  Checkbox: He,
1765
1767
  Switch: _e,
1766
- InputField: Re,
1768
+ InputField: Te,
1767
1769
  FileUpload: tt,
1768
- InputLabel: xe,
1770
+ InputLabel: Pe,
1769
1771
  RadioButton: rt,
1770
1772
  RadioGroup: st,
1771
1773
  Select: ot,
@@ -1774,9 +1776,9 @@ const Wt = {
1774
1776
  }, zt = (e, t) => {
1775
1777
  const { as: a, name: r, ...c } = e, n = (i) => {
1776
1778
  t(r, i);
1777
- }, s = Wt[a] || Re;
1779
+ }, s = Wt[a] || Te;
1778
1780
  return /* @__PURE__ */ o(
1779
- I,
1781
+ A,
1780
1782
  {
1781
1783
  as: s,
1782
1784
  ...c,
@@ -1804,7 +1806,7 @@ const Wt = {
1804
1806
  }, key: `${c.name}-${n}` }, zt(f, t));
1805
1807
  });
1806
1808
  return /* @__PURE__ */ o(nt, { gutters: a, children: r });
1807
- }, _t = b.forwardRef(
1809
+ }, _t = g.forwardRef(
1808
1810
  ({ spacing: e = "small", fields: t, onFieldsChange: a, children: r, errorText: c, ...n }, s) => {
1809
1811
  let i = [];
1810
1812
  e && i.push(`spacing-${e}`);
@@ -1814,7 +1816,7 @@ const Wt = {
1814
1816
  });
1815
1817
  }, u = t != null && t.length ? Ht(t, l, e) : r;
1816
1818
  return /* @__PURE__ */ T(
1817
- I,
1819
+ A,
1818
1820
  {
1819
1821
  as: "form",
1820
1822
  "data-form": !0,
@@ -1830,7 +1832,7 @@ const Wt = {
1830
1832
  }
1831
1833
  );
1832
1834
  _t.displayName = "Form";
1833
- const Gt = b.forwardRef(
1835
+ const Gt = g.forwardRef(
1834
1836
  ({
1835
1837
  isJoint: e,
1836
1838
  equalWidthForChildren: t,
@@ -1843,7 +1845,7 @@ const Gt = b.forwardRef(
1843
1845
  const l = n || `form-group-${Math.random().toString(36).substring(2, 9)}`;
1844
1846
  let u = [];
1845
1847
  return e && u.push("is-joint"), t && u.push("equal-width-for-children"), a && u.push("retain-layout"), /* @__PURE__ */ o(
1846
- I,
1848
+ A,
1847
1849
  {
1848
1850
  as: "div",
1849
1851
  "data-form-item-group": !0,
@@ -1859,7 +1861,7 @@ const Gt = b.forwardRef(
1859
1861
  }
1860
1862
  );
1861
1863
  Gt.displayName = "FormItemGroup";
1862
- const Kt = (e, t) => {
1864
+ const Ct = (e, t) => {
1863
1865
  const a = [], r = e.length, c = t.length;
1864
1866
  if (r === 0) return c;
1865
1867
  if (c === 0) return r;
@@ -1878,7 +1880,7 @@ const Kt = (e, t) => {
1878
1880
  // Substitution
1879
1881
  );
1880
1882
  return a[c][r];
1881
- }, Ct = (e, t) => {
1883
+ }, Kt = (e, t) => {
1882
1884
  let a = 0, r = 0;
1883
1885
  for (; a < e.length && r < t.length; )
1884
1886
  e[a] === t[r] && a++, r++;
@@ -1887,9 +1889,9 @@ const Kt = (e, t) => {
1887
1889
  if (!t) return e;
1888
1890
  const a = t.toLowerCase().trim(), r = Math.floor(a.length / 2);
1889
1891
  return e.map((n) => {
1890
- const s = n.label.toLowerCase(), i = Kt(a, s), l = s.split(/[\s\-_]+/), u = a.split(/[\s\-_]+/), d = s.includes(a) || u.every(
1891
- (k) => l.some((N) => N.startsWith(k))
1892
- ), f = jt(s), p = Ct(a, f);
1892
+ const s = n.label.toLowerCase(), i = Ct(a, s), l = s.split(/[\s\-_]+/), u = a.split(/[\s\-_]+/), d = s.includes(a) || u.every(
1893
+ ($) => l.some((k) => k.startsWith($))
1894
+ ), f = jt(s), p = Kt(a, f);
1893
1895
  return {
1894
1896
  option: n,
1895
1897
  distance: i,
@@ -1899,7 +1901,7 @@ const Kt = (e, t) => {
1899
1901
  }).filter(
1900
1902
  ({ distance: n, isPartialMatch: s, isAcronymMatch: i }) => s || i || n <= r
1901
1903
  ).sort((n, s) => n.isPartialMatch && !s.isPartialMatch ? -1 : !n.isPartialMatch && s.isPartialMatch ? 1 : n.isAcronymMatch && !s.isAcronymMatch ? -1 : !n.isAcronymMatch && s.isAcronymMatch ? 1 : n.distance - s.distance).map(({ option: n }) => n);
1902
- }, Ut = b.forwardRef(
1904
+ }, Ut = g.forwardRef(
1903
1905
  ({
1904
1906
  options: e = [],
1905
1907
  label: t,
@@ -1914,92 +1916,98 @@ const Kt = (e, t) => {
1914
1916
  allowMultiSelect: d = !1,
1915
1917
  allowCustomEntries: f = !1,
1916
1918
  isLoading: p,
1917
- value: k,
1918
- isFullWidth: N,
1919
- className: $,
1919
+ value: $,
1920
+ isFullWidth: k,
1921
+ className: x,
1920
1922
  required: h,
1921
1923
  size: L,
1922
- ...y
1923
- }, x) => {
1924
- const [O, E] = j(!1), [D, g] = j(""), [B, M] = j(-1), [V, C] = j(null), [P, w] = j([]);
1925
- q(() => {
1924
+ ...v
1925
+ }, R) => {
1926
+ const [S, E] = j(!1), [D, N] = j(""), [W, M] = j(-1), [V, K] = j(null), [P, y] = j([]), [H, F] = j(!1);
1927
+ U(() => {
1926
1928
  s && i && i(s);
1927
1929
  }, []);
1928
- const H = b.useMemo(() => [...e], [e]), F = J(null), S = J(null), m = n || `listbox-${Math.random().toString(36).substring(2, 9)}`, v = Xt(H, D), R = (W) => {
1929
- if (W.disabled) return;
1930
+ const O = g.useMemo(() => [...e], [e]), w = Y(null), m = Y(null), b = Y(null), I = n || `listbox-${Math.random().toString(36).substring(2, 9)}`, B = Xt(O, D), _ = (z) => {
1931
+ if (z.disabled) return;
1930
1932
  let X;
1931
1933
  if (d) {
1932
- if (P.some((ce) => ce.value === W.value))
1933
- X = P.filter((ce) => ce.value !== W.value);
1934
+ if (P.some((se) => se.value === z.value))
1935
+ X = P.filter((se) => se.value !== z.value);
1934
1936
  else {
1935
1937
  if (u && P.length >= u)
1936
1938
  return;
1937
- X = [...P, W];
1939
+ X = [...P, z];
1938
1940
  }
1939
- w(X), i == null || i(X.map((ce) => ce.value));
1941
+ y(X), i == null || i(X.map((se) => se.value));
1940
1942
  } else
1941
- X = [W], C(W), w(X), i == null || i(W.value), E(!1);
1942
- g(""), M(-1);
1943
- }, A = (W) => {
1944
- g(W);
1945
- }, z = () => {
1943
+ X = [z], K(z), y(X), i == null || i(z.value), E(!1);
1944
+ N(""), M(-1);
1945
+ }, Z = (z) => {
1946
+ N(z);
1947
+ }, ie = () => {
1946
1948
  if (!D.trim() || !f) return;
1947
- const W = D.trim(), X = {
1948
- value: W,
1949
- label: W
1949
+ const z = D.trim(), X = {
1950
+ value: z,
1951
+ label: z
1950
1952
  };
1951
- H.some((Q) => Q.value === W) || R(X);
1952
- }, K = (W) => {
1953
+ O.some((Q) => Q.value === z) || _(X);
1954
+ }, te = (z) => {
1953
1955
  if (d) {
1954
- const X = P.filter((Q) => Q.value !== W);
1955
- w(X), i == null || i(X.map((Q) => Q.value));
1956
+ const X = P.filter((Q) => Q.value !== z);
1957
+ y(X), i == null || i(X.map((Q) => Q.value));
1956
1958
  } else
1957
- C(null), w([]), i == null || i("");
1958
- }, Z = () => {
1959
- C(null), w([]), i == null || i(d ? [] : "");
1960
- }, ne = (W) => {
1961
- switch (W.key) {
1959
+ K(null), y([]), i == null || i("");
1960
+ }, ae = () => {
1961
+ K(null), y([]), i == null || i(d ? [] : "");
1962
+ }, re = (z) => {
1963
+ switch (z.key) {
1962
1964
  case "ArrowDown":
1963
- W.preventDefault(), O ? M(
1964
- (X) => X < v.length - 1 ? X + 1 : X
1965
+ z.preventDefault(), S ? M(
1966
+ (X) => X < B.length - 1 ? X + 1 : X
1965
1967
  ) : (E(!0), M(0));
1966
1968
  break;
1967
1969
  case "ArrowUp":
1968
- W.preventDefault(), M((X) => X > 0 ? X - 1 : X);
1970
+ z.preventDefault(), M((X) => X > 0 ? X - 1 : X);
1969
1971
  break;
1970
1972
  case "Enter":
1971
- if (W.preventDefault(), f && D.trim()) {
1972
- const X = v.find(
1973
+ if (z.preventDefault(), f && D.trim()) {
1974
+ const X = B.find(
1973
1975
  (Q) => Q.label.toLowerCase() === D.trim().toLowerCase()
1974
1976
  );
1975
- X ? R(X) : z();
1976
- } else B >= 0 && v[B] && R(v[B]);
1977
+ X ? _(X) : ie();
1978
+ } else W >= 0 && B[W] && _(B[W]);
1977
1979
  break;
1978
1980
  case "Escape":
1979
- W.preventDefault(), E(!1), M(-1);
1981
+ z.preventDefault(), E(!1), M(-1);
1980
1982
  break;
1981
1983
  case " ":
1982
- O || (W.preventDefault(), E(!0), M(0));
1984
+ S || (z.preventDefault(), E(!0), M(0));
1983
1985
  break;
1984
1986
  case "Home":
1985
- O && (W.preventDefault(), M(0));
1987
+ S && (z.preventDefault(), M(0));
1986
1988
  break;
1987
1989
  case "End":
1988
- O && (W.preventDefault(), M(v.length - 1));
1990
+ S && (z.preventDefault(), M(B.length - 1));
1989
1991
  break;
1990
1992
  }
1991
1993
  };
1992
- We(F, () => {
1994
+ We(w, () => {
1993
1995
  E(!1), M(-1);
1994
- }), q(() => {
1995
- O && S.current && S.current.focus();
1996
- }, [O]), q(() => {
1997
- if (B >= 0) {
1998
- const W = document.querySelector(`[data-index="${B}"]`);
1999
- W == null || W.scrollIntoView({ block: "nearest" });
1996
+ }), U(() => {
1997
+ S && m.current && m.current.focus();
1998
+ }, [S]), U(() => {
1999
+ if (S && w.current) {
2000
+ const z = w.current.getBoundingClientRect(), X = window.innerHeight, Q = 300, se = X - z.bottom, xe = z.top;
2001
+ F(se < Q && xe > se);
2002
+ } else
2003
+ F(!1);
2004
+ }, [S]), U(() => {
2005
+ if (W >= 0) {
2006
+ const z = document.querySelector(`[data-index="${W}"]`);
2007
+ z == null || z.scrollIntoView({ block: "nearest" });
2000
2008
  }
2001
- }, [B]);
2002
- const { wrapperProps: te, inputProps: ae } = le(y);
2009
+ }, [W]);
2010
+ const { wrapperProps: $e, inputProps: we } = de(v);
2003
2011
  return /* @__PURE__ */ o(
2004
2012
  ee,
2005
2013
  {
@@ -2008,46 +2016,46 @@ const Kt = (e, t) => {
2008
2016
  helpText: a,
2009
2017
  errorText: r,
2010
2018
  required: h,
2011
- isFullWidth: N,
2019
+ isFullWidth: k,
2012
2020
  size: L,
2013
- ...te,
2021
+ ...$e,
2014
2022
  children: /* @__PURE__ */ T(
2015
- I,
2023
+ A,
2016
2024
  {
2017
2025
  as: "div",
2018
2026
  "data-list-box": !0,
2019
- classNames: ["list-box-wrapper", l ? "disabled" : "", $ || ""],
2020
- ref: F,
2021
- isFullWidth: N,
2022
- ...ae,
2027
+ classNames: ["list-box-wrapper", l ? "disabled" : "", x || ""],
2028
+ ref: w,
2029
+ isFullWidth: k,
2030
+ ...we,
2023
2031
  children: [
2024
2032
  /* @__PURE__ */ T(
2025
- G,
2033
+ C,
2026
2034
  {
2027
2035
  className: "list-box-input-wrapper",
2028
- onClick: () => !l && E(!O),
2036
+ onClick: () => !l && E(!S),
2029
2037
  role: "combobox",
2030
2038
  "aria-haspopup": "listbox",
2031
- "aria-expanded": O,
2032
- "aria-controls": `${m}-listbox`,
2033
- "aria-owns": `${m}-listbox`,
2039
+ "aria-expanded": S,
2040
+ "aria-controls": `${I}-listbox`,
2041
+ "aria-owns": `${I}-listbox`,
2034
2042
  tabIndex: l ? -1 : 0,
2035
2043
  children: [
2036
- d ? /* @__PURE__ */ T($e, { children: [
2037
- P.length > 0 ? /* @__PURE__ */ T(G, { className: "options-wrapper", children: [
2038
- /* @__PURE__ */ o(G, { className: "options-list", children: P.map((W) => /* @__PURE__ */ o(
2039
- Oe,
2044
+ d ? /* @__PURE__ */ T(Ee, { children: [
2045
+ P.length > 0 ? /* @__PURE__ */ T(C, { className: "options-wrapper", children: [
2046
+ /* @__PURE__ */ o(C, { className: "options-list", children: P.map((z) => /* @__PURE__ */ o(
2047
+ Be,
2040
2048
  {
2041
2049
  actionIcon: "cross",
2042
- onActionClick: () => K(W.value),
2043
- actionAriaLabel: `Remove ${W.label}`,
2050
+ onActionClick: () => te(z.value),
2051
+ actionAriaLabel: `Remove ${z.label}`,
2044
2052
  size: "small",
2045
2053
  shape: "rounded",
2046
- children: /* @__PURE__ */ o(Y, { children: W.label })
2054
+ children: /* @__PURE__ */ o(J, { children: z.label })
2047
2055
  },
2048
- W.value
2056
+ z.value
2049
2057
  )) }),
2050
- u && P.length >= u && /* @__PURE__ */ T(Y, { className: "options-limit-warning", textColour: "red", size: "tiny", children: [
2058
+ u && P.length >= u && /* @__PURE__ */ T(J, { className: "options-limit-warning", textColour: "red", size: "tiny", children: [
2051
2059
  "You can choose only ",
2052
2060
  u,
2053
2061
  " option",
@@ -2055,87 +2063,94 @@ const Kt = (e, t) => {
2055
2063
  ] })
2056
2064
  ] }) : /* @__PURE__ */ o("span", { className: "placeholder", children: c }),
2057
2065
  P.length > 0 && /* @__PURE__ */ o(
2058
- G,
2066
+ C,
2059
2067
  {
2060
2068
  className: "icon-wrapper clear-all",
2061
2069
  title: "Clear all options",
2062
- onClick: () => Z(),
2070
+ onClick: () => ae(),
2063
2071
  children: /* @__PURE__ */ T("svg", { viewBox: "0 0 24 24", children: [
2064
2072
  /* @__PURE__ */ o("line", { x1: "5", y1: "5", x2: "19", y2: "19" }),
2065
2073
  /* @__PURE__ */ o("line", { x1: "5", y1: "19", x2: "19", y2: "5" })
2066
2074
  ] })
2067
2075
  }
2068
2076
  )
2069
- ] }) : P[0] ? /* @__PURE__ */ o(Y, { className: "selected-option", children: P[0].label }) : /* @__PURE__ */ o("span", { className: "placeholder", children: c }),
2070
- /* @__PURE__ */ o(G, { className: "icon-wrapper chevrons", children: /* @__PURE__ */ T("svg", { viewBox: "0 0 24 24", "aria-hidden": "true", children: [
2077
+ ] }) : P[0] ? /* @__PURE__ */ o(J, { className: "selected-option", children: P[0].label }) : /* @__PURE__ */ o("span", { className: "placeholder", children: c }),
2078
+ /* @__PURE__ */ o(C, { className: "icon-wrapper chevrons", children: /* @__PURE__ */ T("svg", { viewBox: "0 0 24 24", "aria-hidden": "true", children: [
2071
2079
  /* @__PURE__ */ o("polyline", { points: "6 9 12 4 18 9" }),
2072
2080
  /* @__PURE__ */ o("polyline", { points: "6 15 12 20 18 15" })
2073
2081
  ] }) })
2074
2082
  ]
2075
2083
  }
2076
2084
  ),
2077
- O && !l && /* @__PURE__ */ T(G, { className: "list-box-dropdown", children: [
2078
- /* @__PURE__ */ T(G, { className: "list-box-search-wrapper", children: [
2079
- /* @__PURE__ */ o(
2080
- Re,
2081
- {
2082
- type: "text",
2083
- ref: S,
2084
- className: "list-box-search",
2085
- placeholder: f ? "Type to search or add new" : "Search",
2086
- value: D,
2087
- onChange: A,
2088
- onKeyDown: ne,
2089
- "aria-controls": `${m}-listbox`,
2090
- "aria-label": "Search options",
2091
- isFullWidth: !0
2092
- }
2093
- ),
2094
- f && D.trim() && !P.some((W) => W.label.toLowerCase() === D.trim().toLowerCase()) && /* @__PURE__ */ o(
2095
- "kbd",
2096
- {
2097
- className: "list-box-enter-key",
2098
- "aria-label": "Press Enter to add custom option",
2099
- children: "↵"
2100
- }
2101
- )
2102
- ] }),
2103
- /* @__PURE__ */ o(
2104
- I,
2105
- {
2106
- as: "ul",
2107
- id: `${m}-listbox`,
2108
- className: "list-box-options",
2109
- role: "listbox",
2110
- "aria-multiselectable": d,
2111
- "aria-busy": p,
2112
- tabIndex: -1,
2113
- children: v.length > 0 ? v.map((W, X) => /* @__PURE__ */ o(
2114
- "li",
2085
+ S && !l && /* @__PURE__ */ T(
2086
+ C,
2087
+ {
2088
+ ref: b,
2089
+ className: `list-box-dropdown${H ? " opens-upward" : ""}`,
2090
+ children: [
2091
+ /* @__PURE__ */ T(C, { className: "list-box-search-wrapper", children: [
2092
+ /* @__PURE__ */ o(
2093
+ Te,
2094
+ {
2095
+ type: "text",
2096
+ ref: m,
2097
+ className: "list-box-search",
2098
+ placeholder: f ? "Type to search or add new" : "Search",
2099
+ value: D,
2100
+ onChange: Z,
2101
+ onKeyDown: re,
2102
+ "aria-controls": `${I}-listbox`,
2103
+ "aria-label": "Search options",
2104
+ isFullWidth: !0
2105
+ }
2106
+ ),
2107
+ f && D.trim() && !P.some((z) => z.label.toLowerCase() === D.trim().toLowerCase()) && /* @__PURE__ */ o(
2108
+ "kbd",
2109
+ {
2110
+ className: "list-box-enter-key",
2111
+ "aria-label": "Press Enter to add custom option",
2112
+ children: "↵"
2113
+ }
2114
+ )
2115
+ ] }),
2116
+ /* @__PURE__ */ o(
2117
+ A,
2115
2118
  {
2116
- id: `${m}-option-${W.value}`,
2117
- className: `list-box-option ${W.disabled ? "disabled" : ""} ${B === X ? "active" : ""}`,
2118
- role: "option",
2119
- "aria-selected": P.some((Q) => Q.value === W.value),
2120
- "aria-disabled": W.disabled,
2121
- onClick: () => R(W),
2122
- "data-index": X,
2119
+ as: "ul",
2120
+ id: `${I}-listbox`,
2121
+ className: "list-box-options",
2122
+ role: "listbox",
2123
+ "aria-multiselectable": d,
2124
+ "aria-busy": p,
2123
2125
  tabIndex: -1,
2124
- children: W.customLabel || W.label
2125
- },
2126
- W.value
2127
- )) : /* @__PURE__ */ o(
2128
- "li",
2129
- {
2130
- className: "list-box-option disabled",
2131
- role: "alert",
2132
- "aria-live": "polite",
2133
- children: f ? "Type and press Enter to add new option" : "No matches found"
2126
+ children: B.length > 0 ? B.map((z, X) => /* @__PURE__ */ o(
2127
+ "li",
2128
+ {
2129
+ id: `${I}-option-${z.value}`,
2130
+ className: `list-box-option ${z.disabled ? "disabled" : ""} ${W === X ? "active" : ""}`,
2131
+ role: "option",
2132
+ "aria-selected": P.some((Q) => Q.value === z.value),
2133
+ "aria-disabled": z.disabled,
2134
+ onClick: () => _(z),
2135
+ "data-index": X,
2136
+ tabIndex: -1,
2137
+ children: z.customLabel || z.label
2138
+ },
2139
+ z.value
2140
+ )) : /* @__PURE__ */ o(
2141
+ "li",
2142
+ {
2143
+ className: "list-box-option disabled",
2144
+ role: "alert",
2145
+ "aria-live": "polite",
2146
+ children: f ? "Type and press Enter to add new option" : "No matches found"
2147
+ }
2148
+ )
2134
2149
  }
2135
2150
  )
2136
- }
2137
- )
2138
- ] })
2151
+ ]
2152
+ }
2153
+ )
2139
2154
  ]
2140
2155
  }
2141
2156
  )
@@ -2147,7 +2162,7 @@ Ut.displayName = "ListBox";
2147
2162
  function Xe(e, t) {
2148
2163
  return (t === "alphanumeric" ? /^[a-zA-Z0-9]+$/i : /^[0-9]+$/).test(e);
2149
2164
  }
2150
- const qt = b.forwardRef(
2165
+ const qt = g.forwardRef(
2151
2166
  ({
2152
2167
  numberOfFields: e,
2153
2168
  onChange: t,
@@ -2161,77 +2176,77 @@ const qt = b.forwardRef(
2161
2176
  ariaLabel: u,
2162
2177
  ...d
2163
2178
  }, f) => {
2164
- const p = J(null), [k, N] = j([]), [$, h] = j([]), [L, y] = j(!0), [x, O] = j(-1), E = d.id || `pin-input-${Math.random().toString(36).substring(2, 9)}`, D = u || "Enter verification code", g = _(
2165
- (S) => {
2166
- var v;
2167
- const m = k[S];
2168
- (v = m == null ? void 0 : m.current) == null || v.focus();
2179
+ const p = Y(null), [$, k] = j([]), [x, h] = j([]), [L, v] = j(!0), [R, S] = j(-1), E = d.id || `pin-input-${Math.random().toString(36).substring(2, 9)}`, D = u || "Enter verification code", N = G(
2180
+ (O) => {
2181
+ var m;
2182
+ const w = $[O];
2183
+ (m = w == null ? void 0 : w.current) == null || m.focus();
2169
2184
  },
2170
- [k]
2171
- ), B = _(
2172
- (S) => {
2185
+ [$]
2186
+ ), W = G(
2187
+ (O) => {
2173
2188
  if (!L) return;
2174
- const m = S + 1 < e ? S + 1 : null;
2175
- m && g(m);
2189
+ const w = O + 1 < e ? O + 1 : null;
2190
+ w && N(w);
2176
2191
  },
2177
- [g, e, L]
2178
- ), M = _(() => {
2179
- h(Array(e).fill("")), t == null || t(""), i && (g(0), O(0));
2180
- }, [e, t, g, i]), V = _(
2181
- (S, m) => {
2182
- const v = [...$];
2183
- v[m] = S, h(v), t == null || t(v.join("")), S !== "" && v.length === e && v.every((A) => A != null && A !== "") && m === e - 1 || (y(!0), B(m));
2192
+ [N, e, L]
2193
+ ), M = G(() => {
2194
+ h(Array(e).fill("")), t == null || t(""), i && (N(0), S(0));
2195
+ }, [e, t, N, i]), V = G(
2196
+ (O, w) => {
2197
+ const m = [...x];
2198
+ m[w] = O, h(m), t == null || t(m.join("")), O !== "" && m.length === e && m.every((I) => I != null && I !== "") && w === e - 1 || (v(!0), W(w));
2184
2199
  },
2185
- [B, e, t, $]
2186
- ), C = _((S, m) => {
2187
- var A;
2188
- const v = typeof S == "string" ? S : S.target.value, R = $[m];
2189
- if (v === "") {
2190
- V("", m);
2200
+ [W, e, t, x]
2201
+ ), K = G((O, w) => {
2202
+ var I;
2203
+ const m = typeof O == "string" ? O : O.target.value, b = x[w];
2204
+ if (m === "") {
2205
+ V("", w);
2191
2206
  return;
2192
2207
  }
2193
- if (v.length > 1 && m < e - 1) {
2194
- if (Xe(v, a)) {
2195
- let z = [];
2196
- const K = v.split("");
2197
- R === "" ? z = K.filter((te, ae) => m + ae < e) : ((A = k[m].current) == null ? void 0 : A.selectionEnd) === v.length ? z = K.filter((ae, W) => W > 0 && m + W - 1 < e) : z = K.filter((ae, W) => W < v.length - 1 && m + W < e);
2198
- const Z = $.map(
2199
- (te, ae) => ae >= m && ae < m + z.length ? z[ae - m] : te
2208
+ if (m.length > 1 && w < e - 1) {
2209
+ if (Xe(m, a)) {
2210
+ let B = [];
2211
+ const _ = m.split("");
2212
+ b === "" ? B = _.filter((te, ae) => w + ae < e) : ((I = $[w].current) == null ? void 0 : I.selectionEnd) === m.length ? B = _.filter((ae, re) => re > 0 && w + re - 1 < e) : B = _.filter((ae, re) => re < m.length - 1 && w + re < e);
2213
+ const Z = x.map(
2214
+ (te, ae) => ae >= w && ae < w + B.length ? B[ae - w] : te
2200
2215
  );
2201
2216
  h(Z), t == null || t(Z.join(""));
2202
- const ne = Math.min(m + z.length, e - 1);
2203
- g(ne);
2217
+ const ie = Math.min(w + B.length, e - 1);
2218
+ N(ie);
2204
2219
  }
2205
2220
  } else {
2206
- let z = v;
2207
- (R == null ? void 0 : R.length) > 0 && (z = v.charAt(v.length - 1)), Xe(z, a) && V(z, m);
2221
+ let B = m;
2222
+ (b == null ? void 0 : b.length) > 0 && (B = m.charAt(m.length - 1)), Xe(B, a) && V(B, w);
2208
2223
  }
2209
- }, [e, t, V, a, $, g, k]), P = _((S, m) => {
2210
- var v;
2211
- if (S.key === "Backspace")
2212
- if (S.target.value === "") {
2213
- if (m > 0) {
2214
- const R = m - 1;
2215
- V("", R), g(R), y(!0);
2224
+ }, [e, t, V, a, x, N, $]), P = G((O, w) => {
2225
+ var m;
2226
+ if (O.key === "Backspace")
2227
+ if (O.target.value === "") {
2228
+ if (w > 0) {
2229
+ const b = w - 1;
2230
+ V("", b), N(b), v(!0);
2216
2231
  }
2217
2232
  } else
2218
- y(!1);
2219
- else S.key === "Escape" ? ((v = k[m].current) == null || v.blur(), F()) : S.key === "ArrowRight" ? m < e - 1 && g(m + 1) : S.key === "ArrowLeft" && m > 0 && g(m - 1);
2220
- }, [g, V, k, e]), w = _((S, m) => {
2221
- O(m);
2222
- }, []), H = _((S) => {
2223
- const m = S.target;
2233
+ v(!1);
2234
+ else O.key === "Escape" ? ((m = $[w].current) == null || m.blur(), F()) : O.key === "ArrowRight" ? w < e - 1 && N(w + 1) : O.key === "ArrowLeft" && w > 0 && N(w - 1);
2235
+ }, [N, V, $, e]), y = G((O, w) => {
2236
+ S(w);
2237
+ }, []), H = G((O) => {
2238
+ const w = O.target;
2224
2239
  setTimeout(() => {
2225
- m.setSelectionRange(m.value.length, m.value.length);
2240
+ w.setSelectionRange(w.value.length, w.value.length);
2226
2241
  }, 0);
2227
- }, []), F = _(() => {
2228
- O(-1);
2242
+ }, []), F = G(() => {
2243
+ S(-1);
2229
2244
  }, []);
2230
- return q(() => {
2231
- N((S) => Array(e).fill(0).map((v, R) => {
2232
- var z;
2233
- const A = S[R] || Rt();
2234
- return n && R === 0 && ((z = A.current) == null || z.focus()), A;
2245
+ return U(() => {
2246
+ k((O) => Array(e).fill(0).map((m, b) => {
2247
+ var B;
2248
+ const I = O[b] || Rt();
2249
+ return n && b === 0 && ((B = I.current) == null || B.focus()), I;
2235
2250
  }));
2236
2251
  }, [e, n]), Je(
2237
2252
  f,
@@ -2241,7 +2256,7 @@ const qt = b.forwardRef(
2241
2256
  }),
2242
2257
  [M]
2243
2258
  ), /* @__PURE__ */ o(
2244
- G,
2259
+ C,
2245
2260
  {
2246
2261
  "data-pin-input-field": !0,
2247
2262
  ref: p,
@@ -2250,35 +2265,35 @@ const qt = b.forwardRef(
2250
2265
  "aria-label": D,
2251
2266
  "aria-required": d.required,
2252
2267
  ...d,
2253
- children: Array.from({ length: e }, (S, m) => /* @__PURE__ */ o(
2254
- Re,
2268
+ children: Array.from({ length: e }, (O, w) => /* @__PURE__ */ o(
2269
+ Te,
2255
2270
  {
2256
- id: `${E}-${m}`,
2257
- ref: k[m],
2271
+ id: `${E}-${w}`,
2272
+ ref: $[w],
2258
2273
  type: r ? "password" : a === "number" ? "tel" : "text",
2259
2274
  inputMode: a === "number" ? "numeric" : "text",
2260
- onChange: (v) => C(v, m),
2261
- onKeyDown: (v) => P(v, m),
2262
- onFocus: (v) => w(v, m),
2275
+ onChange: (m) => K(m, w),
2276
+ onKeyDown: (m) => P(m, w),
2277
+ onFocus: (m) => y(m, w),
2263
2278
  onSelect: H,
2264
2279
  onBlur: F,
2265
- placeholder: x !== m ? "⦁" : void 0,
2280
+ placeholder: R !== w ? "⦁" : void 0,
2266
2281
  autoComplete: c ? "one-time-code" : "off",
2267
- value: $[m] || "",
2268
- autoFocus: n && m === 0,
2269
- onCopy: (v) => s === "disabled" && v.preventDefault(),
2270
- onPaste: (v) => s === "disabled" && v.preventDefault(),
2271
- "aria-label": `Digit ${m + 1} of ${e}`,
2282
+ value: x[w] || "",
2283
+ autoFocus: n && w === 0,
2284
+ onCopy: (m) => s === "disabled" && m.preventDefault(),
2285
+ onPaste: (m) => s === "disabled" && m.preventDefault(),
2286
+ "aria-label": `Digit ${w + 1} of ${e}`,
2272
2287
  "aria-required": d.required
2273
2288
  },
2274
- m
2289
+ w
2275
2290
  ))
2276
2291
  }
2277
2292
  );
2278
2293
  }
2279
2294
  );
2280
2295
  qt.displayName = "PinInputField";
2281
- const Yt = b.forwardRef(
2296
+ const Yt = g.forwardRef(
2282
2297
  ({
2283
2298
  id: e,
2284
2299
  name: t,
@@ -2293,62 +2308,62 @@ const Yt = b.forwardRef(
2293
2308
  size: d = "medium",
2294
2309
  bgColour: f,
2295
2310
  disabled: p,
2296
- ...k
2297
- }, N) => {
2298
- const $ = ve(() => t || e, [t, e]), h = J(null), [L, y] = j({
2311
+ ...$
2312
+ }, k) => {
2313
+ const x = ye(() => t || e, [t, e]), h = Y(null), [L, v] = j({
2299
2314
  width: 0,
2300
2315
  transform: "translateX(0)"
2301
- }), [x, O] = j(!1), [E, D] = j(0), [g, B] = j(0), M = J([]), V = _(() => {
2316
+ }), [R, S] = j(!1), [E, D] = j(0), [N, W] = j(0), M = Y([]), V = G(() => {
2302
2317
  if (!h.current) return;
2303
- const v = h.current, R = v.closest("[data-input-wrapper]");
2304
- if (v && R) {
2305
- const A = v.scrollWidth, z = R.clientWidth, K = A > z;
2306
- O(K), B(K ? A - z : 0);
2318
+ const m = h.current, b = m.closest("[data-input-wrapper]");
2319
+ if (m && b) {
2320
+ const I = m.scrollWidth, B = b.clientWidth, _ = I > B;
2321
+ S(_), W(_ ? I - B : 0);
2307
2322
  }
2308
2323
  }, []);
2309
- q(() => {
2310
- const v = h.current;
2311
- if (!v) return;
2324
+ U(() => {
2325
+ const m = h.current;
2326
+ if (!m) return;
2312
2327
  V();
2313
- const R = new ResizeObserver(() => {
2328
+ const b = new ResizeObserver(() => {
2314
2329
  V();
2315
2330
  });
2316
- return R.observe(v), v.closest("[data-input-wrapper]") && R.observe(v.closest("[data-input-wrapper]")), () => R.disconnect();
2317
- }, [V]), q(() => {
2318
- const v = n.findIndex((R) => R.value === i);
2319
- if (v >= 0) {
2320
- const R = () => {
2321
- const A = M.current[v];
2322
- if (A) {
2323
- const z = A.offsetWidth;
2324
- let K = "translateX(0)";
2325
- v > 0 && (K = `translateX(${M.current.slice(0, v).reduce((ne, te) => ne + ((te == null ? void 0 : te.offsetWidth) || 0), 0)}px)`), y({ width: z, transform: K });
2331
+ return b.observe(m), m.closest("[data-input-wrapper]") && b.observe(m.closest("[data-input-wrapper]")), () => b.disconnect();
2332
+ }, [V]), U(() => {
2333
+ const m = n.findIndex((b) => b.value === i);
2334
+ if (m >= 0) {
2335
+ const b = () => {
2336
+ const I = M.current[m];
2337
+ if (I) {
2338
+ const B = I.offsetWidth;
2339
+ let _ = "translateX(0)";
2340
+ m > 0 && (_ = `translateX(${M.current.slice(0, m).reduce((ie, te) => ie + ((te == null ? void 0 : te.offsetWidth) || 0), 0)}px)`), v({ width: B, transform: _ });
2326
2341
  }
2327
2342
  };
2328
2343
  if (document.fonts && document.fonts.ready)
2329
2344
  document.fonts.ready.then(() => {
2330
2345
  requestAnimationFrame(() => {
2331
- requestAnimationFrame(R);
2346
+ requestAnimationFrame(b);
2332
2347
  });
2333
2348
  });
2334
2349
  else {
2335
- const A = setTimeout(R, 100);
2336
- return () => clearTimeout(A);
2350
+ const I = setTimeout(b, 100);
2351
+ return () => clearTimeout(I);
2337
2352
  }
2338
2353
  }
2339
2354
  }, [i, n]);
2340
- const C = (v) => {
2341
- u == null || u(v.target.value);
2342
- }, { wrapperProps: P, inputProps: w } = le(k), H = _((v) => {
2343
- const R = h.current;
2344
- if (!R) return;
2345
- const z = R.clientWidth * 0.8;
2346
- let K = v === "right" ? Math.min(E + z, g) : Math.max(E - z, 0);
2347
- D(K), requestAnimationFrame(() => {
2348
- R.style.transform = `translateX(-${K}px)`;
2355
+ const K = (m) => {
2356
+ u == null || u(m.target.value);
2357
+ }, { wrapperProps: P, inputProps: y } = de($), H = G((m) => {
2358
+ const b = h.current;
2359
+ if (!b) return;
2360
+ const B = b.clientWidth * 0.8;
2361
+ let _ = m === "right" ? Math.min(E + B, N) : Math.max(E - B, 0);
2362
+ D(_), requestAnimationFrame(() => {
2363
+ b.style.transform = `translateX(-${_}px)`;
2349
2364
  });
2350
- }, [E, g]), F = E > 0, S = E < g, m = [];
2351
- return d && m.push(`size-${d}`), /* @__PURE__ */ o(
2365
+ }, [E, N]), F = E > 0, O = E < N, w = [];
2366
+ return d && w.push(`size-${d}`), /* @__PURE__ */ o(
2352
2367
  ee,
2353
2368
  {
2354
2369
  label: a,
@@ -2359,32 +2374,32 @@ const Yt = b.forwardRef(
2359
2374
  size: d,
2360
2375
  ...P,
2361
2376
  children: /* @__PURE__ */ T(
2362
- I,
2377
+ A,
2363
2378
  {
2364
2379
  as: "div",
2365
2380
  "data-radio-tab-group": !0,
2366
- ref: N,
2367
- classNames: m,
2368
- name: $,
2369
- ...w,
2381
+ ref: k,
2382
+ classNames: w,
2383
+ name: x,
2384
+ ...y,
2370
2385
  children: [
2371
- x && F && /* @__PURE__ */ o(
2372
- G,
2386
+ R && F && /* @__PURE__ */ o(
2387
+ C,
2373
2388
  {
2374
2389
  className: "scroll-button left",
2375
2390
  onClick: () => H("left"),
2376
2391
  children: /* @__PURE__ */ o("svg", { viewBox: "0 0 24 24", children: /* @__PURE__ */ o("polyline", { points: "15 18 9 12 15 6" }) })
2377
2392
  }
2378
2393
  ),
2379
- /* @__PURE__ */ T(G, { className: "rtg-options-container", children: [
2394
+ /* @__PURE__ */ T(C, { className: "rtg-options-container", children: [
2380
2395
  /* @__PURE__ */ T(
2381
- G,
2396
+ C,
2382
2397
  {
2383
2398
  className: "rtg-options-wrapper",
2384
2399
  ref: h,
2385
2400
  children: [
2386
2401
  /* @__PURE__ */ o(
2387
- G,
2402
+ C,
2388
2403
  {
2389
2404
  className: "indicator",
2390
2405
  style: {
@@ -2393,38 +2408,38 @@ const Yt = b.forwardRef(
2393
2408
  }
2394
2409
  }
2395
2410
  ),
2396
- n.map((v, R) => {
2397
- const { id: A, ...z } = v, K = A || `${e}-option-${R}`;
2398
- return /* @__PURE__ */ T(b.Fragment, { children: [
2411
+ n.map((m, b) => {
2412
+ const { id: I, ...B } = m, _ = I || `${e}-option-${b}`;
2413
+ return /* @__PURE__ */ T(g.Fragment, { children: [
2399
2414
  /* @__PURE__ */ o(
2400
2415
  "input",
2401
2416
  {
2402
2417
  type: "radio",
2403
- ...z,
2404
- id: K,
2405
- name: $,
2406
- checked: i === v.value,
2407
- disabled: p || v.disabled,
2408
- onChange: C
2418
+ ...B,
2419
+ id: _,
2420
+ name: x,
2421
+ checked: i === m.value,
2422
+ disabled: p || m.disabled,
2423
+ onChange: K
2409
2424
  }
2410
2425
  ),
2411
2426
  /* @__PURE__ */ o(
2412
2427
  "label",
2413
2428
  {
2414
2429
  ref: (Z) => {
2415
- M.current[R] = Z;
2430
+ M.current[b] = Z;
2416
2431
  },
2417
- htmlFor: K,
2418
- children: v.label
2432
+ htmlFor: _,
2433
+ children: m.label
2419
2434
  }
2420
2435
  )
2421
- ] }, K);
2436
+ ] }, _);
2422
2437
  })
2423
2438
  ]
2424
2439
  }
2425
2440
  ),
2426
- x && S && /* @__PURE__ */ o(
2427
- G,
2441
+ R && O && /* @__PURE__ */ o(
2442
+ C,
2428
2443
  {
2429
2444
  className: "scroll-button right",
2430
2445
  onClick: () => H("right"),
@@ -2443,7 +2458,7 @@ Yt.displayName = "RadioTabGroup";
2443
2458
  function Jt(e) {
2444
2459
  return Array.isArray(e.value);
2445
2460
  }
2446
- const Zt = b.forwardRef(
2461
+ const Zt = g.forwardRef(
2447
2462
  (e, t) => Jt(e) ? /* @__PURE__ */ o(ct, { ...e, forwardedRef: t }) : /* @__PURE__ */ o(lt, { ...e, forwardedRef: t })
2448
2463
  );
2449
2464
  Zt.displayName = "Range";
@@ -2462,108 +2477,108 @@ const lt = ({
2462
2477
  size: f,
2463
2478
  ...p
2464
2479
  }) => {
2465
- const { wrapperProps: k } = le(p), N = J(null), $ = J(null), [h, L] = j(!1), [y, x] = j(!1), O = Math.max(s, Math.min(i, r)), E = _((P) => i <= s ? 0 : (Math.max(s, Math.min(i, P)) - s) / (i - s) * 100, [s, i]), D = _((P) => {
2466
- if (!$.current) return s;
2467
- const w = $.current.getBoundingClientRect(), H = Math.max(0, Math.min(1, (P - w.left) / w.width)), F = s + H * (i - s), S = Math.round(F / l) * l;
2468
- return Math.max(s, Math.min(i, S));
2469
- }, [s, i, l]), g = _((P) => {
2470
- const w = D(P);
2471
- n == null || n(w);
2472
- }, [D, n]), B = _((P) => {
2473
- d || (P.preventDefault(), L(!0), x(!0), g(P.clientX));
2474
- }, [d, g]);
2475
- q(() => {
2480
+ const { wrapperProps: $ } = de(p), k = Y(null), x = Y(null), [h, L] = j(!1), [v, R] = j(!1), S = Math.max(s, Math.min(i, r)), E = G((P) => i <= s ? 0 : (Math.max(s, Math.min(i, P)) - s) / (i - s) * 100, [s, i]), D = G((P) => {
2481
+ if (!x.current) return s;
2482
+ const y = x.current.getBoundingClientRect(), H = Math.max(0, Math.min(1, (P - y.left) / y.width)), F = s + H * (i - s), O = Math.round(F / l) * l;
2483
+ return Math.max(s, Math.min(i, O));
2484
+ }, [s, i, l]), N = G((P) => {
2485
+ const y = D(P);
2486
+ n == null || n(y);
2487
+ }, [D, n]), W = G((P) => {
2488
+ d || (P.preventDefault(), L(!0), R(!0), N(P.clientX));
2489
+ }, [d, N]);
2490
+ U(() => {
2476
2491
  if (!h) return;
2477
2492
  const P = (H) => {
2478
- g(H.clientX);
2479
- }, w = () => {
2493
+ N(H.clientX);
2494
+ }, y = () => {
2480
2495
  L(!1);
2481
2496
  };
2482
- return document.addEventListener("mousemove", P), document.addEventListener("mouseup", w), () => {
2483
- document.removeEventListener("mousemove", P), document.removeEventListener("mouseup", w);
2497
+ return document.addEventListener("mousemove", P), document.addEventListener("mouseup", y), () => {
2498
+ document.removeEventListener("mousemove", P), document.removeEventListener("mouseup", y);
2484
2499
  };
2485
- }, [h, g]);
2486
- const M = _((P) => {
2487
- d || (L(!0), x(!0), g(P.touches[0].clientX));
2488
- }, [d, g]);
2489
- q(() => {
2500
+ }, [h, N]);
2501
+ const M = G((P) => {
2502
+ d || (L(!0), R(!0), N(P.touches[0].clientX));
2503
+ }, [d, N]);
2504
+ U(() => {
2490
2505
  if (!h) return;
2491
2506
  const P = (H) => {
2492
- H.preventDefault(), g(H.touches[0].clientX);
2493
- }, w = () => {
2507
+ H.preventDefault(), N(H.touches[0].clientX);
2508
+ }, y = () => {
2494
2509
  L(!1);
2495
2510
  };
2496
- return document.addEventListener("touchmove", P, { passive: !1 }), document.addEventListener("touchend", w), () => {
2497
- document.removeEventListener("touchmove", P), document.removeEventListener("touchend", w);
2511
+ return document.addEventListener("touchmove", P, { passive: !1 }), document.addEventListener("touchend", y), () => {
2512
+ document.removeEventListener("touchmove", P), document.removeEventListener("touchend", y);
2498
2513
  };
2499
- }, [h, g]);
2500
- const V = _((P) => {
2514
+ }, [h, N]);
2515
+ const V = G((P) => {
2501
2516
  if (d) return;
2502
- let w = O;
2517
+ let y = S;
2503
2518
  switch (P.key) {
2504
2519
  case "ArrowRight":
2505
2520
  case "ArrowUp":
2506
- P.preventDefault(), w = Math.min(O + l, i);
2521
+ P.preventDefault(), y = Math.min(S + l, i);
2507
2522
  break;
2508
2523
  case "ArrowLeft":
2509
2524
  case "ArrowDown":
2510
- P.preventDefault(), w = Math.max(O - l, s);
2525
+ P.preventDefault(), y = Math.max(S - l, s);
2511
2526
  break;
2512
2527
  case "Home":
2513
- P.preventDefault(), w = s;
2528
+ P.preventDefault(), y = s;
2514
2529
  break;
2515
2530
  case "End":
2516
- P.preventDefault(), w = i;
2531
+ P.preventDefault(), y = i;
2517
2532
  break;
2518
2533
  case "PageUp":
2519
- P.preventDefault(), w = Math.min(O + l * 10, i);
2534
+ P.preventDefault(), y = Math.min(S + l * 10, i);
2520
2535
  break;
2521
2536
  case "PageDown":
2522
- P.preventDefault(), w = Math.max(O - l * 10, s);
2537
+ P.preventDefault(), y = Math.max(S - l * 10, s);
2523
2538
  break;
2524
2539
  default:
2525
2540
  return;
2526
2541
  }
2527
- n == null || n(w);
2528
- }, [d, O, s, i, l, n]), C = E(O);
2542
+ n == null || n(y);
2543
+ }, [d, S, s, i, l, n]), K = E(S);
2529
2544
  return /* @__PURE__ */ o(
2530
2545
  ee,
2531
2546
  {
2532
- customLabel: e && /* @__PURE__ */ T(G, { "data-range-meta": !0, children: [
2547
+ customLabel: e && /* @__PURE__ */ T(C, { "data-range-meta": !0, children: [
2533
2548
  /* @__PURE__ */ o(
2534
- xe,
2549
+ Pe,
2535
2550
  {
2536
2551
  className: "range-label",
2537
2552
  label: e,
2538
2553
  htmlFor: u
2539
2554
  }
2540
2555
  ),
2541
- /* @__PURE__ */ T(Y, { className: "range-value", children: [
2542
- O,
2556
+ /* @__PURE__ */ T(J, { className: "range-value", children: [
2557
+ S,
2543
2558
  c && c
2544
2559
  ] })
2545
2560
  ] }),
2546
2561
  helpText: t,
2547
2562
  errorText: a,
2548
2563
  size: f,
2549
- ...k,
2564
+ ...$,
2550
2565
  children: /* @__PURE__ */ T(
2551
- G,
2566
+ C,
2552
2567
  {
2553
- ref: $,
2568
+ ref: x,
2554
2569
  "data-range-single": !0,
2555
2570
  className: d ? "disabled" : "",
2556
2571
  role: "group",
2557
2572
  "aria-labelledby": e ? `${u}-label` : void 0,
2558
2573
  children: [
2559
- /* @__PURE__ */ o(G, { className: "range-track", "aria-hidden": "true" }),
2574
+ /* @__PURE__ */ o(C, { className: "range-track", "aria-hidden": "true" }),
2560
2575
  /* @__PURE__ */ o(
2561
- G,
2576
+ C,
2562
2577
  {
2563
2578
  className: "range-track-fill",
2564
2579
  style: {
2565
2580
  left: "0%",
2566
- right: `${100 - C}%`
2581
+ right: `${100 - K}%`
2567
2582
  },
2568
2583
  "aria-hidden": "true"
2569
2584
  }
@@ -2571,23 +2586,23 @@ const lt = ({
2571
2586
  /* @__PURE__ */ o(
2572
2587
  "button",
2573
2588
  {
2574
- ref: N,
2589
+ ref: k,
2575
2590
  id: u,
2576
2591
  type: "button",
2577
2592
  className: "range-thumb",
2578
- style: { left: `${C}%` },
2593
+ style: { left: `${K}%` },
2579
2594
  disabled: d,
2580
- onMouseDown: B,
2595
+ onMouseDown: W,
2581
2596
  onTouchStart: M,
2582
2597
  onKeyDown: V,
2583
- onFocus: () => x(!0),
2584
- onBlur: () => x(!1),
2585
- "data-active": y || h,
2598
+ onFocus: () => R(!0),
2599
+ onBlur: () => R(!1),
2600
+ "data-active": v || h,
2586
2601
  role: "slider",
2587
2602
  "aria-valuemin": s,
2588
2603
  "aria-valuemax": i,
2589
- "aria-valuenow": O,
2590
- "aria-valuetext": `${O}${c ? ` ${c}` : ""}`,
2604
+ "aria-valuenow": S,
2605
+ "aria-valuetext": `${S}${c ? ` ${c}` : ""}`,
2591
2606
  "aria-orientation": "horizontal"
2592
2607
  }
2593
2608
  )
@@ -2612,111 +2627,111 @@ const ct = ({
2612
2627
  maxLabel: d = "Maximum value",
2613
2628
  id: f,
2614
2629
  disabled: p,
2615
- size: k,
2616
- ...N
2630
+ size: $,
2631
+ ...k
2617
2632
  }) => {
2618
- const { wrapperProps: $ } = le(N), [h, L] = r, y = Math.max(s, Math.min(i, h)), x = Math.max(s, Math.min(i, L)), O = J(null), E = J(null), D = J(null), [g, B] = j(null), [M, V] = j(null), C = _((R) => i <= s ? 0 : (Math.max(s, Math.min(i, R)) - s) / (i - s) * 100, [s, i]), P = _((R) => {
2633
+ const { wrapperProps: x } = de(k), [h, L] = r, v = Math.max(s, Math.min(i, h)), R = Math.max(s, Math.min(i, L)), S = Y(null), E = Y(null), D = Y(null), [N, W] = j(null), [M, V] = j(null), K = G((b) => i <= s ? 0 : (Math.max(s, Math.min(i, b)) - s) / (i - s) * 100, [s, i]), P = G((b) => {
2619
2634
  if (!D.current) return s;
2620
- const A = D.current.getBoundingClientRect(), z = Math.max(0, Math.min(1, (R - A.left) / A.width)), K = s + z * (i - s), Z = Math.round(K / l) * l;
2635
+ const I = D.current.getBoundingClientRect(), B = Math.max(0, Math.min(1, (b - I.left) / I.width)), _ = s + B * (i - s), Z = Math.round(_ / l) * l;
2621
2636
  return Math.max(s, Math.min(i, Z));
2622
- }, [s, i, l]), w = _((R, A) => {
2623
- const z = P(R);
2624
- if (A === "min") {
2625
- const K = Math.min(z, x - l);
2626
- n == null || n([K, x]);
2637
+ }, [s, i, l]), y = G((b, I) => {
2638
+ const B = P(b);
2639
+ if (I === "min") {
2640
+ const _ = Math.min(B, R - l);
2641
+ n == null || n([_, R]);
2627
2642
  } else {
2628
- const K = Math.max(z, y + l);
2629
- n == null || n([y, K]);
2643
+ const _ = Math.max(B, v + l);
2644
+ n == null || n([v, _]);
2630
2645
  }
2631
- }, [P, y, x, l, n]), H = _((R) => (A) => {
2632
- p || (A.preventDefault(), B(R), V(R), w(A.clientX, R));
2633
- }, [p, w]);
2634
- q(() => {
2635
- if (!g) return;
2636
- const R = (z) => {
2637
- w(z.clientX, g);
2638
- }, A = () => {
2639
- B(null);
2646
+ }, [P, v, R, l, n]), H = G((b) => (I) => {
2647
+ p || (I.preventDefault(), W(b), V(b), y(I.clientX, b));
2648
+ }, [p, y]);
2649
+ U(() => {
2650
+ if (!N) return;
2651
+ const b = (B) => {
2652
+ y(B.clientX, N);
2653
+ }, I = () => {
2654
+ W(null);
2640
2655
  };
2641
- return document.addEventListener("mousemove", R), document.addEventListener("mouseup", A), () => {
2642
- document.removeEventListener("mousemove", R), document.removeEventListener("mouseup", A);
2656
+ return document.addEventListener("mousemove", b), document.addEventListener("mouseup", I), () => {
2657
+ document.removeEventListener("mousemove", b), document.removeEventListener("mouseup", I);
2643
2658
  };
2644
- }, [g, w]);
2645
- const F = _((R) => (A) => {
2646
- p || (B(R), V(R), w(A.touches[0].clientX, R));
2647
- }, [p, w]);
2648
- q(() => {
2649
- if (!g) return;
2650
- const R = (z) => {
2651
- z.preventDefault(), w(z.touches[0].clientX, g);
2652
- }, A = () => {
2653
- B(null);
2659
+ }, [N, y]);
2660
+ const F = G((b) => (I) => {
2661
+ p || (W(b), V(b), y(I.touches[0].clientX, b));
2662
+ }, [p, y]);
2663
+ U(() => {
2664
+ if (!N) return;
2665
+ const b = (B) => {
2666
+ B.preventDefault(), y(B.touches[0].clientX, N);
2667
+ }, I = () => {
2668
+ W(null);
2654
2669
  };
2655
- return document.addEventListener("touchmove", R, { passive: !1 }), document.addEventListener("touchend", A), () => {
2656
- document.removeEventListener("touchmove", R), document.removeEventListener("touchend", A);
2670
+ return document.addEventListener("touchmove", b, { passive: !1 }), document.addEventListener("touchend", I), () => {
2671
+ document.removeEventListener("touchmove", b), document.removeEventListener("touchend", I);
2657
2672
  };
2658
- }, [g, w]);
2659
- const S = _((R) => (A) => {
2673
+ }, [N, y]);
2674
+ const O = G((b) => (I) => {
2660
2675
  if (p) return;
2661
- const z = R === "min" ? y : x;
2662
- let K = z;
2663
- switch (A.key) {
2676
+ const B = b === "min" ? v : R;
2677
+ let _ = B;
2678
+ switch (I.key) {
2664
2679
  case "ArrowRight":
2665
2680
  case "ArrowUp":
2666
- A.preventDefault(), K = Math.min(z + l, i);
2681
+ I.preventDefault(), _ = Math.min(B + l, i);
2667
2682
  break;
2668
2683
  case "ArrowLeft":
2669
2684
  case "ArrowDown":
2670
- A.preventDefault(), K = Math.max(z - l, s);
2685
+ I.preventDefault(), _ = Math.max(B - l, s);
2671
2686
  break;
2672
2687
  case "Home":
2673
- A.preventDefault(), K = R === "min" ? s : y + l;
2688
+ I.preventDefault(), _ = b === "min" ? s : v + l;
2674
2689
  break;
2675
2690
  case "End":
2676
- A.preventDefault(), K = R === "max" ? i : x - l;
2691
+ I.preventDefault(), _ = b === "max" ? i : R - l;
2677
2692
  break;
2678
2693
  case "PageUp":
2679
- A.preventDefault(), K = Math.min(z + l * 10, i);
2694
+ I.preventDefault(), _ = Math.min(B + l * 10, i);
2680
2695
  break;
2681
2696
  case "PageDown":
2682
- A.preventDefault(), K = Math.max(z - l * 10, s);
2697
+ I.preventDefault(), _ = Math.max(B - l * 10, s);
2683
2698
  break;
2684
2699
  default:
2685
2700
  return;
2686
2701
  }
2687
- if (R === "min") {
2688
- const Z = Math.min(K, x - l);
2689
- n == null || n([Z, x]);
2702
+ if (b === "min") {
2703
+ const Z = Math.min(_, R - l);
2704
+ n == null || n([Z, R]);
2690
2705
  } else {
2691
- const Z = Math.max(K, y + l);
2692
- n == null || n([y, Z]);
2706
+ const Z = Math.max(_, v + l);
2707
+ n == null || n([v, Z]);
2693
2708
  }
2694
- }, [p, y, x, s, i, l, n]), m = C(y), v = C(x);
2709
+ }, [p, v, R, s, i, l, n]), w = K(v), m = K(R);
2695
2710
  return /* @__PURE__ */ o(
2696
2711
  ee,
2697
2712
  {
2698
- customLabel: e && /* @__PURE__ */ T(G, { "data-range-meta": !0, children: [
2713
+ customLabel: e && /* @__PURE__ */ T(C, { "data-range-meta": !0, children: [
2699
2714
  /* @__PURE__ */ o(
2700
- xe,
2715
+ Pe,
2701
2716
  {
2702
2717
  className: "range-label",
2703
2718
  label: e,
2704
2719
  htmlFor: f
2705
2720
  }
2706
2721
  ),
2707
- /* @__PURE__ */ T(Y, { className: "range-value", children: [
2708
- y,
2722
+ /* @__PURE__ */ T(J, { className: "range-value", children: [
2723
+ v,
2709
2724
  "–",
2710
- x,
2725
+ R,
2711
2726
  c && c
2712
2727
  ] })
2713
2728
  ] }),
2714
2729
  helpText: t,
2715
2730
  errorText: a,
2716
- size: k,
2717
- ...$,
2731
+ size: $,
2732
+ ...x,
2718
2733
  children: /* @__PURE__ */ T(
2719
- G,
2734
+ C,
2720
2735
  {
2721
2736
  ref: D,
2722
2737
  "data-range-dual": !0,
@@ -2724,14 +2739,14 @@ const ct = ({
2724
2739
  role: "group",
2725
2740
  "aria-labelledby": e ? `${f}-label` : void 0,
2726
2741
  children: [
2727
- /* @__PURE__ */ o(G, { className: "range-track", "aria-hidden": "true" }),
2742
+ /* @__PURE__ */ o(C, { className: "range-track", "aria-hidden": "true" }),
2728
2743
  /* @__PURE__ */ o(
2729
- G,
2744
+ C,
2730
2745
  {
2731
2746
  className: "range-track-fill",
2732
2747
  style: {
2733
- left: `${m}%`,
2734
- right: `${100 - v}%`
2748
+ left: `${w}%`,
2749
+ right: `${100 - m}%`
2735
2750
  },
2736
2751
  "aria-hidden": "true"
2737
2752
  }
@@ -2739,24 +2754,24 @@ const ct = ({
2739
2754
  /* @__PURE__ */ o(
2740
2755
  "button",
2741
2756
  {
2742
- ref: O,
2757
+ ref: S,
2743
2758
  id: `${f}-min`,
2744
2759
  type: "button",
2745
2760
  className: "range-thumb range-thumb-min",
2746
- style: { left: `${m}%` },
2761
+ style: { left: `${w}%` },
2747
2762
  disabled: p,
2748
2763
  onMouseDown: H("min"),
2749
2764
  onTouchStart: F("min"),
2750
- onKeyDown: S("min"),
2765
+ onKeyDown: O("min"),
2751
2766
  onFocus: () => V("min"),
2752
2767
  onBlur: () => V(null),
2753
- "data-active": M === "min" || g === "min",
2768
+ "data-active": M === "min" || N === "min",
2754
2769
  role: "slider",
2755
2770
  "aria-label": u,
2756
2771
  "aria-valuemin": s,
2757
- "aria-valuemax": x - l,
2758
- "aria-valuenow": y,
2759
- "aria-valuetext": `${y}${c ? ` ${c}` : ""}`,
2772
+ "aria-valuemax": R - l,
2773
+ "aria-valuenow": v,
2774
+ "aria-valuetext": `${v}${c ? ` ${c}` : ""}`,
2760
2775
  "aria-orientation": "horizontal"
2761
2776
  }
2762
2777
  ),
@@ -2767,20 +2782,20 @@ const ct = ({
2767
2782
  id: `${f}-max`,
2768
2783
  type: "button",
2769
2784
  className: "range-thumb range-thumb-max",
2770
- style: { left: `${v}%` },
2785
+ style: { left: `${m}%` },
2771
2786
  disabled: p,
2772
2787
  onMouseDown: H("max"),
2773
2788
  onTouchStart: F("max"),
2774
- onKeyDown: S("max"),
2789
+ onKeyDown: O("max"),
2775
2790
  onFocus: () => V("max"),
2776
2791
  onBlur: () => V(null),
2777
- "data-active": M === "max" || g === "max",
2792
+ "data-active": M === "max" || N === "max",
2778
2793
  role: "slider",
2779
2794
  "aria-label": d,
2780
- "aria-valuemin": y + l,
2795
+ "aria-valuemin": v + l,
2781
2796
  "aria-valuemax": i,
2782
- "aria-valuenow": x,
2783
- "aria-valuetext": `${x}${c ? ` ${c}` : ""}`,
2797
+ "aria-valuenow": R,
2798
+ "aria-valuetext": `${R}${c ? ` ${c}` : ""}`,
2784
2799
  "aria-orientation": "horizontal"
2785
2800
  }
2786
2801
  )
@@ -2791,7 +2806,7 @@ const ct = ({
2791
2806
  );
2792
2807
  };
2793
2808
  ct.displayName = "DualThumbRange";
2794
- const Qt = b.forwardRef(
2809
+ const Qt = g.forwardRef(
2795
2810
  ({
2796
2811
  label: e,
2797
2812
  value: t,
@@ -2806,14 +2821,14 @@ const Qt = b.forwardRef(
2806
2821
  high: d,
2807
2822
  optimum: f,
2808
2823
  ...p
2809
- }, k) => {
2810
- const N = f ? (f - i) / (l - i) * 100 : 0, $ = () => {
2811
- const y = (t - i) / (l - i) * 100;
2812
- let x;
2813
- return t <= u ? x = "Low" : t >= d ? x = "High" : x = "Normal", `Current value is ${t}${r || ""} (${y.toFixed(1)}%). Status: ${x}`;
2814
- }, { wrapperProps: h, inputProps: L } = le(p);
2824
+ }, $) => {
2825
+ const k = f ? (f - i) / (l - i) * 100 : 0, x = () => {
2826
+ const v = (t - i) / (l - i) * 100;
2827
+ let R;
2828
+ return t <= u ? R = "Low" : t >= d ? R = "High" : R = "Normal", `Current value is ${t}${r || ""} (${v.toFixed(1)}%). Status: ${R}`;
2829
+ }, { wrapperProps: h, inputProps: L } = de(p);
2815
2830
  return /* @__PURE__ */ T(
2816
- I,
2831
+ A,
2817
2832
  {
2818
2833
  as: "div",
2819
2834
  role: "region",
@@ -2821,14 +2836,14 @@ const Qt = b.forwardRef(
2821
2836
  ...h,
2822
2837
  children: [
2823
2838
  e && /* @__PURE__ */ T(
2824
- I,
2839
+ A,
2825
2840
  {
2826
2841
  as: "div",
2827
2842
  "data-meter-meta": !0,
2828
2843
  id: `meter-label-${e.toLowerCase().replace(/\s+/g, "-")}`,
2829
2844
  children: [
2830
- /* @__PURE__ */ o(Y, { children: e }),
2831
- /* @__PURE__ */ T(Y, { children: [
2845
+ /* @__PURE__ */ o(J, { children: e }),
2846
+ /* @__PURE__ */ T(J, { children: [
2832
2847
  t,
2833
2848
  r && r
2834
2849
  ] })
@@ -2842,11 +2857,11 @@ const Qt = b.forwardRef(
2842
2857
  role: "presentation",
2843
2858
  children: [
2844
2859
  /* @__PURE__ */ o(
2845
- I,
2860
+ A,
2846
2861
  {
2847
2862
  as: "meter",
2848
2863
  "data-meter": !0,
2849
- ref: k,
2864
+ ref: $,
2850
2865
  value: t,
2851
2866
  min: i,
2852
2867
  max: l,
@@ -2859,7 +2874,7 @@ const Qt = b.forwardRef(
2859
2874
  "aria-valuemin": i,
2860
2875
  "aria-valuemax": l,
2861
2876
  "aria-valuenow": t,
2862
- "aria-valuetext": $(),
2877
+ "aria-valuetext": x(),
2863
2878
  "aria-describedby": s ? `meter-description-${e == null ? void 0 : e.toLowerCase().replace(/\s+/g, "-")}` : void 0
2864
2879
  }
2865
2880
  ),
@@ -2867,7 +2882,7 @@ const Qt = b.forwardRef(
2867
2882
  "div",
2868
2883
  {
2869
2884
  className: "optimum-marker",
2870
- style: { left: `calc(${N}% - var(--meter-border-width))` },
2885
+ style: { left: `calc(${k}% - var(--meter-border-width))` },
2871
2886
  title: `Optimum: ${f}`,
2872
2887
  role: "presentation",
2873
2888
  "aria-hidden": "true"
@@ -2890,7 +2905,7 @@ const Qt = b.forwardRef(
2890
2905
  }
2891
2906
  );
2892
2907
  Qt.displayName = "Meter";
2893
- const ea = b.forwardRef(
2908
+ const ea = g.forwardRef(
2894
2909
  ({
2895
2910
  id: e,
2896
2911
  children: t,
@@ -2904,27 +2919,27 @@ const ea = b.forwardRef(
2904
2919
  description: u,
2905
2920
  ...d
2906
2921
  }, f) => {
2907
- const p = `${e}`, k = u ? `${p}-description` : void 0;
2908
- return s && a.push("show-backdrop"), i && a.push("blur-backdrop"), q(() => {
2909
- const N = document.querySelector(`#${p}[data-modal]`);
2910
- if (!(!N || !(N instanceof HTMLElement)))
2922
+ const p = `${e}`, $ = u ? `${p}-description` : void 0;
2923
+ return s && a.push("show-backdrop"), i && a.push("blur-backdrop"), U(() => {
2924
+ const k = document.querySelector(`#${p}[data-modal]`);
2925
+ if (!(!k || !(k instanceof HTMLElement)))
2911
2926
  if (r) {
2912
- N.showPopover();
2913
- const $ = N.querySelectorAll(
2927
+ k.showPopover();
2928
+ const x = k.querySelectorAll(
2914
2929
  'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'
2915
2930
  );
2916
- $.length && $[0].focus();
2931
+ x.length && x[0].focus();
2917
2932
  } else
2918
- N.matches(":popover-open") && N.hidePopover();
2919
- }, [r, p]), q(() => {
2920
- const N = document.querySelector(`#${p}[data-modal]`);
2921
- if (!N || !(N instanceof HTMLElement)) return;
2922
- const $ = (h) => {
2933
+ k.matches(":popover-open") && k.hidePopover();
2934
+ }, [r, p]), U(() => {
2935
+ const k = document.querySelector(`#${p}[data-modal]`);
2936
+ if (!k || !(k instanceof HTMLElement)) return;
2937
+ const x = (h) => {
2923
2938
  h.newState === "closed" && r && c && c();
2924
2939
  };
2925
- return N.addEventListener("toggle", $), () => N.removeEventListener("toggle", $);
2940
+ return k.addEventListener("toggle", x), () => k.removeEventListener("toggle", x);
2926
2941
  }, [p, r, c]), /* @__PURE__ */ T(
2927
- I,
2942
+ A,
2928
2943
  {
2929
2944
  as: "dialog",
2930
2945
  id: p,
@@ -2935,11 +2950,11 @@ const ea = b.forwardRef(
2935
2950
  role: "dialog",
2936
2951
  "aria-modal": "true",
2937
2952
  "aria-label": l || "Modal dialog",
2938
- "aria-describedby": k,
2953
+ "aria-describedby": $,
2939
2954
  ...d,
2940
2955
  children: [
2941
2956
  n && c && /* @__PURE__ */ o(
2942
- Y,
2957
+ J,
2943
2958
  {
2944
2959
  className: "dismiss-button",
2945
2960
  onClick: c,
@@ -2948,7 +2963,7 @@ const ea = b.forwardRef(
2948
2963
  children: "×"
2949
2964
  }
2950
2965
  ),
2951
- u && /* @__PURE__ */ o("div", { id: k, className: "sr-only", children: u }),
2966
+ u && /* @__PURE__ */ o("div", { id: $, className: "sr-only", children: u }),
2952
2967
  /* @__PURE__ */ o("div", { role: "document", children: t })
2953
2968
  ]
2954
2969
  }
@@ -2956,7 +2971,7 @@ const ea = b.forwardRef(
2956
2971
  }
2957
2972
  );
2958
2973
  ea.displayName = "Modal";
2959
- const dt = b.forwardRef(
2974
+ const dt = g.forwardRef(
2960
2975
  ({
2961
2976
  position: e = "right",
2962
2977
  anchor: t = "top",
@@ -2967,8 +2982,8 @@ const dt = b.forwardRef(
2967
2982
  ...s
2968
2983
  }, i) => {
2969
2984
  let l = [];
2970
- return e && l.push(e), t && l.push(t), a && l.push(a), r && l.push(r), b.Children.count(c) === 0 ? null : /* @__PURE__ */ o(
2971
- I,
2985
+ return e && l.push(e), t && l.push(t), a && l.push(a), r && l.push(r), g.Children.count(c) === 0 ? null : /* @__PURE__ */ o(
2986
+ A,
2972
2987
  {
2973
2988
  as: "section",
2974
2989
  "data-notifications-wrapper": !0,
@@ -2999,13 +3014,13 @@ const ta = {
2999
3014
  children: n
3000
3015
  }) => {
3001
3016
  const [s, i] = j(!1);
3002
- q(() => {
3017
+ U(() => {
3003
3018
  if (a === 0) return;
3004
3019
  const p = setTimeout(() => {
3005
3020
  i(!0);
3006
3021
  }, a * 1e3);
3007
3022
  return () => clearTimeout(p);
3008
- }, [a]), q(() => {
3023
+ }, [a]), U(() => {
3009
3024
  if (!s) return;
3010
3025
  const p = setTimeout(() => {
3011
3026
  c();
@@ -3020,7 +3035,7 @@ const ta = {
3020
3035
  s && c();
3021
3036
  }, f = [t];
3022
3037
  return r && f.push("dismissible"), s && f.push("dismissed"), /* @__PURE__ */ T(
3023
- I,
3038
+ A,
3024
3039
  {
3025
3040
  as: "div",
3026
3041
  "data-notification-item": !0,
@@ -3033,7 +3048,7 @@ const ta = {
3033
3048
  children: [
3034
3049
  /* @__PURE__ */ o("div", { className: "notification-content", children: n }),
3035
3050
  r && /* @__PURE__ */ o(
3036
- G,
3051
+ C,
3037
3052
  {
3038
3053
  className: "dismiss-button",
3039
3054
  onClick: l,
@@ -3048,25 +3063,25 @@ const ta = {
3048
3063
  );
3049
3064
  };
3050
3065
  ut.displayName = "NotificationItem";
3051
- const ft = Se(null), aa = ({
3066
+ const ft = Oe(null), aa = ({
3052
3067
  children: e,
3053
3068
  position: t = "right",
3054
3069
  anchor: a = "top",
3055
3070
  order: r = "new-on-top",
3056
3071
  kind: c = "list"
3057
3072
  }) => {
3058
- const [n, s] = j([]), i = _((f) => {
3059
- s((p) => p.filter((k) => k.id !== f));
3060
- }, []), l = _((f, p = "generic", k = 4, N = !0) => {
3061
- const $ = `notification-${Date.now()}-${Math.random().toString(36).substring(2, 9)}`;
3073
+ const [n, s] = j([]), i = G((f) => {
3074
+ s((p) => p.filter(($) => $.id !== f));
3075
+ }, []), l = G((f, p = "generic", $ = 4, k = !0) => {
3076
+ const x = `notification-${Date.now()}-${Math.random().toString(36).substring(2, 9)}`;
3062
3077
  return s((h) => [...h, {
3063
- id: $,
3078
+ id: x,
3064
3079
  content: f,
3065
3080
  kind: p,
3066
- duration: k,
3067
- isDismissible: N
3068
- }]), $;
3069
- }, []), u = _((f) => {
3081
+ duration: $,
3082
+ isDismissible: k
3083
+ }]), x;
3084
+ }, []), u = G((f) => {
3070
3085
  if (typeof f == "string") {
3071
3086
  l(f);
3072
3087
  return;
@@ -3082,7 +3097,7 @@ const ft = Se(null), aa = ({
3082
3097
  return;
3083
3098
  }
3084
3099
  l(f);
3085
- }, [l]), d = _(() => {
3100
+ }, [l]), d = G(() => {
3086
3101
  const f = u;
3087
3102
  return f.success = (p) => {
3088
3103
  l(p, "success");
@@ -3103,13 +3118,13 @@ const ft = Se(null), aa = ({
3103
3118
  anchor: a,
3104
3119
  order: r,
3105
3120
  kind: c,
3106
- children: n.map(({ id: f, content: p, kind: k, duration: N, isDismissible: $ }) => /* @__PURE__ */ o(
3121
+ children: n.map(({ id: f, content: p, kind: $, duration: k, isDismissible: x }) => /* @__PURE__ */ o(
3107
3122
  ut,
3108
3123
  {
3109
3124
  id: f,
3110
- kind: k,
3111
- duration: N,
3112
- isDismissible: $,
3125
+ kind: $,
3126
+ duration: k,
3127
+ isDismissible: x,
3113
3128
  onClose: () => i(f),
3114
3129
  children: typeof p == "function" ? p({ close: () => i(f) }) : p
3115
3130
  },
@@ -3121,11 +3136,11 @@ const ft = Se(null), aa = ({
3121
3136
  };
3122
3137
  aa.displayName = "NotificationsProvider";
3123
3138
  const Xa = () => {
3124
- const e = be(ft);
3139
+ const e = Ne(ft);
3125
3140
  if (!e)
3126
3141
  throw new Error("useNotifications must be used within a NotificationsProvider");
3127
3142
  return e.notify;
3128
- }, pt = b.forwardRef(
3143
+ }, pt = g.forwardRef(
3129
3144
  ({
3130
3145
  size: e = "medium",
3131
3146
  loadingText: t = "Loading...",
@@ -3133,7 +3148,7 @@ const Xa = () => {
3133
3148
  }, r) => {
3134
3149
  let c = [];
3135
3150
  return e && c.push(`size-${e}`), /* @__PURE__ */ o(
3136
- I,
3151
+ A,
3137
3152
  {
3138
3153
  as: "div",
3139
3154
  "data-spinner": !0,
@@ -3188,7 +3203,7 @@ const Ue = (e, t) => {
3188
3203
  ...s
3189
3204
  }) => {
3190
3205
  if (e === "ellipsis")
3191
- return /* @__PURE__ */ o(Y, { className: "pagination-ellipsis", children: "..." });
3206
+ return /* @__PURE__ */ o(J, { className: "pagination-ellipsis", children: "..." });
3192
3207
  const i = {
3193
3208
  type: "button",
3194
3209
  className: `pagination-item ${a ? "selected" : ""} ${r ? "disabled" : ""}`,
@@ -3235,7 +3250,7 @@ const Ue = (e, t) => {
3235
3250
  children: l
3236
3251
  }
3237
3252
  );
3238
- }, na = b.forwardRef(
3253
+ }, na = g.forwardRef(
3239
3254
  ({
3240
3255
  totalItems: e,
3241
3256
  currentPage: t,
@@ -3250,45 +3265,45 @@ const Ue = (e, t) => {
3250
3265
  disabled: d = !1,
3251
3266
  hideDisabledButtons: f = !1,
3252
3267
  renderItem: p = sa,
3253
- isLoading: k = !1,
3254
- loadingText: N,
3255
- emptyText: $,
3268
+ isLoading: $ = !1,
3269
+ loadingText: k,
3270
+ emptyText: x,
3256
3271
  itemDisplayText: h = "Page",
3257
3272
  ...L
3258
- }, y) => {
3273
+ }, v) => {
3259
3274
  const {
3260
- items: x,
3261
- totalPages: O,
3275
+ items: R,
3276
+ totalPages: S,
3262
3277
  rangeStart: E,
3263
3278
  hasPrevPage: D,
3264
- hasNextPage: g
3279
+ hasNextPage: N
3265
3280
  } = ra({
3266
3281
  totalItems: e,
3267
3282
  currentPage: t,
3268
3283
  itemsToShowEachSide: r
3269
- }), [B, M] = b.useState(""), V = (w) => {
3270
- M(w.target.value);
3271
- }, C = (w) => {
3272
- if (w.key === "Enter") {
3273
- const H = parseInt(B);
3274
- !isNaN(H) && H >= 1 && H <= O && (a(H), M(""));
3284
+ }), [W, M] = g.useState(""), V = (y) => {
3285
+ M(y.target.value);
3286
+ }, K = (y) => {
3287
+ if (y.key === "Enter") {
3288
+ const H = parseInt(W);
3289
+ !isNaN(H) && H >= 1 && H <= S && (a(H), M(""));
3275
3290
  }
3276
3291
  };
3277
3292
  if (e === 0)
3278
- return /* @__PURE__ */ o(Y, { className: "pagination-empty", children: $ || "No items to display" });
3293
+ return /* @__PURE__ */ o(J, { className: "pagination-empty", children: x || "No items to display" });
3279
3294
  let P = ["pagination"];
3280
- return c && P.push(c), d && P.push("disabled"), k && P.push("loading"), /* @__PURE__ */ T(
3281
- I,
3295
+ return c && P.push(c), d && P.push("disabled"), $ && P.push("loading"), /* @__PURE__ */ T(
3296
+ A,
3282
3297
  {
3283
3298
  as: "nav",
3284
3299
  "data-pagination": !0,
3285
- ref: y,
3300
+ ref: v,
3286
3301
  classNames: P,
3287
3302
  role: "navigation",
3288
3303
  "aria-label": "pagination",
3289
3304
  ...L,
3290
3305
  children: [
3291
- /* @__PURE__ */ T(G, { className: "pagination-controls", children: [
3306
+ /* @__PURE__ */ T(C, { className: "pagination-controls", children: [
3292
3307
  n && (!f || D) && p({
3293
3308
  type: "first",
3294
3309
  disabled: !D || d,
@@ -3301,57 +3316,57 @@ const Ue = (e, t) => {
3301
3316
  selected: !1,
3302
3317
  onClick: () => a(t - 1)
3303
3318
  }),
3304
- x.map((w, H) => {
3305
- const F = w === "..." ? {
3319
+ R.map((y, H) => {
3320
+ const F = y === "..." ? {
3306
3321
  key: `ellipsis-${H}`,
3307
3322
  type: "ellipsis",
3308
3323
  selected: !1,
3309
3324
  disabled: !0
3310
3325
  } : {
3311
- key: w.toString(),
3326
+ key: y.toString(),
3312
3327
  type: "page",
3313
- page: w,
3314
- selected: w === t,
3328
+ page: y,
3329
+ selected: y === t,
3315
3330
  disabled: d,
3316
- "aria-current": w === t ? "page" : void 0,
3317
- onClick: () => a(w)
3331
+ "aria-current": y === t ? "page" : void 0,
3332
+ onClick: () => a(y)
3318
3333
  };
3319
3334
  return p(F);
3320
3335
  }),
3321
- l && (!f || g) && p({
3336
+ l && (!f || N) && p({
3322
3337
  type: "next",
3323
- disabled: !g || d,
3338
+ disabled: !N || d,
3324
3339
  selected: !1,
3325
3340
  onClick: () => a(t + 1)
3326
3341
  }),
3327
- s && (!f || g) && p({
3342
+ s && (!f || N) && p({
3328
3343
  type: "last",
3329
- disabled: !g || d,
3344
+ disabled: !N || d,
3330
3345
  selected: !1,
3331
- onClick: () => a(O)
3346
+ onClick: () => a(S)
3332
3347
  }),
3333
- k && /* @__PURE__ */ T(G, { className: "pagination-loading", children: [
3348
+ $ && /* @__PURE__ */ T(C, { className: "pagination-loading", children: [
3334
3349
  /* @__PURE__ */ o(pt, {}),
3335
- N && /* @__PURE__ */ o(Y, { size: "small", children: N })
3350
+ k && /* @__PURE__ */ o(J, { size: "small", children: k })
3336
3351
  ] })
3337
3352
  ] }),
3338
- /* @__PURE__ */ T(G, { className: "pagination-info", children: [
3339
- /* @__PURE__ */ T(Y, { size: "tiny", children: [
3353
+ /* @__PURE__ */ T(C, { className: "pagination-info", children: [
3354
+ /* @__PURE__ */ T(J, { size: "tiny", children: [
3340
3355
  h,
3341
3356
  " ",
3342
3357
  E,
3343
3358
  " of ",
3344
3359
  e
3345
3360
  ] }),
3346
- u && /* @__PURE__ */ o(G, { className: "pagination-go-to", children: /* @__PURE__ */ o(
3361
+ u && /* @__PURE__ */ o(C, { className: "pagination-go-to", children: /* @__PURE__ */ o(
3347
3362
  "input",
3348
3363
  {
3349
3364
  type: "number",
3350
3365
  min: 1,
3351
- max: O,
3352
- value: B,
3366
+ max: S,
3367
+ value: W,
3353
3368
  onChange: V,
3354
- onKeyDown: C,
3369
+ onKeyDown: K,
3355
3370
  placeholder: `Go to ${h}`,
3356
3371
  "aria-label": `Go to ${h}`,
3357
3372
  disabled: d
@@ -3364,7 +3379,7 @@ const Ue = (e, t) => {
3364
3379
  }
3365
3380
  );
3366
3381
  na.displayName = "Pagination";
3367
- const oa = b.forwardRef(
3382
+ const oa = g.forwardRef(
3368
3383
  ({
3369
3384
  label: e,
3370
3385
  value: t,
@@ -3377,26 +3392,26 @@ const oa = b.forwardRef(
3377
3392
  fillColour: l,
3378
3393
  ...u
3379
3394
  }, d) => {
3380
- const f = Math.max(0, Math.min(r, Number(t) || 0)), p = `${f}${u.suffix || ""}`, k = s || n, N = l || i, $ = {
3395
+ const f = Math.max(0, Math.min(r, Number(t) || 0)), p = `${f}${u.suffix || ""}`, $ = s || n, k = l || i, x = {
3381
3396
  height: a,
3382
- ...k && { "--progress-bar-bg": `var(--${k})` },
3383
- ...N && { "--progress-bar-fill": `var(--${N})` }
3397
+ ...$ && { "--progress-bar-bg": `var(--${$})` },
3398
+ ...k && { "--progress-bar-fill": `var(--${k})` }
3384
3399
  };
3385
- return /* @__PURE__ */ T($e, { children: [
3400
+ return /* @__PURE__ */ T(Ee, { children: [
3386
3401
  e && /* @__PURE__ */ T(
3387
- I,
3402
+ A,
3388
3403
  {
3389
3404
  as: "div",
3390
3405
  "data-progress-bar-meta": !0,
3391
3406
  "aria-hidden": "true",
3392
3407
  children: [
3393
- /* @__PURE__ */ o(Y, { children: e }),
3394
- /* @__PURE__ */ o(Y, { children: p })
3408
+ /* @__PURE__ */ o(J, { children: e }),
3409
+ /* @__PURE__ */ o(J, { children: p })
3395
3410
  ]
3396
3411
  }
3397
3412
  ),
3398
3413
  /* @__PURE__ */ o(
3399
- I,
3414
+ A,
3400
3415
  {
3401
3416
  as: "progress",
3402
3417
  "data-progress-bar": !0,
@@ -3410,14 +3425,14 @@ const oa = b.forwardRef(
3410
3425
  "aria-valuetext": `${e ? `${e}: ` : ""}${p}`,
3411
3426
  shape: c,
3412
3427
  ...u,
3413
- style: $
3428
+ style: x
3414
3429
  }
3415
3430
  )
3416
3431
  ] });
3417
3432
  }
3418
3433
  );
3419
3434
  oa.displayName = "ProgressBar";
3420
- const Be = Se({
3435
+ const Ve = Oe({
3421
3436
  isSelected: () => !1,
3422
3437
  toggleSelection: () => {
3423
3438
  },
@@ -3435,7 +3450,7 @@ const Be = Se({
3435
3450
  },
3436
3451
  unregisterOption: () => {
3437
3452
  }
3438
- }), ia = b.forwardRef(
3453
+ }), ia = g.forwardRef(
3439
3454
  ({
3440
3455
  children: e,
3441
3456
  allowMultipleSelections: t = !1,
@@ -3448,71 +3463,71 @@ const Be = Se({
3448
3463
  }, l) => {
3449
3464
  const [u, d] = j(
3450
3465
  s ? new Set(s) : /* @__PURE__ */ new Set()
3451
- ), f = J(/* @__PURE__ */ new Map());
3452
- q(() => {
3466
+ ), f = Y(/* @__PURE__ */ new Map());
3467
+ U(() => {
3453
3468
  s && s.size > 0 && (d(new Set(s)), r == null || r(new Set(s)));
3454
3469
  }, [s, r]);
3455
- const p = _((E, D) => {
3470
+ const p = G((E, D) => {
3456
3471
  f.current.set(E, D);
3457
- }, []), k = _((E) => {
3472
+ }, []), $ = G((E) => {
3458
3473
  f.current.delete(E);
3459
- }, []), N = _((E) => {
3474
+ }, []), k = G((E) => {
3460
3475
  d((D) => {
3461
- const g = new Set(D);
3476
+ const N = new Set(D);
3462
3477
  if (t)
3463
- if (g.has(E))
3464
- g.delete(E);
3478
+ if (N.has(E))
3479
+ N.delete(E);
3465
3480
  else {
3466
- if (n && g.size >= n)
3481
+ if (n && N.size >= n)
3467
3482
  return D;
3468
- g.add(E);
3483
+ N.add(E);
3469
3484
  }
3470
3485
  else
3471
- g.has(E) && D.size === 1 ? g.clear() : (g.clear(), g.add(E));
3472
- return r == null || r(g), g;
3486
+ N.has(E) && D.size === 1 ? N.clear() : (N.clear(), N.add(E));
3487
+ return r == null || r(N), N;
3473
3488
  });
3474
- }, [t, r, n]), $ = _(() => {
3489
+ }, [t, r, n]), x = G(() => {
3475
3490
  t && d((E) => {
3476
- const D = new Set(E), g = Array.from(f.current.entries()).filter(([M, V]) => !V).map(([M]) => M);
3477
- return (n ? g.slice(0, n) : g).forEach((M) => D.add(M)), r == null || r(D), D;
3491
+ const D = new Set(E), N = Array.from(f.current.entries()).filter(([M, V]) => !V).map(([M]) => M);
3492
+ return (n ? N.slice(0, n) : N).forEach((M) => D.add(M)), r == null || r(D), D;
3478
3493
  });
3479
- }, [t, n, r]), h = _(() => {
3494
+ }, [t, n, r]), h = G(() => {
3480
3495
  d(/* @__PURE__ */ new Set()), r == null || r(/* @__PURE__ */ new Set());
3481
- }, [r]), L = _((E) => {
3496
+ }, [r]), L = G((E) => {
3482
3497
  E && (console.log("Setting selected options:", E), d(() => {
3483
3498
  const D = new Set(E);
3484
3499
  return r == null || r(D), D;
3485
3500
  }));
3486
- }, [r]), y = _((E) => {
3501
+ }, [r]), v = G((E) => {
3487
3502
  E && (console.log("Setting selected ids:", Array.from(E)), d(() => {
3488
3503
  const D = new Set(E);
3489
3504
  return r == null || r(D), D;
3490
3505
  }));
3491
- }, [r]), x = _((E) => u.has(E), [u]);
3492
- b.useImperativeHandle(l, () => ({
3493
- selectAllOptions: $,
3506
+ }, [r]), R = G((E) => u.has(E), [u]);
3507
+ g.useImperativeHandle(l, () => ({
3508
+ selectAllOptions: x,
3494
3509
  clearAllOptions: h,
3495
3510
  setSelectedOptions: L,
3496
- setSelectedIds: y
3497
- }), [$, h, L, y]);
3498
- const O = {
3499
- isSelected: x,
3500
- toggleSelection: N,
3511
+ setSelectedIds: v
3512
+ }), [x, h, L, v]);
3513
+ const S = {
3514
+ isSelected: R,
3515
+ toggleSelection: k,
3501
3516
  showTickIcon: a,
3502
3517
  tickPosition: c,
3503
- selectAllOptions: $,
3518
+ selectAllOptions: x,
3504
3519
  clearAllOptions: h,
3505
3520
  setSelectedOptions: L,
3506
- setSelectedIds: y,
3521
+ setSelectedIds: v,
3507
3522
  registerOption: p,
3508
- unregisterOption: k
3523
+ unregisterOption: $
3509
3524
  };
3510
- return /* @__PURE__ */ o(Be.Provider, { value: O, children: /* @__PURE__ */ o(G, { "data-option-cards-group": !0, className: `tick-${c}`, children: e }) });
3525
+ return /* @__PURE__ */ o(Ve.Provider, { value: S, children: /* @__PURE__ */ o(C, { "data-option-cards-group": !0, className: `tick-${c}`, children: e }) });
3511
3526
  }
3512
3527
  );
3513
3528
  ia.displayName = "OptionCardsGroup";
3514
3529
  const Ua = (e) => {
3515
- const t = be(Be);
3530
+ const t = Ne(Ve);
3516
3531
  return {
3517
3532
  isSelected: t.isSelected(e),
3518
3533
  toggleSelection: () => t.toggleSelection(e),
@@ -3524,7 +3539,7 @@ const Ua = (e) => {
3524
3539
  clearAllOptions: t,
3525
3540
  setSelectedOptions: a,
3526
3541
  setSelectedIds: r
3527
- } = be(Be);
3542
+ } = Ne(Ve);
3528
3543
  return {
3529
3544
  selectAllOptions: e,
3530
3545
  clearAllOptions: t,
@@ -3532,22 +3547,22 @@ const Ua = (e) => {
3532
3547
  setSelectedIds: r
3533
3548
  };
3534
3549
  }, Ya = ({ id: e, children: t, disabled: a = !1, ...r }) => {
3535
- const { isSelected: c, toggleSelection: n, showTickIcon: s, registerOption: i, unregisterOption: l } = be(Be), [u, d] = j(!1), [f, p] = j(!0);
3536
- b.useEffect(() => (i(e, a), () => l(e)), [e, a, i, l]);
3537
- let k = [];
3538
- c(e) && k.push("selected"), a && k.push("disabled"), u && k.push("show-deselect");
3539
- const N = () => {
3550
+ const { isSelected: c, toggleSelection: n, showTickIcon: s, registerOption: i, unregisterOption: l } = Ne(Ve), [u, d] = j(!1), [f, p] = j(!0);
3551
+ g.useEffect(() => (i(e, a), () => l(e)), [e, a, i, l]);
3552
+ let $ = [];
3553
+ c(e) && $.push("selected"), a && $.push("disabled"), u && $.push("show-deselect");
3554
+ const k = () => {
3540
3555
  c(e) && !f && d(!0);
3541
- }, $ = () => {
3556
+ }, x = () => {
3542
3557
  d(!1), p(!1);
3543
- }, h = (y) => {
3544
- var x;
3545
- a || (p(!0), d(!1), n(e), (x = r.onClick) == null || x.call(r, y));
3546
- }, L = (y) => {
3547
- (y.key === "Enter" || y.key === " ") && !a && (y.preventDefault(), p(!0), d(!1), n(e));
3558
+ }, h = (v) => {
3559
+ var R;
3560
+ a || (p(!0), d(!1), n(e), (R = r.onClick) == null || R.call(r, v));
3561
+ }, L = (v) => {
3562
+ (v.key === "Enter" || v.key === " ") && !a && (v.preventDefault(), p(!0), d(!1), n(e));
3548
3563
  };
3549
3564
  return /* @__PURE__ */ T(
3550
- I,
3565
+ A,
3551
3566
  {
3552
3567
  as: Qe,
3553
3568
  "data-option-card": !0,
@@ -3555,14 +3570,14 @@ const Ua = (e) => {
3555
3570
  tabIndex: a ? -1 : 0,
3556
3571
  "aria-disabled": a,
3557
3572
  "aria-selected": c(e),
3558
- classNames: k,
3573
+ classNames: $,
3559
3574
  onClick: h,
3560
3575
  onKeyDown: L,
3561
- onMouseEnter: N,
3562
- onMouseLeave: $,
3576
+ onMouseEnter: k,
3577
+ onMouseLeave: x,
3563
3578
  ...r,
3564
3579
  children: [
3565
- s && /* @__PURE__ */ T($e, { children: [
3580
+ s && /* @__PURE__ */ T(Ee, { children: [
3566
3581
  /* @__PURE__ */ T("svg", { viewBox: "0 0 24 24", className: "tick-icon", children: [
3567
3582
  /* @__PURE__ */ o("circle", { cx: "12", cy: "12", r: "11" }),
3568
3583
  /* @__PURE__ */ o("path", { d: "M8 13 L11 15 L16 9" })
@@ -3576,20 +3591,20 @@ const Ua = (e) => {
3576
3591
  ]
3577
3592
  }
3578
3593
  );
3579
- }, la = b.forwardRef(
3594
+ }, la = g.forwardRef(
3580
3595
  ({
3581
3596
  collapsed: e,
3582
3597
  closeOnClickOutside: t,
3583
3598
  showMobileSidebar: a,
3584
3599
  ...r
3585
3600
  }, c) => {
3586
- const n = J(null);
3601
+ const n = Y(null);
3587
3602
  Je(c, () => n.current), We(n, () => {
3588
3603
  typeof t == "function" && t();
3589
3604
  });
3590
3605
  let s = [];
3591
3606
  return e && s.push("collapsed"), a && s.push("show-sidebar"), /* @__PURE__ */ o(
3592
- I,
3607
+ A,
3593
3608
  {
3594
3609
  as: "aside",
3595
3610
  "data-sidebar-wrapper": !0,
@@ -3601,9 +3616,9 @@ const Ua = (e) => {
3601
3616
  }
3602
3617
  );
3603
3618
  la.displayName = "SidebarWrapper";
3604
- const ca = b.forwardRef(
3619
+ const ca = g.forwardRef(
3605
3620
  ({ label: e, ...t }, a) => /* @__PURE__ */ o(
3606
- I,
3621
+ A,
3607
3622
  {
3608
3623
  as: "main",
3609
3624
  "data-content-wrapper": !0,
@@ -3615,11 +3630,11 @@ const ca = b.forwardRef(
3615
3630
  )
3616
3631
  );
3617
3632
  ca.displayName = "ContentWrapper";
3618
- const da = b.forwardRef(
3633
+ const da = g.forwardRef(
3619
3634
  ({ isSticky: e, ...t }, a) => {
3620
3635
  let r = [];
3621
3636
  return e && r.push("is-sticky"), /* @__PURE__ */ o(
3622
- I,
3637
+ A,
3623
3638
  {
3624
3639
  as: "header",
3625
3640
  "data-sidebar-header": !0,
@@ -3631,11 +3646,11 @@ const da = b.forwardRef(
3631
3646
  }
3632
3647
  );
3633
3648
  da.displayName = "SidebarHeader";
3634
- const ua = b.forwardRef(
3649
+ const ua = g.forwardRef(
3635
3650
  ({ hasAlert: e, hasEmptyIcon: t, hasNoIcon: a, children: r, ...c }, n) => {
3636
3651
  let s = [];
3637
3652
  return e && s.push("has-alert"), t ? s.push("has-empty-icon") : a && s.push("has-no-icon"), /* @__PURE__ */ T(
3638
- I,
3653
+ A,
3639
3654
  {
3640
3655
  as: "div",
3641
3656
  "data-sidebar-item": !0,
@@ -3643,7 +3658,7 @@ const ua = b.forwardRef(
3643
3658
  classNames: s,
3644
3659
  ...c,
3645
3660
  children: [
3646
- t && /* @__PURE__ */ o(G, { className: "empty-icon-wrapper" }),
3661
+ t && /* @__PURE__ */ o(C, { className: "empty-icon-wrapper" }),
3647
3662
  r
3648
3663
  ]
3649
3664
  }
@@ -3651,11 +3666,11 @@ const ua = b.forwardRef(
3651
3666
  }
3652
3667
  );
3653
3668
  ua.displayName = "SidebarItem";
3654
- const fa = b.forwardRef(
3669
+ const fa = g.forwardRef(
3655
3670
  ({ isSticky: e, ...t }, a) => {
3656
3671
  let r = [];
3657
3672
  return e && r.push("is-sticky"), /* @__PURE__ */ o(
3658
- I,
3673
+ A,
3659
3674
  {
3660
3675
  as: "footer",
3661
3676
  "data-sidebar-footer": !0,
@@ -3667,10 +3682,10 @@ const fa = b.forwardRef(
3667
3682
  }
3668
3683
  );
3669
3684
  fa.displayName = "SidebarFooter";
3670
- const mt = Se({
3685
+ const mt = Oe({
3671
3686
  effect: "wave",
3672
3687
  animate: !0
3673
- }), pa = b.forwardRef(({
3688
+ }), pa = g.forwardRef(({
3674
3689
  variant: e = "line",
3675
3690
  width: t,
3676
3691
  height: a,
@@ -3679,23 +3694,23 @@ const mt = Se({
3679
3694
  loadingLabel: n,
3680
3695
  ...s
3681
3696
  }, i) => {
3682
- const l = be(mt), u = c || l.effect, d = n || l.loadingLabel || "Loading...";
3697
+ const l = Ne(mt), u = c || l.effect, d = n || l.loadingLabel || "Loading...";
3683
3698
  let f = [];
3684
3699
  e && f.push(`variant-${e}`), r && f.push(`shape-${r}`), u && f.push(`effect-${u}`);
3685
- const p = t || "100%", k = e === "circle" ? (typeof t == "number" ? `${t}px` : t) || a || "100%" : a, N = {
3700
+ const p = t || "100%", $ = e === "circle" ? (typeof t == "number" ? `${t}px` : t) || a || "100%" : a, k = {
3686
3701
  width: p,
3687
- height: k,
3702
+ height: $,
3688
3703
  aspectRatio: e === "circle" ? "1 / 1" : "auto",
3689
3704
  ...s.style
3690
3705
  };
3691
3706
  return /* @__PURE__ */ o(
3692
- I,
3707
+ A,
3693
3708
  {
3694
3709
  as: "div",
3695
3710
  "data-skeleton": !0,
3696
3711
  ref: i,
3697
3712
  classNames: f,
3698
- style: N,
3713
+ style: k,
3699
3714
  role: "progressbar",
3700
3715
  "aria-busy": "true",
3701
3716
  "aria-valuemin": 0,
@@ -3707,7 +3722,7 @@ const mt = Se({
3707
3722
  );
3708
3723
  });
3709
3724
  pa.displayName = "Skeleton";
3710
- const ma = b.forwardRef(({
3725
+ const ma = g.forwardRef(({
3711
3726
  effect: e = "wave",
3712
3727
  spacing: t = "small",
3713
3728
  animate: a = !0,
@@ -3724,7 +3739,7 @@ const ma = b.forwardRef(({
3724
3739
  ...s
3725
3740
  ];
3726
3741
  return t && d.push(`spacing-${t}`), /* @__PURE__ */ o(mt.Provider, { value: { effect: e, animate: a, loadingLabel: i }, children: /* @__PURE__ */ o(
3727
- I,
3742
+ A,
3728
3743
  {
3729
3744
  as: "div",
3730
3745
  ref: u,
@@ -3734,14 +3749,14 @@ const ma = b.forwardRef(({
3734
3749
  "aria-busy": "true",
3735
3750
  "aria-label": i,
3736
3751
  ...l,
3737
- children: Array(r).fill(n).map((f, p) => b.cloneElement(f, {
3752
+ children: Array(r).fill(n).map((f, p) => g.cloneElement(f, {
3738
3753
  key: p
3739
3754
  }))
3740
3755
  }
3741
3756
  ) });
3742
3757
  });
3743
3758
  ma.displayName = "SkeletonGroup";
3744
- const ha = b.forwardRef(
3759
+ const ha = g.forwardRef(
3745
3760
  ({
3746
3761
  bordersFor: e,
3747
3762
  isStriped: t,
@@ -3756,9 +3771,9 @@ const ha = b.forwardRef(
3756
3771
  }, d) => {
3757
3772
  let f = [];
3758
3773
  e && f.push(`bordered-${e}`), t && f.push("striped"), a && f.push("hoverable"), r && f.push("full-width"), c && f.push(`align-text-${c}`);
3759
- const p = b.Children.count(l);
3774
+ const p = g.Children.count(l);
3760
3775
  return /* @__PURE__ */ T(
3761
- I,
3776
+ A,
3762
3777
  {
3763
3778
  as: "table",
3764
3779
  classNames: f,
@@ -3766,12 +3781,12 @@ const ha = b.forwardRef(
3766
3781
  role: "table",
3767
3782
  "aria-rowcount": p || void 0,
3768
3783
  "aria-colcount": i ? void 0 : (() => {
3769
- if (!l || !b.isValidElement(l)) return;
3770
- const N = b.Children.toArray(l)[0];
3771
- if (b.isValidElement(N)) {
3772
- const $ = N.props;
3773
- if ($.children)
3774
- return b.Children.count($.children);
3784
+ if (!l || !g.isValidElement(l)) return;
3785
+ const k = g.Children.toArray(l)[0];
3786
+ if (g.isValidElement(k)) {
3787
+ const x = k.props;
3788
+ if (x.children)
3789
+ return g.Children.count(x.children);
3775
3790
  }
3776
3791
  })(),
3777
3792
  summary: s,
@@ -3785,37 +3800,37 @@ const ha = b.forwardRef(
3785
3800
  }
3786
3801
  );
3787
3802
  ha.displayName = "Table";
3788
- const va = b.forwardRef(
3803
+ const va = g.forwardRef(
3789
3804
  ({ tabs: e, additionalNavContentWrapper: t, defaultActiveTab: a, align: r = "left", isFullWidth: c, ...n }, s) => {
3790
- const i = e.findIndex((h) => h.key === a), l = i > -1 ? i : 0, [u, d] = b.useState(
3805
+ const i = e.findIndex((h) => h.key === a), l = i > -1 ? i : 0, [u, d] = g.useState(
3791
3806
  e.length > 0 ? e[l] : void 0
3792
- ), [f, p] = b.useState(!1), k = J([]), N = _((h) => {
3807
+ ), [f, p] = g.useState(!1), $ = Y([]), k = G((h) => {
3793
3808
  (u == null ? void 0 : u.key) !== h.key && (p(!0), setTimeout(() => {
3794
3809
  d(h), p(!1);
3795
3810
  }, 150));
3796
3811
  }, [u == null ? void 0 : u.key]);
3797
- q(() => {
3812
+ U(() => {
3798
3813
  e.length > 0 ? e.find((L) => L.key === (u == null ? void 0 : u.key)) || d(e[l]) : d(void 0);
3799
3814
  }, [e, l, u == null ? void 0 : u.key]);
3800
- const $ = _((h, L) => {
3801
- var O;
3802
- let y = L;
3815
+ const x = G((h, L) => {
3816
+ var S;
3817
+ let v = L;
3803
3818
  if (h.key === "ArrowRight")
3804
- y = (L + 1) % e.length;
3819
+ v = (L + 1) % e.length;
3805
3820
  else if (h.key === "ArrowLeft")
3806
- y = (L - 1 + e.length) % e.length;
3821
+ v = (L - 1 + e.length) % e.length;
3807
3822
  else if (h.key === "Home")
3808
- y = 0;
3823
+ v = 0;
3809
3824
  else if (h.key === "End")
3810
- y = e.length - 1;
3825
+ v = e.length - 1;
3811
3826
  else
3812
3827
  return;
3813
3828
  h.preventDefault();
3814
- const x = e[y];
3815
- x && (N(x), (O = k.current[y]) == null || O.focus());
3816
- }, [e, N]);
3829
+ const R = e[v];
3830
+ R && (k(R), (S = $.current[v]) == null || S.focus());
3831
+ }, [e, k]);
3817
3832
  return u ? /* @__PURE__ */ T(
3818
- I,
3833
+ A,
3819
3834
  {
3820
3835
  as: "div",
3821
3836
  "data-tabs": !0,
@@ -3826,10 +3841,10 @@ const va = b.forwardRef(
3826
3841
  children: [
3827
3842
  /* @__PURE__ */ o(Pt, { "data-tabs-nav": !0, role: "tablist", "aria-label": "Tab Navigation", children: /* @__PURE__ */ T("ul", { className: "tab-labels-list", children: [
3828
3843
  e.map((h, L) => /* @__PURE__ */ o("li", { children: /* @__PURE__ */ o(
3829
- I,
3844
+ A,
3830
3845
  {
3831
3846
  as: "button",
3832
- ref: (y) => k.current[L] = y,
3847
+ ref: (v) => $.current[L] = v,
3833
3848
  id: `tab-${h.key}`,
3834
3849
  role: "tab",
3835
3850
  "aria-selected": u.key === h.key,
@@ -3838,12 +3853,12 @@ const va = b.forwardRef(
3838
3853
  "data-tab-label": !0,
3839
3854
  "data-active": u.key === h.key,
3840
3855
  "data-alert": h.hasAlert,
3841
- onClick: () => N(h),
3842
- onKeyDown: (y) => $(y, L),
3856
+ onClick: () => k(h),
3857
+ onKeyDown: (v) => x(v, L),
3843
3858
  className: `tab-button ${u.key === h.key ? "is-active" : ""}`,
3844
3859
  marginBottom: "nano",
3845
3860
  children: /* @__PURE__ */ o(
3846
- Y,
3861
+ J,
3847
3862
  {
3848
3863
  className: `tab-label ${u.key === h.key ? "is-active" : ""} ${h.hasAlert ? "has-alert" : ""}`,
3849
3864
  children: h.label
@@ -3855,7 +3870,7 @@ const va = b.forwardRef(
3855
3870
  ] }) }),
3856
3871
  /* @__PURE__ */ o(et, { kind: "tertiary", marginTop: "none", marginBottom: "micro" }),
3857
3872
  e.map((h) => /* @__PURE__ */ o(
3858
- G,
3873
+ C,
3859
3874
  {
3860
3875
  id: `tab-panel-${h.key}`,
3861
3876
  role: "tabpanel",
@@ -3875,7 +3890,7 @@ const va = b.forwardRef(
3875
3890
  }
3876
3891
  );
3877
3892
  va.displayName = "Tabs";
3878
- const Ie = () => {
3893
+ const Ae = () => {
3879
3894
  if (typeof window < "u") {
3880
3895
  const e = window.location.hostname, t = window.location.port;
3881
3896
  let a = e.replace(/\./g, "-");
@@ -3883,8 +3898,8 @@ const Ie = () => {
3883
3898
  }
3884
3899
  return "fictoan-theme";
3885
3900
  }, ya = ["", (e) => {
3886
- }], ht = b.createContext(void 0), Ja = () => {
3887
- const e = b.useContext(ht);
3901
+ }], ht = g.createContext(void 0), Ja = () => {
3902
+ const e = g.useContext(ht);
3888
3903
  return e === void 0 ? ya : e;
3889
3904
  }, qe = (e, t) => {
3890
3905
  let a;
@@ -3893,42 +3908,42 @@ const Ie = () => {
3893
3908
  } catch {
3894
3909
  }
3895
3910
  return a || t;
3896
- }, wa = b.forwardRef(
3911
+ }, wa = g.forwardRef(
3897
3912
  ({ currentTheme: e, themeList: t, children: a, ...r }, c) => {
3898
- const [n, s] = j(!1), [i, l] = j(() => qe(Ie()) || e), u = _(
3913
+ const [n, s] = j(!1), [i, l] = j(() => qe(Ae()) || e), u = G(
3899
3914
  (d) => {
3900
3915
  const f = typeof d == "function" ? d(i) : d;
3901
3916
  if (!t.includes(f)) {
3902
3917
  const p = t[0];
3903
3918
  l(p), document.documentElement.className = "", document.documentElement.classList.add(p);
3904
3919
  try {
3905
- localStorage.setItem(Ie(), p);
3920
+ localStorage.setItem(Ae(), p);
3906
3921
  } catch {
3907
3922
  }
3908
3923
  return;
3909
3924
  }
3910
3925
  l(f), document.documentElement.className = "", document.documentElement.classList.add(f), n || s(!0);
3911
3926
  try {
3912
- localStorage.setItem(Ie(), f);
3927
+ localStorage.setItem(Ae(), f);
3913
3928
  } catch {
3914
3929
  }
3915
3930
  },
3916
3931
  [i, t]
3917
3932
  );
3918
- return q(() => {
3919
- const d = qe(Ie());
3933
+ return U(() => {
3934
+ const d = qe(Ae());
3920
3935
  u(d || e);
3921
- }, [e, u]), /* @__PURE__ */ o(ht.Provider, { value: [i, u], children: /* @__PURE__ */ o(I, { as: "div", "data-theme-provider": !0, ref: c, ...r, children: n && a }) });
3936
+ }, [e, u]), /* @__PURE__ */ o(ht.Provider, { value: [i, u], children: /* @__PURE__ */ o(A, { as: "div", "data-theme-provider": !0, ref: c, ...r, children: n && a }) });
3922
3937
  }
3923
3938
  );
3924
3939
  wa.displayName = "ThemeProvider";
3925
- const vt = b.forwardRef(
3940
+ const vt = g.forwardRef(
3926
3941
  ({
3927
3942
  anchor: e = "top",
3928
3943
  children: t,
3929
3944
  ...a
3930
- }, r) => b.Children.count(t) === 0 ? null : /* @__PURE__ */ o(
3931
- I,
3945
+ }, r) => g.Children.count(t) === 0 ? null : /* @__PURE__ */ o(
3946
+ A,
3932
3947
  {
3933
3948
  as: "section",
3934
3949
  "data-toasts-wrapper": !0,
@@ -3950,20 +3965,20 @@ const yt = ({
3950
3965
  children: r
3951
3966
  }) => {
3952
3967
  const [c, n] = j(!1);
3953
- return q(() => {
3968
+ return U(() => {
3954
3969
  if (t === 0) return;
3955
3970
  const i = setTimeout(() => {
3956
3971
  n(!0);
3957
3972
  }, t * 1e3);
3958
3973
  return () => clearTimeout(i);
3959
- }, [t]), q(() => {
3974
+ }, [t]), U(() => {
3960
3975
  if (!c) return;
3961
3976
  const i = setTimeout(() => {
3962
3977
  a();
3963
3978
  }, 500);
3964
3979
  return () => clearTimeout(i);
3965
3980
  }, [c, a]), /* @__PURE__ */ o(
3966
- I,
3981
+ A,
3967
3982
  {
3968
3983
  as: "div",
3969
3984
  "data-toast-item": !0,
@@ -3981,13 +3996,13 @@ const yt = ({
3981
3996
  );
3982
3997
  };
3983
3998
  yt.displayName = "ToastItem";
3984
- const wt = Se(null), ba = ({
3999
+ const wt = Oe(null), ba = ({
3985
4000
  children: e,
3986
4001
  anchor: t = "top"
3987
4002
  }) => {
3988
- const [a, r] = j([]), c = _((s) => {
4003
+ const [a, r] = j([]), c = G((s) => {
3989
4004
  r((i) => i.filter((l) => l.id !== s));
3990
- }, []), n = _((s, i = 4) => {
4005
+ }, []), n = G((s, i = 4) => {
3991
4006
  const l = `toast-${Date.now()}-${Math.random().toString(36).substring(2, 9)}`;
3992
4007
  r((u) => [...u, {
3993
4008
  id: l,
@@ -4011,33 +4026,33 @@ const wt = Se(null), ba = ({
4011
4026
  };
4012
4027
  ba.displayName = "ToastsProvider";
4013
4028
  const Za = () => {
4014
- const e = be(wt);
4029
+ const e = Ne(wt);
4015
4030
  if (!e)
4016
4031
  throw new Error("useToasts must be used within a ToastsProvider");
4017
4032
  return e.toast;
4018
- }, ue = 8, re = 16;
4019
- let se = null, fe = null, Fe = !1, oe = null, he = null;
4020
- const pe = /* @__PURE__ */ new Map(), ga = (e, t, a) => {
4033
+ }, fe = 8, ne = 16;
4034
+ let oe = null, pe = null, Fe = !1, le = null, ve = null;
4035
+ const me = /* @__PURE__ */ new Map(), ga = (e, t, a) => {
4021
4036
  const r = e.getBoundingClientRect(), c = t.getBoundingClientRect(), n = window.innerHeight, s = window.innerWidth;
4022
4037
  let i, l;
4023
4038
  switch (a) {
4024
4039
  case "top":
4025
- i = c.top - r.height - ue, l = c.left + (c.width - r.width) / 2, i < re && (i = c.bottom + ue);
4040
+ i = c.top - r.height - fe, l = c.left + (c.width - r.width) / 2, i < ne && (i = c.bottom + fe);
4026
4041
  break;
4027
4042
  case "bottom":
4028
- i = c.bottom + ue, l = c.left + (c.width - r.width) / 2, i + r.height > n - re && (i = c.top - r.height - ue);
4043
+ i = c.bottom + fe, l = c.left + (c.width - r.width) / 2, i + r.height > n - ne && (i = c.top - r.height - fe);
4029
4044
  break;
4030
4045
  case "left":
4031
- i = c.top + (c.height - r.height) / 2, l = c.left - r.width - ue, l < re && (l = c.right + ue);
4046
+ i = c.top + (c.height - r.height) / 2, l = c.left - r.width - fe, l < ne && (l = c.right + fe);
4032
4047
  break;
4033
4048
  case "right":
4034
- i = c.top + (c.height - r.height) / 2, l = c.right + ue, l + r.width > s - re && (l = c.left - r.width - ue);
4049
+ i = c.top + (c.height - r.height) / 2, l = c.right + fe, l + r.width > s - ne && (l = c.left - r.width - fe);
4035
4050
  break;
4036
4051
  default:
4037
- i = c.top - r.height - ue, l = c.left + (c.width - r.width) / 2;
4052
+ i = c.top - r.height - fe, l = c.left + (c.width - r.width) / 2;
4038
4053
  }
4039
- return l < re ? l = re : l + r.width > s - re && (l = s - r.width - re), i < re ? i = re : i + r.height > n - re && (i = n - r.height - re), { top: i, left: l };
4040
- }, Ae = ({ content: e, isVisible: t, position: a, zIndex: r }) => /* @__PURE__ */ o(
4054
+ return l < ne ? l = ne : l + r.width > s - ne && (l = s - r.width - ne), i < ne ? i = ne : i + r.height > n - ne && (i = n - r.height - ne), { top: i, left: l };
4055
+ }, Le = ({ content: e, isVisible: t, position: a, zIndex: r }) => /* @__PURE__ */ o(
4041
4056
  "div",
4042
4057
  {
4043
4058
  "data-tooltip": !0,
@@ -4051,69 +4066,69 @@ const pe = /* @__PURE__ */ new Map(), ga = (e, t, a) => {
4051
4066
  },
4052
4067
  children: e
4053
4068
  }
4054
- ), ke = (e, t) => {
4055
- if (!(!fe || !se)) {
4069
+ ), Me = (e, t) => {
4070
+ if (!(!pe || !oe)) {
4056
4071
  if (!e || !t) {
4057
- fe.render(
4058
- /* @__PURE__ */ o(Ae, { content: null, isVisible: !1, position: { top: -9999, left: -9999 }, zIndex: 1e5 })
4072
+ pe.render(
4073
+ /* @__PURE__ */ o(Le, { content: null, isVisible: !1, position: { top: -9999, left: -9999 }, zIndex: 1e5 })
4059
4074
  );
4060
4075
  return;
4061
4076
  }
4062
- fe.render(
4063
- /* @__PURE__ */ o(Ae, { content: e.content, isVisible: !1, position: { top: -9999, left: -9999 }, zIndex: e.zIndex })
4077
+ pe.render(
4078
+ /* @__PURE__ */ o(Le, { content: e.content, isVisible: !1, position: { top: -9999, left: -9999 }, zIndex: e.zIndex })
4064
4079
  ), requestAnimationFrame(() => {
4065
- if (!se || !t) return;
4066
- const a = se.firstElementChild;
4080
+ if (!oe || !t) return;
4081
+ const a = oe.firstElementChild;
4067
4082
  if (!a) return;
4068
4083
  const { top: r, left: c } = ga(a, t, e.position);
4069
- fe == null || fe.render(
4070
- /* @__PURE__ */ o(Ae, { content: e.content, isVisible: !0, position: { top: r, left: c }, zIndex: e.zIndex })
4084
+ pe == null || pe.render(
4085
+ /* @__PURE__ */ o(Le, { content: e.content, isVisible: !0, position: { top: r, left: c }, zIndex: e.zIndex })
4071
4086
  );
4072
4087
  });
4073
4088
  }
4074
4089
  }, Ye = () => {
4075
- if (!oe || !he) return;
4076
- const e = pe.get(oe);
4077
- e && ke(e, he);
4090
+ if (!le || !ve) return;
4091
+ const e = me.get(le);
4092
+ e && Me(e, ve);
4078
4093
  }, bt = (e, t) => {
4079
- const a = pe.get(e);
4080
- a && (oe = e, he = t, ke(a, t));
4081
- }, Le = (e) => {
4082
- e && oe !== e || (oe = null, he = null, ke(null, null));
4094
+ const a = me.get(e);
4095
+ a && (le = e, ve = t, Me(a, t));
4096
+ }, Se = (e) => {
4097
+ e && le !== e || (le = null, ve = null, Me(null, null));
4083
4098
  }, Na = (e) => {
4084
4099
  const t = e.target.closest("[id]");
4085
4100
  if (!(t != null && t.id)) return;
4086
- const a = pe.get(t.id);
4101
+ const a = me.get(t.id);
4087
4102
  (a == null ? void 0 : a.showOn) === "hover" && bt(t.id, t);
4088
4103
  }, ka = (e) => {
4089
4104
  const t = e.target.closest("[id]");
4090
4105
  if (!(t != null && t.id)) return;
4091
- const a = pe.get(t.id);
4092
- (a == null ? void 0 : a.showOn) === "hover" && Le(t.id);
4106
+ const a = me.get(t.id);
4107
+ (a == null ? void 0 : a.showOn) === "hover" && Se(t.id);
4093
4108
  }, $a = (e) => {
4094
- if (se != null && se.contains(e.target))
4109
+ if (oe != null && oe.contains(e.target))
4095
4110
  return;
4096
4111
  const t = e.target.closest("[id]");
4097
4112
  if (t != null && t.id) {
4098
- const a = pe.get(t.id);
4113
+ const a = me.get(t.id);
4099
4114
  if ((a == null ? void 0 : a.showOn) === "click") {
4100
- oe === t.id ? Le() : bt(t.id, t);
4115
+ le === t.id ? Se() : bt(t.id, t);
4101
4116
  return;
4102
4117
  }
4103
4118
  }
4104
- if (oe) {
4105
- const a = pe.get(oe);
4106
- (a == null ? void 0 : a.showOn) === "click" && Le();
4119
+ if (le) {
4120
+ const a = me.get(le);
4121
+ (a == null ? void 0 : a.showOn) === "click" && Se();
4107
4122
  }
4108
4123
  }, xa = () => {
4109
4124
  if (typeof document > "u") return;
4110
4125
  const e = document.getElementById("fictoan-tooltip-singleton");
4111
4126
  if (e && Fe) {
4112
- se = e;
4127
+ oe = e;
4113
4128
  return;
4114
4129
  }
4115
- Fe = !1, se = null, fe = null, se = document.createElement("div"), se.id = "fictoan-tooltip-singleton", document.body.appendChild(se), fe = Mt(se), fe.render(
4116
- /* @__PURE__ */ o(Ae, { content: null, isVisible: !1, position: { top: -9999, left: -9999 }, zIndex: 1e5 })
4130
+ Fe = !1, oe = null, pe = null, oe = document.createElement("div"), oe.id = "fictoan-tooltip-singleton", document.body.appendChild(oe), pe = Mt(oe), pe.render(
4131
+ /* @__PURE__ */ o(Le, { content: null, isVisible: !1, position: { top: -9999, left: -9999 }, zIndex: 1e5 })
4117
4132
  ), document.addEventListener("mouseover", Na), document.addEventListener("mouseout", ka), document.addEventListener("click", $a), window.addEventListener("scroll", Ye, !0), window.addEventListener("resize", Ye), Fe = !0;
4118
4133
  }, Qa = ({
4119
4134
  children: e,
@@ -4122,32 +4137,32 @@ const pe = /* @__PURE__ */ new Map(), ga = (e, t, a) => {
4122
4137
  position: r = "top",
4123
4138
  zIndex: c = 1e5
4124
4139
  }) => {
4125
- const n = J({ content: e, position: r, showOn: a, zIndex: c });
4126
- return n.current = { content: e, position: r, showOn: a, zIndex: c }, q(() => (xa(), pe.set(t, n.current), oe === t && he && ke(n.current, he), () => {
4127
- pe.delete(t), oe === t && Le();
4128
- }), [t]), q(() => {
4129
- pe.set(t, n.current), oe === t && he && ke(n.current, he);
4140
+ const n = Y({ content: e, position: r, showOn: a, zIndex: c });
4141
+ return n.current = { content: e, position: r, showOn: a, zIndex: c }, U(() => (xa(), me.set(t, n.current), le === t && ve && Me(n.current, ve), () => {
4142
+ me.delete(t), le === t && Se();
4143
+ }), [t]), U(() => {
4144
+ me.set(t, n.current), le === t && ve && Me(n.current, ve);
4130
4145
  }, [e, r, a, c, t]), null;
4131
- }, ge = b.forwardRef(
4146
+ }, ke = g.forwardRef(
4132
4147
  ({ fontStyle: e = "sans-serif", weight: t, align: a, ...r }, c) => {
4133
4148
  let n = [];
4134
- return t && n.push(`weight-${t}`), e && n.push(`font-${e}`), a && n.push(`text-${a}`), /* @__PURE__ */ o(I, { ref: c, classNames: n, ...r });
4149
+ return t && n.push(`weight-${t}`), e && n.push(`font-${e}`), a && n.push(`text-${a}`), /* @__PURE__ */ o(A, { ref: c, classNames: n, ...r });
4135
4150
  }
4136
- ), Ra = b.forwardRef((e, t) => /* @__PURE__ */ o(ge, { as: "h1", ref: t, ...e }));
4151
+ ), Ra = g.forwardRef((e, t) => /* @__PURE__ */ o(ke, { as: "h1", ref: t, ...e }));
4137
4152
  Ra.displayName = "Heading1";
4138
- const Ma = b.forwardRef((e, t) => /* @__PURE__ */ o(ge, { as: "h2", ref: t, ...e }));
4153
+ const Ma = g.forwardRef((e, t) => /* @__PURE__ */ o(ke, { as: "h2", ref: t, ...e }));
4139
4154
  Ma.displayName = "Heading2";
4140
- const Ea = b.forwardRef((e, t) => /* @__PURE__ */ o(ge, { as: "h3", ref: t, ...e }));
4155
+ const Ea = g.forwardRef((e, t) => /* @__PURE__ */ o(ke, { as: "h3", ref: t, ...e }));
4141
4156
  Ea.displayName = "Heading3";
4142
- const Pa = b.forwardRef((e, t) => /* @__PURE__ */ o(ge, { as: "h4", ref: t, ...e }));
4157
+ const Pa = g.forwardRef((e, t) => /* @__PURE__ */ o(ke, { as: "h4", ref: t, ...e }));
4143
4158
  Pa.displayName = "Heading4";
4144
- const Ta = b.forwardRef((e, t) => /* @__PURE__ */ o(ge, { as: "h5", ref: t, ...e }));
4159
+ const Ta = g.forwardRef((e, t) => /* @__PURE__ */ o(ke, { as: "h5", ref: t, ...e }));
4145
4160
  Ta.displayName = "Heading5";
4146
- const Da = b.forwardRef((e, t) => /* @__PURE__ */ o(ge, { as: "h6", ref: t, ...e }));
4161
+ const Da = g.forwardRef((e, t) => /* @__PURE__ */ o(ke, { as: "h6", ref: t, ...e }));
4147
4162
  Da.displayName = "Heading6";
4148
- const Ia = b.forwardRef(
4163
+ const Ia = g.forwardRef(
4149
4164
  ({ summary: e, children: t, isOpen: a = !1, ...r }, c) => /* @__PURE__ */ T(
4150
- I,
4165
+ A,
4151
4166
  {
4152
4167
  as: "details",
4153
4168
  "data-expandable-content": !0,
@@ -4164,7 +4179,7 @@ const Ia = b.forwardRef(
4164
4179
  tabIndex: 0,
4165
4180
  "aria-controls": "accordion-content",
4166
4181
  "aria-expanded": a,
4167
- children: typeof e == "string" ? /* @__PURE__ */ o(Y, { margin: "none", children: e }) : e
4182
+ children: typeof e == "string" ? /* @__PURE__ */ o(J, { margin: "none", children: e }) : e
4168
4183
  }
4169
4184
  ),
4170
4185
  t
@@ -4176,14 +4191,14 @@ Ia.displayName = "Accordion";
4176
4191
  export {
4177
4192
  ca as $,
4178
4193
  Ia as A,
4179
- Oe as B,
4194
+ Be as B,
4180
4195
  Ze as C,
4181
4196
  Dt as D,
4182
- I as E,
4197
+ A as E,
4183
4198
  Ha as F,
4184
4199
  ea as G,
4185
4200
  _a as H,
4186
- Re as I,
4201
+ Te as I,
4187
4202
  aa as J,
4188
4203
  Xa as K,
4189
4204
  Ut as L,
@@ -4193,7 +4208,7 @@ export {
4193
4208
  qt as P,
4194
4209
  at as Q,
4195
4210
  rt as R,
4196
- Ka as S,
4211
+ Ca as S,
4197
4212
  it as T,
4198
4213
  oa as U,
4199
4214
  nt as V,
@@ -4222,17 +4237,17 @@ export {
4222
4237
  Pa as ag,
4223
4238
  Ta as ah,
4224
4239
  Da as ai,
4225
- Y as aj,
4240
+ J as aj,
4226
4241
  It as b,
4227
4242
  Lt as c,
4228
4243
  Qe as d,
4229
4244
  St as e,
4230
4245
  et as f,
4231
- G as g,
4246
+ C as g,
4232
4247
  Fa as h,
4233
4248
  Wa as i,
4234
4249
  za as j,
4235
- Ca as k,
4250
+ Ka as k,
4236
4251
  ja as l,
4237
4252
  He as m,
4238
4253
  Vt as n,
@@ -4240,7 +4255,7 @@ export {
4240
4255
  _t as p,
4241
4256
  ee as q,
4242
4257
  Gt as r,
4243
- xe as s,
4258
+ Pe as s,
4244
4259
  st as t,
4245
4260
  Yt as u,
4246
4261
  Zt as v,
@@ -4249,4 +4264,4 @@ export {
4249
4264
  Ft as y,
4250
4265
  Qt as z
4251
4266
  };
4252
- //# sourceMappingURL=Accordion-B49ajUrB.js.map
4267
+ //# sourceMappingURL=Accordion-f3si5mdH.js.map