@tempots/beatui 0.24.0 → 0.26.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (81) hide show
  1. package/dist/{2019-7ojCcWUJ.cjs → 2019-BZdoHGOO.cjs} +1 -1
  2. package/dist/{2019-JwkYbae8.js → 2019-Bt_x1Mqh.js} +2 -2
  3. package/dist/{2020-BLYgDBO4.cjs → 2020-Bk0sGwzQ.cjs} +1 -1
  4. package/dist/{2020-kK0rQWn9.js → 2020-C2Ifu6RV.js} +2 -2
  5. package/dist/ar-CNSt2O6X.cjs +1 -0
  6. package/dist/{ar-BgrUqaxG.js → ar-CxLxXsxZ.js} +1 -1
  7. package/dist/auth/index.cjs.js +1 -1
  8. package/dist/auth/index.es.js +547 -529
  9. package/dist/de-BlQbCGWj.cjs +1 -0
  10. package/dist/{de-D_sdCcAw.js → de-C7iv8rS5.js} +1 -1
  11. package/dist/es-Chf24sm_.cjs +1 -0
  12. package/dist/{es-DczvLqEV.js → es-DyivIdRS.js} +1 -1
  13. package/dist/fa-DPDyDuq_.cjs +1 -0
  14. package/dist/{fa-DhPP5Tgo.js → fa-T2168lXR.js} +1 -1
  15. package/dist/fr-BnxbTKeV.cjs +1 -0
  16. package/dist/{fr-D3WwoeQg.js → fr-ehNjmGC4.js} +1 -1
  17. package/dist/he-B9YZGENc.cjs +1 -0
  18. package/dist/{he-CFhi-6Rs.js → he-TD57Y17Z.js} +1 -1
  19. package/dist/{hi-Cqy8JcS7.js → hi-B4NbRIf5.js} +1 -1
  20. package/dist/hi-ZyCUnzwK.cjs +1 -0
  21. package/dist/{index-BeoVum6H.js → index-C494pbos.js} +1 -1
  22. package/dist/{index-D1rYqvi5.cjs → index-CZn1Pgwz.cjs} +4 -4
  23. package/dist/{index-CgH6d8ie.cjs → index-DN_efvsJ.cjs} +1 -1
  24. package/dist/{index-DYmfX0jE.js → index-DvqD_Y1P.js} +481 -481
  25. package/dist/index.cjs.js +2 -2
  26. package/dist/index.es.js +187 -186
  27. package/dist/it-C5sp2CZC.cjs +1 -0
  28. package/dist/{it-CtMArqSp.js → it-D3x9ILJi.js} +1 -1
  29. package/dist/ja-31clSGC3.cjs +1 -0
  30. package/dist/{ja-UFqZT78C.js → ja-BSfyBDbo.js} +1 -1
  31. package/dist/json-schema/index.cjs.js +1 -1
  32. package/dist/json-schema/index.es.js +1 -1
  33. package/dist/{ko-B5LB1_X_.js → ko-DNahUn8W.js} +1 -1
  34. package/dist/ko-j4lOKHLl.cjs +1 -0
  35. package/dist/{modal-C2Aa-aVN.js → modal-5GSPw0e_.js} +1 -1
  36. package/dist/modal-CMuvQ7U-.cjs +1 -0
  37. package/dist/{nl-DCfHVqzQ.js → nl-DxveNtuq.js} +1 -1
  38. package/dist/nl-gQLaSMRt.cjs +1 -0
  39. package/dist/{translations-DpZ-btu9.cjs → notice-DTflcSdc.cjs} +2 -2
  40. package/dist/{translations-GO9sIajX.js → notice-DuvHeGyh.js} +476 -376
  41. package/dist/pl-BQTsowH4.cjs +1 -0
  42. package/dist/{pl-UcTv39q1.js → pl-DuKW800E.js} +1 -1
  43. package/dist/pt-DB-njyTA.cjs +1 -0
  44. package/dist/{pt-CXsgmVtb.js → pt-DPt1NyaL.js} +1 -1
  45. package/dist/ru-CIXDYJrr.cjs +1 -0
  46. package/dist/{ru-C0MvZW2g.js → ru-DwiRelVA.js} +1 -1
  47. package/dist/{tr-CIIkc1uL.js → tr-DQIURNMa.js} +1 -1
  48. package/dist/tr-Dx_9vMU9.cjs +1 -0
  49. package/dist/{translations-CB6iJ1Rn.js → translations-D4pKsgdi.js} +1 -1
  50. package/dist/translations-YkLfpjMl.cjs +1 -0
  51. package/dist/types/components/form/control/list-control.d.ts +4 -2
  52. package/dist/{ur-Cpx9oyTV.js → ur-ChuKCUVI.js} +1 -1
  53. package/dist/ur-DpGDKEUr.cjs +1 -0
  54. package/dist/{notice-c9Vbv45l.js → utils-CBZohCZi.js} +937 -1002
  55. package/dist/utils-Dz1qVHrn.cjs +1 -0
  56. package/dist/{vi-D24AUQ01.js → vi-CJ3gBepb.js} +1 -1
  57. package/dist/vi-CjpgcyEa.cjs +1 -0
  58. package/dist/zh-CLb0vdcx.cjs +1 -0
  59. package/dist/{zh-25YFRjoV.js → zh-DBCCiN2o.js} +1 -1
  60. package/package.json +1 -1
  61. package/dist/ar-BAb4yHZS.cjs +0 -1
  62. package/dist/de-Dn2CdXgD.cjs +0 -1
  63. package/dist/es-CEPxKSog.cjs +0 -1
  64. package/dist/fa-NvkKjIQ6.cjs +0 -1
  65. package/dist/fr-cR59lx1A.cjs +0 -1
  66. package/dist/he-CxSHPJMg.cjs +0 -1
  67. package/dist/hi-DLnz3lCX.cjs +0 -1
  68. package/dist/it-C7Kv6j-_.cjs +0 -1
  69. package/dist/ja-BPL80aw5.cjs +0 -1
  70. package/dist/ko-Cmt_34Xp.cjs +0 -1
  71. package/dist/modal-UsqvSvHy.cjs +0 -1
  72. package/dist/nl-B-WL9SX2.cjs +0 -1
  73. package/dist/notice-C7I6EmRh.cjs +0 -1
  74. package/dist/pl-TGqkSi2w.cjs +0 -1
  75. package/dist/pt-Ua_e-1JE.cjs +0 -1
  76. package/dist/ru-9YWCN6fR.cjs +0 -1
  77. package/dist/tr-D70Oy8aN.cjs +0 -1
  78. package/dist/translations-NYxsXjMT.cjs +0 -1
  79. package/dist/ur-DmxXuJ9O.cjs +0 -1
  80. package/dist/vi-Cboo_ueb.cjs +0 -1
  81. package/dist/zh-BXivX7rD.cjs +0 -1
@@ -1,6 +1,6 @@
1
- import { makeProviderMark as ae, localStorageProp as X, computedOf as k, Use as q, html as p, attr as c, When as _, Fragment as E, aria as x, coalesce as Q, style as H, prop as I, on as w, OnDispose as oe, Value as L, WithElement as ve, Empty as y, dataAttr as J, input as ie, emitValue as M, emitValueAsNumber as ke } from "@tempots/dom";
2
- import { WhenInViewport as ye, Query as we, ElementRect as Ce } from "@tempots/ui";
3
- import { b as xe, g as Se } from "./colors-WfmhQ5e1.js";
1
+ import { makeProviderMark as ae, localStorageProp as X, computedOf as y, Use as q, html as p, attr as c, When as E, Fragment as M, aria as S, coalesce as Q, style as H, prop as I, on as C, OnDispose as oe, Value as D, WithElement as ve, Empty as w, dataAttr as J, input as ie, emitValue as P, emitValueAsNumber as ke, Unless as ye, Ensure as we } from "@tempots/dom";
2
+ import { WhenInViewport as Ce, Query as xe, ElementRect as Se } from "@tempots/ui";
3
+ import { b as De, g as Ie } from "./colors-WfmhQ5e1.js";
4
4
  function ee(e, {
5
5
  units: t = ["B", "KB", "MB", "GB", "TB"],
6
6
  decimalPlaces: s = 0,
@@ -34,7 +34,7 @@ function le(e) {
34
34
  const t = te.get(e) ?? 0;
35
35
  return te.set(e, t + 1), `${e}-${t}`;
36
36
  }
37
- const C = {
37
+ const x = {
38
38
  /**
39
39
  * Creates a loading state.
40
40
  * @param previousValue - The previous value.
@@ -113,7 +113,7 @@ const C = {
113
113
  * @public
114
114
  */
115
115
  getOrElse(e, t) {
116
- return C.isSuccess(e) ? e.value : t;
116
+ return x.isSuccess(e) ? e.value : t;
117
117
  },
118
118
  /**
119
119
  * Gets the value if the result is a success; otherwise, returns the value from the alternative function.
@@ -124,7 +124,7 @@ const C = {
124
124
  * function.
125
125
  */
126
126
  getOrElseLazy(e, t) {
127
- return C.isSuccess(e) ? e.value : t();
127
+ return x.isSuccess(e) ? e.value : t();
128
128
  },
129
129
  /**
130
130
  * Gets the value if the result is a success; otherwise, returns `null`.
@@ -133,7 +133,7 @@ const C = {
133
133
  * @public
134
134
  */
135
135
  getOrNull(e) {
136
- return C.isSuccess(e) ? e.value : null;
136
+ return x.isSuccess(e) ? e.value : null;
137
137
  },
138
138
  /**
139
139
  * Gets the value if the result is a success; otherwise, returns `undefined`.
@@ -142,7 +142,7 @@ const C = {
142
142
  * @public
143
143
  */
144
144
  getOrUndefined(e) {
145
- return C.isSuccess(e) ? e.value : void 0;
145
+ return x.isSuccess(e) ? e.value : void 0;
146
146
  },
147
147
  /**
148
148
  * Gets the value of a `AsyncResult` if it is a `Success`, otherwise it throws the error contained in the `Failure`.
@@ -150,9 +150,9 @@ const C = {
150
150
  * @returns The value of the `AsyncResult` if it is a `Success`.
151
151
  */
152
152
  getUnsafe: (e) => {
153
- if (C.isSuccess(e))
153
+ if (x.isSuccess(e))
154
154
  return e.value;
155
- throw C.isFailure(e) ? e.error : new Error("Cannot get value from a not-asked or loading result");
155
+ throw x.isFailure(e) ? e.error : new Error("Cannot get value from a not-asked or loading result");
156
156
  },
157
157
  /**
158
158
  * Based on the state of the result, it picks the appropriate function to call and returns the result.
@@ -168,7 +168,7 @@ const C = {
168
168
  failure: s,
169
169
  loading: n,
170
170
  notAsked: r = n
171
- }) => C.isSuccess(e) ? t(e.value) : C.isFailure(e) ? s(e.error) : C.isNotAsked(e) ? r() : n(e.previousValue),
171
+ }) => x.isSuccess(e) ? t(e.value) : x.isFailure(e) ? s(e.error) : x.isNotAsked(e) ? r() : n(e.previousValue),
172
172
  /**
173
173
  * When the result is a success, it applies the function to the value.
174
174
  *
@@ -177,7 +177,7 @@ const C = {
177
177
  * @returns The result that was passed in.
178
178
  * @public
179
179
  */
180
- whenSuccess: (e, t) => (C.isSuccess(e) && t(e.value), e),
180
+ whenSuccess: (e, t) => (x.isSuccess(e) && t(e.value), e),
181
181
  /**
182
182
  * When the result is a failure, it applies the function to the error.
183
183
  *
@@ -186,7 +186,7 @@ const C = {
186
186
  * @returns The result that was passed in.
187
187
  * @public
188
188
  */
189
- whenFailure: (e, t) => (C.isFailure(e) && t(e.error), e),
189
+ whenFailure: (e, t) => (x.isFailure(e) && t(e.error), e),
190
190
  /**
191
191
  * Compares two results for equality.
192
192
  * @param r1 - The first result.
@@ -206,11 +206,11 @@ const C = {
206
206
  all: (e) => {
207
207
  const t = [];
208
208
  for (const s of e)
209
- if (C.isSuccess(s))
209
+ if (x.isSuccess(s))
210
210
  t.push(s.value);
211
211
  else
212
212
  return s;
213
- return C.success(t);
213
+ return x.success(t);
214
214
  },
215
215
  /**
216
216
  * Converts a Promise to an AsyncResult.
@@ -220,12 +220,12 @@ const C = {
220
220
  ofPromise: async (e) => {
221
221
  try {
222
222
  const t = await e;
223
- return C.success(t);
223
+ return x.success(t);
224
224
  } catch (t) {
225
- return C.failure(t instanceof Error ? t : new Error(String(t)));
225
+ return x.failure(t instanceof Error ? t : new Error(String(t)));
226
226
  }
227
227
  }
228
- }, N = (e, t) => e === t || e !== e && t !== t, D = {
228
+ }, F = (e, t) => e === t || e !== e && t !== t, _ = {
229
229
  /**
230
230
  * Creates a valid `Validation`.
231
231
  * @returns A `Validation` that is `Valid`.
@@ -263,17 +263,17 @@ const C = {
263
263
  * @param invalid - The mapping function for an invalid value.
264
264
  * @returns The mapped value.
265
265
  */
266
- match: (e, t, s) => D.isValid(e) ? t() : s(e.error),
266
+ match: (e, t, s) => _.isValid(e) ? t() : s(e.error),
267
267
  /**
268
268
  * Maps the value of a `Validation` to a new `Validation`.
269
269
  * @param validation - The `Validation` to map.
270
270
  * @param value - The value to map.
271
271
  * @returns A new `Validation` with the mapped value.
272
272
  */
273
- toResult: (e, t) => D.match(
273
+ toResult: (e, t) => _.match(
274
274
  e,
275
- () => g.success(t),
276
- (s) => g.failure(s)
275
+ () => k.success(t),
276
+ (s) => k.failure(s)
277
277
  ),
278
278
  /**
279
279
  * Execute a function when the `Validation` is valid.
@@ -282,7 +282,7 @@ const C = {
282
282
  * @param apply - The function to execute when the `Validation` is valid.
283
283
  * @returns The `Validation` object.
284
284
  */
285
- whenValid: (e, t) => (D.isValid(e) && t(), e),
285
+ whenValid: (e, t) => (_.isValid(e) && t(), e),
286
286
  /**
287
287
  * Execute a function when the `Validation` is invalid.
288
288
  *
@@ -290,8 +290,8 @@ const C = {
290
290
  * @param apply - The function to execute when the `Validation` is invalid.
291
291
  * @returns The `Validation` object.
292
292
  */
293
- whenInvalid: (e, t) => (D.isInvalid(e) && t(e.error), e)
294
- }, g = {
293
+ whenInvalid: (e, t) => (_.isInvalid(e) && t(e.error), e)
294
+ }, k = {
295
295
  /**
296
296
  * Creates a successful `Result`.
297
297
  * @param value - The value to wrap in a `Success` type.
@@ -319,7 +319,7 @@ const C = {
319
319
  * @returns A new `Result` with the mapped value.
320
320
  * @public
321
321
  */
322
- map: (e, t) => e.type === "Success" ? g.success(t(e.value)) : e,
322
+ map: (e, t) => e.type === "Success" ? k.success(t(e.value)) : e,
323
323
  /**
324
324
  * Maps the value of a `Result` to a new `Result`.
325
325
  * @param r - The `Result` to map.
@@ -335,10 +335,10 @@ const C = {
335
335
  * @public
336
336
  */
337
337
  toAsync(e) {
338
- return g.match(
338
+ return k.match(
339
339
  e,
340
- (t) => C.success(t),
341
- (t) => C.failure(t)
340
+ (t) => x.success(t),
341
+ (t) => x.failure(t)
342
342
  );
343
343
  },
344
344
  /**
@@ -348,10 +348,10 @@ const C = {
348
348
  * @public
349
349
  */
350
350
  toValidation(e) {
351
- return g.match(
351
+ return k.match(
352
352
  e,
353
- () => D.valid,
354
- (t) => D.invalid(t)
353
+ () => _.valid,
354
+ (t) => _.invalid(t)
355
355
  );
356
356
  },
357
357
  /**
@@ -380,7 +380,7 @@ const C = {
380
380
  * @public
381
381
  */
382
382
  getOrElse(e, t) {
383
- return g.isSuccess(e) ? e.value : t;
383
+ return k.isSuccess(e) ? e.value : t;
384
384
  },
385
385
  /**
386
386
  * Gets the value of a `Result` if it is a `Success`, otherwise returns the result of the provided function.
@@ -390,7 +390,7 @@ const C = {
390
390
  * @public
391
391
  */
392
392
  getOrElseLazy(e, t) {
393
- return g.isSuccess(e) ? e.value : t();
393
+ return k.isSuccess(e) ? e.value : t();
394
394
  },
395
395
  /**
396
396
  * Gets the value of a `Result` if it is a `Success`, otherwise returns `null`.
@@ -399,7 +399,7 @@ const C = {
399
399
  * @public
400
400
  */
401
401
  getOrNull(e) {
402
- return g.isSuccess(e) ? e.value : null;
402
+ return k.isSuccess(e) ? e.value : null;
403
403
  },
404
404
  /**
405
405
  * Gets the value of a `Result` if it is a `Success`, otherwise returns `undefined`.
@@ -408,7 +408,7 @@ const C = {
408
408
  * @public
409
409
  */
410
410
  getOrUndefined(e) {
411
- return g.isSuccess(e) ? e.value : void 0;
411
+ return k.isSuccess(e) ? e.value : void 0;
412
412
  },
413
413
  /**
414
414
  * Gets the value of a `Result` if it is a `Success`, otherwise it throws the error contained in the `Failure`.
@@ -416,7 +416,7 @@ const C = {
416
416
  * @returns The value of the `Result` if it is a `Success`.
417
417
  */
418
418
  getUnsafe: (e) => {
419
- if (g.isSuccess(e))
419
+ if (k.isSuccess(e))
420
420
  return e.value;
421
421
  throw e.error;
422
422
  },
@@ -427,15 +427,15 @@ const C = {
427
427
  * @returns The result of calling the appropriate function based on the state of the result.
428
428
  * @public
429
429
  */
430
- match: (e, t, s) => g.isSuccess(e) ? t(e.value) : s(e.error),
430
+ match: (e, t, s) => k.isSuccess(e) ? t(e.value) : s(e.error),
431
431
  /**
432
432
  * Calls the provided function if the result is a success.
433
433
  * @param apply - The function to call if the result is a success.
434
434
  * @returns A function that takes a `Result` and calls the provided function if the result is a success.
435
435
  * @public
436
436
  */
437
- whenSuccess: (e, t) => (g.isSuccess(e) && t(e.value), e),
438
- whenFailure: (e, t) => (g.isFailure(e) && t(e.error), e),
437
+ whenSuccess: (e, t) => (k.isSuccess(e) && t(e.value), e),
438
+ whenFailure: (e, t) => (k.isFailure(e) && t(e.error), e),
439
439
  /**
440
440
  * Combines two results into a single result.
441
441
  * @param r1 - The first result.
@@ -445,18 +445,18 @@ const C = {
445
445
  * @returns The combined result.
446
446
  * @public
447
447
  */
448
- combine: (e, t, s, n) => g.match(
448
+ combine: (e, t, s, n) => k.match(
449
449
  e,
450
- (r) => g.match(
450
+ (r) => k.match(
451
451
  t,
452
- (a) => g.success(s(r, a)),
453
- (a) => g.failure(a)
452
+ (a) => k.success(s(r, a)),
453
+ (a) => k.failure(a)
454
454
  ),
455
- (r) => g.match(
455
+ (r) => k.match(
456
456
  t,
457
457
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
458
- (a) => g.failure(r),
459
- (a) => g.failure(n(r, a))
458
+ (a) => k.failure(r),
459
+ (a) => k.failure(n(r, a))
460
460
  )
461
461
  ),
462
462
  /**
@@ -478,11 +478,11 @@ const C = {
478
478
  all: (e) => {
479
479
  const t = [];
480
480
  for (const s of e)
481
- if (g.isSuccess(s))
481
+ if (k.isSuccess(s))
482
482
  t.push(s.value);
483
483
  else
484
484
  return s;
485
- return g.success(t);
485
+ return k.success(t);
486
486
  }
487
487
  }, ce = {
488
488
  loadingExtended: "Loading, please wait",
@@ -561,15 +561,15 @@ const C = {
561
561
  }
562
562
  return n;
563
563
  }
564
- }, De = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
564
+ }, _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
565
565
  __proto__: null,
566
566
  default: ce
567
- }, Symbol.toStringTag, { value: "Module" })), Ie = ce, _e = "en", Ee = (e, t, s) => {
567
+ }, Symbol.toStringTag, { value: "Module" })), Ee = ce, Te = "en", Le = (e, t, s) => {
568
568
  const n = e[t];
569
569
  return n ? typeof n == "function" ? n() : Promise.resolve(n) : new Promise((r, a) => {
570
570
  (typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(a.bind(null, /* @__PURE__ */ new Error("Unknown variable dynamic import: " + t + (t.split("/").length !== s ? ". Note that variables only represent file names one level deep." : ""))));
571
571
  });
572
- }, Te = /* @__PURE__ */ new Set([
572
+ }, Me = /* @__PURE__ */ new Set([
573
573
  "ar",
574
574
  // Arabic
575
575
  "he",
@@ -598,21 +598,21 @@ const C = {
598
598
  function ue(e) {
599
599
  if (!e) return "ltr";
600
600
  const t = e.split(/[-_]/)[0].toLowerCase();
601
- return Te.has(t) ? "rtl" : "ltr";
601
+ return Me.has(t) ? "rtl" : "ltr";
602
602
  }
603
- function Le(e, t) {
603
+ function Pe(e, t) {
604
604
  return e === "auto" ? ue(t) : e;
605
605
  }
606
- function mt(e) {
606
+ function xt(e) {
607
607
  return `b-${e}`;
608
608
  }
609
- function vt(e) {
609
+ function St(e) {
610
610
  return ue(e) === "rtl";
611
611
  }
612
- function kt(e) {
612
+ function Dt(e) {
613
613
  return e === "ltr" ? "rtl" : "ltr";
614
614
  }
615
- const Me = {
615
+ const Ve = {
616
616
  ltr: {
617
617
  "inline-start": "left",
618
618
  "inline-end": "right",
@@ -626,10 +626,10 @@ const Me = {
626
626
  "block-end": "bottom"
627
627
  }
628
628
  };
629
- function yt(e, t) {
630
- return Me[t][e];
629
+ function It(e, t) {
630
+ return Ve[t][e];
631
631
  }
632
- const Pe = {
632
+ const Ae = {
633
633
  mark: ae("Locale"),
634
634
  create: (e) => {
635
635
  const t = X({
@@ -638,11 +638,11 @@ const Pe = {
638
638
  }), s = X({
639
639
  defaultValue: "auto",
640
640
  key: "beatui-direction-preference"
641
- }), n = k(
641
+ }), n = y(
642
642
  t,
643
643
  s
644
644
  )(
645
- (a, o) => Le(o, a)
645
+ (a, o) => Pe(o, a)
646
646
  );
647
647
  return {
648
648
  value: {
@@ -658,10 +658,10 @@ const Pe = {
658
658
  };
659
659
  }
660
660
  }, {
661
- variants: Ve,
662
- special: Ae,
661
+ variants: $e,
662
+ special: Be,
663
663
  overrides: Y
664
- } = xe;
664
+ } = De;
665
665
  function B(e, t) {
666
666
  switch (e) {
667
667
  case "white":
@@ -671,18 +671,18 @@ function B(e, t) {
671
671
  case "transparent":
672
672
  return "transparent";
673
673
  default:
674
- return Se(e, t);
674
+ return Ie(e, t);
675
675
  }
676
676
  }
677
677
  function de(e, t) {
678
- const s = Ae[e];
678
+ const s = Be[e];
679
679
  if (!s) return;
680
680
  if (t === "light")
681
681
  return s;
682
682
  const n = Y[e];
683
683
  return n ? n[t] : s;
684
684
  }
685
- function O(e, t, s) {
685
+ function j(e, t, s) {
686
686
  const n = Y[e];
687
687
  if (n) {
688
688
  const a = n[s];
@@ -697,23 +697,23 @@ function O(e, t, s) {
697
697
  textColor: a.color
698
698
  };
699
699
  }
700
- const r = Ve[t][s];
700
+ const r = $e[t][s];
701
701
  return {
702
702
  backgroundColor: B(e, r.bgShade),
703
703
  textColor: r.textColor
704
704
  };
705
705
  }
706
- const $e = {
706
+ const Oe = {
707
707
  light: { shade: 600, textColor: "var(--color-white)" },
708
708
  dark: { shade: 600, textColor: "var(--text-inverted-dark)" }
709
- }, Be = {
709
+ }, je = {
710
710
  light: { shade: 300, textColor: "var(--text-normal-light)" },
711
711
  dark: { shade: 700, textColor: "var(--text-normal-dark)" }
712
- }, Oe = {
712
+ }, Ne = {
713
713
  light: { shade: 400, textColor: "var(--text-normal-light)" },
714
714
  dark: { shade: 600, textColor: "var(--text-normal-dark)" }
715
715
  };
716
- function V(e, t, s) {
716
+ function A(e, t, s) {
717
717
  const n = Y[e];
718
718
  if (n) {
719
719
  const a = n[s];
@@ -727,13 +727,13 @@ function V(e, t, s) {
727
727
  backgroundColor: a.backgroundColor,
728
728
  textColor: a.color
729
729
  };
730
- const o = $e[s];
730
+ const o = Oe[s];
731
731
  return {
732
732
  backgroundColor: B(e, o.shade),
733
733
  textColor: o.textColor
734
734
  };
735
735
  }
736
- const r = t === "light" ? Be[s] : Oe[s];
736
+ const r = t === "light" ? je[s] : Ne[s];
737
737
  return {
738
738
  backgroundColor: B(e, r.shade),
739
739
  textColor: r.textColor
@@ -752,22 +752,22 @@ function se(e, t) {
752
752
  return B(e, s);
753
753
  }
754
754
  }
755
- function j(e, t) {
755
+ function N(e, t) {
756
756
  return e === "white" ? "var(--color-white)" : e === "black" ? "var(--color-black)" : e === "transparent" ? "inherit" : B(e, t === "light" ? 800 : 200);
757
757
  }
758
758
  function ne(e, t, s) {
759
759
  return t === "soft" ? B(e, s === "light" ? 300 : 700) : B(e, s === "light" ? 500 : 600);
760
760
  }
761
- const je = "bui-icons", U = /* @__PURE__ */ new Map(), he = (() => {
761
+ const Fe = "bui-icons", U = /* @__PURE__ */ new Map(), he = (() => {
762
762
  try {
763
763
  return typeof indexedDB < "u" && indexedDB !== null;
764
764
  } catch {
765
765
  return !1;
766
766
  }
767
767
  })();
768
- function Ne() {
768
+ function qe() {
769
769
  return he ? new Promise((e, t) => {
770
- const s = indexedDB.open(je, 1);
770
+ const s = indexedDB.open(Fe, 1);
771
771
  s.onupgradeneeded = function(n) {
772
772
  const r = n.target.result;
773
773
  r.objectStoreNames.contains("icons") || r.createObjectStore("icons");
@@ -778,8 +778,8 @@ function Ne() {
778
778
  };
779
779
  }) : Promise.reject(new Error("IndexedDB not available"));
780
780
  }
781
- const z = he ? Ne() : null;
782
- function Fe(e, t) {
781
+ const z = he ? qe() : null;
782
+ function Re(e, t) {
783
783
  return new Promise(async (s, n) => {
784
784
  try {
785
785
  if (z) {
@@ -792,7 +792,7 @@ function Fe(e, t) {
792
792
  }
793
793
  });
794
794
  }
795
- function qe(e) {
795
+ function He(e) {
796
796
  return new Promise(async (t, s) => {
797
797
  try {
798
798
  if (z) {
@@ -807,7 +807,7 @@ function qe(e) {
807
807
  }
808
808
  });
809
809
  }
810
- async function Re(e) {
810
+ async function Ue(e) {
811
811
  const t = `https://api.iconify.design/${e}.svg`;
812
812
  return fetch(t).then((s) => {
813
813
  if (s.status === 200)
@@ -815,22 +815,22 @@ async function Re(e) {
815
815
  throw new Error(`Failed to load icon: ${e}`);
816
816
  });
817
817
  }
818
- async function He(e) {
819
- const t = e.replace(":", "/"), s = await qe(t);
818
+ async function ze(e) {
819
+ const t = e.replace(":", "/"), s = await He(t);
820
820
  if (s)
821
821
  return s;
822
- const n = await Re(t);
823
- return await Fe(t, n), n;
822
+ const n = await Ue(t);
823
+ return await Re(t, n), n;
824
824
  }
825
- function Ue(e) {
825
+ function Ge(e) {
826
826
  return ["bc-icon", `bc-icon--${e}`].join(" ");
827
827
  }
828
- function ze(e, t = "solid") {
828
+ function We(e, t = "solid") {
829
829
  if (!e) return "";
830
830
  const s = ne(e, t, "light"), n = ne(e, t, "dark");
831
831
  return `--icon-color: ${s}; --icon-color-dark: ${n}`;
832
832
  }
833
- function F({
833
+ function O({
834
834
  icon: e,
835
835
  size: t = "md",
836
836
  color: s,
@@ -838,7 +838,7 @@ function F({
838
838
  accessibility: r = "auto",
839
839
  tone: a = "solid"
840
840
  }, ...o) {
841
- const i = k(
841
+ const i = y(
842
842
  r,
843
843
  n
844
844
  )((l, d) => l === "decorative" ? !1 : l === "informative" ? !0 : d != null && d !== "");
@@ -846,30 +846,30 @@ function F({
846
846
  R,
847
847
  (l) => p.span(
848
848
  c.class(
849
- k(t, s)((d) => Ue(d ?? "md"))
849
+ y(t, s)((d) => Ge(d ?? "md"))
850
850
  ),
851
851
  c.style(
852
- k(
852
+ y(
853
853
  s,
854
854
  a
855
855
  )(
856
- (d, u) => ze(d ?? void 0, u ?? "solid")
856
+ (d, u) => We(d ?? void 0, u ?? "solid")
857
857
  )
858
858
  ),
859
859
  // Add accessibility attributes based on icon type
860
- _(
860
+ E(
861
861
  i,
862
- () => E(
862
+ () => M(
863
863
  c.role("img"),
864
- x.label(Q(n, l.$.iconDescription))
864
+ S.label(Q(n, l.$.iconDescription))
865
865
  ),
866
- () => x.hidden(!0)
866
+ () => S.hidden(!0)
867
867
  ),
868
- ye(
868
+ Ce(
869
869
  { once: !0 },
870
- () => we({
870
+ () => xe({
871
871
  request: e,
872
- load: ({ request: d }) => He(d),
872
+ load: ({ request: d }) => ze(d),
873
873
  convertError: String,
874
874
  success: ({ value: d }) => p.span(
875
875
  H.width("100%"),
@@ -879,10 +879,10 @@ function F({
879
879
  pending: () => p.span(
880
880
  c.class("animate-spin"),
881
881
  // Loading state accessibility
882
- _(
882
+ E(
883
883
  i,
884
- () => E(c.role("img"), x.label(l.$.loadingIcon)),
885
- () => x.hidden(!0)
884
+ () => M(c.role("img"), S.label(l.$.loadingIcon)),
885
+ () => S.hidden(!0)
886
886
  ),
887
887
  "↻"
888
888
  ),
@@ -890,10 +890,10 @@ function F({
890
890
  c.title(d),
891
891
  c.class("text-red-500"),
892
892
  // Error state accessibility
893
- _(
893
+ E(
894
894
  i,
895
- () => E(c.role("img"), x.label(l.$.failedToLoadIcon)),
896
- () => x.hidden(!0)
895
+ () => M(c.role("img"), S.label(l.$.failedToLoadIcon)),
896
+ () => S.hidden(!0)
897
897
  ),
898
898
  "🚫"
899
899
  )
@@ -903,7 +903,7 @@ function F({
903
903
  )
904
904
  );
905
905
  }
906
- function Ge(e, t, s) {
906
+ function Ke(e, t, s) {
907
907
  const n = [
908
908
  "bc-button",
909
909
  `bc-button--size-${e}`,
@@ -912,7 +912,7 @@ function Ge(e, t, s) {
912
912
  ];
913
913
  return s && n.push("bc-button--loading"), n.join(" ");
914
914
  }
915
- function We(e, t, s) {
915
+ function Je(e, t, s) {
916
916
  const n = /* @__PURE__ */ new Map();
917
917
  n.set("--button-text-shadow", "var(--text-shadow-none)"), n.set("--button-text-shadow-dark", "var(--text-shadow-none)");
918
918
  const r = (a, o, i, l) => {
@@ -920,7 +920,7 @@ function We(e, t, s) {
920
920
  };
921
921
  switch (e) {
922
922
  case "filled": {
923
- const a = O(t, "solid", "light"), o = O(t, "solid", "dark");
923
+ const a = j(t, "solid", "light"), o = j(t, "solid", "dark");
924
924
  n.set("--button-bg", a.backgroundColor), n.set("--button-text", a.textColor), n.set("--button-bg-dark", o.backgroundColor), n.set("--button-text-dark", o.textColor), n.set(
925
925
  "--button-text-shadow",
926
926
  "var(--text-shadow-button-filled, var(--text-shadow-sm))"
@@ -928,7 +928,7 @@ function We(e, t, s) {
928
928
  "--button-text-shadow-dark",
929
929
  "var(--text-shadow-button-filled, var(--text-shadow-sm))"
930
930
  );
931
- const i = V(t, "solid", "light"), l = V(t, "solid", "dark");
931
+ const i = A(t, "solid", "light"), l = A(t, "solid", "dark");
932
932
  r(
933
933
  i.backgroundColor,
934
934
  l.backgroundColor,
@@ -938,9 +938,9 @@ function We(e, t, s) {
938
938
  break;
939
939
  }
940
940
  case "light": {
941
- const a = O(t, "light", "light"), o = O(t, "light", "dark");
941
+ const a = j(t, "light", "light"), o = j(t, "light", "dark");
942
942
  n.set("--button-bg", a.backgroundColor), n.set("--button-text", a.textColor), n.set("--button-bg-dark", o.backgroundColor), n.set("--button-text-dark", o.textColor);
943
- const i = V(t, "light", "light"), l = V(t, "light", "dark");
943
+ const i = A(t, "light", "light"), l = A(t, "light", "dark");
944
944
  r(
945
945
  i.backgroundColor,
946
946
  l.backgroundColor,
@@ -950,14 +950,14 @@ function We(e, t, s) {
950
950
  break;
951
951
  }
952
952
  case "outline": {
953
- n.set("--button-bg", "transparent"), n.set("--button-bg-dark", "transparent"), n.set("--button-border", se(t, "light")), n.set("--button-border-dark", se(t, "dark")), n.set("--button-text", j(t, "light")), n.set("--button-text-dark", j(t, "dark")), n.set(
953
+ n.set("--button-bg", "transparent"), n.set("--button-bg-dark", "transparent"), n.set("--button-border", se(t, "light")), n.set("--button-border-dark", se(t, "dark")), n.set("--button-text", N(t, "light")), n.set("--button-text-dark", N(t, "dark")), n.set(
954
954
  "--button-text-shadow",
955
955
  "var(--text-shadow-button-light, var(--text-shadow-xs))"
956
956
  ), n.set(
957
957
  "--button-text-shadow-dark",
958
958
  "var(--text-shadow-button-light, var(--text-shadow-xs))"
959
959
  );
960
- const a = V(t, "light", "light"), o = V(t, "light", "dark");
960
+ const a = A(t, "light", "light"), o = A(t, "light", "dark");
961
961
  r(
962
962
  a.backgroundColor,
963
963
  o.backgroundColor,
@@ -967,15 +967,15 @@ function We(e, t, s) {
967
967
  break;
968
968
  }
969
969
  case "default": {
970
- const a = O("neutral", "light", "light"), o = O("neutral", "light", "dark");
971
- n.set("--button-bg", a.backgroundColor), n.set("--button-text", j(t, "light")), n.set("--button-bg-dark", o.backgroundColor), n.set("--button-text-dark", j(t, "dark")), n.set(
970
+ const a = j("neutral", "light", "light"), o = j("neutral", "light", "dark");
971
+ n.set("--button-bg", a.backgroundColor), n.set("--button-text", N(t, "light")), n.set("--button-bg-dark", o.backgroundColor), n.set("--button-text-dark", N(t, "dark")), n.set(
972
972
  "--button-text-shadow",
973
973
  "var(--text-shadow-button-default, var(--text-shadow-2xs))"
974
974
  ), n.set(
975
975
  "--button-text-shadow-dark",
976
976
  "var(--text-shadow-button-default, var(--text-shadow-2xs))"
977
977
  );
978
- const i = V("base", "light", "light"), l = V("base", "light", "dark");
978
+ const i = A("base", "light", "light"), l = A("base", "light", "dark");
979
979
  r(
980
980
  i.backgroundColor,
981
981
  l.backgroundColor,
@@ -985,13 +985,13 @@ function We(e, t, s) {
985
985
  break;
986
986
  }
987
987
  case "text": {
988
- n.set("--button-bg", "transparent"), n.set("--button-bg-dark", "transparent"), n.set("--button-text", j(t, "light")), n.set("--button-text-dark", j(t, "dark")), s || n.set("--button-hover-decoration", "underline");
988
+ n.set("--button-bg", "transparent"), n.set("--button-bg-dark", "transparent"), n.set("--button-text", N(t, "light")), n.set("--button-text-dark", N(t, "dark")), s || n.set("--button-hover-decoration", "underline");
989
989
  break;
990
990
  }
991
991
  }
992
992
  return Array.from(n.entries()).map(([a, o]) => `${a}: ${o}`).join("; ");
993
993
  }
994
- function Ke({
994
+ function Qe({
995
995
  type: e = "button",
996
996
  disabled: t,
997
997
  loading: s,
@@ -1008,61 +1008,61 @@ function Ke({
1008
1008
  (u) => p.button(
1009
1009
  c.type(e),
1010
1010
  c.disabled(
1011
- k(
1011
+ y(
1012
1012
  t,
1013
1013
  s
1014
- )((h, b) => h || b)
1014
+ )((h, g) => h || g)
1015
1015
  ),
1016
1016
  // Add ARIA attributes for accessibility
1017
- x.busy(s ?? !1),
1018
- _(s ?? !1, () => x.label(u.$.loadingExtended)),
1017
+ S.busy(s ?? !1),
1018
+ E(s ?? !1, () => S.label(u.$.loadingExtended)),
1019
1019
  c.class(
1020
- k(
1020
+ y(
1021
1021
  r,
1022
1022
  o,
1023
1023
  s
1024
1024
  )(
1025
- (h, b, m) => Ge(h ?? "md", b ?? "sm", m)
1025
+ (h, g, v) => Ke(h ?? "md", g ?? "sm", v)
1026
1026
  )
1027
1027
  ),
1028
1028
  c.style(
1029
- k(
1029
+ y(
1030
1030
  n,
1031
1031
  a,
1032
1032
  t
1033
1033
  )(
1034
- (h, b, m) => We(
1034
+ (h, g, v) => Je(
1035
1035
  h ?? "filled",
1036
- b ?? "base",
1037
- m
1036
+ g ?? "base",
1037
+ v
1038
1038
  )
1039
1039
  )
1040
1040
  ),
1041
- _(
1041
+ E(
1042
1042
  s ?? !1,
1043
- () => E(
1043
+ () => M(
1044
1044
  H.width(
1045
1045
  d.map((h) => h == null ? "" : `${h.width}px`)
1046
1046
  ),
1047
1047
  H.height(
1048
1048
  d.map((h) => h == null ? "" : `${h.height}px`)
1049
1049
  ),
1050
- F({ icon: "line-md:loading-twotone-loop", size: r ?? "md" }),
1050
+ O({ icon: "line-md:loading-twotone-loop", size: r ?? "md" }),
1051
1051
  // Hidden live region for screen reader announcements
1052
1052
  p.span(
1053
1053
  c.class("sr-only"),
1054
- x.live("polite"),
1054
+ S.live("polite"),
1055
1055
  u.$.loadingExtended
1056
1056
  )
1057
1057
  ),
1058
- () => E(w.click(i), ...l)
1058
+ () => M(C.click(i), ...l)
1059
1059
  ),
1060
- _(
1060
+ E(
1061
1061
  s != null,
1062
- () => Ce(
1062
+ () => Se(
1063
1063
  (h) => oe(
1064
- h.on((b) => {
1065
- L.get(s ?? !1) || d.set(b);
1064
+ h.on((g) => {
1065
+ D.get(s ?? !1) || d.set(g);
1066
1066
  })
1067
1067
  )
1068
1068
  )
@@ -1070,7 +1070,7 @@ function Ke({
1070
1070
  )
1071
1071
  );
1072
1072
  }
1073
- function wt({
1073
+ function Ye({
1074
1074
  size: e = "sm",
1075
1075
  icon: t = "line-md:close",
1076
1076
  disabled: s,
@@ -1081,7 +1081,7 @@ function wt({
1081
1081
  }, ...i) {
1082
1082
  return q(R, (l) => {
1083
1083
  const d = Q(o, l.$.closeModal);
1084
- return Ke(
1084
+ return Qe(
1085
1085
  {
1086
1086
  variant: "text",
1087
1087
  size: e,
@@ -1091,13 +1091,13 @@ function wt({
1091
1091
  onClick: a
1092
1092
  },
1093
1093
  c.title(d),
1094
- x.label(d),
1094
+ S.label(d),
1095
1095
  ...i,
1096
- F({ icon: t, size: e ?? "sm" })
1096
+ O({ icon: t, size: e ?? "sm" })
1097
1097
  );
1098
1098
  });
1099
1099
  }
1100
- function Je(e, t, s) {
1100
+ function Ze(e, t, s) {
1101
1101
  const n = [
1102
1102
  e ? "bc-base-input-container" : "bc-input-container"
1103
1103
  ];
@@ -1117,7 +1117,7 @@ const W = ({
1117
1117
  focusableSelector: o = "input, select, textarea",
1118
1118
  growInput: i = !0
1119
1119
  }, ...l) => {
1120
- const d = L.map(t ?? !1, (u) => u);
1120
+ const d = D.map(t ?? !1, (u) => u);
1121
1121
  return p.div(
1122
1122
  ve((u) => {
1123
1123
  const h = () => {
@@ -1126,15 +1126,15 @@ const W = ({
1126
1126
  return u.addEventListener("click", h), oe(() => u.removeEventListener("click", h));
1127
1127
  }),
1128
1128
  c.class(
1129
- k(
1129
+ y(
1130
1130
  e,
1131
1131
  d,
1132
1132
  a ?? !1
1133
1133
  )(
1134
- (u, h, b) => Je(
1134
+ (u, h, g) => Ze(
1135
1135
  u ?? !1,
1136
1136
  h ?? !1,
1137
- b ?? !1
1137
+ g ?? !1
1138
1138
  )
1139
1139
  )
1140
1140
  ),
@@ -1142,7 +1142,7 @@ const W = ({
1142
1142
  p.div(
1143
1143
  c.class("bc-input-container__input"),
1144
1144
  c.class(
1145
- L.map(
1145
+ D.map(
1146
1146
  i,
1147
1147
  (u) => u ? "bc-input-container__input--grow" : ""
1148
1148
  )
@@ -1156,7 +1156,7 @@ const W = ({
1156
1156
  function K(e) {
1157
1157
  return `bc-label bc-label--${e}`;
1158
1158
  }
1159
- const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span(c.class(K("default")), ...e), Ye = (...e) => p.span(c.class(K("muted")), ...e), xt = (...e) => p.span(c.class(K("danger")), ...e), St = (e) => {
1159
+ const _t = (...e) => p.span(c.class(K("emphasis")), ...e), Xe = (...e) => p.span(c.class(K("default")), ...e), et = (...e) => p.span(c.class(K("muted")), ...e), Et = (...e) => p.span(c.class(K("danger")), ...e), Tt = (e) => {
1160
1160
  const {
1161
1161
  value: t,
1162
1162
  onBlur: s,
@@ -1167,12 +1167,12 @@ const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span
1167
1167
  checkedIcon: i,
1168
1168
  uncheckedIcon: l,
1169
1169
  iconSize: d = "lg"
1170
- } = e, u = o ?? le("checkbox"), h = `${u}-label`, b = () => {
1171
- if (L.get(a ?? !1)) return;
1172
- const f = L.get(t);
1170
+ } = e, u = o ?? le("checkbox"), h = `${u}-label`, g = () => {
1171
+ if (D.get(a ?? !1)) return;
1172
+ const f = D.get(t);
1173
1173
  n?.(!f);
1174
- }, m = (f) => {
1175
- L.get(a ?? !1) || (f.key === " " || f.key === "Enter") && (f.preventDefault(), b());
1174
+ }, v = (f) => {
1175
+ D.get(a ?? !1) || (f.key === " " || f.key === "Enter") && (f.preventDefault(), g());
1176
1176
  };
1177
1177
  return W(
1178
1178
  {
@@ -1184,13 +1184,13 @@ const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span
1184
1184
  p.span(
1185
1185
  c.class("bc-checkbox-input__checkbox"),
1186
1186
  c.class(
1187
- L.map(
1187
+ D.map(
1188
1188
  t,
1189
1189
  (f) => f ? "bc-checkbox-input__checkbox--checked" : "bc-checkbox-input__checkbox--unchecked"
1190
1190
  )
1191
1191
  ),
1192
1192
  c.class(
1193
- L.map(
1193
+ D.map(
1194
1194
  a ?? !1,
1195
1195
  (f) => f ? "bc-checkbox-input__checkbox--disabled" : ""
1196
1196
  )
@@ -1198,23 +1198,23 @@ const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span
1198
1198
  c.id(u),
1199
1199
  c.role("checkbox"),
1200
1200
  c.tabindex(
1201
- L.map(
1201
+ D.map(
1202
1202
  a ?? !1,
1203
1203
  (f) => f ? -1 : 0
1204
1204
  )
1205
1205
  ),
1206
- x.checked(t),
1207
- x.disabled(a),
1208
- r != null ? x.labelledby(h) : y,
1209
- w.keydown(m),
1210
- s != null ? w.blur(s) : y,
1211
- F({
1212
- icon: k(
1206
+ S.checked(t),
1207
+ S.disabled(a),
1208
+ r != null ? S.labelledby(h) : w,
1209
+ C.keydown(v),
1210
+ s != null ? C.blur(s) : w,
1211
+ O({
1212
+ icon: y(
1213
1213
  t,
1214
1214
  i,
1215
1215
  l
1216
1216
  )(
1217
- (f, v, S) => f ? v ?? "akar-icons/check-box-fill" : S ?? "akar-icons/box"
1217
+ (f, b, m) => f ? b ?? "akar-icons/check-box-fill" : m ?? "akar-icons/box"
1218
1218
  ),
1219
1219
  accessibility: "decorative",
1220
1220
  size: d
@@ -1224,11 +1224,11 @@ const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span
1224
1224
  c.class("bc-checkbox-input__label"),
1225
1225
  c.id(h),
1226
1226
  c.for(u),
1227
- Ye(r)
1228
- ) : y
1227
+ et(r)
1228
+ ) : w
1229
1229
  )
1230
1230
  },
1231
- w.click(b)
1231
+ C.click(g)
1232
1232
  );
1233
1233
  }, Z = ({
1234
1234
  autocomplete: e,
@@ -1240,7 +1240,7 @@ const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span
1240
1240
  id: o,
1241
1241
  required: i,
1242
1242
  hasError: l
1243
- }) => E(
1243
+ }) => M(
1244
1244
  c.autocomplete(e),
1245
1245
  c.autofocus(t),
1246
1246
  c.class(s),
@@ -1248,19 +1248,19 @@ const Ct = (...e) => p.span(c.class(K("emphasis")), ...e), Qe = (...e) => p.span
1248
1248
  c.name(r ?? o),
1249
1249
  c.placeholder(a),
1250
1250
  c.id(o),
1251
- x.required(i),
1252
- l != null ? x.invalid(
1251
+ S.required(i),
1252
+ l != null ? S.invalid(
1253
1253
  l ?? !1
1254
1254
  ) : null
1255
- ), Ze = p.span(
1255
+ ), tt = p.span(
1256
1256
  c.class("bc-input-wrapper__required"),
1257
1257
  " *"
1258
1258
  );
1259
- function Xe(e) {
1259
+ function st(e) {
1260
1260
  const t = ["bc-input-wrapper"];
1261
1261
  return e && t.push("bc-input-wrapper--horizontal"), t.join(" ");
1262
1262
  }
1263
- function et(e, t) {
1263
+ function nt(e, t) {
1264
1264
  const s = ["bc-input-wrapper__label-text"];
1265
1265
  return e ? s.push("bc-input-wrapper__label-text--error") : t ? s.push("bc-input-wrapper__label-text--disabled") : s.push("bc-input-wrapper__label-text--default"), s.join(" ");
1266
1266
  }
@@ -1277,10 +1277,10 @@ const pe = ({
1277
1277
  disabled: d,
1278
1278
  horizontal: u
1279
1279
  }, ...h) => {
1280
- const b = l ?? o != null, m = d ?? !1, f = u ?? !1, v = le("input-wrapper"), S = r ? `${v}-description` : void 0, P = o != null ? `${v}-error` : void 0;
1280
+ const g = l ?? o != null, v = d ?? !1, f = u ?? !1, b = le("input-wrapper"), m = r ? `${b}-description` : void 0, T = o != null ? `${b}-error` : void 0;
1281
1281
  return p.div(
1282
1282
  c.class(
1283
- L.map(f, (T) => Xe(T))
1283
+ D.map(f, (L) => st(L))
1284
1284
  ),
1285
1285
  t != null || n != null ? p.div(
1286
1286
  c.class("bc-input-wrapper__header"),
@@ -1288,69 +1288,69 @@ const pe = ({
1288
1288
  c.class("bc-input-wrapper__label-section"),
1289
1289
  p.label(
1290
1290
  c.class("bc-input-wrapper__label"),
1291
- i != null ? c.for(i) : y,
1291
+ i != null ? c.for(i) : w,
1292
1292
  p.span(
1293
1293
  c.class(
1294
- k(
1295
- b,
1296
- m
1294
+ y(
1295
+ g,
1296
+ v
1297
1297
  )(
1298
- (T, $) => et(
1299
- T ?? !1,
1300
- $ ?? !1
1298
+ (L, V) => nt(
1299
+ L ?? !1,
1300
+ V ?? !1
1301
1301
  )
1302
1302
  )
1303
1303
  ),
1304
1304
  t
1305
1305
  ),
1306
- t != null && e ? Ze : y
1306
+ t != null && e ? tt : w
1307
1307
  ),
1308
1308
  // Show description under label when horizontal
1309
- _(
1310
- k(
1309
+ E(
1310
+ y(
1311
1311
  f,
1312
1312
  r
1313
- )((T, $) => T && $ != null),
1313
+ )((L, V) => L && V != null),
1314
1314
  () => p.div(
1315
1315
  c.class(
1316
1316
  "bc-input-wrapper__description bc-input-wrapper__description--under-label"
1317
1317
  ),
1318
- c.id(S),
1318
+ c.id(m),
1319
1319
  r
1320
1320
  )
1321
1321
  )
1322
1322
  ),
1323
- n != null ? Qe(n) : y,
1323
+ n != null ? Xe(n) : w,
1324
1324
  s
1325
- ) : y,
1325
+ ) : w,
1326
1326
  p.div(
1327
1327
  c.class("bc-input-wrapper__content"),
1328
1328
  // Add data attributes to help inputs inherit accessibility information
1329
- [S, P].filter(Boolean).length > 0 ? J.describedby(
1330
- [S, P].filter(Boolean).join(" ")
1331
- ) : y,
1332
- e ? J.required("true") : y,
1333
- _(b, () => J.invalid("true")),
1329
+ [m, T].filter(Boolean).length > 0 ? J.describedby(
1330
+ [m, T].filter(Boolean).join(" ")
1331
+ ) : w,
1332
+ e ? J.required("true") : w,
1333
+ E(g, () => J.invalid("true")),
1334
1334
  a
1335
1335
  ),
1336
1336
  // Show description at bottom only when not horizontal
1337
- _(
1338
- k(
1337
+ E(
1338
+ y(
1339
1339
  f,
1340
1340
  r
1341
- )((T, $) => !T && $ != null),
1341
+ )((L, V) => !L && V != null),
1342
1342
  () => p.div(
1343
1343
  c.class("bc-input-wrapper__description"),
1344
- c.id(S),
1344
+ c.id(m),
1345
1345
  r
1346
1346
  )
1347
1347
  ),
1348
- o != null ? _(
1349
- b,
1348
+ o != null ? E(
1349
+ g,
1350
1350
  () => p.div(
1351
1351
  c.class("bc-input-wrapper__error"),
1352
- c.id(P),
1353
- x.live("polite"),
1352
+ c.id(T),
1353
+ S.live("polite"),
1354
1354
  // Announce errors to screen readers
1355
1355
  c.role("alert"),
1356
1356
  // Mark as alert for immediate attention
@@ -1360,10 +1360,10 @@ const pe = ({
1360
1360
  ...h
1361
1361
  );
1362
1362
  };
1363
- function Dt(...e) {
1363
+ function Lt(...e) {
1364
1364
  return p.div(c.class("bc-stack"), ...e);
1365
1365
  }
1366
- const It = (e) => {
1366
+ const Mt = (e) => {
1367
1367
  const t = {
1368
1368
  name: "email",
1369
1369
  autocomplete: "email",
@@ -1375,7 +1375,7 @@ const It = (e) => {
1375
1375
  onChange: a,
1376
1376
  onInput: o,
1377
1377
  placeholder: i
1378
- } = t, l = n ?? F({
1378
+ } = t, l = n ?? O({
1379
1379
  icon: "line-md:email",
1380
1380
  size: "sm",
1381
1381
  color: "neutral"
@@ -1390,13 +1390,13 @@ const It = (e) => {
1390
1390
  c.placeholder(Q(i, d.$.emailPlaceholderText)),
1391
1391
  c.value(s),
1392
1392
  c.class("bc-input"),
1393
- r != null ? w.blur(M(r)) : y,
1394
- a != null ? w.change(M(a)) : y,
1395
- o != null ? w.input(M(o)) : y
1393
+ r != null ? C.blur(P(r)) : w,
1394
+ a != null ? C.change(P(a)) : w,
1395
+ o != null ? C.input(P(o)) : w
1396
1396
  )
1397
1397
  })
1398
1398
  );
1399
- }, _t = (e) => {
1399
+ }, Pt = (e) => {
1400
1400
  const { value: t, onBlur: s, onChange: n, onInput: r } = e;
1401
1401
  return W({
1402
1402
  ...e,
@@ -1404,12 +1404,12 @@ const It = (e) => {
1404
1404
  Z(e),
1405
1405
  c.value(t),
1406
1406
  c.class("bc-input"),
1407
- s != null ? w.blur(M(s)) : y,
1408
- n != null ? w.change(M(n)) : y,
1409
- r != null ? w.input(M(r)) : y
1407
+ s != null ? C.blur(P(s)) : w,
1408
+ n != null ? C.change(P(n)) : w,
1409
+ r != null ? C.input(P(r)) : w
1410
1410
  )
1411
1411
  });
1412
- }, Et = (e) => {
1412
+ }, Vt = (e) => {
1413
1413
  const {
1414
1414
  value: t,
1415
1415
  onBlur: s,
@@ -1422,27 +1422,27 @@ const It = (e) => {
1422
1422
  autocomplete: d,
1423
1423
  placeholder: u,
1424
1424
  ...h
1425
- } = e, b = {
1425
+ } = e, g = {
1426
1426
  name: "password",
1427
1427
  disabled: l,
1428
1428
  ...h
1429
- }, m = I(!0), f = k(
1430
- m,
1429
+ }, v = I(!0), f = y(
1430
+ v,
1431
1431
  d
1432
- )((v, S) => v ? S ?? "current-password" : "off");
1433
- return q(R, (v) => {
1434
- const S = k(
1435
- v.$.passwordPlaceholderText,
1436
- m,
1432
+ )((b, m) => b ? m ?? "current-password" : "off");
1433
+ return q(R, (b) => {
1434
+ const m = y(
1435
+ b.$.passwordPlaceholderText,
1436
+ v,
1437
1437
  u
1438
- )((T, $, me) => $ ? "•••••••••••••••" : me ?? T), P = p.button(
1438
+ )((L, V, me) => V ? "•••••••••••••••" : me ?? L), T = p.button(
1439
1439
  c.class("bc-input-container__password-toggle"),
1440
- x.label(v.$.togglePasswordVisibility),
1441
- w.click(() => m.update((T) => !T)),
1442
- _(
1443
- m,
1444
- () => F({ icon: "line-md:watch" }),
1445
- () => F({ icon: "line-md:watch-off" })
1440
+ S.label(b.$.togglePasswordVisibility),
1441
+ C.click(() => v.update((L) => !L)),
1442
+ E(
1443
+ v,
1444
+ () => O({ icon: "line-md:watch" }),
1445
+ () => O({ icon: "line-md:watch-off" })
1446
1446
  )
1447
1447
  );
1448
1448
  return W({
@@ -1451,30 +1451,30 @@ const It = (e) => {
1451
1451
  hasError: i,
1452
1452
  input: p.input(
1453
1453
  Z({
1454
- ...b,
1454
+ ...g,
1455
1455
  autocomplete: f,
1456
- placeholder: S
1456
+ placeholder: m
1457
1457
  }),
1458
- _(
1459
- m,
1460
- () => E(c.type("password")),
1461
- () => E(c.type("text"))
1458
+ E(
1459
+ v,
1460
+ () => M(c.type("password")),
1461
+ () => M(c.type("text"))
1462
1462
  ),
1463
1463
  c.class("bc-input"),
1464
1464
  c.value(t),
1465
- s != null ? w.blur(M(s)) : y,
1466
- n != null ? w.change(M(n)) : y,
1467
- r != null ? w.input(M(r)) : y
1465
+ s != null ? C.blur(P(s)) : w,
1466
+ n != null ? C.change(P(n)) : w,
1467
+ r != null ? C.input(P(r)) : w
1468
1468
  ),
1469
- after: o != null ? E(P, o) : P
1469
+ after: o != null ? M(T, o) : T
1470
1470
  });
1471
1471
  });
1472
- }, tt = (
1472
+ }, rt = (
1473
1473
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1474
1474
  (e, t) => () => {
1475
1475
  e.markTouched(), t?.();
1476
1476
  }
1477
- ), st = (e, t) => (s) => {
1477
+ ), at = (e, t) => (s) => {
1478
1478
  e.change(s), t?.(s);
1479
1479
  };
1480
1480
  function fe(e, t) {
@@ -1485,11 +1485,11 @@ function fe(e, t) {
1485
1485
  value: s.value,
1486
1486
  hasError: s.errorVisible,
1487
1487
  ...a,
1488
- onChange: st(s, r),
1489
- onBlur: tt(s, n)
1488
+ onChange: at(s, r),
1489
+ onBlur: rt(s, n)
1490
1490
  });
1491
1491
  }
1492
- function Tt(e, t, ...s) {
1492
+ function At(e, t, ...s) {
1493
1493
  return pe(
1494
1494
  {
1495
1495
  ...t,
@@ -1501,37 +1501,37 @@ function Tt(e, t, ...s) {
1501
1501
  ...s
1502
1502
  );
1503
1503
  }
1504
- function nt(e, t) {
1504
+ function ot(e, t) {
1505
1505
  const { toInput: s, fromInput: n, controller: r, ...a } = t, o = r.transform(s, n);
1506
1506
  return fe(e, {
1507
1507
  ...a,
1508
1508
  controller: o
1509
1509
  });
1510
1510
  }
1511
- function Lt(e, t, ...s) {
1511
+ function $t(e, t, ...s) {
1512
1512
  return pe(
1513
1513
  {
1514
1514
  ...t,
1515
- content: nt(e, t)
1515
+ content: ot(e, t)
1516
1516
  },
1517
1517
  ...s
1518
1518
  );
1519
1519
  }
1520
- function Mt(e) {
1520
+ function Bt(e) {
1521
1521
  return e.split(".").map((s) => {
1522
1522
  const n = s.match(/^\[(\d+)\]$/);
1523
1523
  return n ? Number(n[1]) : s;
1524
1524
  });
1525
1525
  }
1526
- function rt(e) {
1526
+ function it(e) {
1527
1527
  return typeof e == "number" ? `[${e}]` : `.${e}`;
1528
1528
  }
1529
- function at(e) {
1529
+ function lt(e) {
1530
1530
  if (e.length === 0) return "";
1531
1531
  const [t, ...s] = e;
1532
1532
  return [
1533
1533
  typeof t == "number" ? `[${t}]` : t,
1534
- ...s.map(rt)
1534
+ ...s.map(it)
1535
1535
  ].join("");
1536
1536
  }
1537
1537
  function G(e) {
@@ -1539,11 +1539,11 @@ function G(e) {
1539
1539
  if (s.type === "valid") return s;
1540
1540
  let n = s.error;
1541
1541
  for (const r of e)
1542
- if (n = n?.dependencies?.[r], n == null) return D.valid;
1543
- return D.invalid(n);
1542
+ if (n = n?.dependencies?.[r], n == null) return _.valid;
1543
+ return _.invalid(n);
1544
1544
  };
1545
1545
  }
1546
- class A {
1546
+ class $ {
1547
1547
  path;
1548
1548
  change;
1549
1549
  value;
@@ -1564,25 +1564,25 @@ class A {
1564
1564
  disabled;
1565
1565
  #n = [];
1566
1566
  disabledOrHasErrors;
1567
- constructor(t, s, n, r, a, o = N) {
1567
+ constructor(t, s, n, r, a, o = F) {
1568
1568
  this.path = t, this.change = s, this.value = n, this.status = r, this.#s = o, this.#t.set(n.value), this.error = r.map(
1569
1569
  (i) => i?.type === "invalid" ? i.error?.message : void 0
1570
- ), this.hasError = this.error.map((i) => i != null), this.touched = this.#e.touched, a.validationMode ? this.errorVisible = k(
1570
+ ), this.hasError = this.error.map((i) => i != null), this.touched = this.#e.touched, a.validationMode ? this.errorVisible = y(
1571
1571
  this.hasError,
1572
1572
  this.touched,
1573
1573
  a.validationMode
1574
- )((i, l, d) => d === "continuous" ? !!i : !!i && !!l) : this.errorVisible = k(
1574
+ )((i, l, d) => d === "continuous" ? !!i : !!i && !!l) : this.errorVisible = y(
1575
1575
  this.hasError,
1576
1576
  this.touched
1577
- )((i, l) => !!i && !!l), this.dirty = k(
1577
+ )((i, l) => !!i && !!l), this.dirty = y(
1578
1578
  this.value,
1579
1579
  this.#t
1580
1580
  )((i, l) => !this.#s(i, l)), this.dependencyErrors = r.map(
1581
1581
  (i) => i?.type === "invalid" ? i.error?.dependencies : void 0
1582
- ), this.parent = a, this.disabled = k(
1582
+ ), this.parent = a, this.disabled = y(
1583
1583
  this.#e.disabled,
1584
1584
  a.disabled
1585
- )((i, l) => i || l), this.disabledOrHasErrors = k(
1585
+ )((i, l) => i || l), this.disabledOrHasErrors = y(
1586
1586
  this.disabled,
1587
1587
  this.hasError
1588
1588
  )((i, l) => i || l), this.onDispose(() => {
@@ -1590,7 +1590,7 @@ class A {
1590
1590
  });
1591
1591
  }
1592
1592
  get name() {
1593
- return at(this.path);
1593
+ return lt(this.path);
1594
1594
  }
1595
1595
  onDispose = (t) => {
1596
1596
  this.#n.push(t);
@@ -1621,7 +1621,7 @@ class A {
1621
1621
  reset = () => {
1622
1622
  this.change(this.#t.value);
1623
1623
  };
1624
- array = (t = N) => new it(
1624
+ array = (t = F) => new ut(
1625
1625
  this.path,
1626
1626
  this.change,
1627
1627
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -1630,7 +1630,7 @@ class A {
1630
1630
  this.parent,
1631
1631
  t
1632
1632
  );
1633
- object = (t = N) => new ot(
1633
+ object = (t = F) => new ct(
1634
1634
  this.path,
1635
1635
  this.change,
1636
1636
  this.value,
@@ -1638,7 +1638,7 @@ class A {
1638
1638
  this.parent,
1639
1639
  t
1640
1640
  );
1641
- transform = (t, s, n = [], r = N) => new A(
1641
+ transform = (t, s, n = [], r = F) => new $(
1642
1642
  [...this.path, ...n],
1643
1643
  (a) => this.change(s(a)),
1644
1644
  this.value.map(t, r),
@@ -1646,7 +1646,7 @@ class A {
1646
1646
  this.parent,
1647
1647
  r
1648
1648
  );
1649
- asyncTransform = (t, s, n, r = [], a = N) => new A(
1649
+ asyncTransform = (t, s, n, r = [], a = F) => new $(
1650
1650
  [...this.path, ...r],
1651
1651
  (o) => {
1652
1652
  s(o).then((i) => this.change(i));
@@ -1657,7 +1657,7 @@ class A {
1657
1657
  a
1658
1658
  );
1659
1659
  }
1660
- class ot extends A {
1660
+ class ct extends $ {
1661
1661
  #e = /* @__PURE__ */ new Map();
1662
1662
  #s = /* @__PURE__ */ new Map();
1663
1663
  #t = /* @__PURE__ */ new Map();
@@ -1710,7 +1710,7 @@ class ot extends A {
1710
1710
  ...this.value.value,
1711
1711
  [t]: o
1712
1712
  });
1713
- }, n = new A(
1713
+ }, n = new $(
1714
1714
  [...this.path, t],
1715
1715
  s,
1716
1716
  this.value.map((o) => o[t]),
@@ -1757,7 +1757,7 @@ class ot extends A {
1757
1757
  this.#i.set(this.dirty.value || t);
1758
1758
  };
1759
1759
  }
1760
- class it extends A {
1760
+ class ut extends $ {
1761
1761
  #e = new Array();
1762
1762
  length;
1763
1763
  #s = /* @__PURE__ */ new Map();
@@ -1784,9 +1784,9 @@ class it extends A {
1784
1784
  super(t, s, i, r, a, o);
1785
1785
  const l = i.on((u) => {
1786
1786
  const h = this.#e.length - u.length;
1787
- h > 0 && (this.#e.splice(u.length, h).forEach((b, m) => {
1788
- const f = u.length + m;
1789
- b.dispose(), this.#t.get(f)?.(), this.#t.delete(f), this.#s.delete(f), this.#r.get(f)?.(), this.#r.delete(f), this.#a.delete(f);
1787
+ h > 0 && (this.#e.splice(u.length, h).forEach((g, v) => {
1788
+ const f = u.length + v;
1789
+ g.dispose(), this.#t.get(f)?.(), this.#t.delete(f), this.#s.delete(f), this.#r.get(f)?.(), this.#r.delete(f), this.#a.delete(f);
1790
1790
  }), this.#l(), this.#o());
1791
1791
  });
1792
1792
  this.length = i.map((u) => u.length), this.#c = this.touched.on(() => {
@@ -1811,7 +1811,7 @@ class it extends A {
1811
1811
  const s = async (o) => {
1812
1812
  const i = this.value.value.slice();
1813
1813
  i[t] = o, this.change(i);
1814
- }, n = new A(
1814
+ }, n = new $(
1815
1815
  [...this.path, t],
1816
1816
  s,
1817
1817
  this.value.map((o) => o[t]),
@@ -1877,7 +1877,7 @@ class it extends A {
1877
1877
  this.#i.set(this.dirty.value || t);
1878
1878
  };
1879
1879
  }
1880
- function lt(e) {
1880
+ function dt(e) {
1881
1881
  function t(s) {
1882
1882
  return typeof s == "number" ? s : s.toString();
1883
1883
  }
@@ -1885,9 +1885,9 @@ function lt(e) {
1885
1885
  (s) => typeof s == "object" && s.key != null ? t(s.key) : t(s)
1886
1886
  );
1887
1887
  }
1888
- function ct(e) {
1888
+ function ht(e) {
1889
1889
  const t = e.filter((r) => r.path == null || r.path.length === 0).map((r) => r.message), s = e.filter((r) => r.path != null && r.path.length > 0).reduce((r, a) => {
1890
- const o = lt(a.path), i = o.pop();
1890
+ const o = dt(a.path), i = o.pop();
1891
1891
  let l = r;
1892
1892
  for (const d of o)
1893
1893
  l.dependencies == null && (l.dependencies = {}), l.dependencies[d] == null && (l.dependencies[d] = {}), l = l.dependencies[d];
@@ -1899,7 +1899,7 @@ function ct(e) {
1899
1899
  message: n != "" ? n : void 0
1900
1900
  };
1901
1901
  }
1902
- function ut({
1902
+ function pt({
1903
1903
  initialValue: e,
1904
1904
  onChange: t,
1905
1905
  validate: s,
@@ -1907,68 +1907,68 @@ function ut({
1907
1907
  validationMode: r,
1908
1908
  validateDebounceMs: a
1909
1909
  }) {
1910
- const o = L.deriveProp(e), i = I(D.valid), l = I(!1), d = I(r ?? "touchedOrSubmit"), u = (v) => {
1911
- i.set(v);
1910
+ const o = D.deriveProp(e), i = I(_.valid), l = I(!1), d = I(r ?? "touchedOrSubmit"), u = (b) => {
1911
+ i.set(b);
1912
1912
  };
1913
1913
  let h;
1914
- const b = async (v) => {
1914
+ const g = async (b) => {
1915
1915
  if (s != null) {
1916
- const S = await s(v);
1917
- u(S);
1916
+ const m = await s(b);
1917
+ u(m);
1918
1918
  }
1919
- }, m = async (v) => {
1920
- o.set(v), t?.(v);
1921
- const S = d.value;
1919
+ }, v = async (b) => {
1920
+ o.set(b), t?.(b);
1921
+ const m = d.value;
1922
1922
  if (s != null) {
1923
- if (S === "onSubmit")
1923
+ if (m === "onSubmit")
1924
1924
  return;
1925
- const P = a ?? 0;
1926
- P > 0 ? (h && clearTimeout(h), h = setTimeout(() => {
1927
- b(v);
1928
- }, P)) : await b(v);
1925
+ const T = a ?? 0;
1926
+ T > 0 ? (h && clearTimeout(h), h = setTimeout(() => {
1927
+ g(b);
1928
+ }, T)) : await g(b);
1929
1929
  }
1930
- }, f = new A(
1930
+ }, f = new $(
1931
1931
  [],
1932
- m,
1932
+ v,
1933
1933
  o,
1934
1934
  i,
1935
1935
  {
1936
1936
  disabled: l,
1937
1937
  validationMode: d
1938
1938
  },
1939
- n ?? N
1939
+ n ?? F
1940
1940
  );
1941
1941
  return f.onDispose(() => {
1942
1942
  l.dispose(), o.dispose(), i.dispose(), d.dispose(), h && clearTimeout(h);
1943
1943
  }), { controller: f, setStatus: u };
1944
1944
  }
1945
1945
  function be(e) {
1946
- return E(c.disabled(e.disabled), c.name(e.name));
1946
+ return M(c.disabled(e.disabled), c.name(e.name));
1947
1947
  }
1948
- function Pt(e, {
1948
+ function Ot(e, {
1949
1949
  triggerOn: t = "change"
1950
1950
  } = {}) {
1951
- return E(
1951
+ return M(
1952
1952
  be(e),
1953
1953
  c.value(e.value),
1954
- (t === "input" ? w.input : w.change)(M(e.change))
1954
+ (t === "input" ? C.input : C.change)(P(e.change))
1955
1955
  );
1956
1956
  }
1957
- function Vt(e, {
1957
+ function jt(e, {
1958
1958
  triggerOn: t = "change"
1959
1959
  } = {}) {
1960
- return E(
1960
+ return M(
1961
1961
  be(e),
1962
1962
  c.valueAsNumber(e.value),
1963
- (t === "input" ? w.input : w.change)(
1963
+ (t === "input" ? C.input : C.change)(
1964
1964
  ke(e.change)
1965
1965
  )
1966
1966
  );
1967
1967
  }
1968
1968
  function re(e) {
1969
- return e.issues != null ? D.invalid(ct(e.issues)) : D.valid;
1969
+ return e.issues != null ? _.invalid(ht(e.issues)) : _.valid;
1970
1970
  }
1971
- async function At({
1971
+ async function Nt({
1972
1972
  task: e,
1973
1973
  errorMessage: t,
1974
1974
  errorPath: s = ["root"],
@@ -1976,12 +1976,13 @@ async function At({
1976
1976
  }) {
1977
1977
  try {
1978
1978
  const r = await e();
1979
- return n != null ? n(r) : D.valid;
1979
+ return console.log(n), n != null ? (console.log("Applying validation"), n(r)) : (console.log("No validation"), _.valid);
1980
1980
  } catch (r) {
1981
+ console.log("Error", r);
1981
1982
  const a = t ?? (r instanceof Error ? r.message : "Operation failed");
1982
- return s.length === 1 && s[0] === "root" ? D.invalid({
1983
+ return s.length === 1 && s[0] === "root" ? _.invalid({
1983
1984
  message: a
1984
- }) : D.invalid({
1985
+ }) : _.invalid({
1985
1986
  dependencies: ge(s, a)
1986
1987
  });
1987
1988
  }
@@ -1998,14 +1999,14 @@ function ge(e, t) {
1998
1999
  }
1999
2000
  };
2000
2001
  }
2001
- function $t({
2002
+ function Ft({
2002
2003
  initialValue: e = {},
2003
2004
  schema: t,
2004
- onSubmit: s = async () => D.valid,
2005
+ onSubmit: s = async () => _.valid,
2005
2006
  validationMode: n,
2006
2007
  validateDebounceMs: r
2007
2008
  }) {
2008
- const { controller: a, setStatus: o } = ut({
2009
+ const { controller: a, setStatus: o } = pt({
2009
2010
  initialValue: e,
2010
2011
  validationMode: n ?? "touchedOrSubmit",
2011
2012
  validateDebounceMs: r,
@@ -2018,10 +2019,10 @@ function $t({
2018
2019
  setStatus: o,
2019
2020
  submit: async (u) => {
2020
2021
  if (i.set(!0), u?.preventDefault(), l.markAllTouched(), (n ?? "touchedOrSubmit") === "onSubmit") {
2021
- const b = l.value.value, m = re(
2022
- await t["~standard"].validate(b)
2022
+ const g = l.value.value, v = re(
2023
+ await t["~standard"].validate(g)
2023
2024
  );
2024
- if (o(m), m.type === "invalid") {
2025
+ if (o(v), v.type === "invalid") {
2025
2026
  i.set(!1);
2026
2027
  return;
2027
2028
  }
@@ -2032,11 +2033,11 @@ function $t({
2032
2033
  submitting: i
2033
2034
  };
2034
2035
  }
2035
- function dt(e) {
2036
+ function ft(e) {
2036
2037
  const t = e.split("-"), s = [e];
2037
2038
  return t.length > 1 && s.push(t[0]), s;
2038
2039
  }
2039
- function ht({
2040
+ function bt({
2040
2041
  locale: e,
2041
2042
  defaultLocale: t = "en-US",
2042
2043
  defaultMessages: s,
@@ -2045,7 +2046,7 @@ function ht({
2045
2046
  const r = I(t), a = I(s), o = e.on(async (i) => {
2046
2047
  if (i === r.value) return;
2047
2048
  r.set(i);
2048
- const l = dt(i);
2049
+ const l = ft(i);
2049
2050
  for (const d of l)
2050
2051
  try {
2051
2052
  const u = await n(d);
@@ -2076,7 +2077,7 @@ function ht({
2076
2077
  t: a
2077
2078
  };
2078
2079
  }
2079
- function pt({
2080
+ function gt({
2080
2081
  defaultLocale: e,
2081
2082
  defaultMessages: t,
2082
2083
  localeLoader: s,
@@ -2087,7 +2088,7 @@ function pt({
2087
2088
  create: (r, a) => {
2088
2089
  const {
2089
2090
  value: { locale: o }
2090
- } = a.getProvider(Pe.mark), { t: i, dispose: l } = ht({
2091
+ } = a.getProvider(Ae.mark), { t: i, dispose: l } = bt({
2091
2092
  locale: o,
2092
2093
  defaultMessages: t,
2093
2094
  defaultLocale: e,
@@ -2100,76 +2101,175 @@ function pt({
2100
2101
  }
2101
2102
  };
2102
2103
  }
2103
- const R = pt({
2104
- defaultLocale: _e,
2105
- defaultMessages: Ie,
2106
- localeLoader: async (e) => (await Ee(/* @__PURE__ */ Object.assign({ "./locales/ar.ts": () => import("./ar-BgrUqaxG.js"), "./locales/de.ts": () => import("./de-D_sdCcAw.js"), "./locales/en.ts": () => Promise.resolve().then(() => De), "./locales/es.ts": () => import("./es-DczvLqEV.js"), "./locales/fa.ts": () => import("./fa-DhPP5Tgo.js"), "./locales/fr.ts": () => import("./fr-D3WwoeQg.js"), "./locales/he.ts": () => import("./he-CFhi-6Rs.js"), "./locales/hi.ts": () => import("./hi-Cqy8JcS7.js"), "./locales/it.ts": () => import("./it-CtMArqSp.js"), "./locales/ja.ts": () => import("./ja-UFqZT78C.js"), "./locales/ko.ts": () => import("./ko-B5LB1_X_.js"), "./locales/nl.ts": () => import("./nl-DCfHVqzQ.js"), "./locales/pl.ts": () => import("./pl-UcTv39q1.js"), "./locales/pt.ts": () => import("./pt-CXsgmVtb.js"), "./locales/ru.ts": () => import("./ru-C0MvZW2g.js"), "./locales/tr.ts": () => import("./tr-CIIkc1uL.js"), "./locales/ur.ts": () => import("./ur-Cpx9oyTV.js"), "./locales/vi.ts": () => import("./vi-D24AUQ01.js"), "./locales/zh.ts": () => import("./zh-25YFRjoV.js") }), `./locales/${e}.ts`, 3)).default,
2104
+ const R = gt({
2105
+ defaultLocale: Te,
2106
+ defaultMessages: Ee,
2107
+ localeLoader: async (e) => (await Le(/* @__PURE__ */ Object.assign({ "./locales/ar.ts": () => import("./ar-CxLxXsxZ.js"), "./locales/de.ts": () => import("./de-C7iv8rS5.js"), "./locales/en.ts": () => Promise.resolve().then(() => _e), "./locales/es.ts": () => import("./es-DyivIdRS.js"), "./locales/fa.ts": () => import("./fa-T2168lXR.js"), "./locales/fr.ts": () => import("./fr-ehNjmGC4.js"), "./locales/he.ts": () => import("./he-TD57Y17Z.js"), "./locales/hi.ts": () => import("./hi-B4NbRIf5.js"), "./locales/it.ts": () => import("./it-D3x9ILJi.js"), "./locales/ja.ts": () => import("./ja-BSfyBDbo.js"), "./locales/ko.ts": () => import("./ko-DNahUn8W.js"), "./locales/nl.ts": () => import("./nl-DxveNtuq.js"), "./locales/pl.ts": () => import("./pl-DuKW800E.js"), "./locales/pt.ts": () => import("./pt-DPt1NyaL.js"), "./locales/ru.ts": () => import("./ru-DwiRelVA.js"), "./locales/tr.ts": () => import("./tr-DQIURNMa.js"), "./locales/ur.ts": () => import("./ur-ChuKCUVI.js"), "./locales/vi.ts": () => import("./vi-CJ3gBepb.js"), "./locales/zh.ts": () => import("./zh-DBCCiN2o.js") }), `./locales/${e}.ts`, 3)).default,
2107
2108
  providerName: "BeatUII18n"
2108
2109
  });
2110
+ function mt(e) {
2111
+ switch (e) {
2112
+ case "success":
2113
+ return "material-symbols:check-circle-outline";
2114
+ case "warning":
2115
+ return "material-symbols:warning-outline";
2116
+ case "danger":
2117
+ return "material-symbols:error-outline";
2118
+ case "info":
2119
+ default:
2120
+ return "material-symbols:info-outline";
2121
+ }
2122
+ }
2123
+ function vt(e) {
2124
+ switch (e) {
2125
+ case "success":
2126
+ return "success";
2127
+ case "warning":
2128
+ return "warning";
2129
+ case "danger":
2130
+ return "danger";
2131
+ case "info":
2132
+ default:
2133
+ return "info";
2134
+ }
2135
+ }
2136
+ function kt(e, t, s, n) {
2137
+ const r = [
2138
+ "bc-notice",
2139
+ `bc-notice--${e}`,
2140
+ `bc-notice--tone-${t}`
2141
+ ];
2142
+ return s && r.push("bc-notice--dismissible"), n && n.length > 0 && r.push(n), r.join(" ");
2143
+ }
2144
+ function qt({
2145
+ variant: e = "info",
2146
+ tone: t = "subtle",
2147
+ role: s,
2148
+ title: n,
2149
+ icon: r,
2150
+ closable: a = !1,
2151
+ onDismiss: o,
2152
+ class: i
2153
+ }, ...l) {
2154
+ const d = D.map(
2155
+ a,
2156
+ (b) => !!b || o != null
2157
+ ), u = D.map(e, (b) => b ?? "info"), h = D.map(t, (b) => b ?? "subtle"), g = y(
2158
+ s,
2159
+ u
2160
+ )(
2161
+ (b, m) => b ?? (m === "danger" ? "alert" : "status")
2162
+ ), v = I(!0), f = q(
2163
+ R,
2164
+ (b) => p.div(
2165
+ c.class(
2166
+ y(
2167
+ u,
2168
+ h,
2169
+ d,
2170
+ i
2171
+ )((m, T, L, V) => kt(m, T, L, V))
2172
+ ),
2173
+ // Accessibility role mapping (always defined)
2174
+ c.role(D.map(g, (m) => m)),
2175
+ ye(
2176
+ D.map(r, (m) => m === !1),
2177
+ () => p.div(
2178
+ c.class("bc-notice__icon"),
2179
+ O({
2180
+ icon: y(
2181
+ r,
2182
+ u
2183
+ )((m, T) => m === void 0 ? mt(T) : String(m)),
2184
+ size: "md",
2185
+ color: D.map(u, vt)
2186
+ })
2187
+ )
2188
+ ),
2189
+ p.div(
2190
+ c.class("bc-notice__body"),
2191
+ we(n, (m) => p.div(c.class("bc-notice__title"), m)),
2192
+ p.div(c.class("bc-notice__content"), ...l)
2193
+ ),
2194
+ E(
2195
+ d,
2196
+ () => Ye({
2197
+ size: "xs",
2198
+ label: b.$.closeModal,
2199
+ onClick: () => {
2200
+ v.set(!1), o?.();
2201
+ }
2202
+ })
2203
+ )
2204
+ )
2205
+ );
2206
+ return E(v, () => f);
2207
+ }
2109
2208
  export {
2110
- re as $,
2209
+ jt as $,
2111
2210
  he as A,
2112
2211
  R as B,
2113
- wt as C,
2114
- Fe as D,
2115
- It as E,
2116
- qe as F,
2117
- nt as G,
2118
- Mt as H,
2119
- F as I,
2120
- rt as J,
2121
- at as K,
2122
- Qe as L,
2123
- Lt as M,
2124
- ot as N,
2125
- N as O,
2126
- Et as P,
2127
- it as Q,
2128
- Ze as R,
2129
- Dt as S,
2130
- _t as T,
2131
- lt as U,
2132
- ct as V,
2133
- ut as W,
2134
- be as X,
2135
- Pt as Y,
2136
- Vt as Z,
2137
- Ee as _,
2138
- Ke as a,
2139
- Ct as a0,
2140
- Ye as a1,
2141
- xt as a2,
2142
- ht as a3,
2143
- ue as a4,
2144
- Le as a5,
2145
- mt as a6,
2146
- vt as a7,
2147
- kt as a8,
2148
- Me as a9,
2149
- yt as aa,
2150
- D as b,
2151
- St as c,
2152
- Tt as d,
2212
+ Ye as C,
2213
+ Re as D,
2214
+ Mt as E,
2215
+ He as F,
2216
+ ot as G,
2217
+ Bt as H,
2218
+ O as I,
2219
+ it as J,
2220
+ lt as K,
2221
+ Xe as L,
2222
+ $t as M,
2223
+ qt as N,
2224
+ F as O,
2225
+ Vt as P,
2226
+ ct as Q,
2227
+ ut as R,
2228
+ Lt as S,
2229
+ Pt as T,
2230
+ tt as U,
2231
+ dt as V,
2232
+ ht as W,
2233
+ pt as X,
2234
+ be as Y,
2235
+ Ot as Z,
2236
+ Le as _,
2237
+ Qe as a,
2238
+ re as a0,
2239
+ _t as a1,
2240
+ et as a2,
2241
+ Et as a3,
2242
+ bt as a4,
2243
+ ue as a5,
2244
+ Pe as a6,
2245
+ xt as a7,
2246
+ St as a8,
2247
+ Dt as a9,
2248
+ Ve as aa,
2249
+ It as ab,
2250
+ _ as b,
2251
+ Tt as c,
2252
+ At as d,
2153
2253
  W as e,
2154
2254
  ee as f,
2155
2255
  Z as g,
2156
- tt as h,
2157
- st as i,
2256
+ rt as h,
2257
+ at as i,
2158
2258
  pe as j,
2159
- Ie as k,
2160
- Pe as l,
2161
- pt as m,
2162
- O as n,
2259
+ Ee as k,
2260
+ Ae as l,
2261
+ gt as m,
2262
+ j as n,
2163
2263
  se as o,
2164
- A as p,
2264
+ $ as p,
2165
2265
  G as q,
2166
- V as r,
2266
+ A as r,
2167
2267
  le as s,
2168
- At as t,
2169
- $t as u,
2268
+ Nt as t,
2269
+ Ft as u,
2170
2270
  fe as v,
2171
- j as w,
2172
- Ge as x,
2173
- We as y,
2174
- _e as z
2271
+ N as w,
2272
+ Ke as x,
2273
+ Je as y,
2274
+ Te as z
2175
2275
  };