@tempots/beatui 0.39.0 → 0.41.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 (92) hide show
  1. package/README.md +11 -11
  2. package/dist/{2019-1S9vgvv2.cjs → 2019-BFDr925O.cjs} +1 -1
  3. package/dist/{2019-DPD_eCKE.js → 2019-DnG5Y5sm.js} +2 -2
  4. package/dist/{2020-aLm9VmDL.js → 2020-D0-tZTo7.js} +2 -2
  5. package/dist/{2020-CGrbEEmD.cjs → 2020-gUs7l1CJ.cjs} +1 -1
  6. package/dist/{ar-B0vT_MPe.cjs → ar-BLgxAefV.cjs} +1 -1
  7. package/dist/{ar-CbM09z5P.js → ar-DpQo8C31.js} +1 -1
  8. package/dist/auth/index.cjs.js +1 -1
  9. package/dist/auth/index.es.js +54 -49
  10. package/dist/beatui.css +216 -129
  11. package/dist/beatui.tailwind.css +216 -129
  12. package/dist/{de-tK36cL_u.cjs → de-Bv-qs--J.cjs} +1 -1
  13. package/dist/{de-Dd907tZQ.js → de-D1MQ4wen.js} +1 -1
  14. package/dist/{es-K35LRZa-.cjs → es-3r8Ko5Dn.cjs} +1 -1
  15. package/dist/{es-BkJxjMdG.js → es-DwPjonS7.js} +1 -1
  16. package/dist/{fa-BBikwwku.cjs → fa-Qw6uVZeX.cjs} +1 -1
  17. package/dist/{fa-DBTUBsw_.js → fa-fxf_lWjh.js} +1 -1
  18. package/dist/{fr-Fmupo556.js → fr-BDDsMHRZ.js} +1 -1
  19. package/dist/{fr-DMtXrrnJ.cjs → fr-pVhG9qik.cjs} +1 -1
  20. package/dist/{he-DkI64oaY.js → he-B4deK_wE.js} +1 -1
  21. package/dist/{he-on3Ivp8g.cjs → he-D-fvzfe1.cjs} +1 -1
  22. package/dist/{hi-GdD5MihT.js → hi-CxQT8nRD.js} +1 -1
  23. package/dist/{hi-CNFV8ITE.cjs → hi-DKgxHzmH.cjs} +1 -1
  24. package/dist/{index-BK8t6gqu.js → index-Acyxme63.js} +680 -677
  25. package/dist/{index-e8oQ-k0x.cjs → index-BZ2AX5sk.cjs} +4 -4
  26. package/dist/{index-BfFlhmAq.js → index-BwEJlbG2.js} +1 -1
  27. package/dist/{index-DjShJtXp.js → index-CAeOFdez.js} +1 -1
  28. package/dist/{index-BI5w0jSz.js → index-CBT2SLat.js} +224 -223
  29. package/dist/{index-BkQ7xHgi.js → index-CWq36UAJ.js} +770 -757
  30. package/dist/{index-Bv2gn_kV.cjs → index-ClFVnBUS.cjs} +3 -3
  31. package/dist/{index-LUItEwlw.js → index-Clw0AwwJ.js} +1 -1
  32. package/dist/{index-wdi93sK4.cjs → index-DRDJFYRb.cjs} +1 -1
  33. package/dist/{index-CKyH3jwP.cjs → index-KPHFBjQB.cjs} +1 -1
  34. package/dist/{index-BA93M8Ux.cjs → index-Lj0QS2po.cjs} +1 -1
  35. package/dist/{index-CPBlySmE.cjs → index-nVVPqgLq.cjs} +12 -12
  36. package/dist/index.cjs.js +4 -4
  37. package/dist/index.es.js +2200 -2181
  38. package/dist/{it-Bpnfd60V.js → it-6QS5PWzQ.js} +1 -1
  39. package/dist/{it-BDOzBRkQ.cjs → it-Ck0r9TO3.cjs} +1 -1
  40. package/dist/{ja-SjlGNgs9.js → ja-D2VvVGEN.js} +1 -1
  41. package/dist/{ja-N-7c7zD7.cjs → ja-D6b9suYB.cjs} +1 -1
  42. package/dist/json-schema/index.cjs.js +1 -1
  43. package/dist/json-schema/index.es.js +1 -1
  44. package/dist/{ko-CH69ZNts.js → ko-CP_WopWz.js} +1 -1
  45. package/dist/{ko-BBeTXIlY.cjs → ko-CzvM2Bjv.cjs} +1 -1
  46. package/dist/markdown/index.cjs.js +1 -1
  47. package/dist/markdown/index.es.js +1 -1
  48. package/dist/modal-BmSRMdY9.cjs +1 -0
  49. package/dist/{modal-BD76Rve3.js → modal-DMc-R2VT.js} +234 -209
  50. package/dist/{nl-DnvMlW8v.js → nl-DZ4dFolZ.js} +1 -1
  51. package/dist/{nl-C2C9QDH2.cjs → nl-_9vJc8JD.cjs} +1 -1
  52. package/dist/{notice-CQZseCQs.js → notice-B5Yn_3Ay.js} +205 -195
  53. package/dist/notice-D3P0lewM.cjs +2 -0
  54. package/dist/{pl-CBEX2qN1.js → pl-BE81iFSF.js} +1 -1
  55. package/dist/{pl-sNBCzEUd.cjs → pl-DKcVCojx.cjs} +1 -1
  56. package/dist/prosemirror/index.cjs.js +1 -1
  57. package/dist/prosemirror/index.es.js +1 -1
  58. package/dist/{pt-ByFqFAdQ.js → pt-BcCdXUA2.js} +1 -1
  59. package/dist/{pt-Bvxg9VEA.cjs → pt-DNVS1_MF.cjs} +1 -1
  60. package/dist/{ru-6d5JfoDw.js → ru-Bo_jc3s1.js} +1 -1
  61. package/dist/{ru-CPAdsn4m.cjs → ru-DTn9Rssv.cjs} +1 -1
  62. package/dist/{toolbar-Cl_TAa3r.js → toolbar-DhD5GmMa.js} +1 -1
  63. package/dist/{toolbar-Dw2VQD9y.cjs → toolbar-jPGzdJGi.cjs} +1 -1
  64. package/dist/{tr-IKZtCQQR.cjs → tr-BhTJYHQ3.cjs} +1 -1
  65. package/dist/{tr-gv4vJfm8.js → tr-CBw3FlOg.js} +1 -1
  66. package/dist/{translations-DXLmnUiB.js → translations-B0HuWYIz.js} +1 -1
  67. package/dist/{translations-CK426qyd.cjs → translations-B7_3phoA.cjs} +1 -1
  68. package/dist/translations-C21osktO.cjs +1 -0
  69. package/dist/{translations-djDSPqdb.js → translations-D-fMB_IO.js} +212 -183
  70. package/dist/types/components/form/controller/color-controller.d.ts +1 -1
  71. package/dist/types/components/form/input/color-input.d.ts +2 -5
  72. package/dist/types/components/form/input/color-swatch-input.d.ts +9 -0
  73. package/dist/types/components/form/input/index.d.ts +1 -0
  74. package/dist/types/components/form/input/input-container.d.ts +7 -0
  75. package/dist/types/components/misc/notification-provider.d.ts +3 -3
  76. package/dist/types/utils/{color-validation.d.ts → color.d.ts} +13 -0
  77. package/dist/types/utils/index.d.ts +1 -1
  78. package/dist/types/utils/use-animated-toggle.d.ts +17 -4
  79. package/dist/{ur-Bgq_2yjr.cjs → ur-BjuXyU8Z.cjs} +1 -1
  80. package/dist/{ur-Bo6bjEBS.js → ur-BsXnPgxd.js} +1 -1
  81. package/dist/utils-BOEQMy82.js +2512 -0
  82. package/dist/utils-DH-SYrQg.cjs +1 -0
  83. package/dist/{vi-BrUQnj-8.cjs → vi-CvsTHMkK.cjs} +1 -1
  84. package/dist/{vi-xDLJ3TIx.js → vi-D1rLo6MX.js} +1 -1
  85. package/dist/{zh-BivWxJJh.js → zh-BoLsjdfz.js} +1 -1
  86. package/dist/{zh-BqH1Cioq.cjs → zh-zh1FJ4Ud.cjs} +1 -1
  87. package/package.json +4 -3
  88. package/dist/modal-DQycMZ8_.cjs +0 -1
  89. package/dist/notice-CFoc4PJe.cjs +0 -2
  90. package/dist/translations-DJR65Jii.cjs +0 -1
  91. package/dist/utils-Bsrfm-0d.cjs +0 -1
  92. package/dist/utils-Bw911Eo4.js +0 -2418
@@ -1,7 +1,7 @@
1
- import { makeProviderMark as R, localStorageProp as j, computedOf as m, Use as O, html as f, attr as c, When as w, Fragment as y, aria as g, coalesce as z, style as L, prop as $, on as I, OnDispose as A, Value as _, WithElement as K, input as W, Empty as P, emitValue as S } from "@tempots/dom";
2
- import { b as J, g as Q } from "./colors-WfmhQ5e1.js";
3
- import { WhenInViewport as Y, Query as Z, ElementRect as X } from "@tempots/ui";
4
- function T(t, {
1
+ import { makeProviderMark as O, localStorageProp as T, computedOf as p, Use as A, html as f, attr as c, When as w, Fragment as y, aria as g, coalesce as z, style as D, prop as $, on as I, OnDispose as M, Value as L, WithElement as K, input as W, Empty as S, emitValue as _ } from "@tempots/dom";
2
+ import { WhenInViewport as J, Query as Q, ElementRect as Y } from "@tempots/ui";
3
+ import { b as Z, g as X } from "./colors-WfmhQ5e1.js";
4
+ function E(t, {
5
5
  units: e = ["B", "KB", "MB", "GB", "TB"],
6
6
  decimalPlaces: n = 0,
7
7
  locale: o
@@ -13,21 +13,21 @@ function T(t, {
13
13
  unitDisplay: "short",
14
14
  maximumFractionDigits: 0
15
15
  }).format(0).replace("byte", e[0]);
16
- let r, a;
16
+ let a, r;
17
17
  if (typeof t == "bigint") {
18
18
  let l = t < 0n ? -t : t;
19
- for (r = 0; l >= 1024n && r < e.length - 1; )
20
- l = l / 1024n, r++;
21
- a = Number(t) / Math.pow(1024, r);
19
+ for (a = 0; l >= 1024n && a < e.length - 1; )
20
+ l = l / 1024n, a++;
21
+ r = Number(t) / Math.pow(1024, a);
22
22
  } else
23
- r = Math.floor(Math.log(Math.abs(t)) / Math.log(1024)), r = Math.min(r, e.length - 1), a = t / Math.pow(1024, r);
23
+ a = Math.floor(Math.log(Math.abs(t)) / Math.log(1024)), a = Math.min(a, e.length - 1), r = t / Math.pow(1024, a);
24
24
  return new Intl.NumberFormat(o, {
25
25
  style: "unit",
26
26
  unit: "byte",
27
27
  unitDisplay: "short",
28
- minimumFractionDigits: r === 0 ? 0 : n,
29
- maximumFractionDigits: r === 0 ? 0 : n
30
- }).format(a).replace("byte", e[r]);
28
+ minimumFractionDigits: a === 0 ? 0 : n,
29
+ maximumFractionDigits: a === 0 ? 0 : n
30
+ }).format(r).replace("byte", e[a]);
31
31
  }
32
32
  const N = {
33
33
  loadingExtended: "Loading, please wait",
@@ -90,19 +90,19 @@ const N = {
90
90
  filesInputInstructions: (t, e, n) => {
91
91
  let o = t == null || t > 1 ? "Click to choose or drag files here" : "Click to choose or drag a file here";
92
92
  if (t || e) {
93
- const r = [];
94
- if (t != null && t > 1 && r.push(`up to ${t} files`), e && n) {
95
- const a = T(e, {
93
+ const a = [];
94
+ if (t != null && t > 1 && a.push(`up to ${t} files`), e && n) {
95
+ const r = E(e, {
96
96
  units: n
97
97
  });
98
- r.push(`max ${a} each`);
98
+ a.push(`max ${r} each`);
99
99
  }
100
- r.length > 0 && (o += ` (${r.join(", ")})`);
100
+ a.length > 0 && (o += ` (${a.join(", ")})`);
101
101
  } else if (e && n) {
102
- const r = T(e, {
102
+ const a = E(e, {
103
103
  units: n
104
104
  });
105
- o += ` (max ${r})`;
105
+ o += ` (max ${a})`;
106
106
  }
107
107
  return o;
108
108
  },
@@ -126,8 +126,8 @@ const N = {
126
126
  default: N
127
127
  }, Symbol.toStringTag, { value: "Module" })), et = N, ot = "en", nt = (t, e, n) => {
128
128
  const o = t[e];
129
- return o ? typeof o == "function" ? o() : Promise.resolve(o) : new Promise((r, a) => {
130
- (typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(a.bind(null, /* @__PURE__ */ new Error("Unknown variable dynamic import: " + e + (e.split("/").length !== n ? ". Note that variables only represent file names one level deep." : ""))));
129
+ return o ? typeof o == "function" ? o() : Promise.resolve(o) : new Promise((a, r) => {
130
+ (typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(r.bind(null, /* @__PURE__ */ new Error("Unknown variable dynamic import: " + e + (e.split("/").length !== n ? ". Note that variables only represent file names one level deep." : ""))));
131
131
  });
132
132
  }, rt = /* @__PURE__ */ new Set([
133
133
  "ar",
@@ -190,27 +190,27 @@ function Vt(t, e) {
190
190
  return st[e][t];
191
191
  }
192
192
  const lt = {
193
- mark: R("Locale"),
193
+ mark: O("Locale"),
194
194
  create: (t) => {
195
- const e = j({
195
+ const e = T({
196
196
  defaultValue: navigator.language ?? "en-US",
197
197
  key: "beatui-locale"
198
- }), n = j({
198
+ }), n = T({
199
199
  defaultValue: "auto",
200
200
  key: "beatui-direction-preference"
201
- }), o = m(
201
+ }), o = p(
202
202
  e,
203
203
  n
204
204
  )(
205
- (a, s) => at(s, a)
205
+ (r, s) => at(s, r)
206
206
  );
207
207
  return {
208
208
  value: {
209
209
  locale: e,
210
- setLocale: (a) => e.set(a),
210
+ setLocale: (r) => e.set(r),
211
211
  direction: o,
212
212
  directionPreference: n,
213
- setDirectionPreference: (a) => n.set(a)
213
+ setDirectionPreference: (r) => n.set(r)
214
214
  },
215
215
  dispose: () => {
216
216
  e.dispose(), n.dispose(), o.dispose();
@@ -220,8 +220,8 @@ const lt = {
220
220
  }, {
221
221
  variants: it,
222
222
  special: ct,
223
- overrides: M
224
- } = J;
223
+ overrides: j
224
+ } = Z;
225
225
  function k(t, e) {
226
226
  switch (t) {
227
227
  case "white":
@@ -231,7 +231,7 @@ function k(t, e) {
231
231
  case "transparent":
232
232
  return "transparent";
233
233
  default:
234
- return Q(t, e);
234
+ return X(t, e);
235
235
  }
236
236
  }
237
237
  function U(t, e) {
@@ -239,28 +239,28 @@ function U(t, e) {
239
239
  if (!n) return;
240
240
  if (e === "light")
241
241
  return n;
242
- const o = M[t];
242
+ const o = j[t];
243
243
  return o ? o[e] : n;
244
244
  }
245
245
  function x(t, e, n) {
246
- const o = M[t];
246
+ const o = j[t];
247
247
  if (o) {
248
- const a = o[n];
249
- if (a)
250
- return { backgroundColor: a.backgroundColor, textColor: a.color };
248
+ const r = o[n];
249
+ if (r)
250
+ return { backgroundColor: r.backgroundColor, textColor: r.color };
251
251
  }
252
252
  if (e === "solid") {
253
- const a = U(t, n);
254
- if (a)
253
+ const r = U(t, n);
254
+ if (r)
255
255
  return {
256
- backgroundColor: a.backgroundColor,
257
- textColor: a.color
256
+ backgroundColor: r.backgroundColor,
257
+ textColor: r.color
258
258
  };
259
259
  }
260
- const r = it[e][n];
260
+ const a = it[e][n];
261
261
  return {
262
- backgroundColor: k(t, r.bgShade),
263
- textColor: r.textColor
262
+ backgroundColor: k(t, a.bgShade),
263
+ textColor: a.textColor
264
264
  };
265
265
  }
266
266
  const ut = {
@@ -273,19 +273,19 @@ const ut = {
273
273
  light: { shade: 400, textColor: "var(--text-normal-light)" },
274
274
  dark: { shade: 600, textColor: "var(--text-normal-dark)" }
275
275
  };
276
- function p(t, e, n) {
277
- const o = M[t];
276
+ function m(t, e, n) {
277
+ const o = j[t];
278
278
  if (o) {
279
- const a = o[n];
280
- if (a)
281
- return { backgroundColor: a.backgroundColor, textColor: a.color };
279
+ const r = o[n];
280
+ if (r)
281
+ return { backgroundColor: r.backgroundColor, textColor: r.color };
282
282
  }
283
283
  if (e === "solid") {
284
- const a = U(t, n);
285
- if (a)
284
+ const r = U(t, n);
285
+ if (r)
286
286
  return {
287
- backgroundColor: a.backgroundColor,
288
- textColor: a.color
287
+ backgroundColor: r.backgroundColor,
288
+ textColor: r.color
289
289
  };
290
290
  const s = ut[n];
291
291
  return {
@@ -293,13 +293,13 @@ function p(t, e, n) {
293
293
  textColor: s.textColor
294
294
  };
295
295
  }
296
- const r = e === "light" ? dt[n] : ht[n];
296
+ const a = e === "light" ? dt[n] : ht[n];
297
297
  return {
298
- backgroundColor: k(t, r.shade),
299
- textColor: r.textColor
298
+ backgroundColor: k(t, a.shade),
299
+ textColor: a.textColor
300
300
  };
301
301
  }
302
- function E(t, e) {
302
+ function V(t, e) {
303
303
  const n = e === "light" ? 500 : 600;
304
304
  switch (t) {
305
305
  case "white":
@@ -315,10 +315,10 @@ function E(t, e) {
315
315
  function C(t, e) {
316
316
  return t === "white" ? "var(--color-white)" : t === "black" ? "var(--color-black)" : t === "transparent" ? "inherit" : k(t, e === "light" ? 800 : 200);
317
317
  }
318
- function V(t, e, n) {
318
+ function R(t, e, n) {
319
319
  return e === "soft" ? k(t, n === "light" ? 300 : 700) : k(t, n === "light" ? 500 : 600);
320
320
  }
321
- const bt = "bui-icons", D = /* @__PURE__ */ new Map(), H = (() => {
321
+ const bt = "bui-icons", B = /* @__PURE__ */ new Map(), H = (() => {
322
322
  try {
323
323
  return typeof indexedDB < "u" && indexedDB !== null;
324
324
  } catch {
@@ -329,8 +329,8 @@ function gt() {
329
329
  return H ? new Promise((t, e) => {
330
330
  const n = indexedDB.open(bt, 1);
331
331
  n.onupgradeneeded = function(o) {
332
- const r = o.target.result;
333
- r.objectStoreNames.contains("icons") || r.createObjectStore("icons");
332
+ const a = o.target.result;
333
+ a.objectStoreNames.contains("icons") || a.createObjectStore("icons");
334
334
  }, n.onsuccess = function() {
335
335
  t(n.result);
336
336
  }, n.onerror = function() {
@@ -338,32 +338,32 @@ function gt() {
338
338
  };
339
339
  }) : Promise.reject(new Error("IndexedDB not available"));
340
340
  }
341
- const B = H ? gt() : null;
341
+ const P = H ? gt() : null;
342
342
  function ft(t, e) {
343
343
  return new Promise(async (n, o) => {
344
344
  try {
345
- if (B) {
346
- const a = (await B).transaction("icons", "readwrite");
347
- a.objectStore("icons").put(e, t), a.oncomplete = n, a.onerror = o;
345
+ if (P) {
346
+ const r = (await P).transaction("icons", "readwrite");
347
+ r.objectStore("icons").put(e, t), r.oncomplete = n, r.onerror = o;
348
348
  } else
349
- D.set(t, e), n(void 0);
349
+ B.set(t, e), n(void 0);
350
350
  } catch {
351
- D.set(t, e), n(void 0);
351
+ B.set(t, e), n(void 0);
352
352
  }
353
353
  });
354
354
  }
355
355
  function pt(t) {
356
356
  return new Promise(async (e, n) => {
357
357
  try {
358
- if (B) {
359
- const s = (await B).transaction("icons", "readonly").objectStore("icons").get(t);
358
+ if (P) {
359
+ const s = (await P).transaction("icons", "readonly").objectStore("icons").get(t);
360
360
  s.onsuccess = function() {
361
361
  e(s.result);
362
362
  }, s.onerror = n;
363
363
  } else
364
- e(D.get(t) || null);
364
+ e(B.get(t) || null);
365
365
  } catch {
366
- e(D.get(t) || null);
366
+ e(B.get(t) || null);
367
367
  }
368
368
  });
369
369
  }
@@ -387,31 +387,31 @@ function vt(t) {
387
387
  }
388
388
  function xt(t, e = "solid") {
389
389
  if (!t) return "";
390
- const n = V(t, e, "light"), o = V(t, e, "dark");
390
+ const n = R(t, e, "light"), o = R(t, e, "dark");
391
391
  return `--icon-color: ${n}; --icon-color-dark: ${o}`;
392
392
  }
393
- function Ct({
393
+ function G({
394
394
  icon: t,
395
395
  size: e = "md",
396
396
  color: n,
397
397
  title: o,
398
- accessibility: r = "auto",
399
- tone: a = "solid"
398
+ accessibility: a = "auto",
399
+ tone: r = "solid"
400
400
  }, ...s) {
401
- const i = m(
402
- r,
401
+ const i = p(
402
+ a,
403
403
  o
404
404
  )((l, u) => l === "decorative" ? !1 : l === "informative" ? !0 : u != null && u !== "");
405
- return O(
406
- G,
405
+ return A(
406
+ F,
407
407
  (l) => f.span(
408
408
  c.class(
409
- m(e, n)((u) => vt(u ?? "md"))
409
+ p(e, n)((u) => vt(u ?? "md"))
410
410
  ),
411
411
  c.style(
412
- m(
412
+ p(
413
413
  n,
414
- a
414
+ r
415
415
  )(
416
416
  (u, b) => xt(u ?? void 0, b ?? "solid")
417
417
  )
@@ -425,15 +425,15 @@ function Ct({
425
425
  ),
426
426
  () => g.hidden(!0)
427
427
  ),
428
- Y(
428
+ J(
429
429
  { once: !0 },
430
- () => Z({
430
+ () => Q({
431
431
  request: t,
432
432
  load: ({ request: u }) => kt(u),
433
433
  convertError: String,
434
434
  success: ({ value: u }) => f.span(
435
- L.width("100%"),
436
- L.height("100%"),
435
+ D.width("100%"),
436
+ D.height("100%"),
437
437
  c.innerHTML(u)
438
438
  ),
439
439
  pending: () => f.span(
@@ -463,33 +463,33 @@ function Ct({
463
463
  )
464
464
  );
465
465
  }
466
- function wt(t, e, n, o) {
467
- const r = [
466
+ function Ct(t, e, n, o) {
467
+ const a = [
468
468
  "bc-button",
469
469
  `bc-button--size-${t}`,
470
470
  `bc-control--padding-${t}`,
471
471
  `bc-control--rounded-${e}`
472
472
  ];
473
- return n && r.push("bc-button--loading"), o && r.push("bc-button--full-width"), r.join(" ");
473
+ return n && a.push("bc-button--loading"), o && a.push("bc-button--full-width"), a.join(" ");
474
474
  }
475
- function yt(t, e, n) {
475
+ function wt(t, e, n) {
476
476
  const o = /* @__PURE__ */ new Map();
477
477
  o.set("--button-text-shadow", "var(--text-shadow-none)"), o.set("--button-text-shadow-dark", "var(--text-shadow-none)");
478
- const r = (a, s, i, l) => {
479
- n || (o.set("--button-bg-hover", a), o.set("--button-text-hover", i), o.set("--button-bg-hover-dark", s), o.set("--button-text-hover-dark", l));
478
+ const a = (r, s, i, l) => {
479
+ n || (o.set("--button-bg-hover", r), o.set("--button-text-hover", i), o.set("--button-bg-hover-dark", s), o.set("--button-text-hover-dark", l));
480
480
  };
481
481
  switch (t) {
482
482
  case "filled": {
483
- const a = x(e, "solid", "light"), s = x(e, "solid", "dark");
484
- o.set("--button-bg", a.backgroundColor), o.set("--button-text", a.textColor), o.set("--button-bg-dark", s.backgroundColor), o.set("--button-text-dark", s.textColor), o.set(
483
+ const r = x(e, "solid", "light"), s = x(e, "solid", "dark");
484
+ o.set("--button-bg", r.backgroundColor), o.set("--button-text", r.textColor), o.set("--button-bg-dark", s.backgroundColor), o.set("--button-text-dark", s.textColor), o.set(
485
485
  "--button-text-shadow",
486
486
  "var(--text-shadow-button-filled, var(--text-shadow-sm))"
487
487
  ), o.set(
488
488
  "--button-text-shadow-dark",
489
489
  "var(--text-shadow-button-filled, var(--text-shadow-sm))"
490
490
  );
491
- const i = p(e, "solid", "light"), l = p(e, "solid", "dark");
492
- r(
491
+ const i = m(e, "solid", "light"), l = m(e, "solid", "dark");
492
+ a(
493
493
  i.backgroundColor,
494
494
  l.backgroundColor,
495
495
  i.textColor,
@@ -498,10 +498,10 @@ function yt(t, e, n) {
498
498
  break;
499
499
  }
500
500
  case "light": {
501
- const a = x(e, "light", "light"), s = x(e, "light", "dark");
502
- o.set("--button-bg", a.backgroundColor), o.set("--button-text", a.textColor), o.set("--button-bg-dark", s.backgroundColor), o.set("--button-text-dark", s.textColor);
503
- const i = p(e, "light", "light"), l = p(e, "light", "dark");
504
- r(
501
+ const r = x(e, "light", "light"), s = x(e, "light", "dark");
502
+ o.set("--button-bg", r.backgroundColor), o.set("--button-text", r.textColor), o.set("--button-bg-dark", s.backgroundColor), o.set("--button-text-dark", s.textColor);
503
+ const i = m(e, "light", "light"), l = m(e, "light", "dark");
504
+ a(
505
505
  i.backgroundColor,
506
506
  l.backgroundColor,
507
507
  i.textColor,
@@ -510,36 +510,36 @@ function yt(t, e, n) {
510
510
  break;
511
511
  }
512
512
  case "outline": {
513
- o.set("--button-bg", "transparent"), o.set("--button-bg-dark", "transparent"), o.set("--button-border", E(e, "light")), o.set("--button-border-dark", E(e, "dark")), o.set("--button-text", C(e, "light")), o.set("--button-text-dark", C(e, "dark")), o.set(
513
+ o.set("--button-bg", "transparent"), o.set("--button-bg-dark", "transparent"), o.set("--button-border", V(e, "light")), o.set("--button-border-dark", V(e, "dark")), o.set("--button-text", C(e, "light")), o.set("--button-text-dark", C(e, "dark")), o.set(
514
514
  "--button-text-shadow",
515
515
  "var(--text-shadow-button-light, var(--text-shadow-xs))"
516
516
  ), o.set(
517
517
  "--button-text-shadow-dark",
518
518
  "var(--text-shadow-button-light, var(--text-shadow-xs))"
519
519
  );
520
- const a = p(e, "light", "light"), s = p(e, "light", "dark");
521
- r(
522
- a.backgroundColor,
520
+ const r = m(e, "light", "light"), s = m(e, "light", "dark");
521
+ a(
522
+ r.backgroundColor,
523
523
  s.backgroundColor,
524
- a.textColor,
524
+ r.textColor,
525
525
  s.textColor
526
526
  );
527
527
  break;
528
528
  }
529
529
  case "default": {
530
- const a = x("neutral", "light", "light"), s = x("neutral", "light", "dark");
531
- o.set("--button-bg", a.backgroundColor), o.set("--button-text", C(e, "light")), o.set("--button-bg-dark", s.backgroundColor), o.set("--button-text-dark", C(e, "dark")), o.set(
530
+ const r = x("neutral", "light", "light"), s = x("neutral", "light", "dark");
531
+ o.set("--button-bg", r.backgroundColor), o.set("--button-text", C(e, "light")), o.set("--button-bg-dark", s.backgroundColor), o.set("--button-text-dark", C(e, "dark")), o.set(
532
532
  "--button-text-shadow",
533
533
  "var(--text-shadow-button-default, var(--text-shadow-2xs))"
534
534
  ), o.set(
535
535
  "--button-text-shadow-dark",
536
536
  "var(--text-shadow-button-default, var(--text-shadow-2xs))"
537
537
  );
538
- const i = p("base", "light", "light"), l = p("base", "light", "dark");
539
- r(
538
+ const i = m("base", "light", "light"), l = m("base", "light", "dark");
539
+ a(
540
540
  i.backgroundColor,
541
541
  l.backgroundColor,
542
- o.get("--button-text") ?? a.textColor,
542
+ o.get("--button-text") ?? r.textColor,
543
543
  o.get("--button-text-dark") ?? s.textColor
544
544
  );
545
545
  break;
@@ -549,27 +549,27 @@ function yt(t, e, n) {
549
549
  break;
550
550
  }
551
551
  }
552
- return Array.from(o.entries()).map(([a, s]) => `${a}: ${s}`).join("; ");
552
+ return Array.from(o.entries()).map(([r, s]) => `${r}: ${s}`).join("; ");
553
553
  }
554
554
  function Rt({
555
555
  type: t = "button",
556
556
  disabled: e = !1,
557
557
  loading: n = !1,
558
558
  variant: o = "filled",
559
- size: r = "md",
560
- color: a = "base",
559
+ size: a = "md",
560
+ color: r = "base",
561
561
  roundedness: s = "sm",
562
562
  onClick: i = () => {
563
563
  },
564
564
  fullWidth: l = !1
565
565
  }, ...u) {
566
566
  const b = $(null);
567
- return O(
568
- G,
567
+ return A(
568
+ F,
569
569
  (h) => f.button(
570
570
  c.type(t),
571
571
  c.disabled(
572
- m(
572
+ p(
573
573
  e,
574
574
  n
575
575
  )((d, v) => d || v)
@@ -578,19 +578,19 @@ function Rt({
578
578
  g.busy(n ?? !1),
579
579
  w(n ?? !1, () => g.label(h.$.loadingExtended)),
580
580
  c.class(
581
- m(r, s, n, l)(wt)
581
+ p(a, s, n, l)(Ct)
582
582
  ),
583
- c.style(m(o, a, e)(yt)),
583
+ c.style(p(o, r, e)(wt)),
584
584
  w(
585
585
  n ?? !1,
586
586
  () => y(
587
- L.width(
587
+ D.width(
588
588
  b.map((d) => d == null ? "" : `${d.width}px`)
589
589
  ),
590
- L.height(
590
+ D.height(
591
591
  b.map((d) => d == null ? "" : `${d.height}px`)
592
592
  ),
593
- Ct({ icon: "line-md:loading-twotone-loop", size: r ?? "md" }),
593
+ G({ icon: "line-md:loading-twotone-loop", size: a ?? "md" }),
594
594
  // Hidden live region for screen reader announcements
595
595
  f.span(
596
596
  c.class("sr-only"),
@@ -602,10 +602,10 @@ function Rt({
602
602
  ),
603
603
  w(
604
604
  n != null,
605
- () => X(
606
- (d) => A(
605
+ () => Y(
606
+ (d) => M(
607
607
  d.on((v) => {
608
- _.get(n ?? !1) || b.set(v);
608
+ L.get(n ?? !1) || b.set(v);
609
609
  })
610
610
  )
611
611
  )
@@ -613,71 +613,98 @@ function Rt({
613
613
  )
614
614
  );
615
615
  }
616
- function It(t, e, n, o) {
617
- const r = [
616
+ function yt(t, e, n) {
617
+ const o = [
618
618
  t ? "bc-base-input-container" : "bc-input-container"
619
619
  ];
620
- return e ? r.push(
620
+ return e ? o.push(
621
621
  t ? "bc-base-input-container--disabled" : "bc-input-container--disabled"
622
- ) : r.push(
622
+ ) : o.push(
623
623
  t ? "bc-base-input-container--default" : "bc-input-container--default"
624
- ), n && r.push("bc-input-container--error"), t || (r.push(`bc-control--padding-${o}`), r.push(`bc-control--text-size-${o}`)), r.join(" ");
624
+ ), n && o.push("bc-input-container--error"), o.join(" ");
625
+ }
626
+ function It(t, e) {
627
+ const n = ["bc-input-container__input"];
628
+ return t || (n.push(`bc-control--padding-${e}`), n.push(`bc-control--text-size-${e}`)), n.join(" ");
625
629
  }
626
630
  const Lt = ({
627
631
  baseContainer: t,
628
632
  disabled: e,
629
633
  input: n,
630
634
  before: o,
631
- after: r,
632
- hasError: a,
635
+ after: a,
636
+ hasError: r,
633
637
  focusableSelector: s = "input, select, textarea",
634
638
  growInput: i = !0,
635
639
  size: l
636
640
  }, ...u) => {
637
- const b = _.map(e ?? !1, (h) => h);
641
+ const b = L.map(e ?? !1, (h) => h);
638
642
  return f.div(
643
+ M(() => L.dispose(b)),
639
644
  K((h) => {
640
645
  const d = () => {
641
646
  h.querySelector(s)?.focus();
642
647
  };
643
- return h.addEventListener("click", d), A(() => h.removeEventListener("click", d));
648
+ return h.addEventListener("click", d), M(() => h.removeEventListener("click", d));
644
649
  }),
645
650
  c.class(
646
- m(
651
+ p(
647
652
  t,
648
653
  b,
649
- a ?? !1,
650
- l ?? "md"
654
+ r ?? !1
655
+ // size ?? 'md'
651
656
  )(
652
- (h, d, v, F) => It(
657
+ (h, d, v) => yt(
653
658
  h ?? !1,
654
659
  d ?? !1,
655
- v ?? !1,
656
- F ?? "md"
660
+ v ?? !1
661
+ // (size ?? 'md') as ControlSize
657
662
  )
658
663
  )
659
664
  ),
660
665
  o != null ? f.span(c.class("bc-input-container__before"), o) : null,
661
666
  f.div(
662
- c.class("bc-input-container__input"),
663
667
  c.class(
664
- _.map(
668
+ p(
669
+ t,
670
+ l ?? "md"
671
+ )(
672
+ (h, d) => It(
673
+ h ?? !1,
674
+ d ?? "md"
675
+ )
676
+ )
677
+ ),
678
+ // attr.class('bc-input-container__input'),
679
+ c.class(
680
+ L.map(
665
681
  i,
666
682
  (h) => h ? "bc-input-container__input--grow" : ""
667
683
  )
668
684
  ),
669
685
  n
670
686
  ),
671
- r != null ? f.span(c.class("bc-input-container__after"), r) : null,
687
+ a != null ? f.span(c.class("bc-input-container__after"), a) : null,
672
688
  ...u
673
689
  );
674
- }, Dt = ({
690
+ };
691
+ function Ot({
692
+ icon: t,
693
+ size: e = "md",
694
+ color: n = "neutral"
695
+ }) {
696
+ return f.span(
697
+ c.class("bc-input-container__icon"),
698
+ G({ icon: t, size: e, color: n })
699
+ );
700
+ }
701
+ const Dt = ({
675
702
  autocomplete: t,
676
703
  autofocus: e,
677
704
  class: n,
678
705
  disabled: o,
679
- name: r,
680
- placeholder: a,
706
+ name: a,
707
+ placeholder: r,
681
708
  id: s,
682
709
  required: i,
683
710
  hasError: l
@@ -686,24 +713,24 @@ const Lt = ({
686
713
  c.autofocus(e),
687
714
  c.class(n),
688
715
  c.disabled(o),
689
- c.name(r ?? s),
690
- c.placeholder(a),
716
+ c.name(a ?? s),
717
+ c.placeholder(r),
691
718
  c.id(s),
692
719
  g.required(i),
693
720
  l != null ? g.invalid(
694
721
  l ?? !1
695
722
  ) : null
696
- ), Ot = (t) => {
697
- const { value: e, onBlur: n, onChange: o, onInput: r } = t;
723
+ ), At = (t) => {
724
+ const { value: e, onBlur: n, onChange: o, onInput: a } = t;
698
725
  return Lt({
699
726
  ...t,
700
727
  input: W.text(
701
728
  Dt(t),
702
729
  c.value(e),
703
730
  c.class("bc-input"),
704
- n != null ? I.blur(S(n)) : P,
705
- o != null ? I.change(S(o)) : P,
706
- r != null ? I.input(S(r)) : P
731
+ n != null ? I.blur(_(n)) : S,
732
+ o != null ? I.change(_(o)) : S,
733
+ a != null ? I.input(_(a)) : S
707
734
  )
708
735
  });
709
736
  };
@@ -717,9 +744,9 @@ function Pt({
717
744
  defaultMessages: n,
718
745
  localeLoader: o
719
746
  }) {
720
- const r = $(e), a = $(n), s = t.on(async (i) => {
721
- if (i === r.value) return;
722
- r.set(i);
747
+ const a = $(e), r = $(n), s = t.on(async (i) => {
748
+ if (i === a.value) return;
749
+ a.set(i);
723
750
  const l = Bt(i);
724
751
  for (const u of l)
725
752
  try {
@@ -733,22 +760,22 @@ function Pt({
733
760
  );
734
761
  return;
735
762
  }
736
- if (i === r.value) {
737
- a.set(b);
763
+ if (i === a.value) {
764
+ r.set(b);
738
765
  return;
739
766
  }
740
767
  } catch {
741
768
  continue;
742
769
  }
743
- console.warn(`No locale found for "${t.value}", using fallback`), i === r.value && a.set(n);
770
+ console.warn(`No locale found for "${t.value}", using fallback`), i === a.value && r.set(n);
744
771
  });
745
772
  return {
746
773
  /** Clean up all resources and event listeners */
747
774
  dispose: () => {
748
- s(), r.dispose(), a.dispose();
775
+ s(), a.dispose(), r.dispose();
749
776
  },
750
777
  /** Translation functions that return reactive signals */
751
- t: a
778
+ t: r
752
779
  };
753
780
  }
754
781
  function St({
@@ -758,11 +785,11 @@ function St({
758
785
  providerName: o = "I18nProvider"
759
786
  }) {
760
787
  return {
761
- mark: R(o),
762
- create: (r, a) => {
788
+ mark: O(o),
789
+ create: (a, r) => {
763
790
  const {
764
791
  value: { locale: s }
765
- } = a.getProvider(lt.mark), { t: i, dispose: l } = Pt({
792
+ } = r.getProvider(lt.mark), { t: i, dispose: l } = Pt({
766
793
  locale: s,
767
794
  defaultMessages: e,
768
795
  defaultLocale: t,
@@ -775,40 +802,42 @@ function St({
775
802
  }
776
803
  };
777
804
  }
778
- const G = St({
805
+ const F = St({
779
806
  defaultLocale: ot,
780
807
  defaultMessages: et,
781
- localeLoader: async (t) => (await nt(/* @__PURE__ */ Object.assign({ "./locales/ar.ts": () => import("./ar-CbM09z5P.js"), "./locales/de.ts": () => import("./de-Dd907tZQ.js"), "./locales/en.ts": () => Promise.resolve().then(() => tt), "./locales/es.ts": () => import("./es-BkJxjMdG.js"), "./locales/fa.ts": () => import("./fa-DBTUBsw_.js"), "./locales/fr.ts": () => import("./fr-Fmupo556.js"), "./locales/he.ts": () => import("./he-DkI64oaY.js"), "./locales/hi.ts": () => import("./hi-GdD5MihT.js"), "./locales/it.ts": () => import("./it-Bpnfd60V.js"), "./locales/ja.ts": () => import("./ja-SjlGNgs9.js"), "./locales/ko.ts": () => import("./ko-CH69ZNts.js"), "./locales/nl.ts": () => import("./nl-DnvMlW8v.js"), "./locales/pl.ts": () => import("./pl-CBEX2qN1.js"), "./locales/pt.ts": () => import("./pt-ByFqFAdQ.js"), "./locales/ru.ts": () => import("./ru-6d5JfoDw.js"), "./locales/tr.ts": () => import("./tr-gv4vJfm8.js"), "./locales/ur.ts": () => import("./ur-Bo6bjEBS.js"), "./locales/vi.ts": () => import("./vi-xDLJ3TIx.js"), "./locales/zh.ts": () => import("./zh-BivWxJJh.js") }), `./locales/${t}.ts`, 3)).default,
808
+ localeLoader: async (t) => (await nt(/* @__PURE__ */ Object.assign({ "./locales/ar.ts": () => import("./ar-DpQo8C31.js"), "./locales/de.ts": () => import("./de-D1MQ4wen.js"), "./locales/en.ts": () => Promise.resolve().then(() => tt), "./locales/es.ts": () => import("./es-DwPjonS7.js"), "./locales/fa.ts": () => import("./fa-fxf_lWjh.js"), "./locales/fr.ts": () => import("./fr-BDDsMHRZ.js"), "./locales/he.ts": () => import("./he-B4deK_wE.js"), "./locales/hi.ts": () => import("./hi-CxQT8nRD.js"), "./locales/it.ts": () => import("./it-6QS5PWzQ.js"), "./locales/ja.ts": () => import("./ja-D2VvVGEN.js"), "./locales/ko.ts": () => import("./ko-CP_WopWz.js"), "./locales/nl.ts": () => import("./nl-DZ4dFolZ.js"), "./locales/pl.ts": () => import("./pl-BE81iFSF.js"), "./locales/pt.ts": () => import("./pt-BcCdXUA2.js"), "./locales/ru.ts": () => import("./ru-Bo_jc3s1.js"), "./locales/tr.ts": () => import("./tr-CBw3FlOg.js"), "./locales/ur.ts": () => import("./ur-BsXnPgxd.js"), "./locales/vi.ts": () => import("./vi-D1rLo6MX.js"), "./locales/zh.ts": () => import("./zh-BoLsjdfz.js") }), `./locales/${t}.ts`, 3)).default,
782
809
  providerName: "BeatUII18n"
783
810
  });
784
811
  export {
785
812
  Rt as B,
786
813
  Dt as C,
787
- Ct as I,
814
+ G as I,
788
815
  lt as L,
789
- Ot as T,
816
+ At as T,
790
817
  nt as _,
791
- G as a,
818
+ F as a,
792
819
  Lt as b,
793
- x as c,
820
+ Ot as c,
794
821
  et as d,
795
- E as e,
796
- T as f,
797
- wt as g,
798
- p as h,
799
- yt as i,
800
- ot as j,
801
- H as k,
802
- pt as l,
822
+ x as e,
823
+ E as f,
824
+ It as g,
825
+ V as h,
826
+ m as i,
827
+ Ct as j,
828
+ wt as k,
829
+ ot as l,
803
830
  St as m,
804
- Pt as n,
805
- q as o,
806
- jt as p,
807
- Tt as q,
831
+ H as n,
832
+ pt as o,
833
+ Pt as p,
834
+ q,
808
835
  at as r,
809
836
  ft as s,
810
837
  C as t,
811
- Et as u,
812
- st as v,
813
- Vt as w
838
+ jt as u,
839
+ Tt as v,
840
+ Et as w,
841
+ st as x,
842
+ Vt as y
814
843
  };