@brightlocal/ui-components 3.1.0 → 3.2.0

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 (176) hide show
  1. package/README.md +6 -1
  2. package/component-meta.json +663 -38
  3. package/deprecations.json +1 -1
  4. package/dist/alert-dialog.cjs +1 -1
  5. package/dist/alert-dialog.d.ts +32 -3
  6. package/dist/alert-dialog.d.ts.map +1 -1
  7. package/dist/alert-dialog.js +61 -58
  8. package/dist/alert.cjs +1 -1
  9. package/dist/alert.d.ts.map +1 -1
  10. package/dist/alert.js +58 -57
  11. package/dist/badge.cjs +1 -1
  12. package/dist/badge.d.ts +9 -0
  13. package/dist/badge.d.ts.map +1 -1
  14. package/dist/badge.js +50 -30
  15. package/dist/banner.cjs +1 -0
  16. package/dist/banner.d.ts +81 -0
  17. package/dist/banner.d.ts.map +1 -0
  18. package/dist/banner.js +176 -0
  19. package/dist/blocks/empty-state.cjs +1 -1
  20. package/dist/blocks/empty-state.d.ts +4 -3
  21. package/dist/blocks/empty-state.d.ts.map +1 -1
  22. package/dist/blocks/empty-state.js +21 -20
  23. package/dist/blocks/progress-state.d.ts +2 -2
  24. package/dist/blocks/sidebar.cjs +1 -1
  25. package/dist/blocks/sidebar.d.ts +17 -0
  26. package/dist/blocks/sidebar.d.ts.map +1 -1
  27. package/dist/blocks/sidebar.js +8 -2
  28. package/dist/brand-illustration-motif.d.ts +1 -1
  29. package/dist/card.cjs +1 -1
  30. package/dist/card.d.ts +86 -6
  31. package/dist/card.d.ts.map +1 -1
  32. package/dist/card.js +185 -96
  33. package/dist/chart.cjs +3 -3
  34. package/dist/chart.d.ts +231 -13
  35. package/dist/chart.d.ts.map +1 -1
  36. package/dist/chart.js +466 -306
  37. package/dist/checkbox.cjs +1 -1
  38. package/dist/checkbox.d.ts +1 -1
  39. package/dist/checkbox.d.ts.map +1 -1
  40. package/dist/checkbox.js +2 -1
  41. package/dist/combobox.cjs +1 -1
  42. package/dist/combobox.js +2 -2
  43. package/dist/command.cjs +1 -1
  44. package/dist/command.js +1 -1
  45. package/dist/data-table.cjs +1 -1
  46. package/dist/data-table.d.ts +169 -22
  47. package/dist/data-table.d.ts.map +1 -1
  48. package/dist/data-table.js +695 -561
  49. package/dist/grid.d.ts +24 -1
  50. package/dist/grid.d.ts.map +1 -1
  51. package/dist/hooks/use-breakpoint.cjs +1 -1
  52. package/dist/hooks/use-breakpoint.d.ts +1 -1
  53. package/dist/hooks/use-breakpoint.d.ts.map +1 -1
  54. package/dist/hooks/use-breakpoint.js +1 -0
  55. package/dist/index.cjs +1 -1
  56. package/dist/index.d.ts +5 -0
  57. package/dist/index.d.ts.map +1 -1
  58. package/dist/index.js +593 -561
  59. package/dist/info-tooltip.cjs +1 -0
  60. package/dist/info-tooltip.d.ts +39 -0
  61. package/dist/info-tooltip.d.ts.map +1 -0
  62. package/dist/info-tooltip.js +41 -0
  63. package/dist/input-chip.cjs +1 -1
  64. package/dist/input-chip.js +1 -1
  65. package/dist/input-group.cjs +1 -1
  66. package/dist/input-group.d.ts +33 -2
  67. package/dist/input-group.d.ts.map +1 -1
  68. package/dist/input-group.js +167 -54
  69. package/dist/input-otp.cjs +1 -1
  70. package/dist/input-otp.js +9 -9
  71. package/dist/input-password.cjs +1 -1
  72. package/dist/input-password.d.ts +28 -6
  73. package/dist/input-password.d.ts.map +1 -1
  74. package/dist/input-password.js +5 -5
  75. package/dist/input.cjs +1 -1
  76. package/dist/input.js +10 -10
  77. package/dist/lib/block-illustration.cjs +1 -1
  78. package/dist/lib/block-illustration.d.ts +4 -1
  79. package/dist/lib/block-illustration.d.ts.map +1 -1
  80. package/dist/lib/block-illustration.js +12 -11
  81. package/dist/lib/utils.cjs +1 -1
  82. package/dist/lib/utils.d.ts.map +1 -1
  83. package/dist/lib/utils.js +4 -3
  84. package/dist/list.cjs +1 -1
  85. package/dist/list.js +1 -1
  86. package/dist/multi-select-filter.cjs +1 -0
  87. package/dist/multi-select-filter.d.ts +178 -0
  88. package/dist/multi-select-filter.d.ts.map +1 -0
  89. package/dist/multi-select-filter.js +463 -0
  90. package/dist/progress.cjs +1 -1
  91. package/dist/progress.d.ts +123 -16
  92. package/dist/progress.d.ts.map +1 -1
  93. package/dist/progress.js +89 -75
  94. package/dist/rating.cjs +1 -1
  95. package/dist/rating.js +18 -18
  96. package/dist/relative-date.cjs +1 -0
  97. package/dist/relative-date.d.ts +65 -0
  98. package/dist/relative-date.d.ts.map +1 -0
  99. package/dist/relative-date.js +128 -0
  100. package/dist/select.cjs +2 -2
  101. package/dist/select.d.ts +11 -1
  102. package/dist/select.d.ts.map +1 -1
  103. package/dist/select.js +97 -81
  104. package/dist/sheet.cjs +1 -1
  105. package/dist/sheet.d.ts +78 -2
  106. package/dist/sheet.d.ts.map +1 -1
  107. package/dist/sheet.js +192 -85
  108. package/dist/single-select-filter.cjs +1 -0
  109. package/dist/single-select-filter.d.ts +81 -0
  110. package/dist/single-select-filter.d.ts.map +1 -0
  111. package/dist/single-select-filter.js +226 -0
  112. package/dist/sonner.cjs +1 -1
  113. package/dist/sonner.d.ts.map +1 -1
  114. package/dist/sonner.js +22 -22
  115. package/dist/split-layout.cjs +1 -1
  116. package/dist/split-layout.d.ts +1 -1
  117. package/dist/split-layout.js +13 -13
  118. package/dist/table.cjs +1 -1
  119. package/dist/table.d.ts +45 -4
  120. package/dist/table.d.ts.map +1 -1
  121. package/dist/table.js +90 -73
  122. package/dist/tabs.cjs +1 -1
  123. package/dist/tabs.d.ts +12 -1
  124. package/dist/tabs.d.ts.map +1 -1
  125. package/dist/tabs.js +148 -126
  126. package/dist/textarea.cjs +1 -1
  127. package/dist/textarea.js +1 -1
  128. package/dist/tooltip.cjs +1 -1
  129. package/dist/tooltip.d.ts +38 -36
  130. package/dist/tooltip.d.ts.map +1 -1
  131. package/dist/tooltip.js +262 -73
  132. package/dist/typography-text.d.ts +1 -2
  133. package/dist/typography-text.d.ts.map +1 -1
  134. package/dist/typography.d.ts +1 -1
  135. package/package.json +5 -6
  136. package/src/blocks/empty-state.tsx +8 -3
  137. package/src/blocks/progress-state.tsx +2 -2
  138. package/src/blocks/sidebar.tsx +26 -2
  139. package/src/components/alert-dialog.tsx +50 -5
  140. package/src/components/alert.tsx +16 -8
  141. package/src/components/badge.tsx +40 -3
  142. package/src/components/banner.tsx +288 -0
  143. package/src/components/brand-illustration-motif.tsx +1 -1
  144. package/src/components/card.tsx +211 -24
  145. package/src/components/chart.tsx +523 -35
  146. package/src/components/checkbox.tsx +1 -1
  147. package/src/components/combobox.tsx +2 -2
  148. package/src/components/command.tsx +1 -1
  149. package/src/components/data-table.tsx +778 -195
  150. package/src/components/grid.tsx +32 -1
  151. package/src/components/info-tooltip.tsx +94 -0
  152. package/src/components/input-chip.tsx +1 -1
  153. package/src/components/input-group.tsx +246 -11
  154. package/src/components/input-otp.tsx +1 -1
  155. package/src/components/input-password.tsx +33 -11
  156. package/src/components/input.tsx +1 -1
  157. package/src/components/list.tsx +1 -1
  158. package/src/components/multi-select-filter.tsx +912 -0
  159. package/src/components/progress.tsx +190 -31
  160. package/src/components/rating.tsx +1 -1
  161. package/src/components/relative-date.tsx +230 -0
  162. package/src/components/select.tsx +35 -5
  163. package/src/components/sheet.tsx +240 -4
  164. package/src/components/single-select-filter.tsx +443 -0
  165. package/src/components/sonner.tsx +16 -5
  166. package/src/components/split-layout.tsx +2 -2
  167. package/src/components/table.tsx +71 -11
  168. package/src/components/tabs.tsx +93 -46
  169. package/src/components/textarea.tsx +1 -1
  170. package/src/components/tooltip.tsx +440 -68
  171. package/src/components/typography-text.tsx +1 -2
  172. package/src/components/typography.tsx +1 -1
  173. package/src/hooks/use-breakpoint.ts +2 -1
  174. package/src/index.ts +5 -0
  175. package/src/lib/block-illustration.tsx +5 -1
  176. package/src/lib/utils.ts +1 -0
@@ -1,243 +1,286 @@
1
- import { jsx as a, jsxs as x, Fragment as T } from "react/jsx-runtime";
2
- import * as p from "react";
3
- import { useReactTable as se, getExpandedRowModel as ce, getFilteredRowModel as de, getSortedRowModel as ue, getPaginationRowModel as ge, getCoreRowModel as pe, flexRender as L } from "@tanstack/react-table";
4
- import { useVirtualizer as me } from "@tanstack/react-virtual";
5
- import { ArrowDown as he, ArrowUp as be, ArrowUpDown as fe, ChevronRight as xe, Search as we, X as Se } from "@brightlocal/icons";
6
- import { cn as g } from "@brightlocal/ui-components/lib/utils";
7
- import { useIsBelowBreakpoint as V } from "@brightlocal/ui-components/hooks/use-breakpoint";
8
- import { Button as j } from "./button.js";
9
- import { Checkbox as _ } from "./checkbox.js";
10
- import { InputGroup as Ce, InputGroupAddon as G, InputGroupInput as ke } from "./input-group.js";
11
- import { usePagination as ve, Pagination as Te, PaginationContent as Pe, PaginationItem as $, PaginationPrevious as ye, PaginationNext as Re, PaginationEllipsis as De, PaginationLink as Ne } from "./pagination.js";
12
- import { Skeleton as B } from "./skeleton.js";
13
- import { Table as U, TableBody as W, TableRow as k, TableCell as v, TableHeader as ze, TableHead as Ae } from "./table.js";
14
- import { TypographyMuted as Ie } from "./typography.js";
15
- function R(e, n, o) {
16
- const [t, r] = p.useState(n), l = e !== void 0 ? e : t, i = p.useRef(l);
17
- p.useEffect(() => {
18
- i.current = l;
1
+ import { jsxs as y, jsx as t, Fragment as N } from "react/jsx-runtime";
2
+ import * as g from "react";
3
+ import { useReactTable as ge, getExpandedRowModel as pe, getFilteredRowModel as fe, getSortedRowModel as be, getPaginationRowModel as me, getCoreRowModel as he, flexRender as W } from "@tanstack/react-table";
4
+ import { useVirtualizer as Se } from "@tanstack/react-virtual";
5
+ import { ArrowDown as xe, ArrowUp as ve, ArrowUpDown as we, ChevronRight as Ce, Search as ye } from "@brightlocal/icons";
6
+ import { cn as h } from "@brightlocal/ui-components/lib/utils";
7
+ import { useIsBelowBreakpoint as G } from "@brightlocal/ui-components/hooks/use-breakpoint";
8
+ import { Button as q } from "./button.js";
9
+ import { Checkbox as J } from "./checkbox.js";
10
+ import { InputGroup as ke, InputGroupAddon as Te, InputGroupInput as Pe, InputGroupClear as Re } from "./input-group.js";
11
+ import { usePagination as De, Pagination as Ne, PaginationContent as Ee, PaginationItem as F, PaginationPrevious as ze, PaginationNext as Ae, PaginationEllipsis as Ie, PaginationLink as $e } from "./pagination.js";
12
+ import { Skeleton as j } from "./skeleton.js";
13
+ import { Spinner as K } from "./spinner.js";
14
+ import { Table as Q, TableBody as X, TableRow as P, TableCell as R, scrollRegionProps as Y, TableHeader as Me, TableHead as Fe } from "./table.js";
15
+ import { TypographyMuted as He } from "./typography.js";
16
+ function z(e, a, i) {
17
+ const [n, o] = g.useState(a), s = e !== void 0 ? e : n, l = g.useRef(s);
18
+ g.useEffect(() => {
19
+ l.current = s;
19
20
  });
20
- const s = e !== void 0, d = p.useCallback(
21
- (c) => {
22
- const u = typeof c == "function" ? c(i.current) : c;
23
- s || r(u), o?.(u);
21
+ const c = e !== void 0, u = g.useCallback(
22
+ (r) => {
23
+ const d = typeof r == "function" ? r(l.current) : r;
24
+ c || o(d), i?.(d);
24
25
  },
25
- [s, o]
26
+ [c, i]
26
27
  );
27
- return [l, d];
28
+ return [s, u];
28
29
  }
29
- function da(e) {
30
+ function St(e) {
30
31
  const {
31
- columns: n,
32
- data: o,
33
- enableSorting: t = !0,
34
- enableGlobalFiltering: r = !1,
35
- enableRowSelection: l = !1,
36
- enablePagination: i = !1,
37
- pageSize: s = 10,
38
- manualSorting: d = !1,
39
- manualFiltering: c = !1,
40
- manualPagination: u = !1,
41
- rowCount: h,
42
- pageCount: b,
32
+ columns: a,
33
+ data: i,
34
+ enableSorting: n = !0,
35
+ enableGlobalFiltering: o = !1,
36
+ enableRowSelection: s = !1,
37
+ enablePagination: l = !1,
38
+ pageSize: c = 10,
39
+ manualSorting: u = !1,
40
+ manualFiltering: r = !1,
41
+ manualPagination: d = !1,
42
+ rowCount: b,
43
+ pageCount: f,
43
44
  enableExpanding: m = !1,
44
- getSubRows: w,
45
+ getSubRows: v,
45
46
  getRowCanExpand: S,
46
- paginateExpandedRows: P = !1,
47
- getRowId: f,
48
- pagination: E,
49
- onPaginationChange: D,
50
- sorting: y,
51
- onSortingChange: N,
52
- globalFilter: C,
53
- onGlobalFilterChange: M,
54
- rowSelection: z,
55
- onRowSelectionChange: A,
56
- expanded: F,
57
- onExpandedChange: I
58
- } = e, [Y, Z] = R(
59
- E,
60
- { pageIndex: 0, pageSize: s },
61
- D
62
- ), [ee, ae] = R(
63
- y,
47
+ paginateExpandedRows: w = !1,
48
+ getRowId: C,
49
+ pagination: k,
50
+ onPaginationChange: p,
51
+ sorting: x,
52
+ onSortingChange: D,
53
+ globalFilter: E,
54
+ onGlobalFilterChange: A,
55
+ rowSelection: T,
56
+ onRowSelectionChange: B,
57
+ expanded: I,
58
+ onExpandedChange: $
59
+ } = e, [V, M] = z(
60
+ k,
61
+ { pageIndex: 0, pageSize: c },
62
+ p
63
+ ), [le, oe] = z(
64
+ x,
64
65
  [],
65
- N
66
- ), [te, ne] = R(
67
- C,
66
+ D
67
+ ), [se, ie] = z(
68
+ E,
68
69
  "",
69
- M
70
- ), [oe, le] = R(z, {}, A), [ie, re] = R(
71
- F,
70
+ A
71
+ ), [re, ce] = z(T, {}, B), [de, ue] = z(
72
+ I,
72
73
  {},
73
- I
74
+ $
74
75
  );
75
- return se({
76
- data: o,
77
- columns: n,
78
- getCoreRowModel: pe(),
79
- ...f && { getRowId: f },
80
- ...(i || u) && {
81
- onPaginationChange: Z
76
+ return ge({
77
+ data: i,
78
+ columns: a,
79
+ getCoreRowModel: he(),
80
+ ...C && { getRowId: C },
81
+ ...(l || d) && {
82
+ onPaginationChange: M
82
83
  },
83
- ...i && {
84
- ...!u && {
85
- getPaginationRowModel: ge()
84
+ ...l && {
85
+ ...!d && {
86
+ getPaginationRowModel: me()
86
87
  }
87
88
  },
88
- ...u && {
89
+ ...d && {
89
90
  manualPagination: !0,
90
- ...h != null && { rowCount: h },
91
- ...b != null && { pageCount: b }
91
+ ...b != null && { rowCount: b },
92
+ ...f != null && { pageCount: f }
92
93
  },
93
94
  // Always forward the flag — TanStack defaults `enableSorting` to true,
94
95
  // so omitting it would leave `column.getCanSort()` returning true even
95
96
  // when the consumer disabled sorting table-wide.
96
- enableSorting: t,
97
- ...t && {
98
- ...!d && {
99
- getSortedRowModel: ue()
97
+ enableSorting: n,
98
+ ...n && {
99
+ ...!u && {
100
+ getSortedRowModel: be()
100
101
  },
101
- onSortingChange: ae,
102
- ...d && { manualSorting: !0 }
102
+ onSortingChange: oe,
103
+ ...u && { manualSorting: !0 }
103
104
  },
104
- ...r && {
105
- ...!c && {
106
- getFilteredRowModel: de()
105
+ ...o && {
106
+ ...!r && {
107
+ getFilteredRowModel: fe()
107
108
  },
108
- ...c && { manualFiltering: !0 },
109
- onGlobalFilterChange: ne,
109
+ ...r && { manualFiltering: !0 },
110
+ onGlobalFilterChange: ie,
110
111
  globalFilterFn: "includesString"
111
112
  },
112
113
  // Always forward — TanStack defaults `enableRowSelection` to true, so
113
114
  // omitting it would leave `row.getCanSelect()` returning true and
114
115
  // `DataTableSelectRowCheckbox` enabled on tables without selection.
115
- enableRowSelection: l,
116
+ enableRowSelection: s,
116
117
  // A predicate turns selection on for the table as a whole; individual rows
117
118
  // opt out through `row.getCanSelect()`, so the state wiring is still needed.
118
- ...l !== !1 && {
119
- onRowSelectionChange: le
119
+ ...s !== !1 && {
120
+ onRowSelectionChange: ce
120
121
  },
121
122
  // Always forward the flag — TanStack defaults `enableExpanding` to true,
122
123
  // so omitting it would leave `row.getCanExpand()` returning true and
123
124
  // `DataTableExpandRowButton` interactive on tables without expanding.
124
125
  enableExpanding: m,
125
126
  ...m && {
126
- getExpandedRowModel: ce(),
127
- onExpandedChange: re,
128
- getSubRows: w,
127
+ getExpandedRowModel: pe(),
128
+ onExpandedChange: ue,
129
+ getSubRows: v,
129
130
  ...S && { getRowCanExpand: S },
130
131
  // Forward only with client-side pagination: `paginateExpandedRows:
131
132
  // false` defers expansion to the pagination row model, so without one
132
133
  // it would suppress row expansion entirely.
133
- ...i && !u && { paginateExpandedRows: P }
134
+ ...l && !d && { paginateExpandedRows: w }
134
135
  },
135
136
  state: {
136
- pagination: Y,
137
- sorting: ee,
138
- globalFilter: te,
139
- rowSelection: oe,
140
- expanded: ie
137
+ pagination: V,
138
+ sorting: le,
139
+ globalFilter: se,
140
+ rowSelection: re,
141
+ expanded: de
141
142
  }
142
143
  });
143
144
  }
144
- function $e({
145
+ const H = g.createContext(!1);
146
+ function Be({
145
147
  table: e,
146
- dataHook: n,
147
- trackingEl: o,
148
- trackingLabel: t,
149
- isLoading: r = !1,
150
- skeletonRowCount: l,
151
- noResultsMessage: i = "No results.",
152
- stickyHeader: s = !1,
148
+ dataHook: a,
149
+ trackingEl: i,
150
+ trackingLabel: n,
151
+ isLoading: o = !1,
152
+ refetching: s = !1,
153
+ refetchingLabel: l,
154
+ skeletonRowCount: c,
155
+ noResultsMessage: u = "No results.",
156
+ stickyHeader: r = !1,
153
157
  className: d,
154
- layout: c,
155
- minWidth: u,
156
- scrollRegionLabel: h,
157
- footer: b,
158
- getRowClassName: m,
158
+ layout: b,
159
+ minWidth: f,
160
+ scrollRegionLabel: m,
161
+ footer: v,
162
+ getRowClassName: S,
159
163
  renderExpandedContent: w
160
164
  }) {
161
- const S = e.getVisibleLeafColumns().length, P = l ?? e.getState().pagination.pageSize ?? 10;
162
- return /* @__PURE__ */ a(
165
+ const C = e.getVisibleLeafColumns().length, k = c ?? e.getState().pagination.pageSize ?? 10, p = !!f || r || m !== void 0;
166
+ return /* @__PURE__ */ y(
163
167
  "div",
164
168
  {
165
- "aria-busy": r || void 0,
166
- className: g("border-border overflow-auto rounded-md border", d),
167
- "data-hook": n,
169
+ className: h(
170
+ // `scrollbar` themes the native scrollbar with DS colors — the same
171
+ // treatment Command/Combobox lists use for bounded scroll containers.
172
+ "border-border scrollbar relative overflow-auto rounded-md border",
173
+ p && "focus-visible:shadow-default outline-none",
174
+ d
175
+ ),
176
+ "data-hook": a,
168
177
  "data-slot": "data-table-view",
169
- "data-tracking-el": o,
170
- "data-tracking-label": t,
171
- children: /* @__PURE__ */ x(
172
- U,
173
- {
174
- dataHook: `${n}-table`,
175
- layout: c,
176
- minWidth: u,
177
- scrollRegionLabel: h,
178
- children: [
179
- /* @__PURE__ */ a(O, { stickyHeader: s, table: e }),
180
- /* @__PURE__ */ a(W, { children: r ? /* @__PURE__ */ x(T, { children: [
181
- /* @__PURE__ */ a(
182
- q,
178
+ "data-tracking-el": i,
179
+ "data-tracking-label": n,
180
+ ...p ? Y(m) : void 0,
181
+ children: [
182
+ /* @__PURE__ */ t("div", { "aria-live": "polite", className: "sr-only", role: "status", children: s ? l ?? "Loading results…" : null }),
183
+ /* @__PURE__ */ t(H.Provider, { value: s, children: /* @__PURE__ */ y(
184
+ Q,
185
+ {
186
+ "aria-busy": o || s || void 0,
187
+ dataHook: `${a}-table`,
188
+ layout: b,
189
+ minWidth: f,
190
+ scrollOwner: "parent",
191
+ children: [
192
+ /* @__PURE__ */ t(Z, { stickyHeader: r, table: e }),
193
+ /* @__PURE__ */ t(X, { children: o ? /* @__PURE__ */ y(N, { children: [
194
+ /* @__PURE__ */ t(
195
+ te,
196
+ {
197
+ colCount: C,
198
+ rowCount: k
199
+ }
200
+ ),
201
+ /* @__PURE__ */ t(P, { className: "sr-only", children: /* @__PURE__ */ t(R, { colSpan: C, children: /* @__PURE__ */ t("div", { "aria-live": "polite", role: "status", children: "Loading data…" }) }) })
202
+ ] }) : /* @__PURE__ */ t(N, { children: e.getRowModel().rows.length > 0 ? e.getRowModel().rows.map((x) => /* @__PURE__ */ t(
203
+ ee,
183
204
  {
184
- colCount: S,
185
- rowCount: P
186
- }
187
- ),
188
- /* @__PURE__ */ a(k, { className: "sr-only", children: /* @__PURE__ */ a(v, { colSpan: S, children: /* @__PURE__ */ a("div", { "aria-live": "polite", role: "status", children: "Loading data…" }) }) })
189
- ] }) : /* @__PURE__ */ a(T, { children: e.getRowModel().rows.length > 0 ? e.getRowModel().rows.map((f) => /* @__PURE__ */ a(
190
- X,
191
- {
192
- columnCount: S,
193
- getRowClassName: m,
194
- renderExpandedContent: w,
195
- row: f
196
- },
197
- f.id
198
- )) : /* @__PURE__ */ a(k, { children: /* @__PURE__ */ a(v, { align: "center", colSpan: S, size: "lg", children: /* @__PURE__ */ a("div", { "aria-live": "polite", className: "py-6", role: "status", children: i }) }) }) }) }),
199
- b
200
- ]
201
- }
202
- )
205
+ columnCount: C,
206
+ getRowClassName: S,
207
+ renderExpandedContent: w,
208
+ row: x
209
+ },
210
+ x.id
211
+ )) : /* @__PURE__ */ t(P, { children: /* @__PURE__ */ t(R, { align: "center", colSpan: C, size: "lg", children: /* @__PURE__ */ t("div", { "aria-live": "polite", className: "py-6", role: "status", children: u }) }) }) }) }),
212
+ v
213
+ ]
214
+ }
215
+ ) })
216
+ ]
203
217
  }
204
218
  );
205
219
  }
206
- $e.displayName = "DataTable";
207
- function O({
220
+ Be.displayName = "DataTable";
221
+ const _ = g.createContext(null), L = () => () => {
222
+ };
223
+ function Ve() {
224
+ const [e] = g.useState(() => {
225
+ const a = /* @__PURE__ */ new Map(), i = /* @__PURE__ */ new Set(), n = (o) => a.get(o) ?? null;
226
+ return {
227
+ set: (o, s) => {
228
+ const l = n(o);
229
+ l === s || l !== null && s !== null && l.displayed === s.displayed && l.live === s.live || (s === null ? a.delete(o) : a.set(o, s), i.forEach((c) => c()));
230
+ },
231
+ get: n,
232
+ anyHeld: () => {
233
+ for (const o of a.values())
234
+ if (o.displayed !== o.live)
235
+ return !0;
236
+ return !1;
237
+ },
238
+ subscribe: (o) => (i.add(o), () => {
239
+ i.delete(o);
240
+ })
241
+ };
242
+ });
243
+ return e;
244
+ }
245
+ function Z({
208
246
  table: e,
209
- stickyHeader: n
247
+ stickyHeader: a
210
248
  }) {
211
- return /* @__PURE__ */ a(ze, { className: g(n && "sticky top-0 z-10"), children: e.getHeaderGroups().map((o) => /* @__PURE__ */ a(k, { children: o.headers.map((t) => {
212
- const r = t.column.getCanSort() ? t.column.getIsSorted() : !1, l = r === "asc" ? "ascending" : r === "desc" ? "descending" : t.column.getCanSort() ? "none" : void 0, i = t.column.columnDef.meta;
213
- return /* @__PURE__ */ a(
214
- Ae,
215
- {
216
- "aria-sort": l,
217
- colSpan: t.colSpan,
218
- minWidth: i?.minWidth,
219
- width: i?.width,
220
- children: t.isPlaceholder ? null : L(
221
- t.column.columnDef.header,
222
- t.getContext()
223
- )
224
- },
225
- t.id
226
- );
227
- }) }, o.id)) });
249
+ const i = Ve();
250
+ return /* @__PURE__ */ t(_.Provider, { value: i, children: /* @__PURE__ */ t(Me, { className: h(a && "sticky top-0 z-10"), children: e.getHeaderGroups().map((n) => /* @__PURE__ */ t(P, { children: n.headers.map((o) => /* @__PURE__ */ t(je, { header: o }, o.id)) }, n.id)) }) });
228
251
  }
229
- function X({
252
+ function je({
253
+ header: e
254
+ }) {
255
+ const a = g.useContext(_), i = g.useSyncExternalStore(
256
+ a ? a.subscribe : L,
257
+ () => a ? a.get(e.column.id)?.displayed ?? null : null,
258
+ // Server render: no header has published yet — fall back to live state.
259
+ () => null
260
+ ), n = e.column.getCanSort(), o = n ? i ?? e.column.getIsSorted() : !1, s = o === "asc" ? "ascending" : o === "desc" ? "descending" : n ? "none" : void 0, l = e.column.columnDef.meta;
261
+ return /* @__PURE__ */ t(
262
+ Fe,
263
+ {
264
+ "aria-sort": s,
265
+ colSpan: e.colSpan,
266
+ minWidth: l?.minWidth,
267
+ width: l?.width,
268
+ children: e.isPlaceholder ? null : W(e.column.columnDef.header, e.getContext())
269
+ }
270
+ );
271
+ }
272
+ function ee({
230
273
  row: e,
231
- columnCount: n,
232
- getRowClassName: o,
233
- renderExpandedContent: t
274
+ columnCount: a,
275
+ getRowClassName: i,
276
+ renderExpandedContent: n
234
277
  }) {
235
- const r = e.getCanExpand(), l = e.getIsExpanded(), i = t && r && l ? t(e) : null;
236
- return /* @__PURE__ */ x(T, { children: [
237
- /* @__PURE__ */ a(
238
- k,
278
+ const o = e.getCanExpand(), s = e.getIsExpanded(), l = n && o && s ? n(e) : null;
279
+ return /* @__PURE__ */ y(N, { children: [
280
+ /* @__PURE__ */ t(
281
+ P,
239
282
  {
240
- className: g(
283
+ className: h(
241
284
  // Rows have no hover of their own — the chevron/action buttons are
242
285
  // the interactive elements. Ghost buttons (the only bg-transparent
243
286
  // variant) get bg-secondary on hover because their default
@@ -248,168 +291,212 @@ function X({
248
291
  // Surfaces are mutually exclusive: an expanded parent shares the
249
292
  // table head's bg-muted at ANY depth; other expanded-zone rows
250
293
  // (sub-rows) get the lighter accent wash.
251
- r && l ? "bg-muted" : e.depth > 0 && "bg-accent/50",
252
- o?.(e)
294
+ o && s ? "bg-muted" : e.depth > 0 && "bg-accent/50",
295
+ i?.(e)
253
296
  ),
254
297
  "data-depth": e.depth,
255
- "data-expanded": r ? String(l) : void 0,
298
+ "data-expanded": o ? String(s) : void 0,
256
299
  "data-state": e.getIsSelected() ? "selected" : void 0,
257
- children: e.getVisibleCells().map((s) => /* @__PURE__ */ a(v, { children: L(s.column.columnDef.cell, s.getContext()) }, s.id))
300
+ children: e.getVisibleCells().map((c) => /* @__PURE__ */ t(R, { children: W(c.column.columnDef.cell, c.getContext()) }, c.id))
258
301
  }
259
302
  ),
260
- i != null && // No data-depth here: panels are not data rows, and sharing the
303
+ l != null && // No data-depth here: panels are not data rows, and sharing the
261
304
  // parent's depth would break depth-based selectors and counts.
262
- /* @__PURE__ */ a(
263
- k,
305
+ /* @__PURE__ */ t(
306
+ P,
264
307
  {
265
308
  className: "bg-accent/50 [&_[data-slot=button].bg-transparent:hover]:bg-secondary",
266
309
  "data-slot": "data-table-expanded-row",
267
- children: /* @__PURE__ */ a(v, { colSpan: n, children: i })
310
+ children: /* @__PURE__ */ t(R, { colSpan: a, children: l })
268
311
  }
269
312
  )
270
313
  ] });
271
314
  }
272
- function q({
315
+ function te({
273
316
  rowCount: e,
274
- colCount: n
317
+ colCount: a
275
318
  }) {
276
- return /* @__PURE__ */ a(T, { children: Array.from({ length: e }).map((o, t) => /* @__PURE__ */ a(k, { children: Array.from({ length: n }).map((r, l) => /* @__PURE__ */ a(v, { children: /* @__PURE__ */ a(B, { className: "h-4 w-full" }) }, `skeleton-${t}-${l}`)) }, `skeleton-${t}`)) });
319
+ return /* @__PURE__ */ t(N, { children: Array.from({ length: e }).map((i, n) => /* @__PURE__ */ t(P, { children: Array.from({ length: a }).map((o, s) => /* @__PURE__ */ t(R, { children: /* @__PURE__ */ t(j, { className: "h-4 w-full" }) }, `skeleton-${n}-${s}`)) }, `skeleton-${n}`)) });
277
320
  }
278
- function Ee({
321
+ function Le({
279
322
  table: e,
280
- dataHook: n,
281
- trackingEl: o,
282
- trackingLabel: t,
283
- isLoading: r = !1,
284
- skeletonRowCount: l,
285
- noResultsMessage: i = "No results.",
286
- stickyHeader: s = !1,
323
+ dataHook: a,
324
+ trackingEl: i,
325
+ trackingLabel: n,
326
+ isLoading: o = !1,
327
+ refetching: s = !1,
328
+ refetchingLabel: l,
329
+ skeletonRowCount: c,
330
+ noResultsMessage: u = "No results.",
331
+ stickyHeader: r = !1,
287
332
  className: d,
288
- layout: c,
289
- minWidth: u,
290
- scrollRegionLabel: h,
291
- footer: b,
292
- getRowClassName: m,
333
+ layout: b,
334
+ minWidth: f,
335
+ scrollRegionLabel: m,
336
+ footer: v,
337
+ getRowClassName: S,
293
338
  height: w,
294
- estimateSize: S = 48,
295
- overscan: P = 5
339
+ estimateSize: C = 48,
340
+ overscan: k = 5
296
341
  }) {
297
- const f = e.getVisibleLeafColumns().length, E = l ?? e.getState().pagination.pageSize ?? 10, D = p.useRef(null), y = e.getRowModel().rows, N = me({
298
- count: y.length,
342
+ const p = e.getVisibleLeafColumns().length, x = c ?? e.getState().pagination.pageSize ?? 10, D = g.useRef(null), E = e.getRowModel().rows, A = Se({
343
+ count: E.length,
299
344
  getScrollElement: () => D.current,
300
- estimateSize: () => S,
301
- overscan: P
302
- }), C = N.getVirtualItems(), M = N.getTotalSize(), z = C.length > 0 ? C[0].start : 0, A = C.length > 0 ? M - C[C.length - 1].end : 0;
303
- return /* @__PURE__ */ a(
345
+ estimateSize: () => C,
346
+ overscan: k
347
+ }), T = A.getVirtualItems(), B = A.getTotalSize(), I = T.length > 0 ? T[0].start : 0, $ = T.length > 0 ? B - T[T.length - 1].end : 0;
348
+ return /* @__PURE__ */ y(
304
349
  "div",
305
350
  {
306
351
  ref: D,
307
- "aria-busy": r || void 0,
308
- className: g("border-border overflow-auto rounded-md border", d),
309
- "data-hook": n,
352
+ className: h(
353
+ // `scrollbar` themes the native scrollbar with DS colors (the
354
+ // Command/Combobox treatment for bounded scroll containers).
355
+ "border-border scrollbar relative overflow-auto rounded-md border",
356
+ // Always a focusable scroll region: virtualization requires a
357
+ // bounded viewport (height or a className bound), so this wrapper
358
+ // always scrolls vertically and keyboard users need to reach it.
359
+ "focus-visible:shadow-default outline-none",
360
+ d
361
+ ),
362
+ "data-hook": a,
310
363
  "data-slot": "data-table-view",
311
- "data-tracking-el": o,
312
- "data-tracking-label": t,
364
+ "data-tracking-el": i,
365
+ "data-tracking-label": n,
313
366
  style: w != null ? { height: w } : void 0,
314
- children: /* @__PURE__ */ x(
315
- U,
316
- {
317
- dataHook: `${n}-table`,
318
- layout: c,
319
- minWidth: u,
320
- scrollRegionLabel: h,
321
- children: [
322
- /* @__PURE__ */ a(O, { stickyHeader: s, table: e }),
323
- /* @__PURE__ */ a(W, { children: r ? /* @__PURE__ */ x(T, { children: [
324
- /* @__PURE__ */ a(
325
- q,
326
- {
327
- colCount: f,
328
- rowCount: E
329
- }
330
- ),
331
- /* @__PURE__ */ a(k, { className: "sr-only", children: /* @__PURE__ */ a(v, { colSpan: f, children: /* @__PURE__ */ a("div", { "aria-live": "polite", role: "status", children: "Loading data…" }) }) })
332
- ] }) : y.length > 0 ? /* @__PURE__ */ x(T, { children: [
333
- z > 0 && /* @__PURE__ */ a("tr", { "aria-hidden": "true", children: /* @__PURE__ */ a("td", { colSpan: f, style: { height: z } }) }),
334
- C.map((F) => {
335
- const I = y[F.index];
336
- return /* @__PURE__ */ a(
337
- X,
367
+ ...Y(m),
368
+ children: [
369
+ /* @__PURE__ */ t("div", { "aria-live": "polite", className: "sr-only", role: "status", children: s ? l ?? "Loading results…" : null }),
370
+ /* @__PURE__ */ t(H.Provider, { value: s, children: /* @__PURE__ */ y(
371
+ Q,
372
+ {
373
+ "aria-busy": o || s || void 0,
374
+ dataHook: `${a}-table`,
375
+ layout: b,
376
+ minWidth: f,
377
+ scrollOwner: "parent",
378
+ children: [
379
+ /* @__PURE__ */ t(Z, { stickyHeader: r, table: e }),
380
+ /* @__PURE__ */ t(X, { children: o ? /* @__PURE__ */ y(N, { children: [
381
+ /* @__PURE__ */ t(
382
+ te,
338
383
  {
339
- columnCount: f,
340
- getRowClassName: m,
341
- row: I
342
- },
343
- I.id
344
- );
345
- }),
346
- A > 0 && /* @__PURE__ */ a("tr", { "aria-hidden": "true", children: /* @__PURE__ */ a("td", { colSpan: f, style: { height: A } }) })
347
- ] }) : /* @__PURE__ */ a(k, { children: /* @__PURE__ */ a(v, { align: "center", colSpan: f, size: "lg", children: /* @__PURE__ */ a("div", { "aria-live": "polite", className: "py-6", role: "status", children: i }) }) }) }),
348
- b
349
- ]
350
- }
351
- )
384
+ colCount: p,
385
+ rowCount: x
386
+ }
387
+ ),
388
+ /* @__PURE__ */ t(P, { className: "sr-only", children: /* @__PURE__ */ t(R, { colSpan: p, children: /* @__PURE__ */ t("div", { "aria-live": "polite", role: "status", children: "Loading data…" }) }) })
389
+ ] }) : E.length > 0 ? /* @__PURE__ */ y(N, { children: [
390
+ I > 0 && /* @__PURE__ */ t("tr", { "aria-hidden": "true", children: /* @__PURE__ */ t("td", { colSpan: p, style: { height: I } }) }),
391
+ T.map((V) => {
392
+ const M = E[V.index];
393
+ return /* @__PURE__ */ t(
394
+ ee,
395
+ {
396
+ columnCount: p,
397
+ getRowClassName: S,
398
+ row: M
399
+ },
400
+ M.id
401
+ );
402
+ }),
403
+ $ > 0 && /* @__PURE__ */ t("tr", { "aria-hidden": "true", children: /* @__PURE__ */ t(
404
+ "td",
405
+ {
406
+ colSpan: p,
407
+ style: { height: $ }
408
+ }
409
+ ) })
410
+ ] }) : /* @__PURE__ */ t(P, { children: /* @__PURE__ */ t(R, { align: "center", colSpan: p, size: "lg", children: /* @__PURE__ */ t("div", { "aria-live": "polite", className: "py-6", role: "status", children: u }) }) }) }),
411
+ v
412
+ ]
413
+ }
414
+ ) })
415
+ ]
352
416
  }
353
417
  );
354
418
  }
355
- Ee.displayName = "VirtualizedDataTable";
356
- function Me({
419
+ Le.displayName = "VirtualizedDataTable";
420
+ function Oe({
357
421
  column: e,
358
- title: n,
359
- className: o,
360
- dataHook: t,
361
- trackingEl: r,
362
- trackingLabel: l,
363
- align: i = "left",
364
- getSortLabel: s
422
+ title: a,
423
+ className: i,
424
+ dataHook: n,
425
+ trackingEl: o,
426
+ trackingLabel: s,
427
+ align: l = "left",
428
+ getSortLabel: c,
429
+ loading: u = !1
365
430
  }) {
366
- if (!e.getCanSort())
367
- return /* @__PURE__ */ a(
431
+ const r = e.getIsSorted(), d = g.useContext(_), b = g.useSyncExternalStore(
432
+ d ? d.subscribe : L,
433
+ () => d ? d.get(e.id)?.displayed ?? null : null,
434
+ () => null
435
+ ), [f, m] = g.useState(r);
436
+ !d && !u && f !== r && m(r);
437
+ const S = u ? d ? b ?? r : f : r, w = S !== r, C = g.useSyncExternalStore(
438
+ d ? d.subscribe : L,
439
+ () => d ? d.anyHeld() : !1,
440
+ () => !1
441
+ ), p = u && (w || !(d ? C : w) && r !== !1);
442
+ if (g.useLayoutEffect(() => {
443
+ if (d)
444
+ return d.set(e.id, {
445
+ displayed: S,
446
+ live: r
447
+ }), () => {
448
+ d.set(e.id, null);
449
+ };
450
+ }, [d, e.id, S, r]), !e.getCanSort())
451
+ return /* @__PURE__ */ t(
368
452
  "div",
369
453
  {
370
- className: g(
454
+ className: h(
371
455
  "text-muted-foreground text-label text-left font-semibold",
372
- i === "right" && "text-right",
373
- i === "center" && "text-center",
374
- o
456
+ l === "right" && "text-right",
457
+ l === "center" && "text-center",
458
+ i
375
459
  ),
376
- "data-hook": t,
460
+ "data-hook": n,
377
461
  "data-slot": "data-table-column-header",
378
- "data-tracking-el": r,
379
- "data-tracking-label": l,
380
- children: n
462
+ "data-tracking-el": o,
463
+ "data-tracking-label": s,
464
+ children: a
381
465
  }
382
466
  );
383
- const d = e.getIsSorted(), c = d === !1 ? e.columnDef.sortDescFirst === !0 : d === "asc", u = s ? s(n, d) : d === "desc" ? `Sort by ${n}, currently descending` : d === "asc" ? `Sort by ${n}, currently ascending` : `Sort by ${n}`;
384
- return /* @__PURE__ */ a(
467
+ const x = r === !1 ? e.columnDef.sortDescFirst === !0 : r === "asc", D = c ? c(a, S) : S === "desc" ? `Sort by ${a}, currently descending` : S === "asc" ? `Sort by ${a}, currently ascending` : `Sort by ${a}`;
468
+ return /* @__PURE__ */ t(
385
469
  "div",
386
470
  {
387
- className: g(
471
+ className: h(
388
472
  "flex items-center",
389
- i === "right" && "justify-end",
390
- i === "center" && "justify-center",
391
- o
473
+ l === "right" && "justify-end",
474
+ l === "center" && "justify-center",
475
+ i
392
476
  ),
393
477
  "data-slot": "data-table-column-header",
394
- "data-tracking-el": r,
395
- "data-tracking-label": l,
396
- children: /* @__PURE__ */ x(
397
- j,
478
+ "data-tracking-el": o,
479
+ "data-tracking-label": s,
480
+ children: /* @__PURE__ */ y(
481
+ q,
398
482
  {
399
- "aria-label": u,
483
+ "aria-busy": u ? "true" : void 0,
484
+ "aria-label": D,
400
485
  className: "text-muted-foreground text-label h-auto p-0 font-semibold",
401
- dataHook: t || `column-header-${e.id}`,
486
+ dataHook: n || `column-header-${e.id}`,
402
487
  size: "sm",
403
488
  variant: "ghost",
404
- onClick: () => e.toggleSorting(c),
489
+ onClick: () => {
490
+ u || e.toggleSorting(x);
491
+ },
405
492
  children: [
406
- /* @__PURE__ */ a("span", { "aria-hidden": "true", children: n }),
407
- /* @__PURE__ */ a(
493
+ /* @__PURE__ */ t("span", { "aria-hidden": "true", children: a }),
494
+ /* @__PURE__ */ t(
408
495
  "span",
409
496
  {
410
497
  "aria-hidden": "true",
411
498
  className: "flex size-3 items-center justify-center",
412
- children: d === "desc" ? /* @__PURE__ */ a(he, { size: 12 }) : d === "asc" ? /* @__PURE__ */ a(be, { size: 12 }) : /* @__PURE__ */ a(fe, { size: 12 })
499
+ children: p ? /* @__PURE__ */ t(K, { size: "sm" }) : S === "desc" ? /* @__PURE__ */ t(xe, { size: 12 }) : S === "asc" ? /* @__PURE__ */ t(ve, { size: 12 }) : /* @__PURE__ */ t(we, { size: 12 })
413
500
  }
414
501
  )
415
502
  ]
@@ -418,469 +505,516 @@ function Me({
418
505
  }
419
506
  );
420
507
  }
421
- Me.displayName = "DataTableColumnHeader";
422
- function Fe({
508
+ Oe.displayName = "DataTableColumnHeader";
509
+ function Ge({
423
510
  table: e,
424
- ariaLabel: n,
425
- placeholder: o,
426
- clearSearchAriaLabel: t,
427
- ...r
511
+ ariaLabel: a,
512
+ placeholder: i,
513
+ clearSearchAriaLabel: n,
514
+ loading: o = !1,
515
+ debounceMs: s,
516
+ ...l
428
517
  }) {
429
- const l = e.getState().globalFilter ?? "", i = (s) => {
430
- e.setGlobalFilter(s);
518
+ const c = e.getState().globalFilter ?? "", [u, r] = g.useState(c), d = s ?? (e.options.manualFiltering === !0 ? 300 : 0), b = g.useRef(null), f = g.useCallback(() => {
519
+ b.current !== null && (clearTimeout(b.current), b.current = null);
520
+ }, []);
521
+ g.useEffect(() => f, [f]);
522
+ const m = g.useRef(u);
523
+ g.useEffect(() => {
524
+ m.current = u;
525
+ });
526
+ const [v, S] = g.useState({ filter: c, pushed: [] }), w = (p) => {
527
+ (e.getState().globalFilter ?? "") !== p && (S((x) => ({
528
+ filter: x.filter,
529
+ pushed: [...x.pushed, p].slice(-10)
530
+ })), e.setGlobalFilter(p));
531
+ }, C = (p) => {
532
+ f(), d > 0 ? b.current = setTimeout(() => {
533
+ b.current = null, m.current === p && w(p);
534
+ }, d) : w(p);
431
535
  };
432
- return /* @__PURE__ */ x(Ce, { "data-slot": "data-table-search", ...r, children: [
433
- /* @__PURE__ */ a(G, { className: "pl-3", children: /* @__PURE__ */ a(we, {}) }),
434
- /* @__PURE__ */ a(
435
- ke,
436
- {
437
- "aria-label": n ?? "Search table",
438
- placeholder: o ?? "Search...",
439
- type: "text",
440
- value: l,
441
- onChange: (s) => i(s.target.value)
442
- }
443
- ),
444
- l && /* @__PURE__ */ a(G, { className: "pr-1", children: /* @__PURE__ */ a(
445
- j,
446
- {
447
- "aria-label": t ?? "Clear search",
448
- className: "size-6 p-0",
449
- "data-slot": "data-table-search-clear",
450
- dataHook: `${r.dataHook}-clear`,
451
- variant: "ghost",
452
- onClick: () => i(""),
453
- children: /* @__PURE__ */ a(Se, { size: 14 })
454
- }
455
- ) })
456
- ] });
536
+ if (c !== v.filter) {
537
+ const p = v.pushed.lastIndexOf(c), x = p !== -1;
538
+ S({
539
+ filter: c,
540
+ pushed: x ? v.pushed.slice(p + 1) : v.pushed
541
+ }), !x && c !== u && r(c);
542
+ }
543
+ const k = () => {
544
+ f(), r(""), w("");
545
+ };
546
+ return /* @__PURE__ */ y(
547
+ ke,
548
+ {
549
+ "aria-busy": o ? "true" : void 0,
550
+ "data-slot": "data-table-search",
551
+ ...l,
552
+ children: [
553
+ /* @__PURE__ */ t(Te, { className: "pl-3", children: o ? /* @__PURE__ */ t(K, { dataHook: `${l.dataHook}-loading` }) : /* @__PURE__ */ t(ye, {}) }),
554
+ /* @__PURE__ */ t(
555
+ Pe,
556
+ {
557
+ "aria-label": a ?? "Search table",
558
+ placeholder: i ?? "Search...",
559
+ type: "text",
560
+ value: u,
561
+ onChange: (p) => {
562
+ const x = p.target.value;
563
+ r(x), C(x);
564
+ }
565
+ }
566
+ ),
567
+ /* @__PURE__ */ t(
568
+ Re,
569
+ {
570
+ clearSearchAriaLabel: n,
571
+ "data-slot": "data-table-search-clear",
572
+ dataHook: `${l.dataHook}-clear`,
573
+ onClear: d > 0 ? k : void 0
574
+ }
575
+ )
576
+ ]
577
+ }
578
+ );
457
579
  }
458
- Fe.displayName = "DataTableSearch";
459
- function Be(e) {
460
- const { pageIndex: n, pageSize: o } = e.getState().pagination, t = e.getRowCount(), r = e.getPageCount(), l = e.getCanPreviousPage(), i = e.getCanNextPage(), s = n + 1, d = t === 0 ? 0 : n * o + 1, c = Math.min(s * o, t), u = p.useCallback(
461
- (w) => e.setPageIndex(w - 1),
580
+ Ge.displayName = "DataTableSearch";
581
+ function _e(e) {
582
+ const { pageIndex: a, pageSize: i } = e.getState().pagination, n = e.getRowCount(), o = e.getPageCount(), s = e.getCanPreviousPage(), l = e.getCanNextPage(), c = a + 1, u = n === 0 ? 0 : a * i + 1, r = Math.min(c * i, n), d = g.useCallback(
583
+ (v) => e.setPageIndex(v - 1),
462
584
  [e]
463
- ), h = p.useCallback(() => e.nextPage(), [e]), b = p.useCallback(() => e.previousPage(), [e]), m = p.useCallback(
464
- (w) => e.setPageSize(w),
585
+ ), b = g.useCallback(() => e.nextPage(), [e]), f = g.useCallback(() => e.previousPage(), [e]), m = g.useCallback(
586
+ (v) => e.setPageSize(v),
465
587
  [e]
466
588
  );
467
- return p.useMemo(
589
+ return g.useMemo(
468
590
  () => ({
469
- pageIndex: n,
470
- pageSize: o,
471
- totalRows: t,
472
- totalPages: r,
473
- startRow: d,
474
- endRow: c,
475
- currentPage: s,
476
- canPrev: l,
477
- canNext: i,
478
- goToPage: u,
479
- nextPage: h,
480
- previousPage: b,
591
+ pageIndex: a,
592
+ pageSize: i,
593
+ totalRows: n,
594
+ totalPages: o,
595
+ startRow: u,
596
+ endRow: r,
597
+ currentPage: c,
598
+ canPrev: s,
599
+ canNext: l,
600
+ goToPage: d,
601
+ nextPage: b,
602
+ previousPage: f,
481
603
  setPageSize: m
482
604
  }),
483
605
  [
606
+ a,
607
+ i,
484
608
  n,
485
609
  o,
486
- t,
610
+ u,
487
611
  r,
488
- d,
489
612
  c,
490
613
  s,
491
614
  l,
492
- i,
493
- u,
494
- h,
615
+ d,
495
616
  b,
617
+ f,
496
618
  m
497
619
  ]
498
620
  );
499
621
  }
500
- const H = p.createContext(null);
501
- function J() {
502
- const e = p.useContext(H);
622
+ const O = g.createContext(null);
623
+ function ae() {
624
+ const e = g.useContext(O);
503
625
  if (!e)
504
626
  throw new Error(
505
627
  "DataTablePagination sub-components must be used within <DataTablePagination>"
506
628
  );
507
629
  return e;
508
630
  }
509
- function He({
631
+ function Ue({
510
632
  renderText: e,
511
- className: n
633
+ className: a
512
634
  }) {
513
- const { info: o } = J(), t = V("sm"), { startRow: r, endRow: l, totalRows: i, pageIndex: s, pageSize: d } = o;
514
- if (t) return null;
515
- const c = e ? e({ startRow: r, endRow: l, totalRows: i, pageIndex: s, pageSize: d }) : i === 0 ? null : `${r}-${l} of ${i}`;
516
- return c == null ? null : /* @__PURE__ */ a(
635
+ const { info: i } = ae(), n = G("sm"), { startRow: o, endRow: s, totalRows: l, pageIndex: c, pageSize: u } = i;
636
+ if (n) return null;
637
+ const r = e ? e({ startRow: o, endRow: s, totalRows: l, pageIndex: c, pageSize: u }) : l === 0 ? null : `${o}-${s} of ${l}`;
638
+ return r == null ? null : /* @__PURE__ */ t(
517
639
  "span",
518
640
  {
519
- className: g(
641
+ className: h(
520
642
  "text-body-sm text-muted-foreground whitespace-nowrap",
521
- n
643
+ a
522
644
  ),
523
645
  "data-slot": "data-table-pagination-row-count",
524
- children: c
646
+ children: r
525
647
  }
526
648
  );
527
649
  }
528
- He.displayName = "DataTablePaginationRowCount";
529
- function K({
650
+ Ue.displayName = "DataTablePaginationRowCount";
651
+ function ne({
530
652
  ariaLabel: e = "Table pagination",
531
- dataHook: n,
532
- className: o
653
+ dataHook: a,
654
+ className: i
533
655
  }) {
534
- const { info: t } = J(), r = V("sm"), l = ve({
535
- page: t.currentPage,
536
- totalPages: t.totalPages
656
+ const { info: n } = ae(), o = G("sm"), s = De({
657
+ page: n.currentPage,
658
+ totalPages: n.totalPages
537
659
  });
538
- return t.totalPages <= 1 ? null : /* @__PURE__ */ a(
539
- Te,
660
+ return n.totalPages <= 1 ? null : /* @__PURE__ */ t(
661
+ Ne,
540
662
  {
541
663
  ariaLabel: e,
542
- className: g(!r && "mx-0 w-auto justify-end", o),
543
- dataHook: n ?? "pagination-nav",
544
- children: /* @__PURE__ */ a(Pe, { children: l.map((i, s) => i === "previous" ? /* @__PURE__ */ a($, { children: /* @__PURE__ */ a(
545
- ye,
664
+ className: h(!o && "mx-0 w-auto justify-end", i),
665
+ dataHook: a ?? "pagination-nav",
666
+ children: /* @__PURE__ */ t(Ee, { children: s.map((l, c) => l === "previous" ? /* @__PURE__ */ t(F, { children: /* @__PURE__ */ t(
667
+ ze,
546
668
  {
547
- disabled: !t.canPrev,
548
- onClick: () => t.previousPage()
669
+ disabled: !n.canPrev,
670
+ onClick: () => n.previousPage()
549
671
  }
550
- ) }, "previous") : i === "next" ? /* @__PURE__ */ a($, { children: /* @__PURE__ */ a(
551
- Re,
672
+ ) }, "previous") : l === "next" ? /* @__PURE__ */ t(F, { children: /* @__PURE__ */ t(
673
+ Ae,
552
674
  {
553
- disabled: !t.canNext,
554
- onClick: () => t.nextPage()
675
+ disabled: !n.canNext,
676
+ onClick: () => n.nextPage()
555
677
  }
556
- ) }, "next") : i === "ellipsis" ? /* @__PURE__ */ a($, { children: /* @__PURE__ */ a(De, {}) }, `ellipsis-${s}`) : /* @__PURE__ */ a($, { children: /* @__PURE__ */ a(
557
- Ne,
678
+ ) }, "next") : l === "ellipsis" ? /* @__PURE__ */ t(F, { children: /* @__PURE__ */ t(Ie, {}) }, `ellipsis-${c}`) : /* @__PURE__ */ t(F, { children: /* @__PURE__ */ t(
679
+ $e,
558
680
  {
559
- isActive: i === t.currentPage,
560
- page: i,
561
- onClick: () => t.goToPage(i)
681
+ isActive: l === n.currentPage,
682
+ page: l,
683
+ onClick: () => n.goToPage(l)
562
684
  }
563
- ) }, i)) })
685
+ ) }, l)) })
564
686
  }
565
687
  );
566
688
  }
567
- K.displayName = "DataTablePaginationNav";
568
- function Ve({
689
+ ne.displayName = "DataTablePaginationNav";
690
+ function We({
569
691
  table: e,
570
- dataHook: n,
571
- showRowCount: o = !0,
572
- renderRowCount: t,
573
- trackingEl: r,
574
- trackingLabel: l,
575
- className: i,
576
- ariaLabel: s = "Table pagination",
577
- children: d
692
+ dataHook: a,
693
+ showRowCount: i = !0,
694
+ renderRowCount: n,
695
+ trackingEl: o,
696
+ trackingLabel: s,
697
+ className: l,
698
+ ariaLabel: c = "Table pagination",
699
+ children: u
578
700
  }) {
579
- const c = Be(e), u = V("sm"), h = p.useMemo(
580
- () => ({ info: c }),
581
- [c]
582
- ), b = {
583
- "data-hook": n,
701
+ const r = _e(e), d = G("sm"), b = g.useMemo(
702
+ () => ({ info: r }),
703
+ [r]
704
+ ), f = {
705
+ "data-hook": a,
584
706
  "data-slot": "data-table-pagination",
585
- "data-tracking-el": r,
586
- "data-tracking-label": l
707
+ "data-tracking-el": o,
708
+ "data-tracking-label": s
587
709
  };
588
- if (d)
589
- return /* @__PURE__ */ a(H.Provider, { value: h, children: /* @__PURE__ */ a(
710
+ if (u)
711
+ return /* @__PURE__ */ t(O.Provider, { value: b, children: /* @__PURE__ */ t(
590
712
  "div",
591
713
  {
592
- className: g(
714
+ className: h(
593
715
  "flex w-full flex-wrap items-center gap-x-4 gap-y-2",
594
- i
716
+ l
595
717
  ),
596
- ...b,
597
- children: d
718
+ ...f,
719
+ children: u
598
720
  }
599
721
  ) });
600
- const m = u || !o || t === null ? null : t ? t({
601
- startRow: c.startRow,
602
- endRow: c.endRow,
603
- totalRows: c.totalRows,
604
- pageIndex: c.pageIndex,
605
- pageSize: c.pageSize
606
- }) : c.totalRows === 0 ? null : `${c.startRow}-${c.endRow} of ${c.totalRows}`;
607
- return m == null && c.totalPages <= 1 ? null : /* @__PURE__ */ a(H.Provider, { value: h, children: /* @__PURE__ */ x(
722
+ const m = d || !i || n === null ? null : n ? n({
723
+ startRow: r.startRow,
724
+ endRow: r.endRow,
725
+ totalRows: r.totalRows,
726
+ pageIndex: r.pageIndex,
727
+ pageSize: r.pageSize
728
+ }) : r.totalRows === 0 ? null : `${r.startRow}-${r.endRow} of ${r.totalRows}`;
729
+ return m == null && r.totalPages <= 1 ? null : /* @__PURE__ */ t(O.Provider, { value: b, children: /* @__PURE__ */ y(
608
730
  "div",
609
731
  {
610
- className: g(
732
+ className: h(
611
733
  "flex min-h-9 w-full flex-wrap items-center gap-x-4 gap-y-2",
612
734
  m != null ? "justify-between" : "justify-end",
613
- i
735
+ l
614
736
  ),
615
- ...b,
737
+ ...f,
616
738
  children: [
617
- m != null && /* @__PURE__ */ a("span", { className: "text-body-sm text-muted-foreground whitespace-nowrap", children: m }),
618
- /* @__PURE__ */ a(
619
- K,
739
+ m != null && /* @__PURE__ */ t("span", { className: "text-body-sm text-muted-foreground whitespace-nowrap", children: m }),
740
+ /* @__PURE__ */ t(
741
+ ne,
620
742
  {
621
- ariaLabel: s,
743
+ ariaLabel: c,
622
744
  className: "grow",
623
- dataHook: `${n}-nav`
745
+ dataHook: `${a}-nav`
624
746
  }
625
747
  )
626
748
  ]
627
749
  }
628
750
  ) });
629
751
  }
630
- Ve.displayName = "DataTablePagination";
631
- function je({
752
+ We.displayName = "DataTablePagination";
753
+ function qe({
632
754
  table: e,
633
- dataHook: n,
634
- trackingEl: o,
635
- trackingLabel: t,
636
- selectAllAriaLabel: r
755
+ dataHook: a,
756
+ trackingEl: i,
757
+ trackingLabel: n,
758
+ selectAllAriaLabel: o
637
759
  }) {
638
- return /* @__PURE__ */ a(
639
- _,
760
+ const s = g.useContext(H);
761
+ return /* @__PURE__ */ t(
762
+ J,
640
763
  {
641
- "aria-label": r ?? "Select all",
764
+ "aria-disabled": s || void 0,
765
+ "aria-label": o ?? "Select all",
642
766
  checked: e.getIsAllPageRowsSelected() || e.getIsSomePageRowsSelected() && "indeterminate",
643
- dataHook: n || "select-all-checkbox",
644
- trackingEl: o,
645
- trackingLabel: t,
646
- onCheckedChange: (l) => e.toggleAllPageRowsSelected(!!l)
767
+ dataHook: a || "select-all-checkbox",
768
+ trackingEl: i,
769
+ trackingLabel: n,
770
+ onCheckedChange: (l) => {
771
+ s || e.toggleAllPageRowsSelected(!!l);
772
+ }
647
773
  }
648
774
  );
649
775
  }
650
- je.displayName = "DataTableSelectAllCheckbox";
651
- function Ge({
776
+ qe.displayName = "DataTableSelectAllCheckbox";
777
+ function Je({
652
778
  row: e,
653
- dataHook: n,
654
- trackingEl: o,
655
- trackingLabel: t,
656
- selectRowAriaLabel: r
779
+ dataHook: a,
780
+ trackingEl: i,
781
+ trackingLabel: n,
782
+ selectRowAriaLabel: o
657
783
  }) {
658
- return /* @__PURE__ */ a(
659
- _,
784
+ const s = g.useContext(H);
785
+ return /* @__PURE__ */ t(
786
+ J,
660
787
  {
661
- "aria-label": r ?? "Select row",
788
+ "aria-disabled": s || void 0,
789
+ "aria-label": o ?? "Select row",
662
790
  checked: e.getIsSelected(),
663
- dataHook: n || `select-row-${e.id}`,
791
+ dataHook: a || `select-row-${e.id}`,
664
792
  disabled: !e.getCanSelect(),
665
- trackingEl: o,
666
- trackingLabel: t,
667
- onCheckedChange: (l) => e.toggleSelected(!!l)
793
+ trackingEl: i,
794
+ trackingLabel: n,
795
+ onCheckedChange: (l) => {
796
+ s || e.toggleSelected(!!l);
797
+ }
668
798
  }
669
799
  );
670
800
  }
671
- Ge.displayName = "DataTableSelectRowCheckbox";
672
- function Le({
801
+ Je.displayName = "DataTableSelectRowCheckbox";
802
+ function Ke({
673
803
  row: e,
674
- rowName: n,
675
- dataHook: o,
676
- trackingEl: t,
677
- trackingLabel: r,
678
- expandLabel: l,
679
- collapseLabel: i,
680
- className: s
804
+ rowName: a,
805
+ dataHook: i,
806
+ trackingEl: n,
807
+ trackingLabel: o,
808
+ expandLabel: s,
809
+ collapseLabel: l,
810
+ className: c
681
811
  }) {
682
812
  if (!e.getCanExpand())
683
- return /* @__PURE__ */ a(
813
+ return /* @__PURE__ */ t(
684
814
  "span",
685
815
  {
686
816
  "aria-hidden": "true",
687
- className: g("inline-block size-9", s),
817
+ className: h("inline-block size-9", c),
688
818
  "data-slot": "data-table-expand-row-spacer"
689
819
  }
690
820
  );
691
- const d = e.getIsExpanded(), c = d ? i : l;
692
- let u;
693
- return c && (n !== void 0 || !c.includes("{name}")) ? u = c.replaceAll("{name}", n ?? "") : n !== void 0 ? u = d ? `Collapse details for ${n}` : `Expand details for ${n}` : u = d ? "Collapse row" : "Expand row", /* @__PURE__ */ a(
694
- j,
821
+ const u = e.getIsExpanded(), r = u ? l : s;
822
+ let d;
823
+ return r && (a !== void 0 || !r.includes("{name}")) ? d = r.replaceAll("{name}", a ?? "") : a !== void 0 ? d = u ? `Collapse details for ${a}` : `Expand details for ${a}` : d = u ? "Collapse row" : "Expand row", /* @__PURE__ */ t(
824
+ q,
695
825
  {
696
826
  iconOnly: !0,
697
- "aria-expanded": d,
698
- "aria-label": u,
699
- className: s,
700
- "data-state": d ? "open" : "closed",
701
- dataHook: o || `expand-row-${e.id}`,
827
+ "aria-expanded": u,
828
+ "aria-label": d,
829
+ className: c,
830
+ "data-state": u ? "open" : "closed",
831
+ dataHook: i || `expand-row-${e.id}`,
702
832
  size: "sm",
703
- trackingEl: t,
704
- trackingLabel: r,
833
+ trackingEl: n,
834
+ trackingLabel: o,
705
835
  variant: "ghost",
706
836
  onClick: e.getToggleExpandedHandler(),
707
- children: /* @__PURE__ */ a(
708
- xe,
837
+ children: /* @__PURE__ */ t(
838
+ Ce,
709
839
  {
710
840
  "aria-hidden": "true",
711
- className: g(
841
+ className: h(
712
842
  "duration-base transition-transform ease-in-out",
713
- d && "rotate-90"
843
+ u && "rotate-90"
714
844
  )
715
845
  }
716
846
  )
717
847
  }
718
848
  );
719
849
  }
720
- Le.displayName = "DataTableExpandRowButton";
721
- function _e({
850
+ Ke.displayName = "DataTableExpandRowButton";
851
+ function Qe({
722
852
  fields: e = 3,
723
- loadingLabel: n,
724
- dataHook: o,
725
- className: t
853
+ loadingLabel: a,
854
+ dataHook: i,
855
+ className: n
726
856
  }) {
727
- return /* @__PURE__ */ x(
857
+ return /* @__PURE__ */ y(
728
858
  "div",
729
859
  {
730
- className: g("relative flex flex-col gap-2 py-1", t),
731
- "data-hook": o || "data-table-expanded-skeleton",
860
+ className: h("relative flex flex-col gap-2 py-1", n),
861
+ "data-hook": i || "data-table-expanded-skeleton",
732
862
  "data-slot": "data-table-expanded-skeleton",
733
863
  role: "status",
734
864
  children: [
735
- /* @__PURE__ */ a("span", { className: "sr-only", children: n ?? "Loading details" }),
736
- Array.from({ length: e }, (r, l) => /* @__PURE__ */ x("div", { "aria-hidden": "true", className: "flex items-center gap-4", children: [
737
- /* @__PURE__ */ a(B, { className: "h-4 w-24 shrink-0" }),
738
- /* @__PURE__ */ a(B, { className: "h-4 w-48 max-w-full" })
739
- ] }, l))
865
+ /* @__PURE__ */ t("span", { className: "sr-only", children: a ?? "Loading details" }),
866
+ Array.from({ length: e }, (o, s) => /* @__PURE__ */ y("div", { "aria-hidden": "true", className: "flex items-center gap-4", children: [
867
+ /* @__PURE__ */ t(j, { className: "h-4 w-24 shrink-0" }),
868
+ /* @__PURE__ */ t(j, { className: "h-4 w-48 max-w-full" })
869
+ ] }, s))
740
870
  ]
741
871
  }
742
872
  );
743
873
  }
744
- _e.displayName = "DataTableExpandedSkeleton";
745
- const Q = p.createContext(null);
746
- function Ue() {
747
- const e = p.useContext(Q);
874
+ Qe.displayName = "DataTableExpandedSkeleton";
875
+ const U = g.createContext(null);
876
+ function Xe() {
877
+ const e = g.useContext(U);
748
878
  if (!e)
749
879
  throw new Error(
750
880
  "DataTableBulkActions components must be used within <DataTableBulkActions>"
751
881
  );
752
882
  return e;
753
883
  }
754
- function We({
884
+ function Ye({
755
885
  table: e,
756
- dataHook: n,
757
- trackingEl: o,
758
- trackingLabel: t,
759
- className: r,
760
- children: l
886
+ dataHook: a,
887
+ trackingEl: i,
888
+ trackingLabel: n,
889
+ className: o,
890
+ children: s,
891
+ refetching: l = !1
761
892
  }) {
762
- const i = e.getFilteredSelectedRowModel().rows.length, s = e.getRowCount(), d = p.useMemo(
763
- () => ({ selectedCount: i, totalCount: s }),
764
- [i, s]
893
+ const c = e.getFilteredSelectedRowModel().rows.length, u = e.getRowCount(), r = g.useMemo(
894
+ () => ({ selectedCount: c, totalCount: u, refetching: l }),
895
+ [c, u, l]
765
896
  );
766
- return i === 0 ? null : /* @__PURE__ */ a(Q.Provider, { value: d, children: /* @__PURE__ */ a(
897
+ return c === 0 ? null : /* @__PURE__ */ t(U.Provider, { value: r, children: /* @__PURE__ */ t(
767
898
  "div",
768
899
  {
769
- className: g("flex items-center gap-2.5", r),
770
- "data-hook": n,
900
+ "aria-busy": l || void 0,
901
+ className: h("flex items-center gap-2.5", o),
902
+ "data-hook": a,
771
903
  "data-slot": "data-table-bulk-actions",
772
- "data-tracking-el": o ?? "data-table-bulk-actions",
773
- "data-tracking-label": t,
774
- children: l
904
+ "data-tracking-el": i ?? "data-table-bulk-actions",
905
+ "data-tracking-label": n,
906
+ children: s
775
907
  }
776
908
  ) });
777
909
  }
778
- We.displayName = "DataTableBulkActions";
779
- function Oe({
910
+ Ye.displayName = "DataTableBulkActions";
911
+ function Ze({
780
912
  dataHook: e = "data-table-bulk-actions-summary",
781
- className: n,
782
- children: o
913
+ className: a,
914
+ children: i
783
915
  }) {
784
- const { selectedCount: t, totalCount: r } = Ue();
916
+ const n = Xe(), { selectedCount: o, totalCount: s } = n;
785
917
  let l;
786
- return typeof o == "function" ? l = o({ selectedCount: t, totalCount: r }) : o != null ? l = o : l = `${t} of ${r} row(s) selected.`, /* @__PURE__ */ a(
787
- Ie,
918
+ return typeof i == "function" ? l = i(n) : i != null ? l = i : l = `${o} of ${s} row(s) selected.`, /* @__PURE__ */ t(
919
+ He,
788
920
  {
789
921
  asChild: !0,
790
- className: g("min-w-0", n),
922
+ className: h("min-w-0", a),
791
923
  dataHook: e,
792
- children: /* @__PURE__ */ a("span", { "data-slot": "data-table-bulk-actions-summary", role: "status", children: l })
924
+ children: /* @__PURE__ */ t("span", { "data-slot": "data-table-bulk-actions-summary", role: "status", children: l })
793
925
  }
794
926
  );
795
927
  }
796
- Oe.displayName = "DataTableBulkActionsSummary";
797
- function Xe({
928
+ Ze.displayName = "DataTableBulkActionsSummary";
929
+ function et({
798
930
  dataHook: e = "data-table-bulk-actions-actions",
799
- className: n,
800
- children: o
931
+ className: a,
932
+ children: i
801
933
  }) {
802
- return /* @__PURE__ */ a(
934
+ const n = g.useContext(U)?.refetching ?? !1;
935
+ return /* @__PURE__ */ t(
803
936
  "div",
804
937
  {
805
- className: g("flex shrink-0 items-center gap-2", n),
938
+ className: h("flex shrink-0 items-center gap-2", a),
806
939
  "data-hook": e,
807
940
  "data-slot": "data-table-bulk-actions-actions",
808
- children: o
941
+ inert: n || void 0,
942
+ children: i
809
943
  }
810
944
  );
811
945
  }
812
- Xe.displayName = "DataTableBulkActionsActions";
813
- function qe({
946
+ et.displayName = "DataTableBulkActionsActions";
947
+ function tt({
814
948
  dataHook: e,
815
- className: n,
816
- children: o
949
+ className: a,
950
+ children: i
817
951
  }) {
818
- return /* @__PURE__ */ a(
952
+ return /* @__PURE__ */ t(
819
953
  "div",
820
954
  {
821
- className: g(
955
+ className: h(
822
956
  "flex flex-col gap-3 py-4 sm:flex-row sm:items-center",
823
- n
957
+ a
824
958
  ),
825
959
  "data-hook": e,
826
960
  "data-slot": "data-table-toolbar",
827
- children: o
961
+ children: i
828
962
  }
829
963
  );
830
964
  }
831
- qe.displayName = "DataTableToolbar";
832
- function Je({
965
+ tt.displayName = "DataTableToolbar";
966
+ function at({
833
967
  className: e,
834
- children: n
968
+ children: a
835
969
  }) {
836
- return /* @__PURE__ */ a(
970
+ return /* @__PURE__ */ t(
837
971
  "div",
838
972
  {
839
- className: g(
973
+ className: h(
840
974
  "flex w-full min-w-0 items-center gap-2 sm:w-auto sm:flex-1",
841
975
  e
842
976
  ),
843
977
  "data-slot": "data-table-toolbar-left",
844
- children: n
978
+ children: a
845
979
  }
846
980
  );
847
981
  }
848
- Je.displayName = "DataTableToolbarLeft";
849
- function Ke({
982
+ at.displayName = "DataTableToolbarLeft";
983
+ function nt({
850
984
  className: e,
851
- children: n
985
+ children: a
852
986
  }) {
853
- return /* @__PURE__ */ a(
987
+ return /* @__PURE__ */ t(
854
988
  "div",
855
989
  {
856
- className: g(
990
+ className: h(
857
991
  "flex w-full items-center justify-end gap-2 sm:w-auto",
858
992
  e
859
993
  ),
860
994
  "data-slot": "data-table-toolbar-right",
861
- children: n
995
+ children: a
862
996
  }
863
997
  );
864
998
  }
865
- Ke.displayName = "DataTableToolbarRight";
999
+ nt.displayName = "DataTableToolbarRight";
866
1000
  export {
867
- $e as DataTable,
868
- We as DataTableBulkActions,
869
- Xe as DataTableBulkActionsActions,
870
- Oe as DataTableBulkActionsSummary,
871
- Me as DataTableColumnHeader,
872
- Le as DataTableExpandRowButton,
873
- _e as DataTableExpandedSkeleton,
874
- Ve as DataTablePagination,
875
- K as DataTablePaginationNav,
876
- He as DataTablePaginationRowCount,
877
- Fe as DataTableSearch,
878
- je as DataTableSelectAllCheckbox,
879
- Ge as DataTableSelectRowCheckbox,
880
- qe as DataTableToolbar,
881
- Je as DataTableToolbarLeft,
882
- Ke as DataTableToolbarRight,
883
- Ee as VirtualizedDataTable,
884
- da as useDataTable,
885
- Ue as useDataTableBulkActionsContext
1001
+ Be as DataTable,
1002
+ Ye as DataTableBulkActions,
1003
+ et as DataTableBulkActionsActions,
1004
+ Ze as DataTableBulkActionsSummary,
1005
+ Oe as DataTableColumnHeader,
1006
+ Ke as DataTableExpandRowButton,
1007
+ Qe as DataTableExpandedSkeleton,
1008
+ We as DataTablePagination,
1009
+ ne as DataTablePaginationNav,
1010
+ Ue as DataTablePaginationRowCount,
1011
+ Ge as DataTableSearch,
1012
+ qe as DataTableSelectAllCheckbox,
1013
+ Je as DataTableSelectRowCheckbox,
1014
+ tt as DataTableToolbar,
1015
+ at as DataTableToolbarLeft,
1016
+ nt as DataTableToolbarRight,
1017
+ Le as VirtualizedDataTable,
1018
+ St as useDataTable,
1019
+ Xe as useDataTableBulkActionsContext
886
1020
  };