@versini/ui-panel 1.4.0 → 1.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +123 -123
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -1,33 +1,33 @@
|
|
|
1
1
|
import { jsx as c, jsxs as S, Fragment as X } from "react/jsx-runtime";
|
|
2
2
|
import * as h from "react";
|
|
3
|
-
import
|
|
3
|
+
import V, { useRef as p, useLayoutEffect as F, useMemo as q, useState as Y, useEffect as R, useCallback as ie, useId as Z } from "react";
|
|
4
4
|
import i from "clsx";
|
|
5
5
|
import { useFloating as le, useClick as ce, useDismiss as se, useRole as de, useInteractions as ue, useMergeRefs as me, FloatingPortal as ge, FloatingOverlay as he, FloatingFocusManager as be } from "@floating-ui/react";
|
|
6
6
|
/*!
|
|
7
|
-
@versini/ui-panel v1.4.
|
|
7
|
+
@versini/ui-panel v1.4.1
|
|
8
8
|
© 2025 gizmette.com
|
|
9
9
|
*/
|
|
10
10
|
try {
|
|
11
11
|
window.__VERSINI_UI_PANEL__ || (window.__VERSINI_UI_PANEL__ = {
|
|
12
|
-
version: "1.4.
|
|
13
|
-
buildTime: "03/10/2025
|
|
12
|
+
version: "1.4.1",
|
|
13
|
+
buildTime: "03/10/2025 02:04 PM EDT",
|
|
14
14
|
homepage: "https://github.com/aversini/ui-components",
|
|
15
15
|
license: "MIT"
|
|
16
16
|
});
|
|
17
17
|
} catch {
|
|
18
18
|
}
|
|
19
|
-
const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "button",
|
|
19
|
+
const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "button", A = "link", fe = ({
|
|
20
20
|
type: e,
|
|
21
21
|
size: t,
|
|
22
22
|
labelRight: r,
|
|
23
23
|
labelLeft: a,
|
|
24
|
-
align:
|
|
25
|
-
animated:
|
|
24
|
+
align: n,
|
|
25
|
+
animated: o
|
|
26
26
|
}) => {
|
|
27
27
|
const l = "max-h-8 py-0 px-2", d = "max-h-9 h-8 px-3", u = "max-h-12 py-2 px-4";
|
|
28
28
|
switch (e) {
|
|
29
29
|
case H:
|
|
30
|
-
case
|
|
30
|
+
case A:
|
|
31
31
|
return i({
|
|
32
32
|
[l]: t === "small",
|
|
33
33
|
[d]: t === "medium",
|
|
@@ -35,21 +35,21 @@ const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "but
|
|
|
35
35
|
});
|
|
36
36
|
case T:
|
|
37
37
|
return i("flex items-center", {
|
|
38
|
-
"justify-center":
|
|
39
|
-
"justify-start":
|
|
40
|
-
"justify-end":
|
|
41
|
-
"h-6 w-6 p-0": t === "small" && !
|
|
42
|
-
"h-6 px-2": t === "small" && !
|
|
43
|
-
"h-8 w-8 p-1": t === "medium" && !
|
|
44
|
-
"h-8 px-3": t === "medium" && !
|
|
45
|
-
"h-12 w-12 p-2": t === "large" && !
|
|
46
|
-
"h-12 px-4": t === "large" && !
|
|
47
|
-
"h-6 py-0": t === "small" &&
|
|
48
|
-
"h-6": t === "small" &&
|
|
49
|
-
"h-8 py-1": t === "medium" &&
|
|
50
|
-
"h-8": t === "medium" &&
|
|
51
|
-
"h-12 py-2": t === "large" &&
|
|
52
|
-
"h-12": t === "large" &&
|
|
38
|
+
"justify-center": n === "center",
|
|
39
|
+
"justify-start": n === "left",
|
|
40
|
+
"justify-end": n === "right",
|
|
41
|
+
"h-6 w-6 p-0": t === "small" && !o && !(r || a),
|
|
42
|
+
"h-6 px-2": t === "small" && !o && (r || a),
|
|
43
|
+
"h-8 w-8 p-1": t === "medium" && !o && !(r || a),
|
|
44
|
+
"h-8 px-3": t === "medium" && !o && (r || a),
|
|
45
|
+
"h-12 w-12 p-2": t === "large" && !o && !(r || a),
|
|
46
|
+
"h-12 px-4": t === "large" && !o && (r || a),
|
|
47
|
+
"h-6 py-0": t === "small" && o && !(r || a),
|
|
48
|
+
"h-6": t === "small" && o && (r || a),
|
|
49
|
+
"h-8 py-1": t === "medium" && o && !(r || a),
|
|
50
|
+
"h-8": t === "medium" && o && (r || a),
|
|
51
|
+
"h-12 py-2": t === "large" && o && !(r || a),
|
|
52
|
+
"h-12": t === "large" && o && (r || a)
|
|
53
53
|
});
|
|
54
54
|
}
|
|
55
55
|
}, ve = ({
|
|
@@ -58,20 +58,20 @@ const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "but
|
|
|
58
58
|
labelRight: r,
|
|
59
59
|
labelLeft: a
|
|
60
60
|
}) => {
|
|
61
|
-
const
|
|
61
|
+
const n = "text-sm font-medium", o = "text-base font-medium", l = "text-lg font-medium";
|
|
62
62
|
switch (e) {
|
|
63
63
|
case H:
|
|
64
|
-
case
|
|
64
|
+
case A:
|
|
65
65
|
return i({
|
|
66
|
-
"text-center": e ===
|
|
67
|
-
[
|
|
68
|
-
[
|
|
66
|
+
"text-center": e === A,
|
|
67
|
+
[n]: t === "small",
|
|
68
|
+
[o]: t === "medium",
|
|
69
69
|
[l]: t === "large"
|
|
70
70
|
});
|
|
71
71
|
case T:
|
|
72
72
|
return i({
|
|
73
|
-
[
|
|
74
|
-
[
|
|
73
|
+
[n]: t === "small" && (r || a),
|
|
74
|
+
[o]: t === "medium" && (r || a),
|
|
75
75
|
[l]: t === "large" && (r || a)
|
|
76
76
|
});
|
|
77
77
|
}
|
|
@@ -265,8 +265,8 @@ const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "but
|
|
|
265
265
|
className: t,
|
|
266
266
|
raw: r,
|
|
267
267
|
mode: a,
|
|
268
|
-
focusMode:
|
|
269
|
-
disabled:
|
|
268
|
+
focusMode: n,
|
|
269
|
+
disabled: o,
|
|
270
270
|
fullWidth: l,
|
|
271
271
|
size: d,
|
|
272
272
|
noBorder: u,
|
|
@@ -298,12 +298,12 @@ const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "but
|
|
|
298
298
|
}),
|
|
299
299
|
ve({ type: e, size: d, labelRight: g, labelLeft: b }),
|
|
300
300
|
_e({ mode: a, variant: s, noBorder: u }),
|
|
301
|
-
Ie({ focusMode:
|
|
302
|
-
xe({ mode: a, variant: s, disabled:
|
|
303
|
-
we({ mode: a, variant: s, disabled:
|
|
301
|
+
Ie({ focusMode: n }),
|
|
302
|
+
xe({ mode: a, variant: s, disabled: o }),
|
|
303
|
+
we({ mode: a, variant: s, disabled: o }),
|
|
304
304
|
{
|
|
305
305
|
"w-full": l,
|
|
306
|
-
"disabled:cursor-not-allowed disabled:opacity-50":
|
|
306
|
+
"disabled:cursor-not-allowed disabled:opacity-50": o
|
|
307
307
|
},
|
|
308
308
|
i({
|
|
309
309
|
"transition-[width] duration-300 ease-in-out": e === T && v
|
|
@@ -312,16 +312,16 @@ const D = "av-messagebox", j = "av-panel", G = "av-button", T = "icon", H = "but
|
|
|
312
312
|
)), Se = (e, t, r) => {
|
|
313
313
|
var a;
|
|
314
314
|
!t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
|
|
315
|
-
}, J =
|
|
316
|
-
const { onClick: r, noInternalClick: a = !1, ...
|
|
315
|
+
}, J = V.forwardRef((e, t) => {
|
|
316
|
+
const { onClick: r, noInternalClick: a = !1, ...n } = e;
|
|
317
317
|
return /* @__PURE__ */ c(
|
|
318
318
|
"button",
|
|
319
319
|
{
|
|
320
320
|
ref: t,
|
|
321
|
-
onClick: (
|
|
322
|
-
Se(
|
|
321
|
+
onClick: (o) => {
|
|
322
|
+
Se(o, a, r);
|
|
323
323
|
},
|
|
324
|
-
...
|
|
324
|
+
...n
|
|
325
325
|
}
|
|
326
326
|
);
|
|
327
327
|
});
|
|
@@ -351,15 +351,15 @@ const Be = {
|
|
|
351
351
|
right: 0
|
|
352
352
|
};
|
|
353
353
|
function P(e) {
|
|
354
|
-
const t = Re(), r = p(0), a = p(null), [
|
|
354
|
+
const t = Re(), r = p(0), a = p(null), [n, o] = Y(Be), l = q(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((d) => {
|
|
355
355
|
const u = d[0];
|
|
356
356
|
u && (cancelAnimationFrame(r.current), r.current = requestAnimationFrame(() => {
|
|
357
|
-
a.current && t() &&
|
|
357
|
+
a.current && t() && o(u.contentRect);
|
|
358
358
|
}));
|
|
359
359
|
}), [t]);
|
|
360
360
|
return R(() => (a.current && (l == null || l.observe(a.current, e)), () => {
|
|
361
361
|
l == null || l.disconnect(), r.current && cancelAnimationFrame(r.current);
|
|
362
|
-
}), [l, e]), [a,
|
|
362
|
+
}), [l, e]), [a, n];
|
|
363
363
|
}
|
|
364
364
|
const Me = {
|
|
365
365
|
small: 24,
|
|
@@ -375,14 +375,14 @@ const Me = {
|
|
|
375
375
|
// px-3 x 2
|
|
376
376
|
large: 16 * 2
|
|
377
377
|
// px-4 x 2
|
|
378
|
-
}, Oe = 2,
|
|
378
|
+
}, Oe = 2, z = V.forwardRef(
|
|
379
379
|
({
|
|
380
380
|
children: e,
|
|
381
381
|
disabled: t = !1,
|
|
382
382
|
mode: r = "system",
|
|
383
383
|
focusMode: a = "system",
|
|
384
|
-
fullWidth:
|
|
385
|
-
className:
|
|
384
|
+
fullWidth: n = !1,
|
|
385
|
+
className: o,
|
|
386
386
|
type: l = "button",
|
|
387
387
|
raw: d = !1,
|
|
388
388
|
noBorder: u = !1,
|
|
@@ -403,10 +403,10 @@ const Me = {
|
|
|
403
403
|
type: T,
|
|
404
404
|
mode: r,
|
|
405
405
|
focusMode: a,
|
|
406
|
-
fullWidth:
|
|
406
|
+
fullWidth: n,
|
|
407
407
|
disabled: t,
|
|
408
408
|
raw: d,
|
|
409
|
-
className:
|
|
409
|
+
className: o,
|
|
410
410
|
noBorder: u,
|
|
411
411
|
size: m,
|
|
412
412
|
labelRight: s,
|
|
@@ -416,7 +416,7 @@ const Me = {
|
|
|
416
416
|
radius: v,
|
|
417
417
|
variant: Q,
|
|
418
418
|
animated: k
|
|
419
|
-
}),
|
|
419
|
+
}), oe = Ne({ mode: r, raw: d, iconClassName: ee }), $ = Ee({ animated: k }), [y, M] = P(), [x, L] = P(), [E, U] = P(), O = p(0), w = p(null), ne = Te([te, w]);
|
|
420
420
|
return F(() => {
|
|
421
421
|
E && E.current && k && (O.current = U.width + Le[m] + (u ? 0 : Oe));
|
|
422
422
|
}, [U, E, m, u, k]), F(() => {
|
|
@@ -433,7 +433,7 @@ const Me = {
|
|
|
433
433
|
]), /* @__PURE__ */ S(
|
|
434
434
|
J,
|
|
435
435
|
{
|
|
436
|
-
ref:
|
|
436
|
+
ref: ne,
|
|
437
437
|
className: ae,
|
|
438
438
|
disabled: t,
|
|
439
439
|
type: l,
|
|
@@ -445,17 +445,17 @@ const Me = {
|
|
|
445
445
|
{
|
|
446
446
|
label: f,
|
|
447
447
|
labelRef: x,
|
|
448
|
-
labelClass:
|
|
448
|
+
labelClass: $,
|
|
449
449
|
labelInnerClass: "pr-2"
|
|
450
450
|
}
|
|
451
451
|
),
|
|
452
|
-
/* @__PURE__ */ c("span", { ref: E, className:
|
|
452
|
+
/* @__PURE__ */ c("span", { ref: E, className: oe, children: e }),
|
|
453
453
|
/* @__PURE__ */ c(
|
|
454
454
|
W,
|
|
455
455
|
{
|
|
456
456
|
label: s,
|
|
457
457
|
labelRef: y,
|
|
458
|
-
labelClass:
|
|
458
|
+
labelClass: $,
|
|
459
459
|
labelInnerClass: "pl-2"
|
|
460
460
|
}
|
|
461
461
|
)
|
|
@@ -469,28 +469,28 @@ const Me = {
|
|
|
469
469
|
label: r,
|
|
470
470
|
labelInnerClass: a
|
|
471
471
|
}) => /* @__PURE__ */ c("span", { ref: e, className: t, children: r && /* @__PURE__ */ c("span", { className: a, children: r }) });
|
|
472
|
-
|
|
472
|
+
z.displayName = "ButtonIcon";
|
|
473
473
|
/*!
|
|
474
|
-
@versini/ui-button v4.2.
|
|
474
|
+
@versini/ui-button v4.2.11
|
|
475
475
|
© 2025 gizmette.com
|
|
476
476
|
*/
|
|
477
477
|
try {
|
|
478
478
|
window.__VERSINI_UI_BUTTON__ || (window.__VERSINI_UI_BUTTON__ = {
|
|
479
|
-
version: "4.2.
|
|
480
|
-
buildTime: "03/10/2025
|
|
479
|
+
version: "4.2.11",
|
|
480
|
+
buildTime: "03/10/2025 02:04 PM EDT",
|
|
481
481
|
homepage: "https://github.com/aversini/ui-components",
|
|
482
482
|
license: "MIT"
|
|
483
483
|
});
|
|
484
484
|
} catch {
|
|
485
485
|
}
|
|
486
|
-
const Pe =
|
|
486
|
+
const Pe = V.forwardRef(
|
|
487
487
|
({
|
|
488
488
|
children: e,
|
|
489
489
|
mode: t = "system",
|
|
490
490
|
className: r,
|
|
491
491
|
active: a = !1,
|
|
492
|
-
...
|
|
493
|
-
},
|
|
492
|
+
...n
|
|
493
|
+
}, o) => {
|
|
494
494
|
const l = a ? i(
|
|
495
495
|
"relative",
|
|
496
496
|
"focus-within:static",
|
|
@@ -509,77 +509,77 @@ const Pe = A.forwardRef(
|
|
|
509
509
|
}
|
|
510
510
|
) : "";
|
|
511
511
|
return /* @__PURE__ */ c("div", { className: l, children: /* @__PURE__ */ c(
|
|
512
|
-
|
|
512
|
+
z,
|
|
513
513
|
{
|
|
514
514
|
className: i("justify-center", r),
|
|
515
|
-
ref:
|
|
515
|
+
ref: o,
|
|
516
516
|
mode: t,
|
|
517
517
|
radius: "small",
|
|
518
|
-
...
|
|
518
|
+
...n,
|
|
519
519
|
children: e
|
|
520
520
|
}
|
|
521
521
|
) });
|
|
522
522
|
}
|
|
523
523
|
);
|
|
524
524
|
Pe.displayName = "ButtonSort";
|
|
525
|
-
const
|
|
525
|
+
const Ae = ({
|
|
526
526
|
children: e,
|
|
527
527
|
fill: t,
|
|
528
528
|
viewBox: r,
|
|
529
529
|
className: a,
|
|
530
|
-
defaultViewBox:
|
|
531
|
-
size:
|
|
530
|
+
defaultViewBox: n,
|
|
531
|
+
size: o,
|
|
532
532
|
title: l,
|
|
533
533
|
semantic: d = !1,
|
|
534
534
|
...u
|
|
535
535
|
}) => {
|
|
536
|
-
const g = i(
|
|
537
|
-
return /* @__PURE__ */
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
children:
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
536
|
+
const g = i(o, a);
|
|
537
|
+
return /* @__PURE__ */ c(X, { children: /* @__PURE__ */ S(
|
|
538
|
+
"svg",
|
|
539
|
+
{
|
|
540
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
541
|
+
className: g,
|
|
542
|
+
viewBox: r || n,
|
|
543
|
+
fill: t || "currentColor",
|
|
544
|
+
role: "img",
|
|
545
|
+
"aria-hidden": !d,
|
|
546
|
+
focusable: !1,
|
|
547
|
+
...u,
|
|
548
|
+
children: [
|
|
549
|
+
l && d && /* @__PURE__ */ c("title", { children: l }),
|
|
550
|
+
e
|
|
551
|
+
]
|
|
552
|
+
}
|
|
553
|
+
) });
|
|
554
554
|
};
|
|
555
555
|
/*!
|
|
556
|
-
@versini/ui-svgicon v4.
|
|
556
|
+
@versini/ui-svgicon v4.1.1
|
|
557
557
|
© 2025 gizmette.com
|
|
558
558
|
*/
|
|
559
559
|
try {
|
|
560
560
|
window.__VERSINI_UI_SVGICON__ || (window.__VERSINI_UI_SVGICON__ = {
|
|
561
|
-
version: "4.
|
|
562
|
-
buildTime: "
|
|
561
|
+
version: "4.1.1",
|
|
562
|
+
buildTime: "02/27/2025 03:46 PM EST",
|
|
563
563
|
homepage: "https://github.com/aversini/ui-components",
|
|
564
564
|
license: "MIT"
|
|
565
565
|
});
|
|
566
566
|
} catch {
|
|
567
567
|
}
|
|
568
|
-
const
|
|
568
|
+
const Ve = ({
|
|
569
569
|
className: e,
|
|
570
570
|
viewBox: t,
|
|
571
571
|
title: r,
|
|
572
572
|
monotone: a,
|
|
573
|
-
...
|
|
573
|
+
...n
|
|
574
574
|
}) => /* @__PURE__ */ c(
|
|
575
|
-
|
|
575
|
+
Ae,
|
|
576
576
|
{
|
|
577
577
|
defaultViewBox: "0 0 384 512",
|
|
578
578
|
size: "size-5",
|
|
579
579
|
viewBox: t,
|
|
580
580
|
className: e,
|
|
581
581
|
title: r || "Close",
|
|
582
|
-
...
|
|
582
|
+
...n,
|
|
583
583
|
children: /* @__PURE__ */ c(
|
|
584
584
|
"path",
|
|
585
585
|
{
|
|
@@ -590,25 +590,25 @@ const Ae = ({
|
|
|
590
590
|
}
|
|
591
591
|
);
|
|
592
592
|
/*!
|
|
593
|
-
@versini/ui-icons v4.
|
|
593
|
+
@versini/ui-icons v4.8.1
|
|
594
594
|
© 2025 gizmette.com
|
|
595
595
|
*/
|
|
596
596
|
try {
|
|
597
597
|
window.__VERSINI_UI_ICONS__ || (window.__VERSINI_UI_ICONS__ = {
|
|
598
|
-
version: "4.
|
|
599
|
-
buildTime: "
|
|
598
|
+
version: "4.8.1",
|
|
599
|
+
buildTime: "02/27/2025 03:46 PM EST",
|
|
600
600
|
homepage: "https://github.com/aversini/ui-components",
|
|
601
601
|
license: "MIT"
|
|
602
602
|
});
|
|
603
603
|
} catch {
|
|
604
604
|
}
|
|
605
605
|
const K = h.createContext(null);
|
|
606
|
-
function
|
|
606
|
+
function ze({
|
|
607
607
|
initialOpen: e = !1,
|
|
608
608
|
open: t,
|
|
609
609
|
onOpenChange: r
|
|
610
610
|
} = {}) {
|
|
611
|
-
const [a,
|
|
611
|
+
const [a, n] = h.useState(e), [o, l] = h.useState(), [d, u] = h.useState(), g = t ?? a, b = r ?? n, m = le({
|
|
612
612
|
open: g,
|
|
613
613
|
onOpenChange: b
|
|
614
614
|
}), s = m.context, f = ce(s, {
|
|
@@ -623,12 +623,12 @@ function Ve({
|
|
|
623
623
|
setOpen: b,
|
|
624
624
|
...v,
|
|
625
625
|
...m,
|
|
626
|
-
labelId:
|
|
626
|
+
labelId: o,
|
|
627
627
|
descriptionId: d,
|
|
628
628
|
setLabelId: l,
|
|
629
629
|
setDescriptionId: u
|
|
630
630
|
}),
|
|
631
|
-
[g, b, v, m,
|
|
631
|
+
[g, b, v, m, o, d]
|
|
632
632
|
);
|
|
633
633
|
}
|
|
634
634
|
const B = () => {
|
|
@@ -637,25 +637,25 @@ const B = () => {
|
|
|
637
637
|
throw new Error("Modal components must be wrapped in <Modal />");
|
|
638
638
|
return e;
|
|
639
639
|
};
|
|
640
|
-
function
|
|
640
|
+
function $e({
|
|
641
641
|
children: e,
|
|
642
642
|
...t
|
|
643
643
|
}) {
|
|
644
|
-
const r =
|
|
644
|
+
const r = ze(t);
|
|
645
645
|
return /* @__PURE__ */ c(K.Provider, { value: r, children: e });
|
|
646
646
|
}
|
|
647
647
|
const Ue = h.forwardRef(function(e, t) {
|
|
648
|
-
const { context: r, ...a } = B(),
|
|
648
|
+
const { context: r, ...a } = B(), n = me([a.refs.setFloating, t]);
|
|
649
649
|
if (!r.open)
|
|
650
650
|
return null;
|
|
651
|
-
const { overlayBackground:
|
|
652
|
-
[`${
|
|
653
|
-
"bg-black sm:bg-black/[.8]": !
|
|
651
|
+
const { overlayBackground: o, ...l } = e, d = i("grid place-items-center", {
|
|
652
|
+
[`${o}`]: o,
|
|
653
|
+
"bg-black sm:bg-black/[.8]": !o
|
|
654
654
|
});
|
|
655
655
|
return /* @__PURE__ */ c(ge, { children: /* @__PURE__ */ c(he, { className: d, lockScroll: !0, children: /* @__PURE__ */ c(be, { context: r, children: /* @__PURE__ */ c(
|
|
656
656
|
"div",
|
|
657
657
|
{
|
|
658
|
-
ref:
|
|
658
|
+
ref: n,
|
|
659
659
|
"aria-labelledby": a.labelId,
|
|
660
660
|
"aria-describedby": a.descriptionId,
|
|
661
661
|
...a.getFloatingProps(l),
|
|
@@ -663,27 +663,27 @@ const Ue = h.forwardRef(function(e, t) {
|
|
|
663
663
|
}
|
|
664
664
|
) }) }) });
|
|
665
665
|
}), Fe = h.forwardRef(function({ children: e, ...t }, r) {
|
|
666
|
-
const { setLabelId: a } = B(),
|
|
667
|
-
return h.useLayoutEffect(() => (a(
|
|
666
|
+
const { setLabelId: a } = B(), n = Z();
|
|
667
|
+
return h.useLayoutEffect(() => (a(n), () => a(void 0)), [n, a]), /* @__PURE__ */ c("h1", { ...t, ref: r, id: n, children: e });
|
|
668
668
|
}), De = h.forwardRef(function({ children: e, ...t }, r) {
|
|
669
|
-
const { setDescriptionId: a } = B(),
|
|
670
|
-
return h.useLayoutEffect(() => (a(
|
|
669
|
+
const { setDescriptionId: a } = B(), n = Z();
|
|
670
|
+
return h.useLayoutEffect(() => (a(n), () => a(void 0)), [n, a]), /* @__PURE__ */ c("div", { ...t, ref: r, id: n, children: e });
|
|
671
671
|
}), je = h.forwardRef(function(e, t) {
|
|
672
|
-
const { setOpen: r } = B(), { trigger: a, className:
|
|
673
|
-
return /* @__PURE__ */ c("div", { className:
|
|
672
|
+
const { setOpen: r } = B(), { trigger: a, className: n, ...o } = e, l = h.useCallback(() => r(!1), [r]);
|
|
673
|
+
return /* @__PURE__ */ c("div", { className: n, children: h.cloneElement(a, {
|
|
674
674
|
ref: t,
|
|
675
675
|
onClick: l,
|
|
676
|
-
...
|
|
676
|
+
...o
|
|
677
677
|
}) });
|
|
678
678
|
});
|
|
679
679
|
/*!
|
|
680
|
-
@versini/ui-modal v1.2.
|
|
680
|
+
@versini/ui-modal v1.2.12
|
|
681
681
|
© 2025 gizmette.com
|
|
682
682
|
*/
|
|
683
683
|
try {
|
|
684
684
|
window.__VERSINI_UI_MODAL__ || (window.__VERSINI_UI_MODAL__ = {
|
|
685
|
-
version: "1.2.
|
|
686
|
-
buildTime: "03/10/2025
|
|
685
|
+
version: "1.2.12",
|
|
686
|
+
buildTime: "03/10/2025 02:04 PM EDT",
|
|
687
687
|
homepage: "https://github.com/aversini/ui-components",
|
|
688
688
|
license: "MIT"
|
|
689
689
|
});
|
|
@@ -719,8 +719,8 @@ const N = "panel", C = "messagebox", Ge = ({
|
|
|
719
719
|
onOpenChange: t,
|
|
720
720
|
title: r,
|
|
721
721
|
children: a,
|
|
722
|
-
footer:
|
|
723
|
-
borderMode:
|
|
722
|
+
footer: n,
|
|
723
|
+
borderMode: o = "light",
|
|
724
724
|
kind: l = N,
|
|
725
725
|
className: d,
|
|
726
726
|
animation: u = !1
|
|
@@ -728,7 +728,7 @@ const N = "panel", C = "messagebox", Ge = ({
|
|
|
728
728
|
const g = p(""), b = p({ opacity: 0 }), [, m] = Y(!1), s = Ge({
|
|
729
729
|
className: d,
|
|
730
730
|
kind: l,
|
|
731
|
-
borderMode:
|
|
731
|
+
borderMode: o,
|
|
732
732
|
animation: u
|
|
733
733
|
});
|
|
734
734
|
return R(() => (e && (g.current = document.title, document.title = `${r} | ${g.current}`), () => {
|
|
@@ -745,7 +745,7 @@ const N = "panel", C = "messagebox", Ge = ({
|
|
|
745
745
|
}, 100);
|
|
746
746
|
return () => clearTimeout(f);
|
|
747
747
|
}
|
|
748
|
-
}, [e, u]), /* @__PURE__ */ c(X, { children: e && /* @__PURE__ */ c(
|
|
748
|
+
}, [e, u]), /* @__PURE__ */ c(X, { children: e && /* @__PURE__ */ c($e, { open: e, onOpenChange: t, children: /* @__PURE__ */ S(
|
|
749
749
|
Ue,
|
|
750
750
|
{
|
|
751
751
|
className: s.main,
|
|
@@ -757,13 +757,13 @@ const N = "panel", C = "messagebox", Ge = ({
|
|
|
757
757
|
{
|
|
758
758
|
className: s.close,
|
|
759
759
|
trigger: /* @__PURE__ */ c(
|
|
760
|
-
|
|
760
|
+
z,
|
|
761
761
|
{
|
|
762
762
|
mode: "dark",
|
|
763
763
|
focusMode: "light",
|
|
764
764
|
noBorder: !0,
|
|
765
765
|
label: "Close",
|
|
766
|
-
children: /* @__PURE__ */ c(
|
|
766
|
+
children: /* @__PURE__ */ c(Ve, {})
|
|
767
767
|
}
|
|
768
768
|
)
|
|
769
769
|
}
|
|
@@ -771,7 +771,7 @@ const N = "panel", C = "messagebox", Ge = ({
|
|
|
771
771
|
/* @__PURE__ */ c(Fe, { className: s.header, children: r })
|
|
772
772
|
] }),
|
|
773
773
|
/* @__PURE__ */ c(De, { className: s.content, children: a }),
|
|
774
|
-
|
|
774
|
+
n && /* @__PURE__ */ c("div", { className: s.footer, children: n })
|
|
775
775
|
]
|
|
776
776
|
}
|
|
777
777
|
) }) });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@versini/ui-panel",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Arno Versini",
|
|
6
6
|
"publishConfig": {
|
|
@@ -40,14 +40,14 @@
|
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"@tailwindcss/typography": "0.5.16",
|
|
43
|
-
"@versini/ui-button": "4.2.
|
|
44
|
-
"@versini/ui-icons": "
|
|
45
|
-
"@versini/ui-modal": "1.2.
|
|
43
|
+
"@versini/ui-button": "4.2.11",
|
|
44
|
+
"@versini/ui-icons": "4.8.1",
|
|
45
|
+
"@versini/ui-modal": "1.2.12",
|
|
46
46
|
"clsx": "2.1.1",
|
|
47
47
|
"tailwindcss": "3.4.17"
|
|
48
48
|
},
|
|
49
49
|
"sideEffects": [
|
|
50
50
|
"**/*.css"
|
|
51
51
|
],
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "fc7e720b770c5ee2e8537eabf9b2f458dba07696"
|
|
53
53
|
}
|