@konstructio/ui 0.1.2-alpha.4 → 0.1.2-alpha.41

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 (179) hide show
  1. package/dist/{Combination-VYaRRJBZ.js → Combination-BtmnusWq.js} +141 -138
  2. package/dist/DatePicker.css +1 -1
  3. package/dist/Modal-CtAG97Ts.js +99 -0
  4. package/dist/_commonjsHelpers-DaMA6jEr.js +8 -0
  5. package/dist/chevron-down-DgT-uSF9.js +5 -0
  6. package/dist/chevron-left-C4LEg1fH.js +7 -0
  7. package/dist/chevron-up-CRyLc5Ml.js +54 -0
  8. package/dist/chevron-up-DrQr2Fwd.js +5 -0
  9. package/dist/components/Alert/Alert.js +2 -2
  10. package/dist/components/AlertDialog/AlertDialog.js +1 -1
  11. package/dist/components/AlertDialog/components/AlertDialogTrigger.js +1 -1
  12. package/dist/components/AlertDialog/components/index.js +1 -1
  13. package/dist/components/Badge/Badge.js +42 -44
  14. package/dist/components/Badge/Badge.variants.js +8 -6
  15. package/dist/components/Breadcrumb/Breadcrumb.js +1 -1
  16. package/dist/components/Breadcrumb/components/Item/Item.js +24 -23
  17. package/dist/components/Breadcrumb/hooks/useBreadcrumb.js +1 -1
  18. package/dist/components/Button/Button.js +1 -1
  19. package/dist/components/Button/Button.variants.js +1 -1
  20. package/dist/components/Card/Card.variants.js +5 -9
  21. package/dist/components/Checkbox/Checkbox.js +6 -6
  22. package/dist/components/Command/Command.js +2 -2
  23. package/dist/components/Command/components/Command.js +1 -1
  24. package/dist/components/Command/components/CommandEmpty.js +1 -1
  25. package/dist/components/Command/components/CommandGroup.js +1 -1
  26. package/dist/components/Command/components/CommandInput.js +2 -2
  27. package/dist/components/Command/components/CommandItem.js +1 -1
  28. package/dist/components/Command/components/CommandList.js +1 -1
  29. package/dist/components/Command/components/CommandSeparator.js +1 -1
  30. package/dist/components/Command/components/DialogContent.js +2 -2
  31. package/dist/components/Command/components/DialogOverlay.js +1 -1
  32. package/dist/components/Datepicker/DatePicker.js +1243 -1191
  33. package/dist/components/Divider/Divider.variants.js +1 -1
  34. package/dist/components/Dropdown/Dropdown.js +37 -31
  35. package/dist/components/Dropdown/Dropdown.variants.js +9 -4
  36. package/dist/components/Dropdown/components/List/List.js +128 -59
  37. package/dist/components/Dropdown/components/ListItem/ListItem.js +90 -39
  38. package/dist/components/Dropdown/components/Wrapper.js +141 -134
  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 +17 -0
  42. package/dist/components/Dropdown/contexts/dropdown.provider.js +48 -20
  43. package/dist/components/Dropdown/hooks/useDropdown.js +74 -29
  44. package/dist/components/Dropdown/hooks/useNavigationList.js +27 -39
  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 +2 -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 +4 -4
  57. package/dist/components/Modal/components/index.js +1 -1
  58. package/dist/components/MultiSelectDropdown/MultiSelectDropdown.js +34 -0
  59. package/dist/components/MultiSelectDropdown/MultiSelectDropdown.variants.js +34 -0
  60. package/dist/components/MultiSelectDropdown/components/Item/Item.js +38 -0
  61. package/dist/components/MultiSelectDropdown/components/Item/Item.variants.js +38 -0
  62. package/dist/components/MultiSelectDropdown/components/List/List.js +37 -0
  63. package/dist/components/MultiSelectDropdown/components/List/List.variants.js +23 -0
  64. package/dist/components/MultiSelectDropdown/components/Wrapper/Wrapper.js +105 -0
  65. package/dist/components/MultiSelectDropdown/components/index.js +8 -0
  66. package/dist/components/MultiSelectDropdown/contexts/MultiSelectDropdown.context.js +21 -0
  67. package/dist/components/MultiSelectDropdown/contexts/MultiSelectDropdown.hook.js +13 -0
  68. package/dist/components/MultiSelectDropdown/contexts/MultiSelectDropdown.provider.js +138 -0
  69. package/dist/components/MultiSelectDropdown/contexts/index.js +6 -0
  70. package/dist/components/MultiSelectDropdown/hooks/useMultiSelectDropdown.js +32 -0
  71. package/dist/components/NumberInput/NumberInput.js +2 -2
  72. package/dist/components/PhoneNumberInput/PhoneNumberInput.js +8 -0
  73. package/dist/components/PhoneNumberInput/PhoneNumberInput.variants.js +46 -0
  74. package/dist/components/PhoneNumberInput/components/FlagContent/FlagContent.js +27 -0
  75. package/dist/components/PhoneNumberInput/components/FlagSelectorList/FlagSelectorList.js +629 -0
  76. package/dist/components/PhoneNumberInput/components/FlagSelectorWrapper/FlagSelectorWrapper.js +36 -0
  77. package/dist/components/PhoneNumberInput/components/TruncateText/TruncateText.js +45 -0
  78. package/dist/components/PhoneNumberInput/components/Wrapper.js +625 -0
  79. package/dist/components/PhoneNumberInput/components/index.js +6 -0
  80. package/dist/components/PhoneNumberInput/contexts/index.js +8 -0
  81. package/dist/components/PhoneNumberInput/contexts/phone-number.context.js +28 -0
  82. package/dist/components/PhoneNumberInput/contexts/phone-number.hook.js +13 -0
  83. package/dist/components/PhoneNumberInput/contexts/phone-number.provider.js +6144 -0
  84. package/dist/components/PhoneNumberInput/utils/index.js +11 -0
  85. package/dist/components/PieChart/PieChart.js +647 -664
  86. package/dist/components/RadioCard/RadioCard.variants.js +1 -6
  87. package/dist/components/RadioGroup/RadioGroup.js +1 -1
  88. package/dist/components/Range/Range.js +1 -1
  89. package/dist/components/Sidebar/Sidebar.variants.js +2 -2
  90. package/dist/components/Sidebar/components/Wrapper/Wrapper.js +29 -28
  91. package/dist/components/Slider/Slider.js +1 -1
  92. package/dist/components/Switch/Switch.js +8 -8
  93. package/dist/components/Switch/Switch.variants.js +4 -4
  94. package/dist/components/Tabs/Tabs.js +1 -1
  95. package/dist/components/Tabs/Tabs.variants.js +1 -1
  96. package/dist/components/Tabs/components/Content.js +1 -1
  97. package/dist/components/Tabs/components/List.js +1 -1
  98. package/dist/components/Tabs/components/Trigger.js +1 -1
  99. package/dist/components/Tag/Tag.js +1 -1
  100. package/dist/components/Tag/Tag.variants.js +1 -0
  101. package/dist/components/TagSelect/components/Wrapper/Wrapper.js +49 -98
  102. package/dist/components/TimePicker/TimePicker.variants.js +2 -2
  103. package/dist/components/TimePicker/components/Wrapper/Wrapper.js +2 -2
  104. package/dist/components/Toast/Toast.js +283 -255
  105. package/dist/components/Toast/Toast.variants.js +37 -24
  106. package/dist/components/Tooltip/Tooltip.js +15 -14
  107. package/dist/components/Tooltip/Tooltip.variants.js +5 -4
  108. package/dist/components/Typography/Typography.variants.js +18 -23
  109. package/dist/components/VirtualizedTable/VirtualizedTable.js +121 -0
  110. package/dist/components/VirtualizedTable/VirtualizedTable.variants.js +5 -0
  111. package/dist/components/VirtualizedTable/assets/chevron-down.js +25 -0
  112. package/dist/components/VirtualizedTable/assets/chevron-up.js +25 -0
  113. package/dist/components/VirtualizedTable/assets/index.js +6 -0
  114. package/dist/components/VirtualizedTable/components/Actions/Actions.js +72 -0
  115. package/dist/components/VirtualizedTable/components/Body/Body.js +51 -0
  116. package/dist/components/VirtualizedTable/components/DotPaginate/DotPaginate.js +165 -0
  117. package/dist/components/VirtualizedTable/components/DropdownPaginate/DropdownPaginate.js +34 -0
  118. package/dist/components/VirtualizedTable/components/Filter/Filter.js +93 -0
  119. package/dist/components/VirtualizedTable/components/FormPaginate/FormPaginate.js +48 -0
  120. package/dist/components/VirtualizedTable/components/Header/Header.js +84 -0
  121. package/dist/components/VirtualizedTable/components/Pagination/Pagination.js +53 -0
  122. package/dist/components/VirtualizedTable/components/Skeleton/Skeleton.js +67 -0
  123. package/dist/components/VirtualizedTable/components/TruncateText/TruncateText.js +34 -0
  124. package/dist/components/VirtualizedTable/components/WrapperBody/WrapperBody.js +27 -0
  125. package/dist/components/VirtualizedTable/components/index.js +16 -0
  126. package/dist/components/VirtualizedTable/constants/index.js +5 -0
  127. package/dist/components/VirtualizedTable/constants/pagination.js +5 -0
  128. package/dist/components/VirtualizedTable/contexts/index.js +8 -0
  129. package/dist/components/VirtualizedTable/contexts/table.context.js +32 -0
  130. package/dist/components/VirtualizedTable/contexts/table.hook.js +11 -0
  131. package/dist/components/VirtualizedTable/contexts/table.provider.js +85 -0
  132. package/dist/components/index.js +88 -80
  133. package/dist/contexts/theme.provider.js +0 -1
  134. package/dist/{createLucideIcon-DbC6TvM5.js → createLucideIcon-D4r5Phnh.js} +0 -24
  135. package/dist/debounce-BFejQm9P.js +200 -0
  136. package/dist/ellipsis-vertical-BVPtjl5f.js +9 -0
  137. package/dist/{index-h-Ul0anl.js → index--V_ZsiQe.js} +1 -22
  138. package/dist/index-2hB40Iuc.js +1873 -0
  139. package/dist/index-BZPx6jYI.js +8 -0
  140. package/dist/{index-bwWKd82e.js → index-BbQkJE5L.js} +1 -1
  141. package/dist/index-BtQfgaSF.js +60 -0
  142. package/dist/index-C3tHPg8y.js +662 -0
  143. package/dist/index-C65LtGuU.js +137 -0
  144. package/dist/index-CIAmiWcw.js +200 -0
  145. package/dist/index-CSFe9uC5.js +14 -0
  146. package/dist/index-CSWGJT-v.js +1722 -0
  147. package/dist/{index-D3xzCzcO.js → index-CdwPV0FE.js} +4 -4
  148. package/dist/index-CigKKiZS.js +91 -0
  149. package/dist/{index-BAraV3ai.js → index-DH2Fnov1.js} +11 -12
  150. package/dist/index-DLcqcWxM.js +29 -0
  151. package/dist/index-Dbt2vBmS.js +136 -0
  152. package/dist/{index-DB2XhXHn.js → index-DpW9ExsS.js} +7 -7
  153. package/dist/index-DrWQH0QF.js +55 -0
  154. package/dist/index-Ds6U2x4Z.js +479 -0
  155. package/dist/{index-C1g_chDT.js → index-mPY_8Y5v.js} +2 -2
  156. package/dist/index-ohdbKsws.js +27 -0
  157. package/dist/index.d.ts +232 -23
  158. package/dist/index.js +112 -102
  159. package/dist/libphonenumber-_7ZyKWA7.js +11549 -0
  160. package/dist/loader-juvMSJ9L.js +5 -0
  161. package/dist/package.json +48 -34
  162. package/dist/styles.css +1 -1
  163. package/dist/ui/civo-theme.css +191 -167
  164. package/dist/{useBreadcrumb-B8DnuqkR.js → useBreadcrumb-BAHbGQ_O.js} +0 -10
  165. package/dist/utils/index.js +534 -501
  166. package/dist/{x-BPcqkRZd.js → x-DPU9OdYH.js} +1 -1
  167. package/package.json +48 -34
  168. package/dist/Modal-V67Uz78z.js +0 -98
  169. package/dist/_commonjsHelpers-C6fGbg64.js +0 -6
  170. package/dist/chevron-down-BLZPftpV.js +0 -11
  171. package/dist/index-BXuxPoz7.js +0 -435
  172. package/dist/index-BfXxHr_2.js +0 -125
  173. package/dist/index-C9T9HQaa.js +0 -423
  174. package/dist/index-CZnD2QxM.js +0 -32
  175. package/dist/index-CrBonFvu.js +0 -144
  176. package/dist/index-Cvx4lqTq.js +0 -47
  177. package/dist/index-DQH6odE9.js +0 -82
  178. package/dist/index-Oq5GlCHP.js +0 -131
  179. package/dist/index-iXyXtdgP.js +0 -31
@@ -1,23 +1,36 @@
1
1
  import { c as a } from "../../index-D29mdTf5.js";
2
- const t = a([
3
- "rounded-md",
4
- "shadow-md",
5
- "p-4",
6
- "flex",
7
- "flex-col",
8
- "relative",
9
- "border",
10
- "overflow-hidden",
11
- "data-[state=open]:animate-slide-in",
12
- "data-[state=closed]:animate-hide",
13
- "data-[swipe=move]:translate-x-4",
14
- "data-[swipe=cancel]:translate-x-0",
15
- "data-[swipe=end]:animate-swipe-out",
16
- "shadow-purple-200",
17
- "border-purple-100",
18
- "dark:border-none",
19
- "dark:shadow-none"
20
- ]), o = a([
2
+ const e = a(
3
+ [
4
+ "rounded-md",
5
+ "p-4",
6
+ "flex",
7
+ "flex-row",
8
+ "relative",
9
+ "overflow-hidden",
10
+ "h-14",
11
+ "items-center",
12
+ "gap-8",
13
+ "data-[state=open]:animate-slide-in",
14
+ "data-[state=closed]:animate-hide",
15
+ "data-[swipe=move]:translate-x-4",
16
+ "data-[swipe=cancel]:translate-x-0",
17
+ "data-[swipe=end]:animate-swipe-out",
18
+ "text-white",
19
+ "shadow-[0px_2px_4px_0px_rgba(100,116,139,0.25)]"
20
+ ],
21
+ {
22
+ variants: {
23
+ variant: {
24
+ success: ["bg-green-800"],
25
+ error: ["bg-red-800"],
26
+ warning: ["bg-amber-800"]
27
+ }
28
+ },
29
+ defaultVariants: {
30
+ variant: "success"
31
+ }
32
+ }
33
+ ), i = a([
21
34
  "fixed",
22
35
  "bottom-0",
23
36
  "right-0",
@@ -30,15 +43,15 @@ const t = a([
30
43
  "m-0",
31
44
  "z-50",
32
45
  "outline-none"
33
- ]), r = a([
46
+ ]), s = a([
34
47
  "top-2",
35
48
  "right-2",
36
49
  "w-4",
37
50
  "h-4",
38
- "text-kubefirst-primary"
51
+ "text-white"
39
52
  ]);
40
53
  export {
41
- r as closeToastVariants,
42
- t as toastVariants,
43
- o as viewportToastVariants
54
+ s as closeToastVariants,
55
+ e as toastVariants,
56
+ i as viewportToastVariants
44
57
  };
@@ -1,28 +1,29 @@
1
- import { jsx as e, jsxs as t } from "react/jsx-runtime";
2
- import { S as i } from "../../index-DQH6odE9.js";
3
- import { forwardRef as v, useRef as N, useImperativeHandle as w, useMemo as h, isValidElement as x } from "react";
1
+ import { jsx as e, jsxs as s } from "react/jsx-runtime";
2
+ import { S as u } from "../../index-BtQfgaSF.js";
3
+ import { forwardRef as v, useRef as N, useImperativeHandle as h, useMemo as w, isValidElement as x } from "react";
4
4
  import { cn as o } from "../../utils/index.js";
5
5
  import { arrowVariants as R, tooltipVariants as V } from "./Tooltip.variants.js";
6
- import { useTooltip as b } from "./hooks/useTooltip.js";
6
+ import { useTooltip as T } from "./hooks/useTooltip.js";
7
+ import { Typography as b } from "../Typography/Typography.js";
7
8
  const I = v(
8
- ({ children: r, content: l, className: m, theme: n, position: a, wrapperClassName: c }, p) => {
9
- const f = N(null), { isVisible: d, componentRef: s } = b();
10
- w(p, () => s.current, [s]);
11
- const u = h(
9
+ ({ children: r, content: i, className: m, theme: l, position: a, wrapperClassName: n }, p) => {
10
+ const c = N(null), { isVisible: f, componentRef: t } = T();
11
+ h(p, () => t.current, [t]);
12
+ const d = w(
12
13
  () => x(r) ? r : /* @__PURE__ */ e("p", { className: "p-2", children: r }),
13
14
  [r]
14
15
  );
15
- return /* @__PURE__ */ e("div", { className: o("w-full", c), "data-theme": n, children: /* @__PURE__ */ t("div", { className: "relative w-max", children: [
16
- /* @__PURE__ */ e(i, { ref: s, className: o("cursor-pointer ", m), children: u }),
17
- /* @__PURE__ */ t(
16
+ return /* @__PURE__ */ e("div", { className: o("w-full", n), "data-theme": l, children: /* @__PURE__ */ s("div", { className: "relative w-max", children: [
17
+ /* @__PURE__ */ e(u, { ref: t, className: o("cursor-pointer ", m), children: d }),
18
+ /* @__PURE__ */ s(
18
19
  "div",
19
20
  {
20
- ref: f,
21
+ ref: c,
21
22
  className: o(V({ position: a })),
22
- "data-visible": d,
23
+ "data-visible": f,
23
24
  children: [
24
25
  /* @__PURE__ */ e("span", { className: o(R({ position: a })) }),
25
- /* @__PURE__ */ e(i, { children: l })
26
+ /* @__PURE__ */ e(b, { variant: "tooltip", className: "text-white", children: i })
26
27
  ]
27
28
  }
28
29
  )
@@ -3,8 +3,9 @@ const a = r(
3
3
  [
4
4
  "absolute",
5
5
  "w-max",
6
- "p-2.5",
7
- "rounded-lg",
6
+ "py-2",
7
+ "px-[6px]",
8
+ "rounded-xs",
8
9
  "shadow-md",
9
10
  "transition-all",
10
11
  "ease-linear",
@@ -12,7 +13,7 @@ const a = r(
12
13
  "duration-250",
13
14
  "[&[data-visible='true']]:opacity-100",
14
15
  "delay-100",
15
- "bg-kubefirst-primary"
16
+ "bg-slate-700"
16
17
  ],
17
18
  {
18
19
  variants: {
@@ -28,7 +29,7 @@ const a = r(
28
29
  }
29
30
  }
30
31
  ), o = r(
31
- ["absolute", "w-0", "h-0", "border-kubefirst-primary"],
32
+ ["absolute", "w-0", "h-0", "border-slate-700"],
32
33
  {
33
34
  variants: {
34
35
  position: {
@@ -1,51 +1,46 @@
1
1
  import { c as t } from "../../index-D29mdTf5.js";
2
- const e = t([], {
2
+ const a = t([], {
3
3
  variants: {
4
4
  variant: {
5
- h1: ["text-[57px]", "leading-[64px]"],
5
+ h1: ["text-[57px]", "leading-16"],
6
6
  h2: ["text-[45px]", "leading-[52px]"],
7
- h3: ["text-[36px]", "leading-[44px]"],
8
- h4: ["text-[32px]", "leading-[40px]"],
9
- h5: ["text-[28px]", "leading-[36px]"],
10
- h6: ["text-[24px]", "font-medium", "leading-[32px]", "tracking-[0.15px]"],
11
- subtitle1: ["text-[22px]", "leading-[28px]"],
12
- subtitle2: [
13
- "text-[16px]",
14
- "font-medium",
15
- "leading-[24px]",
16
- "tracking-[0.15px]"
17
- ],
7
+ h3: ["text-4xl", "leading-11"],
8
+ h4: ["text-[32px]", "leading-10"],
9
+ h5: ["text-[28px]", "leading-9"],
10
+ h6: ["text-2xl", "font-medium", "leading-8", "tracking-[0.15px]"],
11
+ subtitle1: ["text-[22px]", "leading-7"],
12
+ subtitle2: ["text-sm", "font-medium", "leading-6", "tracking-[0.15px]"],
18
13
  subtitle3: [
19
14
  "text-[14px]",
20
15
  "font-medium",
21
- "leading-[20px]",
16
+ "leading-5",
22
17
  "tracking-[0.1px]"
23
18
  ],
24
- labelLarge: ["text-[14px]", "leading-[20px]", "tracking-[0.1px]"],
19
+ labelLarge: ["text-sm", "leading-5", "tracking-[0.1px]"],
25
20
  labelMedium: [
26
21
  "text-[12px]",
27
22
  "font-medium",
28
- "leading-[16px]",
23
+ "leading-4",
29
24
  "tracking-[0.5px]",
30
25
  "uppercase"
31
26
  ],
32
27
  labelSmall: [
33
28
  "text-[11px]",
34
29
  "font-medium",
35
- "leading-[16px]",
30
+ "leading-4",
36
31
  "tracking-[0.5px]",
37
32
  "uppercase"
38
33
  ],
39
34
  buttonSmall: [
40
35
  "text-[14px]",
41
36
  "font-semibold",
42
- "leading-[20px]",
37
+ "leading-5",
43
38
  "tracking-[0.25px]"
44
39
  ],
45
- body1: ["text-[16px]", "leading-[24px]", "tracking-[0.5px]"],
46
- body2: ["text-[14px]", "leading-[20px]", "tracking-[0.25px]"],
47
- body3: ["text-[12px]", "leading-[16px]", "tracking-[0.4px]"],
48
- tooltip: ["text-[14px]", "leading-[22px]"]
40
+ body1: ["text-base", "leading-6", "tracking-[0.5px]"],
41
+ body2: ["text-sm", "leading-5", "tracking-[0.25px]"],
42
+ body3: ["text-xs", "leading-4", "tracking-[0.4px]"],
43
+ tooltip: ["text-sm", "leading-[22px]"]
49
44
  }
50
45
  },
51
46
  defaultVariants: {
@@ -53,5 +48,5 @@ const e = t([], {
53
48
  }
54
49
  });
55
50
  export {
56
- e as typographyVariants
51
+ a as typographyVariants
57
52
  };
@@ -0,0 +1,121 @@
1
+ import { jsx as r, jsxs as s } from "react/jsx-runtime";
2
+ import { useMemo as K } from "react";
3
+ import { cn as c } from "../../utils/index.js";
4
+ import { TableProvider as M } from "./contexts/table.provider.js";
5
+ import { Filter as W } from "./components/Filter/Filter.js";
6
+ import { WrapperBody as k } from "./components/WrapperBody/WrapperBody.js";
7
+ import { Header as q } from "./components/Header/Header.js";
8
+ import { Body as C } from "./components/Body/Body.js";
9
+ import { Pagination as F } from "./components/Pagination/Pagination.js";
10
+ import { TruncateText as G } from "./components/TruncateText/TruncateText.js";
11
+ import { Actions as J } from "./components/Actions/Actions.js";
12
+ const O = ({
13
+ id: n,
14
+ ariaLabel: f,
15
+ columns: p,
16
+ data: d,
17
+ totalItems: u = -1 / 0,
18
+ className: b,
19
+ classNameHeaderActiveArrows: T,
20
+ classNameHeaderArrows: x,
21
+ classNameHeaderTable: N,
22
+ classNameTable: A,
23
+ classNameWrapperTable: y,
24
+ isLoading: o,
25
+ fetchData: h,
26
+ queryOptions: z,
27
+ // Pagination
28
+ showPagination: B,
29
+ showTotalItems: t,
30
+ showDropdownPagination: a,
31
+ showDotPagination: l,
32
+ showFormPagination: m,
33
+ pageSizes: V,
34
+ // Filter
35
+ showFilter: j = !1,
36
+ showFilterInput: v,
37
+ filterSearchPlaceholder: w = "",
38
+ multiSelectFilter: P,
39
+ filterActions: E,
40
+ showResetButton: H = !0,
41
+ resetButtonClassName: I
42
+ }) => {
43
+ const e = K(
44
+ () => B || [
45
+ t,
46
+ a,
47
+ l,
48
+ m
49
+ ].some(Boolean),
50
+ []
51
+ );
52
+ return /* @__PURE__ */ r(
53
+ M,
54
+ {
55
+ id: n,
56
+ columns: p,
57
+ data: d,
58
+ fetchData: h,
59
+ totalItems: u,
60
+ queryOptions: z,
61
+ isPaginationEnabled: e,
62
+ children: /* @__PURE__ */ s("section", { className: c("w-full min-w-fit", b), children: [
63
+ j && /* @__PURE__ */ r(
64
+ W,
65
+ {
66
+ actions: E,
67
+ multiSelectFilter: P,
68
+ placeholder: w,
69
+ showFilterInput: v,
70
+ showResetButton: H,
71
+ resetButtonClassName: I
72
+ }
73
+ ),
74
+ /* @__PURE__ */ r(
75
+ k,
76
+ {
77
+ showPagination: e,
78
+ classNameWrapperTable: y,
79
+ isLoading: o,
80
+ children: /* @__PURE__ */ s(
81
+ "table",
82
+ {
83
+ className: c("w-full border-collapse table-fixed", A),
84
+ "aria-label": f,
85
+ children: [
86
+ /* @__PURE__ */ r(
87
+ q,
88
+ {
89
+ className: N,
90
+ classNameArrows: x,
91
+ classNameActiveArrows: T
92
+ }
93
+ ),
94
+ /* @__PURE__ */ r(C, { isLoading: o, showPagination: e })
95
+ ]
96
+ }
97
+ )
98
+ }
99
+ ),
100
+ e && /* @__PURE__ */ r(
101
+ F,
102
+ {
103
+ showTotalItems: t,
104
+ showDropdownPagination: a,
105
+ showDotPagination: l,
106
+ showFormPagination: m,
107
+ pageSizes: V,
108
+ isLoading: o
109
+ }
110
+ )
111
+ ] })
112
+ }
113
+ );
114
+ }, i = O;
115
+ i.displayName = "KonstructVirtualizedTable";
116
+ i.TruncateText = G;
117
+ i.Actions = J;
118
+ export {
119
+ G as TruncateText,
120
+ i as VirtualizedTable
121
+ };
@@ -0,0 +1,5 @@
1
+ import { c as a } from "../../index-D29mdTf5.js";
2
+ const t = a([]);
3
+ export {
4
+ t as virtualizeTableVariants
5
+ };
@@ -0,0 +1,25 @@
1
+ import { jsx as o } from "react/jsx-runtime";
2
+ const l = ({
3
+ className: t,
4
+ onClick: e
5
+ }) => /* @__PURE__ */ o(
6
+ "svg",
7
+ {
8
+ width: "7",
9
+ height: "5",
10
+ viewBox: "0 0 7 5",
11
+ fill: "none",
12
+ className: t,
13
+ onClick: e,
14
+ children: /* @__PURE__ */ o(
15
+ "path",
16
+ {
17
+ d: "M0.8225 0L3.5 2.67167L6.1775 0L7 0.8225L3.5 4.3225L0 0.8225L0.8225 0Z",
18
+ fill: "currentColor"
19
+ }
20
+ )
21
+ }
22
+ );
23
+ export {
24
+ l as default
25
+ };
@@ -0,0 +1,25 @@
1
+ import { jsx as o } from "react/jsx-runtime";
2
+ const l = ({
3
+ className: r,
4
+ onClick: t
5
+ }) => /* @__PURE__ */ o(
6
+ "svg",
7
+ {
8
+ width: "7",
9
+ height: "5",
10
+ viewBox: "0 0 7 5",
11
+ fill: "currentColor",
12
+ className: r,
13
+ onClick: t,
14
+ children: /* @__PURE__ */ o(
15
+ "path",
16
+ {
17
+ d: "M0.8225 4.99999L3.5 2.32832L6.1775 4.99999L7 4.17749L3.5 0.67749L0 4.17749L0.8225 4.99999Z",
18
+ fill: "currentColor"
19
+ }
20
+ )
21
+ }
22
+ );
23
+ export {
24
+ l as default
25
+ };
@@ -0,0 +1,6 @@
1
+ import { default as r } from "./chevron-up.js";
2
+ import { default as f } from "./chevron-down.js";
3
+ export {
4
+ f as ChevronDown,
5
+ r as ChevronUp
6
+ };
@@ -0,0 +1,72 @@
1
+ import { jsxs as i, jsx as e } from "react/jsx-runtime";
2
+ import { Button as t } from "../../../Button/Button.js";
3
+ import { cn as r } from "../../../../utils/index.js";
4
+ import { E as u } from "../../../../ellipsis-vertical-BVPtjl5f.js";
5
+ const w = ({
6
+ actions: a,
7
+ wrapperClassName: l,
8
+ triggerButtonClassName: s,
9
+ iconTriggerButtonClassName: n,
10
+ wrapperActionsClassName: c,
11
+ wrapperContentActionsClassName: d,
12
+ ...h
13
+ }) => a ? /* @__PURE__ */ i("div", { className: r("relative group", l), children: [
14
+ /* @__PURE__ */ i(
15
+ t,
16
+ {
17
+ variant: "text",
18
+ shape: "circle",
19
+ size: "large",
20
+ className: r(
21
+ "text-slate-400 group-hover:text-slate-800 group-hover:bg-aurora-50",
22
+ s
23
+ ),
24
+ role: "presentation",
25
+ children: [
26
+ /* @__PURE__ */ e(
27
+ u,
28
+ {
29
+ "aria-hidden": "true",
30
+ className: r("w-7 h-7", n)
31
+ }
32
+ ),
33
+ /* @__PURE__ */ e("span", { className: "sr-only", children: "Show Actions" })
34
+ ]
35
+ }
36
+ ),
37
+ /* @__PURE__ */ e(
38
+ "div",
39
+ {
40
+ className: r(
41
+ "absolute top-full right-0 w-[215px] hidden group-hover:block z-10",
42
+ c
43
+ ),
44
+ children: /* @__PURE__ */ e(
45
+ "div",
46
+ {
47
+ className: r(
48
+ "bg-white mt-0.5 py-2 rounded-lg shadow-lg border border-zinc-100 animate-in fade-in-0",
49
+ d
50
+ ),
51
+ children: a.map(({ label: o, className: p, onClick: m }) => /* @__PURE__ */ e(
52
+ t,
53
+ {
54
+ className: r(
55
+ "w-full text-slate-800 cursor-pointer p-0 h-9 flex gap-2 text-sm font-normal justify-start hover:bg-gray-50 hover:text-slate-800 rounded-none px-6",
56
+ p
57
+ ),
58
+ variant: "text",
59
+ asChild: !0,
60
+ role: "presentation",
61
+ children: /* @__PURE__ */ e(t, { onClick: () => m(h.row.original), children: o })
62
+ },
63
+ o
64
+ ))
65
+ }
66
+ )
67
+ }
68
+ )
69
+ ] }) : null;
70
+ export {
71
+ w as Actions
72
+ };
@@ -0,0 +1,51 @@
1
+ import { jsx as e } from "react/jsx-runtime";
2
+ import { f as y } from "../../../../index-CSWGJT-v.js";
3
+ import { Skeleton as x } from "../Skeleton/Skeleton.js";
4
+ import { cn as b } from "../../../../utils/index.js";
5
+ import { useTableContext as D } from "../../contexts/table.hook.js";
6
+ const _ = ({
7
+ isLoading: d,
8
+ showPagination: a
9
+ }) => {
10
+ const { table: s, pageSize: i, tableFetching: p } = D();
11
+ if (d || p)
12
+ return /* @__PURE__ */ e(x, { numberOfRows: i, table: s });
13
+ const r = s.getRowModel().rows ?? [];
14
+ return /* @__PURE__ */ e("tbody", { className: "text-slate-800 text-sm font-normal relative", children: r.map(({ id: o, original: l, getVisibleCells: u }, m) => {
15
+ const { meta: n = {} } = l, c = u();
16
+ return /* @__PURE__ */ e(
17
+ "tr",
18
+ {
19
+ className: b(
20
+ "border-b border-b-gray-200 last:border-b-transparent bg-transparent",
21
+ n.className
22
+ ),
23
+ "data-row-id": o,
24
+ ...n.attributes ?? {},
25
+ children: c.map(({ id: g, column: t, getContext: h }, f) => {
26
+ const N = typeof t.columnDef.meta?.className == "function" ? t.columnDef.meta?.className(l) : t.columnDef.meta?.className;
27
+ return /* @__PURE__ */ e(
28
+ "td",
29
+ {
30
+ className: b(
31
+ "px-4 py-1 text-sm bg-white",
32
+ N,
33
+ {
34
+ "[tr:last-child_&:first-of-type]:rounded-bl-lg": m === r.length - 1 && f === 0 || !a,
35
+ "[tr:last-child_&:last-of-type]:rounded-br-lg": m === r.length - 1 && f === c.length - 1 || !a
36
+ }
37
+ ),
38
+ ...t.columnDef.meta?.attributes ?? {},
39
+ children: y(t.columnDef.cell, h())
40
+ },
41
+ g
42
+ );
43
+ })
44
+ },
45
+ o
46
+ );
47
+ }) });
48
+ };
49
+ export {
50
+ _ as Body
51
+ };