@tempots/beatui 0.61.8 → 0.61.11

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.
package/dist/index.es.js CHANGED
@@ -1,7 +1,7 @@
1
- import { prop as G, html as d, attr as o, computedOf as T, Fragment as R, OnDispose as oe, style as S, on as L, WithElement as ne, When as Q, Value as v, Use as ae, Empty as W, input as pe, emitValue as X, aria as E, OneOfValue as bn, Unless as gn, coalesce as Pe, ForEach as Le, Ensure as Ue, OneOfType as Et, dataAttr as lt, NotEmpty as mn, emitValueAsDate as hn, Portal as st, makeProviderMark as Ot, WithBrowserCtx as vn, renderWithContext as yn, WithProvider as wn, Task as xn, Provide as Nt, MapSignal as Rt, svg as mt, svgAttr as ht, delaySignal as kn } from "@tempots/dom";
1
+ import { prop as G, html as d, attr as o, computedOf as I, Fragment as U, OnDispose as oe, style as C, on as L, WithElement as ne, When as Q, Value as h, Use as ae, Empty as W, input as pe, emitValue as X, aria as M, OneOfValue as bn, Unless as gn, coalesce as Pe, ForEach as Le, Ensure as Ue, OneOfType as Et, dataAttr as lt, NotEmpty as mn, emitValueAsDate as hn, Portal as st, makeProviderMark as Ot, WithBrowserCtx as vn, renderWithContext as yn, WithProvider as wn, Task as xn, Provide as Nt, MapSignal as Rt, svg as mt, svgAttr as ht, delaySignal as kn } from "@tempots/dom";
2
2
  import { Use as Po } from "@tempots/dom";
3
3
  import { PopOver as Sn, ElementRect as Be, WindowSize as Cn, Query as Ut, Location as Ne, NavigationService as In, Anchor as it } from "@tempots/ui";
4
- import { i as le, t as Se, h as vt, e as ue, a as ie, I as te, b as ce, C as fe, B as yt, c as Ye, L as ct, j as wt, k as xt } from "./translations-BUTBIDsS.js";
4
+ import { i as le, t as Se, h as vt, e as ue, a as ie, I as ee, b as ce, C as fe, B as yt, c as Ye, L as ct, j as wt, k as xt } from "./translations-BUTBIDsS.js";
5
5
  import { x as Do, T as Ao, l as Vo, d as Bo, f as Mo, g as Eo, u as Oo, q as No, o as Ro, w as Uo, y as Fo, n as jo, v as Ho, m as Wo, p as zo, r as Yo, s as Zo } from "./translations-BUTBIDsS.js";
6
6
  import { g as ut } from "./colors-pQZlNrwM.js";
7
7
  import { b as qo, e as Jo, i as Ko, a as Qo, c as Xo, o as el, l as tl, m as nl, k as al, j as rl, n as ol, r as ll, s as sl, d as il, h as cl, t as ul } from "./colors-pQZlNrwM.js";
@@ -50,20 +50,20 @@ const qt = async (e, t = "") => {
50
50
  if (i === void 0 || isNaN(i))
51
51
  return n.set({ type: "undetermined" }), await r.blob();
52
52
  {
53
- const b = new Uint8Array(i);
53
+ const f = new Uint8Array(i);
54
54
  if (r.body == null)
55
55
  throw new Error("Response body is null");
56
- const k = r.body.getReader();
57
- let m = 0;
56
+ const S = r.body.getReader();
57
+ let g = 0;
58
58
  for (; ; ) {
59
- const { done: y, value: h } = await k.read();
59
+ const { done: y, value: b } = await S.read();
60
60
  if (y) break;
61
- b.set(h, m), m += h.length, n.set({
61
+ f.set(b, g), g += b.length, n.set({
62
62
  type: "progress",
63
- value: Math.min(m / i, 1)
63
+ value: Math.min(g / i, 1)
64
64
  });
65
65
  }
66
- return new Blob([b], {
66
+ return new Blob([f], {
67
67
  type: r.headers.get("content-type") ?? void 0
68
68
  });
69
69
  }
@@ -173,7 +173,7 @@ function br({
173
173
  }, ...i) {
174
174
  return d.span(
175
175
  o.class(
176
- T(
176
+ I(
177
177
  t,
178
178
  a,
179
179
  r,
@@ -188,7 +188,7 @@ function br({
188
188
  )
189
189
  ),
190
190
  o.style(
191
- T(
191
+ I(
192
192
  e,
193
193
  n
194
194
  )(
@@ -211,62 +211,62 @@ function gr({
211
211
  }) {
212
212
  const i = G(!1), c = G([]);
213
213
  let u = null, l = 0;
214
- const p = (f) => f.dataTransfer?.types.includes("Files") ?? !1, b = (f, C) => C === "*/*" ? !0 : C.split(",").map((D) => D.trim()).some((D) => {
214
+ const p = (v) => v.dataTransfer?.types.includes("Files") ?? !1, f = (v, w) => w === "*/*" ? !0 : w.split(",").map((D) => D.trim()).some((D) => {
215
215
  if (D === "*/*") return !0;
216
216
  if (D.endsWith("/*")) {
217
217
  const _ = D.slice(0, -2);
218
- return f.type.startsWith(_ + "/");
218
+ return v.type.startsWith(_ + "/");
219
219
  }
220
- return f.type === D || f.name.endsWith(D);
221
- }), k = (f) => {
222
- v.get(s) || p(f) && (f.preventDefault(), f.stopPropagation(), l++, l === 1 && (i.value = !0));
223
- }, m = (f) => {
224
- v.get(s) || p(f) && (f.preventDefault(), f.stopPropagation(), f.dataTransfer != null && (f.dataTransfer.dropEffect = "copy"));
225
- }, y = (f) => {
226
- v.get(s) || p(f) && (f.preventDefault(), f.stopPropagation(), l--, l === 0 && (i.value = !1));
227
- }, h = (f) => {
228
- if (v.get(s) || !p(f)) return;
229
- f.preventDefault(), f.stopPropagation(), l = 0, i.value = !1;
230
- const C = Array.from(f.dataTransfer?.files ?? []);
231
- if (C.length > 0) {
232
- const $ = v.get(t), D = C.filter(
233
- (I) => b(I, $)
234
- ), _ = C.filter(
235
- (I) => !D.includes(I)
220
+ return v.type === D || v.name.endsWith(D);
221
+ }), S = (v) => {
222
+ h.get(s) || p(v) && (v.preventDefault(), v.stopPropagation(), l++, l === 1 && (i.value = !0));
223
+ }, g = (v) => {
224
+ h.get(s) || p(v) && (v.preventDefault(), v.stopPropagation(), v.dataTransfer != null && (v.dataTransfer.dropEffect = "copy"));
225
+ }, y = (v) => {
226
+ h.get(s) || p(v) && (v.preventDefault(), v.stopPropagation(), l--, l === 0 && (i.value = !1));
227
+ }, b = (v) => {
228
+ if (h.get(s) || !p(v)) return;
229
+ v.preventDefault(), v.stopPropagation(), l = 0, i.value = !1;
230
+ const w = Array.from(v.dataTransfer?.files ?? []);
231
+ if (w.length > 0) {
232
+ const $ = h.get(t), D = w.filter(
233
+ (T) => f(T, $)
234
+ ), _ = w.filter(
235
+ (T) => !D.includes(T)
236
236
  );
237
- D.length > 0 && (c.value = D, e(D, "dragdrop")), _.length > 0 && r?.(C);
237
+ D.length > 0 && (c.value = D, e(D, "dragdrop")), _.length > 0 && r?.(w);
238
238
  }
239
239
  };
240
- typeof document < "u" && (document.addEventListener("dragenter", k), document.addEventListener("dragover", m), document.addEventListener("dragleave", y), document.addEventListener("drop", h));
241
- const x = () => {
242
- typeof document < "u" && (document.removeEventListener("dragenter", k), document.removeEventListener("dragover", m), document.removeEventListener("dragleave", y), document.removeEventListener("drop", h)), l = 0;
243
- }, w = () => {
240
+ typeof document < "u" && (document.addEventListener("dragenter", S), document.addEventListener("dragover", g), document.addEventListener("dragleave", y), document.addEventListener("drop", b));
241
+ const k = () => {
242
+ typeof document < "u" && (document.removeEventListener("dragenter", S), document.removeEventListener("dragover", g), document.removeEventListener("dragleave", y), document.removeEventListener("drop", b)), l = 0;
243
+ }, x = () => {
244
244
  u?.click();
245
- }, g = (f) => {
246
- const C = f.target, $ = Array.from(C.files ?? []);
247
- $.length > 0 && (c.value = $, e($, "click")), C.value = "";
245
+ }, m = (v) => {
246
+ const w = v.target, $ = Array.from(w.files ?? []);
247
+ $.length > 0 && (c.value = $, e($, "click")), w.value = "";
248
248
  };
249
- return R(
250
- oe(x),
249
+ return U(
250
+ oe(k),
251
251
  // Hidden file input for programmatic file selection
252
252
  d.input(
253
253
  o.type("file"),
254
254
  o.name("bui-page-drop-zone"),
255
255
  o.multiple(!0),
256
256
  o.accept(t),
257
- S.position("absolute"),
258
- S.opacity("0"),
259
- S.pointerEvents("none"),
260
- S.width("0"),
261
- S.height("0"),
262
- L.change(g),
263
- ne((f) => (u = f, oe(() => {
257
+ C.position("absolute"),
258
+ C.opacity("0"),
259
+ C.pointerEvents("none"),
260
+ C.width("0"),
261
+ C.height("0"),
262
+ L.change(m),
263
+ ne((v) => (u = v, oe(() => {
264
264
  u != null && (u.value = "");
265
265
  })))
266
266
  ),
267
267
  // Render overlay content to body when dragging (if content is provided)
268
268
  n != null ? Q(i, () => n({ files: c })) : null,
269
- a != null ? a({ isDragging: i, files: c, selectFiles: w }) : null
269
+ a != null ? a({ isDragging: i, files: c, selectFiles: x }) : null
270
270
  );
271
271
  }
272
272
  function Un(e, t, n, a, r, s) {
@@ -288,7 +288,7 @@ function mr({
288
288
  withRowBorders: c = !0,
289
289
  borderRadius: u
290
290
  } = {}, ...l) {
291
- const p = T(
291
+ const p = I(
292
292
  e,
293
293
  t,
294
294
  n,
@@ -296,27 +296,27 @@ function mr({
296
296
  i,
297
297
  c
298
298
  )(
299
- (m, y, h, x, w, g) => Un(
300
- m ?? "md",
299
+ (g, y, b, k, x, m) => Un(
300
+ g ?? "md",
301
301
  y ?? !1,
302
- h ?? !1,
302
+ b ?? !1,
303
+ k ?? !1,
303
304
  x ?? !1,
304
- w ?? !1,
305
- g ?? !0
305
+ m ?? !0
306
306
  )
307
- ), b = T(
307
+ ), f = I(
308
308
  n,
309
309
  a,
310
310
  s
311
- )((m, y, h) => {
312
- const x = ["bc-table-container"];
313
- return m && x.push("bc-table-container--sticky"), y && x.push("bc-table-container--full-width"), h && x.push("bc-table-container--with-table-border"), x.join(" ");
314
- }), k = T(u)(
315
- (m) => Fn(m)
311
+ )((g, y, b) => {
312
+ const k = ["bc-table-container"];
313
+ return g && k.push("bc-table-container--sticky"), y && k.push("bc-table-container--full-width"), b && k.push("bc-table-container--with-table-border"), k.join(" ");
314
+ }), S = I(u)(
315
+ (g) => Fn(g)
316
316
  );
317
317
  return d.div(
318
- o.class(b),
319
- o.style(k),
318
+ o.class(f),
319
+ o.style(S),
320
320
  d.table(o.class(p), ...l)
321
321
  );
322
322
  }
@@ -346,13 +346,13 @@ const Jt = ({
346
346
  disabled: s
347
347
  }) => d.span(
348
348
  o.class(
349
- T(
349
+ I(
350
350
  a ?? "md",
351
351
  s ?? !1
352
352
  )((i, c) => jn(i, c))
353
353
  ),
354
354
  o.style(
355
- T(t)(
355
+ I(t)(
356
356
  (i) => Hn(i ?? "base")
357
357
  )
358
358
  ),
@@ -367,7 +367,7 @@ const Jt = ({
367
367
  label: i.$.removeItem,
368
368
  color: "white",
369
369
  disabled: s,
370
- onClick: () => n?.(v.get(e))
370
+ onClick: () => n?.(h.get(e))
371
371
  },
372
372
  o.class("bc-tag__close")
373
373
  )
@@ -385,15 +385,15 @@ function Wn({
385
385
  options: {
386
386
  system: d.span(
387
387
  o.title("System"),
388
- te({ icon: "line-md:laptop", color: "gray" })
388
+ ee({ icon: "line-md:laptop", color: "gray" })
389
389
  ),
390
390
  light: d.span(
391
391
  o.title("Light"),
392
- te({ icon: "line-md:sunny-twotone-loop", color: "yellow" })
392
+ ee({ icon: "line-md:sunny-twotone-loop", color: "yellow" })
393
393
  ),
394
394
  dark: d.span(
395
395
  o.title("Dark"),
396
- te({
396
+ ee({
397
397
  icon: "line-md:sunny-outline-to-moon-alt-loop-transition",
398
398
  color: "blue"
399
399
  })
@@ -425,12 +425,12 @@ function zn({
425
425
  pe.color(
426
426
  ne((r) => (a = r, W)),
427
427
  o.value(e),
428
- S.width("4px"),
429
- S.height("4px"),
428
+ C.width("4px"),
429
+ C.height("4px"),
430
430
  t != null ? L.change(X(t)) : W,
431
431
  n != null ? L.input(X(n)) : W
432
432
  ),
433
- o.style(v.map(e, (r) => `background-color: ${r}`))
433
+ o.style(h.map(e, (r) => `background-color: ${r}`))
434
434
  )
435
435
  );
436
436
  }
@@ -467,46 +467,46 @@ function Ge(e) {
467
467
  closable: u = !0,
468
468
  arrow: l,
469
469
  role: p,
470
- hasPopup: b = "dialog"
470
+ hasPopup: f = "dialog"
471
471
  } = e;
472
- return Sn((k, m) => {
472
+ return Sn((S, g) => {
473
473
  const y = Re({
474
474
  initialStatus: "closed"
475
- }), h = he("flyout"), x = G(!1);
476
- let w = null, g = null, f = !1;
477
- function C() {
478
- D != null && (clearTimeout(D), D = null), I != null && (clearTimeout(I), I = null), g && (g(), g = null), w && (document.removeEventListener("keydown", w), w = null), x.set(!1), f = !1;
475
+ }), b = he("flyout"), k = G(!1);
476
+ let x = null, m = null, v = !1;
477
+ function w() {
478
+ D != null && (clearTimeout(D), D = null), T != null && (clearTimeout(T), T = null), m && (m(), m = null), x && (document.removeEventListener("keydown", x), x = null), k.set(!1), v = !1;
479
479
  }
480
480
  function $() {
481
- v.get(u) && (w = (O) => {
481
+ h.get(u) && (x = (O) => {
482
482
  O.key === "Escape" && V();
483
- }, document.addEventListener("keydown", w)), f = !0, x.set(!0), k({
483
+ }, document.addEventListener("keydown", x)), v = !0, k.set(!0), S({
484
484
  placement: n ?? "top",
485
485
  mainAxisOffset: s,
486
486
  crossAxisOffset: i,
487
487
  onClickOutside: () => {
488
- v.get(u) && V();
488
+ h.get(u) && V();
489
489
  },
490
490
  arrow: l,
491
491
  content: ne((O) => {
492
- y.setElement(O), g = Ze(() => {
493
- y.open(), g = null;
492
+ y.setElement(O), m = Ze(() => {
493
+ y.open(), m = null;
494
494
  });
495
- const B = (F) => {
496
- v.get(u) && F.key === "Escape" && (F.preventDefault(), F.stopPropagation(), V(), x.set(!1));
495
+ const E = (N) => {
496
+ h.get(u) && N.key === "Escape" && (N.preventDefault(), N.stopPropagation(), V(), k.set(!1));
497
497
  };
498
- return document.addEventListener("keydown", B, !0), R(
498
+ return document.addEventListener("keydown", E, !0), U(
499
499
  oe(() => {
500
- C(), document.removeEventListener("keydown", B, !0);
500
+ w(), document.removeEventListener("keydown", E, !0);
501
501
  }),
502
502
  o.class("bc-flyout-container"),
503
- o.id(h),
503
+ o.id(b),
504
504
  o.tabindex(-1),
505
505
  // Make focusable for screen readers
506
506
  d.div(
507
507
  o.class("bc-flyout"),
508
508
  ot({
509
- animation: v.map(n, Yn),
509
+ animation: h.map(n, Yn),
510
510
  status: y.status
511
511
  }),
512
512
  p ? o.role(p) : o.role("dialog"),
@@ -519,73 +519,73 @@ function Ge(e) {
519
519
  }
520
520
  let D = null;
521
521
  function _() {
522
- if (D != null && (clearTimeout(D), D = null), I != null && (clearTimeout(I), I = null), y.isOpened.value || y.isOpening.value || y.isStartOpening.value)
522
+ if (D != null && (clearTimeout(D), D = null), T != null && (clearTimeout(T), T = null), y.isOpened.value || y.isOpening.value || y.isStartOpening.value)
523
523
  return;
524
524
  if (y.isClosing.value || y.isStartClosing.value) {
525
525
  y.open();
526
526
  return;
527
527
  }
528
- const O = v.get(a);
528
+ const O = h.get(a);
529
529
  D = setTimeout(() => {
530
530
  D = null, $();
531
531
  }, O);
532
532
  }
533
- let I = null;
533
+ let T = null;
534
534
  function V() {
535
- if (D != null && (clearTimeout(D), D = null), I != null && (clearTimeout(I), I = null), x.set(!1), g && (g(), g = null, f)) {
536
- m(), C();
535
+ if (D != null && (clearTimeout(D), D = null), T != null && (clearTimeout(T), T = null), k.set(!1), m && (m(), m = null, v)) {
536
+ g(), w();
537
537
  return;
538
538
  }
539
- const O = v.get(r);
540
- I = setTimeout(() => {
541
- I = null, y.close(), y.listenOnClosed(() => {
542
- m(), C();
539
+ const O = h.get(r);
540
+ T = setTimeout(() => {
541
+ T = null, y.close(), y.listenOnClosed(() => {
542
+ g(), w();
543
543
  });
544
544
  }, O);
545
545
  }
546
546
  return ne((O) => {
547
- const B = () => {
548
- _(), x.set(!0);
549
- }, F = () => {
550
- V(), x.set(!1);
551
- }, ee = R(
552
- E.expanded(x),
553
- E.controls(h),
554
- E.haspopup(
555
- b
547
+ const E = () => {
548
+ _(), k.set(!0);
549
+ }, N = () => {
550
+ V(), k.set(!1);
551
+ }, te = U(
552
+ M.expanded(k),
553
+ M.controls(b),
554
+ M.haspopup(
555
+ f
556
556
  )
557
557
  );
558
- return typeof c == "function" ? R(
559
- ee,
560
- c(B, F)
561
- ) : R(
562
- ee,
558
+ return typeof c == "function" ? U(
559
+ te,
560
+ c(E, N)
561
+ ) : U(
562
+ te,
563
563
  bn(c, {
564
- "hover-focus": () => R(
565
- L.mouseenter(() => B()),
566
- L.mouseleave(() => F()),
567
- L.focus(() => B()),
568
- L.blur(() => F())
564
+ "hover-focus": () => U(
565
+ L.mouseenter(() => E()),
566
+ L.mouseleave(() => N()),
567
+ L.focus(() => E()),
568
+ L.blur(() => N())
569
569
  ),
570
- hover: () => R(
571
- L.mouseenter(() => B()),
572
- L.mouseleave(() => F())
570
+ hover: () => U(
571
+ L.mouseenter(() => E()),
572
+ L.mouseleave(() => N())
573
573
  ),
574
- focus: () => R(
575
- L.focus(() => B()),
576
- L.blur(() => F())
574
+ focus: () => U(
575
+ L.focus(() => E()),
576
+ L.blur(() => N())
577
577
  ),
578
578
  click: () => {
579
- function U() {
579
+ function F() {
580
580
  document.removeEventListener("click", Y);
581
581
  }
582
582
  function Y() {
583
- U(), F();
583
+ F(), N();
584
584
  }
585
- return R(
586
- oe(U),
585
+ return U(
586
+ oe(F),
587
587
  L.click(() => {
588
- B(), Ze(() => {
588
+ E(), Ze(() => {
589
589
  document.addEventListener("click", Y, {
590
590
  once: !0
591
591
  });
@@ -620,41 +620,41 @@ function yr({
620
620
  iconSize: u = "md",
621
621
  backgroundColor: l,
622
622
  borderColor: p,
623
- titleColor: b,
624
- descriptionColor: k
623
+ titleColor: f,
624
+ descriptionColor: S
625
625
  }) {
626
- const m = s != null;
626
+ const g = s != null;
627
627
  return d.div(
628
628
  o.class(
629
- T(
629
+ I(
630
630
  a,
631
631
  r,
632
632
  i
633
633
  )(
634
- (y, h, x) => Zn(
634
+ (y, b, k) => Zn(
635
635
  y ?? !1,
636
- h ?? !1,
637
- x ?? "md",
638
- m
636
+ b ?? !1,
637
+ k ?? "md",
638
+ g
639
639
  )
640
640
  )
641
641
  ),
642
642
  o.style(
643
- T(
643
+ I(
644
644
  l,
645
645
  p,
646
- b,
647
- k
646
+ f,
647
+ S
648
648
  )(
649
- (y, h, x, w) => Gn(y, h, x, w)
649
+ (y, b, k, x) => Gn(y, b, k, x)
650
650
  )
651
651
  ),
652
652
  Q(
653
- m,
654
- () => R(
653
+ g,
654
+ () => U(
655
655
  gn(
656
656
  r,
657
- () => R(
657
+ () => U(
658
658
  L.click(() => s?.()),
659
659
  o.tabindex(0)
660
660
  )
@@ -662,11 +662,11 @@ function yr({
662
662
  o.role("button")
663
663
  )
664
664
  ),
665
- E.disabled(r),
665
+ M.disabled(r),
666
666
  // Icon container
667
667
  d.div(
668
668
  o.class("bc-action-card__icon"),
669
- te({ icon: e, size: u, color: c })
669
+ ee({ icon: e, size: u, color: c })
670
670
  ),
671
671
  // Content container
672
672
  d.div(
@@ -714,7 +714,7 @@ function Kt(e, { breakpoints: t, mode: n = "viewport" }) {
714
714
  ([i, c]) => [c, i]
715
715
  )].sort((i, c) => i[0] - c[0]), s = (i) => {
716
716
  const c = i.map(({ width: l }) => {
717
- const p = r.findIndex((b) => b[0] > l) - 1;
717
+ const p = r.findIndex((f) => f[0] > l) - 1;
718
718
  return p >= 0 ? { width: l, breakpoint: r[p][1] } : r.length > 0 && l >= r[0][0] ? { width: l, breakpoint: r[0][1] } : { width: l, breakpoint: r[0][1] };
719
719
  });
720
720
  return e({
@@ -773,16 +773,16 @@ function be(e, t) {
773
773
  return `bc-panel ${(Array.isArray(e) ? e : [e]).map((a) => `bc-panel--side-${a}`).join(" ")} bc-panel--shadow-${t}`;
774
774
  }
775
775
  function ke(e) {
776
- const t = v.toSignal(e).map(
776
+ const t = h.toSignal(e).map(
777
777
  (a) => ue(a, "lighter", "light")
778
- ), n = v.toSignal(e).map(
778
+ ), n = h.toSignal(e).map(
779
779
  (a) => ue(a, "lighter", "dark")
780
780
  );
781
- return R(
782
- S.variable("--panel-bg", t.$.backgroundColor),
783
- S.variable("--panel-text", t.$.textColor),
784
- S.variable("--panel-bg-dark", n.$.backgroundColor),
785
- S.variable("--panel-text-dark", n.$.textColor)
781
+ return U(
782
+ C.variable("--panel-bg", t.$.backgroundColor),
783
+ C.variable("--panel-text", t.$.textColor),
784
+ C.variable("--panel-bg-dark", n.$.backgroundColor),
785
+ C.variable("--panel-text-dark", n.$.textColor)
786
786
  );
787
787
  }
788
788
  const me = {
@@ -887,13 +887,13 @@ function ea({
887
887
  ];
888
888
  const p = [];
889
889
  p.push("1fr");
890
- const b = [];
891
- return a.banner && (b.push(a.banner[u] + "px"), l[0][1] = "banner"), (a.header || n.menu || n.aside) && (b.push(
890
+ const f = [];
891
+ return a.banner && (f.push(a.banner[u] + "px"), l[0][1] = "banner"), (a.header || n.menu || n.aside) && (f.push(
892
892
  (a.header?.[u] ?? me.header[u]) + "px"
893
- ), l[1][1] = "header"), a.mainHeader && (b.push(a.mainHeader[u] + "px"), l[2][1] = "mainHeader"), b.push("1fr"), l[3][1] = "main", a.mainFooter && (b.push(a.mainFooter[u] + "px"), l[4][1] = "mainFooter"), a.footer && (b.push(a.footer[u] + "px"), l[5][1] = "footer"), l = tt(l), {
893
+ ), l[1][1] = "header"), a.mainHeader && (f.push(a.mainHeader[u] + "px"), l[2][1] = "mainHeader"), f.push("1fr"), l[3][1] = "main", a.mainFooter && (f.push(a.mainFooter[u] + "px"), l[4][1] = "mainFooter"), a.footer && (f.push(a.footer[u] + "px"), l[5][1] = "footer"), l = tt(l), {
894
894
  columns: p.join(" "),
895
- rows: b.join(" "),
896
- areas: l.map((m) => `"${m.join(" ")}"`).join(`
895
+ rows: f.join(" "),
896
+ areas: l.map((g) => `"${g.join(" ")}"`).join(`
897
897
  `),
898
898
  displayMenu: !1,
899
899
  displayAside: !1,
@@ -912,13 +912,13 @@ function ea({
912
912
  ];
913
913
  const p = [];
914
914
  n.menu && (p.push(n.menu[u] + "px"), l[2][0] = "?menu", l[3][0] = "menu", l[4][0] = "?menu"), p.push("1fr");
915
- const b = [];
916
- return a.banner && (b.push(a.banner[u] + "px"), l[0][0] = "?banner", l[0][1] = "banner"), (a.header || n.aside) && (b.push(
915
+ const f = [];
916
+ return a.banner && (f.push(a.banner[u] + "px"), l[0][0] = "?banner", l[0][1] = "banner"), (a.header || n.aside) && (f.push(
917
917
  (a.header?.[u] ?? me.header[u]) + "px"
918
- ), l[1][0] = "?header", l[1][1] = "header"), a.mainHeader && (b.push(a.mainHeader[u] + "px"), l[2][1] = "mainHeader"), b.push("1fr"), l[3][1] = "main", a.mainFooter && (b.push(a.mainFooter[u] + "px"), l[4][1] = "mainFooter"), a.footer && (b.push(a.footer[u] + "px"), l[5][0] = "?footer", l[5][1] = "footer"), l = tt(l), {
918
+ ), l[1][0] = "?header", l[1][1] = "header"), a.mainHeader && (f.push(a.mainHeader[u] + "px"), l[2][1] = "mainHeader"), f.push("1fr"), l[3][1] = "main", a.mainFooter && (f.push(a.mainFooter[u] + "px"), l[4][1] = "mainFooter"), a.footer && (f.push(a.footer[u] + "px"), l[5][0] = "?footer", l[5][1] = "footer"), l = tt(l), {
919
919
  columns: p.join(" "),
920
- rows: b.join(" "),
921
- areas: l.map((m) => `"${m.join(" ")}"`).join(`
920
+ rows: f.join(" "),
921
+ areas: l.map((g) => `"${g.join(" ")}"`).join(`
922
922
  `),
923
923
  displayMenu: !0,
924
924
  displayAside: !1,
@@ -937,11 +937,11 @@ function ea({
937
937
  ];
938
938
  const p = [];
939
939
  n.menu && (p.push(n.menu[u] + "px"), l[2][0] = "?menu", l[3][0] = "menu", l[4][0] = "?menu"), p.push("1fr"), n.aside && (p.push(n.aside[u] + "px"), l[2][2] = "?aside", l[3][2] = "aside", l[4][2] = "?aside");
940
- const b = [];
941
- return a.banner && (b.push(a.banner[u] + "px"), l[0][0] = "?banner", l[0][1] = "banner", l[0][2] = "?banner"), a.header && (b.push(a.header[u] + "px"), l[1][0] = "?header", l[1][1] = "header", l[1][2] = "?header"), a.mainHeader && (b.push(a.mainHeader[u] + "px"), l[2][1] = "mainHeader"), b.push("1fr"), l[3][1] = "main", a.mainFooter && (b.push(a.mainFooter[u] + "px"), l[4][1] = "mainFooter"), a.footer && (b.push(a.footer[u] + "px"), l[5][0] = "?footer", l[5][1] = "footer", l[5][2] = "?footer"), l = tt(l), {
940
+ const f = [];
941
+ return a.banner && (f.push(a.banner[u] + "px"), l[0][0] = "?banner", l[0][1] = "banner", l[0][2] = "?banner"), a.header && (f.push(a.header[u] + "px"), l[1][0] = "?header", l[1][1] = "header", l[1][2] = "?header"), a.mainHeader && (f.push(a.mainHeader[u] + "px"), l[2][1] = "mainHeader"), f.push("1fr"), l[3][1] = "main", a.mainFooter && (f.push(a.mainFooter[u] + "px"), l[4][1] = "mainFooter"), a.footer && (f.push(a.footer[u] + "px"), l[5][0] = "?footer", l[5][1] = "footer", l[5][2] = "?footer"), l = tt(l), {
942
942
  columns: p.join(" "),
943
- rows: b.join(" "),
944
- areas: l.map((m) => `"${m.join(" ")}"`).join(`
943
+ rows: f.join(" "),
944
+ areas: l.map((g) => `"${g.join(" ")}"`).join(`
945
945
  `),
946
946
  displayMenu: !0,
947
947
  displayAside: !0,
@@ -996,37 +996,37 @@ function kr({
996
996
  vertical: a,
997
997
  horizontal: r,
998
998
  is: c
999
- }), l = i.map(u), p = r.header != null || a.menu != null || a.aside != null, b = T(
999
+ }), l = i.map(u), p = r.header != null || a.menu != null || a.aside != null, f = I(
1000
1000
  a.aside != null,
1001
1001
  l
1002
- )((g, { displayAside: f }) => g && !f), k = T(
1002
+ )((m, { displayAside: v }) => m && !v), S = I(
1003
1003
  a.menu != null,
1004
1004
  l
1005
- )((g, { displayMenu: f }) => g && !f), m = Re(), y = Re(), h = G(0), x = T(
1005
+ )((m, { displayMenu: v }) => m && !v), g = Re(), y = Re(), b = G(0), k = I(
1006
1006
  a.menu != null,
1007
1007
  l,
1008
- m.display
1009
- )(aa), w = T(
1008
+ g.display
1009
+ )(aa), x = I(
1010
1010
  a.aside != null,
1011
1011
  l,
1012
1012
  y.display
1013
1013
  )(ra);
1014
1014
  return d.div(
1015
- S.display("grid"),
1016
- S.height("100%"),
1017
- S.width("100%"),
1018
- S.gridTemplateColumns(l.$.columns),
1019
- S.gridTemplateRows(l.$.rows),
1020
- S.gridTemplateAreas(l.$.areas),
1021
- S.gridColumnGap("0"),
1022
- S.gridRowGap("0"),
1015
+ C.display("grid"),
1016
+ C.height("100%"),
1017
+ C.width("100%"),
1018
+ C.gridTemplateColumns(l.$.columns),
1019
+ C.gridTemplateRows(l.$.rows),
1020
+ C.gridTemplateAreas(l.$.areas),
1021
+ C.gridColumnGap("0"),
1022
+ C.gridRowGap("0"),
1023
1023
  n.banner ? d.header(
1024
1024
  o.class(
1025
1025
  be("none", n.banner.shadow ?? "none")
1026
1026
  ),
1027
1027
  ke(n.banner.color ?? "white"),
1028
- S.height("100%"),
1029
- S.gridArea("banner"),
1028
+ C.height("100%"),
1029
+ C.gridArea("banner"),
1030
1030
  n.banner.content
1031
1031
  ) : null,
1032
1032
  d.header(
@@ -1034,47 +1034,47 @@ function kr({
1034
1034
  be("bottom", n.header?.shadow ?? "none")
1035
1035
  ),
1036
1036
  ke(n.header?.color ?? "white"),
1037
- S.zIndex("20"),
1038
- S.display(p ? "block" : "none"),
1039
- S.gridArea("header"),
1040
- Be((g) => (g.$.bottom.feedProp(h), null)),
1037
+ C.zIndex("20"),
1038
+ C.display(p ? "block" : "none"),
1039
+ C.gridArea("header"),
1040
+ Be((m) => (m.$.bottom.feedProp(b), null)),
1041
1041
  d.div(
1042
- S.display("flex"),
1043
- S.height("100%"),
1042
+ C.display("flex"),
1043
+ C.height("100%"),
1044
1044
  d.div(
1045
- S.display(
1046
- k.map((g) => g ? "flex" : "none")
1045
+ C.display(
1046
+ S.map((m) => m ? "flex" : "none")
1047
1047
  ),
1048
- S.alignItems("center"),
1049
- S.justifyContent("center"),
1050
- S.height("100%"),
1051
- S.width("60px"),
1048
+ C.alignItems("center"),
1049
+ C.justifyContent("center"),
1050
+ C.height("100%"),
1051
+ C.width("60px"),
1052
1052
  yt(
1053
1053
  {
1054
- onClick: () => m.toggle(),
1054
+ onClick: () => g.toggle(),
1055
1055
  variant: "light",
1056
1056
  color: "base"
1057
1057
  },
1058
- E.label(s.$.toggleMenu),
1059
- te({
1060
- icon: m.display.map(
1061
- (g) => g ? "line-md/menu-to-close-alt-transition" : "line-md/close-to-menu-alt-transition"
1058
+ M.label(s.$.toggleMenu),
1059
+ ee({
1060
+ icon: g.display.map(
1061
+ (m) => m ? "line-md/menu-to-close-alt-transition" : "line-md/close-to-menu-alt-transition"
1062
1062
  )
1063
1063
  })
1064
1064
  )
1065
1065
  ),
1066
1066
  d.div(
1067
- S.height("100%"),
1068
- S.flexGrow("1"),
1067
+ C.height("100%"),
1068
+ C.flexGrow("1"),
1069
1069
  n.header?.content
1070
1070
  ),
1071
1071
  d.div(
1072
- S.alignItems("center"),
1073
- S.justifyContent("center"),
1074
- S.height("100%"),
1075
- S.width("60px"),
1076
- S.display(
1077
- b.map((g) => g ? "flex" : "none")
1072
+ C.alignItems("center"),
1073
+ C.justifyContent("center"),
1074
+ C.height("100%"),
1075
+ C.width("60px"),
1076
+ C.display(
1077
+ f.map((m) => m ? "flex" : "none")
1078
1078
  ),
1079
1079
  yt(
1080
1080
  {
@@ -1083,13 +1083,13 @@ function kr({
1083
1083
  variant: "light",
1084
1084
  color: "base"
1085
1085
  },
1086
- E.label(s.$.toggleAside),
1087
- te(
1086
+ M.label(s.$.toggleAside),
1087
+ ee(
1088
1088
  { icon: "line-md/chevron-left" },
1089
1089
  o.style("transition: transform 0.2s ease-in-out"),
1090
1090
  o.style(
1091
1091
  y.display.map(
1092
- (g) => `transform: rotate(${g ? 180 : 0}deg)`
1092
+ (m) => `transform: rotate(${m ? 180 : 0}deg)`
1093
1093
  )
1094
1094
  )
1095
1095
  )
@@ -1098,15 +1098,15 @@ function kr({
1098
1098
  )
1099
1099
  ),
1100
1100
  n.menu ? d.nav(
1101
- ne((g) => m.setElement(g)),
1102
- S.zIndex("10"),
1101
+ ne((m) => g.setElement(m)),
1102
+ C.zIndex("10"),
1103
1103
  // Add ARIA attributes for navigation landmark
1104
- E.label(s.$.mainNavigation),
1104
+ M.label(s.$.mainNavigation),
1105
1105
  o.role("navigation"),
1106
- S.overflow("hidden"),
1106
+ C.overflow("hidden"),
1107
1107
  o.class(
1108
- x.map(
1109
- (g) => g === "float" ? be(
1108
+ k.map(
1109
+ (m) => m === "float" ? be(
1110
1110
  "right",
1111
1111
  n.menu?.shadow ?? "md"
1112
1112
  ) : be(
@@ -1116,40 +1116,40 @@ function kr({
1116
1116
  )
1117
1117
  ),
1118
1118
  ke(n.menu?.color ?? "white"),
1119
- S.height(
1120
- x.map(
1121
- (g) => g === "float" ? "auto" : "100%"
1119
+ C.height(
1120
+ k.map(
1121
+ (m) => m === "float" ? "auto" : "100%"
1122
1122
  )
1123
1123
  ),
1124
- S.overflow("hidden"),
1125
- S.gridArea("menu"),
1126
- S.display(
1127
- T(
1128
- x,
1129
- m.status
1130
- )((g, f) => g === "none" && f === "closed" ? "none" : "block")
1124
+ C.overflow("hidden"),
1125
+ C.gridArea("menu"),
1126
+ C.display(
1127
+ I(
1128
+ k,
1129
+ g.status
1130
+ )((m, v) => m === "none" && v === "closed" ? "none" : "block")
1131
1131
  ),
1132
- S.position(
1133
- T(
1134
- x,
1135
- m.status
1136
- )((g, f) => g === "float" || g === "none" && f !== "closed" ? "fixed" : "initial")
1132
+ C.position(
1133
+ I(
1134
+ k,
1135
+ g.status
1136
+ )((m, v) => m === "float" || m === "none" && v !== "closed" ? "fixed" : "initial")
1137
1137
  ),
1138
- S.top(h.map((g) => `${g}px`)),
1138
+ C.top(b.map((m) => `${m}px`)),
1139
1139
  ot({
1140
1140
  animation: { slide: "right" },
1141
- status: T(
1142
- x,
1143
- m.status
1144
- )((g, f) => g === "block" ? "opened" : f)
1141
+ status: I(
1142
+ k,
1143
+ g.status
1144
+ )((m, v) => m === "block" ? "opened" : v)
1145
1145
  }),
1146
- S.width(Pe(n.menu?.width, l.$.menuWidth)),
1147
- S.bottom("0"),
1146
+ C.width(Pe(n.menu?.width, l.$.menuWidth)),
1147
+ C.bottom("0"),
1148
1148
  n.menu?.content
1149
1149
  ) : null,
1150
1150
  n.mainHeader ? d.header(
1151
- S.height("100%"),
1152
- S.gridArea("mainHeader"),
1151
+ C.height("100%"),
1152
+ C.gridArea("mainHeader"),
1153
1153
  o.class(
1154
1154
  be(
1155
1155
  "none",
@@ -1160,9 +1160,9 @@ function kr({
1160
1160
  n.mainHeader.content
1161
1161
  ) : null,
1162
1162
  d.main(
1163
- S.height("100%"),
1164
- S.overflow("hidden"),
1165
- S.gridArea("main"),
1163
+ C.height("100%"),
1164
+ C.overflow("hidden"),
1165
+ C.gridArea("main"),
1166
1166
  o.class(
1167
1167
  be("none", n.main?.shadow ?? "none")
1168
1168
  ),
@@ -1170,8 +1170,8 @@ function kr({
1170
1170
  n.main.content
1171
1171
  ),
1172
1172
  n.mainFooter ? d.footer(
1173
- S.height("100%"),
1174
- S.gridArea("mainFooter"),
1173
+ C.height("100%"),
1174
+ C.gridArea("mainFooter"),
1175
1175
  o.class(
1176
1176
  be(
1177
1177
  "none",
@@ -1182,52 +1182,52 @@ function kr({
1182
1182
  n.mainFooter.content
1183
1183
  ) : null,
1184
1184
  n.aside ? d.aside(
1185
- ne((g) => {
1186
- y.setElement(g);
1185
+ ne((m) => {
1186
+ y.setElement(m);
1187
1187
  }),
1188
- S.zIndex("10"),
1188
+ C.zIndex("10"),
1189
1189
  // Add ARIA attributes for aside landmark
1190
- E.label(s.$.sidebar),
1190
+ M.label(s.$.sidebar),
1191
1191
  o.role("complementary"),
1192
1192
  o.class(
1193
- w.map(
1194
- (g) => g === "float" ? be("left", "md") : be("left", "none")
1193
+ x.map(
1194
+ (m) => m === "float" ? be("left", "md") : be("left", "none")
1195
1195
  )
1196
1196
  ),
1197
1197
  ke("white"),
1198
- S.height("100%"),
1199
- S.gridArea("aside"),
1200
- S.display(
1201
- T(
1202
- w,
1198
+ C.height("100%"),
1199
+ C.gridArea("aside"),
1200
+ C.display(
1201
+ I(
1202
+ x,
1203
1203
  y.status
1204
- )((g, f) => g === "none" && f === "closed" ? "none" : "block")
1204
+ )((m, v) => m === "none" && v === "closed" ? "none" : "block")
1205
1205
  ),
1206
- S.position(
1207
- T(
1208
- w,
1206
+ C.position(
1207
+ I(
1208
+ x,
1209
1209
  y.status
1210
- )((g, f) => g === "float" || g === "none" && f !== "closed" ? "fixed" : "initial")
1210
+ )((m, v) => m === "float" || m === "none" && v !== "closed" ? "fixed" : "initial")
1211
1211
  ),
1212
- S.top(h.map((g) => `${g}px`)),
1212
+ C.top(b.map((m) => `${m}px`)),
1213
1213
  ot({
1214
1214
  animation: { slide: "left" },
1215
- status: T(
1216
- w,
1215
+ status: I(
1216
+ x,
1217
1217
  y.status
1218
- )((g, f) => g === "block" ? "opened" : f)
1218
+ )((m, v) => m === "block" ? "opened" : v)
1219
1219
  }),
1220
- S.width(
1220
+ C.width(
1221
1221
  Pe(n.aside?.width, l.$.asideWidth)
1222
1222
  ),
1223
- S.bottom(h.map((g) => `${g}px`)),
1223
+ C.bottom(b.map((m) => `${m}px`)),
1224
1224
  n.aside.content
1225
1225
  ) : null,
1226
1226
  n.footer ? d.footer(
1227
1227
  o.class(be("top", "none")),
1228
1228
  ke("white"),
1229
- S.height("100%"),
1230
- S.gridArea("footer"),
1229
+ C.height("100%"),
1230
+ C.gridArea("footer"),
1231
1231
  n.footer.content
1232
1232
  ) : null
1233
1233
  );
@@ -1246,31 +1246,31 @@ function oa(e) {
1246
1246
  }
1247
1247
  function Cr({ gap: e = "lg" } = {}, ...t) {
1248
1248
  return d.div(
1249
- o.class(T(e)((n) => oa(n ?? "lg"))),
1249
+ o.class(I(e)((n) => oa(n ?? "lg"))),
1250
1250
  ...t
1251
1251
  );
1252
1252
  }
1253
1253
  function la({ open: e }, ...t) {
1254
1254
  return ne((n) => {
1255
1255
  const { status: a, setOpen: r, dispose: s } = Re({
1256
- initialStatus: v.get(e) ? "opened" : "closed",
1256
+ initialStatus: h.get(e) ? "opened" : "closed",
1257
1257
  element: n
1258
1258
  });
1259
- return v.on(e, r), Be((i) => {
1259
+ return h.on(e, r), Be((i) => {
1260
1260
  const c = G(null);
1261
- return T(
1261
+ return I(
1262
1262
  a,
1263
1263
  i.$.height
1264
1264
  )((l, p) => l === "opened" && p > 0 ? p : null).on((l) => {
1265
1265
  l != null && c.set(l);
1266
1266
  }), a.on((l) => {
1267
1267
  if (n && l === "start-opening") {
1268
- const p = n.style.height, b = n.style.transition;
1268
+ const p = n.style.height, f = n.style.transition;
1269
1269
  n.style.transition = "none", n.style.height = "auto", n.offsetHeight;
1270
- const k = n.scrollHeight;
1271
- k > 0 && c.set(k), n.style.height = p, n.style.transition = b, n.offsetHeight;
1270
+ const S = n.scrollHeight;
1271
+ S > 0 && c.set(S), n.style.height = p, n.style.transition = f, n.offsetHeight;
1272
1272
  }
1273
- }), R(
1273
+ }), U(
1274
1274
  oe(s),
1275
1275
  o.style(
1276
1276
  c.map((l) => `--collapse-height: ${l != null ? `${l}px` : "auto"}`)
@@ -1285,7 +1285,7 @@ function sa(e) {
1285
1285
  return `${e}px`;
1286
1286
  }
1287
1287
  function $t(e) {
1288
- return v.map(e, sa);
1288
+ return h.map(e, sa);
1289
1289
  }
1290
1290
  function Ir({
1291
1291
  body: e,
@@ -1299,152 +1299,152 @@ function Ir({
1299
1299
  footerHeight: u = 0,
1300
1300
  bottomStart: l,
1301
1301
  bottomEnd: p,
1302
- sidebarStart: b,
1303
- sidebarStartWidth: k = 0,
1304
- sidebarEnd: m,
1302
+ sidebarStart: f,
1303
+ sidebarStartWidth: S = 0,
1304
+ sidebarEnd: g,
1305
1305
  sidebarEndWidth: y = 0,
1306
- anchorMode: h = "container-edge"
1306
+ anchorMode: b = "container-edge"
1307
1307
  }) {
1308
- const x = G(0n), w = G(0n), g = $t(r), f = $t(k), C = G(16);
1308
+ const k = G(0n), x = G(0n), m = $t(r), v = $t(S), w = G(16);
1309
1309
  return d.div(
1310
1310
  o.class("bc-nine-slice-container"),
1311
1311
  Be(($) => {
1312
- const D = T(
1312
+ const D = I(
1313
1313
  $.$.width,
1314
- k,
1314
+ S,
1315
1315
  y
1316
- )((A, N, K) => A - N - K), _ = T(
1316
+ )((A, R, K) => A - R - K), _ = I(
1317
1317
  $.$.height,
1318
1318
  r,
1319
1319
  u
1320
- )((A, N, K) => A - N - K), I = T(
1320
+ )((A, R, K) => A - R - K), T = I(
1321
1321
  t,
1322
1322
  D
1323
- )((A, N) => A > BigInt(N)), V = T(
1323
+ )((A, R) => A > BigInt(R)), V = I(
1324
1324
  n,
1325
1325
  _
1326
- )((A, N) => A > BigInt(N)), O = T(
1326
+ )((A, R) => A > BigInt(R)), O = I(
1327
1327
  D,
1328
1328
  V,
1329
- C
1330
- )((A, N, K) => N ? A - K : A), B = T(
1329
+ w
1330
+ )((A, R, K) => R ? A - K : A), E = I(
1331
1331
  _,
1332
- I,
1333
- C
1334
- )((A, N, K) => N ? A - K : A), F = T(
1332
+ T,
1333
+ w
1334
+ )((A, R, K) => R ? A - K : A), N = I(
1335
1335
  t,
1336
1336
  O
1337
- )((A, N) => Number(A / BigInt(Math.max(1, N)))), ee = T(
1337
+ )((A, R) => Number(A / BigInt(Math.max(1, R)))), te = I(
1338
1338
  n,
1339
- B
1340
- )((A, N) => Number(A / BigInt(Math.max(1, N)))), H = v.map(
1341
- h,
1339
+ E
1340
+ )((A, R) => Number(A / BigInt(Math.max(1, R)))), H = h.map(
1341
+ b,
1342
1342
  (A) => A === "body-end" || A === "body-end-bottom"
1343
- ), U = Q(
1343
+ ), F = Q(
1344
1344
  H,
1345
- () => S.left(
1346
- T(
1347
- k,
1345
+ () => C.left(
1346
+ I(
1347
+ S,
1348
1348
  t,
1349
1349
  O,
1350
1350
  y
1351
- )((A, N, K, P) => {
1352
- const M = A + Number(N), j = A + K, J = Math.min(M, j);
1351
+ )((A, R, K, P) => {
1352
+ const B = A + Number(R), j = A + K, J = Math.min(B, j);
1353
1353
  return `${Math.max(A + P, J)}px`;
1354
1354
  })
1355
1355
  ),
1356
- () => S.right("0")
1357
- ), Y = v.map(
1358
- h,
1356
+ () => C.right("0")
1357
+ ), Y = h.map(
1358
+ b,
1359
1359
  (A) => A === "body-bottom" || A === "body-end-bottom"
1360
1360
  ), se = Q(
1361
1361
  Y,
1362
- () => S.top(
1363
- T(
1362
+ () => C.top(
1363
+ I(
1364
1364
  r,
1365
1365
  n,
1366
- B,
1366
+ E,
1367
1367
  u
1368
- )((A, N, K, P) => {
1369
- const M = A + Number(N), j = A + K, J = Math.min(M, j);
1368
+ )((A, R, K, P) => {
1369
+ const B = A + Number(R), j = A + K, J = Math.min(B, j);
1370
1370
  return `${Math.max(A + P, J)}px`;
1371
1371
  })
1372
1372
  ),
1373
- () => S.bottom("0")
1374
- ), Ie = T(
1373
+ () => C.bottom("0")
1374
+ ), Ie = I(
1375
1375
  V,
1376
- C
1377
- )((A, N) => A ? `${N}px` : "0"), q = T(
1378
- I,
1379
- C
1380
- )((A, N) => A ? `${N}px` : "0"), de = S.transform(
1381
- T(
1382
- w,
1376
+ w
1377
+ )((A, R) => A ? `${R}px` : "0"), q = I(
1378
+ T,
1379
+ w
1380
+ )((A, R) => A ? `${R}px` : "0"), de = C.transform(
1381
+ I(
1383
1382
  x,
1384
- I,
1383
+ k,
1384
+ T,
1385
1385
  V
1386
- )((A, N, K, P) => {
1387
- const M = K ? `translateX(-${A}px)` : "", j = P ? `translateY(-${N}px)` : "";
1388
- return `${M} ${j}`.trim() || "none";
1386
+ )((A, R, K, P) => {
1387
+ const B = K ? `translateX(-${A}px)` : "", j = P ? `translateY(-${R}px)` : "";
1388
+ return `${B} ${j}`.trim() || "none";
1389
1389
  })
1390
- ), ye = S.transform(
1391
- w.map((A) => `translateX(-${A}px)`)
1392
- ), we = S.transform(
1393
- x.map((A) => `translateY(-${A}px)`)
1394
- ), De = T(
1390
+ ), ye = C.transform(
1391
+ x.map((A) => `translateX(-${A}px)`)
1392
+ ), we = C.transform(
1393
+ k.map((A) => `translateY(-${A}px)`)
1394
+ ), De = I(
1395
1395
  n,
1396
- B
1397
- )((A, N) => A - BigInt(Math.max(1, N))), Ae = T(
1396
+ E
1397
+ )((A, R) => A - BigInt(Math.max(1, R))), Ae = I(
1398
1398
  t,
1399
1399
  O
1400
- )((A, N) => A - BigInt(Math.max(1, N)));
1400
+ )((A, R) => A - BigInt(Math.max(1, R)));
1401
1401
  let z = null, Te = 0, $e = 0;
1402
1402
  const Ke = () => {
1403
- const A = De.value, N = Ae.value, K = V.value, P = I.value;
1403
+ const A = De.value, R = Ae.value, K = V.value, P = T.value;
1404
1404
  if (K && $e !== 0) {
1405
- const M = It(
1405
+ const B = It(
1406
1406
  je(0n, A),
1407
1407
  je(
1408
1408
  0n,
1409
- x.value + BigInt(Math.round($e))
1409
+ k.value + BigInt(Math.round($e))
1410
1410
  )
1411
1411
  );
1412
- x.set(M);
1412
+ k.set(B);
1413
1413
  }
1414
1414
  if (P && Te !== 0) {
1415
- const M = It(
1416
- je(0n, N),
1415
+ const B = It(
1416
+ je(0n, R),
1417
1417
  je(
1418
1418
  0n,
1419
- w.value + BigInt(Math.round(Te))
1419
+ x.value + BigInt(Math.round(Te))
1420
1420
  )
1421
1421
  );
1422
- w.set(M);
1422
+ x.set(B);
1423
1423
  }
1424
1424
  Te = 0, $e = 0, z = null;
1425
1425
  };
1426
- return I.on((A) => {
1427
- A || w.set(0n);
1428
- }), V.on((A) => {
1426
+ return T.on((A) => {
1429
1427
  A || x.set(0n);
1430
- }), R(
1428
+ }), V.on((A) => {
1429
+ A || k.set(0n);
1430
+ }), U(
1431
1431
  oe(() => {
1432
1432
  z && clearTimeout(z);
1433
1433
  }),
1434
1434
  L.wheel((A) => {
1435
1435
  A.preventDefault();
1436
- const { deltaX: N, deltaY: K } = A;
1437
- Te += N, $e += K, z || (z = setTimeout(Ke, 16));
1436
+ const { deltaX: R, deltaY: K } = A;
1437
+ Te += R, $e += K, z || (z = setTimeout(Ke, 16));
1438
1438
  }),
1439
1439
  d.div(
1440
1440
  o.class("bc-nine-slice-pane-container"),
1441
- S.right(Ie),
1442
- S.bottom(q),
1441
+ C.right(Ie),
1442
+ C.bottom(q),
1443
1443
  // top-start corner
1444
1444
  s != null ? d.div(
1445
1445
  o.class("bc-nine-slice-pane bc-nine-slice-top-start"),
1446
- S.top("0"),
1447
- S.left("0"),
1446
+ C.top("0"),
1447
+ C.left("0"),
1448
1448
  // style.height(headerHeightPx),
1449
1449
  // style.width(sidebarStartWidthPx),
1450
1450
  s
@@ -1452,8 +1452,8 @@ function Ir({
1452
1452
  // top-center
1453
1453
  a != null ? d.div(
1454
1454
  o.class("bc-nine-slice-pane bc-nine-slice-header"),
1455
- S.top("0"),
1456
- S.left(f),
1455
+ C.top("0"),
1456
+ C.left(v),
1457
1457
  // style.height(headerHeightPx),
1458
1458
  // style.width(visibleAreaWidthPx),
1459
1459
  d.div(
@@ -1465,30 +1465,30 @@ function Ir({
1465
1465
  // top-end corner
1466
1466
  i != null ? d.div(
1467
1467
  o.class("bc-nine-slice-pane bc-nine-slice-top-end"),
1468
- S.top("0"),
1469
- U,
1468
+ C.top("0"),
1469
+ F,
1470
1470
  // style.height(headerHeightPx),
1471
1471
  // style.width(sidebarEndWidthPx),
1472
1472
  i
1473
1473
  ) : null,
1474
1474
  // middle-start sidebar
1475
- b != null ? d.div(
1475
+ f != null ? d.div(
1476
1476
  o.class("bc-nine-slice-pane bc-nine-slice-sidebar-start"),
1477
- S.left("0"),
1478
- S.top(g),
1477
+ C.left("0"),
1478
+ C.top(m),
1479
1479
  // style.height(visibleAreaHeightPx),
1480
1480
  // style.width(sidebarStartWidthPx),
1481
1481
  d.div(
1482
1482
  o.class("bc-nine-slice-pane-content"),
1483
1483
  we,
1484
- b
1484
+ f
1485
1485
  )
1486
1486
  ) : null,
1487
1487
  // middle-center (main body)
1488
1488
  d.div(
1489
1489
  o.class("bc-nine-slice-pane bc-nine-slice-body"),
1490
- S.left(f),
1491
- S.top(g),
1490
+ C.left(v),
1491
+ C.top(m),
1492
1492
  // style.width(visibleAreaWidth.map(toPx)),
1493
1493
  // style.height(visibleAreaHeight.map(toPx)),
1494
1494
  d.div(
@@ -1498,22 +1498,22 @@ function Ir({
1498
1498
  )
1499
1499
  ),
1500
1500
  // middle-end sidebar
1501
- m != null ? d.div(
1501
+ g != null ? d.div(
1502
1502
  o.class("bc-nine-slice-pane bc-nine-slice-sidebar-end"),
1503
- U,
1504
- S.top(g),
1503
+ F,
1504
+ C.top(m),
1505
1505
  // style.height(visibleAreaHeightPx),
1506
1506
  // style.width(sidebarEndWidthPx),
1507
1507
  d.div(
1508
1508
  o.class("bc-nine-slice-pane-content"),
1509
1509
  we,
1510
- m
1510
+ g
1511
1511
  )
1512
1512
  ) : null,
1513
1513
  // bottom-start corner
1514
1514
  l != null ? d.div(
1515
1515
  o.class("bc-nine-slice-pane bc-nine-slice-bottom-start"),
1516
- S.left("0"),
1516
+ C.left("0"),
1517
1517
  se,
1518
1518
  // style.height(footerHeightPx),
1519
1519
  // style.width(sidebarStartWidthPx),
@@ -1522,7 +1522,7 @@ function Ir({
1522
1522
  // bottom-center
1523
1523
  c != null ? d.div(
1524
1524
  o.class("bc-nine-slice-pane bc-nine-slice-footer"),
1525
- S.left(f),
1525
+ C.left(v),
1526
1526
  se,
1527
1527
  // style.height(footerHeightPx),
1528
1528
  // style.width(visibleAreaWidthPx),
@@ -1535,7 +1535,7 @@ function Ir({
1535
1535
  // bottom-end corner
1536
1536
  p != null ? d.div(
1537
1537
  o.class("bc-nine-slice-pane bc-nine-slice-bottom-end"),
1538
- U,
1538
+ F,
1539
1539
  se,
1540
1540
  // style.height(footerHeightPx),
1541
1541
  // style.width(sidebarEndWidthPx),
@@ -1545,17 +1545,17 @@ function Ir({
1545
1545
  // horizontal scrollbar
1546
1546
  d.div(
1547
1547
  o.class("bc-nine-slice-pane bc-nine-slice-horizontal-scrollbar"),
1548
- S.overflowX("scroll"),
1549
- S.left("0"),
1550
- S.right(
1551
- T(
1548
+ C.overflowX("scroll"),
1549
+ C.left("0"),
1550
+ C.right(
1551
+ I(
1552
1552
  V,
1553
- C
1554
- )((A, N) => A ? `${N}px` : "0")
1553
+ w
1554
+ )((A, R) => A ? `${R}px` : "0")
1555
1555
  ),
1556
- S.bottom("0"),
1557
- S.height(
1558
- I.map(
1556
+ C.bottom("0"),
1557
+ C.height(
1558
+ T.map(
1559
1559
  (A) => A ? "16px" : "0"
1560
1560
  )
1561
1561
  ),
@@ -1563,18 +1563,18 @@ function Ir({
1563
1563
  o.class(
1564
1564
  "bc-nine-slice-pane bc-nine-slice-horizontal-scrollbar-thumb"
1565
1565
  ),
1566
- S.width(
1567
- F.map((A) => `${100 / Math.max(1, A)}%`)
1566
+ C.width(
1567
+ N.map((A) => `${100 / Math.max(1, A)}%`)
1568
1568
  ),
1569
- S.height("100%"),
1570
- S.backgroundColor("#ff000066")
1569
+ C.height("100%"),
1570
+ C.backgroundColor("#ff000066")
1571
1571
  ),
1572
1572
  L.scroll((A) => {
1573
- const N = A.target, K = N.scrollLeft, P = N.scrollWidth - N.clientWidth;
1573
+ const R = A.target, K = R.scrollLeft, P = R.scrollWidth - R.clientWidth;
1574
1574
  if (P > 0) {
1575
- const M = K / P, j = Ae.value;
1576
- w.set(
1577
- BigInt(Math.round(Number(j) * M))
1575
+ const B = K / P, j = Ae.value;
1576
+ x.set(
1577
+ BigInt(Math.round(Number(j) * B))
1578
1578
  );
1579
1579
  }
1580
1580
  })
@@ -1582,16 +1582,16 @@ function Ir({
1582
1582
  // vertical scrollbar
1583
1583
  d.div(
1584
1584
  o.class("bc-nine-slice-pane bc-nine-slice-vertical-scrollbar"),
1585
- S.overflowY("scroll"),
1586
- S.top("0"),
1587
- S.bottom(
1588
- T(
1589
- I,
1590
- C
1591
- )((A, N) => A ? `${N}px` : "0")
1585
+ C.overflowY("scroll"),
1586
+ C.top("0"),
1587
+ C.bottom(
1588
+ I(
1589
+ T,
1590
+ w
1591
+ )((A, R) => A ? `${R}px` : "0")
1592
1592
  ),
1593
- S.right("0"),
1594
- S.width(
1593
+ C.right("0"),
1594
+ C.width(
1595
1595
  V.map(
1596
1596
  (A) => A ? "16px" : "0"
1597
1597
  )
@@ -1600,23 +1600,23 @@ function Ir({
1600
1600
  o.class(
1601
1601
  "bc-nine-slice-pane bc-nine-slice-vertical-scrollbar-thumb"
1602
1602
  ),
1603
- S.width("100%"),
1604
- S.height(
1605
- T(
1603
+ C.width("100%"),
1604
+ C.height(
1605
+ I(
1606
1606
  r,
1607
1607
  u,
1608
1608
  n,
1609
- ee
1610
- )((A, N, K, P) => `${100 / Math.max(1, P)}%`)
1609
+ te
1610
+ )((A, R, K, P) => `${100 / Math.max(1, P)}%`)
1611
1611
  ),
1612
- S.backgroundColor("#ff000066")
1612
+ C.backgroundColor("#ff000066")
1613
1613
  ),
1614
1614
  L.scroll((A) => {
1615
- const N = A.target, K = N.scrollTop, P = N.scrollHeight - N.clientHeight;
1615
+ const R = A.target, K = R.scrollTop, P = R.scrollHeight - R.clientHeight;
1616
1616
  if (P > 0) {
1617
- const M = K / P, j = De.value;
1618
- x.set(
1619
- BigInt(Math.round(Number(j) * M))
1617
+ const B = K / P, j = De.value;
1618
+ k.set(
1619
+ BigInt(Math.round(Number(j) * B))
1620
1620
  );
1621
1621
  }
1622
1622
  })
@@ -1634,7 +1634,7 @@ function _t({ header: e, footer: t, body: n, shadowOnScroll: a = !0 }, ...r) {
1634
1634
  return d.div(
1635
1635
  o.class("bc-scrollable-panel"),
1636
1636
  o.class(
1637
- T(
1637
+ I(
1638
1638
  s,
1639
1639
  a
1640
1640
  )((u, l) => {
@@ -1676,7 +1676,7 @@ function ia(e, t, n) {
1676
1676
  function Tr({ variant: e = "default", size: t = "md", roundedness: n = "lg" } = {}, ...a) {
1677
1677
  return d.div(
1678
1678
  o.class(
1679
- T(
1679
+ I(
1680
1680
  e,
1681
1681
  t,
1682
1682
  n
@@ -1732,52 +1732,52 @@ const Ce = {
1732
1732
  onBeforeOpen: c,
1733
1733
  onAfterOpen: u,
1734
1734
  buildListboxContent: l
1735
- } = e, p = G(!1), b = G(-1), k = G(null), m = he("dropdown"), y = he("listbox");
1736
- let h, x;
1737
- const w = (f) => {
1738
- t?.(f), p.set(!1), b.set(-1), k.set(null), h?.focus();
1739
- }, g = (f) => {
1740
- const C = Ce.getValues(v.get(s));
1741
- switch (f.key) {
1735
+ } = e, p = G(!1), f = G(-1), S = G(null), g = he("dropdown"), y = he("listbox");
1736
+ let b, k;
1737
+ const x = (v) => {
1738
+ t?.(v), p.set(!1), f.set(-1), S.set(null), b?.focus();
1739
+ }, m = (v) => {
1740
+ const w = Ce.getValues(h.get(s));
1741
+ switch (v.key) {
1742
1742
  case "ArrowDown": {
1743
- if (f.preventDefault(), !p.value)
1744
- p.set(!0), C.length > 0 && (b.set(0), k.set(C[0]));
1743
+ if (v.preventDefault(), !p.value)
1744
+ p.set(!0), w.length > 0 && (f.set(0), S.set(w[0]));
1745
1745
  else {
1746
1746
  const $ = Math.min(
1747
- b.value + 1,
1748
- C.length - 1
1747
+ f.value + 1,
1748
+ w.length - 1
1749
1749
  );
1750
- b.set($), k.set(C[$] ?? null);
1750
+ f.set($), S.set(w[$] ?? null);
1751
1751
  }
1752
1752
  break;
1753
1753
  }
1754
1754
  case "ArrowUp": {
1755
- if (f.preventDefault(), p.value) {
1756
- const $ = Math.max(b.value - 1, 0);
1757
- b.set($), k.set(C[$] ?? null);
1755
+ if (v.preventDefault(), p.value) {
1756
+ const $ = Math.max(f.value - 1, 0);
1757
+ f.set($), S.set(w[$] ?? null);
1758
1758
  }
1759
1759
  break;
1760
1760
  }
1761
1761
  case "Enter": {
1762
- if (f.preventDefault(), p.value && b.value >= 0) {
1763
- const $ = C[b.value];
1764
- $ != null && w($);
1762
+ if (v.preventDefault(), p.value && f.value >= 0) {
1763
+ const $ = w[f.value];
1764
+ $ != null && x($);
1765
1765
  } else {
1766
1766
  c?.();
1767
- const $ = Ce.getValues(v.get(s));
1768
- p.set(!0), $.length > 0 && (b.set(0), k.set($[0])), setTimeout(() => u?.(), 0);
1767
+ const $ = Ce.getValues(h.get(s));
1768
+ p.set(!0), $.length > 0 && (f.set(0), S.set($[0])), setTimeout(() => u?.(), 0);
1769
1769
  }
1770
1770
  break;
1771
1771
  }
1772
1772
  case "Escape": {
1773
- p.value && (f.preventDefault(), p.set(!1), b.set(-1), k.set(null), h?.focus());
1773
+ p.value && (v.preventDefault(), p.set(!1), f.set(-1), S.set(null), b?.focus());
1774
1774
  break;
1775
1775
  }
1776
1776
  case " ": {
1777
- if (v.get(i)) {
1778
- f.preventDefault();
1779
- const $ = Ce.getValues(v.get(s));
1780
- p.set(!p.value), p.value && $.length > 0 && (b.set(0), k.set($[0]));
1777
+ if (h.get(i)) {
1778
+ v.preventDefault();
1779
+ const $ = Ce.getValues(h.get(s));
1780
+ p.set(!p.value), p.value && $.length > 0 && (f.set(0), S.set($[0]));
1781
1781
  }
1782
1782
  break;
1783
1783
  }
@@ -1789,69 +1789,69 @@ const Ce = {
1789
1789
  input: Zt(
1790
1790
  o.class("bc-dropdown__trigger"),
1791
1791
  d.span(o.class("bc-dropdown__display"), r),
1792
- te(
1792
+ ee(
1793
1793
  { icon: "ph:caret-up-down-bold", color: "neutral" },
1794
1794
  o.class("bc-dropdown__arrow")
1795
1795
  )
1796
1796
  )
1797
1797
  },
1798
- Be((f) => R(
1799
- ne((C) => (h = C, C.addEventListener("keydown", g), oe(
1800
- () => C.removeEventListener("keydown", g)
1798
+ Be((v) => U(
1799
+ ne((w) => (b = w, w.addEventListener("keydown", m), oe(
1800
+ () => w.removeEventListener("keydown", m)
1801
1801
  ))),
1802
1802
  fe(e),
1803
- o.id(m),
1803
+ o.id(g),
1804
1804
  o.tabindex(0),
1805
- E.controls(y),
1806
- E.expanded(p),
1805
+ M.controls(y),
1806
+ M.expanded(p),
1807
1807
  o.class("bc-dropdown"),
1808
1808
  o.role(a),
1809
- E.activedescendant(
1810
- T(
1809
+ M.activedescendant(
1810
+ I(
1811
1811
  p,
1812
- k
1812
+ S
1813
1813
  )(
1814
- (C, $) => C && $ != null ? `dropdown-option-${String($)}` : ""
1814
+ (w, $) => w && $ != null ? `dropdown-option-${String($)}` : ""
1815
1815
  )
1816
1816
  ),
1817
1817
  n != null ? L.blur(() => {
1818
1818
  setTimeout(() => {
1819
- x?.contains(document.activeElement) || (p.set(!1), b.set(-1), n());
1819
+ k?.contains(document.activeElement) || (p.set(!1), f.set(-1), n());
1820
1820
  }, 100);
1821
1821
  }) : W,
1822
1822
  Ge({
1823
1823
  content: () => d.div(
1824
- ne((C) => {
1825
- x = C;
1824
+ ne((w) => {
1825
+ k = w;
1826
1826
  }),
1827
- S.minWidth(f.$.width.map((C) => `${C - 10}px`)),
1827
+ C.minWidth(v.$.width.map((w) => `${w - 10}px`)),
1828
1828
  o.class("bc-dropdown__listbox"),
1829
1829
  o.role("listbox"),
1830
1830
  o.id(y),
1831
- E.labelledby(m),
1831
+ M.labelledby(g),
1832
1832
  l({
1833
- dropdownId: m,
1833
+ dropdownId: g,
1834
1834
  listboxId: y,
1835
- focusedValue: k,
1836
- handleKeyDown: g,
1837
- onSelect: w
1835
+ focusedValue: S,
1836
+ handleKeyDown: m,
1837
+ onSelect: x
1838
1838
  })
1839
1839
  ),
1840
1840
  mainAxisOffset: 0,
1841
1841
  placement: "bottom-start",
1842
1842
  hasPopup: "listbox",
1843
- showOn: (C, $) => {
1843
+ showOn: (w, $) => {
1844
1844
  const D = $;
1845
1845
  $ = () => {
1846
- p.set(!1), b.set(-1), k.set(null), D();
1846
+ p.set(!1), f.set(-1), S.set(null), D();
1847
1847
  };
1848
1848
  const _ = () => {
1849
1849
  if (p.value)
1850
1850
  $();
1851
1851
  else {
1852
1852
  c?.();
1853
- const I = Ce.getValues(v.get(s));
1854
- p.set(!0), I.length > 0 && (b.set(0), k.set(I[0])), C(), setTimeout(() => u?.(), 0);
1853
+ const T = Ce.getValues(h.get(s));
1854
+ p.set(!0), T.length > 0 && (f.set(0), S.set(T[0])), w(), setTimeout(() => u?.(), 0);
1855
1855
  }
1856
1856
  };
1857
1857
  return L.click(_);
@@ -1866,28 +1866,28 @@ const Ce = {
1866
1866
  e,
1867
1867
  (s) => Et(s, {
1868
1868
  value: (i) => {
1869
- const c = T(
1869
+ const c = I(
1870
1870
  i,
1871
1871
  n
1872
- )((l, p) => t(l.value, p)), u = T(
1872
+ )((l, p) => t(l.value, p)), u = I(
1873
1873
  i,
1874
1874
  r
1875
1875
  )((l, p) => p != null && t(l.value, p));
1876
1876
  return d.div(
1877
1877
  o.class("bc-dropdown__option"),
1878
1878
  o.class(
1879
- T(
1879
+ I(
1880
1880
  c,
1881
1881
  u,
1882
1882
  i
1883
- )((l, p, b) => {
1884
- const k = [];
1885
- return l && k.push("bc-dropdown__option--selected"), p && k.push("bc-dropdown__option--focused"), b.disabled && k.push("bc-dropdown__option--disabled"), k.join(" ");
1883
+ )((l, p, f) => {
1884
+ const S = [];
1885
+ return l && S.push("bc-dropdown__option--selected"), p && S.push("bc-dropdown__option--focused"), f.disabled && S.push("bc-dropdown__option--disabled"), S.join(" ");
1886
1886
  })
1887
1887
  ),
1888
1888
  o.role("option"),
1889
1889
  o.id(i.map((l) => `dropdown-option-${String(l.value)}`)),
1890
- E.selected(c),
1890
+ M.selected(c),
1891
1891
  An("value", i.$.value),
1892
1892
  Q(
1893
1893
  i.map((l) => !l.disabled),
@@ -1911,7 +1911,7 @@ const Ce = {
1911
1911
  group: (i) => d.div(
1912
1912
  o.class("bc-dropdown__group"),
1913
1913
  o.role("group"),
1914
- E.label(i.$.group),
1914
+ M.label(i.$.group),
1915
1915
  d.div(o.class("bc-dropdown__group-label"), i.$.group),
1916
1916
  Le(
1917
1917
  i.$.options,
@@ -1934,23 +1934,23 @@ const Ce = {
1934
1934
  equality: r = (l, p) => l === p,
1935
1935
  placeholder: s,
1936
1936
  searchable: i = !1
1937
- } = e, c = T(
1937
+ } = e, c = I(
1938
1938
  t,
1939
1939
  n
1940
1940
  )((l, p) => {
1941
1941
  if (l == null) return "";
1942
- const b = (k) => {
1943
- for (const m of k) {
1944
- if (m.type === "value" && r(m.value, l))
1945
- return m.label;
1946
- if (m.type === "group") {
1947
- const y = b(m.options);
1942
+ const f = (S) => {
1943
+ for (const g of S) {
1944
+ if (g.type === "value" && r(g.value, l))
1945
+ return g.label;
1946
+ if (g.type === "group") {
1947
+ const y = f(g.options);
1948
1948
  if (y) return y;
1949
1949
  }
1950
1950
  }
1951
1951
  };
1952
- return b(p) || String(l);
1953
- }), u = T(i)((l) => !l);
1952
+ return f(p) || String(l);
1953
+ }), u = I(i)((l) => !l);
1954
1954
  return Qt({
1955
1955
  ...e,
1956
1956
  role: "dropdown",
@@ -1966,7 +1966,7 @@ const Ce = {
1966
1966
  allowSpaceToggle: u,
1967
1967
  buildListboxContent: ({ focusedValue: l, onSelect: p }) => Le(
1968
1968
  n,
1969
- (b) => Xt(b, r, t, p, l)
1969
+ (f) => Xt(f, r, t, p, l)
1970
1970
  )
1971
1971
  });
1972
1972
  }, ua = (e) => {
@@ -1984,30 +1984,30 @@ const Ce = {
1984
1984
  e,
1985
1985
  (i) => Et(i, {
1986
1986
  value: (c) => {
1987
- const u = T(
1987
+ const u = I(
1988
1988
  c,
1989
1989
  n
1990
- )((p, b) => t(p.value, b)), l = T(
1990
+ )((p, f) => t(p.value, f)), l = I(
1991
1991
  c,
1992
1992
  r
1993
1993
  )(
1994
- (p, b) => b != null && t(p.value, b)
1994
+ (p, f) => f != null && t(p.value, f)
1995
1995
  );
1996
1996
  return d.div(
1997
1997
  o.class("bc-dropdown__option"),
1998
1998
  o.class(
1999
- T(
1999
+ I(
2000
2000
  u,
2001
2001
  l,
2002
2002
  c
2003
- )((p, b, k) => {
2004
- const m = [];
2005
- return p && m.push("bc-dropdown__option--selected"), b && m.push("bc-dropdown__option--focused"), k.disabled && m.push("bc-dropdown__option--disabled"), m.join(" ");
2003
+ )((p, f, S) => {
2004
+ const g = [];
2005
+ return p && g.push("bc-dropdown__option--selected"), f && g.push("bc-dropdown__option--focused"), S.disabled && g.push("bc-dropdown__option--disabled"), g.join(" ");
2006
2006
  })
2007
2007
  ),
2008
2008
  o.role("option"),
2009
2009
  o.id(c.map((p) => `dropdown-option-${String(p.value)}`)),
2010
- E.selected(u),
2010
+ M.selected(u),
2011
2011
  Q(
2012
2012
  c.map((p) => !p.disabled),
2013
2013
  () => L.click(() => a(c.value.value)),
@@ -2033,7 +2033,7 @@ const Ce = {
2033
2033
  group: (c) => d.div(
2034
2034
  o.class("bc-dropdown__group"),
2035
2035
  o.role("group"),
2036
- E.label(c.$.group),
2036
+ M.label(c.$.group),
2037
2037
  d.div(o.class("bc-dropdown__group-label"), c.$.group),
2038
2038
  Le(
2039
2039
  c.$.options,
@@ -2055,24 +2055,24 @@ const Ce = {
2055
2055
  loadOptions: n,
2056
2056
  renderOption: a,
2057
2057
  renderValue: r,
2058
- equality: s = (g, f) => g === f,
2058
+ equality: s = (m, v) => m === v,
2059
2059
  placeholder: i,
2060
2060
  searchPlaceholder: c,
2061
2061
  debounceMs: u = 150
2062
- } = e, l = G(""), p = G(!1), b = G([]);
2063
- let k;
2064
- const m = v.toSignal(t), y = () => (r ?? a)(m);
2065
- let h = null;
2066
- const x = (g) => {
2067
- p.set(!0), Promise.resolve(n(g)).then((f) => {
2068
- b.set(f ?? []);
2062
+ } = e, l = G(""), p = G(!1), f = G([]);
2063
+ let S;
2064
+ const g = h.toSignal(t), y = () => (r ?? a)(g);
2065
+ let b = null;
2066
+ const k = (m) => {
2067
+ p.set(!0), Promise.resolve(n(m)).then((v) => {
2068
+ f.set(v ?? []);
2069
2069
  }).catch(() => {
2070
- b.set([]);
2070
+ f.set([]);
2071
2071
  }).finally(() => p.set(!1));
2072
- }, w = (g) => {
2073
- h != null && (clearTimeout(h), h = null), h = setTimeout(
2072
+ }, x = (m) => {
2073
+ b != null && (clearTimeout(b), b = null), b = setTimeout(
2074
2074
  () => {
2075
- x(g);
2075
+ k(m);
2076
2076
  },
2077
2077
  Math.max(0, u)
2078
2078
  );
@@ -2081,19 +2081,19 @@ const Ce = {
2081
2081
  ...e,
2082
2082
  role: "combobox",
2083
2083
  display: Q(
2084
- T(t)((g) => g != null),
2084
+ I(t)((m) => m != null),
2085
2085
  y,
2086
- () => ae(ie, (g) => g.$.selectOne)
2086
+ () => ae(ie, (m) => m.$.selectOne)
2087
2087
  ),
2088
- optionsSource: b,
2088
+ optionsSource: f,
2089
2089
  onBeforeOpen: () => {
2090
- const g = v.get(l);
2091
- w(g);
2090
+ const m = h.get(l);
2091
+ x(m);
2092
2092
  },
2093
2093
  onAfterOpen: () => {
2094
- k?.focus();
2094
+ S?.focus();
2095
2095
  },
2096
- buildListboxContent: ({ focusedValue: g, handleKeyDown: f, onSelect: C }) => R(
2096
+ buildListboxContent: ({ focusedValue: m, handleKeyDown: v, onSelect: w }) => U(
2097
2097
  // Search input at the top
2098
2098
  d.div(
2099
2099
  o.class("bc-dropdown__search"),
@@ -2101,34 +2101,34 @@ const Ce = {
2101
2101
  o.type("text"),
2102
2102
  o.class("bc-dropdown__search-input"),
2103
2103
  o.placeholder(
2104
- T(
2104
+ I(
2105
2105
  c,
2106
2106
  i
2107
2107
  )(($, D) => $ ?? D ?? "Search")
2108
2108
  ),
2109
2109
  o.value(l),
2110
- ne(($) => (k = $, W)),
2110
+ ne(($) => (S = $, W)),
2111
2111
  L.input(($) => {
2112
2112
  const D = $.target;
2113
- l.set(D.value), w(D.value);
2113
+ l.set(D.value), x(D.value);
2114
2114
  }),
2115
- L.keydown(f)
2115
+ L.keydown(v)
2116
2116
  )
2117
2117
  ),
2118
2118
  Q(
2119
2119
  p,
2120
2120
  () => d.div(
2121
2121
  o.class("bc-dropdown__loading"),
2122
- te({ icon: "ph:spinner-bold", color: "neutral" })
2122
+ ee({ icon: "ph:spinner-bold", color: "neutral" })
2123
2123
  ),
2124
2124
  () => Le(
2125
- b,
2125
+ f,
2126
2126
  ($) => en(
2127
2127
  $,
2128
2128
  s,
2129
- m,
2130
- C,
2131
2129
  g,
2130
+ w,
2131
+ m,
2132
2132
  a
2133
2133
  )
2134
2134
  )
@@ -2159,101 +2159,101 @@ function tn(e) {
2159
2159
  closable: u = !0,
2160
2160
  onClose: l,
2161
2161
  onAction: p,
2162
- ariaLabel: b,
2163
- ariaLabelledBy: k
2164
- } = e, m = he("menu"), y = G(-1), h = G([]);
2165
- let x = null;
2166
- return R(
2162
+ ariaLabel: f,
2163
+ ariaLabelledBy: S
2164
+ } = e, g = he("menu"), y = G(-1), b = G([]);
2165
+ let k = null;
2166
+ return U(
2167
2167
  Ge({
2168
- content: () => ne((w) => {
2169
- x = document.activeElement;
2170
- const g = (_, I, V) => {
2171
- if (I.length === 0) return -1;
2172
- let O = _ + V, B = 0;
2173
- for (; B < I.length; ) {
2174
- O >= I.length && (O = 0), O < 0 && (O = I.length - 1);
2175
- const F = I[O];
2176
- if (F && F.getAttribute("aria-disabled") !== "true")
2168
+ content: () => ne((x) => {
2169
+ k = document.activeElement;
2170
+ const m = (_, T, V) => {
2171
+ if (T.length === 0) return -1;
2172
+ let O = _ + V, E = 0;
2173
+ for (; E < T.length; ) {
2174
+ O >= T.length && (O = 0), O < 0 && (O = T.length - 1);
2175
+ const N = T[O];
2176
+ if (N && N.getAttribute("aria-disabled") !== "true")
2177
2177
  return O;
2178
- O += V, B++;
2178
+ O += V, E++;
2179
2179
  }
2180
2180
  return _;
2181
- }, f = (_) => {
2182
- const I = h.value, V = y.value;
2181
+ }, v = (_) => {
2182
+ const T = b.value, V = y.value;
2183
2183
  switch (_.key) {
2184
2184
  case "ArrowDown":
2185
2185
  _.preventDefault(), _.stopPropagation();
2186
- const O = g(V, I, 1);
2187
- C(O, I);
2186
+ const O = m(V, T, 1);
2187
+ w(O, T);
2188
2188
  break;
2189
2189
  case "ArrowUp":
2190
2190
  _.preventDefault(), _.stopPropagation();
2191
- const B = g(V, I, -1);
2192
- C(B, I);
2191
+ const E = m(V, T, -1);
2192
+ w(E, T);
2193
2193
  break;
2194
2194
  case "Enter":
2195
2195
  case " ":
2196
- if (_.preventDefault(), _.stopPropagation(), V >= 0 && I[V]) {
2197
- const F = I[V];
2198
- if (F.getAttribute("aria-disabled") === "true")
2196
+ if (_.preventDefault(), _.stopPropagation(), V >= 0 && T[V]) {
2197
+ const N = T[V];
2198
+ if (N.getAttribute("aria-disabled") === "true")
2199
2199
  return;
2200
- const ee = F.getAttribute("data-key");
2201
- ee && p && p(ee), F.click(), l?.();
2200
+ const te = N.getAttribute("data-key");
2201
+ te && p && p(te), N.click(), l?.();
2202
2202
  }
2203
2203
  break;
2204
2204
  case "Escape":
2205
2205
  l?.();
2206
2206
  break;
2207
2207
  case "Home":
2208
- _.preventDefault(), _.stopPropagation(), I.length > 0 && C(0, I);
2208
+ _.preventDefault(), _.stopPropagation(), T.length > 0 && w(0, T);
2209
2209
  break;
2210
2210
  case "End":
2211
- _.preventDefault(), _.stopPropagation(), I.length > 0 && C(I.length - 1, I);
2211
+ _.preventDefault(), _.stopPropagation(), T.length > 0 && w(T.length - 1, T);
2212
2212
  break;
2213
2213
  case "ArrowRight":
2214
- if (_.preventDefault(), _.stopPropagation(), V >= 0 && I[V]) {
2215
- const F = I[V];
2216
- F.classList.contains(
2214
+ if (_.preventDefault(), _.stopPropagation(), V >= 0 && T[V]) {
2215
+ const N = T[V];
2216
+ N.classList.contains(
2217
2217
  "bc-menu-item--has-submenu"
2218
- ) && F.dispatchEvent(new Event("mouseenter"));
2218
+ ) && N.dispatchEvent(new Event("mouseenter"));
2219
2219
  }
2220
2220
  break;
2221
2221
  case "ArrowLeft":
2222
2222
  _.preventDefault(), _.stopPropagation(), l?.();
2223
2223
  break;
2224
2224
  }
2225
- }, C = (_, I) => {
2226
- y.value >= 0 && I[y.value] && (I[y.value].classList.remove(
2225
+ }, w = (_, T) => {
2226
+ y.value >= 0 && T[y.value] && (T[y.value].classList.remove(
2227
2227
  "bc-menu-item--focused"
2228
- ), I[y.value].removeAttribute("aria-selected")), _ >= 0 && I[_] && (I[_].classList.add("bc-menu-item--focused"), I[_].setAttribute("aria-selected", "true"), y.set(_), typeof I[_].scrollIntoView == "function" && I[_].scrollIntoView({ block: "nearest" }));
2228
+ ), T[y.value].removeAttribute("aria-selected")), _ >= 0 && T[_] && (T[_].classList.add("bc-menu-item--focused"), T[_].setAttribute("aria-selected", "true"), y.set(_), typeof T[_].scrollIntoView == "function" && T[_].scrollIntoView({ block: "nearest" }));
2229
2229
  }, $ = () => {
2230
2230
  const _ = Array.from(
2231
- w.querySelectorAll('[role="menuitem"]')
2231
+ x.querySelectorAll('[role="menuitem"]')
2232
2232
  );
2233
- if (h.set(_), _.length > 0) {
2234
- const I = _.findIndex(
2233
+ if (b.set(_), _.length > 0) {
2234
+ const T = _.findIndex(
2235
2235
  (V) => V.getAttribute("aria-disabled") !== "true"
2236
2236
  );
2237
- I >= 0 && C(I, _);
2237
+ T >= 0 && w(T, _);
2238
2238
  }
2239
2239
  }, D = new MutationObserver($);
2240
- return D.observe(w, { childList: !0, subtree: !0 }), setTimeout(() => {
2241
- $(), w.focus();
2242
- }, 0), document.addEventListener("keydown", f, !0), R(
2240
+ return D.observe(x, { childList: !0, subtree: !0 }), setTimeout(() => {
2241
+ $(), x.focus();
2242
+ }, 0), document.addEventListener("keydown", v, !0), U(
2243
2243
  oe(() => {
2244
- D.disconnect(), document.removeEventListener("keydown", f, !0), x && x.focus();
2244
+ D.disconnect(), document.removeEventListener("keydown", v, !0), k && k.focus();
2245
2245
  }),
2246
2246
  o.class("bc-menu"),
2247
- o.id(m),
2247
+ o.id(g),
2248
2248
  o.role("menu"),
2249
2249
  o.tabindex(-1),
2250
- E.orientation("vertical"),
2251
- b ? E.label(b) : R(),
2252
- k ? E.labelledby(k) : R(),
2253
- E.activedescendant(
2250
+ M.orientation("vertical"),
2251
+ f ? M.label(f) : U(),
2252
+ S ? M.labelledby(S) : U(),
2253
+ M.activedescendant(
2254
2254
  y.map((_) => {
2255
- const I = h.value;
2256
- return _ >= 0 && I[_] ? I[_].id || `${m}-item-${_}` : "";
2255
+ const T = b.value;
2256
+ return _ >= 0 && T[_] ? T[_].id || `${g}-item-${_}` : "";
2257
2257
  })
2258
2258
  ),
2259
2259
  L.click((_) => {
@@ -2268,13 +2268,13 @@ function tn(e) {
2268
2268
  // Live region for screen reader announcements
2269
2269
  d.div(
2270
2270
  o.class("sr-only"),
2271
- E.live("polite"),
2272
- E.atomic(!0),
2271
+ M.live("polite"),
2272
+ M.atomic(!0),
2273
2273
  y.map((_) => {
2274
- const I = h.value;
2275
- if (_ >= 0 && I[_]) {
2276
- const V = I[_].textContent || "";
2277
- return I[_].getAttribute("aria-disabled") === "true" ? `${V}, disabled` : `${V}, ${_ + 1} of ${I.length}`;
2274
+ const T = b.value;
2275
+ if (_ >= 0 && T[_]) {
2276
+ const V = T[_].textContent || "";
2277
+ return T[_].getAttribute("aria-disabled") === "true" ? `${V}, disabled` : `${V}, ${_ + 1} of ${T.length}`;
2278
2278
  }
2279
2279
  return "";
2280
2280
  })
@@ -2304,25 +2304,25 @@ function Pr(e) {
2304
2304
  ariaLabel: c,
2305
2305
  submenu: u,
2306
2306
  submenuPlacement: l = "right-start"
2307
- } = e, p = t ?? he("menu-item"), b = `menu-item-${p}`, k = u != null;
2307
+ } = e, p = t ?? he("menu-item"), f = `menu-item-${p}`, S = u != null;
2308
2308
  return d.div(
2309
2309
  o.class(
2310
- T(s)(
2311
- (m) => `bc-menu-item ${m ? "bc-menu-item--disabled" : ""} ${k ? "bc-menu-item--has-submenu" : ""}`
2310
+ I(s)(
2311
+ (g) => `bc-menu-item ${g ? "bc-menu-item--disabled" : ""} ${S ? "bc-menu-item--has-submenu" : ""}`
2312
2312
  )
2313
2313
  ),
2314
- o.id(b),
2314
+ o.id(f),
2315
2315
  o.role("menuitem"),
2316
2316
  o.tabindex(-1),
2317
2317
  lt.key(p),
2318
- E.disabled(s),
2319
- E.selected(!1),
2318
+ M.disabled(s),
2319
+ M.selected(!1),
2320
2320
  // Will be updated by focus management
2321
- k ? E.expanded(!1) : R(),
2322
- c ? E.label(c) : R(),
2323
- L.click((m) => {
2324
- if (v.get(s)) {
2325
- m.preventDefault(), m.stopPropagation();
2321
+ S ? M.expanded(!1) : U(),
2322
+ c ? M.label(c) : U(),
2323
+ L.click((g) => {
2324
+ if (h.get(s)) {
2325
+ g.preventDefault(), g.stopPropagation();
2326
2326
  return;
2327
2327
  }
2328
2328
  i?.();
@@ -2334,8 +2334,8 @@ function Pr(e) {
2334
2334
  // End content
2335
2335
  r && d.span(o.class("bc-menu-item__end"), r),
2336
2336
  // Submenu (if present)
2337
- k && u ? Ge({
2338
- content: () => R(
2337
+ S && u ? Ge({
2338
+ content: () => U(
2339
2339
  o.class("bc-menu bc-submenu"),
2340
2340
  o.role("menu"),
2341
2341
  ...u()
@@ -2348,7 +2348,7 @@ function Pr(e) {
2348
2348
  mainAxisOffset: 0,
2349
2349
  crossAxisOffset: 0,
2350
2350
  role: "menu"
2351
- }) : R()
2351
+ }) : U()
2352
2352
  );
2353
2353
  }
2354
2354
  function nn(e = {}) {
@@ -2356,7 +2356,7 @@ function nn(e = {}) {
2356
2356
  return d.div(
2357
2357
  o.class("bc-menu-separator"),
2358
2358
  o.role("separator"),
2359
- E.orientation("horizontal"),
2359
+ M.orientation("horizontal"),
2360
2360
  t && d.span(o.class("bc-menu-separator__label"), t)
2361
2361
  );
2362
2362
  }
@@ -2409,7 +2409,7 @@ function cn(e) {
2409
2409
  () => Le(
2410
2410
  t,
2411
2411
  (i) => Jt({
2412
- value: T(
2412
+ value: I(
2413
2413
  i,
2414
2414
  n
2415
2415
  )((c, u) => fa(u, c, a)),
@@ -2427,46 +2427,46 @@ function un(e) {
2427
2427
  equality: a = (l, p) => l === p,
2428
2428
  placeholder: r
2429
2429
  } = e, s = (l) => {
2430
- const p = v.get(t);
2430
+ const p = h.get(t);
2431
2431
  e.onChange?.(rn(p, l, a));
2432
2432
  }, i = (l) => {
2433
- const p = v.get(t);
2433
+ const p = h.get(t);
2434
2434
  e.onChange?.(an(p, l, a));
2435
- }, c = (l) => T(t)((p) => on(p, l, a)), u = tn({
2435
+ }, c = (l) => I(t)((p) => on(p, l, a)), u = tn({
2436
2436
  items: () => {
2437
- const l = v.get(n), p = [];
2438
- for (const b of l)
2439
- if (b.type === "value") {
2440
- const k = c(b.value);
2437
+ const l = h.get(n), p = [];
2438
+ for (const f of l)
2439
+ if (f.type === "value") {
2440
+ const S = c(f.value);
2441
2441
  p.push(
2442
2442
  d.div(
2443
2443
  o.role("menuitem"),
2444
2444
  o.tabindex(-1),
2445
- E.disabled(b.disabled === !0),
2446
- E.checked(k),
2445
+ M.disabled(f.disabled === !0),
2446
+ M.checked(S),
2447
2447
  o.class("bc-menu-item"),
2448
- d.span(o.class("bc-menu-item__content"), b.label),
2449
- L.click(() => i(b.value))
2448
+ d.span(o.class("bc-menu-item__content"), f.label),
2449
+ L.click(() => i(f.value))
2450
2450
  )
2451
2451
  );
2452
- } else b.type === "group" ? p.push(
2452
+ } else f.type === "group" ? p.push(
2453
2453
  d.div(
2454
2454
  o.class("bc-menu-group"),
2455
- d.div(o.class("bc-menu-group__label"), b.group),
2456
- ...b.options.map((k) => {
2457
- if (k.type === "value") {
2458
- const m = c(k.value);
2455
+ d.div(o.class("bc-menu-group__label"), f.group),
2456
+ ...f.options.map((S) => {
2457
+ if (S.type === "value") {
2458
+ const g = c(S.value);
2459
2459
  return d.div(
2460
2460
  o.role("menuitem"),
2461
2461
  o.tabindex(-1),
2462
- E.disabled(k.disabled === !0),
2463
- E.checked(m),
2462
+ M.disabled(S.disabled === !0),
2463
+ M.checked(g),
2464
2464
  o.class("bc-menu-item"),
2465
- d.span(o.class("bc-menu-item__content"), k.label),
2466
- L.click(() => i(k.value))
2465
+ d.span(o.class("bc-menu-item__content"), S.label),
2466
+ L.click(() => i(S.value))
2467
2467
  );
2468
2468
  }
2469
- return R();
2469
+ return U();
2470
2470
  })
2471
2471
  )
2472
2472
  ) : p.push(nn());
@@ -2481,7 +2481,7 @@ function un(e) {
2481
2481
  return ce({
2482
2482
  ...e,
2483
2483
  before: e.before ?? Ye({ icon: "tabler:tags", color: "neutral" }),
2484
- input: R(
2484
+ input: U(
2485
2485
  o.class("bc-input-container__tags"),
2486
2486
  u,
2487
2487
  cn({
@@ -2519,65 +2519,65 @@ function dn(e) {
2519
2519
  const {
2520
2520
  value: t,
2521
2521
  options: n,
2522
- equality: a = (m, y) => m === y,
2522
+ equality: a = (g, y) => g === y,
2523
2523
  placeholder: r,
2524
2524
  searchPlaceholder: s,
2525
2525
  filter: i
2526
- } = e, c = G(""), u = (m) => {
2527
- const y = v.get(t);
2528
- e.onChange?.(rn(y, m, a));
2529
- }, l = (m) => {
2530
- const y = v.get(t);
2531
- e.onChange?.(an(y, m, a));
2532
- }, p = (m) => T(t)((y) => on(y, m, a)), b = T(
2526
+ } = e, c = G(""), u = (g) => {
2527
+ const y = h.get(t);
2528
+ e.onChange?.(rn(y, g, a));
2529
+ }, l = (g) => {
2530
+ const y = h.get(t);
2531
+ e.onChange?.(an(y, g, a));
2532
+ }, p = (g) => I(t)((y) => on(y, g, a)), f = I(
2533
2533
  n,
2534
2534
  c
2535
- )((m, y) => sn(m, y, i)), k = tn({
2535
+ )((g, y) => sn(g, y, i)), S = tn({
2536
2536
  items: () => {
2537
- const m = [], y = v.get(b);
2537
+ const g = [], y = h.get(f);
2538
2538
  if (y.length === 0)
2539
- return m.push(
2539
+ return g.push(
2540
2540
  d.div(
2541
2541
  o.class("bc-dropdown__empty"),
2542
- ae(ie, (h) => h.$.noResults)
2542
+ ae(ie, (b) => b.$.noResults)
2543
2543
  )
2544
- ), m;
2545
- for (const h of y)
2546
- if (h.type === "value") {
2547
- const x = p(h.value);
2548
- m.push(
2544
+ ), g;
2545
+ for (const b of y)
2546
+ if (b.type === "value") {
2547
+ const k = p(b.value);
2548
+ g.push(
2549
2549
  d.div(
2550
2550
  o.role("menuitem"),
2551
2551
  o.tabindex(-1),
2552
- E.disabled(h.disabled === !0),
2553
- E.checked(x),
2552
+ M.disabled(b.disabled === !0),
2553
+ M.checked(k),
2554
2554
  o.class("bc-menu-item"),
2555
- d.span(o.class("bc-menu-item__content"), h.label),
2556
- L.click(() => l(h.value))
2555
+ d.span(o.class("bc-menu-item__content"), b.label),
2556
+ L.click(() => l(b.value))
2557
2557
  )
2558
2558
  );
2559
- } else h.type === "group" ? m.push(
2559
+ } else b.type === "group" ? g.push(
2560
2560
  d.div(
2561
2561
  o.class("bc-menu-group"),
2562
- d.div(o.class("bc-menu-group__label"), h.group),
2563
- ...h.options.map((x) => {
2564
- if (x.type === "value") {
2565
- const w = p(x.value);
2562
+ d.div(o.class("bc-menu-group__label"), b.group),
2563
+ ...b.options.map((k) => {
2564
+ if (k.type === "value") {
2565
+ const x = p(k.value);
2566
2566
  return d.div(
2567
2567
  o.role("menuitem"),
2568
2568
  o.tabindex(-1),
2569
- E.disabled(x.disabled === !0),
2570
- E.checked(w),
2569
+ M.disabled(k.disabled === !0),
2570
+ M.checked(x),
2571
2571
  o.class("bc-menu-item"),
2572
- d.span(o.class("bc-menu-item__content"), x.label),
2573
- L.click(() => l(x.value))
2572
+ d.span(o.class("bc-menu-item__content"), k.label),
2573
+ L.click(() => l(k.value))
2574
2574
  );
2575
2575
  }
2576
- return R();
2576
+ return U();
2577
2577
  })
2578
2578
  )
2579
- ) : m.push(nn());
2580
- return m;
2579
+ ) : g.push(nn());
2580
+ return g;
2581
2581
  },
2582
2582
  placement: "bottom-start",
2583
2583
  showDelay: 0,
@@ -2585,24 +2585,24 @@ function dn(e) {
2585
2585
  // Open the menu when the search input gains focus
2586
2586
  // We intentionally do not auto-hide on blur here because the Menu
2587
2587
  // manages its own close behavior (outside click, Escape, etc.)
2588
- showOn: (m, y) => ne((h) => {
2589
- const x = h.querySelector(
2588
+ showOn: (g, y) => ne((b) => {
2589
+ const k = b.querySelector(
2590
2590
  ".bc-dropdown__search-input"
2591
2591
  );
2592
- if (x) {
2593
- const w = () => m();
2594
- return x.addEventListener("focus", w), oe(() => {
2595
- x.removeEventListener("focus", w);
2592
+ if (k) {
2593
+ const x = () => g();
2594
+ return k.addEventListener("focus", x), oe(() => {
2595
+ k.removeEventListener("focus", x);
2596
2596
  });
2597
2597
  }
2598
- return R();
2598
+ return U();
2599
2599
  }),
2600
2600
  closable: !0
2601
2601
  });
2602
2602
  return ce({
2603
2603
  ...e,
2604
2604
  before: e.before ?? Ye({ icon: "tabler:tags", color: "neutral" }),
2605
- input: R(
2605
+ input: U(
2606
2606
  o.class("bc-input-container__tags"),
2607
2607
  cn({
2608
2608
  values: t,
@@ -2619,21 +2619,21 @@ function dn(e) {
2619
2619
  o.type("text"),
2620
2620
  o.class("bc-dropdown__search-input"),
2621
2621
  o.placeholder(
2622
- T(
2622
+ I(
2623
2623
  s,
2624
2624
  r
2625
- )((m, y) => m ?? y ?? "")
2625
+ )((g, y) => g ?? y ?? "")
2626
2626
  ),
2627
2627
  o.value(c),
2628
- L.input((m) => {
2629
- const y = m.target;
2628
+ L.input((g) => {
2629
+ const y = g.target;
2630
2630
  c.set(y.value);
2631
2631
  }),
2632
- L.keydown((m) => {
2633
- (m.key === "ArrowUp" || m.key === "ArrowDown" || m.key === "Enter" || m.key === " ") && m.stopPropagation();
2632
+ L.keydown((g) => {
2633
+ (g.key === "ArrowUp" || g.key === "ArrowDown" || g.key === "Enter" || g.key === " ") && g.stopPropagation();
2634
2634
  })
2635
2635
  ),
2636
- k
2636
+ S
2637
2637
  )
2638
2638
  )
2639
2639
  });
@@ -2665,7 +2665,7 @@ const Br = (e) => {
2665
2665
  ...e,
2666
2666
  input: pe["datetime-local"](
2667
2667
  fe(e),
2668
- o.value(v.map(t, ba)),
2668
+ o.value(h.map(t, ba)),
2669
2669
  o.class("bc-input"),
2670
2670
  n != null ? L.blur(X(n)) : W,
2671
2671
  a != null ? L.change(X((r) => a(new Date(r)))) : W
@@ -2681,7 +2681,7 @@ const Br = (e) => {
2681
2681
  return Vn({
2682
2682
  ...r,
2683
2683
  maxFiles: 1,
2684
- value: v.map(t, (s) => s == null ? [] : [s]),
2684
+ value: h.map(t, (s) => s == null ? [] : [s]),
2685
2685
  onChange: (s) => {
2686
2686
  a?.(s[0]);
2687
2687
  },
@@ -2707,7 +2707,7 @@ const Br = (e) => {
2707
2707
  pending: () => ae(
2708
2708
  ie,
2709
2709
  (t) => d.span(
2710
- te({
2710
+ ee({
2711
2711
  icon: "line-md:loading-twotone-loop",
2712
2712
  title: t.$.loadingShort
2713
2713
  })
@@ -2717,11 +2717,11 @@ const Br = (e) => {
2717
2717
  const { value: t, onBlur: n, onChange: a, onInput: r, after: s, disabled: i, ...c } = e, u = Me(t, i, a ?? r);
2718
2718
  return Ee({
2719
2719
  ...c,
2720
- value: v.map(t, Bn),
2720
+ value: h.map(t, Bn),
2721
2721
  onChange: a != null ? (l) => a(kt(l)) : void 0,
2722
2722
  onInput: r != null ? (l) => r(kt(l)) : void 0,
2723
2723
  onBlur: n,
2724
- after: s != null ? R(u, s) : u
2724
+ after: s != null ? U(u, s) : u
2725
2725
  });
2726
2726
  }, Pt = (e) => {
2727
2727
  try {
@@ -2730,21 +2730,21 @@ const Br = (e) => {
2730
2730
  return null;
2731
2731
  }
2732
2732
  }, Rr = (e) => {
2733
- const { value: t, step: n, min: a, max: r, onChange: s, onInput: i, after: c } = e, u = (m) => {
2734
- const y = a != null ? v.get(a) : void 0, h = r != null ? v.get(r) : void 0;
2735
- return y != null && m < y ? y : h != null && m > h ? h : m;
2736
- }, l = n != null ? ae(ie, (m) => {
2737
- const y = T(
2733
+ const { value: t, step: n, min: a, max: r, onChange: s, onInput: i, after: c } = e, u = (g) => {
2734
+ const y = a != null ? h.get(a) : void 0, b = r != null ? h.get(r) : void 0;
2735
+ return y != null && g < y ? y : b != null && g > b ? b : g;
2736
+ }, l = n != null ? ae(ie, (g) => {
2737
+ const y = I(
2738
2738
  t,
2739
2739
  a
2740
- )((w, g) => g == null ? !0 : (w ?? 0n) > g), h = T(
2740
+ )((x, m) => m == null ? !0 : (x ?? 0n) > m), b = I(
2741
2741
  t,
2742
2742
  r
2743
- )((w, g) => g == null ? !0 : (w ?? 0n) < g), x = (w, g) => {
2744
- const f = v.get(t) ?? 0n, C = v.get(n), $ = g?.shiftKey ? 10n : 1n, D = f + C * $ * w, _ = a != null ? v.get(a) : void 0, I = r != null ? v.get(r) : void 0;
2745
- if (w < 0n && _ != null && D < _ || w > 0n && I != null && D > I) return;
2743
+ )((x, m) => m == null ? !0 : (x ?? 0n) < m), k = (x, m) => {
2744
+ const v = h.get(t) ?? 0n, w = h.get(n), $ = m?.shiftKey ? 10n : 1n, D = v + w * $ * x, _ = a != null ? h.get(a) : void 0, T = r != null ? h.get(r) : void 0;
2745
+ if (x < 0n && _ != null && D < _ || x > 0n && T != null && D > T) return;
2746
2746
  const V = u(D);
2747
- V !== f && s && s(V);
2747
+ V !== v && s && s(V);
2748
2748
  };
2749
2749
  return pt(
2750
2750
  o.class("bc-number-input-steppers"),
@@ -2754,14 +2754,14 @@ const Br = (e) => {
2754
2754
  "bc-button bc-number-input-steppers-button bc-number-input-steppers-button--increment"
2755
2755
  ),
2756
2756
  o.disabled(
2757
- T(
2758
- h,
2757
+ I(
2758
+ b,
2759
2759
  e.disabled ?? !1
2760
- )((w, g) => !w || g)
2760
+ )((x, m) => !x || m)
2761
2761
  ),
2762
- L.click((w) => x(1n, w)),
2763
- E.label(m.$.incrementValue),
2764
- te({ icon: "line-md:plus", size: "xs" })
2762
+ L.click((x) => k(1n, x)),
2763
+ M.label(g.$.incrementValue),
2764
+ ee({ icon: "line-md:plus", size: "xs" })
2765
2765
  ),
2766
2766
  d.button(
2767
2767
  o.type("button"),
@@ -2769,28 +2769,28 @@ const Br = (e) => {
2769
2769
  "bc-button bc-number-input-steppers-button bc-number-input-steppers-button--decrement"
2770
2770
  ),
2771
2771
  o.disabled(
2772
- T(
2772
+ I(
2773
2773
  y,
2774
2774
  e.disabled ?? !1
2775
- )((w, g) => !w || g)
2775
+ )((x, m) => !x || m)
2776
2776
  ),
2777
- L.click((w) => x(-1n, w)),
2778
- E.label(m.$.decrementValue),
2779
- te({ icon: "line-md:minus", size: "xs" })
2777
+ L.click((x) => k(-1n, x)),
2778
+ M.label(g.$.decrementValue),
2779
+ ee({ icon: "line-md:minus", size: "xs" })
2780
2780
  )
2781
2781
  );
2782
- }) : null, p = c != null && l != null ? R(l, c) : c ?? l, b = s ? (m) => {
2783
- const y = Pt(m);
2782
+ }) : null, p = c != null && l != null ? U(l, c) : c ?? l, f = s ? (g) => {
2783
+ const y = Pt(g);
2784
2784
  y != null && s(u(y));
2785
- } : void 0, k = i ? (m) => {
2786
- const y = Pt(m);
2785
+ } : void 0, S = i ? (g) => {
2786
+ const y = Pt(g);
2787
2787
  y != null && i(u(y));
2788
2788
  } : void 0;
2789
2789
  return Ee({
2790
2790
  ...e,
2791
- value: v.map(t, (m) => m.toString()),
2792
- onChange: b,
2793
- onInput: k,
2791
+ value: h.map(t, (g) => g.toString()),
2792
+ onChange: f,
2793
+ onInput: S,
2794
2794
  after: p,
2795
2795
  mask: null,
2796
2796
  allowMode: "digits",
@@ -2805,26 +2805,26 @@ const Br = (e) => {
2805
2805
  }
2806
2806
  }, Ur = (e) => {
2807
2807
  const { value: t, step: n, min: a, max: r, onChange: s, onInput: i, after: c } = e, u = (y) => {
2808
- const h = a != null ? v.get(a) : void 0, x = r != null ? v.get(r) : void 0;
2809
- return h != null && y < h ? h : x != null && y > x ? x : y;
2808
+ const b = a != null ? h.get(a) : void 0, k = r != null ? h.get(r) : void 0;
2809
+ return b != null && y < b ? b : k != null && y > k ? k : y;
2810
2810
  }, l = n != null ? ae(ie, (y) => {
2811
- const h = T(
2811
+ const b = I(
2812
2812
  t,
2813
2813
  a
2814
- )((g, f) => {
2815
- const C = g ?? 0n;
2816
- return f == null ? !0 : C > f;
2817
- }), x = T(
2814
+ )((m, v) => {
2815
+ const w = m ?? 0n;
2816
+ return v == null ? !0 : w > v;
2817
+ }), k = I(
2818
2818
  t,
2819
2819
  r
2820
- )((g, f) => {
2821
- const C = g ?? 0n;
2822
- return f == null ? !0 : C < f;
2823
- }), w = (g, f) => {
2824
- const C = v.get(t) ?? 0n, $ = v.get(n), D = f?.shiftKey ? 10n : 1n, _ = C + $ * D * g, I = a != null ? v.get(a) : void 0, V = r != null ? v.get(r) : void 0;
2825
- if (g < 0n && I != null && _ < I || g > 0n && V != null && _ > V) return;
2820
+ )((m, v) => {
2821
+ const w = m ?? 0n;
2822
+ return v == null ? !0 : w < v;
2823
+ }), x = (m, v) => {
2824
+ const w = h.get(t) ?? 0n, $ = h.get(n), D = v?.shiftKey ? 10n : 1n, _ = w + $ * D * m, T = a != null ? h.get(a) : void 0, V = r != null ? h.get(r) : void 0;
2825
+ if (m < 0n && T != null && _ < T || m > 0n && V != null && _ > V) return;
2826
2826
  const O = u(_);
2827
- O !== C && s && s(O);
2827
+ O !== w && s && s(O);
2828
2828
  };
2829
2829
  return pt(
2830
2830
  o.class("bc-number-input-steppers"),
@@ -2834,14 +2834,14 @@ const Br = (e) => {
2834
2834
  "bc-button bc-number-input-steppers-button bc-number-input-steppers-button--increment"
2835
2835
  ),
2836
2836
  o.disabled(
2837
- T(
2838
- x,
2837
+ I(
2838
+ k,
2839
2839
  e.disabled ?? !1
2840
- )((g, f) => !g || f)
2840
+ )((m, v) => !m || v)
2841
2841
  ),
2842
- L.click((g) => w(1n, g)),
2843
- E.label(y.$.incrementValue),
2844
- te({ icon: "line-md:plus", size: "xs" })
2842
+ L.click((m) => x(1n, m)),
2843
+ M.label(y.$.incrementValue),
2844
+ ee({ icon: "line-md:plus", size: "xs" })
2845
2845
  ),
2846
2846
  d.button(
2847
2847
  o.type("button"),
@@ -2849,42 +2849,42 @@ const Br = (e) => {
2849
2849
  "bc-button bc-number-input-steppers-button bc-number-input-steppers-button--decrement"
2850
2850
  ),
2851
2851
  o.disabled(
2852
- T(
2853
- h,
2852
+ I(
2853
+ b,
2854
2854
  e.disabled ?? !1
2855
- )((g, f) => !g || f)
2855
+ )((m, v) => !m || v)
2856
2856
  ),
2857
- L.click((g) => w(-1n, g)),
2858
- E.label(y.$.decrementValue),
2859
- te({ icon: "line-md:minus", size: "xs" })
2857
+ L.click((m) => x(-1n, m)),
2858
+ M.label(y.$.decrementValue),
2859
+ ee({ icon: "line-md:minus", size: "xs" })
2860
2860
  )
2861
2861
  );
2862
2862
  }) : null, p = Me(
2863
2863
  t,
2864
2864
  e.disabled,
2865
2865
  s ?? i
2866
- ), b = c != null && l != null ? R(l, p, c) : c != null ? R(p, c) : l != null ? R(l, p) : p, k = s ? (y) => {
2867
- const h = Lt(y);
2868
- s(h === null ? null : u(h));
2869
- } : void 0, m = i ? (y) => {
2870
- const h = Lt(y);
2871
- i(h === null ? null : u(h));
2866
+ ), f = c != null && l != null ? U(l, p, c) : c != null ? U(p, c) : l != null ? U(l, p) : p, S = s ? (y) => {
2867
+ const b = Lt(y);
2868
+ s(b === null ? null : u(b));
2869
+ } : void 0, g = i ? (y) => {
2870
+ const b = Lt(y);
2871
+ i(b === null ? null : u(b));
2872
2872
  } : void 0;
2873
2873
  return Ee({
2874
2874
  ...e,
2875
- value: v.map(t, (y) => y == null ? "" : y.toString()),
2876
- onChange: k,
2877
- onInput: m,
2878
- after: b,
2875
+ value: h.map(t, (y) => y == null ? "" : y.toString()),
2876
+ onChange: S,
2877
+ onInput: g,
2878
+ after: f,
2879
2879
  mask: null,
2880
2880
  allowMode: "digits",
2881
2881
  class: "bc-number-input"
2882
2882
  });
2883
2883
  }, Fr = (e) => {
2884
2884
  const { value: t, onChange: n, onBlur: a, before: r } = e, s = G(""), i = (u) => {
2885
- n?.(v.get(t).filter((l) => l !== u));
2885
+ n?.(h.get(t).filter((l) => l !== u));
2886
2886
  }, c = () => {
2887
- const u = s.value.trim(), l = v.get(t);
2887
+ const u = s.value.trim(), l = h.get(t);
2888
2888
  u === "" || l.includes(u) || (s.set(""), n?.([...l, u]));
2889
2889
  };
2890
2890
  return ce({
@@ -2894,7 +2894,7 @@ const Br = (e) => {
2894
2894
  size: e.size,
2895
2895
  color: "neutral"
2896
2896
  }),
2897
- input: R(
2897
+ input: U(
2898
2898
  o.class("bc-input-container__tags"),
2899
2899
  Le(
2900
2900
  t,
@@ -2923,7 +2923,7 @@ function qe(e) {
2923
2923
  ...t,
2924
2924
  input: pe[e.inputType](
2925
2925
  fe(t),
2926
- o.value(v.map(n, e.valueToString)),
2926
+ o.value(h.map(n, e.valueToString)),
2927
2927
  o.class("bc-input"),
2928
2928
  a != null ? L.blur(X(a)) : W,
2929
2929
  r != null ? L.change(X((i) => r(e.parseValue(s, i)))) : W
@@ -2941,7 +2941,7 @@ function Je(e) {
2941
2941
  input: pe[e.inputType](
2942
2942
  fe(t),
2943
2943
  o.value(
2944
- v.map(n, (p) => p == null ? "" : e.valueToString(p))
2944
+ h.map(n, (p) => p == null ? "" : e.valueToString(p))
2945
2945
  ),
2946
2946
  o.class("bc-input"),
2947
2947
  a != null ? L.blur(X(a)) : W,
@@ -2956,7 +2956,7 @@ function Je(e) {
2956
2956
  )
2957
2957
  ) : W
2958
2958
  ),
2959
- after: i != null ? R(u, i) : u
2959
+ after: i != null ? U(u, i) : u
2960
2960
  })
2961
2961
  );
2962
2962
  };
@@ -2996,7 +2996,7 @@ const jr = qe({
2996
2996
  input: pe["datetime-local"](
2997
2997
  fe(e),
2998
2998
  o.value(
2999
- v.map(t, (s) => ga(Number(s.epochMilliseconds)))
2999
+ h.map(t, (s) => ga(Number(s.epochMilliseconds)))
3000
3000
  ),
3001
3001
  o.class("bc-input"),
3002
3002
  n != null ? L.blur(X(n)) : W,
@@ -3019,7 +3019,7 @@ const jr = qe({
3019
3019
  input: pe["datetime-local"](
3020
3020
  fe(e),
3021
3021
  o.value(
3022
- v.map(
3022
+ h.map(
3023
3023
  t,
3024
3024
  (l) => l == null ? null : ma(Number(l.epochMilliseconds))
3025
3025
  )
@@ -3037,7 +3037,7 @@ const jr = qe({
3037
3037
  )
3038
3038
  ) : W
3039
3039
  ),
3040
- after: s != null ? R(c, s) : c
3040
+ after: s != null ? U(c, s) : c
3041
3041
  })
3042
3042
  );
3043
3043
  }, Jr = (e) => {
@@ -3047,12 +3047,12 @@ const jr = qe({
3047
3047
  ...e,
3048
3048
  input: pe["datetime-local"](
3049
3049
  fe(e),
3050
- o.value(v.map(t, (s) => s.toJSON())),
3050
+ o.value(h.map(t, (s) => s.toJSON())),
3051
3051
  o.class("bc-input"),
3052
3052
  n != null ? L.blur(X(n)) : W,
3053
3053
  a != null ? L.change(
3054
3054
  X((s) => {
3055
- const i = r.PlainDateTime.from(s), c = v.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
3055
+ const i = r.PlainDateTime.from(s), c = h.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
3056
3056
  return a(r.ZonedDateTime.from({ ...i, timeZone: c }));
3057
3057
  })
3058
3058
  ) : W
@@ -3066,25 +3066,25 @@ const jr = qe({
3066
3066
  ...e,
3067
3067
  input: pe["datetime-local"](
3068
3068
  fe(e),
3069
- o.value(v.map(t, (l) => l?.toJSON())),
3069
+ o.value(h.map(t, (l) => l?.toJSON())),
3070
3070
  o.class("bc-input"),
3071
3071
  n != null ? L.blur(X(n)) : W,
3072
3072
  a != null ? L.change(
3073
3073
  X((l) => {
3074
3074
  if (l === "") return a(null);
3075
- const p = u.PlainDateTime.from(l), b = v.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
3076
- return a(u.ZonedDateTime.from({ ...p, timeZone: b }));
3075
+ const p = u.PlainDateTime.from(l), f = h.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
3076
+ return a(u.ZonedDateTime.from({ ...p, timeZone: f }));
3077
3077
  })
3078
3078
  ) : W,
3079
3079
  r != null ? L.input(
3080
3080
  X((l) => {
3081
3081
  if (l === "") return r(null);
3082
- const p = u.PlainDateTime.from(l), b = v.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
3083
- return r(u.ZonedDateTime.from({ ...p, timeZone: b }));
3082
+ const p = u.PlainDateTime.from(l), f = h.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
3083
+ return r(u.ZonedDateTime.from({ ...p, timeZone: f }));
3084
3084
  })
3085
3085
  ) : W
3086
3086
  ),
3087
- after: s != null ? R(c, s) : c
3087
+ after: s != null ? U(c, s) : c
3088
3088
  })
3089
3089
  );
3090
3090
  }, Qr = qe({
@@ -3101,7 +3101,7 @@ const jr = qe({
3101
3101
  (a) => Ee({
3102
3102
  ...e,
3103
3103
  // Map Temporal value to MM-DD string
3104
- value: v.map(t, (r) => r.toString()),
3104
+ value: h.map(t, (r) => r.toString()),
3105
3105
  onChange: n != null ? (r) => n(a.PlainMonthDay.from(`--${r}`)) : void 0,
3106
3106
  onInput: void 0,
3107
3107
  mask: "99-99",
@@ -3113,12 +3113,12 @@ const jr = qe({
3113
3113
  return ve(
3114
3114
  (c) => Ee({
3115
3115
  ...e,
3116
- value: v.map(t, (u) => u?.toString() ?? ""),
3116
+ value: h.map(t, (u) => u?.toString() ?? ""),
3117
3117
  onChange: n != null ? (u) => n(u === "" ? null : c.PlainMonthDay.from(`--${u}`)) : void 0,
3118
3118
  onInput: a != null ? (u) => a(u === "" ? null : c.PlainMonthDay.from(`--${u}`)) : void 0,
3119
3119
  mask: "99-99",
3120
3120
  placeholder: "MM-DD",
3121
- after: r != null ? R(i, r) : i
3121
+ after: r != null ? U(i, r) : i
3122
3122
  })
3123
3123
  );
3124
3124
  }, no = (e) => {
@@ -3126,7 +3126,7 @@ const jr = qe({
3126
3126
  return ve(
3127
3127
  (a) => Ee({
3128
3128
  ...e,
3129
- value: v.map(t, (r) => r.toString()),
3129
+ value: h.map(t, (r) => r.toString()),
3130
3130
  onChange: n ? (r) => n(a.Duration.from(r)) : void 0,
3131
3131
  onInput: void 0,
3132
3132
  ...Mn(a.Duration.from),
@@ -3272,14 +3272,14 @@ function so({
3272
3272
  layout: "horizontal",
3273
3273
  content: Zt(
3274
3274
  o.class("bc-group--align-center bc-group--gap-2"),
3275
- te({
3275
+ ee({
3276
3276
  icon: "ic:twotone-language",
3277
3277
  size: "lg",
3278
3278
  color: "neutral",
3279
3279
  title: a.$.locale
3280
3280
  }),
3281
3281
  Gt({
3282
- options: v.map(
3282
+ options: h.map(
3283
3283
  e,
3284
3284
  (i) => i.map((c) => {
3285
3285
  let u = c.name;
@@ -3320,42 +3320,42 @@ function xa({
3320
3320
  onClose: c,
3321
3321
  class: u
3322
3322
  } = {}, ...l) {
3323
- const p = v.map(i, (b) => b != null);
3323
+ const p = h.map(i, (f) => f != null);
3324
3324
  return d.section(
3325
3325
  o.class(
3326
- T(
3326
+ I(
3327
3327
  n,
3328
3328
  p,
3329
3329
  t,
3330
3330
  e,
3331
3331
  u
3332
3332
  )(
3333
- (b, k, m, y, h) => [
3333
+ (f, S, g, y, b) => [
3334
3334
  ya(
3335
- b,
3336
- k,
3337
- m,
3335
+ f,
3336
+ S,
3337
+ g,
3338
3338
  y,
3339
- h
3339
+ b
3340
3340
  )
3341
3341
  ].join(" ")
3342
3342
  )
3343
3343
  ),
3344
3344
  o.style(
3345
- T(
3345
+ I(
3346
3346
  a,
3347
3347
  r
3348
3348
  )(
3349
- (b, k) => wa(b, k)
3349
+ (f, S) => wa(f, S)
3350
3350
  )
3351
3351
  ),
3352
- E.live("polite"),
3353
- E.busy(e),
3352
+ M.live("polite"),
3353
+ M.busy(e),
3354
3354
  Q(
3355
3355
  e,
3356
3356
  () => d.div(
3357
3357
  o.class("bc-notification__visual bc-notification__loader"),
3358
- te({
3358
+ ee({
3359
3359
  icon: "line-md:loading-twotone-loop",
3360
3360
  size: "lg",
3361
3361
  color: a,
@@ -3366,7 +3366,7 @@ function xa({
3366
3366
  p,
3367
3367
  () => d.div(
3368
3368
  o.class("bc-notification__visual bc-notification__icon"),
3369
- te({
3369
+ ee({
3370
3370
  icon: i,
3371
3371
  size: "lg",
3372
3372
  color: a
@@ -3374,7 +3374,7 @@ function xa({
3374
3374
  ),
3375
3375
  () => d.div(
3376
3376
  o.class("bc-notification__visual bc-notification__accent"),
3377
- E.hidden(!0)
3377
+ M.hidden(!0)
3378
3378
  )
3379
3379
  )
3380
3380
  ),
@@ -3430,26 +3430,26 @@ const Sa = new ka(), pn = {
3430
3430
  l >= 0 && n.splice(l, 1);
3431
3431
  };
3432
3432
  }
3433
- const r = [], s = ({ dismissAfter: u, onClose: l, animation: p = { fade: !0 }, ...b }, ...k) => {
3434
- t.update((h) => h + 1);
3435
- const m = u != null ? typeof u == "number" ? On(u * 1e3) : u : void 0, y = {
3433
+ const r = [], s = ({ dismissAfter: u, onClose: l, animation: p = { fade: !0 }, ...f }, ...S) => {
3434
+ t.update((b) => b + 1);
3435
+ const g = u != null ? typeof u == "number" ? On(u * 1e3) : u : void 0, y = {
3436
3436
  animation: p,
3437
- class: v.toSignal(b.class),
3438
- loading: v.toSignal(b.loading ?? !1),
3439
- withCloseButton: v.toSignal(
3440
- b.withCloseButton == null && u == null ? !0 : b.withCloseButton ?? !0
3437
+ class: h.toSignal(f.class),
3438
+ loading: h.toSignal(f.loading ?? !1),
3439
+ withCloseButton: h.toSignal(
3440
+ f.withCloseButton == null && u == null ? !0 : f.withCloseButton ?? !0
3441
3441
  ),
3442
- withBorder: v.toSignal(b.withBorder ?? !1),
3443
- color: v.toSignal(b.color ?? "primary"),
3444
- radius: v.toSignal(b.radius ?? "md"),
3445
- title: b.title ?? W,
3446
- icon: v.toSignal(b.icon),
3447
- children: k,
3448
- listenRequestClose: (h) => (r.push(h), l?.(), () => {
3442
+ withBorder: h.toSignal(f.withBorder ?? !1),
3443
+ color: h.toSignal(f.color ?? "primary"),
3444
+ radius: h.toSignal(f.radius ?? "md"),
3445
+ title: f.title ?? W,
3446
+ icon: h.toSignal(f.icon),
3447
+ children: S,
3448
+ listenRequestClose: (b) => (r.push(b), l?.(), () => {
3449
3449
  }),
3450
- delayedClose: m
3450
+ delayedClose: g
3451
3451
  };
3452
- n.forEach((h) => h(y));
3452
+ n.forEach((b) => b(y));
3453
3453
  }, i = () => {
3454
3454
  r.forEach((u) => u()), r.length = 0;
3455
3455
  }, c = Sa.attach({ show: s, clear: i });
@@ -3517,7 +3517,7 @@ function io({
3517
3517
  defaultAppearance: t ? n : "light",
3518
3518
  appearancePreferenceKey: a
3519
3519
  }), r && c(pn, { position: s }), In.attach(u(Ne));
3520
- const l = R(
3520
+ const l = U(
3521
3521
  t ? Ln() : W,
3522
3522
  va(),
3523
3523
  r ? Ca() : W,
@@ -3541,31 +3541,31 @@ function co({
3541
3541
  search: u,
3542
3542
  nameddest: l,
3543
3543
  viewrect: p,
3544
- highlight: b,
3545
- allowfullscreen: k = !1
3544
+ highlight: f,
3545
+ allowfullscreen: S = !1
3546
3546
  }) {
3547
- const m = v.toSignal(
3547
+ const g = h.toSignal(
3548
3548
  e
3549
- ).mapAsync(async (h) => {
3550
- if (h instanceof Blob) {
3551
- const x = await h.arrayBuffer(), w = new Blob([x], { type: "application/pdf" });
3552
- return URL.createObjectURL(w);
3549
+ ).mapAsync(async (b) => {
3550
+ if (b instanceof Blob) {
3551
+ const k = await b.arrayBuffer(), x = new Blob([k], { type: "application/pdf" });
3552
+ return URL.createObjectURL(x);
3553
3553
  } else {
3554
- if (h instanceof ArrayBuffer)
3554
+ if (b instanceof ArrayBuffer)
3555
3555
  return URL.createObjectURL(
3556
- new Blob([h], { type: "application/pdf" })
3556
+ new Blob([b], { type: "application/pdf" })
3557
3557
  );
3558
- if (h instanceof Uint8Array)
3558
+ if (b instanceof Uint8Array)
3559
3559
  return URL.createObjectURL(
3560
- new Blob([new Uint8Array(h)], { type: "application/pdf" })
3560
+ new Blob([new Uint8Array(b)], { type: "application/pdf" })
3561
3561
  );
3562
- if (typeof h == "string") {
3563
- const w = await (await fetch(h)).arrayBuffer(), g = new Blob([w], { type: "application/pdf" });
3564
- return URL.createObjectURL(g);
3562
+ if (typeof b == "string") {
3563
+ const x = await (await fetch(b)).arrayBuffer(), m = new Blob([x], { type: "application/pdf" });
3564
+ return URL.createObjectURL(m);
3565
3565
  }
3566
3566
  }
3567
- }, null), y = T(
3568
- m,
3567
+ }, null), y = I(
3568
+ g,
3569
3569
  t,
3570
3570
  n,
3571
3571
  a,
@@ -3576,36 +3576,36 @@ function co({
3576
3576
  u,
3577
3577
  l,
3578
3578
  p,
3579
- b
3580
- )((h, x, w, g, f, C, $, D, _, I, V, O) => {
3581
- if (h == null) return null;
3582
- const B = [];
3583
- x === !1 && B.push("toolbar=0"), w != null && w > 0 && B.push(`page=${w}`), g != null && g > 0 && B.push(`zoom=${g}`), f != null && B.push(`view=${f}`), C != null && B.push(`pagemode=${C}`), $ === !1 && B.push("scrollbar=0"), D === !1 && B.push("navpanes=0"), _ != null && B.push(`search=${encodeURIComponent(_)}`), I != null && B.push(`nameddest=${encodeURIComponent(I)}`), V != null && B.push(`viewrect=${encodeURIComponent(V)}`), O != null && B.push(`highlight=${encodeURIComponent(O)}`);
3584
- const F = B.join("&");
3585
- return F ? `${h}#${F}` : h;
3579
+ f
3580
+ )((b, k, x, m, v, w, $, D, _, T, V, O) => {
3581
+ if (b == null) return null;
3582
+ const E = [];
3583
+ k === !1 && E.push("toolbar=0"), x != null && x > 0 && E.push(`page=${x}`), m != null && m > 0 && E.push(`zoom=${m}`), v != null && E.push(`view=${v}`), w != null && E.push(`pagemode=${w}`), $ === !1 && E.push("scrollbar=0"), D === !1 && E.push("navpanes=0"), _ != null && E.push(`search=${encodeURIComponent(_)}`), T != null && E.push(`nameddest=${encodeURIComponent(T)}`), V != null && E.push(`viewrect=${encodeURIComponent(V)}`), O != null && E.push(`highlight=${encodeURIComponent(O)}`);
3584
+ const N = E.join("&");
3585
+ return N ? `${b}#${N}` : b;
3586
3586
  });
3587
- return m.on((h, x) => {
3588
- x != null && URL.revokeObjectURL(x);
3587
+ return g.on((b, k) => {
3588
+ k != null && URL.revokeObjectURL(k);
3589
3589
  }), d.div(
3590
3590
  oe(() => {
3591
- const h = m.value;
3592
- h != null && URL.revokeObjectURL(h);
3591
+ const b = g.value;
3592
+ b != null && URL.revokeObjectURL(b);
3593
3593
  }),
3594
3594
  o.class("h-full w-full"),
3595
3595
  // could also use embed or object. IFrame seems to work on Safari.
3596
3596
  d.iframe(
3597
3597
  o.class("h-full w-full"),
3598
- o.allowfullscreen(k),
3598
+ o.allowfullscreen(S),
3599
3599
  o.title("PDF Preview"),
3600
3600
  o.loading("lazy"),
3601
3601
  // Force iframe reload when URL changes (including fragment changes)
3602
3602
  // by manually updating src instead of using attr.src
3603
- ne((h) => {
3604
- const x = h;
3605
- let w = !0;
3606
- return y.on((g) => {
3607
- g != null && (w ? (x.src = g, w = !1) : (x.src = "about:blank", setTimeout(() => {
3608
- x.src = g;
3603
+ ne((b) => {
3604
+ const k = b;
3605
+ let x = !0;
3606
+ return y.on((m) => {
3607
+ m != null && (x ? (k.src = m, x = !1) : (k.src = "about:blank", setTimeout(() => {
3608
+ k.src = m;
3609
3609
  }, 50)));
3610
3610
  }), W;
3611
3611
  })
@@ -3624,29 +3624,29 @@ function uo({
3624
3624
  scrollModeOnLoad: u,
3625
3625
  spreadModeOnLoad: l,
3626
3626
  enableScripting: p,
3627
- enablePrinting: b,
3628
- viewerUrl: k = null,
3629
- allowfullscreen: m = !0,
3627
+ enablePrinting: f,
3628
+ viewerUrl: S = null,
3629
+ allowfullscreen: g = !0,
3630
3630
  class: y = null
3631
3631
  }) {
3632
- const h = v.toSignal(
3632
+ const b = h.toSignal(
3633
3633
  e
3634
- ).mapAsync(async (w) => {
3635
- if (w instanceof Blob)
3636
- return URL.createObjectURL(w);
3637
- if (w instanceof ArrayBuffer)
3634
+ ).mapAsync(async (x) => {
3635
+ if (x instanceof Blob)
3636
+ return URL.createObjectURL(x);
3637
+ if (x instanceof ArrayBuffer)
3638
3638
  return URL.createObjectURL(
3639
- new Blob([w], { type: "application/pdf" })
3639
+ new Blob([x], { type: "application/pdf" })
3640
3640
  );
3641
- if (w instanceof Uint8Array)
3641
+ if (x instanceof Uint8Array)
3642
3642
  return URL.createObjectURL(
3643
- new Blob([new Uint8Array(w)], { type: "application/pdf" })
3643
+ new Blob([new Uint8Array(x)], { type: "application/pdf" })
3644
3644
  );
3645
- if (typeof w == "string")
3646
- return w;
3647
- }, null), x = T(
3648
- h,
3649
- k,
3645
+ if (typeof x == "string")
3646
+ return x;
3647
+ }, null), k = I(
3648
+ b,
3649
+ S,
3650
3650
  t,
3651
3651
  n,
3652
3652
  a,
@@ -3657,31 +3657,31 @@ function uo({
3657
3657
  u,
3658
3658
  l,
3659
3659
  p,
3660
- b
3661
- )((w, g, f, C, $, D, _, I, V, O, B, F, ee) => {
3662
- if (w == null) return null;
3663
- const H = g ?? "https://mozilla.github.io/pdf.js/web/viewer.html", U = new URLSearchParams();
3664
- U.set("file", encodeURIComponent(w));
3660
+ f
3661
+ )((x, m, v, w, $, D, _, T, V, O, E, N, te) => {
3662
+ if (x == null) return null;
3663
+ const H = m ?? "https://mozilla.github.io/pdf.js/web/viewer.html", F = new URLSearchParams();
3664
+ F.set("file", encodeURIComponent(x));
3665
3665
  const Y = [];
3666
- f != null && f > 0 && Y.push(`page=${f}`), C != null && (typeof C == "string" ? Y.push(`zoom=${C}`) : Y.push(`zoom=${C}`)), $ != null && Y.push(`pagemode=${$}`), D != null && Y.push(`nameddest=${encodeURIComponent(D)}`), _ != null && Y.push(`search=${encodeURIComponent(_)}`), I != null && Y.push(`textLayer=${I}`), V != null && Y.push(`sidebar=${V}`), O != null && Y.push(`scrollMode=${O}`), B != null && Y.push(`spreadMode=${B}`), F != null && Y.push(`enableScripting=${F ? "1" : "0"}`), ee != null && Y.push(`enablePrinting=${ee ? "1" : "0"}`);
3666
+ v != null && v > 0 && Y.push(`page=${v}`), w != null && (typeof w == "string" ? Y.push(`zoom=${w}`) : Y.push(`zoom=${w}`)), $ != null && Y.push(`pagemode=${$}`), D != null && Y.push(`nameddest=${encodeURIComponent(D)}`), _ != null && Y.push(`search=${encodeURIComponent(_)}`), T != null && Y.push(`textLayer=${T}`), V != null && Y.push(`sidebar=${V}`), O != null && Y.push(`scrollMode=${O}`), E != null && Y.push(`spreadMode=${E}`), N != null && Y.push(`enableScripting=${N ? "1" : "0"}`), te != null && Y.push(`enablePrinting=${te ? "1" : "0"}`);
3667
3667
  const se = Y.length > 0 ? `#${Y.join("&")}` : "";
3668
- return `${H}?${U.toString()}${se}`;
3668
+ return `${H}?${F.toString()}${se}`;
3669
3669
  });
3670
- return h.on((w, g) => {
3671
- g != null && g.startsWith("blob:") && URL.revokeObjectURL(g);
3670
+ return b.on((x, m) => {
3671
+ m != null && m.startsWith("blob:") && URL.revokeObjectURL(m);
3672
3672
  }), d.div(
3673
3673
  oe(() => {
3674
- const w = h.value;
3675
- w != null && w.startsWith("blob:") && URL.revokeObjectURL(w);
3674
+ const x = b.value;
3675
+ x != null && x.startsWith("blob:") && URL.revokeObjectURL(x);
3676
3676
  }),
3677
3677
  o.class("bc-pdfjs-preview h-full w-full"),
3678
3678
  o.class(y),
3679
3679
  d.iframe(
3680
3680
  o.class("h-full w-full"),
3681
- o.allowfullscreen(m),
3681
+ o.allowfullscreen(g),
3682
3682
  o.title("PDF Preview"),
3683
3683
  o.loading("lazy"),
3684
- o.src(x)
3684
+ o.src(k)
3685
3685
  )
3686
3686
  );
3687
3687
  }
@@ -3689,13 +3689,13 @@ const po = ({ id: e, css: t }) => st("head", d.style(o.id(e), o.innerHTML(t)));
3689
3689
  function ge(e, t) {
3690
3690
  return t == null ? null : d.meta(
3691
3691
  o.name(e),
3692
- o.content(v.map(t, (n) => String(n)))
3692
+ o.content(h.map(t, (n) => String(n)))
3693
3693
  );
3694
3694
  }
3695
3695
  function Z(e, t) {
3696
3696
  return t == null ? null : d.meta(
3697
3697
  o.property(e),
3698
- o.content(v.map(t, (n) => String(n)))
3698
+ o.content(h.map(t, (n) => String(n)))
3699
3699
  );
3700
3700
  }
3701
3701
  function ze(e, t) {
@@ -3703,7 +3703,7 @@ function ze(e, t) {
3703
3703
  }
3704
3704
  function Ia(e, t) {
3705
3705
  return t == null ? null : Q(
3706
- v.map(t, (n) => Array.isArray(n)),
3706
+ h.map(t, (n) => Array.isArray(n)),
3707
3707
  () => ze(e, t),
3708
3708
  () => Z(e, t)
3709
3709
  );
@@ -3736,7 +3736,7 @@ const fo = (e) => {
3736
3736
  "twitter:image:alt",
3737
3737
  Pe(e.twitterImageAlt, e.imageAlt)
3738
3738
  )
3739
- ), e.canonical != null && v.get(e.canonical) != null && t.push(d.link(o.rel("canonical"), o.href(e.canonical))), t.push(ge("robots", e.robots)), t.push(ge("keywords", e.keywords)), t.push(ge("author", e.metaAuthor)), st("head", t.filter((n) => n != null).flat());
3739
+ ), e.canonical != null && h.get(e.canonical) != null && t.push(d.link(o.rel("canonical"), o.href(e.canonical))), t.push(ge("robots", e.robots)), t.push(ge("keywords", e.keywords)), t.push(ge("author", e.metaAuthor)), st("head", t.filter((n) => n != null).flat());
3740
3740
  }, ft = ({
3741
3741
  viewTransition: e,
3742
3742
  state: t,
@@ -3786,22 +3786,22 @@ function Ta({
3786
3786
  replace: u,
3787
3787
  target: l,
3788
3788
  rel: p
3789
- }, ...b) {
3789
+ }, ...f) {
3790
3790
  return Q(
3791
3791
  r,
3792
3792
  () => d.span(
3793
3793
  o.class(
3794
- T(
3794
+ I(
3795
3795
  t,
3796
3796
  r
3797
- )((k, m) => Dt(k, m))
3797
+ )((S, g) => Dt(S, g))
3798
3798
  ),
3799
3799
  o.style(
3800
- T(a)(
3801
- (k) => At(k ?? "base")
3800
+ I(a)(
3801
+ (S) => At(S ?? "base")
3802
3802
  )
3803
3803
  ),
3804
- ...b
3804
+ ...f
3805
3805
  ),
3806
3806
  () => it(
3807
3807
  {
@@ -3814,17 +3814,17 @@ function Ta({
3814
3814
  })
3815
3815
  },
3816
3816
  o.class(
3817
- T(
3817
+ I(
3818
3818
  t,
3819
3819
  r
3820
- )((k, m) => Dt(k, m))
3820
+ )((S, g) => Dt(S, g))
3821
3821
  ),
3822
3822
  o.style(
3823
- T(n)((k) => At(k ?? "primary"))
3823
+ I(n)((S) => At(S ?? "primary"))
3824
3824
  ),
3825
3825
  l ? o.target(l) : null,
3826
3826
  p ? o.rel(p) : null,
3827
- ...b
3827
+ ...f
3828
3828
  )
3829
3829
  );
3830
3830
  }
@@ -3851,9 +3851,9 @@ function Pa(e, t, n) {
3851
3851
  const l = Array.from(
3852
3852
  new URLSearchParams(u.search).entries()
3853
3853
  ).sort(), p = Array.from(a.entries()).sort();
3854
- return l.length !== p.length ? !1 : l.every(([b, k], m) => {
3855
- const [y, h] = p[m];
3856
- return b === y && k === h;
3854
+ return l.length !== p.length ? !1 : l.every(([f, S], g) => {
3855
+ const [y, b] = p[g];
3856
+ return f === y && S === b;
3857
3857
  });
3858
3858
  } catch {
3859
3859
  return e.pathname === t;
@@ -3863,7 +3863,7 @@ function Pa(e, t, n) {
3863
3863
  }
3864
3864
  }
3865
3865
  function bt(e, t) {
3866
- return t === "exact" ? T(e)((n) => n) : T(e)(
3866
+ return t === "exact" ? I(e)((n) => n) : I(e)(
3867
3867
  (n) => (a) => Pa(a, n, t)
3868
3868
  );
3869
3869
  }
@@ -3876,7 +3876,7 @@ function bo({
3876
3876
  return ae(Ne, (s) => {
3877
3877
  const i = s.matchSignal(
3878
3878
  bt(e, t)
3879
- ), c = T(
3879
+ ), c = I(
3880
3880
  i,
3881
3881
  n
3882
3882
  )((u, l) => l ?? !0 ? u : !1);
@@ -3902,18 +3902,18 @@ function go({
3902
3902
  disableWhenActive: u,
3903
3903
  variant: l = "filled",
3904
3904
  size: p = "md",
3905
- color: b = "base",
3906
- roundedness: k = "sm",
3907
- disabled: m = !1
3905
+ color: f = "base",
3906
+ roundedness: S = "sm",
3907
+ disabled: g = !1
3908
3908
  }, ...y) {
3909
- return c !== void 0 || u !== void 0 ? ae(Ne, (h) => {
3910
- const x = c !== void 0 ? h.matchSignal(bt(e, c)) : T(h.location)(() => !1), w = T(
3911
- x,
3909
+ return c !== void 0 || u !== void 0 ? ae(Ne, (b) => {
3910
+ const k = c !== void 0 ? b.matchSignal(bt(e, c)) : I(b.location)(() => !1), x = I(
3911
+ k,
3912
3912
  u
3913
- )((f, C) => !(C ?? !0) || !c ? !1 : f), g = T(
3914
- m,
3915
- w
3916
- )((f, C) => f || C);
3913
+ )((v, w) => !(w ?? !0) || !c ? !1 : v), m = I(
3914
+ g,
3915
+ x
3916
+ )((v, w) => v || w);
3917
3917
  return Vt(
3918
3918
  {
3919
3919
  href: e,
@@ -3925,9 +3925,9 @@ function go({
3925
3925
  rel: i,
3926
3926
  variant: l,
3927
3927
  size: p,
3928
- color: b,
3929
- roundedness: k,
3930
- disabled: g
3928
+ color: f,
3929
+ roundedness: S,
3930
+ disabled: m
3931
3931
  },
3932
3932
  ...y
3933
3933
  );
@@ -3942,9 +3942,9 @@ function go({
3942
3942
  rel: i,
3943
3943
  variant: l,
3944
3944
  size: p,
3945
- color: b,
3946
- roundedness: k,
3947
- disabled: m
3945
+ color: f,
3946
+ roundedness: S,
3947
+ disabled: g
3948
3948
  },
3949
3949
  ...y
3950
3950
  );
@@ -3961,31 +3961,31 @@ function Vt({
3961
3961
  size: u = "md",
3962
3962
  color: l = "base",
3963
3963
  roundedness: p = "sm",
3964
- disabled: b = !1,
3965
- fullWidth: k = !1,
3966
- loading: m = !1
3964
+ disabled: f = !1,
3965
+ fullWidth: S = !1,
3966
+ loading: g = !1
3967
3967
  }, ...y) {
3968
3968
  return Q(
3969
- b ?? !1,
3969
+ f ?? !1,
3970
3970
  () => d.span(
3971
3971
  o.class(
3972
- T(
3972
+ I(
3973
3973
  u,
3974
3974
  p,
3975
- m,
3976
- k
3975
+ g,
3976
+ S
3977
3977
  )(wt)
3978
3978
  ),
3979
3979
  o.style(
3980
- T(
3980
+ I(
3981
3981
  c,
3982
3982
  l,
3983
- b
3983
+ f
3984
3984
  )(
3985
- (h, x, w) => xt(
3986
- h ?? "filled",
3987
- x ?? "base",
3988
- w
3985
+ (b, k, x) => xt(
3986
+ b ?? "filled",
3987
+ k ?? "base",
3988
+ x
3989
3989
  )
3990
3990
  )
3991
3991
  ),
@@ -4002,23 +4002,23 @@ function Vt({
4002
4002
  })
4003
4003
  },
4004
4004
  o.class(
4005
- T(
4005
+ I(
4006
4006
  u,
4007
4007
  p,
4008
- m,
4009
- k
4008
+ g,
4009
+ S
4010
4010
  )(wt)
4011
4011
  ),
4012
4012
  o.style(
4013
- T(
4013
+ I(
4014
4014
  c,
4015
4015
  l,
4016
- b
4016
+ f
4017
4017
  )(
4018
- (h, x, w) => xt(
4019
- h ?? "filled",
4020
- x ?? "base",
4021
- w
4018
+ (b, k, x) => xt(
4019
+ b ?? "filled",
4020
+ k ?? "base",
4021
+ x
4022
4022
  )
4023
4023
  )
4024
4024
  ),
@@ -4041,7 +4041,7 @@ const La = {
4041
4041
  function mo({ backgroundMode: e = "light" }, ...t) {
4042
4042
  return Nt(
4043
4043
  La,
4044
- v.map(
4044
+ h.map(
4045
4045
  e,
4046
4046
  (n) => ({
4047
4047
  backgroundMode: n
@@ -4050,7 +4050,7 @@ function mo({ backgroundMode: e = "light" }, ...t) {
4050
4050
  () => d.div(
4051
4051
  o.class("bc-sidebar"),
4052
4052
  o.class(
4053
- v.map(
4053
+ h.map(
4054
4054
  e,
4055
4055
  (n) => n === "dark" ? "bc-sidebar--dark-bg" : ""
4056
4056
  )
@@ -4064,7 +4064,7 @@ function Bt({ rail: e, header: t }, ...n) {
4064
4064
  t != null ? d.div(o.class("bc-sidebar-group__header"), t) : null,
4065
4065
  d.div(
4066
4066
  o.class(
4067
- v.map(
4067
+ h.map(
4068
4068
  e ?? !1,
4069
4069
  (a) => a ? "bc-sidebar-group--rail" : ""
4070
4070
  )
@@ -4090,14 +4090,14 @@ function Va(e, ...t) {
4090
4090
  return d.button(
4091
4091
  o.type("button"),
4092
4092
  L.click(e.onClick),
4093
- e.ariaExpanded != null ? E.expanded(
4094
- v.map(
4093
+ e.ariaExpanded != null ? M.expanded(
4094
+ h.map(
4095
4095
  e.ariaExpanded,
4096
4096
  (n) => n
4097
4097
  )
4098
4098
  ) : null,
4099
- e.ariaControls != null ? E.controls(e.ariaControls) : null,
4100
- e.ariaLabel != null ? E.label(e.ariaLabel) : null,
4099
+ e.ariaControls != null ? M.controls(e.ariaControls) : null,
4100
+ e.ariaLabel != null ? M.label(e.ariaLabel) : null,
4101
4101
  ...t
4102
4102
  );
4103
4103
  }
@@ -4106,7 +4106,7 @@ function Ba(e) {
4106
4106
  return e.icon != null && t.push(
4107
4107
  d.span(
4108
4108
  o.class("bc-sidebar-link--icon"),
4109
- te({ icon: e.icon })
4109
+ ee({ icon: e.icon })
4110
4110
  )
4111
4111
  ), t.push(
4112
4112
  d.span(o.class("bc-sidebar-link__content"), e.content)
@@ -4119,7 +4119,7 @@ function Ba(e) {
4119
4119
  L.click((n, a) => {
4120
4120
  e.action?.onClick?.(a);
4121
4121
  }),
4122
- te({ icon: e.action?.icon })
4122
+ ee({ icon: e.action?.icon })
4123
4123
  )
4124
4124
  ), "onClick" in e ? Va(e, ...t) : ae(Ne, (n) => {
4125
4125
  const a = n.matchSignal(
@@ -4142,7 +4142,7 @@ function ho({
4142
4142
  header: n,
4143
4143
  startOpen: a = !0
4144
4144
  }, ...r) {
4145
- const s = v.deriveProp(a), i = he("sidebar-group"), c = `${i}-content`;
4145
+ const s = h.deriveProp(a), i = he("sidebar-group"), c = `${i}-content`;
4146
4146
  return Bt(
4147
4147
  {},
4148
4148
  o.class("bc-sidebar-group-collapsible"),
@@ -4162,7 +4162,7 @@ function ho({
4162
4162
  ariaControls: c,
4163
4163
  right: d.span(
4164
4164
  o.class("bc-sidebar-group-collapsible-indicator"),
4165
- te({ icon: "lucide:chevron-down", color: "base" })
4165
+ ee({ icon: "lucide:chevron-down", color: "base" })
4166
4166
  ),
4167
4167
  content: n
4168
4168
  }),
@@ -4198,7 +4198,7 @@ function He(e, t, n) {
4198
4198
  let s = 0;
4199
4199
  for (; s < a; ) {
4200
4200
  const i = t[r];
4201
- if (!v.get(i.disabled ?? !1))
4201
+ if (!h.get(i.disabled ?? !1))
4202
4202
  return r;
4203
4203
  r += n, r >= a ? r = 0 : r < 0 && (r = a - 1), s++;
4204
4204
  }
@@ -4216,84 +4216,84 @@ function yo(e) {
4216
4216
  orientation: u = "horizontal",
4217
4217
  showContent: l = !0,
4218
4218
  ariaLabel: p
4219
- } = e, b = he("tablist"), k = G(-1), m = T(n)((h) => t.find((x) => x.key === h)), y = (h) => {
4220
- if (v.get(c)) return;
4221
- const w = k.value, g = v.get(u) === "horizontal";
4222
- let f = w;
4223
- switch (h.key) {
4224
- case (g ? "ArrowRight" : "ArrowDown"):
4225
- h.preventDefault(), f = He(w, t, 1);
4219
+ } = e, f = he("tablist"), S = G(-1), g = I(n)((b) => t.find((k) => k.key === b)), y = (b) => {
4220
+ if (h.get(c)) return;
4221
+ const x = S.value, m = h.get(u) === "horizontal";
4222
+ let v = x;
4223
+ switch (b.key) {
4224
+ case (m ? "ArrowRight" : "ArrowDown"):
4225
+ b.preventDefault(), v = He(x, t, 1);
4226
4226
  break;
4227
- case (g ? "ArrowLeft" : "ArrowUp"):
4228
- h.preventDefault(), f = He(w, t, -1);
4227
+ case (m ? "ArrowLeft" : "ArrowUp"):
4228
+ b.preventDefault(), v = He(x, t, -1);
4229
4229
  break;
4230
4230
  case "Home":
4231
- h.preventDefault(), f = He(-1, t, 1);
4231
+ b.preventDefault(), v = He(-1, t, 1);
4232
4232
  break;
4233
4233
  case "End":
4234
- h.preventDefault(), f = He(t.length, t, -1);
4234
+ b.preventDefault(), v = He(t.length, t, -1);
4235
4235
  break;
4236
4236
  case "Enter":
4237
4237
  case " ":
4238
- if (h.preventDefault(), w >= 0 && w < t.length) {
4239
- const C = t[w];
4240
- v.get(C.disabled ?? !1) || a?.(C.key);
4238
+ if (b.preventDefault(), x >= 0 && x < t.length) {
4239
+ const w = t[x];
4240
+ h.get(w.disabled ?? !1) || a?.(w.key);
4241
4241
  }
4242
4242
  break;
4243
4243
  }
4244
- f !== w && f >= 0 && f < t.length && (k.set(f), setTimeout(() => {
4245
- const C = document.querySelector(
4246
- `[data-tab-index="${f}"]`
4244
+ v !== x && v >= 0 && v < t.length && (S.set(v), setTimeout(() => {
4245
+ const w = document.querySelector(
4246
+ `[data-tab-index="${v}"]`
4247
4247
  );
4248
- C && C.focus();
4248
+ w && w.focus();
4249
4249
  }, 0));
4250
4250
  };
4251
4251
  return d.div(
4252
4252
  o.class(
4253
- T(
4253
+ I(
4254
4254
  r,
4255
4255
  u,
4256
4256
  c,
4257
4257
  s
4258
4258
  )(
4259
- (h, x, w, g) => Ma(
4260
- h ?? "md",
4261
- x ?? "horizontal",
4262
- w ?? !1,
4263
- g ?? "default"
4259
+ (b, k, x, m) => Ma(
4260
+ b ?? "md",
4261
+ k ?? "horizontal",
4262
+ x ?? !1,
4263
+ m ?? "default"
4264
4264
  )
4265
4265
  )
4266
4266
  ),
4267
4267
  o.style(
4268
- T(
4268
+ I(
4269
4269
  s,
4270
4270
  i
4271
4271
  )(
4272
- (h, x) => Ea(h ?? "default", x ?? "primary")
4272
+ (b, k) => Ea(b ?? "default", k ?? "primary")
4273
4273
  )
4274
4274
  ),
4275
4275
  // Tab list
4276
4276
  d.div(
4277
4277
  o.class("bc-tabs__list"),
4278
4278
  o.role("tablist"),
4279
- o.id(b),
4280
- E.orientation(
4279
+ o.id(f),
4280
+ M.orientation(
4281
4281
  u ?? "horizontal"
4282
4282
  ),
4283
- p ? E.label(p) : R(),
4283
+ p ? M.label(p) : U(),
4284
4284
  L.keydown(y),
4285
- ...t.map((h, x) => {
4286
- const w = T(n)(($) => $ === h.key), g = T(
4285
+ ...t.map((b, k) => {
4286
+ const x = I(n)(($) => $ === b.key), m = I(
4287
4287
  c,
4288
- h.disabled
4289
- )(($, D) => $ || D), f = `${b}-tab-${h.key}`, C = `${b}-panel-${h.key}`;
4288
+ b.disabled
4289
+ )(($, D) => $ || D), v = `${f}-tab-${b.key}`, w = `${f}-panel-${b.key}`;
4290
4290
  return d.button(
4291
4291
  o.type("button"),
4292
4292
  o.class(
4293
- T(
4293
+ I(
4294
4294
  r,
4295
- w,
4296
- g
4295
+ x,
4296
+ m
4297
4297
  )(
4298
4298
  ($, D, _) => Oa(
4299
4299
  $ ?? "md",
@@ -4302,44 +4302,44 @@ function yo(e) {
4302
4302
  )
4303
4303
  )
4304
4304
  ),
4305
- o.id(f),
4305
+ o.id(v),
4306
4306
  o.role("tab"),
4307
4307
  o.tabindex(
4308
- T(
4309
- w,
4310
- k
4311
- )(($, D) => $ || D === x ? 0 : -1)
4308
+ I(
4309
+ x,
4310
+ S
4311
+ )(($, D) => $ || D === k ? 0 : -1)
4312
4312
  ),
4313
- E.selected(w),
4314
- E.controls(C),
4315
- E.disabled(g),
4316
- o.disabled(g),
4317
- lt["tab-index"](String(x)),
4318
- h.ariaLabel ? E.label(h.ariaLabel) : R(),
4313
+ M.selected(x),
4314
+ M.controls(w),
4315
+ M.disabled(m),
4316
+ o.disabled(m),
4317
+ lt["tab-index"](String(k)),
4318
+ b.ariaLabel ? M.label(b.ariaLabel) : U(),
4319
4319
  L.click(($) => {
4320
- $.preventDefault(), v.get(h.disabled ?? !1) || v.get(c) || (a?.(h.key), k.set(x));
4320
+ $.preventDefault(), h.get(b.disabled ?? !1) || h.get(c) || (a?.(b.key), S.set(k));
4321
4321
  }),
4322
4322
  L.focus(() => {
4323
- k.set(x);
4323
+ S.set(k);
4324
4324
  }),
4325
- h.label
4325
+ b.label
4326
4326
  );
4327
4327
  })
4328
4328
  ),
4329
4329
  // Panel
4330
4330
  Q(
4331
4331
  l ?? !0,
4332
- () => Ue(m, (h) => {
4333
- const x = h.$.key, w = x.map((f) => `${b}-tab-${f}`), g = x.map((f) => `${b}-panel-${f}`);
4332
+ () => Ue(g, (b) => {
4333
+ const k = b.$.key, x = k.map((v) => `${f}-tab-${v}`), m = k.map((v) => `${f}-panel-${v}`);
4334
4334
  return d.div(
4335
4335
  o.class("bc-tabs__panels"),
4336
4336
  d.div(
4337
4337
  o.class("bc-tabs__panel"),
4338
- o.id(g),
4338
+ o.id(m),
4339
4339
  o.role("tabpanel"),
4340
4340
  o.tabindex(0),
4341
- E.labelledby(w),
4342
- Rt(h, (f) => f.content())
4341
+ M.labelledby(x),
4342
+ Rt(b, (v) => v.content())
4343
4343
  )
4344
4344
  );
4345
4345
  })
@@ -4355,23 +4355,23 @@ function wo(e) {
4355
4355
  size: u = "md",
4356
4356
  side: l = "right",
4357
4357
  dismissable: p = !0,
4358
- showCloseButton: b = !0,
4359
- onClose: k,
4360
- overlayEffect: m = "opaque",
4358
+ showCloseButton: f = !0,
4359
+ onClose: S,
4360
+ overlayEffect: g = "opaque",
4361
4361
  container: y = "body",
4362
- header: h,
4363
- body: x,
4364
- footer: w
4362
+ header: b,
4363
+ body: k,
4364
+ footer: x
4365
4365
  } = c;
4366
4366
  a = n;
4367
- const g = G("capturing");
4368
- v.on(p, ($) => {
4369
- g.set($ ? "capturing" : "non-capturing");
4367
+ const m = G("capturing");
4368
+ h.on(p, ($) => {
4369
+ m.set($ ? "capturing" : "non-capturing");
4370
4370
  });
4371
- const f = T(
4372
- h != null,
4373
- b
4374
- )(($, D) => $ || D), C = ne(($) => {
4371
+ const v = I(
4372
+ b != null,
4373
+ f
4374
+ )(($, D) => $ || D), w = ne(($) => {
4375
4375
  const D = Re({
4376
4376
  initialStatus: "closed",
4377
4377
  element: $
@@ -4381,25 +4381,25 @@ function wo(e) {
4381
4381
  }), a = () => {
4382
4382
  D.close();
4383
4383
  }, Ze(() => D.open());
4384
- const I = he("drawer"), V = h != null ? `${I}-header` : void 0, O = `${I}-body`;
4384
+ const T = he("drawer"), V = b != null ? `${T}-header` : void 0, O = `${T}-body`;
4385
4385
  return d.div(
4386
4386
  o.class(
4387
- T(
4387
+ I(
4388
4388
  u,
4389
4389
  l,
4390
4390
  D.status
4391
4391
  )(
4392
- (B, F, ee) => `bc-drawer bc-drawer--size-${B} bc-drawer--container-${y} bc-drawer--side-${F} bc-drawer--status-${ee}`
4392
+ (E, N, te) => `bc-drawer bc-drawer--size-${E} bc-drawer--container-${y} bc-drawer--side-${N} bc-drawer--status-${te}`
4393
4393
  )
4394
4394
  ),
4395
4395
  // Essential ARIA attributes for drawer dialog
4396
4396
  o.role("dialog"),
4397
- E.modal(!0),
4398
- ...V ? [E.labelledby(V)] : [],
4399
- E.describedby(O),
4397
+ M.modal(!0),
4398
+ ...V ? [M.labelledby(V)] : [],
4399
+ M.describedby(O),
4400
4400
  o.tabindex(-1),
4401
4401
  // Make drawer focusable for initial focus
4402
- o.id(I),
4402
+ o.id(T),
4403
4403
  lt.focusTrap("true"),
4404
4404
  // Mark as focus trap container
4405
4405
  // Focus trap for keyboard navigation
@@ -4408,24 +4408,24 @@ function wo(e) {
4408
4408
  escapeDeactivates: !1,
4409
4409
  // Let Overlay handle escape key
4410
4410
  initialFocus: () => document.querySelector(
4411
- `#${I} [aria-label="Close drawer"]`
4411
+ `#${T} [aria-label="Close drawer"]`
4412
4412
  ) || null
4413
4413
  }),
4414
- L.mousedown((B) => B.stopPropagation()),
4414
+ L.mousedown((E) => E.stopPropagation()),
4415
4415
  // Prevent overlay click-outside when clicking drawer content
4416
4416
  // Drawer content container
4417
- Rt(f, (B) => _t(B ? {
4417
+ Rt(v, (E) => _t(E ? {
4418
4418
  header: d.div(
4419
4419
  o.class("bc-drawer__header"),
4420
- d.div(o.id(V), h),
4420
+ d.div(o.id(V), b),
4421
4421
  Q(
4422
- b,
4422
+ f,
4423
4423
  () => ae(
4424
4424
  ie,
4425
- (F) => Fe({
4425
+ (N) => Fe({
4426
4426
  size: "sm",
4427
4427
  onClick: r,
4428
- label: F.$.closeDrawer
4428
+ label: N.$.closeDrawer
4429
4429
  })
4430
4430
  )
4431
4431
  )
@@ -4433,29 +4433,29 @@ function wo(e) {
4433
4433
  body: d.div(
4434
4434
  o.class("bc-drawer__body"),
4435
4435
  o.id(O),
4436
- x
4436
+ k
4437
4437
  ),
4438
- footer: w && d.div(o.class("bc-drawer__footer"), w)
4438
+ footer: x && d.div(o.class("bc-drawer__footer"), x)
4439
4439
  } : {
4440
4440
  body: d.div(
4441
4441
  o.class("bc-drawer__body"),
4442
4442
  o.id(O),
4443
- x
4443
+ k
4444
4444
  ),
4445
- footer: w && d.div(o.class("bc-drawer__footer"), w)
4445
+ footer: x && d.div(o.class("bc-drawer__footer"), x)
4446
4446
  }))
4447
4447
  );
4448
4448
  });
4449
4449
  t({
4450
- mode: g,
4451
- effect: m ?? "opaque",
4450
+ mode: m,
4451
+ effect: g ?? "opaque",
4452
4452
  container: y,
4453
- content: C,
4453
+ content: w,
4454
4454
  onClickOutside: () => {
4455
- k?.(), r();
4455
+ S?.(), r();
4456
4456
  },
4457
4457
  onEscape: () => {
4458
- k?.(), r();
4458
+ S?.(), r();
4459
4459
  }
4460
4460
  });
4461
4461
  }, () => {
@@ -4485,10 +4485,10 @@ function xo(e) {
4485
4485
  crossAxisOffset: i = 0,
4486
4486
  showOn: c = "hover-focus"
4487
4487
  } = e, u = he("tooltip");
4488
- return R(
4489
- E.describedby(u),
4488
+ return U(
4489
+ M.describedby(u),
4490
4490
  Ge({
4491
- content: () => R(
4491
+ content: () => U(
4492
4492
  o.class("bc-tooltip"),
4493
4493
  o.role("tooltip"),
4494
4494
  o.id(u),
@@ -4507,14 +4507,14 @@ function xo(e) {
4507
4507
  arrow: (l) => {
4508
4508
  const p = l.map(
4509
4509
  ({
4510
- placement: b
4511
- }) => b.includes("top") ? "down" : b.includes("bottom") ? "up" : b.includes("left") ? "right" : b.includes("right") ? "left" : "up"
4510
+ placement: f
4511
+ }) => f.includes("top") ? "down" : f.includes("bottom") ? "up" : f.includes("left") ? "right" : f.includes("right") ? "left" : "up"
4512
4512
  );
4513
- return R(
4513
+ return U(
4514
4514
  o.class("bc-tooltip__arrow"),
4515
- o.class(p.map((b) => `bc-tooltip__arrow-${b}`)),
4516
- S.transform(
4517
- l.map(({ x: b, y: k }) => b == null && k == null ? "" : b != null ? `translate(${b}px, 0)` : `translate(0, ${k}px)`)
4515
+ o.class(p.map((f) => `bc-tooltip__arrow-${f}`)),
4516
+ C.transform(
4517
+ l.map(({ x: f, y: S }) => f == null && S == null ? "" : f != null ? `translate(${f}px, 0)` : `translate(0, ${S}px)`)
4518
4518
  ),
4519
4519
  Na(p)
4520
4520
  );
@@ -4552,7 +4552,7 @@ function ko({
4552
4552
  o.class("bc-ribbon"),
4553
4553
  // Theme styles via CSS variables
4554
4554
  o.style(
4555
- T(
4555
+ I(
4556
4556
  e,
4557
4557
  n,
4558
4558
  a,
@@ -4577,27 +4577,27 @@ function So(e, t) {
4577
4577
  return zt((c, u) => {
4578
4578
  let l = () => {
4579
4579
  };
4580
- return t((k) => {
4580
+ return t((S) => {
4581
4581
  l = u;
4582
- const m = G(
4582
+ const g = G(
4583
4583
  typeof n != "boolean" || n ? "capturing" : "non-capturing"
4584
4584
  );
4585
4585
  let y = typeof n == "boolean" ? n : !0;
4586
- v.on(n, (x) => {
4587
- y = x, m.set(x ? "capturing" : "non-capturing");
4586
+ h.on(n, (k) => {
4587
+ y = k, g.set(k ? "capturing" : "non-capturing");
4588
4588
  });
4589
- const h = d.div(
4589
+ const b = d.div(
4590
4590
  o.class("bc-lightbox"),
4591
4591
  // Close button (top-end)
4592
4592
  Q(
4593
4593
  a,
4594
4594
  () => ae(
4595
4595
  ie,
4596
- (x) => d.div(
4596
+ (k) => d.div(
4597
4597
  o.class("bc-lightbox__close"),
4598
4598
  Fe({
4599
4599
  size: "md",
4600
- label: x.$.closeModal,
4600
+ label: k.$.closeModal,
4601
4601
  onClick: () => {
4602
4602
  l(), u();
4603
4603
  }
@@ -4611,19 +4611,19 @@ function So(e, t) {
4611
4611
  o.class("bc-lightbox__viewport"),
4612
4612
  // Visual padding applied here
4613
4613
  o.style(
4614
- T(i)(
4615
- (x) => `padding:${typeof x == "number" ? x + "px" : x}`
4614
+ I(i)(
4615
+ (k) => `padding:${typeof k == "number" ? k + "px" : k}`
4616
4616
  )
4617
4617
  ),
4618
4618
  // Content wrapper capped by viewport; overflow is clipped
4619
- d.div(o.class("bc-lightbox__content"), k)
4619
+ d.div(o.class("bc-lightbox__content"), S)
4620
4620
  )
4621
4621
  );
4622
4622
  c({
4623
- mode: m,
4623
+ mode: g,
4624
4624
  effect: r ?? "opaque",
4625
4625
  container: s,
4626
- content: h,
4626
+ content: b,
4627
4627
  onClickOutside: () => {
4628
4628
  y && (l(), u());
4629
4629
  },
@@ -4652,27 +4652,27 @@ function Co({
4652
4652
  }, ...s) {
4653
4653
  const i = G(!0);
4654
4654
  return Q(i, () => {
4655
- const c = v.map(
4655
+ const c = h.map(
4656
4656
  n,
4657
4657
  (u) => !!u || a != null
4658
4658
  );
4659
4659
  return d.div(
4660
4660
  o.class(
4661
- T(
4661
+ I(
4662
4662
  c,
4663
4663
  r
4664
4664
  )((u, l) => Ua(u, l))
4665
4665
  ),
4666
4666
  o.style(
4667
- v.map(e, (u) => Fa(u))
4667
+ h.map(e, (u) => Fa(u))
4668
4668
  ),
4669
4669
  d.div(
4670
4670
  o.class("bc-announcement-bar__content"),
4671
4671
  Q(
4672
- v.map(t, (u) => u != null),
4672
+ h.map(t, (u) => u != null),
4673
4673
  () => d.div(
4674
4674
  o.class("bc-announcement-bar__icon"),
4675
- te({
4675
+ ee({
4676
4676
  icon: t,
4677
4677
  size: "sm",
4678
4678
  accessibility: "decorative"
@@ -4723,37 +4723,37 @@ function Io(e) {
4723
4723
  pip: u = !1,
4724
4724
  playsinline: l = !0,
4725
4725
  width: p,
4726
- height: b,
4727
- progressInterval: k = 1e3,
4728
- seekTo: m,
4726
+ height: f,
4727
+ progressInterval: S = 1e3,
4728
+ seekTo: g,
4729
4729
  config: y,
4730
- onReady: h,
4731
- onStart: x,
4732
- onPlay: w,
4733
- onPause: g,
4734
- onBuffer: f,
4735
- onBufferEnd: C,
4730
+ onReady: b,
4731
+ onStart: k,
4732
+ onPlay: x,
4733
+ onPause: m,
4734
+ onBuffer: v,
4735
+ onBufferEnd: w,
4736
4736
  onEnded: $,
4737
4737
  onError: D,
4738
4738
  onDuration: _,
4739
- onSeek: I,
4739
+ onSeek: T,
4740
4740
  onProgress: V,
4741
4741
  onPlaybackRateChange: O,
4742
- onPlaybackQualityChange: B
4742
+ onPlaybackQualityChange: E
4743
4743
  } = e;
4744
- function F(P) {
4744
+ function N(P) {
4745
4745
  return /\.m3u8(\?|$)/i.test(P);
4746
4746
  }
4747
- function ee(P) {
4747
+ function te(P) {
4748
4748
  try {
4749
- const M = P.canPlayType("application/vnd.apple.mpegurl");
4750
- return M === "probably" || M === "maybe";
4749
+ const B = P.canPlayType("application/vnd.apple.mpegurl");
4750
+ return B === "probably" || B === "maybe";
4751
4751
  } catch {
4752
4752
  return !1;
4753
4753
  }
4754
4754
  }
4755
4755
  const H = G("file");
4756
- let U = null, Y = null, se = null;
4756
+ let F = null, Y = null, se = null;
4757
4757
  function Ie() {
4758
4758
  try {
4759
4759
  se?.destroy();
@@ -4763,20 +4763,20 @@ function Io(e) {
4763
4763
  }
4764
4764
  const q = [];
4765
4765
  q.push(
4766
- v.on(t, (P) => {
4767
- typeof P == "string" && P.length > 0 && ja(P) ? H.value = "youtube" : (H.value = "file", U && de());
4766
+ h.on(t, (P) => {
4767
+ typeof P == "string" && P.length > 0 && ja(P) ? H.value = "youtube" : (H.value = "file", F && de());
4768
4768
  })
4769
4769
  );
4770
4770
  async function de() {
4771
- const P = U;
4771
+ const P = F;
4772
4772
  if (!P) return;
4773
- const M = v.get(t);
4774
- if (typeof M != "string" || M.length === 0) return;
4773
+ const B = h.get(t);
4774
+ if (typeof B != "string" || B.length === 0) return;
4775
4775
  Ie();
4776
4776
  const j = y?.file?.forceHLS ?? !1;
4777
- if (F(M) || j) {
4778
- if (ee(P)) {
4779
- P.setAttribute("src", M);
4777
+ if (N(B) || j) {
4778
+ if (te(P)) {
4779
+ P.setAttribute("src", B);
4780
4780
  try {
4781
4781
  P.load();
4782
4782
  } catch {
@@ -4798,23 +4798,23 @@ function Io(e) {
4798
4798
  } catch {
4799
4799
  }
4800
4800
  const Qe = new xe(y?.hls);
4801
- se = Qe, Qe.attachMedia(P), Qe.loadSource(M);
4801
+ se = Qe, Qe.attachMedia(P), Qe.loadSource(B);
4802
4802
  } else {
4803
- P.setAttribute("src", M);
4803
+ P.setAttribute("src", B);
4804
4804
  try {
4805
4805
  P.load();
4806
4806
  } catch {
4807
4807
  }
4808
4808
  }
4809
4809
  } else {
4810
- P.setAttribute("src", M);
4810
+ P.setAttribute("src", B);
4811
4811
  try {
4812
4812
  P.load();
4813
4813
  } catch {
4814
4814
  }
4815
4815
  }
4816
4816
  } catch (J) {
4817
- D?.(J), P.setAttribute("src", M);
4817
+ D?.(J), P.setAttribute("src", B);
4818
4818
  try {
4819
4819
  P.load();
4820
4820
  } catch {
@@ -4822,7 +4822,7 @@ function Io(e) {
4822
4822
  }
4823
4823
  return;
4824
4824
  }
4825
- P.setAttribute("src", M);
4825
+ P.setAttribute("src", B);
4826
4826
  try {
4827
4827
  P.load();
4828
4828
  } catch {
@@ -4830,11 +4830,11 @@ function Io(e) {
4830
4830
  }
4831
4831
  function ye() {
4832
4832
  Y?.();
4833
- const P = v.get(k) ?? 1e3;
4833
+ const P = h.get(S) ?? 1e3;
4834
4834
  Y = Ct(() => {
4835
- const M = U;
4836
- if (!M) return;
4837
- const j = M.duration || 0, J = M.currentTime || 0, Oe = M.buffered?.length ? M.buffered.end(M.buffered.length - 1) : 0;
4835
+ const B = F;
4836
+ if (!B) return;
4837
+ const j = B.duration || 0, J = B.currentTime || 0, Oe = B.buffered?.length ? B.buffered.end(B.buffered.length - 1) : 0;
4838
4838
  V?.({
4839
4839
  played: j > 0 ? J / j : 0,
4840
4840
  playedSeconds: J,
@@ -4849,38 +4849,38 @@ function Io(e) {
4849
4849
  }
4850
4850
  const De = d.video(
4851
4851
  ne((P) => {
4852
- U = P, h?.();
4852
+ F = P, b?.();
4853
4853
  try {
4854
- U.playbackRate = v.get(c) ?? 1;
4854
+ F.playbackRate = h.get(c) ?? 1;
4855
4855
  } catch {
4856
4856
  }
4857
- U.muted = !!(v.get(i) ?? !1), U.loop = !!(v.get(a) ?? !1), U.controls = !!(v.get(r) ?? !1), U.playsInline != null && (!!(v.get(l) ?? !0) ? U.setAttribute("playsinline", "") : U.removeAttribute("playsinline")), v.get(n) && (U.play?.().catch(() => {
4858
- }), x?.());
4857
+ F.muted = !!(h.get(i) ?? !1), F.loop = !!(h.get(a) ?? !1), F.controls = !!(h.get(r) ?? !1), F.playsInline != null && (!!(h.get(l) ?? !0) ? F.setAttribute("playsinline", "") : F.removeAttribute("playsinline")), h.get(n) && (F.play?.().catch(() => {
4858
+ }), k?.());
4859
4859
  try {
4860
- const M = !!(v.get(u) ?? !1), j = document, J = U;
4861
- M ? typeof J.requestPictureInPicture == "function" && j.pictureInPictureElement !== U && J.requestPictureInPicture().catch(() => {
4862
- }) : j.pictureInPictureElement === U && typeof j.exitPictureInPicture == "function" && j.exitPictureInPicture().catch(() => {
4860
+ const B = !!(h.get(u) ?? !1), j = document, J = F;
4861
+ B ? typeof J.requestPictureInPicture == "function" && j.pictureInPictureElement !== F && J.requestPictureInPicture().catch(() => {
4862
+ }) : j.pictureInPictureElement === F && typeof j.exitPictureInPicture == "function" && j.exitPictureInPicture().catch(() => {
4863
4863
  });
4864
4864
  } catch {
4865
4865
  }
4866
4866
  ye(), de();
4867
4867
  }),
4868
4868
  // size
4869
- S.width(
4870
- v.map(p, we)
4869
+ C.width(
4870
+ h.map(p, we)
4871
4871
  ),
4872
- S.height(
4873
- v.map(b, we)
4872
+ C.height(
4873
+ h.map(f, we)
4874
4874
  ),
4875
4875
  // Events
4876
- L.play(() => w?.()),
4876
+ L.play(() => x?.()),
4877
4877
  L.playing(() => {
4878
- x?.(), C?.();
4878
+ k?.(), w?.();
4879
4879
  }),
4880
- L.pause(() => g?.()),
4881
- L.waiting(() => f?.()),
4880
+ L.pause(() => m?.()),
4881
+ L.waiting(() => v?.()),
4882
4882
  L.canplay(() => {
4883
- const P = U?.duration;
4883
+ const P = F?.duration;
4884
4884
  P != null && Number.isFinite(P) && _?.(P);
4885
4885
  }),
4886
4886
  L.ended(() => $?.()),
@@ -4890,40 +4890,40 @@ function Io(e) {
4890
4890
  );
4891
4891
  let Ae = null, z = null, Te = null;
4892
4892
  function $e() {
4893
- const P = v.get(t);
4894
- !Ae || typeof P != "string" || Ha().then((M) => {
4893
+ const P = h.get(t);
4894
+ !Ae || typeof P != "string" || Ha().then((B) => {
4895
4895
  const j = fn(P);
4896
4896
  if (j) {
4897
4897
  if (z) {
4898
4898
  z.loadVideoById({ videoId: j });
4899
4899
  return;
4900
4900
  }
4901
- z = new M.Player(Ae, {
4901
+ z = new B.Player(Ae, {
4902
4902
  videoId: j,
4903
4903
  playerVars: Wa(e),
4904
4904
  events: {
4905
4905
  onReady: () => {
4906
- h?.(), A(), v.get(n) && x?.(), Ke();
4906
+ b?.(), A(), h.get(n) && k?.(), Ke();
4907
4907
  },
4908
4908
  onStateChange: (J) => {
4909
4909
  switch (J.data) {
4910
- case M.PlayerState.PLAYING:
4911
- w?.(), C?.();
4910
+ case B.PlayerState.PLAYING:
4911
+ x?.(), w?.();
4912
4912
  break;
4913
- case M.PlayerState.PAUSED:
4914
- g?.();
4913
+ case B.PlayerState.PAUSED:
4914
+ m?.();
4915
4915
  break;
4916
- case M.PlayerState.BUFFERING:
4917
- f?.();
4916
+ case B.PlayerState.BUFFERING:
4917
+ v?.();
4918
4918
  break;
4919
- case M.PlayerState.ENDED:
4919
+ case B.PlayerState.ENDED:
4920
4920
  $?.();
4921
4921
  break;
4922
4922
  }
4923
4923
  },
4924
4924
  onError: (J) => D?.(J),
4925
4925
  onPlaybackRateChange: (J) => O?.(J.data),
4926
- onPlaybackQualityChange: (J) => B?.(J.data)
4926
+ onPlaybackQualityChange: (J) => E?.(J.data)
4927
4927
  }
4928
4928
  });
4929
4929
  }
@@ -4931,116 +4931,116 @@ function Io(e) {
4931
4931
  }
4932
4932
  function Ke() {
4933
4933
  Te?.();
4934
- const P = v.get(k) ?? 1e3;
4934
+ const P = h.get(S) ?? 1e3;
4935
4935
  Te = Ct(() => {
4936
4936
  if (!z) return;
4937
- const M = z.getDuration?.() ?? 0, j = z.getCurrentTime?.() ?? 0, J = z.getVideoLoadedFraction?.() ?? 0;
4937
+ const B = z.getDuration?.() ?? 0, j = z.getCurrentTime?.() ?? 0, J = z.getVideoLoadedFraction?.() ?? 0;
4938
4938
  V?.({
4939
- played: M > 0 ? j / M : 0,
4939
+ played: B > 0 ? j / B : 0,
4940
4940
  playedSeconds: j,
4941
4941
  loaded: J,
4942
- loadedSeconds: J * M
4942
+ loadedSeconds: J * B
4943
4943
  });
4944
4944
  }, P);
4945
4945
  }
4946
4946
  function A() {
4947
4947
  if (!z) return;
4948
4948
  try {
4949
- const j = v.get(c) ?? 1;
4949
+ const j = h.get(c) ?? 1;
4950
4950
  z.setPlaybackRate?.(j);
4951
4951
  } catch {
4952
4952
  }
4953
4953
  try {
4954
4954
  const j = Math.round(
4955
- Math.min(Math.max(v.get(s) ?? 1, 0), 1) * 100
4955
+ Math.min(Math.max(h.get(s) ?? 1, 0), 1) * 100
4956
4956
  );
4957
4957
  z.setVolume?.(j);
4958
4958
  } catch {
4959
4959
  }
4960
4960
  try {
4961
- v.get(i) ?? !1 ? z.mute?.() : z.unMute?.();
4961
+ h.get(i) ?? !1 ? z.mute?.() : z.unMute?.();
4962
4962
  } catch {
4963
4963
  }
4964
- v.get(n) ?? !1 ? z.playVideo?.() : z.pauseVideo?.();
4965
- const M = v.get(m);
4966
- typeof M == "number" && Number.isFinite(M) && (z.seekTo?.(M, !0), I?.(M));
4964
+ h.get(n) ?? !1 ? z.playVideo?.() : z.pauseVideo?.();
4965
+ const B = h.get(g);
4966
+ typeof B == "number" && Number.isFinite(B) && (z.seekTo?.(B, !0), T?.(B));
4967
4967
  }
4968
- const N = d.div(
4968
+ const R = d.div(
4969
4969
  ne((P) => {
4970
- Ae = P, $e(), h?.();
4970
+ Ae = P, $e(), b?.();
4971
4971
  })
4972
4972
  );
4973
4973
  q.push(
4974
- v.on(t, () => {
4974
+ h.on(t, () => {
4975
4975
  H.value === "youtube" && $e();
4976
4976
  })
4977
4977
  ), q.push(
4978
- v.on(n, () => {
4979
- H.value === "file" && U ? v.get(n) ? U.play?.().catch(() => {
4980
- }) : U.pause?.() : H.value === "youtube" && z && (v.get(n) ? z.playVideo?.() : z.pauseVideo?.());
4978
+ h.on(n, () => {
4979
+ H.value === "file" && F ? h.get(n) ? F.play?.().catch(() => {
4980
+ }) : F.pause?.() : H.value === "youtube" && z && (h.get(n) ? z.playVideo?.() : z.pauseVideo?.());
4981
4981
  })
4982
4982
  ), q.push(
4983
- v.on(s, () => {
4984
- if (H.value === "file" && U)
4985
- U.volume = Math.min(Math.max(v.get(s) ?? 1, 0), 1);
4983
+ h.on(s, () => {
4984
+ if (H.value === "file" && F)
4985
+ F.volume = Math.min(Math.max(h.get(s) ?? 1, 0), 1);
4986
4986
  else if (H.value === "youtube" && z) {
4987
4987
  const P = Math.round(
4988
- Math.min(Math.max(v.get(s) ?? 1, 0), 1) * 100
4988
+ Math.min(Math.max(h.get(s) ?? 1, 0), 1) * 100
4989
4989
  );
4990
4990
  z.setVolume?.(P);
4991
4991
  }
4992
4992
  })
4993
4993
  ), q.push(
4994
- v.on(i, () => {
4995
- H.value === "file" && U ? U.muted = !!v.get(i) : H.value === "youtube" && z && (v.get(i) ? z.mute?.() : z.unMute?.());
4994
+ h.on(i, () => {
4995
+ H.value === "file" && F ? F.muted = !!h.get(i) : H.value === "youtube" && z && (h.get(i) ? z.mute?.() : z.unMute?.());
4996
4996
  })
4997
4997
  ), q.push(
4998
- v.on(c, () => {
4999
- if (H.value === "file" && U)
4998
+ h.on(c, () => {
4999
+ if (H.value === "file" && F)
5000
5000
  try {
5001
- U.playbackRate = v.get(c) ?? 1;
5001
+ F.playbackRate = h.get(c) ?? 1;
5002
5002
  } catch {
5003
5003
  }
5004
- else H.value === "youtube" && z && z.setPlaybackRate?.(v.get(c) ?? 1);
5004
+ else H.value === "youtube" && z && z.setPlaybackRate?.(h.get(c) ?? 1);
5005
5005
  })
5006
5006
  ), q.push(
5007
- v.on(u, async () => {
5008
- if (!(H.value !== "file" || !U))
5007
+ h.on(u, async () => {
5008
+ if (!(H.value !== "file" || !F))
5009
5009
  try {
5010
- const P = !!(v.get(u) ?? !1), M = document, j = U;
5011
- P ? typeof j.requestPictureInPicture == "function" && M.pictureInPictureElement !== U && await j.requestPictureInPicture()?.catch(() => {
5012
- }) : M.pictureInPictureElement === U && typeof M.exitPictureInPicture == "function" && await M.exitPictureInPicture()?.catch(() => {
5010
+ const P = !!(h.get(u) ?? !1), B = document, j = F;
5011
+ P ? typeof j.requestPictureInPicture == "function" && B.pictureInPictureElement !== F && await j.requestPictureInPicture()?.catch(() => {
5012
+ }) : B.pictureInPictureElement === F && typeof B.exitPictureInPicture == "function" && await B.exitPictureInPicture()?.catch(() => {
5013
5013
  });
5014
5014
  } catch {
5015
5015
  }
5016
5016
  })
5017
5017
  ), q.push(
5018
- v.on(m ?? null, () => {
5019
- const P = v.get(m);
5018
+ h.on(g ?? null, () => {
5019
+ const P = h.get(g);
5020
5020
  if (P != null)
5021
- if (H.value === "file" && U)
5021
+ if (H.value === "file" && F)
5022
5022
  try {
5023
- U.currentTime = P, I?.(P);
5023
+ F.currentTime = P, T?.(P);
5024
5024
  } catch {
5025
5025
  }
5026
- else H.value === "youtube" && z && (z.seekTo?.(P, !0), I?.(P));
5026
+ else H.value === "youtube" && z && (z.seekTo?.(P, !0), T?.(P));
5027
5027
  })
5028
5028
  );
5029
5029
  const K = d.div(
5030
5030
  o.class("bc-base-video"),
5031
- S.width(
5032
- v.map(p, we)
5031
+ C.width(
5032
+ h.map(p, we)
5033
5033
  ),
5034
- S.height(
5035
- v.map(b, we)
5034
+ C.height(
5035
+ h.map(f, we)
5036
5036
  ),
5037
5037
  Q(
5038
- v.map(H, (P) => P === "youtube"),
5039
- () => N,
5038
+ h.map(H, (P) => P === "youtube"),
5039
+ () => R,
5040
5040
  () => De
5041
5041
  )
5042
5042
  );
5043
- return R(oe(...q), K);
5043
+ return U(oe(...q), K);
5044
5044
  }
5045
5045
  function fn(e) {
5046
5046
  const t = /[?&]v=([^&#]+)/.exec(e);
@@ -5052,12 +5052,12 @@ function fn(e) {
5052
5052
  }
5053
5053
  function Wa(e) {
5054
5054
  const t = {
5055
- autoplay: v.get(e.playing) ?? !1 ? 1 : 0,
5056
- controls: v.get(e.controls) ?? !1 ? 1 : 0,
5055
+ autoplay: h.get(e.playing) ?? !1 ? 1 : 0,
5056
+ controls: h.get(e.controls) ?? !1 ? 1 : 0,
5057
5057
  rel: 0,
5058
- playsinline: v.get(e.playsinline) ?? !0 ? 1 : 0,
5058
+ playsinline: h.get(e.playsinline) ?? !0 ? 1 : 0,
5059
5059
  modestbranding: 1
5060
- }, n = v.get(e.loop) ?? !1, a = v.get(e.url), r = typeof a == "string" ? fn(a) : null;
5060
+ }, n = h.get(e.loop) ?? !1, a = h.get(e.url), r = typeof a == "string" ? fn(a) : null;
5061
5061
  return n && r && (t.loop = 1, t.playlist = r), t;
5062
5062
  }
5063
5063
  const gt = "https://cdn.jsdelivr.net/npm/pdfjs-dist@5.4.394/", za = (e) => {
@@ -5129,27 +5129,34 @@ function To({
5129
5129
  onPageChange: u,
5130
5130
  onLoadComplete: l
5131
5131
  }, ...p) {
5132
- const b = qa();
5133
- let k = rt(
5134
- v.get(e)
5135
- ), m = null, y = v.get(t);
5136
- return ae(ie, (h) => R(
5132
+ const f = qa();
5133
+ let S = rt(
5134
+ h.get(e)
5135
+ ), g = null, y = h.get(t), b = null;
5136
+ return ae(ie, (k) => U(
5137
5137
  // Clean up PDF document when component unmounts
5138
5138
  oe(() => {
5139
- m != null && (m.destroy(), m = null);
5139
+ if (b) {
5140
+ try {
5141
+ b.cancel();
5142
+ } catch {
5143
+ }
5144
+ b = null;
5145
+ }
5146
+ g != null && (g.destroy(), g = null);
5140
5147
  }),
5141
5148
  Be((x) => {
5142
- const w = kn(
5149
+ const m = kn(
5143
5150
  x.map(
5144
- (g) => g == null ? null : { width: g.width, height: g.height },
5145
- (g, f) => g != null && f != null && g.width === f.width && g.height === f.height
5151
+ (v) => v == null ? null : { width: v.width, height: v.height },
5152
+ (v, w) => v != null && w != null && v.width === w.width && v.height === w.height
5146
5153
  ),
5147
5154
  100
5148
5155
  );
5149
5156
  return Ue(
5150
- w,
5151
- (g) => Ut({
5152
- request: T(
5157
+ m,
5158
+ (v) => Ut({
5159
+ request: I(
5153
5160
  e,
5154
5161
  t,
5155
5162
  n,
@@ -5158,83 +5165,82 @@ function To({
5158
5165
  s,
5159
5166
  i,
5160
5167
  c,
5161
- g
5162
- )((f, C, $, D, _, I, V, O, B) => ({
5163
- source: f,
5164
- page: C,
5165
- fit: $,
5166
- scale: D,
5167
- rotation: _,
5168
- quality: I,
5169
- renderTextLayer: V,
5170
- renderAnnotationLayer: O,
5171
- containerWidth: B.width,
5172
- containerHeight: B.height
5168
+ v
5169
+ )((w, $, D, _, T, V, O, E, N) => ({
5170
+ source: w,
5171
+ page: $,
5172
+ fit: D,
5173
+ scale: _,
5174
+ rotation: T,
5175
+ quality: V,
5176
+ renderTextLayer: O,
5177
+ renderAnnotationLayer: E,
5178
+ containerWidth: N.width,
5179
+ containerHeight: N.height
5173
5180
  })),
5174
- load: async ({ request: f }) => {
5175
- const C = await b, $ = f.source, D = rt($), _ = rt($);
5176
- (m == null || !Qa(k, D)) && (m != null && (m.destroy(), m = null), k = D, m = await C.getDocument(_).promise, l?.({ numPages: m.numPages }));
5177
- const I = f.page < 1 || f.page > m.numPages ? 1 : f.page;
5178
- u != null && I !== y && (y = I, u(I));
5179
- const V = await m.getPage(I);
5180
- let O;
5181
- if (f.fit === "none")
5182
- O = f.scale;
5181
+ load: async ({ request: w }) => {
5182
+ const $ = await f, D = w.source, _ = rt(D), T = rt(D);
5183
+ (g == null || !Qa(S, _)) && (g != null && (g.destroy(), g = null), S = _, g = await $.getDocument(T).promise, l?.({ numPages: g.numPages }));
5184
+ const V = w.page < 1 || w.page > g.numPages ? 1 : w.page;
5185
+ u != null && V !== y && (y = V, u(V));
5186
+ const O = await g.getPage(V);
5187
+ let E;
5188
+ if (w.fit === "none")
5189
+ E = w.scale;
5183
5190
  else {
5184
- const H = V.getViewport({
5191
+ const H = O.getViewport({
5185
5192
  scale: 1,
5186
- rotation: f.rotation
5187
- }), U = H.width / H.height, Y = f.containerWidth / f.containerHeight;
5188
- switch (f.fit) {
5193
+ rotation: w.rotation
5194
+ }), F = H.width / H.height, Y = w.containerWidth / w.containerHeight;
5195
+ switch (w.fit) {
5189
5196
  case "width":
5190
- O = f.containerWidth / H.width;
5197
+ E = w.containerWidth / H.width;
5191
5198
  break;
5192
5199
  case "height":
5193
- O = f.containerHeight / H.height;
5200
+ E = w.containerHeight / H.height;
5194
5201
  break;
5195
5202
  case "contain":
5196
- O = Math.min(
5197
- f.containerWidth / H.width,
5198
- f.containerHeight / H.height
5203
+ E = Math.min(
5204
+ w.containerWidth / H.width,
5205
+ w.containerHeight / H.height
5199
5206
  );
5200
5207
  break;
5201
5208
  case "cover":
5202
- U > Y ? O = f.containerHeight / H.height : O = f.containerWidth / H.width;
5209
+ F > Y ? E = w.containerHeight / H.height : E = w.containerWidth / H.width;
5203
5210
  break;
5204
5211
  }
5205
5212
  }
5206
- const B = V.getViewport({
5207
- scale: O,
5208
- rotation: f.rotation
5209
- }), F = V.getViewport({
5210
- scale: O * f.quality,
5211
- rotation: f.rotation
5213
+ const N = O.getViewport({
5214
+ scale: E,
5215
+ rotation: w.rotation
5216
+ }), te = O.getViewport({
5217
+ scale: E * w.quality,
5218
+ rotation: w.rotation
5212
5219
  });
5213
- let ee = null;
5214
5220
  return {
5215
- pdfWidth: B.width,
5216
- pdfHeight: B.height,
5217
- canvasWidth: Math.floor(B.width),
5218
- canvasHeight: Math.floor(B.height),
5219
- highResWidth: Math.floor(F.width),
5220
- highResHeight: Math.floor(F.height),
5221
- render: async (H, U, Y) => {
5222
- if (ee)
5221
+ pdfWidth: N.width,
5222
+ pdfHeight: N.height,
5223
+ canvasWidth: Math.floor(N.width),
5224
+ canvasHeight: Math.floor(N.height),
5225
+ highResWidth: Math.floor(te.width),
5226
+ highResHeight: Math.floor(te.height),
5227
+ render: async (H, F, Y) => {
5228
+ if (b)
5223
5229
  try {
5224
- ee.cancel(), await ee.promise.catch(() => {
5230
+ b.cancel(), await b.promise.catch(() => {
5225
5231
  });
5226
5232
  } catch {
5227
5233
  }
5228
- H.width = F.width, H.height = F.height, H.style.width = `${B.width}px`, H.style.height = `${B.height}px`;
5234
+ H.width = te.width, H.height = te.height, H.style.width = `${N.width}px`, H.style.height = `${N.height}px`;
5229
5235
  const se = H.getContext("2d");
5230
5236
  if (!se)
5231
5237
  throw new Error("Failed to get canvas context");
5232
- const Ie = V.render({
5238
+ const Ie = O.render({
5233
5239
  canvasContext: se,
5234
5240
  canvas: H,
5235
- viewport: F
5241
+ viewport: te
5236
5242
  });
5237
- ee = Ie;
5243
+ b = Ie;
5238
5244
  try {
5239
5245
  await Ie.promise;
5240
5246
  } catch (q) {
@@ -5242,25 +5248,25 @@ function To({
5242
5248
  throw q;
5243
5249
  return;
5244
5250
  } finally {
5245
- ee === Ie && (ee = null);
5251
+ b === Ie && (b = null);
5246
5252
  }
5247
- if (f.renderTextLayer && U != null) {
5248
- U.innerHTML = "";
5253
+ if (w.renderTextLayer && F != null) {
5254
+ F.innerHTML = "";
5249
5255
  try {
5250
- const q = await V.getTextContent(), de = C.TextLayer;
5256
+ const q = await O.getTextContent(), de = $.TextLayer;
5251
5257
  de != null && await new de({
5252
5258
  textContentSource: q,
5253
- container: U,
5254
- viewport: B
5259
+ container: F,
5260
+ viewport: N
5255
5261
  }).render();
5256
5262
  } catch (q) {
5257
5263
  console.warn("Failed to render text layer:", q);
5258
5264
  }
5259
5265
  }
5260
- if (f.renderAnnotationLayer && Y != null) {
5261
- Y.innerHTML = "", Y.style.width = `${B.width}px`, Y.style.height = `${B.height}px`;
5266
+ if (w.renderAnnotationLayer && Y != null) {
5267
+ Y.innerHTML = "", Y.style.width = `${N.width}px`, Y.style.height = `${N.height}px`;
5262
5268
  try {
5263
- const q = await V.getAnnotations(), de = C.AnnotationLayer;
5269
+ const q = await O.getAnnotations(), de = $.AnnotationLayer;
5264
5270
  if (de != null && q.length > 0) {
5265
5271
  const ye = {
5266
5272
  // Minimal link service for basic functionality
@@ -5275,15 +5281,15 @@ function To({
5275
5281
  };
5276
5282
  await new de({
5277
5283
  div: Y,
5278
- page: V,
5279
- viewport: B,
5284
+ page: O,
5285
+ viewport: N,
5280
5286
  linkService: ye,
5281
5287
  annotationStorage: null
5282
5288
  }).render({
5283
- viewport: B,
5289
+ viewport: N,
5284
5290
  div: Y,
5285
5291
  annotations: q,
5286
- page: V,
5292
+ page: O,
5287
5293
  linkService: ye,
5288
5294
  renderForms: !0
5289
5295
  });
@@ -5295,32 +5301,32 @@ function To({
5295
5301
  }
5296
5302
  };
5297
5303
  },
5298
- convertError: (f) => f instanceof Error ? f.message : JSON.stringify(f),
5304
+ convertError: (w) => w instanceof Error ? w.message : JSON.stringify(w),
5299
5305
  pending: () => d.div(
5300
5306
  o.class("bc-pdf-page-viewer__loading"),
5301
- te({
5307
+ ee({
5302
5308
  icon: "line-md:loading-twotone-loop",
5303
5309
  size: "lg"
5304
5310
  }),
5305
5311
  d.span(
5306
5312
  o.class("bc-pdf-page-viewer__loading-text"),
5307
- h.map((f) => f.pdfPageViewer.loading)
5313
+ k.map((w) => w.pdfPageViewer.loading)
5308
5314
  )
5309
5315
  ),
5310
- failure: ({ error: f }) => d.div(
5316
+ failure: ({ error: w }) => d.div(
5311
5317
  o.class("bc-pdf-page-viewer__error"),
5312
- te({
5318
+ ee({
5313
5319
  icon: "line-md:alert-circle",
5314
5320
  size: "lg",
5315
5321
  color: "danger"
5316
5322
  }),
5317
- d.span(o.class("bc-pdf-page-viewer__error-text"), f)
5323
+ d.span(o.class("bc-pdf-page-viewer__error-text"), w)
5318
5324
  ),
5319
- success: ({ value: f }) => d.div(
5325
+ success: ({ value: w }) => d.div(
5320
5326
  o.class(
5321
- v.map(
5327
+ h.map(
5322
5328
  n,
5323
- (C) => C === "none" ? "bc-pdf-page-viewer" : `bc-pdf-page-viewer bc-pdf-page-viewer--fit-${C}`
5329
+ ($) => $ === "none" ? "bc-pdf-page-viewer" : `bc-pdf-page-viewer bc-pdf-page-viewer--fit-${$}`
5324
5330
  )
5325
5331
  ),
5326
5332
  // Wrapper for canvas and layers (provides positioning context)
@@ -5328,19 +5334,19 @@ function To({
5328
5334
  o.class("bc-pdf-page-viewer__content"),
5329
5335
  // Only set fixed dimensions when fit is 'none'
5330
5336
  Q(
5331
- v.map(n, (C) => C === "none"),
5337
+ h.map(n, ($) => $ === "none"),
5332
5338
  () => o.style(
5333
- f.$.canvasWidth.map(
5334
- (C) => `width: ${C}px; height: ${f.value.canvasHeight}px;`
5339
+ w.$.canvasWidth.map(
5340
+ ($) => `width: ${$}px; height: ${w.value.canvasHeight}px;`
5335
5341
  )
5336
5342
  ),
5337
- () => R()
5343
+ () => U()
5338
5344
  ),
5339
5345
  // Canvas layer
5340
5346
  d.canvas(
5341
5347
  o.class("bc-pdf-page-viewer__canvas"),
5342
- o.width(f.$.canvasWidth.map(String)),
5343
- o.height(f.$.canvasHeight.map(String)),
5348
+ o.width(w.$.canvasWidth.map(String)),
5349
+ o.height(w.$.canvasHeight.map(String)),
5344
5350
  ...p
5345
5351
  ),
5346
5352
  // Text layer (for text selection)
@@ -5348,19 +5354,19 @@ function To({
5348
5354
  // Annotation layer (for links, forms, etc.)
5349
5355
  d.div(o.class("bc-pdf-page-viewer__annotation-layer"))
5350
5356
  ),
5351
- ne((C) => {
5352
- const $ = C.querySelector(
5357
+ ne(($) => {
5358
+ const D = $.querySelector(
5353
5359
  ".bc-pdf-page-viewer__canvas"
5354
- ), D = C.querySelector(
5360
+ ), _ = $.querySelector(
5355
5361
  ".bc-pdf-page-viewer__text-layer"
5356
- ), _ = C.querySelector(
5362
+ ), T = $.querySelector(
5357
5363
  ".bc-pdf-page-viewer__annotation-layer"
5358
5364
  );
5359
- return v.on(f, async (I) => {
5360
- await I.render(
5361
- $,
5365
+ return h.on(w, async (V) => {
5366
+ await V.render(
5362
5367
  D,
5363
- _
5368
+ _,
5369
+ T
5364
5370
  );
5365
5371
  }), W;
5366
5372
  })
@@ -5434,7 +5440,7 @@ export {
5434
5440
  Pn as FocusTrap,
5435
5441
  ro as FormStatus,
5436
5442
  Zt as Group,
5437
- te as Icon,
5443
+ ee as Icon,
5438
5444
  ce as InputContainer,
5439
5445
  Ye as InputIcon,
5440
5446
  dt as InputWrapper,