@ahmetilhn/hanui 2.0.6 → 2.0.7
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/README.md +27 -0
- package/build/index.cjs +3 -3
- package/build/index.cjs.map +1 -1
- package/build/index.js +808 -802
- package/build/index.js.map +1 -1
- package/build/styles.css +1 -1
- package/package.json +4 -2
package/build/index.js
CHANGED
|
@@ -146,7 +146,7 @@ const T = {
|
|
|
146
146
|
/** 9,82:1 koyu zemin üzerinde. */
|
|
147
147
|
dark: "#f0b429"
|
|
148
148
|
}, B = (e, t) => {
|
|
149
|
-
const n = e.replace("#", ""), r = n.length === 3 ? n.split("").map((
|
|
149
|
+
const n = e.replace("#", ""), r = n.length === 3 ? n.split("").map((u) => u + u).join("") : n, o = parseInt(r.slice(0, 2), 16), s = parseInt(r.slice(2, 4), 16), i = parseInt(r.slice(4, 6), 16);
|
|
150
150
|
return `rgba(${o}, ${s}, ${i}, ${t})`;
|
|
151
151
|
}, ie = "#000000", wn = {
|
|
152
152
|
// --- Yüzey ---
|
|
@@ -549,11 +549,11 @@ const T = {
|
|
|
549
549
|
const n = e === "dark" ? xn : wn, r = (e === "dark" ? t == null ? void 0 : t.dark : t == null ? void 0 : t.light) ?? {};
|
|
550
550
|
return { ...n, ...r };
|
|
551
551
|
}, kn = (e) => {
|
|
552
|
-
const t = [], n = (i,
|
|
552
|
+
const t = [], n = (i, u = " ") => Object.entries(i).map(([h, d]) => `${u}${ba}${h}: ${d};`).join(`
|
|
553
553
|
`), r = e.fonts ?? {}, o = Object.entries(r).filter(([, i]) => !!i);
|
|
554
554
|
o.length > 0 && t.push(
|
|
555
555
|
`:root {
|
|
556
|
-
${o.map(([i,
|
|
556
|
+
${o.map(([i, u]) => ` ${ba}font-${i}: ${u};`).join(`
|
|
557
557
|
`)}
|
|
558
558
|
}`
|
|
559
559
|
);
|
|
@@ -651,46 +651,46 @@ ${n(
|
|
|
651
651
|
const d = window.matchMedia("(prefers-color-scheme: dark)"), c = () => r(va());
|
|
652
652
|
return d.addEventListener("change", c), () => d.removeEventListener("change", c);
|
|
653
653
|
}, []);
|
|
654
|
-
const i = e === "system" ? n : e,
|
|
654
|
+
const i = e === "system" ? n : e, u = z((d) => {
|
|
655
655
|
if (!he()) return;
|
|
656
656
|
const c = document.documentElement;
|
|
657
657
|
c.classList.add(fa), d === "system" ? c.removeAttribute(Ve) : c.setAttribute(Ve, d), t(d), window.requestAnimationFrame(() => {
|
|
658
658
|
window.requestAnimationFrame(() => c.classList.remove(fa));
|
|
659
659
|
});
|
|
660
|
-
}, []),
|
|
661
|
-
() =>
|
|
662
|
-
[i,
|
|
660
|
+
}, []), h = z(
|
|
661
|
+
() => u(i === "dark" ? "light" : "dark"),
|
|
662
|
+
[i, u]
|
|
663
663
|
);
|
|
664
|
-
return { scheme: i, preference: e, setScheme:
|
|
664
|
+
return { scheme: i, preference: e, setScheme: u, toggle: h, isReady: o };
|
|
665
665
|
}, ia = (e, t) => {
|
|
666
666
|
typeof (e == null ? void 0 : e.scrollIntoView) == "function" && e.scrollIntoView(t);
|
|
667
667
|
}, qa = ({ count: e, isOpen: t, initialIndex: n = 0, onSelect: r, onClose: o }, { hasSpaceSelect: s = !1 } = {}) => {
|
|
668
|
-
const [i,
|
|
668
|
+
const [i, u] = P(n), h = R(null);
|
|
669
669
|
S(() => {
|
|
670
|
-
t &&
|
|
670
|
+
t && u(n);
|
|
671
671
|
}, [t, n]), S(() => {
|
|
672
|
-
|
|
672
|
+
u((c) => c >= e ? Math.max(0, e - 1) : c);
|
|
673
673
|
}, [e]), S(() => {
|
|
674
674
|
var c;
|
|
675
|
-
t && ia((c =
|
|
675
|
+
t && ia((c = h.current) == null ? void 0 : c.querySelector(`[data-index="${i}"]`), {
|
|
676
676
|
block: "nearest"
|
|
677
677
|
});
|
|
678
678
|
}, [i, t, e]);
|
|
679
679
|
const d = z(
|
|
680
680
|
(c) => {
|
|
681
|
-
const
|
|
681
|
+
const _ = e - 1;
|
|
682
682
|
switch (c.key) {
|
|
683
683
|
case "ArrowDown":
|
|
684
|
-
c.preventDefault(),
|
|
684
|
+
c.preventDefault(), u((l) => l >= _ ? 0 : l + 1);
|
|
685
685
|
break;
|
|
686
686
|
case "ArrowUp":
|
|
687
|
-
c.preventDefault(),
|
|
687
|
+
c.preventDefault(), u((l) => l <= 0 ? _ : l - 1);
|
|
688
688
|
break;
|
|
689
689
|
case "Home":
|
|
690
|
-
c.preventDefault(),
|
|
690
|
+
c.preventDefault(), u(0);
|
|
691
691
|
break;
|
|
692
692
|
case "End":
|
|
693
|
-
c.preventDefault(), _
|
|
693
|
+
c.preventDefault(), u(_);
|
|
694
694
|
break;
|
|
695
695
|
case " ":
|
|
696
696
|
case "Enter": {
|
|
@@ -708,22 +708,22 @@ ${n(
|
|
|
708
708
|
},
|
|
709
709
|
[i, e, s, o, r]
|
|
710
710
|
);
|
|
711
|
-
return { activeIndex: i, setActiveIndex:
|
|
712
|
-
},
|
|
711
|
+
return { activeIndex: i, setActiveIndex: u, listRef: h, handleKeyDown: d };
|
|
712
|
+
}, Wt = {
|
|
713
713
|
top: "bottom",
|
|
714
714
|
bottom: "top",
|
|
715
715
|
left: "right",
|
|
716
716
|
right: "left"
|
|
717
|
-
}, ya = (e, t, n) => Math.min(Math.max(e, t), n),
|
|
717
|
+
}, ya = (e, t, n) => Math.min(Math.max(e, t), n), Qt = (e, t, n, r, o) => {
|
|
718
718
|
const s = n === "top" || n === "bottom", i = {
|
|
719
719
|
top: e.top - t.height - o,
|
|
720
720
|
bottom: e.top + e.height + o,
|
|
721
721
|
left: e.left - t.width - o,
|
|
722
722
|
right: e.left + e.width + o
|
|
723
|
-
}[n],
|
|
724
|
-
start:
|
|
725
|
-
center:
|
|
726
|
-
end:
|
|
723
|
+
}[n], u = s ? e.left : e.top, h = s ? e.width : e.height, d = s ? t.width : t.height, c = {
|
|
724
|
+
start: u,
|
|
725
|
+
center: u + h / 2 - d / 2,
|
|
726
|
+
end: u + h - d
|
|
727
727
|
}[r];
|
|
728
728
|
return s ? { top: i, left: c } : { top: c, left: i };
|
|
729
729
|
}, wa = (e, t, n, r, o) => ({
|
|
@@ -732,79 +732,79 @@ ${n(
|
|
|
732
732
|
left: e.left >= r,
|
|
733
733
|
right: e.left + t.width <= o.width - r
|
|
734
734
|
})[n], Ut = (e, t, { side: n = "top", align: r = "center", offset: o = 8, padding: s = 8, isOpen: i }) => {
|
|
735
|
-
const [
|
|
735
|
+
const [u, h] = P({
|
|
736
736
|
style: { position: "fixed", top: 0, left: 0 },
|
|
737
737
|
side: n,
|
|
738
738
|
isPositioned: !1
|
|
739
739
|
}), d = R(0), c = z(() => {
|
|
740
|
-
const m = e.current,
|
|
741
|
-
if (!m || !
|
|
742
|
-
const b = m.getBoundingClientRect(), p =
|
|
743
|
-
|
|
740
|
+
const m = e.current, w = t.current;
|
|
741
|
+
if (!m || !w) return;
|
|
742
|
+
const b = m.getBoundingClientRect(), p = w.getBoundingClientRect(), y = { width: window.innerWidth, height: window.innerHeight }, D = Qt(b, p, n, r, o), N = wa(D, p, n, s, y) ? n : wa(
|
|
743
|
+
Qt(b, p, Wt[n], r, o),
|
|
744
744
|
p,
|
|
745
|
-
|
|
745
|
+
Wt[n],
|
|
746
746
|
s,
|
|
747
747
|
y
|
|
748
|
-
) ?
|
|
749
|
-
|
|
748
|
+
) ? Wt[n] : n, f = Qt(b, p, N, r, o);
|
|
749
|
+
h({
|
|
750
750
|
style: {
|
|
751
751
|
position: "fixed",
|
|
752
|
-
top: Math.round(ya(
|
|
753
|
-
left: Math.round(ya(
|
|
752
|
+
top: Math.round(ya(f.top, s, y.height - p.height - s)),
|
|
753
|
+
left: Math.round(ya(f.left, s, y.width - p.width - s))
|
|
754
754
|
},
|
|
755
755
|
side: N,
|
|
756
756
|
isPositioned: !0
|
|
757
757
|
});
|
|
758
|
-
}, [e, t, n, r, o, s]),
|
|
758
|
+
}, [e, t, n, r, o, s]), _ = z(() => {
|
|
759
759
|
d.current || (d.current = window.requestAnimationFrame(() => {
|
|
760
760
|
d.current = 0, c();
|
|
761
761
|
}));
|
|
762
762
|
}, [c]);
|
|
763
763
|
return (he() ? Ea : S)(() => {
|
|
764
764
|
if (!i) {
|
|
765
|
-
|
|
765
|
+
h((w) => w.isPositioned ? { ...w, isPositioned: !1 } : w);
|
|
766
766
|
return;
|
|
767
767
|
}
|
|
768
|
-
c(), window.addEventListener("resize",
|
|
769
|
-
const m = typeof ResizeObserver > "u" ? null : new ResizeObserver(
|
|
768
|
+
c(), window.addEventListener("resize", _), document.addEventListener("scroll", _, !0);
|
|
769
|
+
const m = typeof ResizeObserver > "u" ? null : new ResizeObserver(_);
|
|
770
770
|
return m && t.current && m.observe(t.current), m && e.current && m.observe(e.current), () => {
|
|
771
|
-
window.removeEventListener("resize",
|
|
771
|
+
window.removeEventListener("resize", _), document.removeEventListener("scroll", _, !0), m == null || m.disconnect(), d.current && (window.cancelAnimationFrame(d.current), d.current = 0);
|
|
772
772
|
};
|
|
773
|
-
}, [i, c,
|
|
773
|
+
}, [i, c, _, e, t]), u;
|
|
774
774
|
}, Tn = (e, { rowHeight: t = 40, overscan: n = 6, isEnabled: r = !0 } = {}) => {
|
|
775
775
|
const o = R(null), [s, i] = P({
|
|
776
776
|
start: 0,
|
|
777
777
|
end: e,
|
|
778
778
|
totalHeight: e * t,
|
|
779
779
|
offset: 0
|
|
780
|
-
}),
|
|
780
|
+
}), u = z(() => {
|
|
781
781
|
const d = o.current, c = !r || !d || d.clientHeight === 0 ? { start: 0, end: e, totalHeight: e * t, offset: 0 } : (() => {
|
|
782
|
-
const
|
|
783
|
-
return { start: m, end:
|
|
782
|
+
const _ = Math.ceil(d.clientHeight / t), l = Math.floor(d.scrollTop / t), m = Math.max(0, l - n), w = Math.min(e, l + _ + n);
|
|
783
|
+
return { start: m, end: w, totalHeight: e * t, offset: m * t };
|
|
784
784
|
})();
|
|
785
785
|
i(
|
|
786
|
-
(
|
|
786
|
+
(_) => _.start === c.start && _.end === c.end && _.totalHeight === c.totalHeight && _.offset === c.offset ? _ : c
|
|
787
787
|
);
|
|
788
788
|
}, [e, r, n, t]);
|
|
789
|
-
S(
|
|
789
|
+
S(u), S(() => {
|
|
790
790
|
const d = o.current;
|
|
791
791
|
if (!d) return;
|
|
792
|
-
d.addEventListener("scroll",
|
|
793
|
-
const c = typeof ResizeObserver > "u" ? null : new ResizeObserver(
|
|
792
|
+
d.addEventListener("scroll", u, { passive: !0 });
|
|
793
|
+
const c = typeof ResizeObserver > "u" ? null : new ResizeObserver(u);
|
|
794
794
|
return c == null || c.observe(d), () => {
|
|
795
|
-
d.removeEventListener("scroll",
|
|
795
|
+
d.removeEventListener("scroll", u), c == null || c.disconnect();
|
|
796
796
|
};
|
|
797
|
-
}, [
|
|
798
|
-
const
|
|
797
|
+
}, [u]);
|
|
798
|
+
const h = z(
|
|
799
799
|
(d) => {
|
|
800
800
|
const c = o.current;
|
|
801
801
|
if (!c || !r) return;
|
|
802
|
-
const
|
|
803
|
-
|
|
802
|
+
const _ = d * t, l = _ + t;
|
|
803
|
+
_ < c.scrollTop ? c.scrollTop = _ : l > c.scrollTop + c.clientHeight && (c.scrollTop = l - c.clientHeight);
|
|
804
804
|
},
|
|
805
805
|
[r, t]
|
|
806
806
|
);
|
|
807
|
-
return { scrollRef: o, range: s, scrollToIndex:
|
|
807
|
+
return { scrollRef: o, range: s, scrollToIndex: h, measure: u };
|
|
808
808
|
};
|
|
809
809
|
let $t = 0, Ee = null;
|
|
810
810
|
const Cn = () => /iP(hone|ad|od)/.test(navigator.platform) || navigator.platform === "MacIntel" && navigator.maxTouchPoints > 1, En = () => {
|
|
@@ -907,7 +907,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
907
907
|
t >= 0 && Dt.splice(t, 1);
|
|
908
908
|
}
|
|
909
909
|
};
|
|
910
|
-
}, Gt = (e) => Dt[Dt.length - 1] === e,
|
|
910
|
+
}, Gt = (e) => Dt[Dt.length - 1] === e, v = (...e) => {
|
|
911
911
|
let t = "";
|
|
912
912
|
for (const n of e)
|
|
913
913
|
n && (t = t === "" ? n : `${t} ${n}`);
|
|
@@ -929,7 +929,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
929
929
|
"spinner--lg": "hanui-spinner--lg-K9k-Z"
|
|
930
930
|
}, Hn = ({ size: e = "md", label: t, className: n }) => {
|
|
931
931
|
const { labels: r } = j();
|
|
932
|
-
return /* @__PURE__ */ a("span", { className:
|
|
932
|
+
return /* @__PURE__ */ a("span", { className: v(Jt.spinner, Jt[`spinner--${e}`], n), role: "status", children: /* @__PURE__ */ a("span", { className: Jt.spinner__label, children: t ?? H("Spinner.label", r == null ? void 0 : r.loading) }) });
|
|
933
933
|
}, Xa = /* @__PURE__ */ I(Hn), Kn = "hanui-button-SRu4R", Un = "hanui-button__icon-giom6", qn = "hanui-button__spinner-vexVG", jn = "hanui-button__label-qiMHm", $e = {
|
|
934
934
|
button: Kn,
|
|
935
935
|
button__icon: Un,
|
|
@@ -957,15 +957,15 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
957
957
|
startIcon: o,
|
|
958
958
|
endIcon: s,
|
|
959
959
|
className: i,
|
|
960
|
-
children:
|
|
961
|
-
disabled:
|
|
960
|
+
children: u,
|
|
961
|
+
disabled: h,
|
|
962
962
|
href: d,
|
|
963
963
|
isExternal: c,
|
|
964
|
-
linkProps:
|
|
965
|
-
testId:
|
|
964
|
+
linkProps: _,
|
|
965
|
+
testId: l,
|
|
966
966
|
...m
|
|
967
|
-
},
|
|
968
|
-
const b =
|
|
967
|
+
}, w) => {
|
|
968
|
+
const b = v(
|
|
969
969
|
$e.button,
|
|
970
970
|
$e[`button--${e.toLowerCase()}`],
|
|
971
971
|
$e[`button--${t.toLowerCase()}`],
|
|
@@ -975,7 +975,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
975
975
|
), p = /* @__PURE__ */ g(fe, { children: [
|
|
976
976
|
n && /* @__PURE__ */ a(Xa, { size: "sm", className: $e.button__spinner, label: "" }),
|
|
977
977
|
!n && o && /* @__PURE__ */ a("span", { className: $e.button__icon, children: o }),
|
|
978
|
-
/* @__PURE__ */ a("span", { className: $e.button__label, children:
|
|
978
|
+
/* @__PURE__ */ a("span", { className: $e.button__label, children: u }),
|
|
979
979
|
s && /* @__PURE__ */ a("span", { className: $e.button__icon, children: s })
|
|
980
980
|
] });
|
|
981
981
|
return d && c ? /* @__PURE__ */ a(
|
|
@@ -986,17 +986,17 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
986
986
|
target: "_blank",
|
|
987
987
|
rel: "noopener noreferrer",
|
|
988
988
|
"aria-label": m["aria-label"],
|
|
989
|
-
"data-testid":
|
|
989
|
+
"data-testid": l,
|
|
990
990
|
children: p
|
|
991
991
|
}
|
|
992
|
-
) : d ? /* @__PURE__ */ a(ke, { href: d, className: b, "data-testid":
|
|
992
|
+
) : d ? /* @__PURE__ */ a(ke, { href: d, className: b, "data-testid": l, ..._, children: p }) : /* @__PURE__ */ a(
|
|
993
993
|
"button",
|
|
994
994
|
{
|
|
995
|
-
ref:
|
|
995
|
+
ref: w,
|
|
996
996
|
className: b,
|
|
997
|
-
disabled:
|
|
997
|
+
disabled: h || n,
|
|
998
998
|
"aria-busy": n,
|
|
999
|
-
"data-testid":
|
|
999
|
+
"data-testid": l,
|
|
1000
1000
|
...m,
|
|
1001
1001
|
children: p
|
|
1002
1002
|
}
|
|
@@ -1020,11 +1020,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1020
1020
|
className: o,
|
|
1021
1021
|
type: s = "button",
|
|
1022
1022
|
href: i,
|
|
1023
|
-
linkProps:
|
|
1024
|
-
testId:
|
|
1023
|
+
linkProps: u,
|
|
1024
|
+
testId: h,
|
|
1025
1025
|
...d
|
|
1026
1026
|
}, c) => {
|
|
1027
|
-
const
|
|
1027
|
+
const _ = v(
|
|
1028
1028
|
Zt.iconButton,
|
|
1029
1029
|
Zt[`iconButton--${n}`],
|
|
1030
1030
|
Zt[`iconButton--${r}`],
|
|
@@ -1034,11 +1034,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1034
1034
|
ke,
|
|
1035
1035
|
{
|
|
1036
1036
|
href: i,
|
|
1037
|
-
className:
|
|
1037
|
+
className: _,
|
|
1038
1038
|
"aria-label": t,
|
|
1039
1039
|
title: d.title,
|
|
1040
|
-
"data-testid":
|
|
1041
|
-
...
|
|
1040
|
+
"data-testid": h,
|
|
1041
|
+
...u,
|
|
1042
1042
|
children: e
|
|
1043
1043
|
}
|
|
1044
1044
|
) : /* @__PURE__ */ a(
|
|
@@ -1046,9 +1046,9 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1046
1046
|
{
|
|
1047
1047
|
ref: c,
|
|
1048
1048
|
type: s,
|
|
1049
|
-
className:
|
|
1049
|
+
className: _,
|
|
1050
1050
|
"aria-label": t,
|
|
1051
|
-
"data-testid":
|
|
1051
|
+
"data-testid": h,
|
|
1052
1052
|
...d,
|
|
1053
1053
|
children: e
|
|
1054
1054
|
}
|
|
@@ -1056,9 +1056,9 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1056
1056
|
}
|
|
1057
1057
|
), Re = /* @__PURE__ */ I(
|
|
1058
1058
|
/* @__PURE__ */ F(Xn, "IconButton")
|
|
1059
|
-
),
|
|
1060
|
-
link:
|
|
1061
|
-
link__label:
|
|
1059
|
+
), Wn = "hanui-link-WBmXY", Qn = "hanui-link__label--OEu-", Jn = "hanui-link__arrow-JKXm-", gt = {
|
|
1060
|
+
link: Wn,
|
|
1061
|
+
link__label: Qn,
|
|
1062
1062
|
link__arrow: Jn,
|
|
1063
1063
|
"link--sm": "hanui-link--sm-a-3Dz",
|
|
1064
1064
|
"link--md": "hanui-link--md-lZdYP",
|
|
@@ -1072,14 +1072,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1072
1072
|
size: o = "md",
|
|
1073
1073
|
className: s,
|
|
1074
1074
|
linkProps: i,
|
|
1075
|
-
...
|
|
1075
|
+
...u
|
|
1076
1076
|
}) => /* @__PURE__ */ g(
|
|
1077
1077
|
ke,
|
|
1078
1078
|
{
|
|
1079
1079
|
href: e,
|
|
1080
|
-
className:
|
|
1080
|
+
className: v(gt.link, gt[`link--${r}`], gt[`link--${o}`], s),
|
|
1081
1081
|
...i,
|
|
1082
|
-
...
|
|
1082
|
+
...u,
|
|
1083
1083
|
children: [
|
|
1084
1084
|
/* @__PURE__ */ a("span", { className: gt.link__label, children: t }),
|
|
1085
1085
|
n && /* @__PURE__ */ a(_n, { "aria-hidden": !0, className: gt.link__arrow })
|
|
@@ -1097,76 +1097,76 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1097
1097
|
"bubble--right": "hanui-bubble--right-EQjUT",
|
|
1098
1098
|
"hanui-fade-in": "hanui-hanui-fade-in-wwrDx"
|
|
1099
1099
|
}, ar = 120, nr = 500, rr = ({ content: e, children: t, side: n, position: r, openDelay: o = 300, className: s }) => {
|
|
1100
|
-
const [i,
|
|
1100
|
+
const [i, u] = P(!1), h = J(), d = n ?? r ?? "top", c = R(null), _ = R(null), l = R(0), m = R(0), w = Ut(c, _, {
|
|
1101
1101
|
side: d,
|
|
1102
1102
|
align: "center",
|
|
1103
1103
|
isOpen: i
|
|
1104
1104
|
}), b = z(() => {
|
|
1105
|
-
|
|
1105
|
+
l.current && window.clearTimeout(l.current), l.current = 0;
|
|
1106
1106
|
}, []), p = z(
|
|
1107
|
-
(
|
|
1108
|
-
b(),
|
|
1107
|
+
(f) => {
|
|
1108
|
+
b(), l.current = window.setTimeout(() => u(!0), f);
|
|
1109
1109
|
},
|
|
1110
1110
|
[b]
|
|
1111
1111
|
), y = z(
|
|
1112
|
-
(
|
|
1113
|
-
b(),
|
|
1112
|
+
(f = ar) => {
|
|
1113
|
+
b(), l.current = window.setTimeout(() => u(!1), f);
|
|
1114
1114
|
},
|
|
1115
1115
|
[b]
|
|
1116
1116
|
);
|
|
1117
1117
|
S(() => b, [b]), S(() => {
|
|
1118
1118
|
if (!i) return;
|
|
1119
|
-
const
|
|
1119
|
+
const f = ($) => {
|
|
1120
1120
|
$.key === "Escape" && y(0);
|
|
1121
1121
|
};
|
|
1122
|
-
return document.addEventListener("keydown",
|
|
1122
|
+
return document.addEventListener("keydown", f), () => document.removeEventListener("keydown", f);
|
|
1123
1123
|
}, [i, y]), S(() => {
|
|
1124
1124
|
if (!i) return;
|
|
1125
|
-
const
|
|
1125
|
+
const f = ($) => {
|
|
1126
1126
|
var k;
|
|
1127
1127
|
$.pointerType !== "mouse" && ((k = c.current) != null && k.contains($.target) || y(0));
|
|
1128
1128
|
};
|
|
1129
|
-
return document.addEventListener("pointerdown",
|
|
1129
|
+
return document.addEventListener("pointerdown", f), () => document.removeEventListener("pointerdown", f);
|
|
1130
1130
|
}, [i, y]);
|
|
1131
1131
|
const D = () => {
|
|
1132
1132
|
m.current && window.clearTimeout(m.current), m.current = 0;
|
|
1133
|
-
}, N = (
|
|
1134
|
-
|
|
1133
|
+
}, N = (f) => {
|
|
1134
|
+
f.pointerType !== "mouse" && (m.current = window.setTimeout(() => u(!0), nr));
|
|
1135
1135
|
};
|
|
1136
1136
|
return /* @__PURE__ */ g(fe, { children: [
|
|
1137
1137
|
/* @__PURE__ */ a(
|
|
1138
1138
|
"span",
|
|
1139
1139
|
{
|
|
1140
1140
|
ref: c,
|
|
1141
|
-
className:
|
|
1142
|
-
onPointerEnter: (
|
|
1143
|
-
onPointerLeave: (
|
|
1144
|
-
D(),
|
|
1141
|
+
className: v(Rt.tooltip, s),
|
|
1142
|
+
onPointerEnter: (f) => f.pointerType === "mouse" && p(o),
|
|
1143
|
+
onPointerLeave: (f) => {
|
|
1144
|
+
D(), f.pointerType === "mouse" && y();
|
|
1145
1145
|
},
|
|
1146
1146
|
onPointerDown: N,
|
|
1147
1147
|
onPointerUp: D,
|
|
1148
1148
|
onPointerCancel: D,
|
|
1149
1149
|
onFocus: () => p(0),
|
|
1150
1150
|
onBlur: () => y(0),
|
|
1151
|
-
onContextMenu: (
|
|
1152
|
-
(i || m.current) &&
|
|
1151
|
+
onContextMenu: (f) => {
|
|
1152
|
+
(i || m.current) && f.preventDefault();
|
|
1153
1153
|
},
|
|
1154
|
-
children: /* @__PURE__ */ a("span", { "aria-describedby": i ?
|
|
1154
|
+
children: /* @__PURE__ */ a("span", { "aria-describedby": i ? h : void 0, className: Rt.tooltip__trigger, children: t })
|
|
1155
1155
|
}
|
|
1156
1156
|
),
|
|
1157
1157
|
i && he() && Et(
|
|
1158
1158
|
/* @__PURE__ */ a(
|
|
1159
1159
|
"span",
|
|
1160
1160
|
{
|
|
1161
|
-
ref:
|
|
1162
|
-
id:
|
|
1161
|
+
ref: _,
|
|
1162
|
+
id: h,
|
|
1163
1163
|
role: "tooltip",
|
|
1164
|
-
className:
|
|
1164
|
+
className: v(Rt.bubble, Rt[`bubble--${w.side}`]),
|
|
1165
1165
|
style: {
|
|
1166
|
-
...
|
|
1166
|
+
...w.style,
|
|
1167
1167
|
/* Olculmeden cizilen balon bir kare boyunca sol ust kosede
|
|
1168
1168
|
parliyordu. */
|
|
1169
|
-
visibility:
|
|
1169
|
+
visibility: w.isPositioned ? "visible" : "hidden"
|
|
1170
1170
|
},
|
|
1171
1171
|
onPointerEnter: b,
|
|
1172
1172
|
onPointerLeave: () => y(),
|
|
@@ -1197,118 +1197,118 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1197
1197
|
className: s,
|
|
1198
1198
|
testId: i
|
|
1199
1199
|
}) => {
|
|
1200
|
-
const
|
|
1201
|
-
(
|
|
1202
|
-
y.length !== 0 && (c.current = pt(), b(
|
|
1200
|
+
const u = J(), h = R(null), d = R(null), c = R(null), _ = R({ text: "", at: 0 }), [l, m] = P(!1), [w, b] = P(0), p = Ut(h, d, { side: r, align: o, isOpen: l }), y = cr(t), D = z(
|
|
1201
|
+
(x) => {
|
|
1202
|
+
y.length !== 0 && (c.current = pt(), b(x === "first" ? y[0] : y[y.length - 1]), m(!0));
|
|
1203
1203
|
},
|
|
1204
1204
|
[y]
|
|
1205
1205
|
), N = z(() => {
|
|
1206
|
-
var
|
|
1207
|
-
m(!1), (
|
|
1206
|
+
var x;
|
|
1207
|
+
m(!1), (x = c.current) == null || x.call(c), c.current = null;
|
|
1208
1208
|
}, []);
|
|
1209
1209
|
S(() => {
|
|
1210
|
-
var
|
|
1211
|
-
|
|
1212
|
-
}, [
|
|
1213
|
-
if (!
|
|
1214
|
-
const
|
|
1215
|
-
var
|
|
1210
|
+
var x, M;
|
|
1211
|
+
l && ((M = (x = d.current) == null ? void 0 : x.querySelector(`[data-index="${w}"]`)) == null || M.focus({ preventScroll: !0 }));
|
|
1212
|
+
}, [l, w]), S(() => {
|
|
1213
|
+
if (!l) return;
|
|
1214
|
+
const x = (M) => {
|
|
1215
|
+
var Q, Z;
|
|
1216
1216
|
const U = M.target;
|
|
1217
|
-
(
|
|
1217
|
+
(Q = d.current) != null && Q.contains(U) || (Z = h.current) != null && Z.contains(U) || N();
|
|
1218
1218
|
};
|
|
1219
|
-
return document.addEventListener("mousedown",
|
|
1220
|
-
}, [
|
|
1221
|
-
const
|
|
1222
|
-
const U = (y.indexOf(
|
|
1219
|
+
return document.addEventListener("mousedown", x), () => document.removeEventListener("mousedown", x);
|
|
1220
|
+
}, [l, N]);
|
|
1221
|
+
const f = (x) => {
|
|
1222
|
+
const U = (y.indexOf(w) + x + y.length) % y.length;
|
|
1223
1223
|
b(y[U]);
|
|
1224
|
-
}, $ = (
|
|
1225
|
-
const M = Date.now(), U = M -
|
|
1226
|
-
|
|
1227
|
-
const
|
|
1224
|
+
}, $ = (x) => {
|
|
1225
|
+
const M = Date.now(), U = M - _.current.at > 500 ? x : _.current.text + x;
|
|
1226
|
+
_.current = { text: U, at: M };
|
|
1227
|
+
const Q = y.find(
|
|
1228
1228
|
(Z) => t[Z].label.toLocaleLowerCase("tr").startsWith(U.toLocaleLowerCase("tr"))
|
|
1229
1229
|
);
|
|
1230
|
-
|
|
1231
|
-
}, k = (
|
|
1232
|
-
switch (
|
|
1230
|
+
Q !== void 0 && b(Q);
|
|
1231
|
+
}, k = (x) => {
|
|
1232
|
+
switch (x.key) {
|
|
1233
1233
|
case "ArrowDown":
|
|
1234
|
-
|
|
1234
|
+
x.preventDefault(), f(1);
|
|
1235
1235
|
break;
|
|
1236
1236
|
case "ArrowUp":
|
|
1237
|
-
|
|
1237
|
+
x.preventDefault(), f(-1);
|
|
1238
1238
|
break;
|
|
1239
1239
|
case "Home":
|
|
1240
|
-
|
|
1240
|
+
x.preventDefault(), b(y[0]);
|
|
1241
1241
|
break;
|
|
1242
1242
|
case "End":
|
|
1243
|
-
|
|
1243
|
+
x.preventDefault(), b(y[y.length - 1]);
|
|
1244
1244
|
break;
|
|
1245
1245
|
case "Escape":
|
|
1246
|
-
|
|
1246
|
+
x.preventDefault(), N();
|
|
1247
1247
|
break;
|
|
1248
1248
|
case "Tab":
|
|
1249
1249
|
N();
|
|
1250
1250
|
break;
|
|
1251
1251
|
default:
|
|
1252
|
-
|
|
1252
|
+
x.key.length === 1 && !x.metaKey && !x.ctrlKey && $(x.key);
|
|
1253
1253
|
}
|
|
1254
|
-
}, L = (
|
|
1255
|
-
if (
|
|
1256
|
-
|
|
1254
|
+
}, L = (x) => {
|
|
1255
|
+
if (x.key === "ArrowUp") {
|
|
1256
|
+
x.preventDefault(), D("last");
|
|
1257
1257
|
return;
|
|
1258
1258
|
}
|
|
1259
|
-
["ArrowDown", "Enter", " "].includes(
|
|
1259
|
+
["ArrowDown", "Enter", " "].includes(x.key) && (x.preventDefault(), D("first"));
|
|
1260
1260
|
};
|
|
1261
1261
|
if (!La(e)) return null;
|
|
1262
1262
|
const C = e.props, E = Sa(e, {
|
|
1263
|
-
ref:
|
|
1263
|
+
ref: h,
|
|
1264
1264
|
"aria-haspopup": "menu",
|
|
1265
|
-
"aria-expanded":
|
|
1266
|
-
"aria-controls":
|
|
1267
|
-
onClick: (
|
|
1265
|
+
"aria-expanded": l,
|
|
1266
|
+
"aria-controls": l ? u : void 0,
|
|
1267
|
+
onClick: (x) => {
|
|
1268
1268
|
var M;
|
|
1269
|
-
(M = C.onClick) == null || M.call(C,
|
|
1269
|
+
(M = C.onClick) == null || M.call(C, x), l ? N() : D("first");
|
|
1270
1270
|
},
|
|
1271
|
-
onKeyDown: (
|
|
1271
|
+
onKeyDown: (x) => {
|
|
1272
1272
|
var M;
|
|
1273
|
-
(M = C.onKeyDown) == null || M.call(C,
|
|
1273
|
+
(M = C.onKeyDown) == null || M.call(C, x), l || L(x);
|
|
1274
1274
|
}
|
|
1275
1275
|
});
|
|
1276
1276
|
return /* @__PURE__ */ g(fe, { children: [
|
|
1277
1277
|
E,
|
|
1278
|
-
|
|
1278
|
+
l && he() && Et(
|
|
1279
1279
|
/* @__PURE__ */ a(
|
|
1280
1280
|
"div",
|
|
1281
1281
|
{
|
|
1282
1282
|
ref: d,
|
|
1283
|
-
id:
|
|
1283
|
+
id: u,
|
|
1284
1284
|
role: "menu",
|
|
1285
1285
|
"aria-label": n,
|
|
1286
|
-
className:
|
|
1286
|
+
className: v(ft.menu, ft[`menu--${p.side}`], s),
|
|
1287
1287
|
style: {
|
|
1288
1288
|
...p.style,
|
|
1289
1289
|
visibility: p.isPositioned ? "visible" : "hidden"
|
|
1290
1290
|
},
|
|
1291
1291
|
"data-testid": i,
|
|
1292
1292
|
onKeyDown: k,
|
|
1293
|
-
children: t.map((
|
|
1293
|
+
children: t.map((x, M) => /* @__PURE__ */ g(
|
|
1294
1294
|
"button",
|
|
1295
1295
|
{
|
|
1296
1296
|
type: "button",
|
|
1297
1297
|
role: "menuitem",
|
|
1298
1298
|
"data-index": M,
|
|
1299
|
-
tabIndex: M ===
|
|
1300
|
-
disabled:
|
|
1301
|
-
className:
|
|
1299
|
+
tabIndex: M === w ? 0 : -1,
|
|
1300
|
+
disabled: x.isDisabled,
|
|
1301
|
+
className: v(ft.menu__item, x.isDanger && ft["menu__item--danger"]),
|
|
1302
1302
|
onClick: () => {
|
|
1303
|
-
|
|
1303
|
+
x.onSelect(), N();
|
|
1304
1304
|
},
|
|
1305
|
-
onMouseEnter: () => !
|
|
1305
|
+
onMouseEnter: () => !x.isDisabled && b(M),
|
|
1306
1306
|
children: [
|
|
1307
|
-
|
|
1308
|
-
|
|
1307
|
+
x.icon && /* @__PURE__ */ a("span", { className: ft.menu__icon, "aria-hidden": !0, children: x.icon }),
|
|
1308
|
+
x.label
|
|
1309
1309
|
]
|
|
1310
1310
|
},
|
|
1311
|
-
|
|
1311
|
+
x.id
|
|
1312
1312
|
))
|
|
1313
1313
|
}
|
|
1314
1314
|
),
|
|
@@ -1332,37 +1332,37 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1332
1332
|
align: o = "start",
|
|
1333
1333
|
isOpen: s,
|
|
1334
1334
|
onOpenChange: i,
|
|
1335
|
-
className:
|
|
1336
|
-
testId:
|
|
1335
|
+
className: u,
|
|
1336
|
+
testId: h
|
|
1337
1337
|
}) => {
|
|
1338
|
-
const d = J(), c = R(null),
|
|
1338
|
+
const d = J(), c = R(null), _ = R(null), l = R(null), [m, w] = P(!1), b = s !== void 0, p = b ? s : m, y = Ut(c, _, { side: r, align: o, isOpen: p }), D = z(
|
|
1339
1339
|
($) => {
|
|
1340
|
-
b ||
|
|
1340
|
+
b || w($), i == null || i($);
|
|
1341
1341
|
},
|
|
1342
1342
|
[b, i]
|
|
1343
1343
|
);
|
|
1344
1344
|
if (S(() => {
|
|
1345
1345
|
if (!p) return;
|
|
1346
|
-
|
|
1347
|
-
const $ =
|
|
1346
|
+
l.current = pt();
|
|
1347
|
+
const $ = _.current;
|
|
1348
1348
|
return $ && jt($), () => {
|
|
1349
1349
|
var k;
|
|
1350
|
-
(k =
|
|
1350
|
+
(k = l.current) == null || k.call(l), l.current = null;
|
|
1351
1351
|
};
|
|
1352
1352
|
}, [p]), S(() => {
|
|
1353
1353
|
if (!p) return;
|
|
1354
1354
|
const $ = (L) => {
|
|
1355
1355
|
L.key === "Escape" && D(!1);
|
|
1356
1356
|
}, k = (L) => {
|
|
1357
|
-
var E,
|
|
1357
|
+
var E, x;
|
|
1358
1358
|
const C = L.target;
|
|
1359
|
-
(E =
|
|
1359
|
+
(E = _.current) != null && E.contains(C) || (x = c.current) != null && x.contains(C) || D(!1);
|
|
1360
1360
|
};
|
|
1361
1361
|
return document.addEventListener("keydown", $), document.addEventListener("mousedown", k), () => {
|
|
1362
1362
|
document.removeEventListener("keydown", $), document.removeEventListener("mousedown", k);
|
|
1363
1363
|
};
|
|
1364
1364
|
}, [p, D]), !La(e)) return null;
|
|
1365
|
-
const N = e.props,
|
|
1365
|
+
const N = e.props, f = Sa(e, {
|
|
1366
1366
|
ref: c,
|
|
1367
1367
|
"aria-expanded": p,
|
|
1368
1368
|
"aria-haspopup": "dialog",
|
|
@@ -1373,21 +1373,21 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1373
1373
|
}
|
|
1374
1374
|
});
|
|
1375
1375
|
return /* @__PURE__ */ g(fe, { children: [
|
|
1376
|
-
|
|
1376
|
+
f,
|
|
1377
1377
|
p && he() && Et(
|
|
1378
1378
|
/* @__PURE__ */ a(
|
|
1379
1379
|
"div",
|
|
1380
1380
|
{
|
|
1381
|
-
ref:
|
|
1381
|
+
ref: _,
|
|
1382
1382
|
id: d,
|
|
1383
1383
|
role: "dialog",
|
|
1384
1384
|
"aria-label": n,
|
|
1385
|
-
className:
|
|
1385
|
+
className: v($a.popover, $a[`popover--${y.side}`], u),
|
|
1386
1386
|
style: {
|
|
1387
1387
|
...y.style,
|
|
1388
1388
|
visibility: y.isPositioned ? "visible" : "hidden"
|
|
1389
1389
|
},
|
|
1390
|
-
"data-testid":
|
|
1390
|
+
"data-testid": h,
|
|
1391
1391
|
onBlur: ($) => {
|
|
1392
1392
|
var k;
|
|
1393
1393
|
$.currentTarget.contains($.relatedTarget) || (k = c.current) != null && k.contains($.relatedTarget) || D(!1);
|
|
@@ -1416,15 +1416,15 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1416
1416
|
isSelected: o,
|
|
1417
1417
|
size: s = "md",
|
|
1418
1418
|
label: i,
|
|
1419
|
-
href:
|
|
1420
|
-
linkProps:
|
|
1419
|
+
href: u,
|
|
1420
|
+
linkProps: h,
|
|
1421
1421
|
className: d,
|
|
1422
1422
|
type: c = "button",
|
|
1423
|
-
role:
|
|
1424
|
-
testId:
|
|
1423
|
+
role: _,
|
|
1424
|
+
testId: l,
|
|
1425
1425
|
...m
|
|
1426
|
-
},
|
|
1427
|
-
const b =
|
|
1426
|
+
}, w) => {
|
|
1427
|
+
const b = v(
|
|
1428
1428
|
Me.chip,
|
|
1429
1429
|
Me[`chip--${s}`],
|
|
1430
1430
|
o && Me["chip--selected"],
|
|
@@ -1436,27 +1436,27 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1436
1436
|
ut(r) && /* @__PURE__ */ a("span", { className: Me.chip__count, children: r }),
|
|
1437
1437
|
n && /* @__PURE__ */ a("span", { className: Me.chip__icon, "aria-hidden": !0, children: n })
|
|
1438
1438
|
] });
|
|
1439
|
-
return
|
|
1439
|
+
return u ? /* @__PURE__ */ a(
|
|
1440
1440
|
ke,
|
|
1441
1441
|
{
|
|
1442
|
-
href:
|
|
1442
|
+
href: u,
|
|
1443
1443
|
className: b,
|
|
1444
1444
|
"aria-label": e ? void 0 : i,
|
|
1445
1445
|
"aria-current": o ? "page" : void 0,
|
|
1446
|
-
"data-testid":
|
|
1447
|
-
...
|
|
1446
|
+
"data-testid": l,
|
|
1447
|
+
...h,
|
|
1448
1448
|
children: p
|
|
1449
1449
|
}
|
|
1450
1450
|
) : /* @__PURE__ */ a(
|
|
1451
1451
|
"button",
|
|
1452
1452
|
{
|
|
1453
|
-
ref:
|
|
1453
|
+
ref: w,
|
|
1454
1454
|
type: c,
|
|
1455
|
-
role:
|
|
1455
|
+
role: _,
|
|
1456
1456
|
className: b,
|
|
1457
1457
|
"aria-label": e ? void 0 : i,
|
|
1458
|
-
"data-testid":
|
|
1459
|
-
...
|
|
1458
|
+
"data-testid": l,
|
|
1459
|
+
..._ === "radio" ? { "aria-checked": !!o } : { "aria-pressed": !!o },
|
|
1460
1460
|
...m,
|
|
1461
1461
|
children: p
|
|
1462
1462
|
}
|
|
@@ -1473,48 +1473,48 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1473
1473
|
className: o,
|
|
1474
1474
|
...s
|
|
1475
1475
|
}) => {
|
|
1476
|
-
var
|
|
1477
|
-
const i = R(null),
|
|
1476
|
+
var _;
|
|
1477
|
+
const i = R(null), u = (l) => s.isMultiple ? s.value.includes(l) : s.value === l, h = (l) => {
|
|
1478
1478
|
if (s.isMultiple) {
|
|
1479
|
-
const m = s.value.includes(
|
|
1479
|
+
const m = s.value.includes(l) ? s.value.filter((w) => w !== l) : [...s.value, l];
|
|
1480
1480
|
s.onChange(m);
|
|
1481
1481
|
return;
|
|
1482
1482
|
}
|
|
1483
|
-
s.onChange(s.value ===
|
|
1484
|
-
}, d = (
|
|
1483
|
+
s.onChange(s.value === l ? null : l);
|
|
1484
|
+
}, d = (l) => {
|
|
1485
1485
|
var y, D;
|
|
1486
1486
|
if (s.isMultiple) return;
|
|
1487
|
-
const m =
|
|
1487
|
+
const m = l.key === "ArrowRight" || l.key === "ArrowDown" ? 1 : l.key === "ArrowLeft" || l.key === "ArrowUp" ? -1 : 0;
|
|
1488
1488
|
if (m === 0) return;
|
|
1489
|
-
|
|
1490
|
-
const
|
|
1491
|
-
if (
|
|
1492
|
-
const b =
|
|
1489
|
+
l.preventDefault();
|
|
1490
|
+
const w = e.filter((N) => !N.isDisabled);
|
|
1491
|
+
if (w.length === 0) return;
|
|
1492
|
+
const b = w.findIndex((N) => N.value === s.value), p = w[(b + m + w.length) % w.length];
|
|
1493
1493
|
s.onChange(p.value), (D = (y = i.current) == null ? void 0 : y.querySelector(`[data-chip-value="${p.value}"]`)) == null || D.focus();
|
|
1494
|
-
}, c = s.isMultiple ? null : s.value ?? ((
|
|
1494
|
+
}, c = s.isMultiple ? null : s.value ?? ((_ = e.find((l) => !l.isDisabled)) == null ? void 0 : _.value) ?? null;
|
|
1495
1495
|
return /* @__PURE__ */ a(
|
|
1496
1496
|
"div",
|
|
1497
1497
|
{
|
|
1498
1498
|
ref: i,
|
|
1499
|
-
className:
|
|
1499
|
+
className: v(Da.group, r && Da["group--scrollable"], o),
|
|
1500
1500
|
role: s.isMultiple ? "group" : "radiogroup",
|
|
1501
1501
|
"aria-label": t,
|
|
1502
1502
|
onKeyDown: d,
|
|
1503
|
-
children: e.map((
|
|
1503
|
+
children: e.map((l) => /* @__PURE__ */ a(
|
|
1504
1504
|
gr,
|
|
1505
1505
|
{
|
|
1506
1506
|
size: n,
|
|
1507
|
-
icon:
|
|
1508
|
-
count:
|
|
1509
|
-
isSelected:
|
|
1510
|
-
disabled:
|
|
1507
|
+
icon: l.icon,
|
|
1508
|
+
count: l.count,
|
|
1509
|
+
isSelected: u(l.value),
|
|
1510
|
+
disabled: l.isDisabled,
|
|
1511
1511
|
role: s.isMultiple ? void 0 : "radio",
|
|
1512
|
-
tabIndex: s.isMultiple ||
|
|
1513
|
-
"data-chip-value":
|
|
1514
|
-
onClick: () =>
|
|
1515
|
-
children:
|
|
1512
|
+
tabIndex: s.isMultiple || l.value === c ? 0 : -1,
|
|
1513
|
+
"data-chip-value": l.value,
|
|
1514
|
+
onClick: () => h(l.value),
|
|
1515
|
+
children: l.label
|
|
1516
1516
|
},
|
|
1517
|
-
|
|
1517
|
+
l.value
|
|
1518
1518
|
))
|
|
1519
1519
|
}
|
|
1520
1520
|
);
|
|
@@ -1533,24 +1533,24 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1533
1533
|
toolbar: o,
|
|
1534
1534
|
footer: s,
|
|
1535
1535
|
closeAbove: i = sa,
|
|
1536
|
-
className:
|
|
1537
|
-
testId:
|
|
1536
|
+
className: u,
|
|
1537
|
+
testId: h
|
|
1538
1538
|
}) => {
|
|
1539
|
-
const { labels: d } = j(), c = J(),
|
|
1539
|
+
const { labels: d } = j(), c = J(), _ = R(null);
|
|
1540
1540
|
Rn(), qt(), S(() => {
|
|
1541
|
-
const
|
|
1542
|
-
return
|
|
1543
|
-
p(),
|
|
1541
|
+
const w = pt(), { token: b, pop: p } = Yt();
|
|
1542
|
+
return _.current = b, () => {
|
|
1543
|
+
p(), _.current = null, w();
|
|
1544
1544
|
};
|
|
1545
1545
|
}, []), S(() => {
|
|
1546
|
-
const
|
|
1547
|
-
return
|
|
1546
|
+
const w = window.matchMedia(i);
|
|
1547
|
+
return w.addEventListener("change", n), () => w.removeEventListener("change", n);
|
|
1548
1548
|
}, [i, n]);
|
|
1549
|
-
const
|
|
1550
|
-
!
|
|
1549
|
+
const l = z((w) => {
|
|
1550
|
+
!w || w.open || (w.showModal(), jt(w, `.${qe.sheet__header} button`), ca(w));
|
|
1551
1551
|
}, []), m = z(
|
|
1552
|
-
(
|
|
1553
|
-
|
|
1552
|
+
(w) => {
|
|
1553
|
+
w.target === w.currentTarget && n();
|
|
1554
1554
|
},
|
|
1555
1555
|
[n]
|
|
1556
1556
|
);
|
|
@@ -1558,12 +1558,12 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1558
1558
|
/* @__PURE__ */ g(
|
|
1559
1559
|
"dialog",
|
|
1560
1560
|
{
|
|
1561
|
-
ref:
|
|
1562
|
-
className:
|
|
1561
|
+
ref: l,
|
|
1562
|
+
className: v(qe.sheet, u),
|
|
1563
1563
|
"aria-labelledby": c,
|
|
1564
|
-
"data-testid":
|
|
1565
|
-
onCancel: (
|
|
1566
|
-
|
|
1564
|
+
"data-testid": h,
|
|
1565
|
+
onCancel: (w) => {
|
|
1566
|
+
w.preventDefault(), !(_.current && !Gt(_.current)) && n();
|
|
1567
1567
|
},
|
|
1568
1568
|
onClick: m,
|
|
1569
1569
|
children: [
|
|
@@ -1588,7 +1588,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1588
1588
|
),
|
|
1589
1589
|
document.body
|
|
1590
1590
|
) : null;
|
|
1591
|
-
},
|
|
1591
|
+
}, Wa = /* @__PURE__ */ I(Dr), Ir = "hanui-combobox-NtZoV", Tr = "hanui-combobox__trigger-2riRR", Cr = "hanui-combobox__leadingIcon-it2xz", Er = "hanui-combobox__value-acDlr", Lr = "hanui-combobox__clear-EXOsc", Sr = "hanui-combobox__chevron-g-QzQ", Rr = "hanui-combobox__panel-srBxl", Ar = "hanui-combobox__search-THjer", Mr = "hanui-combobox__searchIcon-vr4Bg", Br = "hanui-combobox__searchInput-JPp5h", Fr = "hanui-combobox__list-p-eCs", Pr = "hanui-combobox__option-CLWh-", Or = "hanui-combobox__optionText-Zm0D6", zr = "hanui-combobox__optionLabel-WvT4W", Hr = "hanui-combobox__optionDescription-8OEzi", Kr = "hanui-combobox__check-MKlLz", Ur = "hanui-combobox__empty-mZwBq", q = {
|
|
1592
1592
|
combobox: Ir,
|
|
1593
1593
|
combobox__trigger: Tr,
|
|
1594
1594
|
"combobox__trigger--empty": "hanui-combobox__trigger--empty-RxwCq",
|
|
@@ -1623,14 +1623,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1623
1623
|
isSearchHidden: o,
|
|
1624
1624
|
onSearch: s,
|
|
1625
1625
|
isLoading: i,
|
|
1626
|
-
isDisabled:
|
|
1627
|
-
isClearable:
|
|
1626
|
+
isDisabled: u,
|
|
1627
|
+
isClearable: h,
|
|
1628
1628
|
icon: d,
|
|
1629
1629
|
id: c,
|
|
1630
|
-
className:
|
|
1631
|
-
testId:
|
|
1630
|
+
className: _,
|
|
1631
|
+
testId: l,
|
|
1632
1632
|
"aria-describedby": m,
|
|
1633
|
-
"aria-invalid":
|
|
1633
|
+
"aria-invalid": w
|
|
1634
1634
|
}) => {
|
|
1635
1635
|
var ha;
|
|
1636
1636
|
const { labels: b } = j(), p = {
|
|
@@ -1662,7 +1662,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1662
1662
|
var A;
|
|
1663
1663
|
return H("Combobox.clearLabel", r.clearLabel, (A = b == null ? void 0 : b.combobox) == null ? void 0 : A.clearLabel);
|
|
1664
1664
|
}
|
|
1665
|
-
}, y = J(), D = c ?? y, N = `${D}-listbox`,
|
|
1665
|
+
}, y = J(), D = c ?? y, N = `${D}-listbox`, f = R(null), $ = R(null), k = R(null), L = R(null), [C, E] = P(null), x = C !== null, [M, U] = P(""), [Q, Z] = P(null), Y = Tt(() => {
|
|
1666
1666
|
if (s || M.trim() === "") return e;
|
|
1667
1667
|
const A = M.trim();
|
|
1668
1668
|
return e.filter(
|
|
@@ -1672,25 +1672,25 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1672
1672
|
S(() => {
|
|
1673
1673
|
de ? Z(de.label) : t === null && Z(null);
|
|
1674
1674
|
}, [de, t]);
|
|
1675
|
-
const at = (de == null ? void 0 : de.label) ??
|
|
1675
|
+
const at = (de == null ? void 0 : de.label) ?? Q, Ne = R(s);
|
|
1676
1676
|
Ne.current = s, S(() => {
|
|
1677
|
-
if (!
|
|
1677
|
+
if (!x || !Ne.current) return;
|
|
1678
1678
|
const A = window.setTimeout(() => {
|
|
1679
1679
|
var oe;
|
|
1680
1680
|
return (oe = Ne.current) == null ? void 0 : oe.call(Ne, M.trim());
|
|
1681
1681
|
}, 300);
|
|
1682
1682
|
return () => window.clearTimeout(A);
|
|
1683
|
-
}, [M,
|
|
1683
|
+
}, [M, x]);
|
|
1684
1684
|
const Ae = z(() => {
|
|
1685
1685
|
E(null), U("");
|
|
1686
1686
|
}, []), Lt = z(() => {
|
|
1687
|
-
|
|
1688
|
-
}, [
|
|
1687
|
+
u || (E(window.matchMedia(sa).matches ? "popover" : "sheet"), U(""));
|
|
1688
|
+
}, [u]);
|
|
1689
1689
|
S(() => {
|
|
1690
1690
|
if (C !== "popover") return;
|
|
1691
1691
|
const A = (oe) => {
|
|
1692
1692
|
var pe;
|
|
1693
|
-
(pe =
|
|
1693
|
+
(pe = f.current) != null && pe.contains(oe.target) || Ae();
|
|
1694
1694
|
};
|
|
1695
1695
|
return document.addEventListener("mousedown", A), () => document.removeEventListener("mousedown", A);
|
|
1696
1696
|
}, [C, Ae]), S(() => {
|
|
@@ -1702,15 +1702,15 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1702
1702
|
}, K = R(!1);
|
|
1703
1703
|
S(() => {
|
|
1704
1704
|
var A;
|
|
1705
|
-
K.current && !
|
|
1706
|
-
}, [
|
|
1705
|
+
K.current && !x && ((A = $.current) == null || A.focus()), K.current = x;
|
|
1706
|
+
}, [x]);
|
|
1707
1707
|
const ee = Ut($, k, {
|
|
1708
1708
|
side: "bottom",
|
|
1709
1709
|
align: "start",
|
|
1710
|
-
isOpen:
|
|
1710
|
+
isOpen: x && C === "popover"
|
|
1711
1711
|
}), { activeIndex: re, setActiveIndex: nt, listRef: Za, handleKeyDown: Va } = qa({
|
|
1712
1712
|
count: Y.length,
|
|
1713
|
-
isOpen:
|
|
1713
|
+
isOpen: x,
|
|
1714
1714
|
initialIndex: Math.max(
|
|
1715
1715
|
e.findIndex((A) => A.value === t),
|
|
1716
1716
|
0
|
|
@@ -1764,7 +1764,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1764
1764
|
ref: an,
|
|
1765
1765
|
id: N,
|
|
1766
1766
|
role: "listbox",
|
|
1767
|
-
className:
|
|
1767
|
+
className: v(q.combobox__list, A && q["combobox__list--sheet"]),
|
|
1768
1768
|
children: [
|
|
1769
1769
|
Ke && Ue.offset > 0 && /* @__PURE__ */ a("li", { "aria-hidden": !0, style: { height: Ue.offset } }),
|
|
1770
1770
|
oe.map((pe, on) => {
|
|
@@ -1779,7 +1779,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1779
1779
|
"aria-posinset": Ke ? bt + 1 : void 0,
|
|
1780
1780
|
"aria-selected": Xt,
|
|
1781
1781
|
"aria-disabled": pe.isDisabled,
|
|
1782
|
-
className:
|
|
1782
|
+
className: v(
|
|
1783
1783
|
q.combobox__option,
|
|
1784
1784
|
sn && q["combobox__option--active"],
|
|
1785
1785
|
Xt && q["combobox__option--selected"],
|
|
@@ -1803,27 +1803,27 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1803
1803
|
}
|
|
1804
1804
|
);
|
|
1805
1805
|
};
|
|
1806
|
-
return /* @__PURE__ */ g("div", { ref:
|
|
1806
|
+
return /* @__PURE__ */ g("div", { ref: f, className: v(q.combobox, _), "data-testid": l, children: [
|
|
1807
1807
|
/* @__PURE__ */ g(
|
|
1808
1808
|
"button",
|
|
1809
1809
|
{
|
|
1810
1810
|
ref: $,
|
|
1811
1811
|
id: D,
|
|
1812
1812
|
type: "button",
|
|
1813
|
-
className:
|
|
1813
|
+
className: v(
|
|
1814
1814
|
q.combobox__trigger,
|
|
1815
1815
|
!at && q["combobox__trigger--empty"],
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1816
|
+
x && q["combobox__trigger--open"],
|
|
1817
|
+
w && q["combobox__trigger--invalid"],
|
|
1818
|
+
h && at && !u && q["combobox__trigger--clearable"]
|
|
1819
1819
|
),
|
|
1820
|
-
disabled:
|
|
1820
|
+
disabled: u,
|
|
1821
1821
|
"aria-haspopup": "listbox",
|
|
1822
|
-
"aria-expanded":
|
|
1823
|
-
"aria-controls":
|
|
1822
|
+
"aria-expanded": x,
|
|
1823
|
+
"aria-controls": x ? N : void 0,
|
|
1824
1824
|
"aria-label": r.placeholder,
|
|
1825
1825
|
"aria-describedby": m,
|
|
1826
|
-
onClick: () =>
|
|
1826
|
+
onClick: () => x ? Ae() : Lt(),
|
|
1827
1827
|
children: [
|
|
1828
1828
|
d && /* @__PURE__ */ a("span", { className: q.combobox__leadingIcon, "aria-hidden": !0, children: d }),
|
|
1829
1829
|
/* @__PURE__ */ a("span", { className: q.combobox__value, children: at ?? r.placeholder }),
|
|
@@ -1831,13 +1831,13 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1831
1831
|
Aa,
|
|
1832
1832
|
{
|
|
1833
1833
|
"aria-hidden": !0,
|
|
1834
|
-
className:
|
|
1834
|
+
className: v(q.combobox__chevron, x && q["combobox__chevron--open"])
|
|
1835
1835
|
}
|
|
1836
1836
|
)
|
|
1837
1837
|
]
|
|
1838
1838
|
}
|
|
1839
1839
|
),
|
|
1840
|
-
|
|
1840
|
+
h && at && !u && /* @__PURE__ */ a(
|
|
1841
1841
|
"button",
|
|
1842
1842
|
{
|
|
1843
1843
|
type: "button",
|
|
@@ -1867,7 +1867,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1867
1867
|
}
|
|
1868
1868
|
),
|
|
1869
1869
|
C === "sheet" && /* @__PURE__ */ a(
|
|
1870
|
-
|
|
1870
|
+
Wa,
|
|
1871
1871
|
{
|
|
1872
1872
|
title: r.placeholder,
|
|
1873
1873
|
closeLabel: r.closeLabel ?? (b == null ? void 0 : b.close),
|
|
@@ -1877,15 +1877,15 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1877
1877
|
}
|
|
1878
1878
|
)
|
|
1879
1879
|
] });
|
|
1880
|
-
}, pu = /* @__PURE__ */ I(jr), Yr = "hanui-segmented-qo2Bw", Gr = "hanui-segmented__item-mqRNZ", Xr = "hanui-segmented__icon-C9CT-",
|
|
1880
|
+
}, pu = /* @__PURE__ */ I(jr), Yr = "hanui-segmented-qo2Bw", Gr = "hanui-segmented__item-mqRNZ", Xr = "hanui-segmented__icon-C9CT-", Wr = "hanui-segmented__label-NVXBv", ot = {
|
|
1881
1881
|
segmented: Yr,
|
|
1882
1882
|
"segmented--sm": "hanui-segmented--sm-7tUry",
|
|
1883
1883
|
"segmented--md": "hanui-segmented--md-PiSqt",
|
|
1884
1884
|
segmented__item: Gr,
|
|
1885
1885
|
"segmented__item--selected": "hanui-segmented__item--selected-r7CLj",
|
|
1886
1886
|
segmented__icon: Xr,
|
|
1887
|
-
segmented__label:
|
|
1888
|
-
},
|
|
1887
|
+
segmented__label: Wr
|
|
1888
|
+
}, Qr = ({
|
|
1889
1889
|
options: e,
|
|
1890
1890
|
value: t,
|
|
1891
1891
|
onChange: n,
|
|
@@ -1893,44 +1893,44 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1893
1893
|
isIconOnly: o,
|
|
1894
1894
|
size: s = "md",
|
|
1895
1895
|
className: i,
|
|
1896
|
-
testId:
|
|
1896
|
+
testId: u
|
|
1897
1897
|
}) => {
|
|
1898
|
-
const
|
|
1898
|
+
const h = R(null), d = (c) => {
|
|
1899
1899
|
var b, p;
|
|
1900
|
-
const
|
|
1901
|
-
if (
|
|
1900
|
+
const _ = c.key === "ArrowRight" || c.key === "ArrowDown" ? 1 : c.key === "ArrowLeft" || c.key === "ArrowUp" ? -1 : 0;
|
|
1901
|
+
if (_ === 0) return;
|
|
1902
1902
|
c.preventDefault();
|
|
1903
|
-
const
|
|
1904
|
-
if (
|
|
1905
|
-
const m =
|
|
1906
|
-
n(
|
|
1903
|
+
const l = e.filter((y) => !y.isDisabled);
|
|
1904
|
+
if (l.length === 0) return;
|
|
1905
|
+
const m = l.findIndex((y) => y.value === t), w = l[(m + _ + l.length) % l.length];
|
|
1906
|
+
n(w.value), (p = (b = h.current) == null ? void 0 : b.querySelector(`[data-value="${w.value}"]`)) == null || p.focus({ preventScroll: !0 });
|
|
1907
1907
|
};
|
|
1908
1908
|
return /* @__PURE__ */ a(
|
|
1909
1909
|
"div",
|
|
1910
1910
|
{
|
|
1911
|
-
ref:
|
|
1911
|
+
ref: h,
|
|
1912
1912
|
role: "radiogroup",
|
|
1913
1913
|
"aria-label": r,
|
|
1914
|
-
className:
|
|
1915
|
-
"data-testid":
|
|
1914
|
+
className: v(ot.segmented, ot[`segmented--${s}`], i),
|
|
1915
|
+
"data-testid": u,
|
|
1916
1916
|
onKeyDown: d,
|
|
1917
1917
|
children: e.map((c) => {
|
|
1918
|
-
const
|
|
1918
|
+
const _ = c.value === t;
|
|
1919
1919
|
return /* @__PURE__ */ g(
|
|
1920
1920
|
"button",
|
|
1921
1921
|
{
|
|
1922
1922
|
type: "button",
|
|
1923
1923
|
role: "radio",
|
|
1924
|
-
"aria-checked":
|
|
1924
|
+
"aria-checked": _,
|
|
1925
1925
|
"aria-label": o ? c.label : void 0,
|
|
1926
1926
|
"data-value": c.value,
|
|
1927
1927
|
disabled: c.isDisabled,
|
|
1928
|
-
tabIndex:
|
|
1929
|
-
className:
|
|
1928
|
+
tabIndex: _ ? 0 : -1,
|
|
1929
|
+
className: v(
|
|
1930
1930
|
ot.segmented__item,
|
|
1931
|
-
|
|
1931
|
+
_ && ot["segmented__item--selected"]
|
|
1932
1932
|
),
|
|
1933
|
-
onClick: () => !
|
|
1933
|
+
onClick: () => !_ && n(c.value),
|
|
1934
1934
|
children: [
|
|
1935
1935
|
c.icon && /* @__PURE__ */ a("span", { className: ot.segmented__icon, "aria-hidden": !0, children: c.icon }),
|
|
1936
1936
|
!o && /* @__PURE__ */ a("span", { className: ot.segmented__label, children: c.label })
|
|
@@ -1942,7 +1942,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1942
1942
|
}
|
|
1943
1943
|
);
|
|
1944
1944
|
}, mu = /* @__PURE__ */ I(
|
|
1945
|
-
/* @__PURE__ */ F(
|
|
1945
|
+
/* @__PURE__ */ F(Qr, "SegmentedControl")
|
|
1946
1946
|
), Jr = "hanui-select-tiiPL", Zr = "hanui-trigger-rHQJz", Vr = "hanui-trigger__icon-apCcx", eo = "hanui-trigger__value-ioH7K", to = "hanui-trigger__chevron-FtsIZ", ao = "hanui-panel-rGOOd", no = "hanui-list-SOKf8", ro = "hanui-option-ZDPef", oo = "hanui-option__label-SsoYB", io = "hanui-option__check-8CPSG", X = {
|
|
1947
1947
|
select: Jr,
|
|
1948
1948
|
trigger: Zr,
|
|
@@ -1973,16 +1973,16 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
1973
1973
|
placeholder: o,
|
|
1974
1974
|
closeLabel: s,
|
|
1975
1975
|
icon: i,
|
|
1976
|
-
size:
|
|
1977
|
-
align:
|
|
1976
|
+
size: u = "md",
|
|
1977
|
+
align: h = "start",
|
|
1978
1978
|
isDisabled: d,
|
|
1979
1979
|
id: c,
|
|
1980
|
-
className:
|
|
1981
|
-
testId:
|
|
1980
|
+
className: _,
|
|
1981
|
+
testId: l,
|
|
1982
1982
|
"aria-describedby": m,
|
|
1983
|
-
"aria-invalid":
|
|
1983
|
+
"aria-invalid": w
|
|
1984
1984
|
}) => {
|
|
1985
|
-
const { labels: b } = j(), p = H("Select.placeholder", o, b == null ? void 0 : b.selectPlaceholder), y = J(), D = c ?? y, N = `${D}-listbox`,
|
|
1985
|
+
const { labels: b } = j(), p = H("Select.placeholder", o, b == null ? void 0 : b.selectPlaceholder), y = J(), D = c ?? y, N = `${D}-listbox`, f = (K) => `${D}-option-${K}`, $ = R(null), k = R(null), [L, C] = P(null), E = L !== null, x = e.findIndex((K) => K.value === t), M = x >= 0 ? e[x] : null, U = z(() => C(null), []), Q = z(() => {
|
|
1986
1986
|
d || e.length === 0 || C(window.matchMedia(sa).matches ? "popover" : "sheet");
|
|
1987
1987
|
}, [d, e.length]), Z = (K) => {
|
|
1988
1988
|
K.isDisabled || (n(K.value), U());
|
|
@@ -2001,7 +2001,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2001
2001
|
const { activeIndex: de, setActiveIndex: at, listRef: Ne, handleKeyDown: Ae } = qa({
|
|
2002
2002
|
count: e.length,
|
|
2003
2003
|
isOpen: E,
|
|
2004
|
-
initialIndex:
|
|
2004
|
+
initialIndex: x >= 0 ? x : 0,
|
|
2005
2005
|
onSelect: (K) => {
|
|
2006
2006
|
const ee = e[K];
|
|
2007
2007
|
ee && Z(ee);
|
|
@@ -2014,7 +2014,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2014
2014
|
}, [L, Ne]);
|
|
2015
2015
|
const Lt = (K) => {
|
|
2016
2016
|
if (!E) {
|
|
2017
|
-
["ArrowDown", "ArrowUp", "Enter", " "].includes(K.key) && (K.preventDefault(),
|
|
2017
|
+
["ArrowDown", "ArrowUp", "Enter", " "].includes(K.key) && (K.preventDefault(), Q());
|
|
2018
2018
|
return;
|
|
2019
2019
|
}
|
|
2020
2020
|
Ae(K);
|
|
@@ -2025,21 +2025,21 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2025
2025
|
id: N,
|
|
2026
2026
|
role: "listbox",
|
|
2027
2027
|
"aria-label": r,
|
|
2028
|
-
"aria-activedescendant": K && e[de] ?
|
|
2028
|
+
"aria-activedescendant": K && e[de] ? f(de) : void 0,
|
|
2029
2029
|
tabIndex: K ? 0 : -1,
|
|
2030
|
-
className:
|
|
2030
|
+
className: v(X.list, K && X["list--sheet"]),
|
|
2031
2031
|
onKeyDown: K ? Lt : void 0,
|
|
2032
2032
|
children: e.map((ee, re) => {
|
|
2033
2033
|
const nt = ee.value === t;
|
|
2034
2034
|
return /* @__PURE__ */ g(
|
|
2035
2035
|
"li",
|
|
2036
2036
|
{
|
|
2037
|
-
id:
|
|
2037
|
+
id: f(re),
|
|
2038
2038
|
role: "option",
|
|
2039
2039
|
"data-index": re,
|
|
2040
2040
|
"aria-selected": nt,
|
|
2041
2041
|
"aria-disabled": ee.isDisabled,
|
|
2042
|
-
className:
|
|
2042
|
+
className: v(
|
|
2043
2043
|
X.option,
|
|
2044
2044
|
re === de && X["option--active"],
|
|
2045
2045
|
nt && X["option--selected"],
|
|
@@ -2057,7 +2057,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2057
2057
|
})
|
|
2058
2058
|
}
|
|
2059
2059
|
);
|
|
2060
|
-
return /* @__PURE__ */ g("span", { ref: $, className:
|
|
2060
|
+
return /* @__PURE__ */ g("span", { ref: $, className: v(X.select, _), "data-testid": l, children: [
|
|
2061
2061
|
/* @__PURE__ */ g(
|
|
2062
2062
|
"button",
|
|
2063
2063
|
{
|
|
@@ -2065,9 +2065,9 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2065
2065
|
id: D,
|
|
2066
2066
|
type: "button",
|
|
2067
2067
|
role: "combobox",
|
|
2068
|
-
className:
|
|
2068
|
+
className: v(
|
|
2069
2069
|
X.trigger,
|
|
2070
|
-
X[`trigger--${
|
|
2070
|
+
X[`trigger--${u}`],
|
|
2071
2071
|
!M && X["trigger--empty"],
|
|
2072
2072
|
E && X["trigger--open"]
|
|
2073
2073
|
),
|
|
@@ -2075,11 +2075,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2075
2075
|
"aria-haspopup": "listbox",
|
|
2076
2076
|
"aria-expanded": E,
|
|
2077
2077
|
"aria-controls": E ? N : void 0,
|
|
2078
|
-
"aria-activedescendant": L === "popover" && e[de] ?
|
|
2078
|
+
"aria-activedescendant": L === "popover" && e[de] ? f(de) : void 0,
|
|
2079
2079
|
"aria-label": r,
|
|
2080
2080
|
"aria-describedby": m,
|
|
2081
|
-
"aria-invalid":
|
|
2082
|
-
onClick: () => E ? U() :
|
|
2081
|
+
"aria-invalid": w,
|
|
2082
|
+
onClick: () => E ? U() : Q(),
|
|
2083
2083
|
onKeyDown: Lt,
|
|
2084
2084
|
children: [
|
|
2085
2085
|
i && /* @__PURE__ */ a("span", { className: X.trigger__icon, "aria-hidden": !0, children: i }),
|
|
@@ -2088,14 +2088,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2088
2088
|
Aa,
|
|
2089
2089
|
{
|
|
2090
2090
|
"aria-hidden": !0,
|
|
2091
|
-
className:
|
|
2091
|
+
className: v(X.trigger__chevron, E && X["trigger__chevron--open"])
|
|
2092
2092
|
}
|
|
2093
2093
|
)
|
|
2094
2094
|
]
|
|
2095
2095
|
}
|
|
2096
2096
|
),
|
|
2097
|
-
L === "popover" && /* @__PURE__ */ a("div", { className:
|
|
2098
|
-
L === "sheet" && /* @__PURE__ */ a(
|
|
2097
|
+
L === "popover" && /* @__PURE__ */ a("div", { className: v(X.panel, X[`panel--${h}`]), children: mt(!1) }),
|
|
2098
|
+
L === "sheet" && /* @__PURE__ */ a(Wa, { title: r, closeLabel: s ?? (b == null ? void 0 : b.close), onClose: U, children: mt(!0) })
|
|
2099
2099
|
] });
|
|
2100
2100
|
}, bu = /* @__PURE__ */ I(so), co = "hanui-checkbox-FaFCj", lo = "hanui-checkbox__input-nTHne", _o = "hanui-checkbox__body-VAEW2", uo = "hanui-checkbox__label-sSNZY", ho = "hanui-checkbox__hint-ish-J", vt = {
|
|
2101
2101
|
checkbox: co,
|
|
@@ -2104,7 +2104,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2104
2104
|
checkbox__label: uo,
|
|
2105
2105
|
checkbox__hint: ho
|
|
2106
2106
|
}, po = /* @__PURE__ */ xe(
|
|
2107
|
-
({ label: e, hint: t, className: n, testId: r, ...o }, s) => /* @__PURE__ */ g("label", { className:
|
|
2107
|
+
({ label: e, hint: t, className: n, testId: r, ...o }, s) => /* @__PURE__ */ g("label", { className: v(vt.checkbox, n), "data-testid": r, children: [
|
|
2108
2108
|
/* @__PURE__ */ a("input", { ref: s, type: "checkbox", className: vt.checkbox__input, ...o }),
|
|
2109
2109
|
/* @__PURE__ */ g("span", { className: vt.checkbox__body, children: [
|
|
2110
2110
|
/* @__PURE__ */ a("span", { className: vt.checkbox__label, children: e }),
|
|
@@ -2121,16 +2121,16 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2121
2121
|
switch__thumb: vo,
|
|
2122
2122
|
switch__text: yo
|
|
2123
2123
|
}, wo = xe(
|
|
2124
|
-
({ label: e, hint: t, isLabelFirst: n, className: r, id: o, testId: s, ...i },
|
|
2124
|
+
({ label: e, hint: t, isLabelFirst: n, className: r, id: o, testId: s, ...i }, u) => /* @__PURE__ */ g(
|
|
2125
2125
|
"label",
|
|
2126
2126
|
{
|
|
2127
|
-
className:
|
|
2127
|
+
className: v(Be.switch, n && Be["switch--labelFirst"], r),
|
|
2128
2128
|
"data-testid": s,
|
|
2129
2129
|
children: [
|
|
2130
2130
|
/* @__PURE__ */ a(
|
|
2131
2131
|
"input",
|
|
2132
2132
|
{
|
|
2133
|
-
ref:
|
|
2133
|
+
ref: u,
|
|
2134
2134
|
type: "checkbox",
|
|
2135
2135
|
role: "switch",
|
|
2136
2136
|
id: o,
|
|
@@ -2154,7 +2154,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2154
2154
|
radio__hint: Do,
|
|
2155
2155
|
radio__count: Io
|
|
2156
2156
|
}, To = /* @__PURE__ */ xe(
|
|
2157
|
-
({ label: e, hint: t, count: n, className: r, testId: o, ...s }, i) => /* @__PURE__ */ g("label", { className:
|
|
2157
|
+
({ label: e, hint: t, count: n, className: r, testId: o, ...s }, i) => /* @__PURE__ */ g("label", { className: v(it.radio, r), "data-testid": o, children: [
|
|
2158
2158
|
/* @__PURE__ */ a("input", { ref: i, type: "radio", className: it.radio__input, ...s }),
|
|
2159
2159
|
/* @__PURE__ */ g("span", { className: it.radio__body, children: [
|
|
2160
2160
|
/* @__PURE__ */ a("span", { className: it.radio__label, children: e }),
|
|
@@ -2177,24 +2177,24 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2177
2177
|
onChange: o,
|
|
2178
2178
|
children: s,
|
|
2179
2179
|
className: i,
|
|
2180
|
-
id:
|
|
2181
|
-
testId:
|
|
2180
|
+
id: u,
|
|
2181
|
+
testId: h
|
|
2182
2182
|
}) => /* @__PURE__ */ g(
|
|
2183
2183
|
"label",
|
|
2184
2184
|
{
|
|
2185
|
-
className:
|
|
2185
|
+
className: v(
|
|
2186
2186
|
st.radioCard,
|
|
2187
2187
|
n && st["radioCard--selected"],
|
|
2188
2188
|
r && st["radioCard--disabled"],
|
|
2189
2189
|
i
|
|
2190
2190
|
),
|
|
2191
|
-
"data-testid":
|
|
2191
|
+
"data-testid": h,
|
|
2192
2192
|
children: [
|
|
2193
2193
|
/* @__PURE__ */ a(
|
|
2194
2194
|
"input",
|
|
2195
2195
|
{
|
|
2196
2196
|
type: "radio",
|
|
2197
|
-
id:
|
|
2197
|
+
id: u,
|
|
2198
2198
|
name: e,
|
|
2199
2199
|
value: t,
|
|
2200
2200
|
checked: n,
|
|
@@ -2224,28 +2224,28 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2224
2224
|
onChange: o,
|
|
2225
2225
|
onCommit: s,
|
|
2226
2226
|
formatValue: i = String,
|
|
2227
|
-
label:
|
|
2228
|
-
minLabel:
|
|
2227
|
+
label: u,
|
|
2228
|
+
minLabel: h,
|
|
2229
2229
|
maxLabel: d,
|
|
2230
2230
|
isDisabled: c,
|
|
2231
|
-
className:
|
|
2232
|
-
testId:
|
|
2231
|
+
className: _,
|
|
2232
|
+
testId: l
|
|
2233
2233
|
}) => {
|
|
2234
|
-
var E,
|
|
2235
|
-
const { labels: m } = j(),
|
|
2234
|
+
var E, x;
|
|
2235
|
+
const { labels: m } = j(), w = H("RangeSlider.minLabel", h, (E = m == null ? void 0 : m.range) == null ? void 0 : E.min), b = H("RangeSlider.maxLabel", d, (x = m == null ? void 0 : m.range) == null ? void 0 : x.max), [p, y] = r, D = z(
|
|
2236
2236
|
(M) => o([Math.min(M, y), y]),
|
|
2237
2237
|
[y, o]
|
|
2238
2238
|
), N = z(
|
|
2239
2239
|
(M) => o([p, Math.max(M, p)]),
|
|
2240
2240
|
[p, o]
|
|
2241
|
-
),
|
|
2241
|
+
), f = z(() => s == null ? void 0 : s([p, y]), [p, y, s]), $ = t - e, k = $ === 0 ? 0 : pa(p - e, $), L = $ === 0 ? 0 : pa(y - e, $), C = k > 50;
|
|
2242
2242
|
return /* @__PURE__ */ g(
|
|
2243
2243
|
"div",
|
|
2244
2244
|
{
|
|
2245
|
-
className:
|
|
2245
|
+
className: v(me.range, c && me["range--disabled"], _),
|
|
2246
2246
|
role: "group",
|
|
2247
|
-
"aria-label":
|
|
2248
|
-
"data-testid":
|
|
2247
|
+
"aria-label": u,
|
|
2248
|
+
"data-testid": l,
|
|
2249
2249
|
children: [
|
|
2250
2250
|
/* @__PURE__ */ g("div", { className: me.range__readout, children: [
|
|
2251
2251
|
/* @__PURE__ */ a("span", { className: me.range__value, children: i(p) }),
|
|
@@ -2272,11 +2272,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2272
2272
|
step: n,
|
|
2273
2273
|
value: p,
|
|
2274
2274
|
disabled: c,
|
|
2275
|
-
"aria-label": `${
|
|
2275
|
+
"aria-label": `${u} — ${w}`,
|
|
2276
2276
|
"aria-valuetext": i(p),
|
|
2277
2277
|
onChange: (M) => D(Number(M.target.value)),
|
|
2278
|
-
onPointerUp:
|
|
2279
|
-
onKeyUp:
|
|
2278
|
+
onPointerUp: f,
|
|
2279
|
+
onKeyUp: f
|
|
2280
2280
|
}
|
|
2281
2281
|
),
|
|
2282
2282
|
/* @__PURE__ */ a(
|
|
@@ -2290,11 +2290,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2290
2290
|
step: n,
|
|
2291
2291
|
value: y,
|
|
2292
2292
|
disabled: c,
|
|
2293
|
-
"aria-label": `${
|
|
2293
|
+
"aria-label": `${u} — ${b}`,
|
|
2294
2294
|
"aria-valuetext": i(y),
|
|
2295
2295
|
onChange: (M) => N(Number(M.target.value)),
|
|
2296
|
-
onPointerUp:
|
|
2297
|
-
onKeyUp:
|
|
2296
|
+
onPointerUp: f,
|
|
2297
|
+
onKeyUp: f
|
|
2298
2298
|
}
|
|
2299
2299
|
)
|
|
2300
2300
|
] }),
|
|
@@ -2315,7 +2315,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2315
2315
|
rating__input: Yo,
|
|
2316
2316
|
rating__srOnly: Go,
|
|
2317
2317
|
rating__caption: Xo
|
|
2318
|
-
},
|
|
2318
|
+
}, Wo = [1, 2, 3, 4, 5], Qo = ({
|
|
2319
2319
|
value: e,
|
|
2320
2320
|
onChange: t,
|
|
2321
2321
|
label: n,
|
|
@@ -2323,28 +2323,28 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2323
2323
|
formatStarCount: o,
|
|
2324
2324
|
isDisabled: s,
|
|
2325
2325
|
className: i,
|
|
2326
|
-
testId:
|
|
2326
|
+
testId: u
|
|
2327
2327
|
}) => {
|
|
2328
|
-
var
|
|
2329
|
-
const { labels:
|
|
2328
|
+
var w;
|
|
2329
|
+
const { labels: h } = j(), d = r ?? ((w = h == null ? void 0 : h.rating) == null ? void 0 : w.scale), c = J(), [_, l] = P(null), m = _ ?? e;
|
|
2330
2330
|
return /* @__PURE__ */ g(
|
|
2331
2331
|
"fieldset",
|
|
2332
2332
|
{
|
|
2333
|
-
className:
|
|
2333
|
+
className: v(De.rating, s && De["rating--disabled"], i),
|
|
2334
2334
|
disabled: s,
|
|
2335
|
-
"data-testid":
|
|
2335
|
+
"data-testid": u,
|
|
2336
2336
|
children: [
|
|
2337
2337
|
/* @__PURE__ */ a("legend", { className: De.rating__legend, children: n }),
|
|
2338
|
-
/* @__PURE__ */ a("div", { className: De.rating__stars, onMouseLeave: () =>
|
|
2338
|
+
/* @__PURE__ */ a("div", { className: De.rating__stars, onMouseLeave: () => l(null), children: Wo.map((b) => {
|
|
2339
2339
|
var p;
|
|
2340
2340
|
return /* @__PURE__ */ g(
|
|
2341
2341
|
"label",
|
|
2342
2342
|
{
|
|
2343
|
-
className:
|
|
2343
|
+
className: v(
|
|
2344
2344
|
De.rating__star,
|
|
2345
2345
|
m !== null && b <= m && De["rating__star--filled"]
|
|
2346
2346
|
),
|
|
2347
|
-
onMouseEnter: () =>
|
|
2347
|
+
onMouseEnter: () => l(b),
|
|
2348
2348
|
children: [
|
|
2349
2349
|
/* @__PURE__ */ a(
|
|
2350
2350
|
"input",
|
|
@@ -2361,7 +2361,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2361
2361
|
/* @__PURE__ */ g("span", { className: De.rating__srOnly, children: [
|
|
2362
2362
|
zt(
|
|
2363
2363
|
"RatingInput.formatStarCount",
|
|
2364
|
-
o ?? ((p =
|
|
2364
|
+
o ?? ((p = h == null ? void 0 : h.rating) == null ? void 0 : p.starCount),
|
|
2365
2365
|
b
|
|
2366
2366
|
),
|
|
2367
2367
|
" ",
|
|
@@ -2377,7 +2377,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2377
2377
|
]
|
|
2378
2378
|
}
|
|
2379
2379
|
);
|
|
2380
|
-
}, xu = /* @__PURE__ */ I(
|
|
2380
|
+
}, xu = /* @__PURE__ */ I(Qo), Jo = "hanui-stepper-8s5Ih", Zo = "hanui-stepper__button-h6g7d", Vo = "hanui-stepper__input-OQh5v", yt = {
|
|
2381
2381
|
stepper: Jo,
|
|
2382
2382
|
stepper__button: Zo,
|
|
2383
2383
|
stepper__input: Vo,
|
|
@@ -2391,23 +2391,23 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2391
2391
|
increaseLabel: o,
|
|
2392
2392
|
min: s = 1,
|
|
2393
2393
|
max: i = 99,
|
|
2394
|
-
isDisabled:
|
|
2395
|
-
size:
|
|
2394
|
+
isDisabled: u,
|
|
2395
|
+
size: h = "md",
|
|
2396
2396
|
className: d,
|
|
2397
2397
|
testId: c
|
|
2398
2398
|
}) => {
|
|
2399
2399
|
var p, y, D;
|
|
2400
|
-
const { labels:
|
|
2401
|
-
|
|
2402
|
-
const
|
|
2403
|
-
|
|
2400
|
+
const { labels: _ } = j(), l = H("QuantityStepper.label", n, (p = _ == null ? void 0 : _.quantity) == null ? void 0 : p.label), [m, w] = P(null), b = (N) => {
|
|
2401
|
+
w(null);
|
|
2402
|
+
const f = Number(N.replace(/\D/g, ""));
|
|
2403
|
+
f && t(Math.min(Math.max(f, s), i));
|
|
2404
2404
|
};
|
|
2405
2405
|
return /* @__PURE__ */ g(
|
|
2406
2406
|
"div",
|
|
2407
2407
|
{
|
|
2408
|
-
className:
|
|
2408
|
+
className: v(yt.stepper, yt[`stepper--${h}`], d),
|
|
2409
2409
|
role: "group",
|
|
2410
|
-
"aria-label":
|
|
2410
|
+
"aria-label": l,
|
|
2411
2411
|
"data-testid": c,
|
|
2412
2412
|
children: [
|
|
2413
2413
|
/* @__PURE__ */ a(
|
|
@@ -2416,11 +2416,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2416
2416
|
type: "button",
|
|
2417
2417
|
className: yt.stepper__button,
|
|
2418
2418
|
onClick: () => t(Math.max(e - 1, s)),
|
|
2419
|
-
disabled:
|
|
2419
|
+
disabled: u || e <= s,
|
|
2420
2420
|
"aria-label": H(
|
|
2421
2421
|
"QuantityStepper.decreaseLabel",
|
|
2422
2422
|
r,
|
|
2423
|
-
(y =
|
|
2423
|
+
(y = _ == null ? void 0 : _.quantity) == null ? void 0 : y.decrease
|
|
2424
2424
|
),
|
|
2425
2425
|
children: /* @__PURE__ */ a(Ma, { "aria-hidden": !0 })
|
|
2426
2426
|
}
|
|
@@ -2430,14 +2430,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2430
2430
|
{
|
|
2431
2431
|
className: yt.stepper__input,
|
|
2432
2432
|
value: m ?? String(e),
|
|
2433
|
-
onChange: (N) =>
|
|
2433
|
+
onChange: (N) => w(N.target.value.replace(/\D/g, "").slice(0, 2)),
|
|
2434
2434
|
onBlur: (N) => b(N.target.value),
|
|
2435
2435
|
onKeyDown: (N) => {
|
|
2436
2436
|
N.key === "Enter" && (N.preventDefault(), b(N.target.value));
|
|
2437
2437
|
},
|
|
2438
2438
|
inputMode: "numeric",
|
|
2439
|
-
disabled:
|
|
2440
|
-
"aria-label": `${
|
|
2439
|
+
disabled: u,
|
|
2440
|
+
"aria-label": `${l} (${s}-${i})`
|
|
2441
2441
|
}
|
|
2442
2442
|
),
|
|
2443
2443
|
/* @__PURE__ */ a(
|
|
@@ -2446,11 +2446,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2446
2446
|
type: "button",
|
|
2447
2447
|
className: yt.stepper__button,
|
|
2448
2448
|
onClick: () => t(Math.min(e + 1, i)),
|
|
2449
|
-
disabled:
|
|
2449
|
+
disabled: u || e >= i,
|
|
2450
2450
|
"aria-label": H(
|
|
2451
2451
|
"QuantityStepper.increaseLabel",
|
|
2452
2452
|
o,
|
|
2453
|
-
(D =
|
|
2453
|
+
(D = _ == null ? void 0 : _.quantity) == null ? void 0 : D.increase
|
|
2454
2454
|
),
|
|
2455
2455
|
children: /* @__PURE__ */ a(un, { "aria-hidden": !0 })
|
|
2456
2456
|
}
|
|
@@ -2467,7 +2467,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2467
2467
|
ref: o,
|
|
2468
2468
|
type: "checkbox",
|
|
2469
2469
|
"aria-label": e,
|
|
2470
|
-
className:
|
|
2470
|
+
className: v(ai.checkbox, t),
|
|
2471
2471
|
"data-testid": n,
|
|
2472
2472
|
...r
|
|
2473
2473
|
}
|
|
@@ -2483,13 +2483,13 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2483
2483
|
"input--hasSuffix": "hanui-input--hasSuffix-OrE5A",
|
|
2484
2484
|
"input--technical": "hanui-input--technical---DCD"
|
|
2485
2485
|
}, ci = /* @__PURE__ */ xe(
|
|
2486
|
-
({ prefix: e, suffix: t, isTechnical: n, className: r, testId: o, ...s }, i) => /* @__PURE__ */ g("span", { className:
|
|
2486
|
+
({ prefix: e, suffix: t, isTechnical: n, className: r, testId: o, ...s }, i) => /* @__PURE__ */ g("span", { className: v(je.wrapper, r), children: [
|
|
2487
2487
|
e && /* @__PURE__ */ a("span", { className: je.wrapper__prefix, "aria-hidden": !0, children: e }),
|
|
2488
2488
|
/* @__PURE__ */ a(
|
|
2489
2489
|
"input",
|
|
2490
2490
|
{
|
|
2491
2491
|
ref: i,
|
|
2492
|
-
className:
|
|
2492
|
+
className: v(
|
|
2493
2493
|
je.input,
|
|
2494
2494
|
/* `Boolean(...)`: `prefix` bir `ReactNode` ve `0` da gecerli bir
|
|
2495
2495
|
deger — `prefix &&` ifadesi o durumda dize degil sayi donuyordu. */
|
|
@@ -2519,24 +2519,24 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2519
2519
|
removeLabel: o,
|
|
2520
2520
|
separators: s = ["Enter", ","],
|
|
2521
2521
|
maxTags: i,
|
|
2522
|
-
isDisabled:
|
|
2523
|
-
id:
|
|
2522
|
+
isDisabled: u,
|
|
2523
|
+
id: h,
|
|
2524
2524
|
className: d,
|
|
2525
2525
|
testId: c,
|
|
2526
|
-
"aria-describedby":
|
|
2527
|
-
"aria-invalid":
|
|
2526
|
+
"aria-describedby": _,
|
|
2527
|
+
"aria-invalid": l
|
|
2528
2528
|
}) => {
|
|
2529
|
-
const m = J(),
|
|
2530
|
-
const
|
|
2531
|
-
if (
|
|
2532
|
-
if (e.includes(
|
|
2533
|
-
|
|
2529
|
+
const m = J(), w = h ?? m, b = R(null), p = oa(), [y, D] = P(""), [N, f] = P(null), $ = i !== void 0 && e.length >= i, k = (E) => {
|
|
2530
|
+
const x = E.trim();
|
|
2531
|
+
if (x !== "") {
|
|
2532
|
+
if (e.includes(x)) {
|
|
2533
|
+
f(x), window.setTimeout(() => f(null), 1e3), p(`${x} zaten ekli`, "assertive"), D("");
|
|
2534
2534
|
return;
|
|
2535
2535
|
}
|
|
2536
|
-
$ || (t([...e,
|
|
2536
|
+
$ || (t([...e, x]), D(""), p(`${x} eklendi`));
|
|
2537
2537
|
}
|
|
2538
2538
|
}, L = (E) => {
|
|
2539
|
-
t(e.filter((
|
|
2539
|
+
t(e.filter((x) => x !== E)), p(`${E} kaldırıldı`);
|
|
2540
2540
|
}, C = (E) => {
|
|
2541
2541
|
if (s.includes(E.key)) {
|
|
2542
2542
|
E.preventDefault(), k(y);
|
|
@@ -2547,10 +2547,10 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2547
2547
|
return /* @__PURE__ */ g(
|
|
2548
2548
|
"div",
|
|
2549
2549
|
{
|
|
2550
|
-
className:
|
|
2550
|
+
className: v(
|
|
2551
2551
|
Ye.tagInput,
|
|
2552
|
-
|
|
2553
|
-
|
|
2552
|
+
u && Ye["tagInput--disabled"],
|
|
2553
|
+
l && Ye["tagInput--invalid"],
|
|
2554
2554
|
d
|
|
2555
2555
|
),
|
|
2556
2556
|
"data-testid": c,
|
|
@@ -2562,7 +2562,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2562
2562
|
e.map((E) => /* @__PURE__ */ g(
|
|
2563
2563
|
"span",
|
|
2564
2564
|
{
|
|
2565
|
-
className:
|
|
2565
|
+
className: v(
|
|
2566
2566
|
Ye.tagInput__tag,
|
|
2567
2567
|
N === E && Ye["tagInput__tag--duplicate"]
|
|
2568
2568
|
),
|
|
@@ -2574,9 +2574,9 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2574
2574
|
type: "button",
|
|
2575
2575
|
className: Ye.tagInput__remove,
|
|
2576
2576
|
"aria-label": `${E} — ${o}`,
|
|
2577
|
-
disabled:
|
|
2578
|
-
onClick: (
|
|
2579
|
-
|
|
2577
|
+
disabled: u,
|
|
2578
|
+
onClick: (x) => {
|
|
2579
|
+
x.stopPropagation(), L(E);
|
|
2580
2580
|
},
|
|
2581
2581
|
children: /* @__PURE__ */ a(He, { "aria-hidden": !0 })
|
|
2582
2582
|
}
|
|
@@ -2589,15 +2589,15 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2589
2589
|
"input",
|
|
2590
2590
|
{
|
|
2591
2591
|
ref: b,
|
|
2592
|
-
id:
|
|
2592
|
+
id: w,
|
|
2593
2593
|
type: "text",
|
|
2594
2594
|
className: Ye.tagInput__field,
|
|
2595
2595
|
value: y,
|
|
2596
2596
|
placeholder: e.length === 0 ? r : void 0,
|
|
2597
2597
|
"aria-label": n,
|
|
2598
|
-
"aria-describedby":
|
|
2599
|
-
"aria-invalid":
|
|
2600
|
-
disabled:
|
|
2598
|
+
"aria-describedby": _,
|
|
2599
|
+
"aria-invalid": l,
|
|
2600
|
+
disabled: u || $,
|
|
2601
2601
|
onChange: (E) => D(E.target.value),
|
|
2602
2602
|
onKeyDown: C,
|
|
2603
2603
|
onBlur: () => k(y)
|
|
@@ -2621,37 +2621,37 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2621
2621
|
hasCounter: o,
|
|
2622
2622
|
maxLength: s,
|
|
2623
2623
|
value: i,
|
|
2624
|
-
defaultValue:
|
|
2625
|
-
onChange:
|
|
2624
|
+
defaultValue: u,
|
|
2625
|
+
onChange: h,
|
|
2626
2626
|
testId: d,
|
|
2627
2627
|
...c
|
|
2628
|
-
},
|
|
2629
|
-
const
|
|
2628
|
+
}, _) => {
|
|
2629
|
+
const l = R(null), [m, w] = P(String(u ?? "").length), b = i === void 0 ? m : String(i).length, p = z(
|
|
2630
2630
|
(D) => {
|
|
2631
|
-
|
|
2631
|
+
l.current = D, typeof _ == "function" ? _(D) : _ && (_.current = D);
|
|
2632
2632
|
},
|
|
2633
|
-
[
|
|
2633
|
+
[_]
|
|
2634
2634
|
);
|
|
2635
2635
|
Ea(() => {
|
|
2636
|
-
const D =
|
|
2636
|
+
const D = l.current;
|
|
2637
2637
|
if (!n || !D) return;
|
|
2638
2638
|
D.style.height = "auto";
|
|
2639
|
-
const
|
|
2640
|
-
D.style.height = `${Math.min(D.scrollHeight,
|
|
2639
|
+
const f = (Number.parseFloat(getComputedStyle(D).lineHeight) || 20) * r;
|
|
2640
|
+
D.style.height = `${Math.min(D.scrollHeight, f)}px`, D.style.overflowY = D.scrollHeight > f ? "auto" : "hidden";
|
|
2641
2641
|
}, [n, r, i, b]);
|
|
2642
2642
|
const y = s !== void 0 && b >= s * 0.9;
|
|
2643
|
-
return /* @__PURE__ */ g("div", { className:
|
|
2643
|
+
return /* @__PURE__ */ g("div", { className: v(wt.wrapper, e), "data-testid": d, children: [
|
|
2644
2644
|
/* @__PURE__ */ a(
|
|
2645
2645
|
"textarea",
|
|
2646
2646
|
{
|
|
2647
2647
|
ref: p,
|
|
2648
2648
|
rows: t,
|
|
2649
|
-
className:
|
|
2649
|
+
className: v(wt.textarea, n && wt["textarea--autoSize"]),
|
|
2650
2650
|
maxLength: s,
|
|
2651
2651
|
value: i,
|
|
2652
|
-
defaultValue:
|
|
2652
|
+
defaultValue: u,
|
|
2653
2653
|
onChange: (D) => {
|
|
2654
|
-
|
|
2654
|
+
w(D.target.value.length), h == null || h(D);
|
|
2655
2655
|
},
|
|
2656
2656
|
...c
|
|
2657
2657
|
}
|
|
@@ -2661,7 +2661,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2661
2661
|
/* @__PURE__ */ g(
|
|
2662
2662
|
"span",
|
|
2663
2663
|
{
|
|
2664
|
-
className:
|
|
2664
|
+
className: v(wt.counter, y && wt["counter--near"]),
|
|
2665
2665
|
"aria-hidden": !0,
|
|
2666
2666
|
children: [
|
|
2667
2667
|
b,
|
|
@@ -2685,7 +2685,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2685
2685
|
{
|
|
2686
2686
|
ref: o,
|
|
2687
2687
|
type: e,
|
|
2688
|
-
className:
|
|
2688
|
+
className: v(Je.dateField, t),
|
|
2689
2689
|
"data-testid": n,
|
|
2690
2690
|
...r
|
|
2691
2691
|
}
|
|
@@ -2698,21 +2698,21 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2698
2698
|
separator: o = "–",
|
|
2699
2699
|
min: s,
|
|
2700
2700
|
max: i,
|
|
2701
|
-
isSummaryVisible:
|
|
2702
|
-
isDisabled:
|
|
2701
|
+
isSummaryVisible: u,
|
|
2702
|
+
isDisabled: h,
|
|
2703
2703
|
className: d,
|
|
2704
2704
|
testId: c
|
|
2705
2705
|
}) => {
|
|
2706
|
-
const { labels:
|
|
2707
|
-
if (!
|
|
2706
|
+
const { labels: _ } = j(), l = (() => {
|
|
2707
|
+
if (!u || !(_ != null && _.locale) || e.start === "" || e.end === "") return null;
|
|
2708
2708
|
try {
|
|
2709
|
-
const m = new Intl.DateTimeFormat(
|
|
2709
|
+
const m = new Intl.DateTimeFormat(_.locale, { dateStyle: "medium" });
|
|
2710
2710
|
return `${m.format(new Date(e.start))} ${o} ${m.format(new Date(e.end))}`;
|
|
2711
2711
|
} catch {
|
|
2712
2712
|
return null;
|
|
2713
2713
|
}
|
|
2714
2714
|
})();
|
|
2715
|
-
return /* @__PURE__ */ g("div", { className:
|
|
2715
|
+
return /* @__PURE__ */ g("div", { className: v(Je.range, d), "data-testid": c, children: [
|
|
2716
2716
|
/* @__PURE__ */ g("div", { className: Je.range__row, children: [
|
|
2717
2717
|
/* @__PURE__ */ a(
|
|
2718
2718
|
ta,
|
|
@@ -2722,7 +2722,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2722
2722
|
value: e.start,
|
|
2723
2723
|
min: s,
|
|
2724
2724
|
max: e.end || i,
|
|
2725
|
-
disabled:
|
|
2725
|
+
disabled: h,
|
|
2726
2726
|
onChange: (m) => t({ ...e, start: m.target.value })
|
|
2727
2727
|
}
|
|
2728
2728
|
),
|
|
@@ -2735,12 +2735,12 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2735
2735
|
value: e.end,
|
|
2736
2736
|
min: e.start || s,
|
|
2737
2737
|
max: i,
|
|
2738
|
-
disabled:
|
|
2738
|
+
disabled: h,
|
|
2739
2739
|
onChange: (m) => t({ ...e, end: m.target.value })
|
|
2740
2740
|
}
|
|
2741
2741
|
)
|
|
2742
2742
|
] }),
|
|
2743
|
-
|
|
2743
|
+
l && /* @__PURE__ */ a("span", { className: Je.range__summary, children: l })
|
|
2744
2744
|
] });
|
|
2745
2745
|
}, Iu = /* @__PURE__ */ F(/* @__PURE__ */ I(Di), "DateRange"), Ii = "hanui-field-KKvre", Ti = "hanui-field__label-9dlYd", Ci = "hanui-field__required-hbDJk", Ei = "hanui-field__srOnly-2WQFH", Li = "hanui-field__hint-SQPiL", Si = "hanui-field__error-gLlZ-", Ri = "hanui-field__errorIcon-uA3o8", Fe = {
|
|
2746
2746
|
field: Ii,
|
|
@@ -2759,20 +2759,20 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2759
2759
|
isRequired: o,
|
|
2760
2760
|
requiredLabel: s,
|
|
2761
2761
|
isLabelHidden: i,
|
|
2762
|
-
className:
|
|
2762
|
+
className: u
|
|
2763
2763
|
}) => {
|
|
2764
|
-
const { labels:
|
|
2765
|
-
return /* @__PURE__ */ g("div", { className:
|
|
2764
|
+
const { labels: h } = j(), d = J(), c = `${d}-error`, _ = `${d}-hint`;
|
|
2765
|
+
return /* @__PURE__ */ g("div", { className: v(Fe.field, u), children: [
|
|
2766
2766
|
/* @__PURE__ */ g(
|
|
2767
2767
|
"label",
|
|
2768
2768
|
{
|
|
2769
2769
|
htmlFor: d,
|
|
2770
|
-
className:
|
|
2770
|
+
className: v(Fe.field__label, i && Fe["field__label--hidden"]),
|
|
2771
2771
|
children: [
|
|
2772
2772
|
e,
|
|
2773
2773
|
o && /* @__PURE__ */ g(fe, { children: [
|
|
2774
2774
|
/* @__PURE__ */ a("span", { className: Fe.field__required, "aria-hidden": !0, children: "*" }),
|
|
2775
|
-
/* @__PURE__ */ a("span", { className: Fe.field__srOnly, children: H("Field.requiredLabel", s,
|
|
2775
|
+
/* @__PURE__ */ a("span", { className: Fe.field__srOnly, children: H("Field.requiredLabel", s, h == null ? void 0 : h.required) })
|
|
2776
2776
|
] })
|
|
2777
2777
|
]
|
|
2778
2778
|
}
|
|
@@ -2793,13 +2793,13 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2793
2793
|
* Sira ONEMLI: once hata, sonra yardim. Ekran okuyucu bagli metinleri
|
|
2794
2794
|
* yazildiklari sirayla okuyor ve once "ne yanlis" duyulmali.
|
|
2795
2795
|
*/
|
|
2796
|
-
"aria-describedby": [r && c, n &&
|
|
2796
|
+
"aria-describedby": [r && c, n && _].filter(Boolean).join(" ") || void 0
|
|
2797
2797
|
}),
|
|
2798
2798
|
r && /* @__PURE__ */ g("p", { id: c, className: Fe.field__error, role: "alert", children: [
|
|
2799
2799
|
/* @__PURE__ */ a(Ft, { "aria-hidden": !0, className: Fe.field__errorIcon }),
|
|
2800
2800
|
r
|
|
2801
2801
|
] }),
|
|
2802
|
-
n && /* @__PURE__ */ a("p", { id:
|
|
2802
|
+
n && /* @__PURE__ */ a("p", { id: _, className: Fe.field__hint, children: n })
|
|
2803
2803
|
] });
|
|
2804
2804
|
}, Mi = /* @__PURE__ */ I(Ai), Bi = "hanui-progress-99MrX", Fi = "hanui-progress__track-Qbp9t", Pi = "hanui-progress__fill-Bam55", Oi = "hanui-progress__value-3FYxj", zi = "hanui-circle-9cn2w", Hi = "hanui-circle__svg-0IwkR", Ki = "hanui-circle__track-zY2qc", Ui = "hanui-circle__fill-Jbde6", qi = "hanui-circle__label-A3nJB", ne = {
|
|
2805
2805
|
progress: Bi,
|
|
@@ -2823,7 +2823,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2823
2823
|
"circle--indeterminate": "hanui-circle--indeterminate-cITY6",
|
|
2824
2824
|
"hanui-spin": "hanui-hanui-spin-ez3g8",
|
|
2825
2825
|
circle__label: qi
|
|
2826
|
-
},
|
|
2826
|
+
}, Qa = (e, t) => !Number.isFinite(e) || !Number.isFinite(t) || t <= 0 ? 0 : Math.min(100, Math.max(0, e / t * 100)), ji = ({
|
|
2827
2827
|
value: e,
|
|
2828
2828
|
max: t = 100,
|
|
2829
2829
|
label: n,
|
|
@@ -2831,11 +2831,11 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2831
2831
|
isValueVisible: o,
|
|
2832
2832
|
tone: s = "brand",
|
|
2833
2833
|
size: i = "md",
|
|
2834
|
-
className:
|
|
2835
|
-
testId:
|
|
2834
|
+
className: u,
|
|
2835
|
+
testId: h
|
|
2836
2836
|
}) => {
|
|
2837
|
-
const d = e === void 0, c = d ? 0 :
|
|
2838
|
-
return /* @__PURE__ */ g("div", { className:
|
|
2837
|
+
const d = e === void 0, c = d ? 0 : Qa(e, t);
|
|
2838
|
+
return /* @__PURE__ */ g("div", { className: v(ne.progress, u), "data-testid": h, children: [
|
|
2839
2839
|
/* @__PURE__ */ a(
|
|
2840
2840
|
"div",
|
|
2841
2841
|
{
|
|
@@ -2845,7 +2845,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2845
2845
|
"aria-valuemin": d ? void 0 : 0,
|
|
2846
2846
|
"aria-valuemax": d ? void 0 : 100,
|
|
2847
2847
|
"aria-valuetext": d ? void 0 : r,
|
|
2848
|
-
className:
|
|
2848
|
+
className: v(
|
|
2849
2849
|
ne.progress__track,
|
|
2850
2850
|
ne[`progress__track--${i}`],
|
|
2851
2851
|
d && ne["progress__track--indeterminate"]
|
|
@@ -2853,7 +2853,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2853
2853
|
children: /* @__PURE__ */ a(
|
|
2854
2854
|
"span",
|
|
2855
2855
|
{
|
|
2856
|
-
className:
|
|
2856
|
+
className: v(ne.progress__fill, ne[`progress__fill--${s}`]),
|
|
2857
2857
|
style: d ? void 0 : { inlineSize: `${c}%` }
|
|
2858
2858
|
}
|
|
2859
2859
|
)
|
|
@@ -2871,16 +2871,16 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2871
2871
|
isValueVisible: o,
|
|
2872
2872
|
tone: s = "brand",
|
|
2873
2873
|
size: i = 44,
|
|
2874
|
-
className:
|
|
2875
|
-
testId:
|
|
2874
|
+
className: u,
|
|
2875
|
+
testId: h
|
|
2876
2876
|
}) => {
|
|
2877
|
-
const d = e === void 0, c = d ? 25 :
|
|
2877
|
+
const d = e === void 0, c = d ? 25 : Qa(e, t), _ = Math.max(3, Math.round(i * 0.1)), l = (i - _) / 2, m = 2 * Math.PI * l;
|
|
2878
2878
|
return /* @__PURE__ */ g(
|
|
2879
2879
|
"div",
|
|
2880
2880
|
{
|
|
2881
|
-
className:
|
|
2881
|
+
className: v(ne.circle, d && ne["circle--indeterminate"], u),
|
|
2882
2882
|
style: { width: i, height: i },
|
|
2883
|
-
"data-testid":
|
|
2883
|
+
"data-testid": h,
|
|
2884
2884
|
children: [
|
|
2885
2885
|
/* @__PURE__ */ g(
|
|
2886
2886
|
"svg",
|
|
@@ -2902,20 +2902,20 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2902
2902
|
className: ne.circle__track,
|
|
2903
2903
|
cx: i / 2,
|
|
2904
2904
|
cy: i / 2,
|
|
2905
|
-
r:
|
|
2905
|
+
r: l,
|
|
2906
2906
|
fill: "none",
|
|
2907
|
-
strokeWidth:
|
|
2907
|
+
strokeWidth: _
|
|
2908
2908
|
}
|
|
2909
2909
|
),
|
|
2910
2910
|
/* @__PURE__ */ a(
|
|
2911
2911
|
"circle",
|
|
2912
2912
|
{
|
|
2913
|
-
className:
|
|
2913
|
+
className: v(ne.circle__fill, ne[`circle__fill--${s}`]),
|
|
2914
2914
|
cx: i / 2,
|
|
2915
2915
|
cy: i / 2,
|
|
2916
|
-
r:
|
|
2916
|
+
r: l,
|
|
2917
2917
|
fill: "none",
|
|
2918
|
-
strokeWidth:
|
|
2918
|
+
strokeWidth: _,
|
|
2919
2919
|
strokeDasharray: m,
|
|
2920
2920
|
strokeDashoffset: m * (1 - c / 100)
|
|
2921
2921
|
}
|
|
@@ -2930,10 +2930,10 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2930
2930
|
}, Tu = /* @__PURE__ */ F(
|
|
2931
2931
|
/* @__PURE__ */ I(Gi),
|
|
2932
2932
|
"ProgressCircle"
|
|
2933
|
-
), Xi = "hanui-upload-v1pRY",
|
|
2933
|
+
), Xi = "hanui-upload-v1pRY", Wi = "hanui-upload__drop-OpNbO", Qi = "hanui-upload__input-Tcg9-", Ji = "hanui-upload__icon-KpMkq", Zi = "hanui-upload__label-M4HJb", Vi = "hanui-upload__drag-ewSQw", es = "hanui-upload__hint-MZRJ6", ts = "hanui-upload__error-7GkCC", as = "hanui-upload__list-lbViQ", ns = "hanui-upload__file-Znp1Q", rs = "hanui-upload__fileText-EtJcs", os = "hanui-upload__fileName-ArF8-", is = "hanui-upload__fileMeta-i6sO1", ss = "hanui-upload__progress-JY2a5", W = {
|
|
2934
2934
|
upload: Xi,
|
|
2935
|
-
upload__drop:
|
|
2936
|
-
upload__input:
|
|
2935
|
+
upload__drop: Wi,
|
|
2936
|
+
upload__input: Qi,
|
|
2937
2937
|
"upload__drop--dragging": "hanui-upload__drop--dragging-YztUx",
|
|
2938
2938
|
"upload__drop--invalid": "hanui-upload__drop--invalid-JhwnL",
|
|
2939
2939
|
"upload__drop--disabled": "hanui-upload__drop--disabled-zyfUv",
|
|
@@ -2957,105 +2957,105 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
2957
2957
|
hint: o,
|
|
2958
2958
|
accept: s,
|
|
2959
2959
|
isMultiple: i,
|
|
2960
|
-
maxSize:
|
|
2961
|
-
removeLabel:
|
|
2960
|
+
maxSize: u,
|
|
2961
|
+
removeLabel: h,
|
|
2962
2962
|
dropLabel: d,
|
|
2963
2963
|
sizeErrorText: c = "{name} çok büyük (en fazla {max}).",
|
|
2964
|
-
isDisabled:
|
|
2965
|
-
error:
|
|
2964
|
+
isDisabled: _,
|
|
2965
|
+
error: l,
|
|
2966
2966
|
children: m,
|
|
2967
|
-
className:
|
|
2967
|
+
className: w,
|
|
2968
2968
|
testId: b
|
|
2969
2969
|
}) => {
|
|
2970
|
-
const p = J(), y = J(), D = R(null), N = oa(), [
|
|
2971
|
-
if (!
|
|
2972
|
-
const M = [...
|
|
2973
|
-
(Y) => c.replace("{name}", Y.name).replace("{max}", Ta(
|
|
2970
|
+
const p = J(), y = J(), D = R(null), N = oa(), [f, $] = P(!1), [k, L] = P([]), C = (x) => {
|
|
2971
|
+
if (!x || x.length === 0) return;
|
|
2972
|
+
const M = [...x], U = u === void 0 ? [] : M.filter((Y) => Y.size > u), Q = M.filter((Y) => !U.includes(Y)), Z = U.map(
|
|
2973
|
+
(Y) => c.replace("{name}", Y.name).replace("{max}", Ta(u ?? 0))
|
|
2974
2974
|
);
|
|
2975
|
-
L(Z),
|
|
2976
|
-
}, E = (
|
|
2977
|
-
|
|
2975
|
+
L(Z), Q.length > 0 && (t(Q), N(`${Q.length} dosya eklendi`)), Z.length > 0 && N(Z.join(" "), "assertive");
|
|
2976
|
+
}, E = (x) => {
|
|
2977
|
+
x.preventDefault(), $(!1), !_ && C(x.dataTransfer.files);
|
|
2978
2978
|
};
|
|
2979
|
-
return /* @__PURE__ */ g("div", { className:
|
|
2979
|
+
return /* @__PURE__ */ g("div", { className: v(W.upload, w), "data-testid": b, children: [
|
|
2980
2980
|
/* @__PURE__ */ g(
|
|
2981
2981
|
"label",
|
|
2982
2982
|
{
|
|
2983
2983
|
htmlFor: p,
|
|
2984
|
-
className:
|
|
2985
|
-
|
|
2986
|
-
|
|
2987
|
-
|
|
2988
|
-
|
|
2984
|
+
className: v(
|
|
2985
|
+
W.upload__drop,
|
|
2986
|
+
f && W["upload__drop--dragging"],
|
|
2987
|
+
_ && W["upload__drop--disabled"],
|
|
2988
|
+
l && W["upload__drop--invalid"]
|
|
2989
2989
|
),
|
|
2990
|
-
onDragOver: (
|
|
2991
|
-
|
|
2990
|
+
onDragOver: (x) => {
|
|
2991
|
+
x.preventDefault(), _ || $(!0);
|
|
2992
2992
|
},
|
|
2993
2993
|
onDragLeave: () => $(!1),
|
|
2994
2994
|
onDrop: E,
|
|
2995
2995
|
children: [
|
|
2996
|
-
/* @__PURE__ */ a(hn, { "aria-hidden": !0, className:
|
|
2997
|
-
/* @__PURE__ */ a("span", { className:
|
|
2998
|
-
/* @__PURE__ */ a("span", { className:
|
|
2999
|
-
o && /* @__PURE__ */ a("span", { id: y, className:
|
|
2996
|
+
/* @__PURE__ */ a(hn, { "aria-hidden": !0, className: W.upload__icon }),
|
|
2997
|
+
/* @__PURE__ */ a("span", { className: W.upload__label, children: r }),
|
|
2998
|
+
/* @__PURE__ */ a("span", { className: W.upload__drag, children: d }),
|
|
2999
|
+
o && /* @__PURE__ */ a("span", { id: y, className: W.upload__hint, children: o }),
|
|
3000
3000
|
/* @__PURE__ */ a(
|
|
3001
3001
|
"input",
|
|
3002
3002
|
{
|
|
3003
3003
|
ref: D,
|
|
3004
3004
|
id: p,
|
|
3005
3005
|
type: "file",
|
|
3006
|
-
className:
|
|
3006
|
+
className: W.upload__input,
|
|
3007
3007
|
accept: s,
|
|
3008
3008
|
multiple: i,
|
|
3009
|
-
disabled:
|
|
3009
|
+
disabled: _,
|
|
3010
3010
|
"aria-describedby": o ? y : void 0,
|
|
3011
|
-
"aria-invalid":
|
|
3012
|
-
onChange: (
|
|
3013
|
-
C(
|
|
3011
|
+
"aria-invalid": l ? !0 : void 0,
|
|
3012
|
+
onChange: (x) => {
|
|
3013
|
+
C(x.target.files), x.target.value = "";
|
|
3014
3014
|
}
|
|
3015
3015
|
}
|
|
3016
3016
|
)
|
|
3017
3017
|
]
|
|
3018
3018
|
}
|
|
3019
3019
|
),
|
|
3020
|
-
|
|
3020
|
+
l && /* @__PURE__ */ g("p", { className: W.upload__error, role: "alert", children: [
|
|
3021
3021
|
/* @__PURE__ */ a(Ft, { "aria-hidden": !0 }),
|
|
3022
|
-
|
|
3022
|
+
l
|
|
3023
3023
|
] }),
|
|
3024
|
-
k.map((
|
|
3024
|
+
k.map((x) => /* @__PURE__ */ g("p", { className: W.upload__error, role: "alert", children: [
|
|
3025
3025
|
/* @__PURE__ */ a(Ft, { "aria-hidden": !0 }),
|
|
3026
|
-
|
|
3027
|
-
] },
|
|
3028
|
-
e.length > 0 && /* @__PURE__ */ a("ul", { className:
|
|
3026
|
+
x
|
|
3027
|
+
] }, x)),
|
|
3028
|
+
e.length > 0 && /* @__PURE__ */ a("ul", { className: W.upload__list, children: e.map((x) => /* @__PURE__ */ g(
|
|
3029
3029
|
"li",
|
|
3030
3030
|
{
|
|
3031
|
-
className:
|
|
3031
|
+
className: v(W.upload__file, x.error && W["upload__file--error"]),
|
|
3032
3032
|
children: [
|
|
3033
|
-
/* @__PURE__ */ g("span", { className:
|
|
3034
|
-
/* @__PURE__ */ a("span", { className:
|
|
3035
|
-
/* @__PURE__ */ a("span", { className:
|
|
3033
|
+
/* @__PURE__ */ g("span", { className: W.upload__fileText, children: [
|
|
3034
|
+
/* @__PURE__ */ a("span", { className: W.upload__fileName, children: x.name }),
|
|
3035
|
+
/* @__PURE__ */ a("span", { className: W.upload__fileMeta, children: x.error ?? Ta(x.size) })
|
|
3036
3036
|
] }),
|
|
3037
|
-
|
|
3037
|
+
x.progress !== void 0 && /* @__PURE__ */ a(
|
|
3038
3038
|
Yi,
|
|
3039
3039
|
{
|
|
3040
|
-
value:
|
|
3041
|
-
label: `${
|
|
3040
|
+
value: x.progress,
|
|
3041
|
+
label: `${x.name} yükleniyor`,
|
|
3042
3042
|
size: "sm",
|
|
3043
|
-
className:
|
|
3043
|
+
className: W.upload__progress
|
|
3044
3044
|
}
|
|
3045
3045
|
),
|
|
3046
3046
|
/* @__PURE__ */ a(
|
|
3047
3047
|
Re,
|
|
3048
3048
|
{
|
|
3049
3049
|
icon: /* @__PURE__ */ a(He, { "aria-hidden": !0 }),
|
|
3050
|
-
label: `${
|
|
3050
|
+
label: `${x.name} — ${h}`,
|
|
3051
3051
|
variant: "ghost",
|
|
3052
3052
|
size: "sm",
|
|
3053
|
-
onClick: () => n(
|
|
3053
|
+
onClick: () => n(x.id)
|
|
3054
3054
|
}
|
|
3055
3055
|
)
|
|
3056
3056
|
]
|
|
3057
3057
|
},
|
|
3058
|
-
|
|
3058
|
+
x.id
|
|
3059
3059
|
)) }),
|
|
3060
3060
|
m
|
|
3061
3061
|
] });
|
|
@@ -3080,7 +3080,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3080
3080
|
}, bs = ({ children: e, tone: t = "info", title: n, action: r, className: o, testId: s }) => /* @__PURE__ */ g(
|
|
3081
3081
|
"div",
|
|
3082
3082
|
{
|
|
3083
|
-
className:
|
|
3083
|
+
className: v(Ge.alert, Ge[`alert--${t}`], o),
|
|
3084
3084
|
role: t === "danger" || t === "warning" ? "alert" : void 0,
|
|
3085
3085
|
"data-testid": s,
|
|
3086
3086
|
children: [
|
|
@@ -3118,7 +3118,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3118
3118
|
return /* @__PURE__ */ a(
|
|
3119
3119
|
"span",
|
|
3120
3120
|
{
|
|
3121
|
-
className:
|
|
3121
|
+
className: v(
|
|
3122
3122
|
At.avatar,
|
|
3123
3123
|
At[`avatar--${r}`],
|
|
3124
3124
|
/* Ton yalnizca BAS HARF madalyonunda: gorselin uzerine renk basmak
|
|
@@ -3157,7 +3157,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3157
3157
|
}) => /* @__PURE__ */ g(
|
|
3158
3158
|
"span",
|
|
3159
3159
|
{
|
|
3160
|
-
className:
|
|
3160
|
+
className: v(Mt.badge, Mt[`badge--${t}`], Mt[`badge--${n}`], o),
|
|
3161
3161
|
"data-testid": s,
|
|
3162
3162
|
children: [
|
|
3163
3163
|
r && /* @__PURE__ */ a("span", { className: Mt.badge__icon, children: r }),
|
|
@@ -3178,12 +3178,12 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3178
3178
|
className: r,
|
|
3179
3179
|
"aria-label": H("Breadcrumb.label", t, s == null ? void 0 : s.breadcrumb),
|
|
3180
3180
|
"data-testid": o,
|
|
3181
|
-
children: /* @__PURE__ */ a("ol", { className:
|
|
3182
|
-
const
|
|
3181
|
+
children: /* @__PURE__ */ a("ol", { className: v(xt.breadcrumb), children: e.map((i, u) => {
|
|
3182
|
+
const h = u === e.length - 1;
|
|
3183
3183
|
return /* @__PURE__ */ g("li", { className: xt.breadcrumb__item, children: [
|
|
3184
|
-
i.href && !
|
|
3185
|
-
!
|
|
3186
|
-
] }, `${i.label}-${
|
|
3184
|
+
i.href && !h ? /* @__PURE__ */ a(ke, { href: i.href, className: xt.breadcrumb__link, ...n, children: i.label }) : /* @__PURE__ */ a("span", { className: xt.breadcrumb__current, "aria-current": "page", children: i.label }),
|
|
3185
|
+
!h && /* @__PURE__ */ a(Kt, { "aria-hidden": !0, className: xt.breadcrumb__separator })
|
|
3186
|
+
] }, `${i.label}-${u}`);
|
|
3187
3187
|
}) })
|
|
3188
3188
|
}
|
|
3189
3189
|
);
|
|
@@ -3204,7 +3204,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3204
3204
|
}, Os = ({ children: e, isInteractive: t, as: n = "div", className: r, testId: o }) => /* @__PURE__ */ a(
|
|
3205
3205
|
n,
|
|
3206
3206
|
{
|
|
3207
|
-
className:
|
|
3207
|
+
className: v(we.card, t && we["card--interactive"], r),
|
|
3208
3208
|
"data-testid": o,
|
|
3209
3209
|
children: e
|
|
3210
3210
|
}
|
|
@@ -3213,12 +3213,12 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3213
3213
|
const i = /* @__PURE__ */ a(
|
|
3214
3214
|
"span",
|
|
3215
3215
|
{
|
|
3216
|
-
className:
|
|
3216
|
+
className: v(we.media__frame, o && we["media__frame--contained"]),
|
|
3217
3217
|
style: { aspectRatio: t },
|
|
3218
3218
|
children: e
|
|
3219
3219
|
}
|
|
3220
3220
|
);
|
|
3221
|
-
return /* @__PURE__ */ a("div", { className:
|
|
3221
|
+
return /* @__PURE__ */ a("div", { className: v(we.media, s), children: n ? (
|
|
3222
3222
|
// `tabIndex={-1}` + `aria-hidden`: aynı hedefe giden başlık bağlantısı
|
|
3223
3223
|
// zaten sekme sırasında. Görseli ikinci bir durak yapmak klavye
|
|
3224
3224
|
// gezinmesini iki katına çıkarıyor, ekran okuyucuda da aynı kayıt
|
|
@@ -3238,13 +3238,13 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3238
3238
|
}),
|
|
3239
3239
|
"CardMedia"
|
|
3240
3240
|
), Mu = /* @__PURE__ */ F(
|
|
3241
|
-
/* @__PURE__ */ I(({ children: e, position: t = "top-left", className: n }) => /* @__PURE__ */ a("div", { className:
|
|
3241
|
+
/* @__PURE__ */ I(({ children: e, position: t = "top-left", className: n }) => /* @__PURE__ */ a("div", { className: v(we.overlay, we[`overlay--${t}`], n), children: e })),
|
|
3242
3242
|
"CardOverlay"
|
|
3243
3243
|
), Bu = /* @__PURE__ */ F(
|
|
3244
|
-
/* @__PURE__ */ I(({ children: e, className: t }) => /* @__PURE__ */ a("div", { className:
|
|
3244
|
+
/* @__PURE__ */ I(({ children: e, className: t }) => /* @__PURE__ */ a("div", { className: v(we.body, t), children: e })),
|
|
3245
3245
|
"CardBody"
|
|
3246
3246
|
), Fu = /* @__PURE__ */ F(
|
|
3247
|
-
/* @__PURE__ */ I(({ children: e, className: t }) => /* @__PURE__ */ a("div", { className:
|
|
3247
|
+
/* @__PURE__ */ I(({ children: e, className: t }) => /* @__PURE__ */ a("div", { className: v(we.footer, t), children: e })),
|
|
3248
3248
|
"CardFooter"
|
|
3249
3249
|
), Pu = /* @__PURE__ */ I(Os), zs = "hanui-carousel-GJXkW", Hs = "hanui-carousel__controls-hm5ij", Ks = "hanui-carousel__arrowIcon-adFey", Us = "hanui-carousel__track-mAux5", qs = "hanui-carousel__dots-iU8RJ", js = "hanui-carousel__dot-JTLCB", Pe = {
|
|
3250
3250
|
carousel: zs,
|
|
@@ -3262,18 +3262,18 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3262
3262
|
formatDotLabel: o,
|
|
3263
3263
|
itemMinWidth: s = 240,
|
|
3264
3264
|
className: i,
|
|
3265
|
-
testId:
|
|
3265
|
+
testId: u
|
|
3266
3266
|
}) => {
|
|
3267
|
-
const
|
|
3268
|
-
const $ =
|
|
3267
|
+
const h = R(null), [d, c] = P(!1), [_, l] = P(!1), [m, w] = P(0), [b, p] = P(1), [y, D] = P(!1), N = z(() => {
|
|
3268
|
+
const $ = h.current;
|
|
3269
3269
|
if (!$) return;
|
|
3270
3270
|
const { scrollLeft: k, scrollWidth: L, clientWidth: C } = $;
|
|
3271
|
-
c(k > 1),
|
|
3271
|
+
c(k > 1), l(k + C < L - 1), w(C > 0 ? Math.round(k / C) : 0), p(C > 0 ? Math.max(1, Math.ceil(L / C)) : 1), D(
|
|
3272
3272
|
L > C && $.querySelector("a, button, input, select, textarea, [tabindex]") === null
|
|
3273
3273
|
);
|
|
3274
3274
|
}, []);
|
|
3275
3275
|
S(() => {
|
|
3276
|
-
const $ =
|
|
3276
|
+
const $ = h.current;
|
|
3277
3277
|
if (!$) return;
|
|
3278
3278
|
N(), $.addEventListener("scroll", N, { passive: !0 });
|
|
3279
3279
|
const k = typeof ResizeObserver > "u" ? null : new ResizeObserver(N);
|
|
@@ -3281,14 +3281,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3281
3281
|
$.removeEventListener("scroll", N), k == null || k.disconnect();
|
|
3282
3282
|
};
|
|
3283
3283
|
}, [N, e]);
|
|
3284
|
-
const
|
|
3284
|
+
const f = ($) => {
|
|
3285
3285
|
var k;
|
|
3286
|
-
return (k =
|
|
3287
|
-
left: $ *
|
|
3286
|
+
return (k = h.current) == null ? void 0 : k.scrollBy({
|
|
3287
|
+
left: $ * h.current.clientWidth,
|
|
3288
3288
|
behavior: "smooth"
|
|
3289
3289
|
});
|
|
3290
3290
|
};
|
|
3291
|
-
return /* @__PURE__ */ g("section", { className:
|
|
3291
|
+
return /* @__PURE__ */ g("section", { className: v(Pe.carousel, i), "aria-label": t, "data-testid": u, children: [
|
|
3292
3292
|
/* @__PURE__ */ g("div", { className: Pe.carousel__controls, children: [
|
|
3293
3293
|
/* @__PURE__ */ a(
|
|
3294
3294
|
Re,
|
|
@@ -3298,7 +3298,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3298
3298
|
variant: "outline",
|
|
3299
3299
|
size: "sm",
|
|
3300
3300
|
disabled: !d,
|
|
3301
|
-
onClick: () =>
|
|
3301
|
+
onClick: () => f(-1)
|
|
3302
3302
|
}
|
|
3303
3303
|
),
|
|
3304
3304
|
/* @__PURE__ */ a(
|
|
@@ -3308,15 +3308,15 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3308
3308
|
label: r,
|
|
3309
3309
|
variant: "outline",
|
|
3310
3310
|
size: "sm",
|
|
3311
|
-
disabled: !
|
|
3312
|
-
onClick: () =>
|
|
3311
|
+
disabled: !_,
|
|
3312
|
+
onClick: () => f(1)
|
|
3313
3313
|
}
|
|
3314
3314
|
)
|
|
3315
3315
|
] }),
|
|
3316
3316
|
/* @__PURE__ */ a(
|
|
3317
3317
|
"div",
|
|
3318
3318
|
{
|
|
3319
|
-
ref:
|
|
3319
|
+
ref: h,
|
|
3320
3320
|
className: Pe.carousel__track,
|
|
3321
3321
|
style: { "--hanui-carousel-item": `${s}px` },
|
|
3322
3322
|
tabIndex: y ? 0 : void 0,
|
|
@@ -3329,7 +3329,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3329
3329
|
"button",
|
|
3330
3330
|
{
|
|
3331
3331
|
type: "button",
|
|
3332
|
-
className:
|
|
3332
|
+
className: v(
|
|
3333
3333
|
Pe.carousel__dot,
|
|
3334
3334
|
k === m && Pe["carousel__dot--active"]
|
|
3335
3335
|
),
|
|
@@ -3337,8 +3337,8 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3337
3337
|
"aria-current": k === m ? "true" : void 0,
|
|
3338
3338
|
onClick: () => {
|
|
3339
3339
|
var L;
|
|
3340
|
-
return (L =
|
|
3341
|
-
left: k *
|
|
3340
|
+
return (L = h.current) == null ? void 0 : L.scrollTo({
|
|
3341
|
+
left: k * h.current.clientWidth,
|
|
3342
3342
|
behavior: "smooth"
|
|
3343
3343
|
});
|
|
3344
3344
|
}
|
|
@@ -3346,14 +3346,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3346
3346
|
k
|
|
3347
3347
|
)) })
|
|
3348
3348
|
] });
|
|
3349
|
-
}, Ou = /* @__PURE__ */ I(/* @__PURE__ */ F(Ys, "Carousel")), Gs = "hanui-copy-Yht5s", Xs = "hanui-copy__code-CYlCA",
|
|
3349
|
+
}, Ou = /* @__PURE__ */ I(/* @__PURE__ */ F(Ys, "Carousel")), Gs = "hanui-copy-Yht5s", Xs = "hanui-copy__code-CYlCA", Ws = "hanui-copy__button-GDdH6", Qs = "hanui-copy__srOnly-WMTNN", ct = {
|
|
3350
3350
|
copy: Gs,
|
|
3351
3351
|
"copy--sm": "hanui-copy--sm-Tjqws",
|
|
3352
3352
|
copy__code: Xs,
|
|
3353
3353
|
"copy--md": "hanui-copy--md-00rhU",
|
|
3354
|
-
copy__button:
|
|
3354
|
+
copy__button: Ws,
|
|
3355
3355
|
"copy__button--done": "hanui-copy__button--done-MujUR",
|
|
3356
|
-
copy__srOnly:
|
|
3356
|
+
copy__srOnly: Qs
|
|
3357
3357
|
}, Js = 1600, Zs = ({
|
|
3358
3358
|
value: e,
|
|
3359
3359
|
copyLabel: t,
|
|
@@ -3362,48 +3362,48 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3362
3362
|
size: o = "sm",
|
|
3363
3363
|
isReadOnly: s,
|
|
3364
3364
|
className: i,
|
|
3365
|
-
testId:
|
|
3365
|
+
testId: u
|
|
3366
3366
|
}) => {
|
|
3367
3367
|
var b, p, y;
|
|
3368
|
-
const { labels:
|
|
3369
|
-
S(() => () => window.clearTimeout(
|
|
3368
|
+
const { labels: h } = j(), [d, c] = P(!1), _ = R(null), l = R(void 0);
|
|
3369
|
+
S(() => () => window.clearTimeout(l.current), []);
|
|
3370
3370
|
const m = z(() => {
|
|
3371
|
-
const D =
|
|
3371
|
+
const D = _.current;
|
|
3372
3372
|
if (!D) return;
|
|
3373
3373
|
const N = document.createRange();
|
|
3374
3374
|
N.selectNodeContents(D);
|
|
3375
|
-
const
|
|
3376
|
-
|
|
3377
|
-
}, []),
|
|
3375
|
+
const f = window.getSelection();
|
|
3376
|
+
f == null || f.removeAllRanges(), f == null || f.addRange(N);
|
|
3377
|
+
}, []), w = z(async () => {
|
|
3378
3378
|
try {
|
|
3379
|
-
await navigator.clipboard.writeText(e), c(!0),
|
|
3379
|
+
await navigator.clipboard.writeText(e), c(!0), l.current = window.setTimeout(() => c(!1), Js);
|
|
3380
3380
|
} catch {
|
|
3381
3381
|
m();
|
|
3382
3382
|
}
|
|
3383
3383
|
}, [e, m]);
|
|
3384
|
-
return /* @__PURE__ */ g("span", { className:
|
|
3385
|
-
/* @__PURE__ */ a("span", { className: ct.copy__code, ref:
|
|
3384
|
+
return /* @__PURE__ */ g("span", { className: v(ct.copy, ct[`copy--${o}`], i), "data-testid": u, children: [
|
|
3385
|
+
/* @__PURE__ */ a("span", { className: ct.copy__code, ref: _, children: e }),
|
|
3386
3386
|
!s && /* @__PURE__ */ a(
|
|
3387
3387
|
"button",
|
|
3388
3388
|
{
|
|
3389
3389
|
type: "button",
|
|
3390
|
-
className:
|
|
3391
|
-
onClick:
|
|
3392
|
-
"aria-label": d ? n ?? zt("CopyField.copiedLabel", (b =
|
|
3390
|
+
className: v(ct.copy__button, d && ct["copy__button--done"]),
|
|
3391
|
+
onClick: w,
|
|
3392
|
+
"aria-label": d ? n ?? zt("CopyField.copiedLabel", (b = h == null ? void 0 : h.copyField) == null ? void 0 : b.copied, e) : t ?? zt("CopyField.copyLabel", (p = h == null ? void 0 : h.copyField) == null ? void 0 : p.copy, e),
|
|
3393
3393
|
children: d ? /* @__PURE__ */ a(pn, { "aria-hidden": !0 }) : /* @__PURE__ */ a(mn, { "aria-hidden": !0 })
|
|
3394
3394
|
}
|
|
3395
3395
|
),
|
|
3396
3396
|
/* @__PURE__ */ a("span", { "aria-live": "polite", className: ct.copy__srOnly, children: d ? H(
|
|
3397
3397
|
"CopyField.copiedAnnouncement",
|
|
3398
3398
|
r,
|
|
3399
|
-
(y =
|
|
3399
|
+
(y = h == null ? void 0 : h.copyField) == null ? void 0 : y.announcement
|
|
3400
3400
|
) : "" })
|
|
3401
3401
|
] });
|
|
3402
3402
|
}, zu = /* @__PURE__ */ I(Zs), Vs = "hanui-divider-RJqCw", ec = "hanui-divider__label-M8sBA", Bt = {
|
|
3403
3403
|
divider: Vs,
|
|
3404
3404
|
"divider--labelled": "hanui-divider--labelled-jZH1-",
|
|
3405
3405
|
divider__label: ec
|
|
3406
|
-
}, tc = ({ label: e, className: t }) => e ? /* @__PURE__ */ a("div", { className:
|
|
3406
|
+
}, tc = ({ label: e, className: t }) => e ? /* @__PURE__ */ a("div", { className: v(Bt.divider, Bt["divider--labelled"], t), children: /* @__PURE__ */ a("span", { className: Bt.divider__label, children: e }) }) : /* @__PURE__ */ a("hr", { className: v(Bt.divider, t) }), Hu = /* @__PURE__ */ I(tc), ac = "hanui-directory-badEd", nc = "hanui-group-i6An9", rc = "hanui-group__header-rc19c", oc = "hanui-group__label-vQTcs", ic = "hanui-group__link-es5V7", sc = "hanui-group__meta-LtC-u", cc = "hanui-group__list-YxBCG", lc = "hanui-row-3LH7X", dc = "hanui-row__name-75Wbq", _c = "hanui-row__media-AxZEh", uc = "hanui-row__marker-RYHb-", hc = "hanui-jump-vpGwB", pc = "hanui-jump__link-rRnT6", ce = {
|
|
3407
3407
|
directory: ac,
|
|
3408
3408
|
group: nc,
|
|
3409
3409
|
group__header: rc,
|
|
@@ -3417,7 +3417,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3417
3417
|
row__marker: uc,
|
|
3418
3418
|
jump: hc,
|
|
3419
3419
|
jump__link: pc
|
|
3420
|
-
}, mc = ({ children: e, className: t }) => /* @__PURE__ */ a("div", { className:
|
|
3420
|
+
}, mc = ({ children: e, className: t }) => /* @__PURE__ */ a("div", { className: v(ce.directory, t), children: e }), Ku = /* @__PURE__ */ F(
|
|
3421
3421
|
/* @__PURE__ */ I(({ label: e, href: t, linkProps: n, meta: r, children: o, id: s }) => /* @__PURE__ */ g("section", { className: ce.group, id: s, children: [
|
|
3422
3422
|
/* @__PURE__ */ g("header", { className: ce.group__header, children: [
|
|
3423
3423
|
/* @__PURE__ */ a("h2", { className: ce.group__label, children: t ? /* @__PURE__ */ a(ke, { href: t, className: ce.group__link, ...n, children: e }) : e }),
|
|
@@ -3427,7 +3427,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3427
3427
|
] })),
|
|
3428
3428
|
"DirectoryGroup"
|
|
3429
3429
|
), Uu = /* @__PURE__ */ F(
|
|
3430
|
-
/* @__PURE__ */ I(({ href: e, name: t, media: n, marker: r, linkProps: o, className: s }) => /* @__PURE__ */ a("li", { children: /* @__PURE__ */ g(ke, { href: e, className:
|
|
3430
|
+
/* @__PURE__ */ I(({ href: e, name: t, media: n, marker: r, linkProps: o, className: s }) => /* @__PURE__ */ a("li", { children: /* @__PURE__ */ g(ke, { href: e, className: v(ce.row, s), ...o, children: [
|
|
3431
3431
|
n && /* @__PURE__ */ a("span", { className: ce.row__media, children: n }),
|
|
3432
3432
|
/* @__PURE__ */ a("span", { className: ce.row__name, children: t }),
|
|
3433
3433
|
r && /* @__PURE__ */ a("span", { className: ce.row__marker, children: r })
|
|
@@ -3462,14 +3462,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3462
3462
|
secondaryAction: o,
|
|
3463
3463
|
tone: s = "empty",
|
|
3464
3464
|
size: i = "md",
|
|
3465
|
-
className:
|
|
3466
|
-
testId:
|
|
3465
|
+
className: u,
|
|
3466
|
+
testId: h
|
|
3467
3467
|
}) => /* @__PURE__ */ g(
|
|
3468
3468
|
"div",
|
|
3469
3469
|
{
|
|
3470
|
-
className:
|
|
3470
|
+
className: v(Xe.empty, Xe[`empty--${i}`], Xe[`empty--${s}`], u),
|
|
3471
3471
|
role: s === "error" ? "alert" : void 0,
|
|
3472
|
-
"data-testid":
|
|
3472
|
+
"data-testid": h,
|
|
3473
3473
|
children: [
|
|
3474
3474
|
n && /* @__PURE__ */ a("span", { className: Xe.empty__icon, children: n }),
|
|
3475
3475
|
/* @__PURE__ */ a("h3", { className: Xe.empty__title, children: e }),
|
|
@@ -3499,16 +3499,16 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3499
3499
|
breadcrumb: o,
|
|
3500
3500
|
meta: s,
|
|
3501
3501
|
children: i,
|
|
3502
|
-
as:
|
|
3503
|
-
className:
|
|
3502
|
+
as: u = "h1",
|
|
3503
|
+
className: h,
|
|
3504
3504
|
testId: d
|
|
3505
|
-
}) => /* @__PURE__ */ g("header", { className:
|
|
3505
|
+
}) => /* @__PURE__ */ g("header", { className: v(ve.header, h), "data-testid": d, children: [
|
|
3506
3506
|
o && /* @__PURE__ */ a("div", { className: ve.header__breadcrumb, children: o }),
|
|
3507
3507
|
/* @__PURE__ */ g("div", { className: ve.header__top, children: [
|
|
3508
3508
|
/* @__PURE__ */ g("div", { className: ve.header__text, children: [
|
|
3509
3509
|
t && /* @__PURE__ */ a("span", { className: ve.header__eyebrow, children: t }),
|
|
3510
3510
|
/* @__PURE__ */ g("div", { className: ve.header__titleRow, children: [
|
|
3511
|
-
/* @__PURE__ */ a(
|
|
3511
|
+
/* @__PURE__ */ a(u, { className: ve.header__title, children: e }),
|
|
3512
3512
|
s && /* @__PURE__ */ a("span", { className: ve.header__meta, children: s })
|
|
3513
3513
|
] }),
|
|
3514
3514
|
n && /* @__PURE__ */ a("p", { className: ve.header__description, children: n })
|
|
@@ -3542,12 +3542,12 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3542
3542
|
icon: o,
|
|
3543
3543
|
isFlush: s,
|
|
3544
3544
|
gap: i = "md",
|
|
3545
|
-
footer:
|
|
3546
|
-
as:
|
|
3545
|
+
footer: u,
|
|
3546
|
+
as: h = "section",
|
|
3547
3547
|
className: d,
|
|
3548
3548
|
bodyClassName: c,
|
|
3549
|
-
testId:
|
|
3550
|
-
}) => /* @__PURE__ */ g(
|
|
3549
|
+
testId: _
|
|
3550
|
+
}) => /* @__PURE__ */ g(h, { className: v(V.panel, d), "data-testid": _, children: [
|
|
3551
3551
|
(t || r) && /* @__PURE__ */ g("div", { className: V.panel__header, children: [
|
|
3552
3552
|
/* @__PURE__ */ g("div", { className: V.panel__heading, children: [
|
|
3553
3553
|
o && /* @__PURE__ */ a("span", { className: V.panel__icon, children: o }),
|
|
@@ -3561,7 +3561,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3561
3561
|
/* @__PURE__ */ a(
|
|
3562
3562
|
"div",
|
|
3563
3563
|
{
|
|
3564
|
-
className:
|
|
3564
|
+
className: v(
|
|
3565
3565
|
V.panel__body,
|
|
3566
3566
|
V[`panel__body--${i}`],
|
|
3567
3567
|
s && V["panel__body--flush"],
|
|
@@ -3570,18 +3570,18 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3570
3570
|
children: e
|
|
3571
3571
|
}
|
|
3572
3572
|
),
|
|
3573
|
-
|
|
3573
|
+
u && /* @__PURE__ */ a("div", { className: V.panel__footer, children: /* @__PURE__ */ a("div", { className: V.panel__footerInner, children: u }) })
|
|
3574
3574
|
] }), Xu = /* @__PURE__ */ F(
|
|
3575
|
-
/* @__PURE__ */ I(({ children: e, columns: t = 1, className: n }) => /* @__PURE__ */ a("div", { className:
|
|
3575
|
+
/* @__PURE__ */ I(({ children: e, columns: t = 1, className: n }) => /* @__PURE__ */ a("div", { className: v(V.form, V[`form--${t}`], n), children: e })),
|
|
3576
3576
|
"PanelForm"
|
|
3577
|
-
),
|
|
3578
|
-
/* @__PURE__ */ I(({ children: e, className: t }) => /* @__PURE__ */ a("div", { className:
|
|
3577
|
+
), Wu = /* @__PURE__ */ F(
|
|
3578
|
+
/* @__PURE__ */ I(({ children: e, className: t }) => /* @__PURE__ */ a("div", { className: v(V.row, t), children: e })),
|
|
3579
3579
|
"PanelRow"
|
|
3580
|
-
),
|
|
3580
|
+
), Qu = /* @__PURE__ */ I(Yc), Gc = "hanui-price-Oc5Nr", Xc = "hanui-price__current-2Xup2", Wc = "hanui-price__currency-32NLN", Qc = "hanui-price__list-MlQgT", Jc = "hanui-price__discount-5Yc6W", We = {
|
|
3581
3581
|
price: Gc,
|
|
3582
3582
|
price__current: Xc,
|
|
3583
|
-
price__currency:
|
|
3584
|
-
price__list:
|
|
3583
|
+
price__currency: Wc,
|
|
3584
|
+
price__list: Qc,
|
|
3585
3585
|
price__discount: Jc,
|
|
3586
3586
|
"price--sm": "hanui-price--sm-Hd8Oe",
|
|
3587
3587
|
"price--md": "hanui-price--md-JMxlK",
|
|
@@ -3595,31 +3595,31 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3595
3595
|
formatDiscount: o = (d) => `%${d}`,
|
|
3596
3596
|
isFormatted: s,
|
|
3597
3597
|
size: i = "md",
|
|
3598
|
-
className:
|
|
3599
|
-
testId:
|
|
3598
|
+
className: u,
|
|
3599
|
+
testId: h
|
|
3600
3600
|
}) => {
|
|
3601
|
-
const { labels: d } = j(), c = H("Price.currency", t, d == null ? void 0 : d.currency),
|
|
3602
|
-
if (!s || !(d != null && d.locale) || !/\d/.test(
|
|
3601
|
+
const { labels: d } = j(), c = H("Price.currency", t, d == null ? void 0 : d.currency), _ = (l) => {
|
|
3602
|
+
if (!s || !(d != null && d.locale) || !/\d/.test(l)) return l;
|
|
3603
3603
|
const m = Number(
|
|
3604
|
-
|
|
3604
|
+
l.replace(/[^\d.,-]/g, "").replace(/\.(?=\d{3}\b)/g, "").replace(",", ".")
|
|
3605
3605
|
);
|
|
3606
|
-
if (!Number.isFinite(m)) return
|
|
3606
|
+
if (!Number.isFinite(m)) return l;
|
|
3607
3607
|
try {
|
|
3608
3608
|
return new Intl.NumberFormat(d.locale).format(m);
|
|
3609
3609
|
} catch {
|
|
3610
|
-
return
|
|
3610
|
+
return l;
|
|
3611
3611
|
}
|
|
3612
3612
|
};
|
|
3613
|
-
return /* @__PURE__ */ g("span", { className:
|
|
3614
|
-
/* @__PURE__ */ g("span", { className:
|
|
3615
|
-
|
|
3616
|
-
/* @__PURE__ */ a("span", { className:
|
|
3613
|
+
return /* @__PURE__ */ g("span", { className: v(We.price, We[`price--${i}`], u), "data-testid": h, children: [
|
|
3614
|
+
/* @__PURE__ */ g("span", { className: We.price__current, children: [
|
|
3615
|
+
_(e),
|
|
3616
|
+
/* @__PURE__ */ a("span", { className: We.price__currency, children: c })
|
|
3617
3617
|
] }),
|
|
3618
|
-
n && /* @__PURE__ */ g("s", { className:
|
|
3619
|
-
|
|
3620
|
-
/* @__PURE__ */ a("span", { className:
|
|
3618
|
+
n && /* @__PURE__ */ g("s", { className: We.price__list, children: [
|
|
3619
|
+
_(n),
|
|
3620
|
+
/* @__PURE__ */ a("span", { className: We.price__currency, children: c })
|
|
3621
3621
|
] }),
|
|
3622
|
-
r !== void 0 && r > 0 && /* @__PURE__ */ a("span", { className:
|
|
3622
|
+
r !== void 0 && r > 0 && /* @__PURE__ */ a("span", { className: We.price__discount, children: o(r) })
|
|
3623
3623
|
] });
|
|
3624
3624
|
}, Ju = /* @__PURE__ */ I(Zc), Vc = "hanui-rating-94dke", el = "hanui-rating__stars-QkpVU", tl = "hanui-rating__empty-Wf6-K", al = "hanui-rating__count-pIoEs", nl = "hanui-rating__srOnly-E9h0d", lt = {
|
|
3625
3625
|
rating: Vc,
|
|
@@ -3630,21 +3630,21 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3630
3630
|
"rating--sm": "hanui-rating--sm-AtY7U",
|
|
3631
3631
|
"rating--md": "hanui-rating--md-Q0nxN"
|
|
3632
3632
|
}, rl = ({ value: e, count: t, srLabel: n, size: r = "sm", className: o, testId: s }) => {
|
|
3633
|
-
var
|
|
3634
|
-
const { labels: i } = j(),
|
|
3635
|
-
return /* @__PURE__ */ g("span", { className:
|
|
3633
|
+
var h;
|
|
3634
|
+
const { labels: i } = j(), u = Math.round(e * 2) / 2;
|
|
3635
|
+
return /* @__PURE__ */ g("span", { className: v(lt.rating, lt[`rating--${r}`], o), "data-testid": s, children: [
|
|
3636
3636
|
/* @__PURE__ */ a("span", { className: lt.rating__stars, "aria-hidden": !0, children: Array.from({ length: 5 }, (d, c) => {
|
|
3637
|
-
const
|
|
3638
|
-
return
|
|
3637
|
+
const _ = c + 1;
|
|
3638
|
+
return u >= _ ? /* @__PURE__ */ a(ea, {}, c) : u >= _ - 0.5 ? /* @__PURE__ */ a(bn, {}, c) : /* @__PURE__ */ a(ea, { className: lt.rating__empty }, c);
|
|
3639
3639
|
}) }),
|
|
3640
|
-
/* @__PURE__ */ a("span", { className: lt.rating__srOnly, children: n ?? zt("Rating.srLabel", (
|
|
3640
|
+
/* @__PURE__ */ a("span", { className: lt.rating__srOnly, children: n ?? zt("Rating.srLabel", (h = i == null ? void 0 : i.rating) == null ? void 0 : h.srLabel, e, t) }),
|
|
3641
3641
|
ut(t) && /* @__PURE__ */ g("span", { className: lt.rating__count, "aria-hidden": !0, children: [
|
|
3642
3642
|
"(",
|
|
3643
3643
|
t,
|
|
3644
3644
|
")"
|
|
3645
3645
|
] })
|
|
3646
3646
|
] });
|
|
3647
|
-
}, Zu = /* @__PURE__ */ I(rl), ol = "hanui-header-a08Jh", il = "hanui-header__text-ArJkA", sl = "hanui-header__overline-X5Epo", cl = "hanui-header__title-nQQQJ", ll = "hanui-header__description-08oCr", dl = "hanui-header__action-xsxQF",
|
|
3647
|
+
}, Zu = /* @__PURE__ */ I(rl), ol = "hanui-header-a08Jh", il = "hanui-header__text-ArJkA", sl = "hanui-header__overline-X5Epo", cl = "hanui-header__title-nQQQJ", ll = "hanui-header__description-08oCr", dl = "hanui-header__action-xsxQF", Qe = {
|
|
3648
3648
|
header: ol,
|
|
3649
3649
|
header__text: il,
|
|
3650
3650
|
header__overline: sl,
|
|
@@ -3661,14 +3661,14 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3661
3661
|
as: o = "h2",
|
|
3662
3662
|
size: s = "md",
|
|
3663
3663
|
className: i,
|
|
3664
|
-
testId:
|
|
3665
|
-
}) => /* @__PURE__ */ g("header", { className:
|
|
3666
|
-
/* @__PURE__ */ g("div", { className:
|
|
3667
|
-
n && /* @__PURE__ */ a("span", { className:
|
|
3668
|
-
/* @__PURE__ */ a(o, { className:
|
|
3669
|
-
t && /* @__PURE__ */ a("p", { className:
|
|
3664
|
+
testId: u
|
|
3665
|
+
}) => /* @__PURE__ */ g("header", { className: v(Qe.header, Qe[`header--${s}`], i), "data-testid": u, children: [
|
|
3666
|
+
/* @__PURE__ */ g("div", { className: Qe.header__text, children: [
|
|
3667
|
+
n && /* @__PURE__ */ a("span", { className: Qe.header__overline, children: n }),
|
|
3668
|
+
/* @__PURE__ */ a(o, { className: Qe.header__title, children: e }),
|
|
3669
|
+
t && /* @__PURE__ */ a("p", { className: Qe.header__description, children: t })
|
|
3670
3670
|
] }),
|
|
3671
|
-
r && /* @__PURE__ */ a("div", { className:
|
|
3671
|
+
r && /* @__PURE__ */ a("div", { className: Qe.header__action, children: r })
|
|
3672
3672
|
] }), Vu = /* @__PURE__ */ I(_l), ul = "hanui-scrollArea-Ly-yT", Vt = {
|
|
3673
3673
|
scrollArea: ul,
|
|
3674
3674
|
"scrollArea--vertical": "hanui-scrollArea--vertical-2ujC7",
|
|
@@ -3684,35 +3684,41 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3684
3684
|
className: s,
|
|
3685
3685
|
testId: i
|
|
3686
3686
|
}) => {
|
|
3687
|
-
const
|
|
3687
|
+
const u = R(null), [h, d] = P(!1), [c, _] = P({ start: !1, end: !1 });
|
|
3688
3688
|
return S(() => {
|
|
3689
|
-
const
|
|
3690
|
-
if (!
|
|
3691
|
-
const
|
|
3692
|
-
const
|
|
3689
|
+
const l = u.current;
|
|
3690
|
+
if (!l || typeof ResizeObserver > "u") return;
|
|
3691
|
+
const m = () => {
|
|
3692
|
+
const b = l.scrollHeight > l.clientHeight, p = l.scrollWidth > l.clientWidth;
|
|
3693
3693
|
d(
|
|
3694
|
-
n === "horizontal" ?
|
|
3694
|
+
n === "horizontal" ? p : n === "vertical" ? b : b || p
|
|
3695
3695
|
);
|
|
3696
|
+
const y = n === "horizontal", D = y ? l.clientWidth : l.clientHeight, N = y ? l.scrollWidth : l.scrollHeight, f = Math.abs(y ? l.scrollLeft : l.scrollTop);
|
|
3697
|
+
_({ start: f > 1, end: f + D < N - 1 });
|
|
3698
|
+
};
|
|
3699
|
+
m();
|
|
3700
|
+
const w = new ResizeObserver(m);
|
|
3701
|
+
w.observe(l);
|
|
3702
|
+
for (const b of l.children) w.observe(b);
|
|
3703
|
+
return l.addEventListener("scroll", m, { passive: !0 }), () => {
|
|
3704
|
+
w.disconnect(), l.removeEventListener("scroll", m);
|
|
3696
3705
|
};
|
|
3697
|
-
l();
|
|
3698
|
-
const h = new ResizeObserver(l);
|
|
3699
|
-
h.observe(c);
|
|
3700
|
-
for (const m of c.children) h.observe(m);
|
|
3701
|
-
return () => h.disconnect();
|
|
3702
3706
|
}, [n, e]), /* @__PURE__ */ a(
|
|
3703
3707
|
"div",
|
|
3704
3708
|
{
|
|
3705
|
-
ref:
|
|
3706
|
-
className:
|
|
3709
|
+
ref: u,
|
|
3710
|
+
className: v(
|
|
3707
3711
|
Vt.scrollArea,
|
|
3708
3712
|
Vt[`scrollArea--${n}`],
|
|
3709
3713
|
o && Vt["scrollArea--fade"],
|
|
3710
3714
|
s
|
|
3711
3715
|
),
|
|
3712
3716
|
style: r === void 0 ? void 0 : { maxBlockSize: r },
|
|
3713
|
-
|
|
3714
|
-
|
|
3715
|
-
|
|
3717
|
+
"data-fade-start": o && c.start ? "" : void 0,
|
|
3718
|
+
"data-fade-end": o && c.end ? "" : void 0,
|
|
3719
|
+
tabIndex: h ? 0 : void 0,
|
|
3720
|
+
role: h ? "region" : void 0,
|
|
3721
|
+
"aria-label": h ? t : void 0,
|
|
3716
3722
|
"data-testid": i,
|
|
3717
3723
|
children: e
|
|
3718
3724
|
}
|
|
@@ -3739,28 +3745,28 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3739
3745
|
width: ma(e) ? `${e}px` : e,
|
|
3740
3746
|
height: ma(t) ? `${t}px` : t
|
|
3741
3747
|
};
|
|
3742
|
-
return n === "text" && r > 1 ? /* @__PURE__ */ a("span", { className:
|
|
3748
|
+
return n === "text" && r > 1 ? /* @__PURE__ */ a("span", { className: v(le.group, o), "aria-hidden": !0, children: Array.from({ length: r }, (i, u) => /* @__PURE__ */ a(
|
|
3743
3749
|
"span",
|
|
3744
3750
|
{
|
|
3745
|
-
className:
|
|
3746
|
-
style:
|
|
3751
|
+
className: v(le.skeleton, le["skeleton--text"]),
|
|
3752
|
+
style: u === r - 1 ? { width: "60%" } : void 0
|
|
3747
3753
|
},
|
|
3748
|
-
|
|
3754
|
+
u
|
|
3749
3755
|
)) }) : /* @__PURE__ */ a(
|
|
3750
3756
|
"span",
|
|
3751
3757
|
{
|
|
3752
|
-
className:
|
|
3758
|
+
className: v(le.skeleton, le[`skeleton--${n}`], o),
|
|
3753
3759
|
style: s,
|
|
3754
3760
|
"aria-hidden": !0
|
|
3755
3761
|
}
|
|
3756
3762
|
);
|
|
3757
|
-
}, th = /* @__PURE__ */ I(ze), Nl = ({ count: e = 1, className: t }) => /* @__PURE__ */ a(fe, { children: Array.from({ length: e }, (n, r) => /* @__PURE__ */ g("div", { className:
|
|
3763
|
+
}, th = /* @__PURE__ */ I(ze), Nl = ({ count: e = 1, className: t }) => /* @__PURE__ */ a(fe, { children: Array.from({ length: e }, (n, r) => /* @__PURE__ */ g("div", { className: v(le.card, t), "aria-hidden": !0, children: [
|
|
3758
3764
|
/* @__PURE__ */ a(ze, { className: le.card__media }),
|
|
3759
3765
|
/* @__PURE__ */ g("div", { className: le.card__body, children: [
|
|
3760
3766
|
/* @__PURE__ */ a(ze, { variant: "text", width: "70%" }),
|
|
3761
3767
|
/* @__PURE__ */ a(ze, { variant: "text", width: "40%" })
|
|
3762
3768
|
] })
|
|
3763
|
-
] }, r)) }), $l = ({ count: e = 3, className: t }) => /* @__PURE__ */ a("div", { className:
|
|
3769
|
+
] }, r)) }), $l = ({ count: e = 3, className: t }) => /* @__PURE__ */ a("div", { className: v(le.rows, t), "aria-hidden": !0, children: Array.from({ length: e }, (n, r) => /* @__PURE__ */ g("div", { className: le.row, children: [
|
|
3764
3770
|
/* @__PURE__ */ a(ze, { variant: "circle", width: 36, height: 36 }),
|
|
3765
3771
|
/* @__PURE__ */ g("div", { className: le.row__text, children: [
|
|
3766
3772
|
/* @__PURE__ */ a(ze, { variant: "text", width: "45%" }),
|
|
@@ -3770,7 +3776,7 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3770
3776
|
count: e = 5,
|
|
3771
3777
|
columns: t = 4,
|
|
3772
3778
|
className: n
|
|
3773
|
-
}) => /* @__PURE__ */ a("div", { className:
|
|
3779
|
+
}) => /* @__PURE__ */ a("div", { className: v(le.table, n), "aria-hidden": !0, children: Array.from({ length: e }, (r, o) => /* @__PURE__ */ a("div", { className: le.table__row, children: Array.from({ length: t }, (s, i) => /* @__PURE__ */ a(ze, { variant: "text" }, i)) }, o)) }), ah = /* @__PURE__ */ F(/* @__PURE__ */ I(Nl), "SkeletonCard"), nh = /* @__PURE__ */ F(/* @__PURE__ */ I($l), "SkeletonRows"), rh = /* @__PURE__ */ F(/* @__PURE__ */ I(Dl), "SkeletonTable"), Il = "hanui-stat-Xb7wp", Tl = "hanui-stat__icon-MB8NU", Cl = "hanui-stat__label-kUX2m", El = "hanui-stat__value--6p13", Ll = "hanui-stat__unit-mjHVk", Sl = "hanui-stat__delta-YKpOu", Rl = "hanui-stat__description-Yvw6J", Al = "hanui-stat__srOnly-YKebA", _e = {
|
|
3774
3780
|
stat: Il,
|
|
3775
3781
|
"stat--sm": "hanui-stat--sm-XnK8p",
|
|
3776
3782
|
"stat--plain": "hanui-stat--plain-N-3RC",
|
|
@@ -3799,13 +3805,13 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3799
3805
|
trend: o,
|
|
3800
3806
|
isUpPositive: s = !0,
|
|
3801
3807
|
description: i,
|
|
3802
|
-
icon:
|
|
3803
|
-
variant:
|
|
3808
|
+
icon: u,
|
|
3809
|
+
variant: h = "card",
|
|
3804
3810
|
size: d = "md",
|
|
3805
3811
|
className: c,
|
|
3806
|
-
testId:
|
|
3812
|
+
testId: _
|
|
3807
3813
|
}) => {
|
|
3808
|
-
const
|
|
3814
|
+
const l = o === "flat" ? void 0 : o === "up" === s;
|
|
3809
3815
|
return (
|
|
3810
3816
|
/*
|
|
3811
3817
|
`card` icin ayri bir sinif YOK: taban sinifin kendisi kart. Arama
|
|
@@ -3815,10 +3821,10 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3815
3821
|
/* @__PURE__ */ g(
|
|
3816
3822
|
"div",
|
|
3817
3823
|
{
|
|
3818
|
-
className:
|
|
3819
|
-
"data-testid":
|
|
3824
|
+
className: v(_e.stat, _e[`stat--${d}`], _e[`stat--${h}`], c),
|
|
3825
|
+
"data-testid": _,
|
|
3820
3826
|
children: [
|
|
3821
|
-
|
|
3827
|
+
u && /* @__PURE__ */ a("span", { className: _e.stat__icon, "aria-hidden": !0, children: u }),
|
|
3822
3828
|
/* @__PURE__ */ a("span", { className: _e.stat__label, children: e }),
|
|
3823
3829
|
/* @__PURE__ */ g("span", { className: _e.stat__value, children: [
|
|
3824
3830
|
t,
|
|
@@ -3827,10 +3833,10 @@ const An = 640, su = 768, Mn = 1024, cu = `(min-width: ${Mn + 1}px)`, sa = `(min
|
|
|
3827
3833
|
r && o && /* @__PURE__ */ g(
|
|
3828
3834
|
"span",
|
|
3829
3835
|
{
|
|
3830
|
-
className:
|
|
3836
|
+
className: v(
|
|
3831
3837
|
_e.stat__delta,
|
|
3832
|
-
|
|
3833
|
-
|
|
3838
|
+
l === !0 && _e["stat__delta--positive"],
|
|
3839
|
+
l === !1 && _e["stat__delta--negative"]
|
|
3834
3840
|
),
|
|
3835
3841
|
children: [
|
|
3836
3842
|
Ml[o],
|
|
@@ -3890,18 +3896,18 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
3890
3896
|
tt = [], la();
|
|
3891
3897
|
}
|
|
3892
3898
|
}, Xl = ({ toast: e, closeLabel: t, onDismiss: n }) => {
|
|
3893
|
-
const r = e.tone ?? "info", o = e.duration ?? Gl[r], [s, i] = P(!1),
|
|
3899
|
+
const r = e.tone ?? "info", o = e.duration ?? Gl[r], [s, i] = P(!1), u = R(o), h = R(0);
|
|
3894
3900
|
return S(() => {
|
|
3895
3901
|
if (o === 0 || s) return;
|
|
3896
|
-
|
|
3897
|
-
const d = window.setTimeout(() => n(e.id),
|
|
3902
|
+
h.current = Date.now();
|
|
3903
|
+
const d = window.setTimeout(() => n(e.id), u.current);
|
|
3898
3904
|
return () => {
|
|
3899
|
-
window.clearTimeout(d),
|
|
3905
|
+
window.clearTimeout(d), u.current = Math.max(0, u.current - (Date.now() - h.current));
|
|
3900
3906
|
};
|
|
3901
3907
|
}, [o, s, n, e.id]), /* @__PURE__ */ g(
|
|
3902
3908
|
"div",
|
|
3903
3909
|
{
|
|
3904
|
-
className:
|
|
3910
|
+
className: v(Le.toast, Le[`toast--${r}`]),
|
|
3905
3911
|
role: r === "danger" ? "alert" : "status",
|
|
3906
3912
|
onPointerEnter: () => i(!0),
|
|
3907
3913
|
onPointerLeave: () => i(!1),
|
|
@@ -3939,34 +3945,34 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
3939
3945
|
]
|
|
3940
3946
|
}
|
|
3941
3947
|
);
|
|
3942
|
-
},
|
|
3948
|
+
}, Wl = ({ closeLabel: e, className: t }) => {
|
|
3943
3949
|
const { labels: n } = j(), [r, o] = P([]);
|
|
3944
3950
|
S(() => (aa.add(o), o(tt), () => {
|
|
3945
3951
|
aa.delete(o);
|
|
3946
3952
|
}), []);
|
|
3947
|
-
const s = z((
|
|
3953
|
+
const s = z((h) => na(h), []);
|
|
3948
3954
|
S(() => {
|
|
3949
3955
|
if (r.length === 0) return;
|
|
3950
|
-
const
|
|
3956
|
+
const h = (d) => {
|
|
3951
3957
|
d.key === "Escape" && na(r[r.length - 1].id);
|
|
3952
3958
|
};
|
|
3953
|
-
return document.addEventListener("keydown",
|
|
3959
|
+
return document.addEventListener("keydown", h), () => document.removeEventListener("keydown", h);
|
|
3954
3960
|
}, [r]);
|
|
3955
|
-
const [i,
|
|
3956
|
-
return S(() =>
|
|
3957
|
-
/* @__PURE__ */ a("div", { className:
|
|
3961
|
+
const [i, u] = P(!1);
|
|
3962
|
+
return S(() => u(!0), []), i ? Et(
|
|
3963
|
+
/* @__PURE__ */ a("div", { className: v(Le.hub, t), children: r.map((h) => /* @__PURE__ */ a(
|
|
3958
3964
|
Xl,
|
|
3959
3965
|
{
|
|
3960
|
-
toast:
|
|
3966
|
+
toast: h,
|
|
3961
3967
|
closeLabel: H("ToastHub.closeLabel", e, n == null ? void 0 : n.close),
|
|
3962
3968
|
onDismiss: s
|
|
3963
3969
|
},
|
|
3964
|
-
|
|
3970
|
+
h.id
|
|
3965
3971
|
)) }),
|
|
3966
3972
|
document.body
|
|
3967
3973
|
) : null;
|
|
3968
|
-
}, sh = /* @__PURE__ */ I(/* @__PURE__ */ F(
|
|
3969
|
-
accordion:
|
|
3974
|
+
}, sh = /* @__PURE__ */ I(/* @__PURE__ */ F(Wl, "ToastHub")), Ql = "hanui-accordion-h9jLC", Jl = "hanui-accordion__item--YvzK", Zl = "hanui-accordion__title-qZOLY", Vl = "hanui-accordion__meta-PSlsO", ed = "hanui-accordion__marker-QcWcI", td = "hanui-accordion__summary-QUhWh", ad = "hanui-accordion__panel--3EXE", nd = "hanui-accordion__content-fO64s", Ie = {
|
|
3975
|
+
accordion: Ql,
|
|
3970
3976
|
accordion__item: Jl,
|
|
3971
3977
|
"accordion__item--disabled": "hanui-accordion__item--disabled-x1erZ",
|
|
3972
3978
|
accordion__title: Zl,
|
|
@@ -3984,32 +3990,32 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
3984
3990
|
className: s,
|
|
3985
3991
|
testId: i
|
|
3986
3992
|
}) => {
|
|
3987
|
-
const
|
|
3988
|
-
(m,
|
|
3989
|
-
const b =
|
|
3993
|
+
const u = J(), [h, d] = P(n ?? []), c = r !== void 0, _ = c ? r : h, l = z(
|
|
3994
|
+
(m, w) => {
|
|
3995
|
+
const b = w ? t ? [m] : [..._.filter((p) => p !== m), m] : _.filter((p) => p !== m);
|
|
3990
3996
|
c || d(b), o == null || o(b);
|
|
3991
3997
|
},
|
|
3992
|
-
[c, t, o,
|
|
3998
|
+
[c, t, o, _]
|
|
3993
3999
|
);
|
|
3994
|
-
return /* @__PURE__ */ a("div", { className:
|
|
3995
|
-
const
|
|
4000
|
+
return /* @__PURE__ */ a("div", { className: v(Ie.accordion, s), "data-testid": i, children: e.map((m) => {
|
|
4001
|
+
const w = _.includes(m.id);
|
|
3996
4002
|
return /* @__PURE__ */ g(
|
|
3997
4003
|
"details",
|
|
3998
4004
|
{
|
|
3999
|
-
className:
|
|
4005
|
+
className: v(
|
|
4000
4006
|
Ie.accordion__item,
|
|
4001
4007
|
m.isDisabled && Ie["accordion__item--disabled"]
|
|
4002
4008
|
),
|
|
4003
|
-
open:
|
|
4009
|
+
open: w,
|
|
4004
4010
|
onToggle: (b) => {
|
|
4005
4011
|
const p = b.currentTarget.open;
|
|
4006
|
-
p !==
|
|
4012
|
+
p !== w && l(m.id, p);
|
|
4007
4013
|
},
|
|
4008
4014
|
children: [
|
|
4009
4015
|
/* @__PURE__ */ g(
|
|
4010
4016
|
"summary",
|
|
4011
4017
|
{
|
|
4012
|
-
id: `${
|
|
4018
|
+
id: `${u}-${m.id}`,
|
|
4013
4019
|
className: Ie.accordion__summary,
|
|
4014
4020
|
"aria-disabled": m.isDisabled,
|
|
4015
4021
|
tabIndex: m.isDisabled ? -1 : void 0,
|
|
@@ -4055,34 +4061,34 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4055
4061
|
}) => /* @__PURE__ */ a(
|
|
4056
4062
|
"ol",
|
|
4057
4063
|
{
|
|
4058
|
-
className:
|
|
4064
|
+
className: v(be.steps, be[`steps--${o}`], s),
|
|
4059
4065
|
"aria-label": r,
|
|
4060
4066
|
"data-testid": i,
|
|
4061
|
-
children: e.map((
|
|
4062
|
-
const d = hd(
|
|
4063
|
-
/* @__PURE__ */ a("span", { className: be.steps__marker, "aria-hidden": !0, children: d === "done" ? /* @__PURE__ */ a(Ht, {}) :
|
|
4067
|
+
children: e.map((u, h) => {
|
|
4068
|
+
const d = hd(h, t), c = !!n && d === "done", _ = /* @__PURE__ */ g(fe, { children: [
|
|
4069
|
+
/* @__PURE__ */ a("span", { className: be.steps__marker, "aria-hidden": !0, children: d === "done" ? /* @__PURE__ */ a(Ht, {}) : h + 1 }),
|
|
4064
4070
|
/* @__PURE__ */ g("span", { className: be.steps__text, children: [
|
|
4065
|
-
/* @__PURE__ */ a("span", { className: be.steps__label, children:
|
|
4066
|
-
|
|
4071
|
+
/* @__PURE__ */ a("span", { className: be.steps__label, children: u.label }),
|
|
4072
|
+
u.description && /* @__PURE__ */ a("span", { className: be.steps__description, children: u.description })
|
|
4067
4073
|
] }),
|
|
4068
4074
|
/* @__PURE__ */ a("span", { className: be.steps__status, children: pd[d] })
|
|
4069
4075
|
] });
|
|
4070
4076
|
return /* @__PURE__ */ a(
|
|
4071
4077
|
"li",
|
|
4072
4078
|
{
|
|
4073
|
-
className:
|
|
4079
|
+
className: v(be.steps__item, be[`steps__item--${d}`]),
|
|
4074
4080
|
"aria-current": d === "current" ? "step" : void 0,
|
|
4075
4081
|
children: c ? /* @__PURE__ */ a(
|
|
4076
4082
|
"button",
|
|
4077
4083
|
{
|
|
4078
4084
|
type: "button",
|
|
4079
4085
|
className: be.steps__button,
|
|
4080
|
-
onClick: () => n == null ? void 0 : n(
|
|
4081
|
-
children:
|
|
4086
|
+
onClick: () => n == null ? void 0 : n(h),
|
|
4087
|
+
children: _
|
|
4082
4088
|
}
|
|
4083
|
-
) : /* @__PURE__ */ a("span", { className: be.steps__button, children:
|
|
4089
|
+
) : /* @__PURE__ */ a("span", { className: be.steps__button, children: _ })
|
|
4084
4090
|
},
|
|
4085
|
-
|
|
4091
|
+
u.id
|
|
4086
4092
|
);
|
|
4087
4093
|
})
|
|
4088
4094
|
}
|
|
@@ -4101,34 +4107,34 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4101
4107
|
ariaLabel: o,
|
|
4102
4108
|
isManualActivation: s,
|
|
4103
4109
|
className: i,
|
|
4104
|
-
testId:
|
|
4110
|
+
testId: u
|
|
4105
4111
|
}) => {
|
|
4106
4112
|
var $;
|
|
4107
|
-
const
|
|
4113
|
+
const h = J(), [d, c] = P(t ?? (($ = e[0]) == null ? void 0 : $.id)), _ = ut(n), l = _ ? n : d, m = e.findIndex((k) => k.id === l), [w, b] = P(m < 0 ? 0 : m), p = R(null), y = e[m] ?? e[0];
|
|
4108
4114
|
S(() => {
|
|
4109
4115
|
var k;
|
|
4110
4116
|
ia((k = p.current) == null ? void 0 : k.querySelector('[aria-selected="true"]'), {
|
|
4111
4117
|
block: "nearest",
|
|
4112
4118
|
inline: "nearest"
|
|
4113
4119
|
});
|
|
4114
|
-
}, [
|
|
4120
|
+
}, [l]);
|
|
4115
4121
|
const D = (k) => {
|
|
4116
|
-
|
|
4122
|
+
_ || c(k), r == null || r(k);
|
|
4117
4123
|
}, N = (k) => {
|
|
4118
4124
|
var E;
|
|
4119
4125
|
if (s && (k.key === "Enter" || k.key === " ")) {
|
|
4120
|
-
k.preventDefault(), D(e[
|
|
4126
|
+
k.preventDefault(), D(e[w].id);
|
|
4121
4127
|
return;
|
|
4122
4128
|
}
|
|
4123
4129
|
const L = k.key === "ArrowRight" ? 1 : k.key === "ArrowLeft" ? -1 : 0;
|
|
4124
4130
|
if (L === 0) return;
|
|
4125
4131
|
k.preventDefault();
|
|
4126
|
-
const C = ((s ?
|
|
4127
|
-
b(C), s || D(e[C].id), (E = document.getElementById(`${
|
|
4132
|
+
const C = ((s ? w : m) + L + e.length) % e.length;
|
|
4133
|
+
b(C), s || D(e[C].id), (E = document.getElementById(`${h}-tab-${e[C].id}`)) == null || E.focus();
|
|
4128
4134
|
};
|
|
4129
4135
|
if (e.length === 0) return null;
|
|
4130
|
-
const
|
|
4131
|
-
return /* @__PURE__ */ g("div", { className:
|
|
4136
|
+
const f = ut(y == null ? void 0 : y.content);
|
|
4137
|
+
return /* @__PURE__ */ g("div", { className: v(dt.tabs, i), "data-testid": u, children: [
|
|
4132
4138
|
/* @__PURE__ */ a(
|
|
4133
4139
|
"div",
|
|
4134
4140
|
{
|
|
@@ -4143,13 +4149,13 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4143
4149
|
return /* @__PURE__ */ g(
|
|
4144
4150
|
"button",
|
|
4145
4151
|
{
|
|
4146
|
-
id: `${
|
|
4152
|
+
id: `${h}-tab-${k.id}`,
|
|
4147
4153
|
type: "button",
|
|
4148
4154
|
role: "tab",
|
|
4149
4155
|
"aria-selected": L,
|
|
4150
|
-
"aria-controls":
|
|
4151
|
-
tabIndex: (s ? ((C = e[
|
|
4152
|
-
className:
|
|
4156
|
+
"aria-controls": f ? `${h}-panel-${k.id}` : void 0,
|
|
4157
|
+
tabIndex: (s ? ((C = e[w]) == null ? void 0 : C.id) === k.id : L) ? 0 : -1,
|
|
4158
|
+
className: v(dt.tabs__tab, L && dt["tabs__tab--active"]),
|
|
4153
4159
|
onClick: () => D(k.id),
|
|
4154
4160
|
children: [
|
|
4155
4161
|
k.label,
|
|
@@ -4161,12 +4167,12 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4161
4167
|
})
|
|
4162
4168
|
}
|
|
4163
4169
|
),
|
|
4164
|
-
|
|
4170
|
+
f && /* @__PURE__ */ a(
|
|
4165
4171
|
"div",
|
|
4166
4172
|
{
|
|
4167
|
-
id: `${
|
|
4173
|
+
id: `${h}-panel-${y.id}`,
|
|
4168
4174
|
role: "tabpanel",
|
|
4169
|
-
"aria-labelledby": `${
|
|
4175
|
+
"aria-labelledby": `${h}-tab-${y.id}`,
|
|
4170
4176
|
className: dt.tabs__panel,
|
|
4171
4177
|
tabIndex: 0,
|
|
4172
4178
|
children: y.content
|
|
@@ -4179,13 +4185,13 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4179
4185
|
tile__label: Nd,
|
|
4180
4186
|
tile__meta: $d,
|
|
4181
4187
|
"tile--active": "hanui-tile--active-z0F2M"
|
|
4182
|
-
}, Dd = ({ label: e, icon: t, href: n, meta: r, isActive: o, linkProps: s, className: i, testId:
|
|
4188
|
+
}, Dd = ({ label: e, icon: t, href: n, meta: r, isActive: o, linkProps: s, className: i, testId: u }) => /* @__PURE__ */ g(
|
|
4183
4189
|
ke,
|
|
4184
4190
|
{
|
|
4185
4191
|
href: n,
|
|
4186
|
-
className:
|
|
4192
|
+
className: v(Nt.tile, o && Nt["tile--active"], i),
|
|
4187
4193
|
"aria-current": o ? "page" : void 0,
|
|
4188
|
-
"data-testid":
|
|
4194
|
+
"data-testid": u,
|
|
4189
4195
|
...s,
|
|
4190
4196
|
children: [
|
|
4191
4197
|
/* @__PURE__ */ a("span", { className: Nt.tile__medallion, "aria-hidden": !0, children: t }),
|
|
@@ -4216,12 +4222,12 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4216
4222
|
current: "şu an",
|
|
4217
4223
|
pending: "bekliyor",
|
|
4218
4224
|
failed: "başarısız"
|
|
4219
|
-
}, Fd = ({ events: e, label: t, className: n, testId: r }) => /* @__PURE__ */ a("ol", { className:
|
|
4225
|
+
}, Fd = ({ events: e, label: t, className: n, testId: r }) => /* @__PURE__ */ a("ol", { className: v(Te.timeline, n), "aria-label": t, "data-testid": r, children: e.map((o) => {
|
|
4220
4226
|
const s = o.status ?? "done";
|
|
4221
4227
|
return /* @__PURE__ */ g(
|
|
4222
4228
|
"li",
|
|
4223
4229
|
{
|
|
4224
|
-
className:
|
|
4230
|
+
className: v(Te.timeline__item, Te[`timeline__item--${s}`]),
|
|
4225
4231
|
"aria-current": s === "current" ? "step" : void 0,
|
|
4226
4232
|
children: [
|
|
4227
4233
|
/* @__PURE__ */ a("span", { className: Te.timeline__marker, "aria-hidden": !0, children: o.icon ?? Md[s] }),
|
|
@@ -4266,53 +4272,53 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4266
4272
|
children: o,
|
|
4267
4273
|
description: s,
|
|
4268
4274
|
footer: i,
|
|
4269
|
-
icon:
|
|
4270
|
-
tone:
|
|
4275
|
+
icon: u,
|
|
4276
|
+
tone: h = "neutral",
|
|
4271
4277
|
size: d = "md",
|
|
4272
4278
|
isDismissable: c = !0,
|
|
4273
|
-
className:
|
|
4274
|
-
testId:
|
|
4279
|
+
className: _,
|
|
4280
|
+
testId: l
|
|
4275
4281
|
}) => {
|
|
4276
|
-
const { labels: m } = j(),
|
|
4282
|
+
const { labels: m } = j(), w = R(null), b = R(null), p = J(), y = J();
|
|
4277
4283
|
S(() => {
|
|
4278
|
-
const N =
|
|
4284
|
+
const N = w.current;
|
|
4279
4285
|
if (!N) return;
|
|
4280
4286
|
if (!e) {
|
|
4281
4287
|
N.open && N.close();
|
|
4282
4288
|
return;
|
|
4283
4289
|
}
|
|
4284
|
-
const
|
|
4290
|
+
const f = pt();
|
|
4285
4291
|
N.open || N.showModal(), jt(N, `.${se.modal__close}`), ca(N);
|
|
4286
4292
|
const { token: $, pop: k } = Yt();
|
|
4287
4293
|
return b.current = $, () => {
|
|
4288
|
-
k(), b.current = null,
|
|
4294
|
+
k(), b.current = null, f();
|
|
4289
4295
|
};
|
|
4290
4296
|
}, [e]), qt(e), S(() => {
|
|
4291
|
-
const N =
|
|
4297
|
+
const N = w.current;
|
|
4292
4298
|
if (!N) return;
|
|
4293
|
-
const
|
|
4299
|
+
const f = ($) => {
|
|
4294
4300
|
$.preventDefault(), c && (b.current && !Gt(b.current) || t());
|
|
4295
4301
|
};
|
|
4296
|
-
return N.addEventListener("cancel",
|
|
4302
|
+
return N.addEventListener("cancel", f), () => N.removeEventListener("cancel", f);
|
|
4297
4303
|
}, [t, c]);
|
|
4298
4304
|
const D = z(
|
|
4299
4305
|
(N) => {
|
|
4300
|
-
c && N.target ===
|
|
4306
|
+
c && N.target === w.current && t();
|
|
4301
4307
|
},
|
|
4302
4308
|
[c, t]
|
|
4303
4309
|
);
|
|
4304
4310
|
return /* @__PURE__ */ a(
|
|
4305
4311
|
"dialog",
|
|
4306
4312
|
{
|
|
4307
|
-
ref:
|
|
4308
|
-
className:
|
|
4313
|
+
ref: w,
|
|
4314
|
+
className: v(se.modal, se[`modal--${d}`], _),
|
|
4309
4315
|
"aria-labelledby": p,
|
|
4310
4316
|
"aria-describedby": s ? y : void 0,
|
|
4311
|
-
"data-testid":
|
|
4317
|
+
"data-testid": l,
|
|
4312
4318
|
onClick: D,
|
|
4313
4319
|
children: /* @__PURE__ */ g("div", { className: se.modal__panel, children: [
|
|
4314
4320
|
/* @__PURE__ */ g("header", { className: se.modal__header, children: [
|
|
4315
|
-
|
|
4321
|
+
u && /* @__PURE__ */ a("span", { className: v(se.modal__icon, se[`modal__icon--${h}`]), children: u }),
|
|
4316
4322
|
/* @__PURE__ */ g("div", { className: se.modal__heading, children: [
|
|
4317
4323
|
/* @__PURE__ */ a("h2", { id: p, className: se.modal__title, children: n }),
|
|
4318
4324
|
s && /* @__PURE__ */ a("p", { id: y, className: se.modal__description, children: s })
|
|
@@ -4334,9 +4340,9 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4334
4340
|
] })
|
|
4335
4341
|
}
|
|
4336
4342
|
);
|
|
4337
|
-
}, Ja = /* @__PURE__ */ I(Xd),
|
|
4338
|
-
palette:
|
|
4339
|
-
palette__search:
|
|
4343
|
+
}, Ja = /* @__PURE__ */ I(Xd), Wd = "hanui-palette-ag-P9", Qd = "hanui-palette__search-G3aYv", Jd = "hanui-palette__searchIcon-2UYj-", Zd = "hanui-palette__input-vvLvt", Vd = "hanui-palette__list--KWiH", e_ = "hanui-palette__group-KPj5Q", t_ = "hanui-palette__item-UZzkp", a_ = "hanui-palette__icon-Fg0Lt", n_ = "hanui-palette__text-flfN9", r_ = "hanui-palette__label-8-UHe", o_ = "hanui-palette__description-eRlk9", i_ = "hanui-palette__shortcut-DwYKX", s_ = "hanui-palette__empty-vg-I3", te = {
|
|
4344
|
+
palette: Wd,
|
|
4345
|
+
palette__search: Qd,
|
|
4340
4346
|
palette__searchIcon: Jd,
|
|
4341
4347
|
palette__input: Zd,
|
|
4342
4348
|
palette__list: Vd,
|
|
@@ -4357,61 +4363,61 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4357
4363
|
searchPlaceholder: o,
|
|
4358
4364
|
emptyMessage: s,
|
|
4359
4365
|
className: i,
|
|
4360
|
-
testId:
|
|
4366
|
+
testId: u
|
|
4361
4367
|
}) => {
|
|
4362
|
-
const
|
|
4368
|
+
const h = J(), d = `${h}-listbox`, c = R(null), _ = R(null), l = R(null), [m, w] = P(""), [b, p] = P(0), y = Tt(() => {
|
|
4363
4369
|
if (m.trim() === "") return n;
|
|
4364
|
-
const
|
|
4370
|
+
const f = m.trim();
|
|
4365
4371
|
return n.filter(
|
|
4366
|
-
($) => Ot($.label,
|
|
4372
|
+
($) => Ot($.label, f) || ($.description ? Ot($.description, f) : !1)
|
|
4367
4373
|
);
|
|
4368
4374
|
}, [n, m]);
|
|
4369
4375
|
qt(e), S(() => {
|
|
4370
4376
|
var C;
|
|
4371
|
-
const
|
|
4372
|
-
if (!
|
|
4377
|
+
const f = c.current;
|
|
4378
|
+
if (!f) return;
|
|
4373
4379
|
if (!e) {
|
|
4374
|
-
|
|
4380
|
+
f.open && f.close();
|
|
4375
4381
|
return;
|
|
4376
4382
|
}
|
|
4377
4383
|
const $ = pt();
|
|
4378
|
-
|
|
4384
|
+
f.open || f.showModal(), (C = _.current) == null || C.focus({ preventScroll: !0 }), w(""), p(0);
|
|
4379
4385
|
const { token: k, pop: L } = Yt();
|
|
4380
|
-
return
|
|
4381
|
-
L(),
|
|
4386
|
+
return l.current = k, () => {
|
|
4387
|
+
L(), l.current = null, $();
|
|
4382
4388
|
};
|
|
4383
4389
|
}, [e]), S(() => {
|
|
4384
|
-
const
|
|
4385
|
-
if (!
|
|
4390
|
+
const f = c.current;
|
|
4391
|
+
if (!f) return;
|
|
4386
4392
|
const $ = (k) => {
|
|
4387
|
-
k.preventDefault(), !(
|
|
4393
|
+
k.preventDefault(), !(l.current && !Gt(l.current)) && t();
|
|
4388
4394
|
};
|
|
4389
|
-
return
|
|
4395
|
+
return f.addEventListener("cancel", $), () => f.removeEventListener("cancel", $);
|
|
4390
4396
|
}, [t]), S(() => {
|
|
4391
|
-
var
|
|
4392
|
-
ia((
|
|
4397
|
+
var f;
|
|
4398
|
+
ia((f = c.current) == null ? void 0 : f.querySelector(`[data-index="${b}"]`), {
|
|
4393
4399
|
block: "nearest"
|
|
4394
4400
|
});
|
|
4395
4401
|
}, [b]);
|
|
4396
|
-
const D = (
|
|
4397
|
-
|
|
4398
|
-
}, N = (
|
|
4402
|
+
const D = (f) => {
|
|
4403
|
+
f.onSelect(), t();
|
|
4404
|
+
}, N = (f) => {
|
|
4399
4405
|
const $ = y.length - 1;
|
|
4400
|
-
switch (
|
|
4406
|
+
switch (f.key) {
|
|
4401
4407
|
case "ArrowDown":
|
|
4402
|
-
|
|
4408
|
+
f.preventDefault(), p((k) => k >= $ ? 0 : k + 1);
|
|
4403
4409
|
break;
|
|
4404
4410
|
case "ArrowUp":
|
|
4405
|
-
|
|
4411
|
+
f.preventDefault(), p((k) => k <= 0 ? $ : k - 1);
|
|
4406
4412
|
break;
|
|
4407
4413
|
case "Home":
|
|
4408
|
-
|
|
4414
|
+
f.preventDefault(), p(0);
|
|
4409
4415
|
break;
|
|
4410
4416
|
case "End":
|
|
4411
|
-
|
|
4417
|
+
f.preventDefault(), p($);
|
|
4412
4418
|
break;
|
|
4413
4419
|
case "Enter": {
|
|
4414
|
-
|
|
4420
|
+
f.preventDefault();
|
|
4415
4421
|
const k = y[b];
|
|
4416
4422
|
k && D(k);
|
|
4417
4423
|
break;
|
|
@@ -4422,17 +4428,17 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4422
4428
|
"dialog",
|
|
4423
4429
|
{
|
|
4424
4430
|
ref: c,
|
|
4425
|
-
className:
|
|
4431
|
+
className: v(te.palette, i),
|
|
4426
4432
|
"aria-label": r,
|
|
4427
|
-
"data-testid":
|
|
4428
|
-
onClick: (
|
|
4433
|
+
"data-testid": u,
|
|
4434
|
+
onClick: (f) => f.target === c.current && t(),
|
|
4429
4435
|
children: [
|
|
4430
4436
|
/* @__PURE__ */ g("div", { className: te.palette__search, children: [
|
|
4431
4437
|
/* @__PURE__ */ a(Ra, { "aria-hidden": !0, className: te.palette__searchIcon }),
|
|
4432
4438
|
/* @__PURE__ */ a(
|
|
4433
4439
|
"input",
|
|
4434
4440
|
{
|
|
4435
|
-
ref:
|
|
4441
|
+
ref: _,
|
|
4436
4442
|
type: "text",
|
|
4437
4443
|
role: "combobox",
|
|
4438
4444
|
className: te.palette__input,
|
|
@@ -4443,46 +4449,46 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4443
4449
|
"aria-autocomplete": "list",
|
|
4444
4450
|
"aria-expanded": !0,
|
|
4445
4451
|
"aria-controls": d,
|
|
4446
|
-
"aria-activedescendant": y[b] ? `${
|
|
4447
|
-
onChange: (
|
|
4448
|
-
|
|
4452
|
+
"aria-activedescendant": y[b] ? `${h}-option-${b}` : void 0,
|
|
4453
|
+
onChange: (f) => {
|
|
4454
|
+
w(f.target.value), p(0);
|
|
4449
4455
|
},
|
|
4450
4456
|
onKeyDown: N
|
|
4451
4457
|
}
|
|
4452
4458
|
)
|
|
4453
4459
|
] }),
|
|
4454
4460
|
/* @__PURE__ */ g("ul", { id: d, role: "listbox", "aria-label": r, className: te.palette__list, children: [
|
|
4455
|
-
y.map((
|
|
4461
|
+
y.map((f, $) => {
|
|
4456
4462
|
var L;
|
|
4457
|
-
const k =
|
|
4463
|
+
const k = f.group !== void 0 && f.group !== ((L = y[$ - 1]) == null ? void 0 : L.group);
|
|
4458
4464
|
return /* @__PURE__ */ g("li", { children: [
|
|
4459
4465
|
k && /* `aria-hidden`: baslik bir SECENEK degil; listbox'in cocugu
|
|
4460
4466
|
olarak okunsaydi ekran okuyucu sayimi bozuluyordu. */
|
|
4461
|
-
/* @__PURE__ */ a("span", { className: te.palette__group, "aria-hidden": !0, children:
|
|
4467
|
+
/* @__PURE__ */ a("span", { className: te.palette__group, "aria-hidden": !0, children: f.group }),
|
|
4462
4468
|
/* @__PURE__ */ g(
|
|
4463
4469
|
"div",
|
|
4464
4470
|
{
|
|
4465
|
-
id: `${
|
|
4471
|
+
id: `${h}-option-${$}`,
|
|
4466
4472
|
role: "option",
|
|
4467
4473
|
"data-index": $,
|
|
4468
4474
|
"aria-selected": $ === b,
|
|
4469
|
-
className:
|
|
4475
|
+
className: v(
|
|
4470
4476
|
te.palette__item,
|
|
4471
4477
|
$ === b && te["palette__item--active"]
|
|
4472
4478
|
),
|
|
4473
4479
|
onMouseEnter: () => p($),
|
|
4474
|
-
onClick: () => D(
|
|
4480
|
+
onClick: () => D(f),
|
|
4475
4481
|
children: [
|
|
4476
|
-
|
|
4482
|
+
f.icon && /* @__PURE__ */ a("span", { className: te.palette__icon, "aria-hidden": !0, children: f.icon }),
|
|
4477
4483
|
/* @__PURE__ */ g("span", { className: te.palette__text, children: [
|
|
4478
|
-
/* @__PURE__ */ a("span", { className: te.palette__label, children:
|
|
4479
|
-
|
|
4484
|
+
/* @__PURE__ */ a("span", { className: te.palette__label, children: f.label }),
|
|
4485
|
+
f.description && /* @__PURE__ */ a("span", { className: te.palette__description, children: f.description })
|
|
4480
4486
|
] }),
|
|
4481
|
-
|
|
4487
|
+
f.shortcut && /* @__PURE__ */ a("kbd", { className: te.palette__shortcut, "aria-hidden": !0, children: f.shortcut })
|
|
4482
4488
|
]
|
|
4483
4489
|
}
|
|
4484
4490
|
)
|
|
4485
|
-
] },
|
|
4491
|
+
] }, f.id);
|
|
4486
4492
|
}),
|
|
4487
4493
|
y.length === 0 && /* @__PURE__ */ a("li", { className: te.palette__empty, children: s })
|
|
4488
4494
|
] })
|
|
@@ -4511,12 +4517,12 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4511
4517
|
description: o,
|
|
4512
4518
|
confirmLabel: s,
|
|
4513
4519
|
cancelLabel: i,
|
|
4514
|
-
closeLabel:
|
|
4515
|
-
variant:
|
|
4520
|
+
closeLabel: u,
|
|
4521
|
+
variant: h,
|
|
4516
4522
|
kind: d,
|
|
4517
4523
|
children: c
|
|
4518
4524
|
}) => {
|
|
4519
|
-
const { labels:
|
|
4525
|
+
const { labels: _ } = j(), [l, m] = P(!1), w = h ?? d ?? "neutral", b = async () => {
|
|
4520
4526
|
m(!0);
|
|
4521
4527
|
try {
|
|
4522
4528
|
await n();
|
|
@@ -4530,12 +4536,12 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4530
4536
|
isOpen: e,
|
|
4531
4537
|
onClose: t,
|
|
4532
4538
|
title: r,
|
|
4533
|
-
closeLabel:
|
|
4539
|
+
closeLabel: u ?? (_ == null ? void 0 : _.close),
|
|
4534
4540
|
description: o,
|
|
4535
|
-
icon: l_[
|
|
4536
|
-
tone: d_[
|
|
4541
|
+
icon: l_[w],
|
|
4542
|
+
tone: d_[w],
|
|
4537
4543
|
size: "sm",
|
|
4538
|
-
isDismissable: !
|
|
4544
|
+
isDismissable: !l,
|
|
4539
4545
|
footer: /* @__PURE__ */ g(fe, { children: [
|
|
4540
4546
|
/* @__PURE__ */ a(
|
|
4541
4547
|
Ct,
|
|
@@ -4543,17 +4549,17 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4543
4549
|
variant: Se.SECONDARY,
|
|
4544
4550
|
size: et.MEDIUM,
|
|
4545
4551
|
onClick: t,
|
|
4546
|
-
disabled:
|
|
4547
|
-
children: H("ConfirmDialog.cancelLabel", i,
|
|
4552
|
+
disabled: l,
|
|
4553
|
+
children: H("ConfirmDialog.cancelLabel", i, _ == null ? void 0 : _.cancel)
|
|
4548
4554
|
}
|
|
4549
4555
|
),
|
|
4550
4556
|
/* @__PURE__ */ a(
|
|
4551
4557
|
Ct,
|
|
4552
4558
|
{
|
|
4553
|
-
variant: __[
|
|
4559
|
+
variant: __[w],
|
|
4554
4560
|
size: et.MEDIUM,
|
|
4555
4561
|
onClick: b,
|
|
4556
|
-
isLoading:
|
|
4562
|
+
isLoading: l,
|
|
4557
4563
|
children: s
|
|
4558
4564
|
}
|
|
4559
4565
|
)
|
|
@@ -4582,14 +4588,14 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4582
4588
|
children: o,
|
|
4583
4589
|
side: s = "end",
|
|
4584
4590
|
size: i = "md",
|
|
4585
|
-
footer:
|
|
4586
|
-
toolbar:
|
|
4591
|
+
footer: u,
|
|
4592
|
+
toolbar: h,
|
|
4587
4593
|
className: d,
|
|
4588
4594
|
testId: c
|
|
4589
4595
|
}) => {
|
|
4590
|
-
const { labels:
|
|
4596
|
+
const { labels: _ } = j(), l = R(null), m = R(null), w = J();
|
|
4591
4597
|
S(() => {
|
|
4592
|
-
const p =
|
|
4598
|
+
const p = l.current;
|
|
4593
4599
|
if (!p) return;
|
|
4594
4600
|
if (!e) {
|
|
4595
4601
|
p.open && p.close();
|
|
@@ -4602,7 +4608,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4602
4608
|
N(), m.current = null, y();
|
|
4603
4609
|
};
|
|
4604
4610
|
}, [e]), qt(e), S(() => {
|
|
4605
|
-
const p =
|
|
4611
|
+
const p = l.current;
|
|
4606
4612
|
if (!p) return;
|
|
4607
4613
|
const y = (D) => {
|
|
4608
4614
|
D.preventDefault(), !(m.current && !Gt(m.current)) && t();
|
|
@@ -4611,26 +4617,26 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4611
4617
|
}, [t]);
|
|
4612
4618
|
const b = z(
|
|
4613
4619
|
(p) => {
|
|
4614
|
-
p.target ===
|
|
4620
|
+
p.target === l.current && t();
|
|
4615
4621
|
},
|
|
4616
4622
|
[t]
|
|
4617
4623
|
);
|
|
4618
4624
|
return /* @__PURE__ */ g(
|
|
4619
4625
|
"dialog",
|
|
4620
4626
|
{
|
|
4621
|
-
ref:
|
|
4622
|
-
className:
|
|
4623
|
-
"aria-labelledby":
|
|
4627
|
+
ref: l,
|
|
4628
|
+
className: v(ye.drawer, ye[`drawer--${s}`], ye[`drawer--${i}`], d),
|
|
4629
|
+
"aria-labelledby": w,
|
|
4624
4630
|
"data-testid": c,
|
|
4625
4631
|
onClick: b,
|
|
4626
4632
|
children: [
|
|
4627
4633
|
/* @__PURE__ */ g("header", { className: ye.drawer__header, children: [
|
|
4628
|
-
/* @__PURE__ */ a("h2", { id:
|
|
4634
|
+
/* @__PURE__ */ a("h2", { id: w, className: ye.drawer__title, children: n }),
|
|
4629
4635
|
/* @__PURE__ */ a(
|
|
4630
4636
|
Re,
|
|
4631
4637
|
{
|
|
4632
4638
|
icon: /* @__PURE__ */ a(He, { "aria-hidden": !0 }),
|
|
4633
|
-
label: H("Drawer.closeLabel", r,
|
|
4639
|
+
label: H("Drawer.closeLabel", r, _ == null ? void 0 : _.close),
|
|
4634
4640
|
variant: "ghost",
|
|
4635
4641
|
size: "sm",
|
|
4636
4642
|
className: ye.drawer__close,
|
|
@@ -4638,9 +4644,9 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4638
4644
|
}
|
|
4639
4645
|
)
|
|
4640
4646
|
] }),
|
|
4641
|
-
|
|
4647
|
+
h && /* @__PURE__ */ a("div", { className: ye.drawer__toolbar, children: h }),
|
|
4642
4648
|
/* @__PURE__ */ a("div", { className: ye.drawer__body, children: o }),
|
|
4643
|
-
|
|
4649
|
+
u && /* @__PURE__ */ a("div", { className: ye.drawer__footer, children: u })
|
|
4644
4650
|
]
|
|
4645
4651
|
}
|
|
4646
4652
|
);
|
|
@@ -4654,27 +4660,27 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4654
4660
|
label: o,
|
|
4655
4661
|
submitLabel: s,
|
|
4656
4662
|
cancelLabel: i,
|
|
4657
|
-
closeLabel:
|
|
4658
|
-
description:
|
|
4663
|
+
closeLabel: u,
|
|
4664
|
+
description: h,
|
|
4659
4665
|
hint: d,
|
|
4660
4666
|
placeholder: c,
|
|
4661
|
-
defaultValue:
|
|
4662
|
-
isRequired:
|
|
4667
|
+
defaultValue: _ = "",
|
|
4668
|
+
isRequired: l,
|
|
4663
4669
|
requiredLabel: m,
|
|
4664
|
-
inputMode:
|
|
4670
|
+
inputMode: w = "text",
|
|
4665
4671
|
maxLength: b,
|
|
4666
4672
|
rows: p = 4
|
|
4667
4673
|
}) => {
|
|
4668
|
-
const { labels: y } = j(), D = J(), [N,
|
|
4674
|
+
const { labels: y } = j(), D = J(), [N, f] = P(_), [$, k] = P(!1), L = R(!1);
|
|
4669
4675
|
S(() => {
|
|
4670
|
-
e && !L.current &&
|
|
4671
|
-
}, [e,
|
|
4672
|
-
const C = N.trim(), E = !!
|
|
4676
|
+
e && !L.current && f(_), L.current = e;
|
|
4677
|
+
}, [e, _]);
|
|
4678
|
+
const C = N.trim(), E = !!l && C === "", x = (U) => w === "multiline" ? /* @__PURE__ */ a(
|
|
4673
4679
|
vi,
|
|
4674
4680
|
{
|
|
4675
4681
|
...U,
|
|
4676
4682
|
value: N,
|
|
4677
|
-
onChange: (
|
|
4683
|
+
onChange: (Q) => f(Q.target.value),
|
|
4678
4684
|
placeholder: c,
|
|
4679
4685
|
maxLength: b,
|
|
4680
4686
|
rows: p
|
|
@@ -4683,9 +4689,9 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4683
4689
|
li,
|
|
4684
4690
|
{
|
|
4685
4691
|
...U,
|
|
4686
|
-
type:
|
|
4692
|
+
type: w === "number" ? "number" : "text",
|
|
4687
4693
|
value: N,
|
|
4688
|
-
onChange: (
|
|
4694
|
+
onChange: (Q) => f(Q.target.value),
|
|
4689
4695
|
placeholder: c,
|
|
4690
4696
|
maxLength: b
|
|
4691
4697
|
}
|
|
@@ -4706,8 +4712,8 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4706
4712
|
isOpen: e,
|
|
4707
4713
|
onClose: t,
|
|
4708
4714
|
title: r,
|
|
4709
|
-
closeLabel:
|
|
4710
|
-
description:
|
|
4715
|
+
closeLabel: u ?? (y == null ? void 0 : y.close),
|
|
4716
|
+
description: h,
|
|
4711
4717
|
size: "sm",
|
|
4712
4718
|
isDismissable: !$,
|
|
4713
4719
|
footer: /* @__PURE__ */ g(fe, { children: [
|
|
@@ -4742,7 +4748,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4742
4748
|
onSubmit: (U) => {
|
|
4743
4749
|
U.preventDefault(), M();
|
|
4744
4750
|
},
|
|
4745
|
-
children: /* @__PURE__ */ a(Mi, { label: o, hint: d, isRequired:
|
|
4751
|
+
children: /* @__PURE__ */ a(Mi, { label: o, hint: d, isRequired: l, requiredLabel: m, children: x })
|
|
4746
4752
|
}
|
|
4747
4753
|
)
|
|
4748
4754
|
}
|
|
@@ -4760,7 +4766,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4760
4766
|
/* @__PURE__ */ I(({ hasFrame: e = !0, className: t, children: n, ...r }) => /* @__PURE__ */ a(
|
|
4761
4767
|
"div",
|
|
4762
4768
|
{
|
|
4763
|
-
className:
|
|
4769
|
+
className: v(_t.scroller, e && _t["scroller--frame"], t),
|
|
4764
4770
|
...r,
|
|
4765
4771
|
children: n
|
|
4766
4772
|
}
|
|
@@ -4776,7 +4782,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4776
4782
|
}) => /* @__PURE__ */ a(
|
|
4777
4783
|
"table",
|
|
4778
4784
|
{
|
|
4779
|
-
className:
|
|
4785
|
+
className: v(
|
|
4780
4786
|
_t.table,
|
|
4781
4787
|
_t[`table--${e}`],
|
|
4782
4788
|
t && _t["table--sticky-head"],
|
|
@@ -4809,36 +4815,36 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4809
4815
|
emptyMessage: o,
|
|
4810
4816
|
loadingMessage: s,
|
|
4811
4817
|
hasViewportCap: i,
|
|
4812
|
-
onSort:
|
|
4813
|
-
bulkBar:
|
|
4818
|
+
onSort: u,
|
|
4819
|
+
bulkBar: h,
|
|
4814
4820
|
className: d,
|
|
4815
4821
|
testId: c
|
|
4816
4822
|
}) => {
|
|
4817
|
-
var
|
|
4818
|
-
const { labels:
|
|
4823
|
+
var w, b;
|
|
4824
|
+
const { labels: _ } = j(), l = dn.count(t), m = (p, y) => /* @__PURE__ */ a("tr", { children: /* @__PURE__ */ a(
|
|
4819
4825
|
"td",
|
|
4820
4826
|
{
|
|
4821
4827
|
colSpan: e.length,
|
|
4822
|
-
className:
|
|
4828
|
+
className: v(ae.state, y && ae[`state--${y}`]),
|
|
4823
4829
|
children: p
|
|
4824
4830
|
}
|
|
4825
4831
|
) });
|
|
4826
4832
|
return /* @__PURE__ */ g(
|
|
4827
4833
|
"div",
|
|
4828
4834
|
{
|
|
4829
|
-
className:
|
|
4835
|
+
className: v(ae.wrapper, i && ae["wrapper--capped"], d),
|
|
4830
4836
|
"data-testid": c,
|
|
4831
4837
|
children: [
|
|
4832
|
-
|
|
4838
|
+
h && /* @__PURE__ */ a("div", { className: ae.bulkBar, children: h }),
|
|
4833
4839
|
/* @__PURE__ */ g("table", { className: ae.table, children: [
|
|
4834
4840
|
/* @__PURE__ */ a("thead", { children: /* @__PURE__ */ a("tr", { children: e.map((p) => {
|
|
4835
|
-
const y = !!(p.isSortable &&
|
|
4841
|
+
const y = !!(p.isSortable && u), D = p.ariaSort === "ascending" ? "descending" : "ascending";
|
|
4836
4842
|
return /* @__PURE__ */ a(
|
|
4837
4843
|
"th",
|
|
4838
4844
|
{
|
|
4839
4845
|
scope: "col",
|
|
4840
4846
|
"aria-sort": p.ariaSort,
|
|
4841
|
-
className:
|
|
4847
|
+
className: v(p.className, p.isSticky && ae.sticky),
|
|
4842
4848
|
children: y ? (
|
|
4843
4849
|
/*
|
|
4844
4850
|
* Siralama bir DUGME, `<th>`ye yazilan `onClick` degil.
|
|
@@ -4851,7 +4857,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4851
4857
|
{
|
|
4852
4858
|
type: "button",
|
|
4853
4859
|
className: ae.sort,
|
|
4854
|
-
onClick: () =>
|
|
4860
|
+
onClick: () => u == null ? void 0 : u(p.key, D),
|
|
4855
4861
|
children: [
|
|
4856
4862
|
p.label,
|
|
4857
4863
|
p.srLabel && /* @__PURE__ */ a("span", { className: ae.srOnly, children: p.srLabel }),
|
|
@@ -4859,7 +4865,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4859
4865
|
"span",
|
|
4860
4866
|
{
|
|
4861
4867
|
"aria-hidden": !0,
|
|
4862
|
-
className:
|
|
4868
|
+
className: v(
|
|
4863
4869
|
ae.sort__arrow,
|
|
4864
4870
|
p.ariaSort && ae[`sort__arrow--${p.ariaSort}`]
|
|
4865
4871
|
),
|
|
@@ -4887,17 +4893,17 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4887
4893
|
H(
|
|
4888
4894
|
"DataTable.loadingMessage",
|
|
4889
4895
|
s,
|
|
4890
|
-
(
|
|
4896
|
+
(w = _ == null ? void 0 : _.dataTable) == null ? void 0 : w.loading
|
|
4891
4897
|
)
|
|
4892
|
-
) :
|
|
4893
|
-
H("DataTable.emptyMessage", o, (b =
|
|
4898
|
+
) : l === 0 ? m(
|
|
4899
|
+
H("DataTable.emptyMessage", o, (b = _ == null ? void 0 : _.dataTable) == null ? void 0 : b.empty)
|
|
4894
4900
|
) : t })
|
|
4895
4901
|
] })
|
|
4896
4902
|
]
|
|
4897
4903
|
}
|
|
4898
4904
|
);
|
|
4899
4905
|
}, vh = /* @__PURE__ */ F(
|
|
4900
|
-
/* @__PURE__ */ I(({ isWarning: e, className: t, children: n, ...r }) => /* @__PURE__ */ a("tr", { className:
|
|
4906
|
+
/* @__PURE__ */ I(({ isWarning: e, className: t, children: n, ...r }) => /* @__PURE__ */ a("tr", { className: v(e && ae["row--warning"], t), ...r, children: n })),
|
|
4901
4907
|
"DataTableRow"
|
|
4902
4908
|
), yh = /* @__PURE__ */ I(B_), F_ = "hanui-bar-b4PP4", P_ = "hanui-bar__hiddenSubmit-jeCyX", O_ = "hanui-bar__actions-rG69L", z_ = "hanui-field-f-rvu", It = {
|
|
4903
4909
|
bar: F_,
|
|
@@ -4910,11 +4916,11 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4910
4916
|
return /* @__PURE__ */ g(
|
|
4911
4917
|
"form",
|
|
4912
4918
|
{
|
|
4913
|
-
className:
|
|
4919
|
+
className: v(It.bar, o),
|
|
4914
4920
|
"aria-label": H("FilterBar.label", r, i == null ? void 0 : i.filters),
|
|
4915
4921
|
"data-testid": s,
|
|
4916
|
-
onSubmit: (
|
|
4917
|
-
|
|
4922
|
+
onSubmit: (u) => {
|
|
4923
|
+
u.preventDefault(), e();
|
|
4918
4924
|
},
|
|
4919
4925
|
children: [
|
|
4920
4926
|
t,
|
|
@@ -4924,7 +4930,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4924
4930
|
}
|
|
4925
4931
|
);
|
|
4926
4932
|
}, wh = /* @__PURE__ */ F(
|
|
4927
|
-
/* @__PURE__ */ I(({ children: e, isWide: t, className: n }) => /* @__PURE__ */ a("div", { className:
|
|
4933
|
+
/* @__PURE__ */ I(({ children: e, isWide: t, className: n }) => /* @__PURE__ */ a("div", { className: v(It.field, t && It["field--wide"], n), children: e })),
|
|
4928
4934
|
"FilterBarField"
|
|
4929
4935
|
), xh = /* @__PURE__ */ I(H_), K_ = "hanui-pagination-K-L20", U_ = "hanui-pagination__list--9HqC", q_ = "hanui-pagination__arrow-XIgoX", j_ = "hanui-pagination__page-TpoJM", Y_ = "hanui-pagination__gap-qoDyI", Ce = {
|
|
4930
4936
|
pagination: K_,
|
|
@@ -4949,17 +4955,17 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4949
4955
|
nextLabel: o,
|
|
4950
4956
|
buildHref: s,
|
|
4951
4957
|
onPageChange: i,
|
|
4952
|
-
linkProps:
|
|
4953
|
-
formatAnnouncement:
|
|
4958
|
+
linkProps: u,
|
|
4959
|
+
formatAnnouncement: h,
|
|
4954
4960
|
className: d,
|
|
4955
4961
|
testId: c
|
|
4956
4962
|
}) => {
|
|
4957
4963
|
var p, y, D;
|
|
4958
|
-
const { labels:
|
|
4964
|
+
const { labels: _ } = j(), l = oa(), m = R(e);
|
|
4959
4965
|
S(() => {
|
|
4960
|
-
m.current !== e && (m.current = e,
|
|
4961
|
-
}, [e, t,
|
|
4962
|
-
const
|
|
4966
|
+
m.current !== e && (m.current = e, h && l(h(e, t)));
|
|
4967
|
+
}, [e, t, h, l]);
|
|
4968
|
+
const w = Tt(() => G_(e, t), [e, t]);
|
|
4963
4969
|
if (t <= 1) return null;
|
|
4964
4970
|
const b = (N) => {
|
|
4965
4971
|
i && i(N);
|
|
@@ -4967,8 +4973,8 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4967
4973
|
return /* @__PURE__ */ g(
|
|
4968
4974
|
"nav",
|
|
4969
4975
|
{
|
|
4970
|
-
className:
|
|
4971
|
-
"aria-label": H("Pagination.label", n, (p =
|
|
4976
|
+
className: v(Ce.pagination, d),
|
|
4977
|
+
"aria-label": H("Pagination.label", n, (p = _ == null ? void 0 : _.pagination) == null ? void 0 : p.label),
|
|
4972
4978
|
"data-testid": c,
|
|
4973
4979
|
children: [
|
|
4974
4980
|
/* @__PURE__ */ a(
|
|
@@ -4979,24 +4985,24 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
4979
4985
|
label: H(
|
|
4980
4986
|
"Pagination.previousLabel",
|
|
4981
4987
|
r,
|
|
4982
|
-
(y =
|
|
4988
|
+
(y = _ == null ? void 0 : _.pagination) == null ? void 0 : y.previous
|
|
4983
4989
|
),
|
|
4984
4990
|
variant: "outline",
|
|
4985
4991
|
disabled: e <= 1,
|
|
4986
4992
|
onClick: () => b(e - 1)
|
|
4987
4993
|
}
|
|
4988
4994
|
),
|
|
4989
|
-
/* @__PURE__ */ a("ul", { className: Ce.pagination__list, children:
|
|
4990
|
-
(N,
|
|
4995
|
+
/* @__PURE__ */ a("ul", { className: Ce.pagination__list, children: w.map(
|
|
4996
|
+
(N, f) => N === "gap" ? /* @__PURE__ */ a("li", { className: Ce.pagination__gap, "aria-hidden": !0, children: "…" }, `gap-${f}`) : /* @__PURE__ */ a("li", { children: s ? /* @__PURE__ */ a(
|
|
4991
4997
|
ke,
|
|
4992
4998
|
{
|
|
4993
4999
|
href: s(N),
|
|
4994
|
-
className:
|
|
5000
|
+
className: v(
|
|
4995
5001
|
Ce.pagination__page,
|
|
4996
5002
|
N === e && Ce["pagination__page--active"]
|
|
4997
5003
|
),
|
|
4998
5004
|
"aria-current": N === e ? "page" : void 0,
|
|
4999
|
-
...
|
|
5005
|
+
...u,
|
|
5000
5006
|
children: N
|
|
5001
5007
|
}
|
|
5002
5008
|
) : /* @__PURE__ */ a(
|
|
@@ -5004,7 +5010,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
5004
5010
|
{
|
|
5005
5011
|
variant: Se.SECONDARY,
|
|
5006
5012
|
size: et.SMALL,
|
|
5007
|
-
className:
|
|
5013
|
+
className: v(
|
|
5008
5014
|
Ce.pagination__page,
|
|
5009
5015
|
N === e && Ce["pagination__page--active"]
|
|
5010
5016
|
),
|
|
@@ -5019,7 +5025,7 @@ const la = () => aa.forEach((e) => e(tt)), na = (e) => {
|
|
|
5019
5025
|
{
|
|
5020
5026
|
className: Ce.pagination__arrow,
|
|
5021
5027
|
icon: /* @__PURE__ */ a(Kt, { "aria-hidden": !0 }),
|
|
5022
|
-
label: H("Pagination.nextLabel", o, (D =
|
|
5028
|
+
label: H("Pagination.nextLabel", o, (D = _ == null ? void 0 : _.pagination) == null ? void 0 : D.next),
|
|
5023
5029
|
variant: "outline",
|
|
5024
5030
|
disabled: e >= t,
|
|
5025
5031
|
onClick: () => b(e + 1)
|
|
@@ -5036,7 +5042,7 @@ export {
|
|
|
5036
5042
|
Eu as Alert,
|
|
5037
5043
|
Lu as Avatar,
|
|
5038
5044
|
Su as Badge,
|
|
5039
|
-
|
|
5045
|
+
Wa as BottomSheet,
|
|
5040
5046
|
Ru as Breadcrumb,
|
|
5041
5047
|
Ct as Button,
|
|
5042
5048
|
tu as COMPACT_DENSITY,
|
|
@@ -5080,9 +5086,9 @@ export {
|
|
|
5080
5086
|
Ja as Modal,
|
|
5081
5087
|
Gu as PageHeader,
|
|
5082
5088
|
kh as Pagination,
|
|
5083
|
-
|
|
5089
|
+
Qu as Panel,
|
|
5084
5090
|
Xu as PanelForm,
|
|
5085
|
-
|
|
5091
|
+
Wu as PanelRow,
|
|
5086
5092
|
uu as Popover,
|
|
5087
5093
|
Ju as Price,
|
|
5088
5094
|
Yi as Progress,
|