@konstructio/ui 0.1.2-alpha.3 → 0.1.2-alpha.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (163) hide show
  1. package/dist/DatePicker.css +1 -1
  2. package/dist/Modal-5xSxFoaD.js +99 -0
  3. package/dist/_commonjsHelpers-DaMA6jEr.js +8 -0
  4. package/dist/chevron-down-DgT-uSF9.js +5 -0
  5. package/dist/chevron-right-DYvXLeql.js +7 -0
  6. package/dist/chevron-up-DrQr2Fwd.js +5 -0
  7. package/dist/components/Alert/Alert.js +2 -2
  8. package/dist/components/AlertDialog/AlertDialog.js +1 -1
  9. package/dist/components/AlertDialog/components/AlertDialogTrigger.js +1 -1
  10. package/dist/components/AlertDialog/components/index.js +1 -1
  11. package/dist/components/Badge/Badge.js +30 -33
  12. package/dist/components/Badge/Badge.variants.js +8 -6
  13. package/dist/components/Breadcrumb/Breadcrumb.js +1 -1
  14. package/dist/components/Breadcrumb/components/Item/Item.js +24 -23
  15. package/dist/components/Breadcrumb/hooks/useBreadcrumb.js +1 -1
  16. package/dist/components/Button/Button.js +1 -1
  17. package/dist/components/Button/Button.variants.js +1 -1
  18. package/dist/components/Card/Card.variants.js +5 -9
  19. package/dist/components/Checkbox/Checkbox.js +6 -6
  20. package/dist/components/Command/Command.js +2 -2
  21. package/dist/components/Command/components/Command.js +1 -1
  22. package/dist/components/Command/components/CommandEmpty.js +1 -1
  23. package/dist/components/Command/components/CommandGroup.js +1 -1
  24. package/dist/components/Command/components/CommandInput.js +2 -2
  25. package/dist/components/Command/components/CommandItem.js +1 -1
  26. package/dist/components/Command/components/CommandList.js +1 -1
  27. package/dist/components/Command/components/CommandSeparator.js +1 -1
  28. package/dist/components/Command/components/DialogContent.js +2 -2
  29. package/dist/components/Command/components/DialogOverlay.js +1 -1
  30. package/dist/components/Datepicker/DatePicker.js +1209 -1147
  31. package/dist/components/Divider/Divider.variants.js +1 -1
  32. package/dist/components/Dropdown/Dropdown.js +46 -28
  33. package/dist/components/Dropdown/Dropdown.variants.js +32 -9
  34. package/dist/components/Dropdown/components/List/List.js +133 -54
  35. package/dist/components/Dropdown/components/List/List.variants.js +9 -7
  36. package/dist/components/Dropdown/components/ListItem/ListItem.js +74 -24
  37. package/dist/components/Dropdown/components/ListItem/ListItem.variants.js +9 -7
  38. package/dist/components/Dropdown/components/Wrapper.js +144 -109
  39. package/dist/components/Dropdown/constants/index.js +4 -0
  40. package/dist/components/Dropdown/constants/pagination.js +4 -0
  41. package/dist/components/Dropdown/contexts/dropdown.context.js +26 -8
  42. package/dist/components/Dropdown/contexts/dropdown.provider.js +48 -19
  43. package/dist/components/Dropdown/hooks/useDropdown.js +83 -39
  44. package/dist/components/Dropdown/hooks/useNavigationList.js +28 -36
  45. package/dist/components/DropdownButton/DropdownButton.js +1 -1
  46. package/dist/components/Filter/Filter.variants.js +2 -2
  47. package/dist/components/Filter/components/BadgeDropdown/BadgeMultiSelect.js +1 -1
  48. package/dist/components/Filter/components/DateFilterDropdown/DateFilterDropdown.js +1 -1
  49. package/dist/components/Input/Input.js +1 -1
  50. package/dist/components/Input/Input.variants.js +1 -1
  51. package/dist/components/Loading/Loading.js +1 -7
  52. package/dist/components/Modal/Modal.js +2 -2
  53. package/dist/components/Modal/components/Body/Body.js +1 -1
  54. package/dist/components/Modal/components/Footer/Footer.js +1 -1
  55. package/dist/components/Modal/components/Header/Header.js +1 -1
  56. package/dist/components/Modal/components/Wrapper/Wrapper.js +3 -3
  57. package/dist/components/Modal/components/index.js +1 -1
  58. package/dist/components/NumberInput/NumberInput.js +2 -2
  59. package/dist/components/PhoneNumberInput/PhoneNumberInput.js +8 -0
  60. package/dist/components/PhoneNumberInput/PhoneNumberInput.variants.js +45 -0
  61. package/dist/components/PhoneNumberInput/components/FlagContent/FlagContent.js +27 -0
  62. package/dist/components/PhoneNumberInput/components/FlagSelectorList/FlagSelectorList.js +629 -0
  63. package/dist/components/PhoneNumberInput/components/FlagSelectorWrapper/FlagSelectorWrapper.js +36 -0
  64. package/dist/components/PhoneNumberInput/components/TruncateText/TruncateText.js +45 -0
  65. package/dist/components/PhoneNumberInput/components/Wrapper.js +625 -0
  66. package/dist/components/PhoneNumberInput/components/index.js +6 -0
  67. package/dist/components/PhoneNumberInput/contexts/index.js +8 -0
  68. package/dist/components/PhoneNumberInput/contexts/phone-number.context.js +28 -0
  69. package/dist/components/PhoneNumberInput/contexts/phone-number.hook.js +13 -0
  70. package/dist/components/PhoneNumberInput/contexts/phone-number.provider.js +6137 -0
  71. package/dist/components/PhoneNumberInput/utils/index.js +11 -0
  72. package/dist/components/PieChart/PieChart.js +647 -664
  73. package/dist/components/RadioCard/RadioCard.variants.js +1 -6
  74. package/dist/components/RadioGroup/RadioGroup.js +1 -1
  75. package/dist/components/Range/Range.js +1 -1
  76. package/dist/components/Sidebar/Sidebar.variants.js +2 -2
  77. package/dist/components/Sidebar/components/Wrapper/Wrapper.js +29 -28
  78. package/dist/components/Slider/Slider.js +1 -1
  79. package/dist/components/Switch/Switch.js +8 -8
  80. package/dist/components/Switch/Switch.variants.js +4 -4
  81. package/dist/components/Tabs/Tabs.js +1 -1
  82. package/dist/components/Tabs/Tabs.variants.js +45 -24
  83. package/dist/components/Tabs/components/Content.js +1 -1
  84. package/dist/components/Tabs/components/List.js +1 -1
  85. package/dist/components/Tabs/components/Trigger.js +9 -8
  86. package/dist/components/Tag/Tag.js +1 -1
  87. package/dist/components/TagSelect/components/Wrapper/Wrapper.js +98 -49
  88. package/dist/components/TimePicker/TimePicker.variants.js +2 -2
  89. package/dist/components/TimePicker/components/Wrapper/Wrapper.js +2 -2
  90. package/dist/components/Toast/Toast.js +206 -181
  91. package/dist/components/Tooltip/Tooltip.js +1 -1
  92. package/dist/components/Typography/Typography.variants.js +18 -23
  93. package/dist/components/VirtualizedTable/VirtualizedTable.js +119 -0
  94. package/dist/components/VirtualizedTable/VirtualizedTable.variants.js +5 -0
  95. package/dist/components/VirtualizedTable/assets/chevron-down.js +25 -0
  96. package/dist/components/VirtualizedTable/assets/chevron-up.js +25 -0
  97. package/dist/components/VirtualizedTable/assets/index.js +6 -0
  98. package/dist/components/VirtualizedTable/components/Actions/Actions.js +72 -0
  99. package/dist/components/VirtualizedTable/components/Body/Body.js +51 -0
  100. package/dist/components/VirtualizedTable/components/DotPaginate/DotPaginate.js +165 -0
  101. package/dist/components/VirtualizedTable/components/DropdownPaginate/DropdownPaginate.js +34 -0
  102. package/dist/components/VirtualizedTable/components/Filter/Filter.js +88 -0
  103. package/dist/components/VirtualizedTable/components/FormPaginate/FormPaginate.js +48 -0
  104. package/dist/components/VirtualizedTable/components/Header/Header.js +84 -0
  105. package/dist/components/VirtualizedTable/components/Pagination/Pagination.js +53 -0
  106. package/dist/components/VirtualizedTable/components/Skeleton/Skeleton.js +67 -0
  107. package/dist/components/VirtualizedTable/components/TruncateText/TruncateText.js +34 -0
  108. package/dist/components/VirtualizedTable/components/WrapperBody/WrapperBody.js +27 -0
  109. package/dist/components/VirtualizedTable/components/index.js +16 -0
  110. package/dist/components/VirtualizedTable/constants/index.js +5 -0
  111. package/dist/components/VirtualizedTable/constants/pagination.js +5 -0
  112. package/dist/components/VirtualizedTable/contexts/index.js +8 -0
  113. package/dist/components/VirtualizedTable/contexts/table.context.js +32 -0
  114. package/dist/components/VirtualizedTable/contexts/table.hook.js +11 -0
  115. package/dist/components/VirtualizedTable/contexts/table.provider.js +85 -0
  116. package/dist/components/index.js +79 -73
  117. package/dist/contexts/theme.provider.js +0 -1
  118. package/dist/{createLucideIcon-DbC6TvM5.js → createLucideIcon-D4r5Phnh.js} +0 -24
  119. package/dist/debounce-BFejQm9P.js +200 -0
  120. package/dist/ellipsis-vertical-BVPtjl5f.js +9 -0
  121. package/dist/{index-h-Ul0anl.js → index--V_ZsiQe.js} +1 -22
  122. package/dist/index-2hB40Iuc.js +1873 -0
  123. package/dist/index-BZPx6jYI.js +8 -0
  124. package/dist/{index-bwWKd82e.js → index-BbQkJE5L.js} +1 -1
  125. package/dist/index-BtQfgaSF.js +60 -0
  126. package/dist/index-C3tHPg8y.js +662 -0
  127. package/dist/index-CIAmiWcw.js +200 -0
  128. package/dist/index-CSFe9uC5.js +14 -0
  129. package/dist/index-CSWGJT-v.js +1722 -0
  130. package/dist/index-CigKKiZS.js +91 -0
  131. package/dist/index-DDByhzds.js +137 -0
  132. package/dist/{index-BAraV3ai.js → index-DH2Fnov1.js} +11 -12
  133. package/dist/index-DLcqcWxM.js +29 -0
  134. package/dist/index-Dbt2vBmS.js +136 -0
  135. package/dist/{index-DB2XhXHn.js → index-DpW9ExsS.js} +7 -7
  136. package/dist/index-DrWQH0QF.js +55 -0
  137. package/dist/{index-D3xzCzcO.js → index-X4k_cU8k.js} +4 -4
  138. package/dist/index-kyuBfLcN.js +479 -0
  139. package/dist/{index-C1g_chDT.js → index-mPY_8Y5v.js} +2 -2
  140. package/dist/index-ohdbKsws.js +27 -0
  141. package/dist/index.d.ts +184 -18
  142. package/dist/index.js +106 -98
  143. package/dist/libphonenumber-_7ZyKWA7.js +11549 -0
  144. package/dist/package.json +46 -32
  145. package/dist/styles.css +1 -1
  146. package/dist/ui/civo-theme.css +191 -167
  147. package/dist/{useBreadcrumb-B8DnuqkR.js → useBreadcrumb-BAHbGQ_O.js} +0 -10
  148. package/dist/utils/index.js +534 -501
  149. package/dist/{x-BPcqkRZd.js → x-DPU9OdYH.js} +1 -1
  150. package/package.json +46 -32
  151. package/dist/Modal-V67Uz78z.js +0 -98
  152. package/dist/_commonjsHelpers-C6fGbg64.js +0 -6
  153. package/dist/chevron-down-BLZPftpV.js +0 -11
  154. package/dist/chevron-up-RLP4nX7V.js +0 -54
  155. package/dist/index-BXuxPoz7.js +0 -435
  156. package/dist/index-BfXxHr_2.js +0 -125
  157. package/dist/index-C9T9HQaa.js +0 -423
  158. package/dist/index-CZnD2QxM.js +0 -32
  159. package/dist/index-CrBonFvu.js +0 -144
  160. package/dist/index-Cvx4lqTq.js +0 -47
  161. package/dist/index-DQH6odE9.js +0 -82
  162. package/dist/index-Oq5GlCHP.js +0 -131
  163. package/dist/index-iXyXtdgP.js +0 -31
@@ -0,0 +1,91 @@
1
+ import * as l from "react";
2
+ import R from "react";
3
+ import { c as T } from "./index-CIAmiWcw.js";
4
+ import { c as P, u as A } from "./index-DLcqcWxM.js";
5
+ import { jsx as E } from "react/jsx-runtime";
6
+ // @__NO_SIDE_EFFECTS__
7
+ function M(e) {
8
+ const t = /* @__PURE__ */ v(e), n = l.forwardRef((r, o) => {
9
+ const { children: c, ...a } = r, s = l.Children.toArray(c), d = s.find(w);
10
+ if (d) {
11
+ const f = d.props.children, y = s.map((I) => I === d ? l.Children.count(f) > 1 ? l.Children.only(null) : l.isValidElement(f) ? f.props.children : null : I);
12
+ return /* @__PURE__ */ E(t, { ...a, ref: o, children: l.isValidElement(f) ? l.cloneElement(f, void 0, y) : null });
13
+ }
14
+ return /* @__PURE__ */ E(t, { ...a, ref: o, children: c });
15
+ });
16
+ return n.displayName = `${e}.Slot`, n;
17
+ }
18
+ // @__NO_SIDE_EFFECTS__
19
+ function v(e) {
20
+ const t = l.forwardRef((n, r) => {
21
+ const { children: o, ...c } = n;
22
+ if (l.isValidElement(o)) {
23
+ const a = D(o), s = V(c, o.props);
24
+ return o.type !== l.Fragment && (s.ref = r ? P(r, a) : a), l.cloneElement(o, s);
25
+ }
26
+ return l.Children.count(o) > 1 ? l.Children.only(null) : null;
27
+ });
28
+ return t.displayName = `${e}.SlotClone`, t;
29
+ }
30
+ var b = Symbol("radix.slottable");
31
+ function w(e) {
32
+ return l.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === b;
33
+ }
34
+ function V(e, t) {
35
+ const n = { ...t };
36
+ for (const r in t) {
37
+ const o = e[r], c = t[r];
38
+ /^on[A-Z]/.test(r) ? o && c ? n[r] = (...s) => {
39
+ const d = c(...s);
40
+ return o(...s), d;
41
+ } : o && (n[r] = o) : r === "style" ? n[r] = { ...o, ...c } : r === "className" && (n[r] = [o, c].filter(Boolean).join(" "));
42
+ }
43
+ return { ...e, ...n };
44
+ }
45
+ function D(e) {
46
+ let t = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning;
47
+ return n ? e.ref : (t = Object.getOwnPropertyDescriptor(e, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
48
+ }
49
+ function B(e) {
50
+ const t = e + "CollectionProvider", [n, r] = T(t), [o, c] = n(
51
+ t,
52
+ { collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
53
+ ), a = (m) => {
54
+ const { scope: i, children: S } = m, u = R.useRef(null), p = R.useRef(/* @__PURE__ */ new Map()).current;
55
+ return /* @__PURE__ */ E(o, { scope: i, itemMap: p, collectionRef: u, children: S });
56
+ };
57
+ a.displayName = t;
58
+ const s = e + "CollectionSlot", d = /* @__PURE__ */ M(s), f = R.forwardRef(
59
+ (m, i) => {
60
+ const { scope: S, children: u } = m, p = c(s, S), C = A(i, p.collectionRef);
61
+ return /* @__PURE__ */ E(d, { ref: C, children: u });
62
+ }
63
+ );
64
+ f.displayName = s;
65
+ const y = e + "CollectionItemSlot", I = "data-radix-collection-item", N = /* @__PURE__ */ M(y), _ = R.forwardRef(
66
+ (m, i) => {
67
+ const { scope: S, children: u, ...p } = m, C = R.useRef(null), g = A(i, C), x = c(y, S);
68
+ return R.useEffect(() => (x.itemMap.set(C, { ref: C, ...p }), () => void x.itemMap.delete(C))), /* @__PURE__ */ E(N, { [I]: "", ref: g, children: u });
69
+ }
70
+ );
71
+ _.displayName = y;
72
+ function O(m) {
73
+ const i = c(e + "CollectionConsumer", m);
74
+ return R.useCallback(() => {
75
+ const u = i.collectionRef.current;
76
+ if (!u) return [];
77
+ const p = Array.from(u.querySelectorAll(`[${I}]`));
78
+ return Array.from(i.itemMap.values()).sort(
79
+ (x, h) => p.indexOf(x.ref.current) - p.indexOf(h.ref.current)
80
+ );
81
+ }, [i.collectionRef, i.itemMap]);
82
+ }
83
+ return [
84
+ { Provider: a, Slot: f, ItemSlot: _ },
85
+ O,
86
+ r
87
+ ];
88
+ }
89
+ export {
90
+ B as c
91
+ };
@@ -0,0 +1,137 @@
1
+ import { jsx as a, Fragment as O, jsxs as w } from "react/jsx-runtime";
2
+ import * as l from "react";
3
+ import { c as I, b as x } from "./index-CIAmiWcw.js";
4
+ import { u } from "./index-DLcqcWxM.js";
5
+ import { c as A, R as M, P as L, O as $, W as F, C as B, T as G, d as W, b as v, e as j } from "./index-kyuBfLcN.js";
6
+ import { Button as Y } from "./components/Button/Button.js";
7
+ import { cn as k } from "./utils/index.js";
8
+ var q = Symbol("radix.slottable");
9
+ // @__NO_SIDE_EFFECTS__
10
+ function H(r) {
11
+ const e = ({ children: o }) => /* @__PURE__ */ a(O, { children: o });
12
+ return e.displayName = `${r}.Slottable`, e.__radixId = q, e;
13
+ }
14
+ var D = "AlertDialog", [V, ne] = I(D, [
15
+ A
16
+ ]), s = A(), f = (r) => {
17
+ const { __scopeAlertDialog: e, ...o } = r, t = s(e);
18
+ return /* @__PURE__ */ a(M, { ...t, ...o, modal: !0 });
19
+ };
20
+ f.displayName = D;
21
+ var z = "AlertDialogTrigger", m = l.forwardRef(
22
+ (r, e) => {
23
+ const { __scopeAlertDialog: o, ...t } = r, i = s(o);
24
+ return /* @__PURE__ */ a(j, { ...i, ...t, ref: e });
25
+ }
26
+ );
27
+ m.displayName = z;
28
+ var J = "AlertDialogPortal", _ = (r) => {
29
+ const { __scopeAlertDialog: e, ...o } = r, t = s(e);
30
+ return /* @__PURE__ */ a(L, { ...t, ...o });
31
+ };
32
+ _.displayName = J;
33
+ var K = "AlertDialogOverlay", y = l.forwardRef(
34
+ (r, e) => {
35
+ const { __scopeAlertDialog: o, ...t } = r, i = s(o);
36
+ return /* @__PURE__ */ a($, { ...i, ...t, ref: e });
37
+ }
38
+ );
39
+ y.displayName = K;
40
+ var n = "AlertDialogContent", [Q, U] = V(n), X = /* @__PURE__ */ H("AlertDialogContent"), N = l.forwardRef(
41
+ (r, e) => {
42
+ const { __scopeAlertDialog: o, children: t, ...i } = r, d = s(o), p = l.useRef(null), P = u(e, p), g = l.useRef(null);
43
+ return /* @__PURE__ */ a(
44
+ F,
45
+ {
46
+ contentName: n,
47
+ titleName: h,
48
+ docsSlug: "alert-dialog",
49
+ children: /* @__PURE__ */ a(Q, { scope: o, cancelRef: g, children: /* @__PURE__ */ w(
50
+ B,
51
+ {
52
+ role: "alertdialog",
53
+ ...d,
54
+ ...i,
55
+ ref: P,
56
+ onOpenAutoFocus: x(i.onOpenAutoFocus, (c) => {
57
+ c.preventDefault(), g.current?.focus({ preventScroll: !0 });
58
+ }),
59
+ onPointerDownOutside: (c) => c.preventDefault(),
60
+ onInteractOutside: (c) => c.preventDefault(),
61
+ children: [
62
+ /* @__PURE__ */ a(X, { children: t }),
63
+ /* @__PURE__ */ a(ee, { contentRef: p })
64
+ ]
65
+ }
66
+ ) })
67
+ }
68
+ );
69
+ }
70
+ );
71
+ N.displayName = n;
72
+ var h = "AlertDialogTitle", R = l.forwardRef(
73
+ (r, e) => {
74
+ const { __scopeAlertDialog: o, ...t } = r, i = s(o);
75
+ return /* @__PURE__ */ a(G, { ...i, ...t, ref: e });
76
+ }
77
+ );
78
+ R.displayName = h;
79
+ var C = "AlertDialogDescription", S = l.forwardRef((r, e) => {
80
+ const { __scopeAlertDialog: o, ...t } = r, i = s(o);
81
+ return /* @__PURE__ */ a(W, { ...i, ...t, ref: e });
82
+ });
83
+ S.displayName = C;
84
+ var Z = "AlertDialogAction", E = l.forwardRef(
85
+ (r, e) => {
86
+ const { __scopeAlertDialog: o, ...t } = r, i = s(o);
87
+ return /* @__PURE__ */ a(v, { ...i, ...t, ref: e });
88
+ }
89
+ );
90
+ E.displayName = Z;
91
+ var T = "AlertDialogCancel", b = l.forwardRef(
92
+ (r, e) => {
93
+ const { __scopeAlertDialog: o, ...t } = r, { cancelRef: i } = U(T, o), d = s(o), p = u(e, i);
94
+ return /* @__PURE__ */ a(v, { ...d, ...t, ref: p });
95
+ }
96
+ );
97
+ b.displayName = T;
98
+ var ee = ({ contentRef: r }) => {
99
+ const e = `\`${n}\` requires a description for the component to be accessible for screen reader users.
100
+
101
+ You can add a description to the \`${n}\` by passing a \`${C}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
102
+
103
+ Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${n}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
104
+
105
+ For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;
106
+ return l.useEffect(() => {
107
+ document.getElementById(
108
+ r.current?.getAttribute("aria-describedby")
109
+ ) || console.warn(e);
110
+ }, [e, r]), null;
111
+ }, ce = f, re = m, pe = _, de = y, ge = N, ue = E, Ae = b, ve = R, De = S;
112
+ const fe = ({
113
+ "data-theme": r,
114
+ className: e,
115
+ text: o,
116
+ onOpen: t
117
+ }) => /* @__PURE__ */ a(re, { asChild: !0, children: /* @__PURE__ */ a(
118
+ Y,
119
+ {
120
+ type: "button",
121
+ "data-theme": r,
122
+ className: k(e),
123
+ onClick: t,
124
+ children: o
125
+ }
126
+ ) });
127
+ export {
128
+ fe as A,
129
+ ge as C,
130
+ De as D,
131
+ de as O,
132
+ pe as P,
133
+ ce as R,
134
+ ve as T,
135
+ Ae as a,
136
+ ue as b
137
+ };
@@ -1,13 +1,12 @@
1
1
  import * as s from "react";
2
- import { c as K, b as I, a as L } from "./index-BfXxHr_2.js";
3
- import { c as ce } from "./index-Cvx4lqTq.js";
4
- import { u as ie } from "./index-DQH6odE9.js";
5
- import { u as O } from "./index-bwWKd82e.js";
6
- import { P as C } from "./index-C9T9HQaa.js";
2
+ import { c as K, P as C, b as I, a as L } from "./index-CIAmiWcw.js";
3
+ import { c as ce } from "./index-CigKKiZS.js";
4
+ import { u as ie } from "./index-DLcqcWxM.js";
5
+ import { u as O } from "./index-BbQkJE5L.js";
7
6
  import { u as ue } from "./index-0ioNhtNM.js";
8
7
  import { u as k } from "./index-BdMNhZnh.js";
9
8
  import { jsx as l } from "react/jsx-runtime";
10
- import { P as le } from "./index-C1g_chDT.js";
9
+ import { P as le } from "./index-mPY_8Y5v.js";
11
10
  var N = "rovingFocusGroup.onEntryFocus", de = { bubbles: !1, cancelable: !0 }, h = "RovingFocusGroup", [D, V, fe] = ce(h), [ve, U] = K(
12
11
  h,
13
12
  [fe]
@@ -172,7 +171,7 @@ function z(e, o = !1) {
172
171
  function Fe(e, o) {
173
172
  return e.map((n, t) => e[(o + t) % e.length]);
174
173
  }
175
- var Re = B, Ce = Y, _ = "Tabs", [he, Ge] = K(_, [
174
+ var Re = B, Ce = Y, _ = "Tabs", [he, Me] = K(_, [
176
175
  U
177
176
  ]), H = U(), [Ee, x] = he(_), j = s.forwardRef(
178
177
  (e, o) => {
@@ -314,10 +313,10 @@ function ee(e, o) {
314
313
  function te(e, o) {
315
314
  return `${e}-content-${o}`;
316
315
  }
317
- var Ke = j, Le = J, Oe = W, ke = Z;
316
+ var Ge = j, Ke = J, Le = W, Oe = Z;
318
317
  export {
319
- ke as C,
320
- Le as L,
321
- Ke as R,
322
- Oe as T
318
+ Oe as C,
319
+ Ke as L,
320
+ Ge as R,
321
+ Le as T
323
322
  };
@@ -0,0 +1,29 @@
1
+ import * as l from "react";
2
+ function s(n, o) {
3
+ if (typeof n == "function")
4
+ return n(o);
5
+ n != null && (n.current = o);
6
+ }
7
+ function f(...n) {
8
+ return (o) => {
9
+ let u = !1;
10
+ const c = n.map((t) => {
11
+ const e = s(t, o);
12
+ return !u && typeof e == "function" && (u = !0), e;
13
+ });
14
+ if (u)
15
+ return () => {
16
+ for (let t = 0; t < c.length; t++) {
17
+ const e = c[t];
18
+ typeof e == "function" ? e() : s(n[t], null);
19
+ }
20
+ };
21
+ };
22
+ }
23
+ function i(...n) {
24
+ return l.useCallback(f(...n), n);
25
+ }
26
+ export {
27
+ f as c,
28
+ i as u
29
+ };
@@ -0,0 +1,136 @@
1
+ import * as i from "react";
2
+ import { P as R, b as h, d as z } from "./index-CIAmiWcw.js";
3
+ import { u as g } from "./index-DLcqcWxM.js";
4
+ import { u as m } from "./index-0ioNhtNM.js";
5
+ import { jsx as B } from "react/jsx-runtime";
6
+ function H(n, e = globalThis?.document) {
7
+ const t = m(n);
8
+ i.useEffect(() => {
9
+ const o = (s) => {
10
+ s.key === "Escape" && t(s);
11
+ };
12
+ return e.addEventListener("keydown", o, { capture: !0 }), () => e.removeEventListener("keydown", o, { capture: !0 });
13
+ }, [t, e]);
14
+ }
15
+ var K = "DismissableLayer", p = "dismissableLayer.update", M = "dismissableLayer.pointerDownOutside", j = "dismissableLayer.focusOutside", C, T = i.createContext({
16
+ layers: /* @__PURE__ */ new Set(),
17
+ layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
18
+ branches: /* @__PURE__ */ new Set()
19
+ }), x = i.forwardRef(
20
+ (n, e) => {
21
+ const {
22
+ disableOutsidePointerEvents: t = !1,
23
+ onEscapeKeyDown: o,
24
+ onPointerDownOutside: s,
25
+ onFocusOutside: c,
26
+ onInteractOutside: f,
27
+ onDismiss: d,
28
+ ...E
29
+ } = n, a = i.useContext(T), [u, S] = i.useState(null), l = u?.ownerDocument ?? globalThis?.document, [, W] = i.useState({}), k = g(e, (r) => S(r)), b = Array.from(a.layers), [A] = [...a.layersWithOutsidePointerEventsDisabled].slice(-1), N = b.indexOf(A), D = u ? b.indexOf(u) : -1, _ = a.layersWithOutsidePointerEventsDisabled.size > 0, P = D >= N, U = Y((r) => {
30
+ const v = r.target, L = [...a.branches].some((y) => y.contains(v));
31
+ !P || L || (s?.(r), f?.(r), r.defaultPrevented || d?.());
32
+ }, l), O = q((r) => {
33
+ const v = r.target;
34
+ [...a.branches].some((y) => y.contains(v)) || (c?.(r), f?.(r), r.defaultPrevented || d?.());
35
+ }, l);
36
+ return H((r) => {
37
+ D === a.layers.size - 1 && (o?.(r), !r.defaultPrevented && d && (r.preventDefault(), d()));
38
+ }, l), i.useEffect(() => {
39
+ if (u)
40
+ return t && (a.layersWithOutsidePointerEventsDisabled.size === 0 && (C = l.body.style.pointerEvents, l.body.style.pointerEvents = "none"), a.layersWithOutsidePointerEventsDisabled.add(u)), a.layers.add(u), w(), () => {
41
+ t && a.layersWithOutsidePointerEventsDisabled.size === 1 && (l.body.style.pointerEvents = C);
42
+ };
43
+ }, [u, l, t, a]), i.useEffect(() => () => {
44
+ u && (a.layers.delete(u), a.layersWithOutsidePointerEventsDisabled.delete(u), w());
45
+ }, [u, a]), i.useEffect(() => {
46
+ const r = () => W({});
47
+ return document.addEventListener(p, r), () => document.removeEventListener(p, r);
48
+ }, []), /* @__PURE__ */ B(
49
+ R.div,
50
+ {
51
+ ...E,
52
+ ref: k,
53
+ style: {
54
+ pointerEvents: _ ? P ? "auto" : "none" : void 0,
55
+ ...n.style
56
+ },
57
+ onFocusCapture: h(n.onFocusCapture, O.onFocusCapture),
58
+ onBlurCapture: h(n.onBlurCapture, O.onBlurCapture),
59
+ onPointerDownCapture: h(
60
+ n.onPointerDownCapture,
61
+ U.onPointerDownCapture
62
+ )
63
+ }
64
+ );
65
+ }
66
+ );
67
+ x.displayName = K;
68
+ var X = "DismissableLayerBranch", F = i.forwardRef((n, e) => {
69
+ const t = i.useContext(T), o = i.useRef(null), s = g(e, o);
70
+ return i.useEffect(() => {
71
+ const c = o.current;
72
+ if (c)
73
+ return t.branches.add(c), () => {
74
+ t.branches.delete(c);
75
+ };
76
+ }, [t.branches]), /* @__PURE__ */ B(R.div, { ...n, ref: s });
77
+ });
78
+ F.displayName = X;
79
+ function Y(n, e = globalThis?.document) {
80
+ const t = m(n), o = i.useRef(!1), s = i.useRef(() => {
81
+ });
82
+ return i.useEffect(() => {
83
+ const c = (d) => {
84
+ if (d.target && !o.current) {
85
+ let E = function() {
86
+ I(
87
+ M,
88
+ t,
89
+ a,
90
+ { discrete: !0 }
91
+ );
92
+ };
93
+ const a = { originalEvent: d };
94
+ d.pointerType === "touch" ? (e.removeEventListener("click", s.current), s.current = E, e.addEventListener("click", s.current, { once: !0 })) : E();
95
+ } else
96
+ e.removeEventListener("click", s.current);
97
+ o.current = !1;
98
+ }, f = window.setTimeout(() => {
99
+ e.addEventListener("pointerdown", c);
100
+ }, 0);
101
+ return () => {
102
+ window.clearTimeout(f), e.removeEventListener("pointerdown", c), e.removeEventListener("click", s.current);
103
+ };
104
+ }, [e, t]), {
105
+ // ensures we check React component tree (not just DOM tree)
106
+ onPointerDownCapture: () => o.current = !0
107
+ };
108
+ }
109
+ function q(n, e = globalThis?.document) {
110
+ const t = m(n), o = i.useRef(!1);
111
+ return i.useEffect(() => {
112
+ const s = (c) => {
113
+ c.target && !o.current && I(j, t, { originalEvent: c }, {
114
+ discrete: !1
115
+ });
116
+ };
117
+ return e.addEventListener("focusin", s), () => e.removeEventListener("focusin", s);
118
+ }, [e, t]), {
119
+ onFocusCapture: () => o.current = !0,
120
+ onBlurCapture: () => o.current = !1
121
+ };
122
+ }
123
+ function w() {
124
+ const n = new CustomEvent(p);
125
+ document.dispatchEvent(n);
126
+ }
127
+ function I(n, e, t, { discrete: o }) {
128
+ const s = t.originalEvent.target, c = new CustomEvent(n, { bubbles: !1, cancelable: !0, detail: t });
129
+ e && s.addEventListener(n, e, { once: !0 }), o ? z(s, c) : s.dispatchEvent(c);
130
+ }
131
+ var Z = x, $ = F;
132
+ export {
133
+ $ as B,
134
+ x as D,
135
+ Z as R
136
+ };
@@ -1,10 +1,10 @@
1
1
  import * as l from "react";
2
- import { a as ce, c as le, b as _ } from "./index-BfXxHr_2.js";
3
- import { u as M } from "./index-DQH6odE9.js";
2
+ import { a as ce, c as le, b as _, P as T } from "./index-CIAmiWcw.js";
3
+ import { u as M } from "./index-DLcqcWxM.js";
4
4
  import { u as de } from "./index-BdMNhZnh.js";
5
- import { a as ue, u as fe } from "./index-CZnD2QxM.js";
6
- import { P as T } from "./index-C9T9HQaa.js";
7
- import { c as me } from "./index-Cvx4lqTq.js";
5
+ import { u as ue } from "./index-BZPx6jYI.js";
6
+ import { u as fe } from "./index-ohdbKsws.js";
7
+ import { c as me } from "./index-CigKKiZS.js";
8
8
  import { jsx as g, jsxs as Se } from "react/jsx-runtime";
9
9
  function $(e, [t, n]) {
10
10
  return Math.min(n, Math.max(t, e));
@@ -305,7 +305,7 @@ var O = "SliderThumb", oe = l.forwardRef(
305
305
  }
306
306
  ), be = l.forwardRef(
307
307
  (e, t) => {
308
- const { __scopeSlider: n, index: o, name: s, ...c } = e, r = V(O, n), a = Q(O, n), [u, w] = l.useState(null), p = M(t, (D) => w(D)), i = u ? r.form || !!u.closest("form") : !0, d = ue(u), v = r.values[o], y = v === void 0 ? 0 : ie(v, r.min, r.max), h = Pe(o, r.values.length), m = d?.[a.size], f = m ? De(m, y, a.direction) : 0;
308
+ const { __scopeSlider: n, index: o, name: s, ...c } = e, r = V(O, n), a = Q(O, n), [u, w] = l.useState(null), p = M(t, (D) => w(D)), i = u ? r.form || !!u.closest("form") : !0, d = fe(u), v = r.values[o], y = v === void 0 ? 0 : ie(v, r.min, r.max), h = Pe(o, r.values.length), m = d?.[a.size], f = m ? De(m, y, a.direction) : 0;
309
309
  return l.useEffect(() => {
310
310
  if (u)
311
311
  return r.thumbs.add(u), () => {
@@ -357,7 +357,7 @@ var O = "SliderThumb", oe = l.forwardRef(
357
357
  oe.displayName = O;
358
358
  var Re = "RadioBubbleInput", re = l.forwardRef(
359
359
  ({ __scopeSlider: e, value: t, ...n }, o) => {
360
- const s = l.useRef(null), c = M(s, o), r = fe(t);
360
+ const s = l.useRef(null), c = M(s, o), r = ue(t);
361
361
  return l.useEffect(() => {
362
362
  const a = s.current;
363
363
  if (!a) return;
@@ -0,0 +1,55 @@
1
+ import * as t from "react";
2
+ import { c as f } from "./index-BtQfgaSF.js";
3
+ import { jsx as a } from "react/jsx-runtime";
4
+ var v = [
5
+ "a",
6
+ "button",
7
+ "div",
8
+ "form",
9
+ "h2",
10
+ "h3",
11
+ "img",
12
+ "input",
13
+ "label",
14
+ "li",
15
+ "nav",
16
+ "ol",
17
+ "p",
18
+ "select",
19
+ "span",
20
+ "svg",
21
+ "ul"
22
+ ], c = v.reduce((i, r) => {
23
+ const l = f(`Primitive.${r}`), e = t.forwardRef((s, d) => {
24
+ const { asChild: n, ...m } = s, p = n ? l : r;
25
+ return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ a(p, { ...m, ref: d });
26
+ });
27
+ return e.displayName = `Primitive.${r}`, { ...i, [r]: e };
28
+ }, {}), u = Object.freeze({
29
+ // See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
30
+ position: "absolute",
31
+ border: 0,
32
+ width: 1,
33
+ height: 1,
34
+ padding: 0,
35
+ margin: -1,
36
+ overflow: "hidden",
37
+ clip: "rect(0, 0, 0, 0)",
38
+ whiteSpace: "nowrap",
39
+ wordWrap: "normal"
40
+ }), w = "VisuallyHidden", o = t.forwardRef(
41
+ (i, r) => /* @__PURE__ */ a(
42
+ c.span,
43
+ {
44
+ ...i,
45
+ ref: r,
46
+ style: { ...u, ...i.style }
47
+ }
48
+ )
49
+ );
50
+ o.displayName = w;
51
+ var S = o;
52
+ export {
53
+ S as R,
54
+ o as V
55
+ };
@@ -1,8 +1,8 @@
1
- import { R as Ee, P as ke, O as Se, C as Ie } from "./index-BXuxPoz7.js";
1
+ import { R as Ee, P as ke, O as Se, C as Ie } from "./index-kyuBfLcN.js";
2
2
  import * as n from "react";
3
- import { P as C } from "./index-C9T9HQaa.js";
4
- import { u as P } from "./index-bwWKd82e.js";
5
- import { a as j } from "./index-DQH6odE9.js";
3
+ import { P as C } from "./index-CIAmiWcw.js";
4
+ import { u as P } from "./index-BbQkJE5L.js";
5
+ import { c as j } from "./index-DLcqcWxM.js";
6
6
  var de = 1, xe = 0.9, Re = 0.8, Ce = 0.17, Q = 0.1, Z = 0.999, Ae = 0.9999, Me = 0.99, $e = /[\\\/_+.#"@\[\(\{&]/, De = /[\\\/_+.#"@\[\(\{&]/g, Fe = /[\s-]/, me = /[\s-]/g;
7
7
  function ee(t, l, r, f, u, c, d) {
8
8
  if (c === l.length) return u === t.length ? de : Me;