@tempots/beatui 0.92.0 → 0.94.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/auth/index.cjs.js +1 -1
- package/dist/auth/index.es.js +1 -1
- package/dist/{auth-divider-VzrKnv2d.cjs → auth-divider-C3E16pml.cjs} +1 -1
- package/dist/{auth-divider-B4n8lGx5.js → auth-divider-Rt0WDKAe.js} +3 -3
- package/dist/better-auth/index.cjs.js +1 -1
- package/dist/better-auth/index.es.js +2 -2
- package/dist/deep-merge-Blrucd-E.cjs +1 -0
- package/dist/{deep-merge-DxUvbsBl.js → deep-merge-CoLO4id0.js} +591 -589
- package/dist/duration-input-47x7nbGh.cjs +1 -0
- package/dist/{duration-input-DQTX3S_A.js → duration-input-DrVonjKK.js} +42 -42
- package/dist/index.cjs.js +2 -2
- package/dist/index.es.js +692 -691
- package/dist/json-schema/index.cjs.js +1 -1
- package/dist/json-schema/index.es.js +5 -5
- package/dist/json-structure/index.cjs.js +1 -1
- package/dist/json-structure/index.es.js +3 -3
- package/dist/lexical/index.cjs.js +30 -30
- package/dist/lexical/index.es.js +2086 -2001
- package/dist/{modal-C-d5Btti.cjs → modal-DUlqGUW7.cjs} +1 -1
- package/dist/{modal-DTz98Dk7.js → modal-ZitwUeXx.js} +1 -1
- package/dist/{notice-BDTfBGtx.cjs → notice-DAVOTnfA.cjs} +1 -1
- package/dist/{notice-CZuh-h6a.js → notice-E_p2hg1G.js} +1 -1
- package/dist/types/lexical/index.d.ts +1 -1
- package/dist/types/lexical/plugins/element-style.d.ts +28 -0
- package/dist/types/lexical/plugins/index.d.ts +1 -1
- package/dist/{use-form-Cd8YFWaN.js → use-form-BQRVnIp9.js} +167 -166
- package/dist/use-form-DTyNw0kM.cjs +2 -0
- package/dist/{widget-customization-Cs422IGY.js → widget-customization-C-fSx3RB.js} +307 -306
- package/dist/widget-customization-xEBfEPhQ.cjs +1 -0
- package/package.json +1 -1
- package/dist/deep-merge-CI1g9sjh.cjs +0 -1
- package/dist/duration-input-a1fCTfKl.cjs +0 -1
- package/dist/use-form-DQVN_Zjb.cjs +0 -2
- package/dist/widget-customization-eyQ2pxvu.cjs +0 -1
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { prop as H, html as i, attr as a, computedOf as k, Value as h, Ensure as xe, aria as
|
|
1
|
+
import { prop as H, html as i, attr as a, computedOf as k, Value as h, Ensure as xe, aria as L, OneOfValue as St, on as I, ForEach as oe, When as B, Fragment as Q, OnDispose as ge, style as D, WithElement as re, Repeat as Tn, Empty as j, Use as ne, input as De, emitValue as de, Unless as Ln, coalesce as he, OneOfType as pt, NotEmpty as Pn, emitValueAsDate as An, MapSignal as Mn, Portal as bt, makeProviderMark as Wt, WithBrowserCtx as Vn, renderWithContext as Bn, WithProvider as En, Task as Nn, Provide as Yt, dataAttr as Gt, svg as Dt, svgAttr as It, delaySignal as Rn } from "@tempots/dom";
|
|
2
2
|
import { Use as el } from "@tempots/dom";
|
|
3
3
|
import { ElementRect as Ue, WindowSize as On, Query as qt, Location as Ye, NavigationService as Fn, Anchor as ft } from "@tempots/ui";
|
|
4
4
|
import { I as K, b as G, h as te, t as pe, a as Ae, B as le, L as gt } from "./translations-CiBhB2FV.js";
|
|
@@ -7,19 +7,19 @@ import { g as Se } from "./colors-BY0Ja_bf.js";
|
|
|
7
7
|
import { b as vl, d as yl, e as _l, f as wl, h as kl, i as xl, a as Cl, c as $l, j as Sl, k as Dl, n as Il, r as Tl, s as Ll, m as Pl, t as Al, o as Ml } from "./colors-BY0Ja_bf.js";
|
|
8
8
|
import { e as jn } from "./index-B8cqD9ny.js";
|
|
9
9
|
import { f as Bl, h as El, i as Nl, j as Rl, k as Ol, l as Fl, m as jl, n as Ul, o as zl, p as Hl, q as Wl, r as Yl, s as Gl, t as ql, u as Zl, v as Jl, w as Kl, x as Xl, y as Ql, z as ei, A as ti, a as ni, B as ai, C as si, D as ri, E as oi, F as li, G as ii, H as ci, I as ui, J as di, K as pi, g as bi, L as fi, M as gi, N as hi, O as mi, P as vi, Q as yi, c as _i, R as wi, S as ki, T as xi, U as Ci, V as $i, W as Si, X as Di, Y as Ii, Z as Ti, _ as Li, $ as Pi, a0 as Ai, a1 as Mi, a2 as Vi, a3 as Bi, a4 as Ei, a5 as Ni, a6 as Ri, a7 as Oi, a8 as Fi, a9 as ji, aa as Ui, ab as zi, ac as Hi, ad as Wi, ae as Yi, af as Gi, ag as qi, d as Zi, ah as Ji, ai as Ki, aj as Xi, ak as Qi, al as ec, am as tc, an as nc, ao as ac, ap as sc, aq as rc, ar as oc, as as lc, at as ic, au as cc, av as uc, aw as dc, ax as pc, ay as bc, b as fc, az as gc, aA as hc, aB as mc, aC as vc, aD as yc, aE as _c, aF as wc, aG as kc, aH as xc, aI as Cc, aJ as $c, aK as Sc, aL as Dc, aM as Ic, aN as Tc, aO as Lc, aP as Pc, aQ as Ac, aR as Mc, aS as Vc, aT as Bc, aU as Ec } from "./index-B8cqD9ny.js";
|
|
10
|
-
import { C as Ge, I as ht, m as Zt, c as Jt, B as Kt, b as Xt, d as Un } from "./use-form-
|
|
11
|
-
import { A as Rc, h as Oc, a as Fc, i as jc, M as Uc, f as zc, R as Hc, j as Wc, k as Yc, l as Gc, n as qc, o as Zc, e as Jc, p as Kc, q as Xc, s as Qc, t as eu, g as tu, u as nu, w as au } from "./use-form-
|
|
10
|
+
import { C as Ge, I as ht, m as Zt, c as Jt, B as Kt, b as Xt, d as Un } from "./use-form-BQRVnIp9.js";
|
|
11
|
+
import { A as Rc, h as Oc, a as Fc, i as jc, M as Uc, f as zc, R as Hc, j as Wc, k as Yc, l as Gc, n as qc, o as Zc, e as Jc, p as Kc, q as Xc, s as Qc, t as eu, g as tu, u as nu, w as au } from "./use-form-BQRVnIp9.js";
|
|
12
12
|
import { u as Qe, A as Tt, a as zn } from "./use-animated-toggle-C7PTmnZi.js";
|
|
13
13
|
import { b as ru, c as ou } from "./use-animated-toggle-C7PTmnZi.js";
|
|
14
14
|
import { T as Qt, a as Hn } from "./theme-kQZEeusG.js";
|
|
15
15
|
import { beatuiPreset as iu, createBeatuiPreset as cu } from "./tailwind/preset.es.js";
|
|
16
|
-
import { p as je, q as mt, C as Wn, r as Yn, s as Lt, t as Fe } from "./widget-customization-
|
|
17
|
-
import { B as du, u as pu, E as bu, f as fu, e as gu, h as hu, d as mu, j as vu, i as yu, a as _u, N as wu, b as ku, c as xu, R as Cu, S as $u, k as Su, v as Du, m as Iu, n as Tu, o as Lu, w as Pu, x as Au, y as Mu, z as Vu, A as Bu, D as Eu, F as Nu, G as Ru, H as Ou, I as Fu, J as ju, K as Uu, L as zu, M as Hu, O as Wu, P as Yu, Q as Gu, T as qu, U as Zu } from "./widget-customization-
|
|
16
|
+
import { p as je, q as mt, C as Wn, r as Yn, s as Lt, t as Fe } from "./widget-customization-C-fSx3RB.js";
|
|
17
|
+
import { B as du, u as pu, E as bu, f as fu, e as gu, h as hu, d as mu, j as vu, i as yu, a as _u, N as wu, b as ku, c as xu, R as Cu, S as $u, k as Su, v as Du, m as Iu, n as Tu, o as Lu, w as Pu, x as Au, y as Mu, z as Vu, A as Bu, D as Eu, F as Nu, G as Ru, H as Ou, I as Fu, J as ju, K as Uu, L as zu, M as Hu, O as Wu, P as Yu, Q as Gu, T as qu, U as Zu } from "./widget-customization-C-fSx3RB.js";
|
|
18
18
|
import { s as me } from "./session-id-3KiilioY.js";
|
|
19
|
-
import { W as Ce, S as Gn, N as ze, G as en, E as qn, b as tn, M as vt, r as ct } from "./deep-merge-
|
|
20
|
-
import { B as Ku, k as Xu, F as Qu, L as ed, l as td, m as nd, h as ad, c as sd, f as rd, g as od, T as ld, U as id, i as cd, n as ud, a as dd, j as pd, o as bd, p as fd, q as gd, e as hd, t as md, s as vd } from "./deep-merge-
|
|
21
|
-
import { O as yt, F as nn, M as _t } from "./modal-
|
|
22
|
-
import { B as _d, C as wd, a as kd, S as xd, b as Cd, c as $d, o as Sd, s as Dd, u as Id } from "./modal-
|
|
19
|
+
import { W as Ce, S as Gn, N as ze, G as en, E as qn, b as tn, M as vt, r as ct } from "./deep-merge-CoLO4id0.js";
|
|
20
|
+
import { B as Ku, k as Xu, F as Qu, L as ed, l as td, m as nd, h as ad, c as sd, f as rd, g as od, T as ld, U as id, i as cd, n as ud, a as dd, j as pd, o as bd, p as fd, q as gd, e as hd, t as md, s as vd } from "./deep-merge-CoLO4id0.js";
|
|
21
|
+
import { O as yt, F as nn, M as _t } from "./modal-ZitwUeXx.js";
|
|
22
|
+
import { B as _d, C as wd, a as kd, S as xd, b as Cd, c as $d, o as Sd, s as Dd, u as Id } from "./modal-ZitwUeXx.js";
|
|
23
23
|
import { B as Ve, I as ve, a as et, b as Pt, c as At } from "./input-container-9r1F3KuX.js";
|
|
24
24
|
import { g as Ld } from "./input-container-9r1F3KuX.js";
|
|
25
25
|
import { C as Ie } from "./text-input-BgPx8BbG.js";
|
|
@@ -27,12 +27,12 @@ import { T as Ad } from "./text-input-BgPx8BbG.js";
|
|
|
27
27
|
import { F as wt, M as an, a as sn } from "./menu-CV85y3Xf.js";
|
|
28
28
|
import { b as Vd } from "./menu-CV85y3Xf.js";
|
|
29
29
|
import { g as rn, T as Mt } from "./timer-Rd2sKnvH.js";
|
|
30
|
-
import { f as Zn, g as Jn } from "./duration-input-
|
|
31
|
-
import { B as Ed, D as Nd, F as Rd, N as Od, d as Fd, b as jd, a as Ud, e as zd, c as Hd, P as Wd } from "./duration-input-
|
|
30
|
+
import { f as Zn, g as Jn } from "./duration-input-DrVonjKK.js";
|
|
31
|
+
import { B as Ed, D as Nd, F as Rd, N as Od, d as Fd, b as jd, a as Ud, e as zd, c as Hd, P as Wd } from "./duration-input-DrVonjKK.js";
|
|
32
32
|
import { C as Gd } from "./utils-DEbsp9Q9.js";
|
|
33
33
|
import { S as Kn } from "./stack-Bm-UZosx.js";
|
|
34
34
|
import { D as Zd, E as Jd, L as Kd, M as Xd } from "./stack-Bm-UZosx.js";
|
|
35
|
-
import { E as ep, N as tp, P as np } from "./notice-
|
|
35
|
+
import { E as ep, N as tp, P as np } from "./notice-E_p2hg1G.js";
|
|
36
36
|
import { L as sp } from "./link-portal-Cr2l9f3k.js";
|
|
37
37
|
import { b as op, T as lp, c as ip, a as cp, d as up } from "./toolbar-DKOh_gbA.js";
|
|
38
38
|
function pr(e, t = 0, n = () => !0) {
|
|
@@ -326,16 +326,16 @@ function un(e, t, n) {
|
|
|
326
326
|
nextYear: m,
|
|
327
327
|
prevYearPage: w,
|
|
328
328
|
nextYearPage: x,
|
|
329
|
-
switchToMonthsView:
|
|
330
|
-
switchToYearsView:
|
|
331
|
-
selectMonth:
|
|
329
|
+
switchToMonthsView: C,
|
|
330
|
+
switchToYearsView: $,
|
|
331
|
+
selectMonth: y,
|
|
332
332
|
selectYear: S
|
|
333
333
|
} = e;
|
|
334
334
|
return i.div(
|
|
335
335
|
a.class(k(s, r)(ra)),
|
|
336
336
|
a.style(h.map(u, oa)),
|
|
337
337
|
a.role("grid"),
|
|
338
|
-
|
|
338
|
+
L.label(l),
|
|
339
339
|
// Navigation header
|
|
340
340
|
St(g, {
|
|
341
341
|
days: () => i.div(
|
|
@@ -344,9 +344,9 @@ function un(e, t, n) {
|
|
|
344
344
|
a.type("button"),
|
|
345
345
|
a.class("bc-calendar__nav-btn"),
|
|
346
346
|
a.disabled(r),
|
|
347
|
-
|
|
348
|
-
I.click((
|
|
349
|
-
|
|
347
|
+
L.label("Previous year"),
|
|
348
|
+
I.click((v) => {
|
|
349
|
+
v.preventDefault(), _();
|
|
350
350
|
}),
|
|
351
351
|
"«"
|
|
352
352
|
),
|
|
@@ -354,9 +354,9 @@ function un(e, t, n) {
|
|
|
354
354
|
a.type("button"),
|
|
355
355
|
a.class("bc-calendar__nav-btn"),
|
|
356
356
|
a.disabled(r),
|
|
357
|
-
|
|
358
|
-
I.click((
|
|
359
|
-
|
|
357
|
+
L.label("Previous month"),
|
|
358
|
+
I.click((v) => {
|
|
359
|
+
v.preventDefault(), b();
|
|
360
360
|
}),
|
|
361
361
|
"‹"
|
|
362
362
|
),
|
|
@@ -366,19 +366,19 @@ function un(e, t, n) {
|
|
|
366
366
|
a.type("button"),
|
|
367
367
|
a.class("bc-calendar__title-btn"),
|
|
368
368
|
a.disabled(r),
|
|
369
|
-
|
|
370
|
-
I.click((
|
|
371
|
-
|
|
369
|
+
L.label("Select month"),
|
|
370
|
+
I.click((v) => {
|
|
371
|
+
v.preventDefault(), C();
|
|
372
372
|
}),
|
|
373
|
-
h.map(o, (
|
|
373
|
+
h.map(o, (v) => na[v - 1])
|
|
374
374
|
),
|
|
375
375
|
i.button(
|
|
376
376
|
a.type("button"),
|
|
377
377
|
a.class("bc-calendar__title-btn"),
|
|
378
378
|
a.disabled(r),
|
|
379
|
-
|
|
380
|
-
I.click((
|
|
381
|
-
|
|
379
|
+
L.label("Select year"),
|
|
380
|
+
I.click((v) => {
|
|
381
|
+
v.preventDefault(), $();
|
|
382
382
|
}),
|
|
383
383
|
h.map(d, String)
|
|
384
384
|
)
|
|
@@ -387,9 +387,9 @@ function un(e, t, n) {
|
|
|
387
387
|
a.type("button"),
|
|
388
388
|
a.class("bc-calendar__nav-btn"),
|
|
389
389
|
a.disabled(r),
|
|
390
|
-
|
|
391
|
-
I.click((
|
|
392
|
-
|
|
390
|
+
L.label("Next month"),
|
|
391
|
+
I.click((v) => {
|
|
392
|
+
v.preventDefault(), p();
|
|
393
393
|
}),
|
|
394
394
|
"›"
|
|
395
395
|
),
|
|
@@ -397,9 +397,9 @@ function un(e, t, n) {
|
|
|
397
397
|
a.type("button"),
|
|
398
398
|
a.class("bc-calendar__nav-btn"),
|
|
399
399
|
a.disabled(r),
|
|
400
|
-
|
|
401
|
-
I.click((
|
|
402
|
-
|
|
400
|
+
L.label("Next year"),
|
|
401
|
+
I.click((v) => {
|
|
402
|
+
v.preventDefault(), m();
|
|
403
403
|
}),
|
|
404
404
|
"»"
|
|
405
405
|
)
|
|
@@ -410,9 +410,9 @@ function un(e, t, n) {
|
|
|
410
410
|
a.type("button"),
|
|
411
411
|
a.class("bc-calendar__nav-btn"),
|
|
412
412
|
a.disabled(r),
|
|
413
|
-
|
|
414
|
-
I.click((
|
|
415
|
-
|
|
413
|
+
L.label("Previous year"),
|
|
414
|
+
I.click((v) => {
|
|
415
|
+
v.preventDefault(), _();
|
|
416
416
|
}),
|
|
417
417
|
"«"
|
|
418
418
|
),
|
|
@@ -424,9 +424,9 @@ function un(e, t, n) {
|
|
|
424
424
|
a.type("button"),
|
|
425
425
|
a.class("bc-calendar__nav-btn"),
|
|
426
426
|
a.disabled(r),
|
|
427
|
-
|
|
428
|
-
I.click((
|
|
429
|
-
|
|
427
|
+
L.label("Next year"),
|
|
428
|
+
I.click((v) => {
|
|
429
|
+
v.preventDefault(), m();
|
|
430
430
|
}),
|
|
431
431
|
"»"
|
|
432
432
|
)
|
|
@@ -437,9 +437,9 @@ function un(e, t, n) {
|
|
|
437
437
|
a.type("button"),
|
|
438
438
|
a.class("bc-calendar__nav-btn"),
|
|
439
439
|
a.disabled(r),
|
|
440
|
-
|
|
441
|
-
I.click((
|
|
442
|
-
|
|
440
|
+
L.label(`Previous ${ke} years`),
|
|
441
|
+
I.click((v) => {
|
|
442
|
+
v.preventDefault(), w();
|
|
443
443
|
}),
|
|
444
444
|
"«"
|
|
445
445
|
),
|
|
@@ -447,16 +447,16 @@ function un(e, t, n) {
|
|
|
447
447
|
a.class("bc-calendar__title"),
|
|
448
448
|
h.map(
|
|
449
449
|
f,
|
|
450
|
-
(
|
|
450
|
+
(v) => `${v} – ${v + ke - 1}`
|
|
451
451
|
)
|
|
452
452
|
),
|
|
453
453
|
i.button(
|
|
454
454
|
a.type("button"),
|
|
455
455
|
a.class("bc-calendar__nav-btn"),
|
|
456
456
|
a.disabled(r),
|
|
457
|
-
|
|
458
|
-
I.click((
|
|
459
|
-
|
|
457
|
+
L.label(`Next ${ke} years`),
|
|
458
|
+
I.click((v) => {
|
|
459
|
+
v.preventDefault(), x();
|
|
460
460
|
}),
|
|
461
461
|
"»"
|
|
462
462
|
)
|
|
@@ -469,7 +469,7 @@ function un(e, t, n) {
|
|
|
469
469
|
i.div(
|
|
470
470
|
a.class("bc-calendar__weekdays"),
|
|
471
471
|
...e.shiftedDayNames.map(
|
|
472
|
-
(
|
|
472
|
+
(v) => i.div(a.class("bc-calendar__weekday"), v)
|
|
473
473
|
)
|
|
474
474
|
),
|
|
475
475
|
n()
|
|
@@ -478,24 +478,24 @@ function un(e, t, n) {
|
|
|
478
478
|
a.class(
|
|
479
479
|
"bc-calendar__picker-grid bc-calendar__picker-grid--months"
|
|
480
480
|
),
|
|
481
|
-
...aa.map((
|
|
482
|
-
const E =
|
|
481
|
+
...aa.map((v, T) => {
|
|
482
|
+
const E = T + 1;
|
|
483
483
|
return i.button(
|
|
484
484
|
a.type("button"),
|
|
485
485
|
a.class(
|
|
486
486
|
k(
|
|
487
487
|
o,
|
|
488
488
|
d
|
|
489
|
-
)((
|
|
489
|
+
)((U, V) => {
|
|
490
490
|
const N = ["bc-calendar__month-cell"];
|
|
491
|
-
return
|
|
491
|
+
return U === E && N.push("bc-calendar__month-cell--current"), c.month === E && c.year === V && N.push("bc-calendar__month-cell--active"), N.join(" ");
|
|
492
492
|
})
|
|
493
493
|
),
|
|
494
494
|
a.disabled(r),
|
|
495
|
-
I.click((
|
|
496
|
-
|
|
495
|
+
I.click((U) => {
|
|
496
|
+
U.preventDefault(), y(E);
|
|
497
497
|
}),
|
|
498
|
-
|
|
498
|
+
v
|
|
499
499
|
);
|
|
500
500
|
})
|
|
501
501
|
),
|
|
@@ -504,28 +504,28 @@ function un(e, t, n) {
|
|
|
504
504
|
"bc-calendar__picker-grid bc-calendar__picker-grid--years"
|
|
505
505
|
),
|
|
506
506
|
oe(
|
|
507
|
-
h.map(f, (
|
|
508
|
-
const
|
|
507
|
+
h.map(f, (v) => {
|
|
508
|
+
const T = [];
|
|
509
509
|
for (let E = 0; E < ke; E++)
|
|
510
|
-
|
|
511
|
-
return
|
|
510
|
+
T.push(v + E);
|
|
511
|
+
return T;
|
|
512
512
|
}),
|
|
513
|
-
(
|
|
513
|
+
(v) => i.button(
|
|
514
514
|
a.type("button"),
|
|
515
515
|
a.class(
|
|
516
516
|
k(
|
|
517
517
|
d,
|
|
518
|
-
|
|
519
|
-
)((
|
|
520
|
-
const
|
|
521
|
-
return
|
|
518
|
+
v
|
|
519
|
+
)((T, E) => {
|
|
520
|
+
const U = ["bc-calendar__year-cell"];
|
|
521
|
+
return T === E && U.push("bc-calendar__year-cell--current"), c.year === E && U.push("bc-calendar__year-cell--active"), U.join(" ");
|
|
522
522
|
})
|
|
523
523
|
),
|
|
524
524
|
a.disabled(r),
|
|
525
|
-
I.click((
|
|
526
|
-
|
|
525
|
+
I.click((T) => {
|
|
526
|
+
T.preventDefault(), S(h.get(v));
|
|
527
527
|
}),
|
|
528
|
-
h.map(
|
|
528
|
+
h.map(v, String)
|
|
529
529
|
)
|
|
530
530
|
)
|
|
531
531
|
)
|
|
@@ -643,11 +643,11 @@ function pn(e, {
|
|
|
643
643
|
g,
|
|
644
644
|
f
|
|
645
645
|
)((p, _, m, w, x) => {
|
|
646
|
-
let
|
|
646
|
+
let C = null, $ = null, y = !1;
|
|
647
647
|
if (w != null && x != null) {
|
|
648
648
|
const S = e.PlainDate.compare(w, x);
|
|
649
|
-
|
|
650
|
-
} else m != null && (
|
|
649
|
+
C = S <= 0 ? w : x, $ = S <= 0 ? x : w, y = !0;
|
|
650
|
+
} else m != null && (C = m[0], $ = m[1]);
|
|
651
651
|
return ln(
|
|
652
652
|
e,
|
|
653
653
|
p,
|
|
@@ -656,8 +656,8 @@ function pn(e, {
|
|
|
656
656
|
o.today,
|
|
657
657
|
s
|
|
658
658
|
).map((S) => {
|
|
659
|
-
let
|
|
660
|
-
return
|
|
659
|
+
let v = !1, T = !1, E = !1;
|
|
660
|
+
return C != null && $ != null && (v = S.date.equals(C), T = S.date.equals($), E = e.PlainDate.compare(S.date, C) > 0 && e.PlainDate.compare(S.date, $) < 0), { ...S, isRangeStart: v, isRangeEnd: T, isInRange: E, isPreview: y };
|
|
661
661
|
});
|
|
662
662
|
});
|
|
663
663
|
return un(
|
|
@@ -670,8 +670,8 @@ function pn(e, {
|
|
|
670
670
|
}),
|
|
671
671
|
oe(b, (p) => {
|
|
672
672
|
const _ = p.map((x) => {
|
|
673
|
-
const
|
|
674
|
-
return x.inMonth ||
|
|
673
|
+
const C = ["bc-calendar__day"];
|
|
674
|
+
return x.inMonth || C.push("bc-calendar__day--outside"), x.isToday && C.push("bc-calendar__day--today"), x.isDisabled && C.push("bc-calendar__day--disabled"), x.isRangeStart && C.push("bc-calendar__day--range-start"), x.isRangeEnd && C.push("bc-calendar__day--range-end"), x.isInRange && C.push("bc-calendar__day--in-range"), x.isPreview && (x.isRangeStart || x.isRangeEnd || x.isInRange) && C.push("bc-calendar__day--preview"), C.join(" ");
|
|
675
675
|
}), m = p.map((x) => x.isDisabled), w = p.map((x) => String(x.day));
|
|
676
676
|
return i.button(
|
|
677
677
|
a.type("button"),
|
|
@@ -680,7 +680,7 @@ function pn(e, {
|
|
|
680
680
|
k(
|
|
681
681
|
m,
|
|
682
682
|
l
|
|
683
|
-
)((x,
|
|
683
|
+
)((x, C) => x || C)
|
|
684
684
|
),
|
|
685
685
|
I.mouseenter(() => {
|
|
686
686
|
const x = h.get(p);
|
|
@@ -688,14 +688,14 @@ function pn(e, {
|
|
|
688
688
|
}),
|
|
689
689
|
I.click((x) => {
|
|
690
690
|
x.preventDefault();
|
|
691
|
-
const
|
|
692
|
-
if (
|
|
693
|
-
|
|
694
|
-
const
|
|
695
|
-
if (
|
|
696
|
-
g.set(
|
|
691
|
+
const C = h.get(p);
|
|
692
|
+
if (C.isDisabled || h.get(l)) return;
|
|
693
|
+
C.inMonth || (o.currentYear.set(C.date.year), o.currentMonth.set(C.date.month));
|
|
694
|
+
const $ = g.value;
|
|
695
|
+
if ($ == null)
|
|
696
|
+
g.set(C.date);
|
|
697
697
|
else {
|
|
698
|
-
const S = e.PlainDate.compare(C
|
|
698
|
+
const S = e.PlainDate.compare($, C.date) <= 0 ? [$, C.date] : [C.date, $];
|
|
699
699
|
g.set(null), f.set(null), n?.(S);
|
|
700
700
|
}
|
|
701
701
|
}),
|
|
@@ -979,7 +979,7 @@ function Cr(e) {
|
|
|
979
979
|
),
|
|
980
980
|
i.span(c.$.actor.$.name)
|
|
981
981
|
),
|
|
982
|
-
|
|
982
|
+
B(
|
|
983
983
|
c.map((d) => d.restorable === !0 && d.onRestore != null),
|
|
984
984
|
() => Ve(
|
|
985
985
|
{
|
|
@@ -995,7 +995,7 @@ function Cr(e) {
|
|
|
995
995
|
)
|
|
996
996
|
)),
|
|
997
997
|
// Empty state
|
|
998
|
-
|
|
998
|
+
B(
|
|
999
999
|
k(r)((c) => c.length === 0),
|
|
1000
1000
|
() => i.div(
|
|
1001
1001
|
a.class("bc-history-timeline__empty"),
|
|
@@ -1025,11 +1025,11 @@ function $r(e) {
|
|
|
1025
1025
|
return i.span(
|
|
1026
1026
|
a.class("bc-icon-badge"),
|
|
1027
1027
|
K(u),
|
|
1028
|
-
|
|
1028
|
+
B(
|
|
1029
1029
|
l,
|
|
1030
1030
|
() => i.span(
|
|
1031
1031
|
a.class("bc-icon-badge__indicator"),
|
|
1032
|
-
|
|
1032
|
+
B(
|
|
1033
1033
|
d,
|
|
1034
1034
|
() => dt({ dot: !0, color: r, size: "xs" }),
|
|
1035
1035
|
() => dt(
|
|
@@ -1051,30 +1051,30 @@ function Sr({
|
|
|
1051
1051
|
}) {
|
|
1052
1052
|
const l = H(!1), c = H([]);
|
|
1053
1053
|
let d = null, o = 0;
|
|
1054
|
-
const g = (
|
|
1055
|
-
if (
|
|
1056
|
-
if (
|
|
1057
|
-
const
|
|
1058
|
-
return
|
|
1054
|
+
const g = ($) => $.dataTransfer?.types.includes("Files") ?? !1, f = ($, y) => y === "*/*" ? !0 : y.split(",").map((v) => v.trim()).some((v) => {
|
|
1055
|
+
if (v === "*/*") return !0;
|
|
1056
|
+
if (v.endsWith("/*")) {
|
|
1057
|
+
const T = v.slice(0, -2);
|
|
1058
|
+
return $.type.startsWith(T + "/");
|
|
1059
1059
|
}
|
|
1060
|
-
return
|
|
1061
|
-
}), b = (
|
|
1062
|
-
h.get(u) || g(
|
|
1063
|
-
}, p = (
|
|
1064
|
-
h.get(u) || g(
|
|
1065
|
-
}, _ = (
|
|
1066
|
-
h.get(u) || g(
|
|
1067
|
-
}, m = (
|
|
1068
|
-
if (h.get(u) || !g(
|
|
1069
|
-
|
|
1070
|
-
const
|
|
1071
|
-
if (
|
|
1072
|
-
const S = h.get(t),
|
|
1060
|
+
return $.type === v || $.name.endsWith(v);
|
|
1061
|
+
}), b = ($) => {
|
|
1062
|
+
h.get(u) || g($) && ($.preventDefault(), $.stopPropagation(), o++, o === 1 && (l.value = !0));
|
|
1063
|
+
}, p = ($) => {
|
|
1064
|
+
h.get(u) || g($) && ($.preventDefault(), $.stopPropagation(), $.dataTransfer != null && ($.dataTransfer.dropEffect = "copy"));
|
|
1065
|
+
}, _ = ($) => {
|
|
1066
|
+
h.get(u) || g($) && ($.preventDefault(), $.stopPropagation(), o--, o === 0 && (l.value = !1));
|
|
1067
|
+
}, m = ($) => {
|
|
1068
|
+
if (h.get(u) || !g($)) return;
|
|
1069
|
+
$.preventDefault(), $.stopPropagation(), o = 0, l.value = !1;
|
|
1070
|
+
const y = Array.from($.dataTransfer?.files ?? []);
|
|
1071
|
+
if (y.length > 0) {
|
|
1072
|
+
const S = h.get(t), v = y.filter(
|
|
1073
1073
|
(E) => f(E, S)
|
|
1074
|
-
),
|
|
1075
|
-
(E) => !
|
|
1074
|
+
), T = y.filter(
|
|
1075
|
+
(E) => !v.includes(E)
|
|
1076
1076
|
);
|
|
1077
|
-
|
|
1077
|
+
v.length > 0 && (c.value = v, e(v, "dragdrop")), T.length > 0 && r?.(y);
|
|
1078
1078
|
}
|
|
1079
1079
|
};
|
|
1080
1080
|
typeof document < "u" && (document.addEventListener("dragenter", b), document.addEventListener("dragover", p), document.addEventListener("dragleave", _), document.addEventListener("drop", m));
|
|
@@ -1082,9 +1082,9 @@ function Sr({
|
|
|
1082
1082
|
typeof document < "u" && (document.removeEventListener("dragenter", b), document.removeEventListener("dragover", p), document.removeEventListener("dragleave", _), document.removeEventListener("drop", m)), o = 0;
|
|
1083
1083
|
}, x = () => {
|
|
1084
1084
|
d?.click();
|
|
1085
|
-
},
|
|
1086
|
-
const
|
|
1087
|
-
S.length > 0 && (c.value = S, e(S, "click")),
|
|
1085
|
+
}, C = ($) => {
|
|
1086
|
+
const y = $.target, S = Array.from(y.files ?? []);
|
|
1087
|
+
S.length > 0 && (c.value = S, e(S, "click")), y.value = "";
|
|
1088
1088
|
};
|
|
1089
1089
|
return Q(
|
|
1090
1090
|
ge(w),
|
|
@@ -1099,13 +1099,13 @@ function Sr({
|
|
|
1099
1099
|
D.pointerEvents("none"),
|
|
1100
1100
|
D.width("0"),
|
|
1101
1101
|
D.height("0"),
|
|
1102
|
-
I.change(
|
|
1103
|
-
re((
|
|
1102
|
+
I.change(C),
|
|
1103
|
+
re(($) => (d = $, ge(() => {
|
|
1104
1104
|
d != null && (d.value = "");
|
|
1105
1105
|
})))
|
|
1106
1106
|
),
|
|
1107
1107
|
// Render overlay content to body when dragging (if content is provided)
|
|
1108
|
-
n != null ?
|
|
1108
|
+
n != null ? B(l, () => n({ files: c })) : null,
|
|
1109
1109
|
s != null ? s({ isDragging: l, files: c, selectFiles: x }) : null
|
|
1110
1110
|
);
|
|
1111
1111
|
}
|
|
@@ -1184,21 +1184,21 @@ function Tr({
|
|
|
1184
1184
|
)
|
|
1185
1185
|
),
|
|
1186
1186
|
a.role("progressbar"),
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1187
|
+
L.valuemin(0),
|
|
1188
|
+
L.valuemax(t),
|
|
1189
|
+
L.valuenow(e),
|
|
1190
|
+
L.valuetext(d),
|
|
1191
1191
|
i.div(
|
|
1192
1192
|
a.class("bc-progress-bar__track"),
|
|
1193
1193
|
i.div(a.class("bc-progress-bar__fill"), D.width(o))
|
|
1194
1194
|
)
|
|
1195
1195
|
),
|
|
1196
1196
|
// Optional label
|
|
1197
|
-
|
|
1197
|
+
B(
|
|
1198
1198
|
u,
|
|
1199
1199
|
() => i.div(
|
|
1200
1200
|
a.class("bc-progress-bar__label"),
|
|
1201
|
-
|
|
1201
|
+
L.hidden(!0),
|
|
1202
1202
|
d
|
|
1203
1203
|
),
|
|
1204
1204
|
() => {
|
|
@@ -1230,7 +1230,7 @@ function Lr({
|
|
|
1230
1230
|
e,
|
|
1231
1231
|
s
|
|
1232
1232
|
)((c, d) => c === "text" && (d ?? 1) > 1);
|
|
1233
|
-
return
|
|
1233
|
+
return B(
|
|
1234
1234
|
l,
|
|
1235
1235
|
// Multi-line text skeleton
|
|
1236
1236
|
() => i.div(
|
|
@@ -1275,7 +1275,7 @@ function Lr({
|
|
|
1275
1275
|
e
|
|
1276
1276
|
)((c, d, o) => ba(c, d, o ?? "text"))
|
|
1277
1277
|
),
|
|
1278
|
-
|
|
1278
|
+
L.hidden(!0)
|
|
1279
1279
|
)
|
|
1280
1280
|
);
|
|
1281
1281
|
}
|
|
@@ -1306,13 +1306,13 @@ function Pr({
|
|
|
1306
1306
|
l,
|
|
1307
1307
|
c
|
|
1308
1308
|
)(
|
|
1309
|
-
(p, _, m, w, x,
|
|
1309
|
+
(p, _, m, w, x, C) => fa(
|
|
1310
1310
|
p ?? "md",
|
|
1311
1311
|
_ ?? !1,
|
|
1312
1312
|
m ?? !1,
|
|
1313
1313
|
w ?? !1,
|
|
1314
1314
|
x ?? !1,
|
|
1315
|
-
|
|
1315
|
+
C ?? !0
|
|
1316
1316
|
)
|
|
1317
1317
|
), f = k(
|
|
1318
1318
|
n,
|
|
@@ -1440,7 +1440,7 @@ function va({
|
|
|
1440
1440
|
a.type("button"),
|
|
1441
1441
|
a.disabled(n),
|
|
1442
1442
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
1443
|
-
|
|
1443
|
+
L.pressed(e),
|
|
1444
1444
|
a.class(
|
|
1445
1445
|
k(
|
|
1446
1446
|
r,
|
|
@@ -1486,7 +1486,7 @@ function Ar({
|
|
|
1486
1486
|
a.role("group"),
|
|
1487
1487
|
a.class(k(o, d)(ya)),
|
|
1488
1488
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
1489
|
-
|
|
1489
|
+
L.orientation(o),
|
|
1490
1490
|
...e.map((f) => {
|
|
1491
1491
|
const b = h.map(t, (_) => _.includes(f.key)), p = f.disabled ? h.map(r, (_) => _ || f.disabled) : r;
|
|
1492
1492
|
return va(
|
|
@@ -1555,7 +1555,7 @@ const bn = ({
|
|
|
1555
1555
|
},
|
|
1556
1556
|
a.class("bc-tag__close")
|
|
1557
1557
|
)
|
|
1558
|
-
) :
|
|
1558
|
+
) : j
|
|
1559
1559
|
);
|
|
1560
1560
|
function ka({
|
|
1561
1561
|
value: e,
|
|
@@ -1611,12 +1611,12 @@ function xa({
|
|
|
1611
1611
|
a.class("bc-color-input__swatch"),
|
|
1612
1612
|
I.click(() => s?.showPicker()),
|
|
1613
1613
|
De.color(
|
|
1614
|
-
re((r) => (s = r,
|
|
1614
|
+
re((r) => (s = r, j)),
|
|
1615
1615
|
a.value(e),
|
|
1616
1616
|
D.width("4px"),
|
|
1617
1617
|
D.height("4px"),
|
|
1618
|
-
t != null ? I.change(de(t)) :
|
|
1619
|
-
n != null ? I.input(de(n)) :
|
|
1618
|
+
t != null ? I.change(de(t)) : j,
|
|
1619
|
+
n != null ? I.input(de(n)) : j
|
|
1620
1620
|
),
|
|
1621
1621
|
a.style(h.map(e, (r) => `background-color: ${r}`))
|
|
1622
1622
|
)
|
|
@@ -1630,9 +1630,9 @@ function Ca(e) {
|
|
|
1630
1630
|
input: De.text(
|
|
1631
1631
|
Ie(e),
|
|
1632
1632
|
a.value(t),
|
|
1633
|
-
n != null ? I.blur(de(n)) :
|
|
1634
|
-
s != null ? I.change(de(s)) :
|
|
1635
|
-
r != null ? I.input(de(r)) :
|
|
1633
|
+
n != null ? I.blur(de(n)) : j,
|
|
1634
|
+
s != null ? I.change(de(s)) : j,
|
|
1635
|
+
r != null ? I.input(de(r)) : j
|
|
1636
1636
|
)
|
|
1637
1637
|
},
|
|
1638
1638
|
a.class("bc-color-input"),
|
|
@@ -1730,15 +1730,15 @@ function Er({
|
|
|
1730
1730
|
(b) => b ? "bc-accordion__item--open" : "bc-accordion__item--closed"
|
|
1731
1731
|
)
|
|
1732
1732
|
),
|
|
1733
|
-
c.disabled ? a.class("bc-accordion__item--disabled") :
|
|
1733
|
+
c.disabled ? a.class("bc-accordion__item--disabled") : j,
|
|
1734
1734
|
// Header / trigger
|
|
1735
1735
|
i.button(
|
|
1736
1736
|
a.type("button"),
|
|
1737
1737
|
a.class("bc-accordion__header"),
|
|
1738
1738
|
a.id(g),
|
|
1739
1739
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
1740
|
-
|
|
1741
|
-
|
|
1740
|
+
L.expanded(o),
|
|
1741
|
+
L.controls(f),
|
|
1742
1742
|
a.disabled(c.disabled ?? !1),
|
|
1743
1743
|
I.click((b) => {
|
|
1744
1744
|
b.preventDefault(), c.disabled || l(c.key);
|
|
@@ -1759,7 +1759,7 @@ function Er({
|
|
|
1759
1759
|
i.div(
|
|
1760
1760
|
a.id(f),
|
|
1761
1761
|
a.role("region"),
|
|
1762
|
-
|
|
1762
|
+
L.labelledby(g),
|
|
1763
1763
|
i.div(
|
|
1764
1764
|
kt(
|
|
1765
1765
|
{ open: o },
|
|
@@ -1821,7 +1821,7 @@ function Nr({
|
|
|
1821
1821
|
(_, m, w, x) => Da(_, m, w, x)
|
|
1822
1822
|
)
|
|
1823
1823
|
),
|
|
1824
|
-
|
|
1824
|
+
B(
|
|
1825
1825
|
p,
|
|
1826
1826
|
() => Q(
|
|
1827
1827
|
Ln(
|
|
@@ -1834,7 +1834,7 @@ function Nr({
|
|
|
1834
1834
|
a.role("button")
|
|
1835
1835
|
)
|
|
1836
1836
|
),
|
|
1837
|
-
|
|
1837
|
+
L.disabled(r),
|
|
1838
1838
|
// Icon container
|
|
1839
1839
|
i.div(
|
|
1840
1840
|
a.class("bc-action-card__icon"),
|
|
@@ -2171,10 +2171,10 @@ function Fr({
|
|
|
2171
2171
|
}), o = l.map(d), g = r.header != null || s.menu != null || s.aside != null, f = k(
|
|
2172
2172
|
s.aside != null,
|
|
2173
2173
|
o
|
|
2174
|
-
)((
|
|
2174
|
+
)((C, { displayAside: $ }) => C && !$), b = k(
|
|
2175
2175
|
s.menu != null,
|
|
2176
2176
|
o
|
|
2177
|
-
)((
|
|
2177
|
+
)((C, { displayMenu: $ }) => C && !$), p = Qe(), _ = Qe(), m = H(0), w = k(
|
|
2178
2178
|
s.menu != null,
|
|
2179
2179
|
o,
|
|
2180
2180
|
p.display
|
|
@@ -2209,13 +2209,13 @@ function Fr({
|
|
|
2209
2209
|
D.zIndex("20"),
|
|
2210
2210
|
D.display(g ? "block" : "none"),
|
|
2211
2211
|
D.gridArea("header"),
|
|
2212
|
-
Ue((
|
|
2212
|
+
Ue((C) => (C.$.bottom.feedProp(m), null)),
|
|
2213
2213
|
i.div(
|
|
2214
2214
|
D.display("flex"),
|
|
2215
2215
|
D.height("100%"),
|
|
2216
2216
|
i.div(
|
|
2217
2217
|
D.display(
|
|
2218
|
-
b.map((
|
|
2218
|
+
b.map((C) => C ? "flex" : "none")
|
|
2219
2219
|
),
|
|
2220
2220
|
D.alignItems("center"),
|
|
2221
2221
|
D.justifyContent("center"),
|
|
@@ -2227,10 +2227,10 @@ function Fr({
|
|
|
2227
2227
|
variant: "light",
|
|
2228
2228
|
color: "base"
|
|
2229
2229
|
},
|
|
2230
|
-
|
|
2230
|
+
L.label(u.$.toggleMenu),
|
|
2231
2231
|
K({
|
|
2232
2232
|
icon: p.display.map(
|
|
2233
|
-
(
|
|
2233
|
+
(C) => C ? "line-md/menu-to-close-alt-transition" : "line-md/close-to-menu-alt-transition"
|
|
2234
2234
|
)
|
|
2235
2235
|
})
|
|
2236
2236
|
)
|
|
@@ -2246,7 +2246,7 @@ function Fr({
|
|
|
2246
2246
|
D.height("100%"),
|
|
2247
2247
|
D.width("60px"),
|
|
2248
2248
|
D.display(
|
|
2249
|
-
f.map((
|
|
2249
|
+
f.map((C) => C ? "flex" : "none")
|
|
2250
2250
|
),
|
|
2251
2251
|
Ve(
|
|
2252
2252
|
{
|
|
@@ -2255,13 +2255,13 @@ function Fr({
|
|
|
2255
2255
|
variant: "light",
|
|
2256
2256
|
color: "base"
|
|
2257
2257
|
},
|
|
2258
|
-
|
|
2258
|
+
L.label(u.$.toggleAside),
|
|
2259
2259
|
K(
|
|
2260
2260
|
{ icon: "line-md/chevron-left" },
|
|
2261
2261
|
a.style("transition: transform 0.2s ease-in-out"),
|
|
2262
2262
|
a.style(
|
|
2263
2263
|
_.display.map(
|
|
2264
|
-
(
|
|
2264
|
+
(C) => `transform: rotate(${C ? 180 : 0}deg)`
|
|
2265
2265
|
)
|
|
2266
2266
|
)
|
|
2267
2267
|
)
|
|
@@ -2270,15 +2270,15 @@ function Fr({
|
|
|
2270
2270
|
)
|
|
2271
2271
|
),
|
|
2272
2272
|
n.menu ? i.nav(
|
|
2273
|
-
re((
|
|
2273
|
+
re((C) => p.setElement(C)),
|
|
2274
2274
|
D.zIndex("10"),
|
|
2275
2275
|
// Add ARIA attributes for navigation landmark
|
|
2276
|
-
|
|
2276
|
+
L.label(u.$.mainNavigation),
|
|
2277
2277
|
a.role("navigation"),
|
|
2278
2278
|
D.overflow("hidden"),
|
|
2279
2279
|
a.class(
|
|
2280
2280
|
w.map(
|
|
2281
|
-
(
|
|
2281
|
+
(C) => C === "float" ? ye(
|
|
2282
2282
|
"right",
|
|
2283
2283
|
n.menu?.shadow ?? "md"
|
|
2284
2284
|
) : ye(
|
|
@@ -2290,7 +2290,7 @@ function Fr({
|
|
|
2290
2290
|
Pe(n.menu?.color ?? "white"),
|
|
2291
2291
|
D.height(
|
|
2292
2292
|
w.map(
|
|
2293
|
-
(
|
|
2293
|
+
(C) => C === "float" ? "auto" : "100%"
|
|
2294
2294
|
)
|
|
2295
2295
|
),
|
|
2296
2296
|
D.overflow("hidden"),
|
|
@@ -2299,24 +2299,24 @@ function Fr({
|
|
|
2299
2299
|
k(
|
|
2300
2300
|
w,
|
|
2301
2301
|
p.status
|
|
2302
|
-
)((
|
|
2302
|
+
)((C, $) => C === "none" && $ === "closed" ? "none" : "block")
|
|
2303
2303
|
),
|
|
2304
2304
|
D.position(
|
|
2305
2305
|
k(
|
|
2306
2306
|
w,
|
|
2307
2307
|
p.status
|
|
2308
|
-
)((
|
|
2308
|
+
)((C, $) => C === "float" || C === "none" && $ !== "closed" ? "fixed" : "initial")
|
|
2309
2309
|
),
|
|
2310
|
-
D.top(m.map((
|
|
2311
|
-
re((
|
|
2312
|
-
|
|
2310
|
+
D.top(m.map((C) => `${C}px`)),
|
|
2311
|
+
re((C) => {
|
|
2312
|
+
C.style.setProperty("--slide-distance", "100%");
|
|
2313
2313
|
}),
|
|
2314
2314
|
Tt({
|
|
2315
2315
|
animation: { slide: "right" },
|
|
2316
2316
|
status: k(
|
|
2317
2317
|
w,
|
|
2318
2318
|
p.status
|
|
2319
|
-
)((
|
|
2319
|
+
)((C, $) => C === "block" ? "opened" : $)
|
|
2320
2320
|
}),
|
|
2321
2321
|
D.width(he(n.menu?.width, o.$.menuWidth)),
|
|
2322
2322
|
D.bottom("0"),
|
|
@@ -2357,16 +2357,16 @@ function Fr({
|
|
|
2357
2357
|
n.mainFooter.content
|
|
2358
2358
|
) : null,
|
|
2359
2359
|
n.aside ? i.aside(
|
|
2360
|
-
re((
|
|
2361
|
-
_.setElement(
|
|
2360
|
+
re((C) => {
|
|
2361
|
+
_.setElement(C);
|
|
2362
2362
|
}),
|
|
2363
2363
|
D.zIndex("10"),
|
|
2364
2364
|
// Add ARIA attributes for aside landmark
|
|
2365
|
-
|
|
2365
|
+
L.label(u.$.sidebar),
|
|
2366
2366
|
a.role("complementary"),
|
|
2367
2367
|
a.class(
|
|
2368
2368
|
x.map(
|
|
2369
|
-
(
|
|
2369
|
+
(C) => C === "float" ? ye("left", "md") : ye("left", "none")
|
|
2370
2370
|
)
|
|
2371
2371
|
),
|
|
2372
2372
|
Pe("white"),
|
|
@@ -2376,29 +2376,29 @@ function Fr({
|
|
|
2376
2376
|
k(
|
|
2377
2377
|
x,
|
|
2378
2378
|
_.status
|
|
2379
|
-
)((
|
|
2379
|
+
)((C, $) => C === "none" && $ === "closed" ? "none" : "block")
|
|
2380
2380
|
),
|
|
2381
2381
|
D.position(
|
|
2382
2382
|
k(
|
|
2383
2383
|
x,
|
|
2384
2384
|
_.status
|
|
2385
|
-
)((
|
|
2385
|
+
)((C, $) => C === "float" || C === "none" && $ !== "closed" ? "fixed" : "initial")
|
|
2386
2386
|
),
|
|
2387
|
-
D.top(m.map((
|
|
2388
|
-
re((
|
|
2389
|
-
|
|
2387
|
+
D.top(m.map((C) => `${C}px`)),
|
|
2388
|
+
re((C) => {
|
|
2389
|
+
C.style.setProperty("--slide-distance", "100%");
|
|
2390
2390
|
}),
|
|
2391
2391
|
Tt({
|
|
2392
2392
|
animation: { slide: "left" },
|
|
2393
2393
|
status: k(
|
|
2394
2394
|
x,
|
|
2395
2395
|
_.status
|
|
2396
|
-
)((
|
|
2396
|
+
)((C, $) => C === "block" ? "opened" : $)
|
|
2397
2397
|
}),
|
|
2398
2398
|
D.width(
|
|
2399
2399
|
he(n.aside?.width, o.$.asideWidth)
|
|
2400
2400
|
),
|
|
2401
|
-
D.bottom(m.map((
|
|
2401
|
+
D.bottom(m.map((C) => `${C}px`)),
|
|
2402
2402
|
n.aside.content
|
|
2403
2403
|
) : null,
|
|
2404
2404
|
n.footer ? i.footer(
|
|
@@ -2503,48 +2503,48 @@ function Hr({
|
|
|
2503
2503
|
sidebarEndWidth: _ = 0,
|
|
2504
2504
|
anchorMode: m = "container-edge"
|
|
2505
2505
|
}) {
|
|
2506
|
-
const w = H(0n), x = H(0n),
|
|
2506
|
+
const w = H(0n), x = H(0n), C = Rt(r), $ = Rt(b), y = H(16);
|
|
2507
2507
|
return i.div(
|
|
2508
2508
|
a.class("bc-nine-slice-container"),
|
|
2509
2509
|
Ue((S) => {
|
|
2510
|
-
const
|
|
2510
|
+
const v = k(
|
|
2511
2511
|
S.$.width,
|
|
2512
2512
|
b,
|
|
2513
2513
|
_
|
|
2514
|
-
)((M, z, se) => M - z - se),
|
|
2514
|
+
)((M, z, se) => M - z - se), T = k(
|
|
2515
2515
|
S.$.height,
|
|
2516
2516
|
r,
|
|
2517
2517
|
d
|
|
2518
2518
|
)((M, z, se) => M - z - se), E = k(
|
|
2519
2519
|
t,
|
|
2520
|
-
y
|
|
2521
|
-
)((M, z) => M > BigInt(z)), j = k(
|
|
2522
|
-
n,
|
|
2523
|
-
L
|
|
2524
|
-
)((M, z) => M > BigInt(z)), B = k(
|
|
2525
|
-
y,
|
|
2526
|
-
j,
|
|
2527
2520
|
v
|
|
2521
|
+
)((M, z) => M > BigInt(z)), U = k(
|
|
2522
|
+
n,
|
|
2523
|
+
T
|
|
2524
|
+
)((M, z) => M > BigInt(z)), V = k(
|
|
2525
|
+
v,
|
|
2526
|
+
U,
|
|
2527
|
+
y
|
|
2528
2528
|
)((M, z, se) => z ? M - se : M), N = k(
|
|
2529
|
-
|
|
2529
|
+
T,
|
|
2530
2530
|
E,
|
|
2531
|
-
|
|
2531
|
+
y
|
|
2532
2532
|
)((M, z, se) => z ? M - se : M), q = k(
|
|
2533
2533
|
t,
|
|
2534
|
-
|
|
2534
|
+
V
|
|
2535
2535
|
)((M, z) => Number(M / BigInt(Math.max(1, z)))), ie = k(
|
|
2536
2536
|
n,
|
|
2537
2537
|
N
|
|
2538
2538
|
)((M, z) => Number(M / BigInt(Math.max(1, z)))), O = h.map(
|
|
2539
2539
|
m,
|
|
2540
2540
|
(M) => M === "body-end" || M === "body-end-bottom"
|
|
2541
|
-
), A =
|
|
2541
|
+
), A = B(
|
|
2542
2542
|
O,
|
|
2543
2543
|
() => D.left(
|
|
2544
2544
|
k(
|
|
2545
2545
|
b,
|
|
2546
2546
|
t,
|
|
2547
|
-
|
|
2547
|
+
V,
|
|
2548
2548
|
_
|
|
2549
2549
|
)((M, z, se, P) => {
|
|
2550
2550
|
const R = M + Number(z), Y = M + se, ae = Math.min(R, Y);
|
|
@@ -2555,7 +2555,7 @@ function Hr({
|
|
|
2555
2555
|
), F = h.map(
|
|
2556
2556
|
m,
|
|
2557
2557
|
(M) => M === "body-bottom" || M === "body-end-bottom"
|
|
2558
|
-
), W =
|
|
2558
|
+
), W = B(
|
|
2559
2559
|
F,
|
|
2560
2560
|
() => D.top(
|
|
2561
2561
|
k(
|
|
@@ -2570,17 +2570,17 @@ function Hr({
|
|
|
2570
2570
|
),
|
|
2571
2571
|
() => D.bottom("0")
|
|
2572
2572
|
), Z = k(
|
|
2573
|
-
|
|
2574
|
-
|
|
2573
|
+
U,
|
|
2574
|
+
y
|
|
2575
2575
|
)((M, z) => M ? `${z}px` : "0"), J = k(
|
|
2576
2576
|
E,
|
|
2577
|
-
|
|
2577
|
+
y
|
|
2578
2578
|
)((M, z) => M ? `${z}px` : "0"), ce = D.transform(
|
|
2579
2579
|
k(
|
|
2580
2580
|
x,
|
|
2581
2581
|
w,
|
|
2582
2582
|
E,
|
|
2583
|
-
|
|
2583
|
+
U
|
|
2584
2584
|
)((M, z, se, P) => {
|
|
2585
2585
|
const R = se ? `translateX(-${M}px)` : "", Y = P ? `translateY(-${z}px)` : "";
|
|
2586
2586
|
return `${R} ${Y}`.trim() || "none";
|
|
@@ -2594,11 +2594,11 @@ function Hr({
|
|
|
2594
2594
|
N
|
|
2595
2595
|
)((M, z) => M - BigInt(Math.max(1, z))), Oe = k(
|
|
2596
2596
|
t,
|
|
2597
|
-
|
|
2597
|
+
V
|
|
2598
2598
|
)((M, z) => M - BigInt(Math.max(1, z)));
|
|
2599
2599
|
let X = null, Be = 0, Ee = 0;
|
|
2600
2600
|
const tt = () => {
|
|
2601
|
-
const M = Te.value, z = Oe.value, se =
|
|
2601
|
+
const M = Te.value, z = Oe.value, se = U.value, P = E.value;
|
|
2602
2602
|
if (se && Ee !== 0) {
|
|
2603
2603
|
const R = Vt(
|
|
2604
2604
|
qe(0n, M),
|
|
@@ -2623,7 +2623,7 @@ function Hr({
|
|
|
2623
2623
|
};
|
|
2624
2624
|
return E.on((M) => {
|
|
2625
2625
|
M || x.set(0n);
|
|
2626
|
-
}),
|
|
2626
|
+
}), U.on((M) => {
|
|
2627
2627
|
M || w.set(0n);
|
|
2628
2628
|
}), Q(
|
|
2629
2629
|
ge(() => {
|
|
@@ -2651,7 +2651,7 @@ function Hr({
|
|
|
2651
2651
|
s != null ? i.div(
|
|
2652
2652
|
a.class("bc-nine-slice-pane bc-nine-slice-header"),
|
|
2653
2653
|
D.top("0"),
|
|
2654
|
-
D.left(
|
|
2654
|
+
D.left($),
|
|
2655
2655
|
// style.height(headerHeightPx),
|
|
2656
2656
|
// style.width(visibleAreaWidthPx),
|
|
2657
2657
|
i.div(
|
|
@@ -2673,7 +2673,7 @@ function Hr({
|
|
|
2673
2673
|
f != null ? i.div(
|
|
2674
2674
|
a.class("bc-nine-slice-pane bc-nine-slice-sidebar-start"),
|
|
2675
2675
|
D.left("0"),
|
|
2676
|
-
D.top(
|
|
2676
|
+
D.top(C),
|
|
2677
2677
|
// style.height(visibleAreaHeightPx),
|
|
2678
2678
|
// style.width(sidebarStartWidthPx),
|
|
2679
2679
|
i.div(
|
|
@@ -2685,8 +2685,8 @@ function Hr({
|
|
|
2685
2685
|
// middle-center (main body)
|
|
2686
2686
|
i.div(
|
|
2687
2687
|
a.class("bc-nine-slice-pane bc-nine-slice-body"),
|
|
2688
|
-
D.left(
|
|
2689
|
-
D.top(
|
|
2688
|
+
D.left($),
|
|
2689
|
+
D.top(C),
|
|
2690
2690
|
// style.width(visibleAreaWidth.map(toPx)),
|
|
2691
2691
|
// style.height(visibleAreaHeight.map(toPx)),
|
|
2692
2692
|
i.div(
|
|
@@ -2699,7 +2699,7 @@ function Hr({
|
|
|
2699
2699
|
p != null ? i.div(
|
|
2700
2700
|
a.class("bc-nine-slice-pane bc-nine-slice-sidebar-end"),
|
|
2701
2701
|
A,
|
|
2702
|
-
D.top(
|
|
2702
|
+
D.top(C),
|
|
2703
2703
|
// style.height(visibleAreaHeightPx),
|
|
2704
2704
|
// style.width(sidebarEndWidthPx),
|
|
2705
2705
|
i.div(
|
|
@@ -2720,7 +2720,7 @@ function Hr({
|
|
|
2720
2720
|
// bottom-center
|
|
2721
2721
|
c != null ? i.div(
|
|
2722
2722
|
a.class("bc-nine-slice-pane bc-nine-slice-footer"),
|
|
2723
|
-
D.left(
|
|
2723
|
+
D.left($),
|
|
2724
2724
|
W,
|
|
2725
2725
|
// style.height(footerHeightPx),
|
|
2726
2726
|
// style.width(visibleAreaWidthPx),
|
|
@@ -2747,8 +2747,8 @@ function Hr({
|
|
|
2747
2747
|
D.left("0"),
|
|
2748
2748
|
D.right(
|
|
2749
2749
|
k(
|
|
2750
|
-
|
|
2751
|
-
|
|
2750
|
+
U,
|
|
2751
|
+
y
|
|
2752
2752
|
)((M, z) => M ? `${z}px` : "0")
|
|
2753
2753
|
),
|
|
2754
2754
|
D.bottom("0"),
|
|
@@ -2785,12 +2785,12 @@ function Hr({
|
|
|
2785
2785
|
D.bottom(
|
|
2786
2786
|
k(
|
|
2787
2787
|
E,
|
|
2788
|
-
|
|
2788
|
+
y
|
|
2789
2789
|
)((M, z) => M ? `${z}px` : "0")
|
|
2790
2790
|
),
|
|
2791
2791
|
D.right("0"),
|
|
2792
2792
|
D.width(
|
|
2793
|
-
|
|
2793
|
+
U.map(
|
|
2794
2794
|
(M) => M ? "16px" : "0"
|
|
2795
2795
|
)
|
|
2796
2796
|
),
|
|
@@ -3014,51 +3014,52 @@ const Me = {
|
|
|
3014
3014
|
}, gn = (e) => {
|
|
3015
3015
|
const {
|
|
3016
3016
|
onChange: t,
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3017
|
+
onInput: n,
|
|
3018
|
+
onBlur: s,
|
|
3019
|
+
role: r,
|
|
3020
|
+
display: u,
|
|
3021
|
+
optionsSource: l,
|
|
3022
|
+
allowSpaceToggle: c = !1,
|
|
3023
|
+
onBeforeOpen: d,
|
|
3024
|
+
onAfterOpen: o,
|
|
3025
|
+
buildListboxContent: g
|
|
3026
|
+
} = e, f = H(!1), b = H(-1), p = H(null), _ = me("dropdown"), m = me("listbox");
|
|
3027
|
+
let w, x, C;
|
|
3028
|
+
const $ = (S) => {
|
|
3029
|
+
t?.(S), n?.(S), f.set(!1), b.set(-1), p.set(null), C?.(), w?.focus();
|
|
3030
|
+
}, y = (S) => {
|
|
3031
|
+
const v = Me.getValues(h.get(l));
|
|
3032
|
+
switch (S.key) {
|
|
3032
3033
|
case "ArrowDown": {
|
|
3033
|
-
if (
|
|
3034
|
-
|
|
3034
|
+
if (S.preventDefault(), !f.value)
|
|
3035
|
+
f.set(!0), v.length > 0 && (b.set(0), p.set(v[0]));
|
|
3035
3036
|
else {
|
|
3036
|
-
const
|
|
3037
|
-
|
|
3038
|
-
|
|
3037
|
+
const T = Math.min(
|
|
3038
|
+
b.value + 1,
|
|
3039
|
+
v.length - 1
|
|
3039
3040
|
);
|
|
3040
|
-
|
|
3041
|
+
b.set(T), p.set(v[T] ?? null);
|
|
3041
3042
|
}
|
|
3042
3043
|
break;
|
|
3043
3044
|
}
|
|
3044
3045
|
case "ArrowUp": {
|
|
3045
|
-
if (
|
|
3046
|
-
const
|
|
3047
|
-
|
|
3046
|
+
if (S.preventDefault(), f.value) {
|
|
3047
|
+
const T = Math.max(b.value - 1, 0);
|
|
3048
|
+
b.set(T), p.set(v[T] ?? null);
|
|
3048
3049
|
}
|
|
3049
3050
|
break;
|
|
3050
3051
|
}
|
|
3051
3052
|
case "Enter": {
|
|
3052
|
-
if (
|
|
3053
|
-
const
|
|
3054
|
-
|
|
3053
|
+
if (S.preventDefault(), f.value && b.value >= 0) {
|
|
3054
|
+
const T = v[b.value];
|
|
3055
|
+
T != null && $(T);
|
|
3055
3056
|
} else {
|
|
3056
|
-
|
|
3057
|
-
const
|
|
3058
|
-
|
|
3057
|
+
d?.();
|
|
3058
|
+
const T = Me.getValues(h.get(l));
|
|
3059
|
+
f.set(!0), T.length > 0 && (b.set(0), p.set(T[0])), setTimeout(() => {
|
|
3059
3060
|
requestAnimationFrame(() => {
|
|
3060
3061
|
requestAnimationFrame(() => {
|
|
3061
|
-
|
|
3062
|
+
o?.();
|
|
3062
3063
|
});
|
|
3063
3064
|
});
|
|
3064
3065
|
}, 0);
|
|
@@ -3066,14 +3067,14 @@ const Me = {
|
|
|
3066
3067
|
break;
|
|
3067
3068
|
}
|
|
3068
3069
|
case "Escape": {
|
|
3069
|
-
|
|
3070
|
+
f.value && (S.preventDefault(), f.set(!1), b.set(-1), p.set(null), w?.focus());
|
|
3070
3071
|
break;
|
|
3071
3072
|
}
|
|
3072
3073
|
case " ": {
|
|
3073
|
-
if (h.get(
|
|
3074
|
-
|
|
3075
|
-
const
|
|
3076
|
-
|
|
3074
|
+
if (h.get(c)) {
|
|
3075
|
+
S.preventDefault();
|
|
3076
|
+
const T = Me.getValues(h.get(l));
|
|
3077
|
+
f.set(!f.value), f.value && T.length > 0 && (b.set(0), p.set(T[0]));
|
|
3077
3078
|
}
|
|
3078
3079
|
break;
|
|
3079
3080
|
}
|
|
@@ -3084,79 +3085,79 @@ const Me = {
|
|
|
3084
3085
|
...e,
|
|
3085
3086
|
input: en(
|
|
3086
3087
|
a.class("bc-dropdown__trigger"),
|
|
3087
|
-
i.span(a.class("bc-dropdown__display"),
|
|
3088
|
+
i.span(a.class("bc-dropdown__display"), u),
|
|
3088
3089
|
K(
|
|
3089
3090
|
{ icon: "ph:caret-up-down-bold", color: "neutral" },
|
|
3090
3091
|
a.class("bc-dropdown__arrow")
|
|
3091
3092
|
)
|
|
3092
3093
|
)
|
|
3093
3094
|
},
|
|
3094
|
-
Ue((
|
|
3095
|
-
re((
|
|
3096
|
-
() =>
|
|
3095
|
+
Ue((S) => Q(
|
|
3096
|
+
re((v) => (w = v, v.addEventListener("keydown", y), ge(
|
|
3097
|
+
() => v.removeEventListener("keydown", y)
|
|
3097
3098
|
))),
|
|
3098
3099
|
Ie(e),
|
|
3099
|
-
a.id(
|
|
3100
|
+
a.id(_),
|
|
3100
3101
|
a.tabindex(0),
|
|
3101
|
-
|
|
3102
|
-
|
|
3102
|
+
L.controls(m),
|
|
3103
|
+
L.expanded(f),
|
|
3103
3104
|
a.class("bc-dropdown"),
|
|
3104
|
-
a.role(
|
|
3105
|
-
|
|
3105
|
+
a.role(r),
|
|
3106
|
+
L.activedescendant(
|
|
3106
3107
|
k(
|
|
3107
|
-
|
|
3108
|
-
|
|
3108
|
+
f,
|
|
3109
|
+
p
|
|
3109
3110
|
)(
|
|
3110
|
-
(
|
|
3111
|
+
(v, T) => v && T != null ? `dropdown-option-${String(T)}` : ""
|
|
3111
3112
|
)
|
|
3112
3113
|
),
|
|
3113
|
-
|
|
3114
|
+
s != null ? I.blur(() => {
|
|
3114
3115
|
setTimeout(() => {
|
|
3115
|
-
|
|
3116
|
+
x?.contains(document.activeElement) || (f.set(!1), b.set(-1), s());
|
|
3116
3117
|
}, 100);
|
|
3117
|
-
}) :
|
|
3118
|
+
}) : j,
|
|
3118
3119
|
wt({
|
|
3119
3120
|
content: () => i.div(
|
|
3120
|
-
re((
|
|
3121
|
-
|
|
3121
|
+
re((v) => {
|
|
3122
|
+
x = v;
|
|
3122
3123
|
}),
|
|
3123
|
-
D.minWidth(
|
|
3124
|
+
D.minWidth(S.$.width.map((v) => `${v - 10}px`)),
|
|
3124
3125
|
a.class("bc-dropdown__listbox"),
|
|
3125
3126
|
a.role("listbox"),
|
|
3126
|
-
a.id(
|
|
3127
|
-
|
|
3128
|
-
|
|
3129
|
-
dropdownId:
|
|
3130
|
-
listboxId:
|
|
3131
|
-
focusedValue:
|
|
3132
|
-
handleKeyDown:
|
|
3127
|
+
a.id(m),
|
|
3128
|
+
L.labelledby(_),
|
|
3129
|
+
g({
|
|
3130
|
+
dropdownId: _,
|
|
3131
|
+
listboxId: m,
|
|
3132
|
+
focusedValue: p,
|
|
3133
|
+
handleKeyDown: y,
|
|
3133
3134
|
onSelect: $
|
|
3134
3135
|
})
|
|
3135
3136
|
),
|
|
3136
3137
|
mainAxisOffset: 0,
|
|
3137
3138
|
placement: "bottom-start",
|
|
3138
3139
|
hasPopup: "listbox",
|
|
3139
|
-
showOn: (
|
|
3140
|
-
const
|
|
3141
|
-
|
|
3142
|
-
|
|
3143
|
-
},
|
|
3144
|
-
const
|
|
3145
|
-
if (
|
|
3146
|
-
|
|
3140
|
+
showOn: (v, T) => {
|
|
3141
|
+
const E = T;
|
|
3142
|
+
T = () => {
|
|
3143
|
+
f.set(!1), b.set(-1), p.set(null), E();
|
|
3144
|
+
}, C = T;
|
|
3145
|
+
const U = () => {
|
|
3146
|
+
if (f.value)
|
|
3147
|
+
T();
|
|
3147
3148
|
else {
|
|
3148
|
-
|
|
3149
|
-
const
|
|
3150
|
-
|
|
3149
|
+
d?.();
|
|
3150
|
+
const V = Me.getValues(h.get(l));
|
|
3151
|
+
f.set(!0), V.length > 0 && (b.set(0), p.set(V[0])), v(), setTimeout(() => {
|
|
3151
3152
|
requestAnimationFrame(() => {
|
|
3152
3153
|
requestAnimationFrame(() => {
|
|
3153
|
-
|
|
3154
|
+
o?.();
|
|
3154
3155
|
});
|
|
3155
3156
|
});
|
|
3156
3157
|
}, 0);
|
|
3157
3158
|
}
|
|
3158
3159
|
};
|
|
3159
|
-
return I.click(
|
|
3160
|
+
return I.click(U);
|
|
3160
3161
|
},
|
|
3161
3162
|
showDelay: 0,
|
|
3162
3163
|
hideDelay: 0,
|
|
@@ -3189,12 +3190,12 @@ const Me = {
|
|
|
3189
3190
|
),
|
|
3190
3191
|
a.role("option"),
|
|
3191
3192
|
a.id(l.map((o) => `dropdown-option-${String(o.value)}`)),
|
|
3192
|
-
|
|
3193
|
+
L.selected(c),
|
|
3193
3194
|
qn("value", l.$.value),
|
|
3194
|
-
|
|
3195
|
+
B(
|
|
3195
3196
|
l.map((o) => !o.disabled),
|
|
3196
3197
|
() => I.click(() => s(l.value.value)),
|
|
3197
|
-
() =>
|
|
3198
|
+
() => j
|
|
3198
3199
|
),
|
|
3199
3200
|
i.div(
|
|
3200
3201
|
a.class("bc-dropdown__option-content"),
|
|
@@ -3213,7 +3214,7 @@ const Me = {
|
|
|
3213
3214
|
group: (l) => i.div(
|
|
3214
3215
|
a.class("bc-dropdown__group"),
|
|
3215
3216
|
a.role("group"),
|
|
3216
|
-
|
|
3217
|
+
L.label(l.$.group),
|
|
3217
3218
|
i.div(a.class("bc-dropdown__group-label"), l.$.group),
|
|
3218
3219
|
oe(
|
|
3219
3220
|
l.$.options,
|
|
@@ -3256,7 +3257,7 @@ const Me = {
|
|
|
3256
3257
|
return gn({
|
|
3257
3258
|
...e,
|
|
3258
3259
|
role: "dropdown",
|
|
3259
|
-
display:
|
|
3260
|
+
display: B(
|
|
3260
3261
|
c.map((o) => o.length > 0),
|
|
3261
3262
|
() => c,
|
|
3262
3263
|
() => ne(
|
|
@@ -3309,11 +3310,11 @@ const Me = {
|
|
|
3309
3310
|
),
|
|
3310
3311
|
a.role("option"),
|
|
3311
3312
|
a.id(c.map((g) => `dropdown-option-${String(g.value)}`)),
|
|
3312
|
-
|
|
3313
|
-
|
|
3313
|
+
L.selected(d),
|
|
3314
|
+
B(
|
|
3314
3315
|
c.map((g) => !g.disabled),
|
|
3315
3316
|
() => I.click(() => s(c.value.value)),
|
|
3316
|
-
() =>
|
|
3317
|
+
() => j
|
|
3317
3318
|
),
|
|
3318
3319
|
i.div(
|
|
3319
3320
|
a.class("bc-dropdown__option-content"),
|
|
@@ -3335,7 +3336,7 @@ const Me = {
|
|
|
3335
3336
|
group: (c) => i.div(
|
|
3336
3337
|
a.class("bc-dropdown__group"),
|
|
3337
3338
|
a.role("group"),
|
|
3338
|
-
|
|
3339
|
+
L.label(c.$.group),
|
|
3339
3340
|
i.div(a.class("bc-dropdown__group-label"), c.$.group),
|
|
3340
3341
|
oe(
|
|
3341
3342
|
c.$.options,
|
|
@@ -3357,7 +3358,7 @@ const Me = {
|
|
|
3357
3358
|
loadOptions: n,
|
|
3358
3359
|
renderOption: s,
|
|
3359
3360
|
renderValue: r,
|
|
3360
|
-
equality: u = (
|
|
3361
|
+
equality: u = ($, y) => $ === y,
|
|
3361
3362
|
placeholder: l,
|
|
3362
3363
|
searchPlaceholder: c,
|
|
3363
3364
|
debounceMs: d = 150,
|
|
@@ -3366,16 +3367,16 @@ const Me = {
|
|
|
3366
3367
|
let p;
|
|
3367
3368
|
const _ = h.toSignal(t), m = () => (r ?? s)(_);
|
|
3368
3369
|
let w = null;
|
|
3369
|
-
const x = (
|
|
3370
|
-
f.set(!0), Promise.resolve(n(
|
|
3371
|
-
b.set(
|
|
3370
|
+
const x = ($) => {
|
|
3371
|
+
f.set(!0), Promise.resolve(n($)).then((y) => {
|
|
3372
|
+
b.set(y ?? []);
|
|
3372
3373
|
}).catch(() => {
|
|
3373
3374
|
b.set([]);
|
|
3374
3375
|
}).finally(() => f.set(!1));
|
|
3375
|
-
},
|
|
3376
|
+
}, C = ($) => {
|
|
3376
3377
|
w != null && (clearTimeout(w), w = null), w = setTimeout(
|
|
3377
3378
|
() => {
|
|
3378
|
-
x(
|
|
3379
|
+
x($);
|
|
3379
3380
|
},
|
|
3380
3381
|
Math.max(0, d)
|
|
3381
3382
|
);
|
|
@@ -3383,20 +3384,20 @@ const Me = {
|
|
|
3383
3384
|
return gn({
|
|
3384
3385
|
...e,
|
|
3385
3386
|
role: "combobox",
|
|
3386
|
-
display:
|
|
3387
|
-
k(t)((
|
|
3387
|
+
display: B(
|
|
3388
|
+
k(t)(($) => $ != null),
|
|
3388
3389
|
m,
|
|
3389
|
-
() => ne(le, (
|
|
3390
|
+
() => ne(le, ($) => $.$.selectOne)
|
|
3390
3391
|
),
|
|
3391
3392
|
optionsSource: b,
|
|
3392
3393
|
onBeforeOpen: () => {
|
|
3393
|
-
const
|
|
3394
|
-
$
|
|
3394
|
+
const $ = h.get(g);
|
|
3395
|
+
C($);
|
|
3395
3396
|
},
|
|
3396
3397
|
onAfterOpen: () => {
|
|
3397
3398
|
o && p?.focus();
|
|
3398
3399
|
},
|
|
3399
|
-
buildListboxContent: ({ focusedValue:
|
|
3400
|
+
buildListboxContent: ({ focusedValue: $, handleKeyDown: y, onSelect: S }) => Q(
|
|
3400
3401
|
// Search input at the top
|
|
3401
3402
|
i.div(
|
|
3402
3403
|
a.class("bc-dropdown__search"),
|
|
@@ -3407,18 +3408,18 @@ const Me = {
|
|
|
3407
3408
|
k(
|
|
3408
3409
|
c,
|
|
3409
3410
|
l
|
|
3410
|
-
)((
|
|
3411
|
+
)((v, T) => v ?? T ?? "Search")
|
|
3411
3412
|
),
|
|
3412
3413
|
a.value(g),
|
|
3413
|
-
re((
|
|
3414
|
-
I.input((
|
|
3415
|
-
const
|
|
3416
|
-
g.set(
|
|
3414
|
+
re((v) => (p = v, j)),
|
|
3415
|
+
I.input((v) => {
|
|
3416
|
+
const T = v.target;
|
|
3417
|
+
g.set(T.value), C(T.value);
|
|
3417
3418
|
}),
|
|
3418
|
-
I.keydown(
|
|
3419
|
+
I.keydown(y)
|
|
3419
3420
|
)
|
|
3420
3421
|
),
|
|
3421
|
-
|
|
3422
|
+
B(
|
|
3422
3423
|
f,
|
|
3423
3424
|
() => i.div(
|
|
3424
3425
|
a.class("bc-dropdown__loading"),
|
|
@@ -3426,12 +3427,12 @@ const Me = {
|
|
|
3426
3427
|
),
|
|
3427
3428
|
() => oe(
|
|
3428
3429
|
b,
|
|
3429
|
-
(
|
|
3430
|
-
|
|
3430
|
+
(v) => mn(
|
|
3431
|
+
v,
|
|
3431
3432
|
u,
|
|
3432
3433
|
_,
|
|
3433
3434
|
S,
|
|
3434
|
-
|
|
3435
|
+
$,
|
|
3435
3436
|
s
|
|
3436
3437
|
)
|
|
3437
3438
|
)
|
|
@@ -3532,8 +3533,8 @@ function Cn(e) {
|
|
|
3532
3533
|
i.div(
|
|
3533
3534
|
a.role("menuitem"),
|
|
3534
3535
|
a.tabindex(-1),
|
|
3535
|
-
|
|
3536
|
-
|
|
3536
|
+
L.disabled(f.disabled === !0),
|
|
3537
|
+
L.checked(b),
|
|
3537
3538
|
a.class("bc-menu-item"),
|
|
3538
3539
|
i.span(a.class("bc-menu-item__content"), f.label),
|
|
3539
3540
|
I.click(() => l(f.value))
|
|
@@ -3549,14 +3550,14 @@ function Cn(e) {
|
|
|
3549
3550
|
return i.div(
|
|
3550
3551
|
a.role("menuitem"),
|
|
3551
3552
|
a.tabindex(-1),
|
|
3552
|
-
|
|
3553
|
-
|
|
3553
|
+
L.disabled(b.disabled === !0),
|
|
3554
|
+
L.checked(p),
|
|
3554
3555
|
a.class("bc-menu-item"),
|
|
3555
3556
|
i.span(a.class("bc-menu-item__content"), b.label),
|
|
3556
3557
|
I.click(() => l(b.value))
|
|
3557
3558
|
);
|
|
3558
3559
|
}
|
|
3559
|
-
return
|
|
3560
|
+
return j;
|
|
3560
3561
|
})
|
|
3561
3562
|
)
|
|
3562
3563
|
) : g.push(sn());
|
|
@@ -3629,12 +3630,12 @@ function $n(e) {
|
|
|
3629
3630
|
const w = k(
|
|
3630
3631
|
t,
|
|
3631
3632
|
m
|
|
3632
|
-
)((x,
|
|
3633
|
+
)((x, C) => _n(x, C.value, s));
|
|
3633
3634
|
return i.div(
|
|
3634
3635
|
a.role("menuitem"),
|
|
3635
3636
|
a.tabindex(-1),
|
|
3636
|
-
|
|
3637
|
-
|
|
3637
|
+
L.disabled(m.map((x) => x.disabled === !0)),
|
|
3638
|
+
L.checked(w),
|
|
3638
3639
|
a.class("bc-menu-item"),
|
|
3639
3640
|
i.span(a.class("bc-menu-item__content"), m.$.label),
|
|
3640
3641
|
I.click(() => o(m.value.value))
|
|
@@ -3649,7 +3650,7 @@ function $n(e) {
|
|
|
3649
3650
|
})
|
|
3650
3651
|
), b = an({
|
|
3651
3652
|
items: () => [
|
|
3652
|
-
|
|
3653
|
+
B(
|
|
3653
3654
|
g.map((p) => p.length === 0),
|
|
3654
3655
|
() => i.div(
|
|
3655
3656
|
a.class("bc-dropdown__empty"),
|
|
@@ -3674,7 +3675,7 @@ function $n(e) {
|
|
|
3674
3675
|
w.removeEventListener("focus", x);
|
|
3675
3676
|
});
|
|
3676
3677
|
}
|
|
3677
|
-
return
|
|
3678
|
+
return j;
|
|
3678
3679
|
}),
|
|
3679
3680
|
closable: !0
|
|
3680
3681
|
});
|
|
@@ -3731,8 +3732,8 @@ const Xr = (e) => {
|
|
|
3731
3732
|
Ie(e),
|
|
3732
3733
|
a.valueAsDate(t),
|
|
3733
3734
|
a.class("bc-input"),
|
|
3734
|
-
n != null ? I.blur(de(n)) :
|
|
3735
|
-
s != null ? I.change(An(s)) :
|
|
3735
|
+
n != null ? I.blur(de(n)) : j,
|
|
3736
|
+
s != null ? I.change(An(s)) : j
|
|
3736
3737
|
)
|
|
3737
3738
|
});
|
|
3738
3739
|
}, Ya = (e) => {
|
|
@@ -3746,8 +3747,8 @@ const Xr = (e) => {
|
|
|
3746
3747
|
Ie(e),
|
|
3747
3748
|
a.value(h.map(t, Ya)),
|
|
3748
3749
|
a.class("bc-input"),
|
|
3749
|
-
n != null ? I.blur(de(n)) :
|
|
3750
|
-
s != null ? I.change(de((r) => s(new Date(r)))) :
|
|
3750
|
+
n != null ? I.blur(de(n)) : j,
|
|
3751
|
+
s != null ? I.change(de((r) => s(new Date(r)))) : j
|
|
3751
3752
|
)
|
|
3752
3753
|
});
|
|
3753
3754
|
};
|
|
@@ -3839,7 +3840,7 @@ function ao(e) {
|
|
|
3839
3840
|
(b) => i.span(
|
|
3840
3841
|
a.class("bc-tag-input__tag"),
|
|
3841
3842
|
i.span(a.class("bc-tag-input__tag-text"), b),
|
|
3842
|
-
|
|
3843
|
+
B(
|
|
3843
3844
|
k(u)((p) => !(p ?? !1)),
|
|
3844
3845
|
() => i.button(
|
|
3845
3846
|
a.type("button"),
|
|
@@ -3849,7 +3850,7 @@ function ao(e) {
|
|
|
3849
3850
|
}),
|
|
3850
3851
|
"×"
|
|
3851
3852
|
),
|
|
3852
|
-
() =>
|
|
3853
|
+
() => j
|
|
3853
3854
|
)
|
|
3854
3855
|
)
|
|
3855
3856
|
),
|
|
@@ -3904,8 +3905,8 @@ const so = (e) => {
|
|
|
3904
3905
|
a.value(u),
|
|
3905
3906
|
a.class("bc-input bc-input-container__tags-input"),
|
|
3906
3907
|
I.input(de((d) => u.set(d))),
|
|
3907
|
-
n != null ? I.change(c) :
|
|
3908
|
-
s != null ? I.blur(s) :
|
|
3908
|
+
n != null ? I.change(c) : j,
|
|
3909
|
+
s != null ? I.blur(s) : j
|
|
3909
3910
|
)
|
|
3910
3911
|
)
|
|
3911
3912
|
});
|
|
@@ -3975,7 +3976,7 @@ function ro({
|
|
|
3975
3976
|
I.change(() => {
|
|
3976
3977
|
h.get(r) || (h.get(o).disabled ?? !1) || n?.(h.get(o).value);
|
|
3977
3978
|
}),
|
|
3978
|
-
|
|
3979
|
+
L.disabled(
|
|
3979
3980
|
k(
|
|
3980
3981
|
r,
|
|
3981
3982
|
g
|
|
@@ -4036,26 +4037,26 @@ function oo({
|
|
|
4036
4037
|
segmentColors: m,
|
|
4037
4038
|
renderThumb: w
|
|
4038
4039
|
}) {
|
|
4039
|
-
const x = o != null ? "multi" : d != null ? "range" : "single",
|
|
4040
|
+
const x = o != null ? "multi" : d != null ? "range" : "single", C = x === "multi" ? h.get(o).length : x === "range" ? 2 : 1, $ = [];
|
|
4040
4041
|
if (b === !0)
|
|
4041
|
-
for (let
|
|
4042
|
-
|
|
4043
|
-
else Array.isArray(b) &&
|
|
4044
|
-
const
|
|
4045
|
-
function
|
|
4042
|
+
for (let V = e; V <= t; V += n)
|
|
4043
|
+
$.push({ value: V });
|
|
4044
|
+
else Array.isArray(b) && $.push(...b);
|
|
4045
|
+
const y = x === "multi" ? h.map(o, (V) => [...V]) : x === "range" ? h.map(d, (V) => [V[0], V[1]]) : h.map(l ?? 0, (V) => [V]), S = H(null);
|
|
4046
|
+
function v(V) {
|
|
4046
4047
|
if (x === "multi")
|
|
4047
|
-
f?.(
|
|
4048
|
+
f?.(V);
|
|
4048
4049
|
else if (x === "range") {
|
|
4049
|
-
const N = [
|
|
4050
|
+
const N = [V[0], V[1]];
|
|
4050
4051
|
N[0] > N[1] && N.reverse(), g?.(N);
|
|
4051
4052
|
} else
|
|
4052
|
-
c?.(
|
|
4053
|
+
c?.(V[0]);
|
|
4053
4054
|
}
|
|
4054
|
-
function
|
|
4055
|
-
const ie =
|
|
4055
|
+
function T(V, N, q) {
|
|
4056
|
+
const ie = V.getBoundingClientRect(), O = Ze((N - ie.left) / ie.width, 0, 1), A = e + O * (t - e), F = Ze(Ja(A, e, n), e, t), W = h.get(y);
|
|
4056
4057
|
if (q != null) {
|
|
4057
4058
|
const Z = [...W];
|
|
4058
|
-
Z[q] = F,
|
|
4059
|
+
Z[q] = F, v(Z);
|
|
4059
4060
|
} else {
|
|
4060
4061
|
let Z = 0, J = Math.abs(W[0] - F);
|
|
4061
4062
|
for (let ue = 1; ue < W.length; ue++) {
|
|
@@ -4063,14 +4064,14 @@ function oo({
|
|
|
4063
4064
|
fe < J && (Z = ue, J = fe);
|
|
4064
4065
|
}
|
|
4065
4066
|
const ce = [...W];
|
|
4066
|
-
ce[Z] = F, S.set(Z),
|
|
4067
|
+
ce[Z] = F, S.set(Z), v(ce);
|
|
4067
4068
|
}
|
|
4068
4069
|
}
|
|
4069
|
-
function E(
|
|
4070
|
-
return h.map(
|
|
4070
|
+
function E(V) {
|
|
4071
|
+
return h.map(y, (N) => N[V] ?? e);
|
|
4071
4072
|
}
|
|
4072
|
-
function
|
|
4073
|
-
const q = E(
|
|
4073
|
+
function U(V, N) {
|
|
4074
|
+
const q = E(V), ie = h.map(
|
|
4074
4075
|
q,
|
|
4075
4076
|
(O) => `${$e(O, e, t)}%`
|
|
4076
4077
|
);
|
|
@@ -4078,13 +4079,13 @@ function oo({
|
|
|
4078
4079
|
a.class("bc-advanced-slider__thumb-container"),
|
|
4079
4080
|
D.left(ie),
|
|
4080
4081
|
// Value label
|
|
4081
|
-
|
|
4082
|
+
B(
|
|
4082
4083
|
p,
|
|
4083
4084
|
() => i.div(
|
|
4084
4085
|
a.class("bc-advanced-slider__value-label"),
|
|
4085
4086
|
h.map(q, (O) => _(O))
|
|
4086
4087
|
),
|
|
4087
|
-
() =>
|
|
4088
|
+
() => j
|
|
4088
4089
|
),
|
|
4089
4090
|
i.div(
|
|
4090
4091
|
a.class(
|
|
@@ -4092,13 +4093,13 @@ function oo({
|
|
|
4092
4093
|
),
|
|
4093
4094
|
a.role("slider"),
|
|
4094
4095
|
a.tabindex(0),
|
|
4095
|
-
|
|
4096
|
-
|
|
4097
|
-
|
|
4098
|
-
|
|
4096
|
+
L.valuemin(e),
|
|
4097
|
+
L.valuemax(t),
|
|
4098
|
+
L.valuenow(q),
|
|
4099
|
+
L.label(`Thumb ${V + 1}`),
|
|
4099
4100
|
I.keydown((O) => {
|
|
4100
4101
|
if (h.get(s)) return;
|
|
4101
|
-
const A = h.get(
|
|
4102
|
+
const A = h.get(y), F = A[V];
|
|
4102
4103
|
let W;
|
|
4103
4104
|
switch (O.key) {
|
|
4104
4105
|
case "ArrowRight":
|
|
@@ -4119,33 +4120,33 @@ function oo({
|
|
|
4119
4120
|
return;
|
|
4120
4121
|
}
|
|
4121
4122
|
const Z = [...A];
|
|
4122
|
-
Z[
|
|
4123
|
+
Z[V] = W, v(Z);
|
|
4123
4124
|
}),
|
|
4124
4125
|
I.pointerdown((O) => {
|
|
4125
4126
|
if (O.stopPropagation(), O.preventDefault(), h.get(s)) return;
|
|
4126
|
-
S.set(
|
|
4127
|
+
S.set(V);
|
|
4127
4128
|
const A = (W) => {
|
|
4128
|
-
|
|
4129
|
+
T(N, W.clientX, V);
|
|
4129
4130
|
}, F = () => {
|
|
4130
4131
|
S.set(null), window.removeEventListener("pointermove", A), window.removeEventListener("pointerup", F);
|
|
4131
4132
|
};
|
|
4132
4133
|
window.addEventListener("pointermove", A), window.addEventListener("pointerup", F);
|
|
4133
4134
|
}),
|
|
4134
|
-
w ? w(
|
|
4135
|
+
w ? w(V, q) : j
|
|
4135
4136
|
)
|
|
4136
4137
|
);
|
|
4137
4138
|
}
|
|
4138
|
-
return re((
|
|
4139
|
+
return re((V) => {
|
|
4139
4140
|
const N = (A) => {
|
|
4140
4141
|
if (h.get(s)) return;
|
|
4141
|
-
A.preventDefault(),
|
|
4142
|
+
A.preventDefault(), T(V, A.clientX, null);
|
|
4142
4143
|
const F = (Z) => {
|
|
4143
|
-
|
|
4144
|
+
T(V, Z.clientX, S.value);
|
|
4144
4145
|
}, W = () => {
|
|
4145
4146
|
S.set(null), window.removeEventListener("pointermove", F), window.removeEventListener("pointerup", W);
|
|
4146
4147
|
};
|
|
4147
4148
|
window.addEventListener("pointermove", F), window.addEventListener("pointerup", W);
|
|
4148
|
-
}, q = m != null && (x === "range" || x === "multi"), ie = q ? "" : k(
|
|
4149
|
+
}, q = m != null && (x === "range" || x === "multi"), ie = q ? "" : k(y)((A) => {
|
|
4149
4150
|
if (x === "range" && A.length === 2) {
|
|
4150
4151
|
const W = $e(Math.min(A[0], A[1]), e, t), Z = $e(Math.max(A[0], A[1]), e, t);
|
|
4151
4152
|
return `left: ${W}%; width: ${Z - W}%`;
|
|
@@ -4156,20 +4157,20 @@ function oo({
|
|
|
4156
4157
|
}
|
|
4157
4158
|
return `left: 0%; width: ${$e(A[0] ?? e, e, t)}%`;
|
|
4158
4159
|
}), O = Array.from(
|
|
4159
|
-
{ length:
|
|
4160
|
-
(A, F) =>
|
|
4160
|
+
{ length: C },
|
|
4161
|
+
(A, F) => U(F, V)
|
|
4161
4162
|
);
|
|
4162
4163
|
return Q(
|
|
4163
4164
|
a.class(k(r, s)(Ka)),
|
|
4164
4165
|
a.style(h.map(u, Xa)),
|
|
4165
4166
|
a.role("group"),
|
|
4166
|
-
|
|
4167
|
+
L.label("Slider"),
|
|
4167
4168
|
I.pointerdown(N),
|
|
4168
4169
|
// Track
|
|
4169
4170
|
i.div(
|
|
4170
4171
|
a.class("bc-advanced-slider__track"),
|
|
4171
4172
|
// Filled portion - either single fill or multiple segments
|
|
4172
|
-
q ? Mn(
|
|
4173
|
+
q ? Mn(y, (A) => {
|
|
4173
4174
|
const F = [...A].sort((Z, J) => Z - J), W = [];
|
|
4174
4175
|
for (let Z = 0; Z < F.length - 1; Z++) {
|
|
4175
4176
|
const J = F[Z], ce = F[Z + 1], ue = $e(J, e, t), fe = $e(ce, e, t), Te = m[Z] ?? h.get(u) ?? "primary";
|
|
@@ -4193,9 +4194,9 @@ function oo({
|
|
|
4193
4194
|
a.style(ie)
|
|
4194
4195
|
),
|
|
4195
4196
|
// Tick marks
|
|
4196
|
-
|
|
4197
|
+
$.length > 0 ? i.div(
|
|
4197
4198
|
a.class("bc-advanced-slider__ticks"),
|
|
4198
|
-
|
|
4199
|
+
...$.map((A) => {
|
|
4199
4200
|
const F = $e(A.value, e, t);
|
|
4200
4201
|
return i.div(
|
|
4201
4202
|
a.class("bc-advanced-slider__tick"),
|
|
@@ -4203,10 +4204,10 @@ function oo({
|
|
|
4203
4204
|
A.label != null ? i.span(
|
|
4204
4205
|
a.class("bc-advanced-slider__tick-label"),
|
|
4205
4206
|
A.label
|
|
4206
|
-
) :
|
|
4207
|
+
) : j
|
|
4207
4208
|
);
|
|
4208
4209
|
})
|
|
4209
|
-
) :
|
|
4210
|
+
) : j,
|
|
4210
4211
|
...O
|
|
4211
4212
|
)
|
|
4212
4213
|
);
|
|
@@ -4238,56 +4239,56 @@ function lo({
|
|
|
4238
4239
|
} = {}) {
|
|
4239
4240
|
const f = me("otp"), b = H(
|
|
4240
4241
|
(() => {
|
|
4241
|
-
const
|
|
4242
|
-
for (let
|
|
4243
|
-
S[
|
|
4242
|
+
const y = h.get(t), S = new Array(e).fill("");
|
|
4243
|
+
for (let v = 0; v < Math.min(y.length, e); v++)
|
|
4244
|
+
S[v] = y[v];
|
|
4244
4245
|
return S;
|
|
4245
4246
|
})()
|
|
4246
4247
|
), p = H(null), _ = [];
|
|
4247
|
-
function m(
|
|
4248
|
-
const S = _[
|
|
4248
|
+
function m(y) {
|
|
4249
|
+
const S = _[y];
|
|
4249
4250
|
S != null && (S.focus(), S.select());
|
|
4250
4251
|
}
|
|
4251
4252
|
function w() {
|
|
4252
|
-
const
|
|
4253
|
-
n?.(
|
|
4253
|
+
const y = b.value.join("");
|
|
4254
|
+
n?.(y), y.length === e && y.split("").every((S) => S !== "") && s?.(y);
|
|
4254
4255
|
}
|
|
4255
|
-
function x(
|
|
4256
|
+
function x(y, S) {
|
|
4256
4257
|
if (h.get(r)) return;
|
|
4257
|
-
const
|
|
4258
|
-
if (
|
|
4259
|
-
const
|
|
4260
|
-
for (let
|
|
4261
|
-
|
|
4262
|
-
b.set(
|
|
4263
|
-
const E = Math.min(
|
|
4258
|
+
const v = S.split("").filter((T) => ts(T, l));
|
|
4259
|
+
if (v.length > 1) {
|
|
4260
|
+
const T = [...b.value];
|
|
4261
|
+
for (let U = 0; U < v.length && y + U < e; U++)
|
|
4262
|
+
T[y + U] = v[U];
|
|
4263
|
+
b.set(T), w();
|
|
4264
|
+
const E = Math.min(y + v.length, e - 1);
|
|
4264
4265
|
m(E);
|
|
4265
4266
|
return;
|
|
4266
4267
|
}
|
|
4267
|
-
if (
|
|
4268
|
-
const
|
|
4269
|
-
|
|
4268
|
+
if (v.length === 1) {
|
|
4269
|
+
const T = [...b.value];
|
|
4270
|
+
T[y] = v[0], b.set(T), w(), y < e - 1 && m(y + 1);
|
|
4270
4271
|
}
|
|
4271
4272
|
}
|
|
4272
|
-
function
|
|
4273
|
+
function C(y, S) {
|
|
4273
4274
|
if (!h.get(r))
|
|
4274
4275
|
switch (S.key) {
|
|
4275
4276
|
case "Backspace": {
|
|
4276
4277
|
S.preventDefault();
|
|
4277
|
-
const
|
|
4278
|
-
y
|
|
4278
|
+
const v = [...b.value];
|
|
4279
|
+
v[y] !== "" ? (v[y] = "", b.set(v), w()) : y > 0 && (v[y - 1] = "", b.set(v), w(), m(y - 1));
|
|
4279
4280
|
break;
|
|
4280
4281
|
}
|
|
4281
4282
|
case "ArrowLeft":
|
|
4282
|
-
S.preventDefault(),
|
|
4283
|
+
S.preventDefault(), y > 0 && m(y - 1);
|
|
4283
4284
|
break;
|
|
4284
4285
|
case "ArrowRight":
|
|
4285
|
-
S.preventDefault(),
|
|
4286
|
+
S.preventDefault(), y < e - 1 && m(y + 1);
|
|
4286
4287
|
break;
|
|
4287
4288
|
case "Delete": {
|
|
4288
4289
|
S.preventDefault();
|
|
4289
|
-
const
|
|
4290
|
-
y
|
|
4290
|
+
const v = [...b.value];
|
|
4291
|
+
v[y] = "", b.set(v), w();
|
|
4291
4292
|
break;
|
|
4292
4293
|
}
|
|
4293
4294
|
case "Home":
|
|
@@ -4298,21 +4299,21 @@ function lo({
|
|
|
4298
4299
|
break;
|
|
4299
4300
|
}
|
|
4300
4301
|
}
|
|
4301
|
-
function
|
|
4302
|
+
function $(y, S) {
|
|
4302
4303
|
S.preventDefault();
|
|
4303
|
-
const
|
|
4304
|
-
x(
|
|
4304
|
+
const v = S.clipboardData?.getData("text") ?? "";
|
|
4305
|
+
x(y, v);
|
|
4305
4306
|
}
|
|
4306
4307
|
return i.div(
|
|
4307
4308
|
a.class(k(c, r)(Qa)),
|
|
4308
4309
|
a.style(h.map(d, es)),
|
|
4309
4310
|
a.role("group"),
|
|
4310
|
-
|
|
4311
|
-
...Array.from({ length: e }, (
|
|
4312
|
-
const
|
|
4311
|
+
L.label("One-time password input"),
|
|
4312
|
+
...Array.from({ length: e }, (y, S) => {
|
|
4313
|
+
const v = `${f}-cell-${S}`;
|
|
4313
4314
|
return i.input(
|
|
4314
|
-
re((
|
|
4315
|
-
a.id(
|
|
4315
|
+
re((T) => (_[S] = T, g && S === 0 && requestAnimationFrame(() => T.focus()), j)),
|
|
4316
|
+
a.id(v),
|
|
4316
4317
|
a.type(u ? "password" : "text"),
|
|
4317
4318
|
a.inputmode(l === "numeric" ? "numeric" : "text"),
|
|
4318
4319
|
a.maxlength(1),
|
|
@@ -4320,27 +4321,27 @@ function lo({
|
|
|
4320
4321
|
a.class("bc-otp-input__cell"),
|
|
4321
4322
|
a.class(
|
|
4322
4323
|
p.map(
|
|
4323
|
-
(
|
|
4324
|
+
(T) => T === S ? "bc-otp-input__cell--focused" : ""
|
|
4324
4325
|
)
|
|
4325
4326
|
),
|
|
4326
4327
|
a.placeholder(o),
|
|
4327
4328
|
a.disabled(r),
|
|
4328
|
-
|
|
4329
|
-
a.value(b.map((
|
|
4329
|
+
L.label(`Digit ${S + 1} of ${e}`),
|
|
4330
|
+
a.value(b.map((T) => T[S] ?? "")),
|
|
4330
4331
|
I.focus(() => {
|
|
4331
4332
|
p.set(S);
|
|
4332
|
-
const
|
|
4333
|
-
|
|
4333
|
+
const T = _[S];
|
|
4334
|
+
T?.select();
|
|
4334
4335
|
}),
|
|
4335
4336
|
I.blur(() => {
|
|
4336
4337
|
p.set(null);
|
|
4337
4338
|
}),
|
|
4338
|
-
I.input((
|
|
4339
|
-
const E =
|
|
4339
|
+
I.input((T) => {
|
|
4340
|
+
const E = T.target;
|
|
4340
4341
|
x(S, E.value), E.value = b.value[S] ?? "";
|
|
4341
4342
|
}),
|
|
4342
|
-
I.keydown((
|
|
4343
|
-
I.paste((
|
|
4343
|
+
I.keydown((T) => C(S, T)),
|
|
4344
|
+
I.paste((T) => $(S, T))
|
|
4344
4345
|
);
|
|
4345
4346
|
})
|
|
4346
4347
|
);
|
|
@@ -4359,12 +4360,12 @@ const ns = (e) => {
|
|
|
4359
4360
|
h.map(t, (u) => ns(Number(u.epochMilliseconds)))
|
|
4360
4361
|
),
|
|
4361
4362
|
a.class("bc-input"),
|
|
4362
|
-
n != null ? I.blur(de(n)) :
|
|
4363
|
+
n != null ? I.blur(de(n)) : j,
|
|
4363
4364
|
s != null ? I.change(
|
|
4364
4365
|
de(
|
|
4365
4366
|
(u) => s(r.Instant.from(new Date(u).toISOString()))
|
|
4366
4367
|
)
|
|
4367
|
-
) :
|
|
4368
|
+
) : j
|
|
4368
4369
|
)
|
|
4369
4370
|
})
|
|
4370
4371
|
);
|
|
@@ -4385,17 +4386,17 @@ const ns = (e) => {
|
|
|
4385
4386
|
)
|
|
4386
4387
|
),
|
|
4387
4388
|
a.class("bc-input"),
|
|
4388
|
-
n != null ? I.blur(de(n)) :
|
|
4389
|
+
n != null ? I.blur(de(n)) : j,
|
|
4389
4390
|
s != null ? I.change(
|
|
4390
4391
|
de(
|
|
4391
4392
|
(o) => s(o === "" ? null : d.Instant.from(new Date(o).toISOString()))
|
|
4392
4393
|
)
|
|
4393
|
-
) :
|
|
4394
|
+
) : j,
|
|
4394
4395
|
r != null ? I.input(
|
|
4395
4396
|
de(
|
|
4396
4397
|
(o) => r(o === "" ? null : d.Instant.from(new Date(o).toISOString()))
|
|
4397
4398
|
)
|
|
4398
|
-
) :
|
|
4399
|
+
) : j
|
|
4399
4400
|
),
|
|
4400
4401
|
after: u != null ? Q(c, u) : c
|
|
4401
4402
|
})
|
|
@@ -4409,13 +4410,13 @@ const ns = (e) => {
|
|
|
4409
4410
|
Ie(e),
|
|
4410
4411
|
a.value(h.map(t, (u) => u.toJSON())),
|
|
4411
4412
|
a.class("bc-input"),
|
|
4412
|
-
n != null ? I.blur(de(n)) :
|
|
4413
|
+
n != null ? I.blur(de(n)) : j,
|
|
4413
4414
|
s != null ? I.change(
|
|
4414
4415
|
de((u) => {
|
|
4415
4416
|
const l = r.PlainDateTime.from(u), c = h.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
4416
4417
|
return s(r.ZonedDateTime.from({ ...l, timeZone: c }));
|
|
4417
4418
|
})
|
|
4418
|
-
) :
|
|
4419
|
+
) : j
|
|
4419
4420
|
)
|
|
4420
4421
|
})
|
|
4421
4422
|
);
|
|
@@ -4428,21 +4429,21 @@ const ns = (e) => {
|
|
|
4428
4429
|
Ie(e),
|
|
4429
4430
|
a.value(h.map(t, (o) => o?.toJSON())),
|
|
4430
4431
|
a.class("bc-input"),
|
|
4431
|
-
n != null ? I.blur(de(n)) :
|
|
4432
|
+
n != null ? I.blur(de(n)) : j,
|
|
4432
4433
|
s != null ? I.change(
|
|
4433
4434
|
de((o) => {
|
|
4434
4435
|
if (o === "") return s(null);
|
|
4435
4436
|
const g = d.PlainDateTime.from(o), f = h.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
4436
4437
|
return s(d.ZonedDateTime.from({ ...g, timeZone: f }));
|
|
4437
4438
|
})
|
|
4438
|
-
) :
|
|
4439
|
+
) : j,
|
|
4439
4440
|
r != null ? I.input(
|
|
4440
4441
|
de((o) => {
|
|
4441
4442
|
if (o === "") return r(null);
|
|
4442
4443
|
const g = d.PlainDateTime.from(o), f = h.get(e.placeholder) ?? Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
4443
4444
|
return r(d.ZonedDateTime.from({ ...g, timeZone: f }));
|
|
4444
4445
|
})
|
|
4445
|
-
) :
|
|
4446
|
+
) : j
|
|
4446
4447
|
),
|
|
4447
4448
|
after: u != null ? Q(c, u) : c
|
|
4448
4449
|
})
|
|
@@ -4715,9 +4716,9 @@ function is({
|
|
|
4715
4716
|
(f, b) => ls(f, b)
|
|
4716
4717
|
)
|
|
4717
4718
|
),
|
|
4718
|
-
|
|
4719
|
-
|
|
4720
|
-
|
|
4719
|
+
L.live("polite"),
|
|
4720
|
+
L.busy(e),
|
|
4721
|
+
B(
|
|
4721
4722
|
e,
|
|
4722
4723
|
() => i.div(
|
|
4723
4724
|
a.class("bc-notification__visual bc-notification__loader"),
|
|
@@ -4728,7 +4729,7 @@ function is({
|
|
|
4728
4729
|
accessibility: "decorative"
|
|
4729
4730
|
})
|
|
4730
4731
|
),
|
|
4731
|
-
() =>
|
|
4732
|
+
() => B(
|
|
4732
4733
|
g,
|
|
4733
4734
|
() => i.div(
|
|
4734
4735
|
a.class("bc-notification__visual bc-notification__icon"),
|
|
@@ -4739,7 +4740,7 @@ function is({
|
|
|
4739
4740
|
),
|
|
4740
4741
|
() => i.div(
|
|
4741
4742
|
a.class("bc-notification__visual bc-notification__accent"),
|
|
4742
|
-
|
|
4743
|
+
L.hidden(!0)
|
|
4743
4744
|
)
|
|
4744
4745
|
)
|
|
4745
4746
|
),
|
|
@@ -4748,7 +4749,7 @@ function is({
|
|
|
4748
4749
|
u != null ? i.div(a.class("bc-notification__title"), u) : null,
|
|
4749
4750
|
i.div(a.class("bc-notification__content"), ...o)
|
|
4750
4751
|
),
|
|
4751
|
-
|
|
4752
|
+
B(
|
|
4752
4753
|
t,
|
|
4753
4754
|
() => i.div(
|
|
4754
4755
|
a.class("bc-notification__meta"),
|
|
@@ -4807,7 +4808,7 @@ const us = new cs(), Sn = {
|
|
|
4807
4808
|
withBorder: h.toSignal(f.withBorder ?? !1),
|
|
4808
4809
|
color: h.toSignal(f.color ?? "primary"),
|
|
4809
4810
|
radius: h.toSignal(f.radius ?? "md"),
|
|
4810
|
-
title: f.title ??
|
|
4811
|
+
title: f.title ?? j,
|
|
4811
4812
|
icon: h.toSignal(f.icon),
|
|
4812
4813
|
children: b,
|
|
4813
4814
|
listenRequestClose: (m) => (r.push(m), o?.(), () => {
|
|
@@ -4883,9 +4884,9 @@ function ko({
|
|
|
4883
4884
|
appearancePreferenceKey: s
|
|
4884
4885
|
}), r && c(Sn, { position: u }), Fn.attach(d(Ye));
|
|
4885
4886
|
const o = Q(
|
|
4886
|
-
t ? Hn() :
|
|
4887
|
+
t ? Hn() : j,
|
|
4887
4888
|
rs(),
|
|
4888
|
-
r ? ds() :
|
|
4889
|
+
r ? ds() : j,
|
|
4889
4890
|
...l
|
|
4890
4891
|
);
|
|
4891
4892
|
return e ? Nn(
|
|
@@ -4925,8 +4926,8 @@ function xo({
|
|
|
4925
4926
|
new Blob([new Uint8Array(m)], { type: "application/pdf" })
|
|
4926
4927
|
);
|
|
4927
4928
|
if (typeof m == "string") {
|
|
4928
|
-
const x = await (await fetch(m)).arrayBuffer(),
|
|
4929
|
-
return URL.createObjectURL(
|
|
4929
|
+
const x = await (await fetch(m)).arrayBuffer(), C = new Blob([x], { type: "application/pdf" });
|
|
4930
|
+
return URL.createObjectURL(C);
|
|
4930
4931
|
}
|
|
4931
4932
|
}
|
|
4932
4933
|
}, null), _ = k(
|
|
@@ -4942,10 +4943,10 @@ function xo({
|
|
|
4942
4943
|
o,
|
|
4943
4944
|
g,
|
|
4944
4945
|
f
|
|
4945
|
-
)((m, w, x,
|
|
4946
|
+
)((m, w, x, C, $, y, S, v, T, E, U, V) => {
|
|
4946
4947
|
if (m == null) return null;
|
|
4947
4948
|
const N = [];
|
|
4948
|
-
w === !1 && N.push("toolbar=0"), x != null && x > 0 && N.push(`page=${x}`),
|
|
4949
|
+
w === !1 && N.push("toolbar=0"), x != null && x > 0 && N.push(`page=${x}`), C != null && C > 0 && N.push(`zoom=${C}`), $ != null && N.push(`view=${$}`), y != null && N.push(`pagemode=${y}`), S === !1 && N.push("scrollbar=0"), v === !1 && N.push("navpanes=0"), T != null && N.push(`search=${encodeURIComponent(T)}`), E != null && N.push(`nameddest=${encodeURIComponent(E)}`), U != null && N.push(`viewrect=${encodeURIComponent(U)}`), V != null && N.push(`highlight=${encodeURIComponent(V)}`);
|
|
4949
4950
|
const q = N.join("&");
|
|
4950
4951
|
return q ? `${m}#${q}` : m;
|
|
4951
4952
|
});
|
|
@@ -4969,12 +4970,12 @@ function xo({
|
|
|
4969
4970
|
// by manually updating src instead of using attr.src
|
|
4970
4971
|
re((w) => {
|
|
4971
4972
|
const x = w;
|
|
4972
|
-
let
|
|
4973
|
-
return _.on((
|
|
4974
|
-
|
|
4975
|
-
x.src =
|
|
4973
|
+
let C = !0;
|
|
4974
|
+
return _.on(($) => {
|
|
4975
|
+
$ != null && (C ? (x.src = $, C = !1) : (x.src = "about:blank", setTimeout(() => {
|
|
4976
|
+
x.src = $;
|
|
4976
4977
|
}, 50)));
|
|
4977
|
-
}),
|
|
4978
|
+
}), j;
|
|
4978
4979
|
})
|
|
4979
4980
|
)
|
|
4980
4981
|
)
|
|
@@ -5026,23 +5027,23 @@ function Co({
|
|
|
5026
5027
|
o,
|
|
5027
5028
|
g,
|
|
5028
5029
|
f
|
|
5029
|
-
)((x,
|
|
5030
|
+
)((x, C, $, y, S, v, T, E, U, V, N, q, ie) => {
|
|
5030
5031
|
if (x == null) return null;
|
|
5031
|
-
const O =
|
|
5032
|
+
const O = C ?? "https://mozilla.github.io/pdf.js/web/viewer.html", A = new URLSearchParams();
|
|
5032
5033
|
A.set("file", x);
|
|
5033
5034
|
const F = [];
|
|
5034
|
-
|
|
5035
|
+
$ != null && $ > 0 && F.push(`page=${$}`), y != null && (typeof y == "string" ? F.push(`zoom=${y}`) : F.push(`zoom=${y}`)), S != null && F.push(`pagemode=${S}`), v != null && F.push(`nameddest=${encodeURIComponent(v)}`), T != null && F.push(`search=${encodeURIComponent(T)}`), E != null && F.push(`textLayer=${E}`), U != null && F.push(`sidebar=${U}`), V != null && F.push(`scrollMode=${V}`), N != null && F.push(`spreadMode=${N}`), q != null && F.push(`enableScripting=${q ? "1" : "0"}`), ie != null && F.push(`enablePrinting=${ie ? "1" : "0"}`);
|
|
5035
5036
|
const W = F.length > 0 ? `#${F.join("&")}` : "";
|
|
5036
5037
|
return `${O}?${A.toString()}${W}`;
|
|
5037
5038
|
});
|
|
5038
|
-
return m.on((x,
|
|
5039
|
-
|
|
5039
|
+
return m.on((x, C) => {
|
|
5040
|
+
C != null && C.startsWith("blob:") && URL.revokeObjectURL(C);
|
|
5040
5041
|
}), ne(
|
|
5041
5042
|
le,
|
|
5042
5043
|
(x) => i.div(
|
|
5043
5044
|
ge(() => {
|
|
5044
|
-
const
|
|
5045
|
-
|
|
5045
|
+
const C = m.value;
|
|
5046
|
+
C != null && C.startsWith("blob:") && URL.revokeObjectURL(C);
|
|
5046
5047
|
}),
|
|
5047
5048
|
a.class("bc-pdfjs-preview h-full w-full"),
|
|
5048
5049
|
a.class(_),
|
|
@@ -5094,7 +5095,7 @@ function $o({
|
|
|
5094
5095
|
n,
|
|
5095
5096
|
(l) => i.p(a.class("bc-empty-state__description"), l)
|
|
5096
5097
|
),
|
|
5097
|
-
r != null ? i.div(a.class("bc-empty-state__action"), r) :
|
|
5098
|
+
r != null ? i.div(a.class("bc-empty-state__action"), r) : j
|
|
5098
5099
|
);
|
|
5099
5100
|
}
|
|
5100
5101
|
const So = ({ id: e, css: t }) => bt("head", i.style(a.id(e), a.innerHTML(t)));
|
|
@@ -5114,7 +5115,7 @@ function Xe(e, t) {
|
|
|
5114
5115
|
return t == null ? null : oe(t, (n) => ee(e, n));
|
|
5115
5116
|
}
|
|
5116
5117
|
function bs(e, t) {
|
|
5117
|
-
return t == null ? null :
|
|
5118
|
+
return t == null ? null : B(
|
|
5118
5119
|
h.map(t, (n) => Array.isArray(n)),
|
|
5119
5120
|
() => Xe(e, t),
|
|
5120
5121
|
() => ee(e, t)
|
|
@@ -5164,7 +5165,7 @@ function Io(e) {
|
|
|
5164
5165
|
i.div(
|
|
5165
5166
|
a.class("bc-notification-panel__header-title"),
|
|
5166
5167
|
i.span(u.$.notifications),
|
|
5167
|
-
|
|
5168
|
+
B(
|
|
5168
5169
|
k(r)((l) => l > 0),
|
|
5169
5170
|
() => dt(
|
|
5170
5171
|
{ color: "primary", size: "xs", circle: !0 },
|
|
@@ -5179,13 +5180,13 @@ function Io(e) {
|
|
|
5179
5180
|
a.type("button"),
|
|
5180
5181
|
I.click(() => n()),
|
|
5181
5182
|
u.$.markAllAsRead
|
|
5182
|
-
) :
|
|
5183
|
+
) : j,
|
|
5183
5184
|
s ? i.button(
|
|
5184
5185
|
a.class("bc-notification-panel__close-btn"),
|
|
5185
5186
|
a.type("button"),
|
|
5186
5187
|
I.click(() => s()),
|
|
5187
5188
|
K({ icon: "lucide:x", size: "sm" })
|
|
5188
|
-
) :
|
|
5189
|
+
) : j
|
|
5189
5190
|
)
|
|
5190
5191
|
),
|
|
5191
5192
|
// List
|
|
@@ -5222,7 +5223,7 @@ function Io(e) {
|
|
|
5222
5223
|
i.div(
|
|
5223
5224
|
a.class("bc-notification-panel__item-meta"),
|
|
5224
5225
|
i.span(l.$.time),
|
|
5225
|
-
|
|
5226
|
+
B(
|
|
5226
5227
|
l.map((c) => c.source !== void 0),
|
|
5227
5228
|
() => i.span(
|
|
5228
5229
|
a.class("bc-notification-panel__item-source"),
|
|
@@ -5232,13 +5233,13 @@ function Io(e) {
|
|
|
5232
5233
|
)
|
|
5233
5234
|
),
|
|
5234
5235
|
// Unread dot
|
|
5235
|
-
|
|
5236
|
+
B(
|
|
5236
5237
|
l.map((c) => !c.read),
|
|
5237
5238
|
() => i.span(a.class("bc-notification-panel__item-dot"))
|
|
5238
5239
|
)
|
|
5239
5240
|
)),
|
|
5240
5241
|
// Empty state
|
|
5241
|
-
|
|
5242
|
+
B(
|
|
5242
5243
|
k(t)((l) => l.length === 0),
|
|
5243
5244
|
() => i.div(
|
|
5244
5245
|
a.class("bc-notification-panel__empty"),
|
|
@@ -5273,7 +5274,7 @@ function To({
|
|
|
5273
5274
|
le,
|
|
5274
5275
|
(u) => i.nav(
|
|
5275
5276
|
a.class(h.map(s, (l) => fs(l ?? "md"))),
|
|
5276
|
-
|
|
5277
|
+
L.label(u.$.breadcrumbs),
|
|
5277
5278
|
i.ol(
|
|
5278
5279
|
a.class("bc-breadcrumbs__list"),
|
|
5279
5280
|
oe(
|
|
@@ -5284,11 +5285,11 @@ function To({
|
|
|
5284
5285
|
), d = l.map(
|
|
5285
5286
|
(o) => !("isEllipsis" in o) && o.current === !0
|
|
5286
5287
|
);
|
|
5287
|
-
return
|
|
5288
|
+
return B(
|
|
5288
5289
|
c,
|
|
5289
5290
|
() => i.li(
|
|
5290
5291
|
a.class("bc-breadcrumbs__item bc-breadcrumbs__ellipsis"),
|
|
5291
|
-
|
|
5292
|
+
L.hidden(!0),
|
|
5292
5293
|
"..."
|
|
5293
5294
|
),
|
|
5294
5295
|
() => {
|
|
@@ -5300,7 +5301,7 @@ function To({
|
|
|
5300
5301
|
(p) => !("isEllipsis" in p) && p.icon != null
|
|
5301
5302
|
), b = (p) => [
|
|
5302
5303
|
a.class(p),
|
|
5303
|
-
|
|
5304
|
+
B(
|
|
5304
5305
|
f,
|
|
5305
5306
|
() => K({
|
|
5306
5307
|
icon: l.map(
|
|
@@ -5321,9 +5322,9 @@ function To({
|
|
|
5321
5322
|
(p) => p ? "bc-breadcrumbs__item bc-breadcrumbs__item--current" : "bc-breadcrumbs__item"
|
|
5322
5323
|
)
|
|
5323
5324
|
),
|
|
5324
|
-
|
|
5325
|
+
B(d, () => L.current("page")),
|
|
5325
5326
|
// Render as link, button, or span based on item properties
|
|
5326
|
-
|
|
5327
|
+
B(
|
|
5327
5328
|
o,
|
|
5328
5329
|
() => i.a(
|
|
5329
5330
|
a.href(
|
|
@@ -5333,7 +5334,7 @@ function To({
|
|
|
5333
5334
|
),
|
|
5334
5335
|
...b("bc-breadcrumbs__link")
|
|
5335
5336
|
),
|
|
5336
|
-
() =>
|
|
5337
|
+
() => B(
|
|
5337
5338
|
g,
|
|
5338
5339
|
() => i.button(
|
|
5339
5340
|
a.type("button"),
|
|
@@ -5353,7 +5354,7 @@ function To({
|
|
|
5353
5354
|
// Native separator between items
|
|
5354
5355
|
() => i.li(
|
|
5355
5356
|
a.class("bc-breadcrumbs__separator"),
|
|
5356
|
-
|
|
5357
|
+
L.hidden(!0),
|
|
5357
5358
|
t
|
|
5358
5359
|
)
|
|
5359
5360
|
)
|
|
@@ -5410,7 +5411,7 @@ function hs({
|
|
|
5410
5411
|
target: o,
|
|
5411
5412
|
rel: g
|
|
5412
5413
|
}, ...f) {
|
|
5413
|
-
return
|
|
5414
|
+
return B(
|
|
5414
5415
|
r,
|
|
5415
5416
|
() => i.span(
|
|
5416
5417
|
a.class(
|
|
@@ -5533,10 +5534,10 @@ function Po({
|
|
|
5533
5534
|
const w = c !== void 0 ? m.matchSignal(Ct(e, c)) : k(m.location)(() => !1), x = k(
|
|
5534
5535
|
w,
|
|
5535
5536
|
d
|
|
5536
|
-
)((
|
|
5537
|
+
)(($, y) => !(y ?? !0) || !c ? !1 : $), C = k(
|
|
5537
5538
|
p,
|
|
5538
5539
|
x
|
|
5539
|
-
)((
|
|
5540
|
+
)(($, y) => $ || y);
|
|
5540
5541
|
return Ut(
|
|
5541
5542
|
{
|
|
5542
5543
|
href: e,
|
|
@@ -5550,7 +5551,7 @@ function Po({
|
|
|
5550
5551
|
size: g,
|
|
5551
5552
|
color: f,
|
|
5552
5553
|
roundedness: b,
|
|
5553
|
-
disabled:
|
|
5554
|
+
disabled: C
|
|
5554
5555
|
},
|
|
5555
5556
|
..._
|
|
5556
5557
|
);
|
|
@@ -5588,7 +5589,7 @@ function Ut({
|
|
|
5588
5589
|
fullWidth: b = !1,
|
|
5589
5590
|
loading: p = !1
|
|
5590
5591
|
}, ..._) {
|
|
5591
|
-
return
|
|
5592
|
+
return B(
|
|
5592
5593
|
f ?? !1,
|
|
5593
5594
|
() => i.span(
|
|
5594
5595
|
a.class(
|
|
@@ -5686,9 +5687,9 @@ function Ao({
|
|
|
5686
5687
|
return p && _.push("bc-pagination--justify"), _.join(" ");
|
|
5687
5688
|
})
|
|
5688
5689
|
),
|
|
5689
|
-
|
|
5690
|
+
L.label(f.$.paginationLabel),
|
|
5690
5691
|
// Responsive ResizeObserver setup
|
|
5691
|
-
|
|
5692
|
+
B(
|
|
5692
5693
|
d,
|
|
5693
5694
|
() => re((b) => {
|
|
5694
5695
|
const p = () => {
|
|
@@ -5698,19 +5699,19 @@ function Ao({
|
|
|
5698
5699
|
".bc-pagination__item"
|
|
5699
5700
|
);
|
|
5700
5701
|
if (!w) return;
|
|
5701
|
-
const x = w.offsetWidth,
|
|
5702
|
-
(m +
|
|
5703
|
-
), S = (h.get(r) ? 2 : 0) + (h.get(u) ? 2 : 0),
|
|
5702
|
+
const x = w.offsetWidth, C = parseFloat(getComputedStyle(b).gap) || 0, $ = x + C, y = Math.floor(
|
|
5703
|
+
(m + C) / $
|
|
5704
|
+
), S = (h.get(r) ? 2 : 0) + (h.get(u) ? 2 : 0), v = h.get(t), T = y - S, E = Math.max(
|
|
5704
5705
|
0,
|
|
5705
|
-
Math.floor((
|
|
5706
|
-
),
|
|
5707
|
-
o.set(Math.min(E, Math.max(0,
|
|
5706
|
+
Math.floor((T - 5) / 2)
|
|
5707
|
+
), U = Math.floor((v - 3) / 2);
|
|
5708
|
+
o.set(Math.min(E, Math.max(0, U)));
|
|
5708
5709
|
}, _ = new ResizeObserver(p);
|
|
5709
5710
|
return _.observe(b), requestAnimationFrame(p), ge(() => _.disconnect());
|
|
5710
5711
|
})
|
|
5711
5712
|
),
|
|
5712
5713
|
// First page button
|
|
5713
|
-
|
|
5714
|
+
B(
|
|
5714
5715
|
u,
|
|
5715
5716
|
() => i.button(
|
|
5716
5717
|
a.class("bc-pagination__item"),
|
|
@@ -5720,7 +5721,7 @@ function Ao({
|
|
|
5720
5721
|
t
|
|
5721
5722
|
)((b, p) => b <= 1 || p <= 1)
|
|
5722
5723
|
),
|
|
5723
|
-
|
|
5724
|
+
L.label(f.$.firstPage),
|
|
5724
5725
|
I.click((b) => {
|
|
5725
5726
|
b.preventDefault(), h.get(t) > 1 && n(1);
|
|
5726
5727
|
}),
|
|
@@ -5729,7 +5730,7 @@ function Ao({
|
|
|
5729
5730
|
)
|
|
5730
5731
|
),
|
|
5731
5732
|
// Previous page button
|
|
5732
|
-
|
|
5733
|
+
B(
|
|
5733
5734
|
r,
|
|
5734
5735
|
() => i.button(
|
|
5735
5736
|
a.class("bc-pagination__item"),
|
|
@@ -5739,7 +5740,7 @@ function Ao({
|
|
|
5739
5740
|
t
|
|
5740
5741
|
)((b, p) => b <= 1 || p <= 1)
|
|
5741
5742
|
),
|
|
5742
|
-
|
|
5743
|
+
L.label(f.$.previousPage),
|
|
5743
5744
|
I.click((b) => {
|
|
5744
5745
|
b.preventDefault();
|
|
5745
5746
|
const p = h.get(e);
|
|
@@ -5763,7 +5764,7 @@ function Ao({
|
|
|
5763
5764
|
b,
|
|
5764
5765
|
e
|
|
5765
5766
|
)((m, w) => m === w);
|
|
5766
|
-
return
|
|
5767
|
+
return B(
|
|
5767
5768
|
p,
|
|
5768
5769
|
() => i.span(a.class("bc-pagination__dots"), "…"),
|
|
5769
5770
|
() => i.button(
|
|
@@ -5789,7 +5790,7 @@ function Ao({
|
|
|
5789
5790
|
}
|
|
5790
5791
|
),
|
|
5791
5792
|
// Next page button
|
|
5792
|
-
|
|
5793
|
+
B(
|
|
5793
5794
|
r,
|
|
5794
5795
|
() => i.button(
|
|
5795
5796
|
a.class("bc-pagination__item"),
|
|
@@ -5799,7 +5800,7 @@ function Ao({
|
|
|
5799
5800
|
t
|
|
5800
5801
|
)((b, p) => b >= p || p <= 1)
|
|
5801
5802
|
),
|
|
5802
|
-
|
|
5803
|
+
L.label(f.$.nextPage),
|
|
5803
5804
|
I.click((b) => {
|
|
5804
5805
|
b.preventDefault();
|
|
5805
5806
|
const p = h.get(e), _ = h.get(t);
|
|
@@ -5810,7 +5811,7 @@ function Ao({
|
|
|
5810
5811
|
)
|
|
5811
5812
|
),
|
|
5812
5813
|
// Last page button
|
|
5813
|
-
|
|
5814
|
+
B(
|
|
5814
5815
|
u,
|
|
5815
5816
|
() => i.button(
|
|
5816
5817
|
a.class("bc-pagination__item"),
|
|
@@ -5820,7 +5821,7 @@ function Ao({
|
|
|
5820
5821
|
t
|
|
5821
5822
|
)((b, p) => b >= p || p <= 1)
|
|
5822
5823
|
),
|
|
5823
|
-
|
|
5824
|
+
L.label(f.$.lastPage),
|
|
5824
5825
|
I.click((b) => {
|
|
5825
5826
|
b.preventDefault();
|
|
5826
5827
|
const p = h.get(t);
|
|
@@ -5895,14 +5896,14 @@ function Cs(e, ...t) {
|
|
|
5895
5896
|
return i.button(
|
|
5896
5897
|
a.type("button"),
|
|
5897
5898
|
I.click(e.onClick),
|
|
5898
|
-
e.ariaExpanded != null ?
|
|
5899
|
+
e.ariaExpanded != null ? L.expanded(
|
|
5899
5900
|
h.map(
|
|
5900
5901
|
e.ariaExpanded,
|
|
5901
5902
|
(n) => n
|
|
5902
5903
|
)
|
|
5903
5904
|
) : null,
|
|
5904
|
-
e.ariaControls != null ?
|
|
5905
|
-
e.ariaLabel != null ?
|
|
5905
|
+
e.ariaControls != null ? L.controls(e.ariaControls) : null,
|
|
5906
|
+
e.ariaLabel != null ? L.label(e.ariaLabel) : null,
|
|
5906
5907
|
...t
|
|
5907
5908
|
);
|
|
5908
5909
|
}
|
|
@@ -5934,7 +5935,7 @@ function $s(e) {
|
|
|
5934
5935
|
includeHash: !1
|
|
5935
5936
|
}
|
|
5936
5937
|
);
|
|
5937
|
-
return
|
|
5938
|
+
return B(
|
|
5938
5939
|
s,
|
|
5939
5940
|
() => xs(...t),
|
|
5940
5941
|
() => ks(e, ...t)
|
|
@@ -6022,41 +6023,41 @@ function Eo(e) {
|
|
|
6022
6023
|
showContent: o = !0,
|
|
6023
6024
|
ariaLabel: g
|
|
6024
6025
|
} = e, f = me("tablist"), b = H(-1), p = t.map((m, w) => {
|
|
6025
|
-
const x = k(n)((S) => S === m.key),
|
|
6026
|
+
const x = k(n)((S) => S === m.key), C = k(
|
|
6026
6027
|
c,
|
|
6027
6028
|
m.disabled
|
|
6028
|
-
)((S,
|
|
6029
|
-
return { item: m, index: w, isActive: x, isTabDisabled:
|
|
6029
|
+
)((S, v) => S || v), $ = `${f}-tab-${m.key}`, y = `${f}-panel-${m.key}`;
|
|
6030
|
+
return { item: m, index: w, isActive: x, isTabDisabled: C, tabId: $, panelId: y };
|
|
6030
6031
|
}), _ = (m) => {
|
|
6031
6032
|
if (h.get(c)) return;
|
|
6032
|
-
const x = b.value,
|
|
6033
|
-
let
|
|
6033
|
+
const x = b.value, C = h.get(d) === "horizontal";
|
|
6034
|
+
let $ = x;
|
|
6034
6035
|
switch (m.key) {
|
|
6035
|
-
case (
|
|
6036
|
-
m.preventDefault(),
|
|
6036
|
+
case (C ? "ArrowRight" : "ArrowDown"):
|
|
6037
|
+
m.preventDefault(), $ = Je(x, t, 1);
|
|
6037
6038
|
break;
|
|
6038
|
-
case (
|
|
6039
|
-
m.preventDefault(),
|
|
6039
|
+
case (C ? "ArrowLeft" : "ArrowUp"):
|
|
6040
|
+
m.preventDefault(), $ = Je(x, t, -1);
|
|
6040
6041
|
break;
|
|
6041
6042
|
case "Home":
|
|
6042
|
-
m.preventDefault(),
|
|
6043
|
+
m.preventDefault(), $ = Je(-1, t, 1);
|
|
6043
6044
|
break;
|
|
6044
6045
|
case "End":
|
|
6045
|
-
m.preventDefault(),
|
|
6046
|
+
m.preventDefault(), $ = Je(t.length, t, -1);
|
|
6046
6047
|
break;
|
|
6047
6048
|
case "Enter":
|
|
6048
6049
|
case " ":
|
|
6049
6050
|
if (m.preventDefault(), x >= 0 && x < t.length) {
|
|
6050
|
-
const
|
|
6051
|
-
h.get(
|
|
6051
|
+
const y = t[x];
|
|
6052
|
+
h.get(y.disabled ?? !1) || s?.(y.key);
|
|
6052
6053
|
}
|
|
6053
6054
|
break;
|
|
6054
6055
|
}
|
|
6055
|
-
|
|
6056
|
-
const
|
|
6057
|
-
`[data-tab-index="${
|
|
6056
|
+
$ !== x && $ >= 0 && $ < t.length && (b.set($), setTimeout(() => {
|
|
6057
|
+
const y = document.querySelector(
|
|
6058
|
+
`[data-tab-index="${$}"]`
|
|
6058
6059
|
);
|
|
6059
|
-
|
|
6060
|
+
y && y.focus();
|
|
6060
6061
|
}, 0));
|
|
6061
6062
|
};
|
|
6062
6063
|
return i.div(
|
|
@@ -6067,11 +6068,11 @@ function Eo(e) {
|
|
|
6067
6068
|
c,
|
|
6068
6069
|
u
|
|
6069
6070
|
)(
|
|
6070
|
-
(m, w, x,
|
|
6071
|
+
(m, w, x, C) => Ss(
|
|
6071
6072
|
m ?? "md",
|
|
6072
6073
|
w ?? "horizontal",
|
|
6073
6074
|
x ?? !1,
|
|
6074
|
-
|
|
6075
|
+
C ?? "default"
|
|
6075
6076
|
)
|
|
6076
6077
|
)
|
|
6077
6078
|
),
|
|
@@ -6088,41 +6089,41 @@ function Eo(e) {
|
|
|
6088
6089
|
a.class("bc-tabs__list"),
|
|
6089
6090
|
a.role("tablist"),
|
|
6090
6091
|
a.id(f),
|
|
6091
|
-
|
|
6092
|
+
L.orientation(
|
|
6092
6093
|
d ?? "horizontal"
|
|
6093
6094
|
),
|
|
6094
|
-
|
|
6095
|
+
L.label(g),
|
|
6095
6096
|
I.keydown(_),
|
|
6096
6097
|
...p.map(
|
|
6097
|
-
({ item: m, index: w, isActive: x, isTabDisabled:
|
|
6098
|
+
({ item: m, index: w, isActive: x, isTabDisabled: C, tabId: $, panelId: y }) => i.button(
|
|
6098
6099
|
a.type("button"),
|
|
6099
6100
|
a.class(
|
|
6100
6101
|
k(
|
|
6101
6102
|
r,
|
|
6102
6103
|
x,
|
|
6103
|
-
|
|
6104
|
+
C
|
|
6104
6105
|
)(
|
|
6105
|
-
(S,
|
|
6106
|
+
(S, v, T) => Is(
|
|
6106
6107
|
S ?? "md",
|
|
6107
|
-
|
|
6108
|
-
|
|
6108
|
+
v ?? !1,
|
|
6109
|
+
T ?? !1
|
|
6109
6110
|
)
|
|
6110
6111
|
)
|
|
6111
6112
|
),
|
|
6112
|
-
a.id(
|
|
6113
|
+
a.id($),
|
|
6113
6114
|
a.role("tab"),
|
|
6114
6115
|
a.tabindex(
|
|
6115
6116
|
k(
|
|
6116
6117
|
x,
|
|
6117
6118
|
b
|
|
6118
|
-
)((S,
|
|
6119
|
+
)((S, v) => S || v === w ? 0 : -1)
|
|
6119
6120
|
),
|
|
6120
|
-
|
|
6121
|
-
|
|
6122
|
-
|
|
6123
|
-
a.disabled(
|
|
6121
|
+
L.selected(x),
|
|
6122
|
+
L.controls(y),
|
|
6123
|
+
L.disabled(C),
|
|
6124
|
+
a.disabled(C),
|
|
6124
6125
|
Gt["tab-index"](String(w)),
|
|
6125
|
-
|
|
6126
|
+
L.label(m.ariaLabel),
|
|
6126
6127
|
I.click((S) => {
|
|
6127
6128
|
S.preventDefault(), h.get(m.disabled ?? !1) || h.get(c) || (s?.(m.key), b.set(w));
|
|
6128
6129
|
}),
|
|
@@ -6134,19 +6135,19 @@ function Eo(e) {
|
|
|
6134
6135
|
)
|
|
6135
6136
|
),
|
|
6136
6137
|
// Panels
|
|
6137
|
-
|
|
6138
|
+
B(
|
|
6138
6139
|
o ?? !0,
|
|
6139
6140
|
() => i.div(
|
|
6140
6141
|
a.class("bc-tabs__panels"),
|
|
6141
6142
|
...p.map(
|
|
6142
|
-
({ item: m, isActive: w, tabId: x, panelId:
|
|
6143
|
+
({ item: m, isActive: w, tabId: x, panelId: C }) => B(
|
|
6143
6144
|
w,
|
|
6144
6145
|
() => i.div(
|
|
6145
6146
|
a.class("bc-tabs__panel"),
|
|
6146
|
-
a.id(
|
|
6147
|
+
a.id(C),
|
|
6147
6148
|
a.role("tabpanel"),
|
|
6148
6149
|
a.tabindex(0),
|
|
6149
|
-
|
|
6150
|
+
L.labelledby(x),
|
|
6150
6151
|
m.content()
|
|
6151
6152
|
)
|
|
6152
6153
|
)
|
|
@@ -6189,7 +6190,7 @@ function Dn(e, t, n, s, r, u, l) {
|
|
|
6189
6190
|
a.role("treeitem"),
|
|
6190
6191
|
a.tabindex(0),
|
|
6191
6192
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
6192
|
-
|
|
6193
|
+
L.selected(o),
|
|
6193
6194
|
re((p) => {
|
|
6194
6195
|
const _ = k(
|
|
6195
6196
|
c,
|
|
@@ -6201,7 +6202,7 @@ function Dn(e, t, n, s, r, u, l) {
|
|
|
6201
6202
|
}),
|
|
6202
6203
|
I.click(f),
|
|
6203
6204
|
// Expand/collapse chevron
|
|
6204
|
-
|
|
6205
|
+
B(
|
|
6205
6206
|
c,
|
|
6206
6207
|
() => i.span(
|
|
6207
6208
|
a.class(
|
|
@@ -6223,7 +6224,7 @@ function Dn(e, t, n, s, r, u, l) {
|
|
|
6223
6224
|
() => i.span(a.class("bc-tree-item__toggle-spacer"))
|
|
6224
6225
|
),
|
|
6225
6226
|
// Icon
|
|
6226
|
-
|
|
6227
|
+
B(
|
|
6227
6228
|
e.map((p) => p.icon != null),
|
|
6228
6229
|
() => i.span(
|
|
6229
6230
|
a.class("bc-tree-item__icon"),
|
|
@@ -6233,7 +6234,7 @@ function Dn(e, t, n, s, r, u, l) {
|
|
|
6233
6234
|
accessibility: "decorative"
|
|
6234
6235
|
})
|
|
6235
6236
|
),
|
|
6236
|
-
() =>
|
|
6237
|
+
() => j
|
|
6237
6238
|
),
|
|
6238
6239
|
// Label
|
|
6239
6240
|
i.span(
|
|
@@ -6241,19 +6242,19 @@ function Dn(e, t, n, s, r, u, l) {
|
|
|
6241
6242
|
e.map((p) => p.label)
|
|
6242
6243
|
),
|
|
6243
6244
|
// Badge
|
|
6244
|
-
|
|
6245
|
+
B(
|
|
6245
6246
|
e.map((p) => p.badge != null),
|
|
6246
6247
|
() => i.span(
|
|
6247
6248
|
a.class("bc-tree-item__badge"),
|
|
6248
6249
|
e.map((p) => p.badge ?? "")
|
|
6249
6250
|
),
|
|
6250
|
-
() =>
|
|
6251
|
+
() => j
|
|
6251
6252
|
)
|
|
6252
6253
|
),
|
|
6253
6254
|
// Children (collapsible) — Collapse uses WithElement which modifies its
|
|
6254
6255
|
// parent element, so it must be wrapped in its own div to avoid hiding
|
|
6255
6256
|
// the entire tree item row when collapsed.
|
|
6256
|
-
|
|
6257
|
+
B(
|
|
6257
6258
|
c,
|
|
6258
6259
|
() => i.div(
|
|
6259
6260
|
kt(
|
|
@@ -6276,7 +6277,7 @@ function Dn(e, t, n, s, r, u, l) {
|
|
|
6276
6277
|
)
|
|
6277
6278
|
)
|
|
6278
6279
|
),
|
|
6279
|
-
() =>
|
|
6280
|
+
() => j
|
|
6280
6281
|
)
|
|
6281
6282
|
);
|
|
6282
6283
|
}
|
|
@@ -6334,39 +6335,39 @@ function Ro(e) {
|
|
|
6334
6335
|
footer: x
|
|
6335
6336
|
} = c;
|
|
6336
6337
|
s = n;
|
|
6337
|
-
const
|
|
6338
|
+
const C = H("capturing");
|
|
6338
6339
|
h.on(g, (S) => {
|
|
6339
|
-
|
|
6340
|
+
C.set(S ? "capturing" : "non-capturing");
|
|
6340
6341
|
});
|
|
6341
|
-
const
|
|
6342
|
+
const $ = k(
|
|
6342
6343
|
m != null,
|
|
6343
6344
|
f
|
|
6344
|
-
)((S,
|
|
6345
|
-
const
|
|
6345
|
+
)((S, v) => S || v), y = re((S) => {
|
|
6346
|
+
const v = Qe({
|
|
6346
6347
|
initialStatus: "closed",
|
|
6347
6348
|
element: S
|
|
6348
6349
|
});
|
|
6349
|
-
|
|
6350
|
+
v.listenOnClosed(() => {
|
|
6350
6351
|
n();
|
|
6351
6352
|
}), s = () => {
|
|
6352
|
-
|
|
6353
|
-
}, rn(() =>
|
|
6354
|
-
const E = me("drawer"),
|
|
6353
|
+
v.close();
|
|
6354
|
+
}, rn(() => v.open());
|
|
6355
|
+
const E = me("drawer"), U = m != null ? `${E}-header` : void 0, V = `${E}-body`;
|
|
6355
6356
|
return i.div(
|
|
6356
6357
|
a.class(
|
|
6357
6358
|
k(
|
|
6358
6359
|
d,
|
|
6359
6360
|
o,
|
|
6360
|
-
|
|
6361
|
+
v.status
|
|
6361
6362
|
)(
|
|
6362
6363
|
(N, q, ie) => `bc-drawer bc-drawer--size-${N} bc-drawer--container-${_} bc-drawer--side-${q} bc-drawer--status-${ie}`
|
|
6363
6364
|
)
|
|
6364
6365
|
),
|
|
6365
6366
|
// Essential ARIA attributes for drawer dialog
|
|
6366
6367
|
a.role("dialog"),
|
|
6367
|
-
|
|
6368
|
-
...
|
|
6369
|
-
|
|
6368
|
+
L.modal(!0),
|
|
6369
|
+
...U ? [L.labelledby(U)] : [],
|
|
6370
|
+
L.describedby(V),
|
|
6370
6371
|
a.tabindex(-1),
|
|
6371
6372
|
// Make drawer focusable for initial focus
|
|
6372
6373
|
a.id(E),
|
|
@@ -6384,13 +6385,13 @@ function Ro(e) {
|
|
|
6384
6385
|
I.mousedown((N) => N.stopPropagation()),
|
|
6385
6386
|
// Prevent overlay click-outside when clicking drawer content
|
|
6386
6387
|
// Drawer content container
|
|
6387
|
-
|
|
6388
|
-
|
|
6388
|
+
B(
|
|
6389
|
+
$,
|
|
6389
6390
|
() => Ot({
|
|
6390
6391
|
header: i.div(
|
|
6391
6392
|
a.class("bc-drawer__header"),
|
|
6392
|
-
i.div(a.id(
|
|
6393
|
-
|
|
6393
|
+
i.div(a.id(U), m),
|
|
6394
|
+
B(
|
|
6394
6395
|
f,
|
|
6395
6396
|
() => ne(
|
|
6396
6397
|
le,
|
|
@@ -6404,7 +6405,7 @@ function Ro(e) {
|
|
|
6404
6405
|
),
|
|
6405
6406
|
body: i.div(
|
|
6406
6407
|
a.class("bc-drawer__body"),
|
|
6407
|
-
a.id(
|
|
6408
|
+
a.id(V),
|
|
6408
6409
|
w
|
|
6409
6410
|
),
|
|
6410
6411
|
footer: x && i.div(a.class("bc-drawer__footer"), x)
|
|
@@ -6412,7 +6413,7 @@ function Ro(e) {
|
|
|
6412
6413
|
() => Ot({
|
|
6413
6414
|
body: i.div(
|
|
6414
6415
|
a.class("bc-drawer__body"),
|
|
6415
|
-
a.id(
|
|
6416
|
+
a.id(V),
|
|
6416
6417
|
w
|
|
6417
6418
|
),
|
|
6418
6419
|
footer: x && i.div(a.class("bc-drawer__footer"), x)
|
|
@@ -6421,10 +6422,10 @@ function Ro(e) {
|
|
|
6421
6422
|
);
|
|
6422
6423
|
});
|
|
6423
6424
|
t({
|
|
6424
|
-
mode:
|
|
6425
|
+
mode: C,
|
|
6425
6426
|
effect: p ?? "opaque",
|
|
6426
6427
|
container: _,
|
|
6427
|
-
content:
|
|
6428
|
+
content: y,
|
|
6428
6429
|
onClickOutside: () => {
|
|
6429
6430
|
b?.(), r();
|
|
6430
6431
|
},
|
|
@@ -6460,7 +6461,7 @@ function Oo(e) {
|
|
|
6460
6461
|
showOn: c = "hover-focus"
|
|
6461
6462
|
} = e, d = me("tooltip");
|
|
6462
6463
|
return Q(
|
|
6463
|
-
|
|
6464
|
+
L.describedby(d),
|
|
6464
6465
|
wt({
|
|
6465
6466
|
content: () => Q(
|
|
6466
6467
|
a.class("bc-tooltip"),
|
|
@@ -6510,7 +6511,7 @@ function Fo(e) {
|
|
|
6510
6511
|
hasPopup: g = "dialog"
|
|
6511
6512
|
} = e, f = me("popover"), b = typeof t == "function" ? t : () => t;
|
|
6512
6513
|
return Q(
|
|
6513
|
-
|
|
6514
|
+
L.describedby(f),
|
|
6514
6515
|
wt({
|
|
6515
6516
|
content: () => Q(
|
|
6516
6517
|
a.class("bc-popover"),
|
|
@@ -6597,7 +6598,7 @@ function Uo(e, t) {
|
|
|
6597
6598
|
const m = i.div(
|
|
6598
6599
|
a.class("bc-lightbox"),
|
|
6599
6600
|
// Close button (top-end)
|
|
6600
|
-
|
|
6601
|
+
B(
|
|
6601
6602
|
s,
|
|
6602
6603
|
() => ne(
|
|
6603
6604
|
le,
|
|
@@ -6659,7 +6660,7 @@ function zo({
|
|
|
6659
6660
|
class: r
|
|
6660
6661
|
}, ...u) {
|
|
6661
6662
|
const l = H(!0);
|
|
6662
|
-
return
|
|
6663
|
+
return B(l, () => {
|
|
6663
6664
|
const c = h.map(
|
|
6664
6665
|
n,
|
|
6665
6666
|
(d) => !!d || s != null
|
|
@@ -6676,7 +6677,7 @@ function zo({
|
|
|
6676
6677
|
),
|
|
6677
6678
|
i.div(
|
|
6678
6679
|
a.class("bc-announcement-bar__content"),
|
|
6679
|
-
|
|
6680
|
+
B(
|
|
6680
6681
|
h.map(t, (d) => d != null),
|
|
6681
6682
|
() => i.div(
|
|
6682
6683
|
a.class("bc-announcement-bar__icon"),
|
|
@@ -6688,7 +6689,7 @@ function zo({
|
|
|
6688
6689
|
)
|
|
6689
6690
|
),
|
|
6690
6691
|
i.div(a.class("bc-announcement-bar__text"), ...u),
|
|
6691
|
-
|
|
6692
|
+
B(
|
|
6692
6693
|
c,
|
|
6693
6694
|
() => i.div(
|
|
6694
6695
|
a.class("bc-announcement-bar__close"),
|
|
@@ -6734,18 +6735,18 @@ function Ho(e, t) {
|
|
|
6734
6735
|
const p = H(""), _ = H(0);
|
|
6735
6736
|
p.on(() => _.set(0));
|
|
6736
6737
|
const w = `${me("command-palette")}-input`, x = p.map(
|
|
6737
|
-
(
|
|
6738
|
-
),
|
|
6738
|
+
(y) => Ms(b, y ?? "")
|
|
6739
|
+
), C = x.map((y) => y.length === 0), $ = i.div(
|
|
6739
6740
|
a.class(
|
|
6740
6741
|
h.map(
|
|
6741
6742
|
r,
|
|
6742
|
-
(
|
|
6743
|
+
(y) => `bc-command-palette bc-command-palette--size-${y ?? "md"}`
|
|
6743
6744
|
)
|
|
6744
6745
|
),
|
|
6745
6746
|
a.role("dialog"),
|
|
6746
|
-
|
|
6747
|
-
|
|
6748
|
-
I.mousedown((
|
|
6747
|
+
L.modal(!0),
|
|
6748
|
+
L.label(l.$.commandPalette),
|
|
6749
|
+
I.mousedown((y) => y.stopPropagation()),
|
|
6749
6750
|
nn({
|
|
6750
6751
|
escapeDeactivates: !1,
|
|
6751
6752
|
initialFocus: () => document.getElementById(w)
|
|
@@ -6767,25 +6768,25 @@ function Ho(e, t) {
|
|
|
6767
6768
|
a.id(w),
|
|
6768
6769
|
a.placeholder(o),
|
|
6769
6770
|
a.autocomplete("off"),
|
|
6770
|
-
I.input((
|
|
6771
|
-
p.set(
|
|
6771
|
+
I.input((y) => {
|
|
6772
|
+
p.set(y.target.value);
|
|
6772
6773
|
}),
|
|
6773
|
-
I.keydown((
|
|
6774
|
-
const S = h.get(x),
|
|
6775
|
-
switch (
|
|
6774
|
+
I.keydown((y) => {
|
|
6775
|
+
const S = h.get(x), v = h.get(_);
|
|
6776
|
+
switch (y.key) {
|
|
6776
6777
|
case "ArrowDown":
|
|
6777
|
-
|
|
6778
|
+
y.preventDefault(), _.set(Math.min(v + 1, S.length - 1));
|
|
6778
6779
|
break;
|
|
6779
6780
|
case "ArrowUp":
|
|
6780
|
-
|
|
6781
|
+
y.preventDefault(), _.set(Math.max(v - 1, 0));
|
|
6781
6782
|
break;
|
|
6782
6783
|
case "Enter":
|
|
6783
|
-
|
|
6784
|
+
y.preventDefault();
|
|
6784
6785
|
{
|
|
6785
|
-
const
|
|
6786
|
-
(E) => E.globalIndex ===
|
|
6786
|
+
const T = S.find(
|
|
6787
|
+
(E) => E.globalIndex === v
|
|
6787
6788
|
);
|
|
6788
|
-
|
|
6789
|
+
T && (T.item.onSelect(), d());
|
|
6789
6790
|
}
|
|
6790
6791
|
break;
|
|
6791
6792
|
}
|
|
@@ -6795,25 +6796,25 @@ function Ho(e, t) {
|
|
|
6795
6796
|
// Body with results
|
|
6796
6797
|
i.div(
|
|
6797
6798
|
a.class("bc-command-palette__body"),
|
|
6798
|
-
|
|
6799
|
-
|
|
6799
|
+
B(
|
|
6800
|
+
C,
|
|
6800
6801
|
() => i.div(
|
|
6801
6802
|
a.class("bc-command-palette__empty"),
|
|
6802
6803
|
g
|
|
6803
6804
|
),
|
|
6804
|
-
() => oe(x, (
|
|
6805
|
+
() => oe(x, (y) => {
|
|
6805
6806
|
const S = k(
|
|
6806
6807
|
_,
|
|
6807
|
-
|
|
6808
|
-
)((
|
|
6808
|
+
y
|
|
6809
|
+
)((v, T) => v === T.globalIndex);
|
|
6809
6810
|
return i.div(
|
|
6810
6811
|
a.class("bc-command-palette__section"),
|
|
6811
6812
|
// Section header (only for the first item in a section)
|
|
6812
|
-
|
|
6813
|
-
|
|
6813
|
+
B(
|
|
6814
|
+
y.map((v) => v.sectionStart != null),
|
|
6814
6815
|
() => i.div(
|
|
6815
6816
|
a.class("bc-command-palette__section-title"),
|
|
6816
|
-
|
|
6817
|
+
y.map((v) => v.sectionStart ?? "")
|
|
6817
6818
|
)
|
|
6818
6819
|
),
|
|
6819
6820
|
// Item
|
|
@@ -6821,24 +6822,24 @@ function Ho(e, t) {
|
|
|
6821
6822
|
a.class(
|
|
6822
6823
|
h.map(
|
|
6823
6824
|
S,
|
|
6824
|
-
(
|
|
6825
|
+
(v) => `bc-command-palette__item${v ? " bc-command-palette__item--selected" : ""}`
|
|
6825
6826
|
)
|
|
6826
6827
|
),
|
|
6827
6828
|
a.role("option"),
|
|
6828
6829
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
6829
|
-
|
|
6830
|
+
L.selected(S),
|
|
6830
6831
|
I.click(() => {
|
|
6831
|
-
h.get(
|
|
6832
|
+
h.get(y).item.onSelect(), d();
|
|
6832
6833
|
}),
|
|
6833
6834
|
I.mouseenter(() => {
|
|
6834
|
-
_.set(h.get(
|
|
6835
|
+
_.set(h.get(y).globalIndex);
|
|
6835
6836
|
}),
|
|
6836
|
-
|
|
6837
|
-
|
|
6837
|
+
B(
|
|
6838
|
+
y.map((v) => v.item.icon != null),
|
|
6838
6839
|
() => i.span(
|
|
6839
6840
|
a.class("bc-command-palette__item-icon"),
|
|
6840
6841
|
K({
|
|
6841
|
-
icon:
|
|
6842
|
+
icon: y.map((v) => v.item.icon ?? ""),
|
|
6842
6843
|
size: "sm",
|
|
6843
6844
|
accessibility: "decorative"
|
|
6844
6845
|
})
|
|
@@ -6848,29 +6849,29 @@ function Ho(e, t) {
|
|
|
6848
6849
|
a.class("bc-command-palette__item-content"),
|
|
6849
6850
|
i.span(
|
|
6850
6851
|
a.class("bc-command-palette__item-label"),
|
|
6851
|
-
|
|
6852
|
+
y.map((v) => v.item.label)
|
|
6852
6853
|
),
|
|
6853
|
-
|
|
6854
|
-
|
|
6854
|
+
B(
|
|
6855
|
+
y.map((v) => v.item.description != null),
|
|
6855
6856
|
() => i.span(
|
|
6856
6857
|
a.class(
|
|
6857
6858
|
"bc-command-palette__item-description"
|
|
6858
6859
|
),
|
|
6859
|
-
|
|
6860
|
+
y.map((v) => v.item.description ?? "")
|
|
6860
6861
|
)
|
|
6861
6862
|
)
|
|
6862
6863
|
),
|
|
6863
|
-
|
|
6864
|
-
|
|
6865
|
-
(
|
|
6864
|
+
B(
|
|
6865
|
+
y.map(
|
|
6866
|
+
(v) => v.item.shortcut != null && v.item.shortcut.length > 0
|
|
6866
6867
|
),
|
|
6867
6868
|
() => i.span(
|
|
6868
6869
|
a.class("bc-command-palette__item-shortcut"),
|
|
6869
6870
|
oe(
|
|
6870
|
-
|
|
6871
|
-
(
|
|
6871
|
+
y.map((v) => v.item.shortcut ?? []),
|
|
6872
|
+
(v) => i.kbd(
|
|
6872
6873
|
a.class("bc-kbd bc-kbd--size-xs"),
|
|
6873
|
-
|
|
6874
|
+
v
|
|
6874
6875
|
)
|
|
6875
6876
|
)
|
|
6876
6877
|
)
|
|
@@ -6885,7 +6886,7 @@ function Ho(e, t) {
|
|
|
6885
6886
|
mode: "capturing",
|
|
6886
6887
|
effect: "transparent",
|
|
6887
6888
|
container: u,
|
|
6888
|
-
content:
|
|
6889
|
+
content: $,
|
|
6889
6890
|
onClickOutside: d,
|
|
6890
6891
|
onEscape: d
|
|
6891
6892
|
});
|
|
@@ -6932,7 +6933,7 @@ function Wo(e) {
|
|
|
6932
6933
|
le,
|
|
6933
6934
|
(o) => i.div(
|
|
6934
6935
|
a.class("bc-block-command-palette"),
|
|
6935
|
-
d ? a.style(d) :
|
|
6936
|
+
d ? a.style(d) : j,
|
|
6936
6937
|
I.keydown(c),
|
|
6937
6938
|
// Search header
|
|
6938
6939
|
i.div(
|
|
@@ -6984,7 +6985,7 @@ function Wo(e) {
|
|
|
6984
6985
|
a.class("bc-block-command-palette__item-label"),
|
|
6985
6986
|
g.map((b) => b.item.label)
|
|
6986
6987
|
),
|
|
6987
|
-
|
|
6988
|
+
B(
|
|
6988
6989
|
g.map((b) => b.item.description != null),
|
|
6989
6990
|
() => i.span(
|
|
6990
6991
|
a.class("bc-block-command-palette__item-desc"),
|
|
@@ -6992,7 +6993,7 @@ function Wo(e) {
|
|
|
6992
6993
|
)
|
|
6993
6994
|
)
|
|
6994
6995
|
),
|
|
6995
|
-
|
|
6996
|
+
B(
|
|
6996
6997
|
g.map((b) => b.item.shortcut != null),
|
|
6997
6998
|
() => i.span(
|
|
6998
6999
|
a.class("bc-block-command-palette__item-shortcut"),
|
|
@@ -7003,7 +7004,7 @@ function Wo(e) {
|
|
|
7003
7004
|
})
|
|
7004
7005
|
),
|
|
7005
7006
|
// Empty state
|
|
7006
|
-
|
|
7007
|
+
B(
|
|
7007
7008
|
k(l)((g) => g.length === 0),
|
|
7008
7009
|
() => i.div(
|
|
7009
7010
|
a.class("bc-block-command-palette__empty"),
|
|
@@ -7045,8 +7046,8 @@ function Yo(e, t) {
|
|
|
7045
7046
|
a.class("bc-dialog__header-row"),
|
|
7046
7047
|
i.div(
|
|
7047
7048
|
a.class("bc-dialog__icon"),
|
|
7048
|
-
D.backgroundColor(h.map(u, (
|
|
7049
|
-
D.color(h.map(u, (
|
|
7049
|
+
D.backgroundColor(h.map(u, ($) => Se($, 100))),
|
|
7050
|
+
D.color(h.map(u, ($) => Se($, 600))),
|
|
7050
7051
|
K({ icon: r, size: "sm" })
|
|
7051
7052
|
),
|
|
7052
7053
|
i.span(a.class("bc-dialog__title"), n)
|
|
@@ -7056,8 +7057,8 @@ function Yo(e, t) {
|
|
|
7056
7057
|
i.p(a.class("bc-dialog__description"), s),
|
|
7057
7058
|
l && l.length > 0 ? i.ul(
|
|
7058
7059
|
a.class("bc-dialog__consequences"),
|
|
7059
|
-
...l.map((
|
|
7060
|
-
) :
|
|
7060
|
+
...l.map(($) => i.li($))
|
|
7061
|
+
) : j
|
|
7061
7062
|
),
|
|
7062
7063
|
footer: Q(
|
|
7063
7064
|
a.class("bc-dialog__actions"),
|
|
@@ -7167,15 +7168,15 @@ function qo(e, t) {
|
|
|
7167
7168
|
header: i.span(a.class("bc-dialog__title"), n),
|
|
7168
7169
|
body: i.div(
|
|
7169
7170
|
a.class("bc-dialog__body"),
|
|
7170
|
-
s ??
|
|
7171
|
+
s ?? j,
|
|
7171
7172
|
i.input(
|
|
7172
7173
|
a.class("bc-dialog__input"),
|
|
7173
7174
|
a.type("text"),
|
|
7174
7175
|
a.value(m),
|
|
7175
7176
|
a.placeholder(r ?? ""),
|
|
7176
|
-
I.input(de((
|
|
7177
|
-
I.keydown((
|
|
7178
|
-
|
|
7177
|
+
I.input(de(($) => m.set($))),
|
|
7178
|
+
I.keydown(($) => {
|
|
7179
|
+
$.key === "Enter" && ($.preventDefault(), w());
|
|
7179
7180
|
})
|
|
7180
7181
|
)
|
|
7181
7182
|
),
|
|
@@ -7242,15 +7243,15 @@ function Jo(e) {
|
|
|
7242
7243
|
onReady: m,
|
|
7243
7244
|
onStart: w,
|
|
7244
7245
|
onPlay: x,
|
|
7245
|
-
onPause:
|
|
7246
|
-
onBuffer:
|
|
7247
|
-
onBufferEnd:
|
|
7246
|
+
onPause: C,
|
|
7247
|
+
onBuffer: $,
|
|
7248
|
+
onBufferEnd: y,
|
|
7248
7249
|
onEnded: S,
|
|
7249
|
-
onError:
|
|
7250
|
-
onDuration:
|
|
7250
|
+
onError: v,
|
|
7251
|
+
onDuration: T,
|
|
7251
7252
|
onSeek: E,
|
|
7252
|
-
onProgress:
|
|
7253
|
-
onPlaybackRateChange:
|
|
7253
|
+
onProgress: U,
|
|
7254
|
+
onPlaybackRateChange: V,
|
|
7254
7255
|
onPlaybackQualityChange: N
|
|
7255
7256
|
} = e;
|
|
7256
7257
|
function q(P) {
|
|
@@ -7326,7 +7327,7 @@ function Jo(e) {
|
|
|
7326
7327
|
}
|
|
7327
7328
|
}
|
|
7328
7329
|
} catch (ae) {
|
|
7329
|
-
|
|
7330
|
+
v?.(ae), P.setAttribute("src", R);
|
|
7330
7331
|
try {
|
|
7331
7332
|
P.load();
|
|
7332
7333
|
} catch {
|
|
@@ -7347,7 +7348,7 @@ function Jo(e) {
|
|
|
7347
7348
|
const R = A;
|
|
7348
7349
|
if (!R) return;
|
|
7349
7350
|
const Y = R.duration || 0, ae = R.currentTime || 0, He = R.buffered?.length ? R.buffered.end(R.buffered.length - 1) : 0;
|
|
7350
|
-
|
|
7351
|
+
U?.({
|
|
7351
7352
|
played: Y > 0 ? ae / Y : 0,
|
|
7352
7353
|
playedSeconds: ae,
|
|
7353
7354
|
loaded: Y > 0 ? Math.min(He, Y) / Y : 0,
|
|
@@ -7387,17 +7388,17 @@ function Jo(e) {
|
|
|
7387
7388
|
// Events
|
|
7388
7389
|
I.play(() => x?.()),
|
|
7389
7390
|
I.playing(() => {
|
|
7390
|
-
w?.(),
|
|
7391
|
+
w?.(), y?.();
|
|
7391
7392
|
}),
|
|
7392
|
-
I.pause(() =>
|
|
7393
|
-
I.waiting(() =>
|
|
7393
|
+
I.pause(() => C?.()),
|
|
7394
|
+
I.waiting(() => $?.()),
|
|
7394
7395
|
I.canplay(() => {
|
|
7395
7396
|
const P = A?.duration;
|
|
7396
|
-
P != null && Number.isFinite(P) &&
|
|
7397
|
+
P != null && Number.isFinite(P) && T?.(P);
|
|
7397
7398
|
}),
|
|
7398
7399
|
I.ended(() => S?.()),
|
|
7399
7400
|
I.error((P) => {
|
|
7400
|
-
W ||
|
|
7401
|
+
W || v?.(P);
|
|
7401
7402
|
})
|
|
7402
7403
|
);
|
|
7403
7404
|
let Oe = null, X = null, Be = null;
|
|
@@ -7420,21 +7421,21 @@ function Jo(e) {
|
|
|
7420
7421
|
onStateChange: (ae) => {
|
|
7421
7422
|
switch (ae.data) {
|
|
7422
7423
|
case R.PlayerState.PLAYING:
|
|
7423
|
-
x?.(),
|
|
7424
|
+
x?.(), y?.();
|
|
7424
7425
|
break;
|
|
7425
7426
|
case R.PlayerState.PAUSED:
|
|
7426
|
-
|
|
7427
|
+
C?.();
|
|
7427
7428
|
break;
|
|
7428
7429
|
case R.PlayerState.BUFFERING:
|
|
7429
|
-
|
|
7430
|
+
$?.();
|
|
7430
7431
|
break;
|
|
7431
7432
|
case R.PlayerState.ENDED:
|
|
7432
7433
|
S?.();
|
|
7433
7434
|
break;
|
|
7434
7435
|
}
|
|
7435
7436
|
},
|
|
7436
|
-
onError: (ae) =>
|
|
7437
|
-
onPlaybackRateChange: (ae) =>
|
|
7437
|
+
onError: (ae) => v?.(ae),
|
|
7438
|
+
onPlaybackRateChange: (ae) => V?.(ae.data),
|
|
7438
7439
|
onPlaybackQualityChange: (ae) => N?.(ae.data)
|
|
7439
7440
|
}
|
|
7440
7441
|
});
|
|
@@ -7447,7 +7448,7 @@ function Jo(e) {
|
|
|
7447
7448
|
Be = Mt(() => {
|
|
7448
7449
|
if (!X) return;
|
|
7449
7450
|
const R = X.getDuration?.() ?? 0, Y = X.getCurrentTime?.() ?? 0, ae = X.getVideoLoadedFraction?.() ?? 0;
|
|
7450
|
-
|
|
7451
|
+
U?.({
|
|
7451
7452
|
played: R > 0 ? Y / R : 0,
|
|
7452
7453
|
playedSeconds: Y,
|
|
7453
7454
|
loaded: ae,
|
|
@@ -7546,7 +7547,7 @@ function Jo(e) {
|
|
|
7546
7547
|
D.height(
|
|
7547
7548
|
h.map(f, fe)
|
|
7548
7549
|
),
|
|
7549
|
-
|
|
7550
|
+
B(
|
|
7550
7551
|
h.map(O, (P) => P === "youtube"),
|
|
7551
7552
|
() => z,
|
|
7552
7553
|
() => Te
|
|
@@ -7658,16 +7659,16 @@ function Ko({
|
|
|
7658
7659
|
p != null && (p.destroy(), p = null);
|
|
7659
7660
|
}),
|
|
7660
7661
|
Ue((x) => {
|
|
7661
|
-
const
|
|
7662
|
+
const C = Rn(
|
|
7662
7663
|
x.map(
|
|
7663
|
-
(
|
|
7664
|
-
(
|
|
7664
|
+
($) => $ == null ? null : { width: $.width, height: $.height },
|
|
7665
|
+
($, y) => $ != null && y != null && $.width === y.width && $.height === y.height
|
|
7665
7666
|
),
|
|
7666
7667
|
100
|
|
7667
7668
|
);
|
|
7668
7669
|
return xe(
|
|
7669
|
-
|
|
7670
|
-
(
|
|
7670
|
+
C,
|
|
7671
|
+
($) => qt({
|
|
7671
7672
|
request: k(
|
|
7672
7673
|
e,
|
|
7673
7674
|
t,
|
|
@@ -7677,57 +7678,57 @@ function Ko({
|
|
|
7677
7678
|
u,
|
|
7678
7679
|
l,
|
|
7679
7680
|
c,
|
|
7680
|
-
|
|
7681
|
-
)((
|
|
7682
|
-
source:
|
|
7681
|
+
$
|
|
7682
|
+
)((y, S, v, T, E, U, V, N, q) => ({
|
|
7683
|
+
source: y,
|
|
7683
7684
|
page: S,
|
|
7684
|
-
fit:
|
|
7685
|
-
scale:
|
|
7685
|
+
fit: v,
|
|
7686
|
+
scale: T,
|
|
7686
7687
|
rotation: E,
|
|
7687
|
-
quality:
|
|
7688
|
-
renderTextLayer:
|
|
7688
|
+
quality: U,
|
|
7689
|
+
renderTextLayer: V,
|
|
7689
7690
|
renderAnnotationLayer: N,
|
|
7690
7691
|
containerWidth: q.width,
|
|
7691
7692
|
containerHeight: q.height
|
|
7692
7693
|
})),
|
|
7693
|
-
load: async ({ request:
|
|
7694
|
-
const S = await f,
|
|
7695
|
-
(p == null || !Gs(b,
|
|
7696
|
-
const
|
|
7697
|
-
d != null &&
|
|
7698
|
-
const
|
|
7694
|
+
load: async ({ request: y }) => {
|
|
7695
|
+
const S = await f, v = y.source, T = it(v), E = it(v);
|
|
7696
|
+
(p == null || !Gs(b, T)) && (p != null && (p.destroy(), p = null), b = T, p = await S.getDocument(E).promise, o?.({ pdfDoc: p }));
|
|
7697
|
+
const U = y.page < 1 || y.page > p.numPages ? 1 : y.page;
|
|
7698
|
+
d != null && U !== _ && (_ = U, d(U));
|
|
7699
|
+
const V = await p.getPage(U);
|
|
7699
7700
|
let N;
|
|
7700
|
-
if (
|
|
7701
|
-
N =
|
|
7701
|
+
if (y.fit === "none")
|
|
7702
|
+
N = y.scale;
|
|
7702
7703
|
else {
|
|
7703
|
-
const O =
|
|
7704
|
+
const O = V.getViewport({
|
|
7704
7705
|
scale: 1,
|
|
7705
|
-
rotation:
|
|
7706
|
-
}), A = O.width / O.height, F =
|
|
7707
|
-
switch (
|
|
7706
|
+
rotation: y.rotation
|
|
7707
|
+
}), A = O.width / O.height, F = y.containerWidth / y.containerHeight;
|
|
7708
|
+
switch (y.fit) {
|
|
7708
7709
|
case "width":
|
|
7709
|
-
N =
|
|
7710
|
+
N = y.containerWidth / O.width;
|
|
7710
7711
|
break;
|
|
7711
7712
|
case "height":
|
|
7712
|
-
N =
|
|
7713
|
+
N = y.containerHeight / O.height;
|
|
7713
7714
|
break;
|
|
7714
7715
|
case "contain":
|
|
7715
7716
|
N = Math.min(
|
|
7716
|
-
|
|
7717
|
-
|
|
7717
|
+
y.containerWidth / O.width,
|
|
7718
|
+
y.containerHeight / O.height
|
|
7718
7719
|
);
|
|
7719
7720
|
break;
|
|
7720
7721
|
case "cover":
|
|
7721
|
-
A > F ? N =
|
|
7722
|
+
A > F ? N = y.containerHeight / O.height : N = y.containerWidth / O.width;
|
|
7722
7723
|
break;
|
|
7723
7724
|
}
|
|
7724
7725
|
}
|
|
7725
|
-
const q =
|
|
7726
|
+
const q = V.getViewport({
|
|
7726
7727
|
scale: N,
|
|
7727
|
-
rotation:
|
|
7728
|
-
}), ie =
|
|
7729
|
-
scale: N *
|
|
7730
|
-
rotation:
|
|
7728
|
+
rotation: y.rotation
|
|
7729
|
+
}), ie = V.getViewport({
|
|
7730
|
+
scale: N * y.quality,
|
|
7731
|
+
rotation: y.rotation
|
|
7731
7732
|
});
|
|
7732
7733
|
return {
|
|
7733
7734
|
pdfWidth: q.width,
|
|
@@ -7747,7 +7748,7 @@ function Ko({
|
|
|
7747
7748
|
const W = O.getContext("2d");
|
|
7748
7749
|
if (!W)
|
|
7749
7750
|
throw new Error("Failed to get canvas context");
|
|
7750
|
-
const Z =
|
|
7751
|
+
const Z = V.render({
|
|
7751
7752
|
canvasContext: W,
|
|
7752
7753
|
canvas: O,
|
|
7753
7754
|
viewport: ie
|
|
@@ -7762,10 +7763,10 @@ function Ko({
|
|
|
7762
7763
|
} finally {
|
|
7763
7764
|
m === Z && (m = null);
|
|
7764
7765
|
}
|
|
7765
|
-
if (
|
|
7766
|
+
if (y.renderTextLayer && A != null) {
|
|
7766
7767
|
A.innerHTML = "";
|
|
7767
7768
|
try {
|
|
7768
|
-
const J = await
|
|
7769
|
+
const J = await V.getTextContent(), ce = S.TextLayer;
|
|
7769
7770
|
ce != null && await new ce({
|
|
7770
7771
|
textContentSource: J,
|
|
7771
7772
|
container: A,
|
|
@@ -7775,10 +7776,10 @@ function Ko({
|
|
|
7775
7776
|
console.warn("Failed to render text layer:", J);
|
|
7776
7777
|
}
|
|
7777
7778
|
}
|
|
7778
|
-
if (
|
|
7779
|
+
if (y.renderAnnotationLayer && F != null) {
|
|
7779
7780
|
F.innerHTML = "", F.style.width = `${q.width}px`, F.style.height = `${q.height}px`;
|
|
7780
7781
|
try {
|
|
7781
|
-
const J = await
|
|
7782
|
+
const J = await V.getAnnotations(), ce = S.AnnotationLayer;
|
|
7782
7783
|
if (ce != null && J.length > 0) {
|
|
7783
7784
|
const ue = {
|
|
7784
7785
|
// Minimal link service for basic functionality
|
|
@@ -7793,7 +7794,7 @@ function Ko({
|
|
|
7793
7794
|
};
|
|
7794
7795
|
await new ce({
|
|
7795
7796
|
div: F,
|
|
7796
|
-
page:
|
|
7797
|
+
page: V,
|
|
7797
7798
|
viewport: q,
|
|
7798
7799
|
linkService: ue,
|
|
7799
7800
|
annotationStorage: null
|
|
@@ -7801,7 +7802,7 @@ function Ko({
|
|
|
7801
7802
|
viewport: q,
|
|
7802
7803
|
div: F,
|
|
7803
7804
|
annotations: J,
|
|
7804
|
-
page:
|
|
7805
|
+
page: V,
|
|
7805
7806
|
linkService: ue,
|
|
7806
7807
|
renderForms: !0
|
|
7807
7808
|
});
|
|
@@ -7813,7 +7814,7 @@ function Ko({
|
|
|
7813
7814
|
}
|
|
7814
7815
|
};
|
|
7815
7816
|
},
|
|
7816
|
-
convertError: (
|
|
7817
|
+
convertError: (y) => y instanceof Error ? y.message : JSON.stringify(y),
|
|
7817
7818
|
pending: () => i.div(
|
|
7818
7819
|
a.class("bc-pdf-page-viewer__loading"),
|
|
7819
7820
|
K({
|
|
@@ -7822,19 +7823,19 @@ function Ko({
|
|
|
7822
7823
|
}),
|
|
7823
7824
|
i.span(
|
|
7824
7825
|
a.class("bc-pdf-page-viewer__loading-text"),
|
|
7825
|
-
w.map((
|
|
7826
|
+
w.map((y) => y.pdfPageViewer.loading)
|
|
7826
7827
|
)
|
|
7827
7828
|
),
|
|
7828
|
-
failure: ({ error:
|
|
7829
|
+
failure: ({ error: y }) => i.div(
|
|
7829
7830
|
a.class("bc-pdf-page-viewer__error"),
|
|
7830
7831
|
K({
|
|
7831
7832
|
icon: "line-md:alert-circle",
|
|
7832
7833
|
size: "lg",
|
|
7833
7834
|
color: "danger"
|
|
7834
7835
|
}),
|
|
7835
|
-
i.span(a.class("bc-pdf-page-viewer__error-text"),
|
|
7836
|
+
i.span(a.class("bc-pdf-page-viewer__error-text"), y)
|
|
7836
7837
|
),
|
|
7837
|
-
success: ({ value:
|
|
7838
|
+
success: ({ value: y }) => i.div(
|
|
7838
7839
|
a.class(
|
|
7839
7840
|
h.map(
|
|
7840
7841
|
n,
|
|
@@ -7845,19 +7846,19 @@ function Ko({
|
|
|
7845
7846
|
i.div(
|
|
7846
7847
|
a.class("bc-pdf-page-viewer__content"),
|
|
7847
7848
|
// Only set fixed dimensions when fit is 'none'
|
|
7848
|
-
|
|
7849
|
+
B(
|
|
7849
7850
|
h.map(n, (S) => S === "none"),
|
|
7850
7851
|
() => a.style(
|
|
7851
|
-
|
|
7852
|
-
(S) => `width: ${S}px; height: ${
|
|
7852
|
+
y.$.canvasWidth.map(
|
|
7853
|
+
(S) => `width: ${S}px; height: ${y.value.canvasHeight}px;`
|
|
7853
7854
|
)
|
|
7854
7855
|
)
|
|
7855
7856
|
),
|
|
7856
7857
|
// Canvas layer
|
|
7857
7858
|
i.canvas(
|
|
7858
7859
|
a.class("bc-pdf-page-viewer__canvas"),
|
|
7859
|
-
a.width(
|
|
7860
|
-
a.height(
|
|
7860
|
+
a.width(y.$.canvasWidth.map(String)),
|
|
7861
|
+
a.height(y.$.canvasHeight.map(String)),
|
|
7861
7862
|
...g
|
|
7862
7863
|
),
|
|
7863
7864
|
// Text layer (for text selection)
|
|
@@ -7866,20 +7867,20 @@ function Ko({
|
|
|
7866
7867
|
i.div(a.class("bc-pdf-page-viewer__annotation-layer"))
|
|
7867
7868
|
),
|
|
7868
7869
|
re((S) => {
|
|
7869
|
-
const
|
|
7870
|
+
const v = S.querySelector(
|
|
7870
7871
|
".bc-pdf-page-viewer__canvas"
|
|
7871
|
-
),
|
|
7872
|
+
), T = S.querySelector(
|
|
7872
7873
|
".bc-pdf-page-viewer__text-layer"
|
|
7873
7874
|
), E = S.querySelector(
|
|
7874
7875
|
".bc-pdf-page-viewer__annotation-layer"
|
|
7875
7876
|
);
|
|
7876
|
-
return h.on(
|
|
7877
|
-
await
|
|
7878
|
-
|
|
7879
|
-
|
|
7877
|
+
return h.on(y, async (U) => {
|
|
7878
|
+
await U.render(
|
|
7879
|
+
v,
|
|
7880
|
+
T,
|
|
7880
7881
|
E
|
|
7881
7882
|
);
|
|
7882
|
-
}),
|
|
7883
|
+
}), j;
|
|
7883
7884
|
})
|
|
7884
7885
|
)
|
|
7885
7886
|
})
|