@konstructio/ui 0.1.2-alpha.6 → 0.1.2-alpha.8

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 (47) hide show
  1. package/dist/{Modal-D-NOEWMX.js → Modal-B8jrP02v.js} +20 -20
  2. package/dist/components/Alert/Alert.js +1 -1
  3. package/dist/components/AlertDialog/AlertDialog.js +1 -1
  4. package/dist/components/AlertDialog/components/AlertDialogTrigger.js +1 -1
  5. package/dist/components/AlertDialog/components/index.js +1 -1
  6. package/dist/components/Checkbox/Checkbox.js +1 -1
  7. package/dist/components/Command/Command.js +2 -2
  8. package/dist/components/Command/components/Command.js +1 -1
  9. package/dist/components/Command/components/CommandEmpty.js +1 -1
  10. package/dist/components/Command/components/CommandGroup.js +1 -1
  11. package/dist/components/Command/components/CommandInput.js +1 -1
  12. package/dist/components/Command/components/CommandItem.js +1 -1
  13. package/dist/components/Command/components/CommandList.js +1 -1
  14. package/dist/components/Command/components/CommandSeparator.js +1 -1
  15. package/dist/components/Command/components/DialogContent.js +1 -1
  16. package/dist/components/Command/components/DialogOverlay.js +1 -1
  17. package/dist/components/Modal/Modal.js +2 -2
  18. package/dist/components/Modal/components/Wrapper/Wrapper.js +2 -2
  19. package/dist/components/Modal/components/index.js +1 -1
  20. package/dist/components/NumberInput/NumberInput.js +1 -1
  21. package/dist/components/Range/Range.js +1 -1
  22. package/dist/components/Slider/Slider.js +1 -1
  23. package/dist/components/Switch/Switch.js +1 -1
  24. package/dist/components/Tabs/Tabs.js +1 -1
  25. package/dist/components/Tabs/components/Content.js +1 -1
  26. package/dist/components/Tabs/components/List.js +1 -1
  27. package/dist/components/Tabs/components/Trigger.js +1 -1
  28. package/dist/components/Toast/Toast.js +54 -53
  29. package/dist/components/VirtualizedTable/VirtualizedTable.js +72 -58
  30. package/dist/components/VirtualizedTable/components/TruncateText/TruncateText.js +4 -3
  31. package/dist/components/VirtualizedTable/contexts/table.provider.js +64 -760
  32. package/dist/components/index.js +1 -1
  33. package/dist/{index-B7t8D14s.js → index-0XtjXVpJ.js} +2 -2
  34. package/dist/index-BVRIAMfe.js +36 -0
  35. package/dist/{index-os7vysFS.js → index-Bn4c-gww.js} +1 -1
  36. package/dist/{index-Cd2vhaop.js → index-CffpTFMi.js} +1 -1
  37. package/dist/{index-Bnb0ezr3.js → index-DQJhMz8c.js} +1 -1
  38. package/dist/index-DdXGVVBv.js +15 -0
  39. package/dist/{index-DzIBBMjs.js → index-amYX3uxF.js} +3 -3
  40. package/dist/{index-C84F4YyO.js → index-l3NwplN0.js} +1 -1
  41. package/dist/{index-DBbEcSUG.js → index-sp5ZfG6g.js} +1 -1
  42. package/dist/index.d.ts +8 -4
  43. package/dist/index.js +1 -1
  44. package/dist/package.json +6 -2
  45. package/package.json +6 -2
  46. package/dist/index-BITvcJAz.js +0 -423
  47. package/dist/index-ti1b9kqV.js +0 -14
@@ -1,38 +1,41 @@
1
1
  import { jsx as r, jsxs as m } from "react/jsx-runtime";
2
- import { useMemo as V } from "react";
3
- import { cn as g } from "../../utils/index.js";
4
- import { TableProvider as j } from "./contexts/table.provider.js";
5
- import { Filter as w } from "./components/Filter/Filter.js";
6
- import { Header as y } from "./components/Header/Header.js";
7
- import { Body as B } from "./components/Body/Body.js";
8
- import { Pagination as H } from "./components/Pagination/Pagination.js";
9
- import { TruncateText as K } from "./components/TruncateText/TruncateText.js";
10
- import { Actions as M } from "./components/Actions/Actions.js";
11
- const P = ({
12
- id: s,
13
- ariaLabel: c,
14
- columns: d,
15
- data: n,
16
- totalItems: f,
17
- classNameHeaderTable: p,
18
- classNameHeaderArrows: u,
2
+ import { useMemo as y } from "react";
3
+ import { cn as s } from "../../utils/index.js";
4
+ import { TableProvider as B } from "./contexts/table.provider.js";
5
+ import { Filter as H } from "./components/Filter/Filter.js";
6
+ import { Header as K } from "./components/Header/Header.js";
7
+ import { Body as M } from "./components/Body/Body.js";
8
+ import { Pagination as P } from "./components/Pagination/Pagination.js";
9
+ import { TruncateText as k } from "./components/TruncateText/TruncateText.js";
10
+ import { Actions as q } from "./components/Actions/Actions.js";
11
+ const C = ({
12
+ id: c,
13
+ ariaLabel: d,
14
+ columns: n,
15
+ data: f,
16
+ totalItems: p,
17
+ className: u,
19
18
  classNameHeaderActiveArrows: b,
20
- fetchData: T,
19
+ classNameHeaderArrows: T,
20
+ classNameHeaderTable: N,
21
+ classNameTable: h,
22
+ classNameWrapperTable: x,
23
+ fetchData: A,
21
24
  // Pagination
22
- showPagination: N,
25
+ showPagination: v,
23
26
  showTotalItems: o,
24
27
  showDropdownPagination: l,
25
28
  showDotPagination: a,
26
29
  showFormPagination: i,
27
- pageSizes: h,
30
+ pageSizes: z,
28
31
  // Filter
29
- showFilter: x = !1,
30
- showFilterInput: A,
31
- filterSearchPlaceholder: v = "",
32
- multiSelectFilter: z
32
+ showFilter: V = !1,
33
+ showFilterInput: g,
34
+ filterSearchPlaceholder: j = "",
35
+ multiSelectFilter: w
33
36
  }) => {
34
- const t = V(
35
- () => N || [
37
+ const t = y(
38
+ () => v || [
36
39
  o,
37
40
  l,
38
41
  a,
@@ -41,59 +44,70 @@ const P = ({
41
44
  []
42
45
  );
43
46
  return /* @__PURE__ */ r(
44
- j,
47
+ B,
45
48
  {
46
- id: s,
47
- columns: d,
48
- data: n,
49
- fetchData: T,
50
- totalItems: f,
51
- children: /* @__PURE__ */ m("section", { children: [
52
- x && /* @__PURE__ */ r(
53
- w,
49
+ id: c,
50
+ columns: n,
51
+ data: f,
52
+ fetchData: A,
53
+ totalItems: p,
54
+ children: /* @__PURE__ */ m("section", { className: u, children: [
55
+ V && /* @__PURE__ */ r(
56
+ H,
54
57
  {
55
- placeholder: v,
56
- multiSelectFilter: z,
57
- showFilterInput: A
58
+ placeholder: j,
59
+ multiSelectFilter: w,
60
+ showFilterInput: g
58
61
  }
59
62
  ),
60
63
  /* @__PURE__ */ r(
61
64
  "div",
62
65
  {
63
- className: g("shadow rounded-t-lg", {
64
- "overflow-hidden rounded-lg": !t
65
- }),
66
- children: /* @__PURE__ */ m("table", { className: "w-full border-collapse", "aria-label": c, children: [
67
- /* @__PURE__ */ r(
68
- y,
69
- {
70
- className: p,
71
- classNameArrows: u,
72
- classNameActiveArrows: b
73
- }
74
- ),
75
- /* @__PURE__ */ r(B, {})
76
- ] })
66
+ className: s(
67
+ "shadow rounded-t-lg",
68
+ {
69
+ "overflow-hidden rounded-lg": !t
70
+ },
71
+ x
72
+ ),
73
+ children: /* @__PURE__ */ m(
74
+ "table",
75
+ {
76
+ className: s("w-full border-collapse", h),
77
+ "aria-label": d,
78
+ children: [
79
+ /* @__PURE__ */ r(
80
+ K,
81
+ {
82
+ className: N,
83
+ classNameArrows: T,
84
+ classNameActiveArrows: b
85
+ }
86
+ ),
87
+ /* @__PURE__ */ r(M, {})
88
+ ]
89
+ }
90
+ )
77
91
  }
78
92
  ),
79
93
  t && /* @__PURE__ */ r(
80
- H,
94
+ P,
81
95
  {
82
96
  showTotalItems: o,
83
97
  showDropdownPagination: l,
84
98
  showDotPagination: a,
85
99
  showFormPagination: i,
86
- pageSizes: h
100
+ pageSizes: z
87
101
  }
88
102
  )
89
103
  ] })
90
104
  }
91
105
  );
92
- }, e = P;
106
+ }, e = C;
93
107
  e.displayName = "KonstructVirtualizedTable";
94
- e.TruncateText = K;
95
- e.Actions = M;
108
+ e.TruncateText = k;
109
+ e.Actions = q;
96
110
  export {
97
- K as TruncateText,
111
+ k as TruncateText,
98
112
  e as VirtualizedTable
99
113
  };
@@ -3,13 +3,14 @@ import * as g from "react";
3
3
  import { useLayoutEffect as Vt, useRef as zt, useState as jt, useCallback as Yt, useEffect as ze } from "react";
4
4
  import { c as ot, u as je, a as Xt, b as J } from "../../../../index-BfXxHr_2.js";
5
5
  import { u as ge, b as Gt } from "../../../../index-DQH6odE9.js";
6
- import { D as qt } from "../../../../index-Cd2vhaop.js";
6
+ import { D as qt } from "../../../../index-CffpTFMi.js";
7
7
  import { u as Ut } from "../../../../index-bwWKd82e.js";
8
- import { r as Kt, P as we } from "../../../../index-BITvcJAz.js";
8
+ import * as Kt from "react-dom";
9
+ import { P as we } from "../../../../index-BVRIAMfe.js";
9
10
  import { u as Zt } from "../../../../index-0ioNhtNM.js";
10
11
  import { u as Jt } from "../../../../index-BAEWsOG1.js";
11
12
  import { P as Qt } from "../../../../index-C1g_chDT.js";
12
- import { R as en } from "../../../../index-DBbEcSUG.js";
13
+ import { R as en } from "../../../../index-sp5ZfG6g.js";
13
14
  import { d as tn } from "../../../../debounce-BFejQm9P.js";
14
15
  const nn = ["top", "right", "bottom", "left"], U = Math.min, F = Math.max, de = Math.round, fe = Math.floor, j = (e) => ({
15
16
  x: e,