@stackone/malachite 2.132.0 → 2.133.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.
- package/COMPONENTS.md +5 -5
- package/dist/components/Button.js.map +1 -1
- package/dist/components/FormActions.js +13 -9
- package/dist/components/FormActions.js.map +1 -1
- package/dist/components/Input/Input.js +55 -54
- package/dist/components/Input/Input.js.map +1 -1
- package/dist/components/KeyValueList.js +36 -32
- package/dist/components/KeyValueList.js.map +1 -1
- package/dist/components/Surface.js +1 -1
- package/dist/components/Surface.js.map +1 -1
- package/dist/components/Table/Table.js +691 -637
- package/dist/components/Table/Table.js.map +1 -1
- package/dist/components/TextArea/TextArea.js +46 -46
- package/dist/components/TextArea/TextArea.js.map +1 -1
- package/dist/components/buttonStyles.js +2 -0
- package/dist/components/buttonStyles.js.map +1 -1
- package/dist/index.d.ts +33 -6
- package/dist/tailwind.css.js +1 -1
- package/dist/theme.js +11 -3
- package/dist/theme.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import { jsx as r, jsxs as
|
|
2
|
-
import { useVirtualizer as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import { devWarning as
|
|
13
|
-
import { FOCUS_RING_INSET as
|
|
14
|
-
import { FRAME_CLASS as
|
|
15
|
-
import { hasHeaderContent as
|
|
16
|
-
import { isFromInteractiveDescendant as
|
|
17
|
-
import { FOREGROUND_RESET as
|
|
18
|
-
import
|
|
19
|
-
import { paginationPlacement as
|
|
20
|
-
import { useFillHeight as
|
|
21
|
-
const
|
|
1
|
+
import { jsx as r, jsxs as $ } from "react/jsx-runtime";
|
|
2
|
+
import { useVirtualizer as cn } from "@tanstack/react-virtual";
|
|
3
|
+
import Re, { useState as K, useRef as q, useCallback as Ze, useId as fn, useEffect as ae, useMemo as _t, useLayoutEffect as Ft } from "react";
|
|
4
|
+
import zt from "../CustomIcons/CaretDownIcon.js";
|
|
5
|
+
import hn from "../CustomIcons/CaretUpIcon.js";
|
|
6
|
+
import un from "../CustomIcons/InfoIcon.js";
|
|
7
|
+
import pn from "../CustomIcons/WarningTriangleIcon.js";
|
|
8
|
+
import vn from "../FrameHeader.js";
|
|
9
|
+
import bn from "../PinnedCornerCap.js";
|
|
10
|
+
import gn from "../Tooltip.js";
|
|
11
|
+
import mn from "../TruncatedTooltip.js";
|
|
12
|
+
import { devWarning as xn } from "../devWarning.js";
|
|
13
|
+
import { FOCUS_RING_INSET as It, FOCUS_RING_INSET_OVERLAY as yn } from "../focusRing.js";
|
|
14
|
+
import { FRAME_CLASS as Sn, FRAME_PADDING as fe, FRAME_SECTION_RADIUS as he, FRAME_SECTION_BORDER as kn, FRAME_RADIUS as $n } from "../frameStyles.js";
|
|
15
|
+
import { hasHeaderContent as Ot } from "../headerContent.js";
|
|
16
|
+
import { isFromInteractiveDescendant as Tt, activateOnEnterOrSpace as Nn } from "../keyboardActivation.js";
|
|
17
|
+
import { FOREGROUND_RESET as Ke, SELECTED_ROW_ACCENT as At, SELECTED_TEXT_CONTEXT as Ht, SELECTED_ROW_FOREGROUND as Bt, SELECTED_ROW_BACKGROUND as tt } from "../selectedRow.js";
|
|
18
|
+
import wn from "./TablePagination.js";
|
|
19
|
+
import { paginationPlacement as En } from "./paginationPlacement.js";
|
|
20
|
+
import { useFillHeight as Rn } from "./useFillHeight.js";
|
|
21
|
+
const Pt = 160, Cn = (e, n) => e.length === n.length && e.every((o, h) => o === n[h]), Mt = "\0", _n = (e, n, o) => {
|
|
22
22
|
if (typeof e != "object" || e === null)
|
|
23
|
-
return `${
|
|
24
|
-
const
|
|
25
|
-
if (
|
|
26
|
-
return
|
|
27
|
-
const
|
|
28
|
-
return n.ids.set(e,
|
|
29
|
-
},
|
|
30
|
-
const
|
|
31
|
-
return
|
|
32
|
-
}),
|
|
23
|
+
return `${Mt}i${o}`;
|
|
24
|
+
const h = n.ids.get(e);
|
|
25
|
+
if (h !== void 0)
|
|
26
|
+
return h;
|
|
27
|
+
const b = `${Mt}${n.next++}`;
|
|
28
|
+
return n.ids.set(e, b), b;
|
|
29
|
+
}, In = (e, n, o) => typeof n == "function" ? e.map((h) => n(h)) : e.map((h, b) => {
|
|
30
|
+
const x = h[n];
|
|
31
|
+
return x == null ? _n(h, o, b) : String(x);
|
|
32
|
+
}), be = (e) => {
|
|
33
33
|
if (typeof e == "number")
|
|
34
34
|
return e;
|
|
35
35
|
if (typeof e == "string") {
|
|
@@ -37,257 +37,260 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
37
37
|
if (n)
|
|
38
38
|
return Number(n[1]);
|
|
39
39
|
}
|
|
40
|
-
},
|
|
41
|
-
const n =
|
|
40
|
+
}, it = (e) => {
|
|
41
|
+
const n = be(e.width);
|
|
42
42
|
return !(e.title === "" || e.title == null) && n !== void 0 && typeof e.minWidth == "number" && e.minWidth < n ? e.minWidth : void 0;
|
|
43
|
-
},
|
|
44
|
-
const
|
|
45
|
-
return
|
|
46
|
-
}, 0),
|
|
43
|
+
}, On = (e) => e.reduce((n, o) => {
|
|
44
|
+
const h = it(o) ?? be(o.width);
|
|
45
|
+
return h !== void 0 ? n + h : typeof o.minWidth == "number" ? n + o.minWidth : n + Pt;
|
|
46
|
+
}, 0), Tn = (e) => {
|
|
47
47
|
const n = typeof e == "string" ? e.trim().toLowerCase() : e;
|
|
48
|
-
return !n || n === "auto" || n === "0" ? 0 :
|
|
49
|
-
},
|
|
50
|
-
let n = 0, o = 0,
|
|
51
|
-
for (const { width:
|
|
52
|
-
const d =
|
|
48
|
+
return !n || n === "auto" || n === "0" ? 0 : be(e);
|
|
49
|
+
}, Mn = (e) => {
|
|
50
|
+
let n = 0, o = 0, h = 0;
|
|
51
|
+
for (const { width: b, minWidth: x } of e) {
|
|
52
|
+
const d = Tn(b);
|
|
53
53
|
if (d === void 0)
|
|
54
54
|
return;
|
|
55
|
-
d === 0 ? (n += 1, o = Math.max(o,
|
|
55
|
+
d === 0 ? (n += 1, o = Math.max(o, x ?? 0)) : h += d;
|
|
56
56
|
}
|
|
57
|
-
return o === 0 ? void 0 :
|
|
58
|
-
},
|
|
59
|
-
const n = [...e].reverse().findIndex((
|
|
60
|
-
(
|
|
61
|
-
const
|
|
62
|
-
return !(d.fixed === "right" ||
|
|
57
|
+
return o === 0 ? void 0 : h + n * o;
|
|
58
|
+
}, Dn = (e) => (e.title === "" || e.title == null) && be(e.width) !== void 0, Wn = (e) => {
|
|
59
|
+
const n = [...e].reverse().findIndex((x) => !Dn(x)), o = n === -1 ? 0 : e.length - n, h = /* @__PURE__ */ new Map(), b = e.reduceRight(
|
|
60
|
+
(x, d, R) => {
|
|
61
|
+
const m = it(d) ?? be(d.width);
|
|
62
|
+
return !(d.fixed === "right" || R >= o) || m === void 0 ? x : (h.set(d.key, x.right), { right: x.right + m, edge: d.key });
|
|
63
63
|
},
|
|
64
64
|
{ right: 0, edge: void 0 }
|
|
65
65
|
);
|
|
66
|
-
return { offsets:
|
|
67
|
-
},
|
|
66
|
+
return { offsets: h, edgeKey: b.edge, extent: b.right };
|
|
67
|
+
}, Ln = { overflowX: "auto", scrollbarWidth: "none" }, Fn = {
|
|
68
68
|
position: "sticky",
|
|
69
69
|
left: 0,
|
|
70
70
|
width: "100%"
|
|
71
|
-
},
|
|
71
|
+
}, zn = { offsets: /* @__PURE__ */ new Map(), edgeKey: void 0, extent: 0 }, Xe = (e) => `color-mix(in srgb, var(--malachite-card-shadow, rgba(0, 0, 0, 0.1)) ${e}%, transparent)`, An = {
|
|
72
72
|
position: "absolute",
|
|
73
73
|
top: 0,
|
|
74
74
|
bottom: 0,
|
|
75
75
|
right: 0,
|
|
76
76
|
width: 24,
|
|
77
77
|
pointerEvents: "none",
|
|
78
|
-
backgroundImage: `linear-gradient(to left, ${
|
|
79
|
-
},
|
|
78
|
+
backgroundImage: `linear-gradient(to left, ${Xe(45)}, ${Xe(18)} 30%, ${Xe(5)} 65%, transparent)`
|
|
79
|
+
}, Hn = (e, n) => e === void 0 ? {} : {
|
|
80
80
|
position: "sticky",
|
|
81
81
|
right: e,
|
|
82
82
|
zIndex: 1,
|
|
83
83
|
height: "auto",
|
|
84
84
|
...n === "row" ? { backgroundColor: "inherit", backgroundImage: "inherit" } : { backgroundColor: n }
|
|
85
|
-
},
|
|
85
|
+
}, Dt = (e) => `linear-gradient(${e}, ${e})`, Bn = (e, n) => {
|
|
86
86
|
if (!e && !n)
|
|
87
87
|
return {};
|
|
88
88
|
const o = [
|
|
89
|
-
n ?
|
|
90
|
-
e ?
|
|
91
|
-
].filter(
|
|
89
|
+
n ? Dt(tt) : void 0,
|
|
90
|
+
e ? Dt(`var(--malachite-table-row-variant-${e}-background)`) : void 0
|
|
91
|
+
].filter(lt);
|
|
92
92
|
return {
|
|
93
93
|
backgroundColor: e ? "var(--malachite-table-background, #f7f7f7)" : "var(--malachite-table-row-background, #fff)",
|
|
94
94
|
backgroundImage: o.join(", ")
|
|
95
95
|
};
|
|
96
|
-
},
|
|
96
|
+
}, lt = (e) => typeof e == "string", Pn = {
|
|
97
97
|
default: 40,
|
|
98
98
|
compact: 30,
|
|
99
99
|
snug: 38
|
|
100
|
-
},
|
|
100
|
+
}, Un = {
|
|
101
101
|
default: 40,
|
|
102
102
|
compact: 40,
|
|
103
103
|
snug: 34
|
|
104
|
-
},
|
|
104
|
+
}, Gn = {
|
|
105
105
|
default: "px-4 py-3",
|
|
106
106
|
compact: "px-4 py-1",
|
|
107
107
|
snug: "px-3 py-0"
|
|
108
|
-
},
|
|
108
|
+
}, jn = {
|
|
109
109
|
default: "px-4 py-3",
|
|
110
110
|
compact: "px-4 py-3",
|
|
111
111
|
snug: "px-3 py-[9px]"
|
|
112
|
-
},
|
|
112
|
+
}, nt = "text-[var(--malachite-text-primary,#0a0a0a)]", rt = "text-[var(--malachite-text-dimmed,#a1a1a1)]", ue = (e) => ({
|
|
113
113
|
small: "text-[length:var(--malachite-font-size-small)]",
|
|
114
114
|
medium: "text-[length:var(--malachite-font-size-medium)]",
|
|
115
115
|
large: "text-[length:var(--malachite-font-size-large)]"
|
|
116
|
-
})[e],
|
|
116
|
+
})[e], Wt = {
|
|
117
117
|
borderBottom: "1px solid var(--malachite-card-border, #e8e8e8)"
|
|
118
|
-
},
|
|
118
|
+
}, Lt = (e, n) => {
|
|
119
119
|
e && n && n.scrollLeft !== e.scrollLeft && (n.scrollLeft = e.scrollLeft);
|
|
120
|
-
},
|
|
121
|
-
|
|
120
|
+
}, Yn = 56, Jn = 44, qn = 8, Qn = 10, Vn = "--malachite-ctx-table-surround", et = "var(--malachite-table-header-background, #f7f7f7)", Zn = () => /* @__PURE__ */ r(
|
|
121
|
+
bn,
|
|
122
122
|
{
|
|
123
|
-
radius:
|
|
124
|
-
surround: `var(${
|
|
123
|
+
radius: $n,
|
|
124
|
+
surround: `var(${Vn}, var(--malachite-card-background, #ffffff))`
|
|
125
125
|
}
|
|
126
|
-
),
|
|
126
|
+
), Kn = ({
|
|
127
127
|
records: e,
|
|
128
128
|
startIndex: n,
|
|
129
129
|
scrollElement: o,
|
|
130
|
-
estimateRowHeight:
|
|
131
|
-
style:
|
|
132
|
-
renderRow:
|
|
130
|
+
estimateRowHeight: h,
|
|
131
|
+
style: b,
|
|
132
|
+
renderRow: x,
|
|
133
133
|
registerHandle: d,
|
|
134
|
-
cardKey:
|
|
135
|
-
rovingIndex:
|
|
134
|
+
cardKey: R,
|
|
135
|
+
rovingIndex: m
|
|
136
136
|
}) => {
|
|
137
|
-
const
|
|
138
|
-
|
|
139
|
-
const O =
|
|
137
|
+
const C = q(null), [z, _] = K(0);
|
|
138
|
+
Ft(() => {
|
|
139
|
+
const O = C.current;
|
|
140
140
|
if (!O || !o)
|
|
141
141
|
return;
|
|
142
|
-
const
|
|
143
|
-
const
|
|
144
|
-
|
|
142
|
+
const re = () => {
|
|
143
|
+
const L = O.getBoundingClientRect().top - o.getBoundingClientRect().top + o.scrollTop;
|
|
144
|
+
_((P) => Math.abs(P - L) < 1 ? P : L);
|
|
145
145
|
};
|
|
146
|
-
if (
|
|
146
|
+
if (re(), typeof ResizeObserver > "u")
|
|
147
147
|
return;
|
|
148
|
-
const
|
|
149
|
-
let
|
|
150
|
-
for (;
|
|
151
|
-
let
|
|
152
|
-
for (;
|
|
153
|
-
|
|
154
|
-
const
|
|
155
|
-
if (
|
|
156
|
-
|
|
148
|
+
const ie = new ResizeObserver(re);
|
|
149
|
+
let W = O;
|
|
150
|
+
for (; W && W !== o; ) {
|
|
151
|
+
let L = W.previousElementSibling;
|
|
152
|
+
for (; L; )
|
|
153
|
+
ie.observe(L), L = L.previousElementSibling;
|
|
154
|
+
const P = W.parentElement;
|
|
155
|
+
if (P)
|
|
156
|
+
W = P;
|
|
157
157
|
else {
|
|
158
|
-
const
|
|
159
|
-
|
|
158
|
+
const G = W.getRootNode();
|
|
159
|
+
W = G instanceof ShadowRoot ? G.host : null;
|
|
160
160
|
}
|
|
161
161
|
}
|
|
162
|
-
return () =>
|
|
162
|
+
return () => ie.disconnect();
|
|
163
163
|
}, [o, e.length, n]);
|
|
164
|
-
const
|
|
164
|
+
const I = cn({
|
|
165
165
|
count: e.length,
|
|
166
166
|
// State, not a ref: an ancestor's ref is not attached when this child's layout effects
|
|
167
167
|
// run, so a ref would leave the virtualizer without a scroll element.
|
|
168
168
|
getScrollElement: () => o,
|
|
169
|
-
estimateSize: () =>
|
|
170
|
-
overscan:
|
|
171
|
-
scrollMargin:
|
|
169
|
+
estimateSize: () => h,
|
|
170
|
+
overscan: qn,
|
|
171
|
+
scrollMargin: z
|
|
172
172
|
});
|
|
173
|
-
|
|
173
|
+
ae(() => {
|
|
174
174
|
if (d)
|
|
175
|
-
return d(
|
|
175
|
+
return d(R, {
|
|
176
176
|
startIndex: n,
|
|
177
177
|
count: e.length,
|
|
178
|
-
scrollToIndex: (O) =>
|
|
179
|
-
}), () => d(
|
|
180
|
-
}, [d,
|
|
181
|
-
const
|
|
182
|
-
Math.max(
|
|
183
|
-
n +
|
|
184
|
-
) :
|
|
185
|
-
return /* @__PURE__ */
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
(O) =>
|
|
178
|
+
scrollToIndex: (O) => I.scrollToIndex(O, { align: "center" })
|
|
179
|
+
}), () => d(R, null);
|
|
180
|
+
}, [d, R, n, e.length, I]);
|
|
181
|
+
const g = I.getVirtualItems(), D = I.getTotalSize(), A = m >= n && m < n + e.length && g.length > 0 ? Math.min(
|
|
182
|
+
Math.max(m, n + g[0].index),
|
|
183
|
+
n + g[g.length - 1].index
|
|
184
|
+
) : m, ne = g.length > 0 ? g[0].start - z : 0, B = g.length > 0 ? D - (g[g.length - 1].end - z) : 0;
|
|
185
|
+
return /* @__PURE__ */ $("div", { ref: C, className: "flex flex-col w-full", style: b, children: [
|
|
186
|
+
ne > 0 && /* @__PURE__ */ r("div", { "aria-hidden": "true", style: { height: ne, flexShrink: 0 } }),
|
|
187
|
+
g.map(
|
|
188
|
+
(O) => x(
|
|
189
189
|
e[O.index],
|
|
190
190
|
n + O.index,
|
|
191
191
|
O.index === e.length - 1,
|
|
192
192
|
O.index === 0,
|
|
193
|
-
{ measureRef:
|
|
194
|
-
|
|
193
|
+
{ measureRef: I.measureElement, index: O.index },
|
|
194
|
+
A
|
|
195
195
|
)
|
|
196
196
|
),
|
|
197
|
-
|
|
197
|
+
B > 0 && /* @__PURE__ */ r("div", { "aria-hidden": "true", style: { height: B, flexShrink: 0 } })
|
|
198
198
|
] });
|
|
199
|
-
},
|
|
200
|
-
const o = n ?
|
|
199
|
+
}, Xn = (e, n) => {
|
|
200
|
+
const o = n ? Yn : 0;
|
|
201
201
|
return typeof e == "number" ? `${Math.max(0, e - o)}px` : `calc(${e} - ${o}px)`;
|
|
202
|
-
},
|
|
202
|
+
}, pe = (e) => {
|
|
203
203
|
const n = e.width;
|
|
204
204
|
if (n == null)
|
|
205
205
|
return {};
|
|
206
|
-
const o = typeof n == "number" ? `${n}px` : n,
|
|
207
|
-
return
|
|
208
|
-
},
|
|
206
|
+
const o = typeof n == "number" ? `${n}px` : n, h = it(e);
|
|
207
|
+
return h === void 0 ? { flexBasis: o, maxWidth: o } : { flexBasis: o, maxWidth: o, minWidth: h, flexShrink: 1 };
|
|
208
|
+
}, ot = (e) => {
|
|
209
209
|
const n = e.width;
|
|
210
210
|
if (n == null)
|
|
211
211
|
return {};
|
|
212
212
|
const o = typeof n == "number" ? `${n}px` : n;
|
|
213
213
|
return { width: o, flexBasis: o };
|
|
214
|
-
},
|
|
214
|
+
}, Ut = (e) => e === "asc" ? "ascending" : e === "desc" ? "descending" : "none", er = 50, tr = (e, n) => e !== void 0 && Number.isFinite(e) && e >= 1 ? Math.min(Math.floor(e), er) : n, te = (e) => e === "center" ? "justify-center" : e === "right" ? "justify-end" : "justify-start", nr = (e) => e === "center" ? "justify-center" : e === "right" ? "justify-end" : "justify-between", ve = (e) => e === "center" ? "text-center" : e === "right" ? "text-right" : "text-left", Gt = (e) => e ? te(e) : "justify-end", Ce = ({ info: e }) => /* @__PURE__ */ r(gn, { text: e, placement: "top", children: /* @__PURE__ */ r(un, { size: 13, className: "shrink-0 text-[var(--malachite-text-secondary,#bbb)]" }) }), rr = { ascend: "asc", descend: "desc" }, ir = (e) => {
|
|
215
215
|
const n = e.find((o) => o.sorter && o.defaultSortOrder);
|
|
216
|
-
return n != null && n.defaultSortOrder ? { key: n.key, direction:
|
|
217
|
-
},
|
|
216
|
+
return n != null && n.defaultSortOrder ? { key: n.key, direction: rr[n.defaultSortOrder] } : null;
|
|
217
|
+
}, jt = (e, n) => ({
|
|
218
218
|
type: "button",
|
|
219
219
|
onClick: n,
|
|
220
220
|
"aria-label": typeof e == "string" ? `Sort by ${e}` : "Sort column"
|
|
221
|
-
}),
|
|
221
|
+
}), lr = ({
|
|
222
222
|
column: e,
|
|
223
223
|
record: n,
|
|
224
224
|
index: o,
|
|
225
|
-
size:
|
|
226
|
-
paddingClass:
|
|
227
|
-
height:
|
|
225
|
+
size: h,
|
|
226
|
+
paddingClass: b,
|
|
227
|
+
height: x,
|
|
228
228
|
bordered: d,
|
|
229
|
-
isFirstRow:
|
|
230
|
-
isLastRow:
|
|
231
|
-
isFirstColumn:
|
|
232
|
-
isLastColumn:
|
|
233
|
-
variantBackground:
|
|
234
|
-
showSelectedAccent:
|
|
235
|
-
isSelected:
|
|
236
|
-
minWidth:
|
|
229
|
+
isFirstRow: R,
|
|
230
|
+
isLastRow: m,
|
|
231
|
+
isFirstColumn: C,
|
|
232
|
+
isLastColumn: z,
|
|
233
|
+
variantBackground: _,
|
|
234
|
+
showSelectedAccent: I,
|
|
235
|
+
isSelected: g,
|
|
236
|
+
minWidth: D,
|
|
237
|
+
id: V
|
|
237
238
|
}) => {
|
|
238
|
-
const A = n[e.dataIndex],
|
|
239
|
+
const A = n[e.dataIndex], ne = e.render ? e.render(A, n, o) : A == null ? "" : String(A), B = e.ellipsis && lt(A) ? A : void 0;
|
|
239
240
|
return /* @__PURE__ */ r(
|
|
240
241
|
"td",
|
|
241
242
|
{
|
|
243
|
+
id: V,
|
|
242
244
|
className: `
|
|
243
|
-
table-cell ${
|
|
245
|
+
table-cell ${b} ${ue(h)}
|
|
244
246
|
${e.ellipsis ? "truncate overflow-hidden whitespace-nowrap" : ""}
|
|
245
247
|
${d ? "table-cell-bordered" : ""}
|
|
246
|
-
${d &&
|
|
247
|
-
${d &&
|
|
248
|
-
${d &&
|
|
249
|
-
${d &&
|
|
250
|
-
${d &&
|
|
251
|
-
${d &&
|
|
252
|
-
${d &&
|
|
253
|
-
${
|
|
248
|
+
${d && R ? "table-cell-bordered-top" : ""}
|
|
249
|
+
${d && C ? "table-cell-bordered-left" : ""}
|
|
250
|
+
${d && z ? "table-cell-bordered-right" : ""}
|
|
251
|
+
${d && C && R ? "rounded-tl-lg" : ""}
|
|
252
|
+
${d && z && R ? "rounded-tr-lg" : ""}
|
|
253
|
+
${d && C && m ? "rounded-bl-lg" : ""}
|
|
254
|
+
${d && z && m ? "rounded-br-lg" : ""}
|
|
255
|
+
${ve(e.align)}
|
|
254
256
|
`,
|
|
255
257
|
style: {
|
|
256
258
|
width: e.width,
|
|
257
|
-
minWidth:
|
|
258
|
-
height:
|
|
259
|
-
backgroundColor:
|
|
259
|
+
minWidth: D,
|
|
260
|
+
height: x,
|
|
261
|
+
backgroundColor: _ ?? // Mirror the row's background, or the tint composites over the wrong opaque
|
|
260
262
|
// base — they differ in dark mode.
|
|
261
|
-
(
|
|
263
|
+
(g ? d ? "var(--malachite-table-borderedRow-background, #fff)" : "var(--malachite-table-row-background, #fff)" : void 0),
|
|
262
264
|
// Its own layer, so the tint composites over the cell instead of replacing it.
|
|
263
|
-
backgroundImage:
|
|
265
|
+
backgroundImage: g ? `linear-gradient(${tt}, ${tt})` : void 0,
|
|
264
266
|
// Content pinning its own colour follows via the channel below.
|
|
265
|
-
color:
|
|
266
|
-
...
|
|
267
|
+
color: g ? Bt : "var(--malachite-table-row-foreground)",
|
|
268
|
+
...g ? Ht : {},
|
|
267
269
|
// Inset box-shadow, not `ring-*`: --tw-ring-* silently doesn't paint in a shadow root.
|
|
268
|
-
boxShadow:
|
|
269
|
-
borderBottom: d ? void 0 :
|
|
270
|
+
boxShadow: I ? `inset 2px 0 0 ${At}` : void 0,
|
|
271
|
+
borderBottom: d ? void 0 : m ? "none" : "1px solid var(--malachite-table-row-border)"
|
|
270
272
|
},
|
|
271
|
-
title:
|
|
272
|
-
children:
|
|
273
|
+
title: B,
|
|
274
|
+
children: ne
|
|
273
275
|
}
|
|
274
276
|
);
|
|
275
|
-
},
|
|
277
|
+
}, or = ({
|
|
276
278
|
column: e,
|
|
277
279
|
paddingClass: n,
|
|
278
280
|
sortDirection: o,
|
|
279
|
-
onSort:
|
|
280
|
-
cellStyle:
|
|
281
|
+
onSort: h,
|
|
282
|
+
cellStyle: b
|
|
281
283
|
}) => {
|
|
282
|
-
const
|
|
284
|
+
const x = !!e.sorter, d = e.title === "" || e.title == null;
|
|
283
285
|
if (d && e.width !== void 0)
|
|
284
286
|
return /* @__PURE__ */ r(
|
|
285
287
|
"div",
|
|
286
288
|
{
|
|
289
|
+
role: "columnheader",
|
|
287
290
|
className: "h-full shrink-0",
|
|
288
291
|
style: {
|
|
289
|
-
...
|
|
290
|
-
...
|
|
292
|
+
...ot(e),
|
|
293
|
+
...b
|
|
291
294
|
}
|
|
292
295
|
}
|
|
293
296
|
);
|
|
@@ -295,36 +298,39 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
295
298
|
return /* @__PURE__ */ r(
|
|
296
299
|
"div",
|
|
297
300
|
{
|
|
301
|
+
role: "columnheader",
|
|
298
302
|
className: "flex flex-[1_0_0] h-full min-w-0",
|
|
299
303
|
style: {
|
|
300
|
-
...
|
|
301
|
-
...
|
|
304
|
+
...pe(e),
|
|
305
|
+
...b
|
|
302
306
|
}
|
|
303
307
|
}
|
|
304
308
|
);
|
|
305
|
-
const
|
|
306
|
-
|
|
309
|
+
const m = typeof e.title == "string" ? /* @__PURE__ */ r("p", { className: "font-medium text-[13px] text-[var(--malachite-text-primary,#0a0a0a)] tracking-[0.13px] whitespace-nowrap truncate", children: e.title }) : e.title, C = /* @__PURE__ */ r(
|
|
310
|
+
zt,
|
|
307
311
|
{
|
|
308
312
|
size: 13,
|
|
309
|
-
className: `shrink-0 transition-transform ${o ?
|
|
313
|
+
className: `shrink-0 transition-transform ${o ? nt : rt} ${o === "asc" ? "rotate-180" : ""}`
|
|
310
314
|
}
|
|
311
315
|
);
|
|
312
|
-
return
|
|
316
|
+
return x ? /* @__PURE__ */ r(
|
|
313
317
|
"div",
|
|
314
318
|
{
|
|
319
|
+
role: "columnheader",
|
|
320
|
+
"aria-sort": Ut(o),
|
|
315
321
|
className: "flex flex-[1_0_0] min-w-0 overflow-hidden",
|
|
316
|
-
style: { ...
|
|
317
|
-
children: /* @__PURE__ */
|
|
322
|
+
style: { ...pe(e), ...b },
|
|
323
|
+
children: /* @__PURE__ */ $(
|
|
318
324
|
"button",
|
|
319
325
|
{
|
|
320
|
-
...
|
|
321
|
-
className: `flex flex-1 items-center ${
|
|
326
|
+
...jt(e.title, h),
|
|
327
|
+
className: `flex flex-1 items-center ${nr(e.align)} gap-1 min-w-0 ${n} cursor-pointer appearance-none bg-transparent border-0 ${ve(e.align)}`,
|
|
322
328
|
children: [
|
|
323
|
-
/* @__PURE__ */
|
|
324
|
-
|
|
325
|
-
e.info && /* @__PURE__ */ r(
|
|
329
|
+
/* @__PURE__ */ $("div", { className: "flex items-center gap-1 min-w-0", children: [
|
|
330
|
+
m,
|
|
331
|
+
e.info && /* @__PURE__ */ r(Ce, { info: e.info })
|
|
326
332
|
] }),
|
|
327
|
-
|
|
333
|
+
C
|
|
328
334
|
]
|
|
329
335
|
}
|
|
330
336
|
)
|
|
@@ -332,295 +338,299 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
332
338
|
) : /* @__PURE__ */ r(
|
|
333
339
|
"div",
|
|
334
340
|
{
|
|
335
|
-
|
|
341
|
+
role: "columnheader",
|
|
342
|
+
className: `flex flex-[1_0_0] items-center ${te(e.align)} min-w-0 overflow-hidden ${n}`,
|
|
336
343
|
style: {
|
|
337
|
-
...
|
|
338
|
-
...
|
|
344
|
+
...pe(e),
|
|
345
|
+
...b
|
|
339
346
|
},
|
|
340
|
-
children: /* @__PURE__ */
|
|
341
|
-
|
|
342
|
-
e.info && /* @__PURE__ */ r(
|
|
347
|
+
children: /* @__PURE__ */ $("div", { className: "flex items-center gap-1 min-w-0", children: [
|
|
348
|
+
m,
|
|
349
|
+
e.info && /* @__PURE__ */ r(Ce, { info: e.info })
|
|
343
350
|
] })
|
|
344
351
|
}
|
|
345
352
|
);
|
|
346
|
-
},
|
|
353
|
+
}, ar = ({
|
|
347
354
|
column: e,
|
|
348
355
|
record: n,
|
|
349
356
|
index: o,
|
|
350
|
-
size:
|
|
351
|
-
paddingClass:
|
|
352
|
-
isSelected:
|
|
353
|
-
cellStyle: d
|
|
357
|
+
size: h,
|
|
358
|
+
paddingClass: b,
|
|
359
|
+
isSelected: x = !1,
|
|
360
|
+
cellStyle: d,
|
|
361
|
+
id: R
|
|
354
362
|
}) => {
|
|
355
|
-
const
|
|
356
|
-
color:
|
|
357
|
-
...
|
|
363
|
+
const m = n[e.dataIndex], C = e.render ? e.render(m, n, o) : m == null ? "" : String(m), _ = (e.title === "" || e.title == null) && e.width !== void 0, I = lt(m) && m.length > 0, g = x ? {
|
|
364
|
+
color: Bt,
|
|
365
|
+
...Ht
|
|
358
366
|
} : {};
|
|
359
|
-
if (
|
|
367
|
+
if (_)
|
|
360
368
|
return /* @__PURE__ */ r(
|
|
361
369
|
"div",
|
|
362
370
|
{
|
|
363
|
-
|
|
371
|
+
role: "cell",
|
|
372
|
+
id: R,
|
|
373
|
+
className: `flex items-center ${Gt(e.align)} shrink-0 overflow-hidden ${b}`,
|
|
364
374
|
style: {
|
|
365
|
-
...
|
|
366
|
-
...
|
|
375
|
+
...ot(e),
|
|
376
|
+
...g,
|
|
367
377
|
...d
|
|
368
378
|
},
|
|
369
|
-
children:
|
|
379
|
+
children: C
|
|
370
380
|
}
|
|
371
381
|
);
|
|
372
|
-
const
|
|
382
|
+
const D = !e.render && I ? /* @__PURE__ */ r(mn, { text: m, children: C }) : C;
|
|
373
383
|
return /* @__PURE__ */ r(
|
|
374
384
|
"div",
|
|
375
385
|
{
|
|
376
|
-
|
|
386
|
+
role: "cell",
|
|
387
|
+
id: R,
|
|
388
|
+
className: `flex flex-[1_0_0] items-center min-w-0 overflow-hidden ${b} ${ue(h)} ${te(e.align)}`,
|
|
377
389
|
style: {
|
|
378
|
-
...
|
|
379
|
-
...
|
|
390
|
+
...pe(e),
|
|
391
|
+
...g,
|
|
380
392
|
...d
|
|
381
393
|
},
|
|
382
|
-
children:
|
|
394
|
+
children: D
|
|
383
395
|
}
|
|
384
396
|
);
|
|
385
|
-
},
|
|
397
|
+
}, Cr = ({
|
|
386
398
|
columns: e,
|
|
387
399
|
data: n,
|
|
388
400
|
loading: o = !1,
|
|
389
|
-
loadingRowCount:
|
|
390
|
-
"aria-label":
|
|
391
|
-
"aria-labelledby":
|
|
401
|
+
loadingRowCount: h,
|
|
402
|
+
"aria-label": b,
|
|
403
|
+
"aria-labelledby": x,
|
|
392
404
|
error: d = !1,
|
|
393
|
-
errorTitle:
|
|
394
|
-
errorSubTitle:
|
|
395
|
-
emptyTitle:
|
|
396
|
-
emptySubTitle:
|
|
397
|
-
bordered:
|
|
398
|
-
showHeader:
|
|
399
|
-
rowKey:
|
|
400
|
-
scrollHeight:
|
|
401
|
-
size:
|
|
402
|
-
rowDensity:
|
|
403
|
-
layout:
|
|
404
|
-
headerVariant:
|
|
405
|
+
errorTitle: R = "Data unavailable",
|
|
406
|
+
errorSubTitle: m = "There was an issue retrieving the data. Please try again.",
|
|
407
|
+
emptyTitle: C = "No data",
|
|
408
|
+
emptySubTitle: z = "",
|
|
409
|
+
bordered: _ = !1,
|
|
410
|
+
showHeader: I = !0,
|
|
411
|
+
rowKey: g = "key",
|
|
412
|
+
scrollHeight: D,
|
|
413
|
+
size: V = "small",
|
|
414
|
+
rowDensity: A = "default",
|
|
415
|
+
layout: ne = "auto",
|
|
416
|
+
headerVariant: B = "inline",
|
|
405
417
|
title: O,
|
|
406
|
-
subtitle:
|
|
407
|
-
extra:
|
|
408
|
-
rowClassName:
|
|
409
|
-
rowVariant:
|
|
410
|
-
onRow:
|
|
411
|
-
onClickRow:
|
|
412
|
-
selectedRowKey:
|
|
413
|
-
scrollSelectedIntoView:
|
|
414
|
-
rowSelection:
|
|
418
|
+
subtitle: re,
|
|
419
|
+
extra: ie,
|
|
420
|
+
rowClassName: W,
|
|
421
|
+
rowVariant: L,
|
|
422
|
+
onRow: P,
|
|
423
|
+
onClickRow: G,
|
|
424
|
+
selectedRowKey: j,
|
|
425
|
+
scrollSelectedIntoView: at = !0,
|
|
426
|
+
rowSelection: st,
|
|
415
427
|
pagination: w,
|
|
416
|
-
className:
|
|
417
|
-
style:
|
|
418
|
-
stickyHeaderTop:
|
|
419
|
-
scrollX:
|
|
420
|
-
rowSection:
|
|
421
|
-
renderSectionDivider:
|
|
422
|
-
onVisibleOrderChange:
|
|
423
|
-
virtual:
|
|
424
|
-
virtualRowHeightEstimate:
|
|
425
|
-
virtualScrollElement:
|
|
428
|
+
className: dt = "",
|
|
429
|
+
style: _e,
|
|
430
|
+
stickyHeaderTop: Ie,
|
|
431
|
+
scrollX: Y = !1,
|
|
432
|
+
rowSection: Oe,
|
|
433
|
+
renderSectionDivider: Te,
|
|
434
|
+
onVisibleOrderChange: Me,
|
|
435
|
+
virtual: Yt = !1,
|
|
436
|
+
virtualRowHeightEstimate: Jt,
|
|
437
|
+
virtualScrollElement: ge = null
|
|
426
438
|
}) => {
|
|
427
|
-
|
|
439
|
+
var Rt, Ct;
|
|
440
|
+
const se = Gn[A], De = jn[A], We = Pn[A], ct = A === "snug" ? We : void 0, [E, qt] = K(() => ir(e)), ft = q(null), Le = q(null), de = q(null), Fe = q(null), ze = q(/* @__PURE__ */ new Map()), Qt = Ze(
|
|
428
441
|
(t, i) => {
|
|
429
|
-
i ?
|
|
442
|
+
i ? ze.current.set(t, i) : ze.current.delete(t);
|
|
430
443
|
},
|
|
431
444
|
[]
|
|
432
|
-
),
|
|
433
|
-
|
|
434
|
-
}, []),
|
|
435
|
-
|
|
436
|
-
|
|
445
|
+
), Q = fn(), ht = ((Rt = e.find((t) => t.title !== "" && t.title != null)) == null ? void 0 : Rt.key) ?? ((Ct = e[0]) == null ? void 0 : Ct.key), me = (t) => `${Q}-row-${t}-label`, [Vt, Ae] = K(0), Z = Yt && B === "detached", Zt = Jt ?? Jn, [ce, Kt] = K(null), Xt = Ze((t) => {
|
|
446
|
+
de.current = t, t && Kt((i) => i === t ? i : t);
|
|
447
|
+
}, []), He = Z ? ge ?? ce : null, [en, ut] = K(null), xe = D === "fill", pt = Rn(
|
|
448
|
+
B === "detached" ? ce : en,
|
|
449
|
+
xe,
|
|
437
450
|
// The pager is only drawn once loaded, and takes its height out of the room.
|
|
438
451
|
!!w && !o
|
|
439
|
-
),
|
|
440
|
-
const t =
|
|
441
|
-
|
|
452
|
+
), Be = pt === void 0 ? void 0 : `${pt}px`, vt = Y ? On(e) : 0, ye = Y && B === "detached" ? Wn(e) : zn, Se = ye.edgeKey !== void 0, [tn, bt] = K(!1), [nn, gt] = K(0), ke = Ze(() => {
|
|
453
|
+
const t = de.current;
|
|
454
|
+
bt(
|
|
442
455
|
t !== null && t.scrollLeft + t.clientWidth < t.scrollWidth - 1
|
|
443
|
-
),
|
|
456
|
+
), gt(t === null ? 0 : t.offsetWidth - t.clientWidth);
|
|
444
457
|
}, []);
|
|
445
|
-
|
|
446
|
-
if (!
|
|
447
|
-
|
|
458
|
+
ae(() => {
|
|
459
|
+
if (!Se || !ce) {
|
|
460
|
+
bt(!1), gt(0);
|
|
448
461
|
return;
|
|
449
462
|
}
|
|
450
|
-
if (
|
|
463
|
+
if (ke(), typeof ResizeObserver > "u")
|
|
451
464
|
return;
|
|
452
|
-
const t = new ResizeObserver(
|
|
453
|
-
return t.observe(
|
|
454
|
-
}, [
|
|
455
|
-
const
|
|
456
|
-
|
|
457
|
-
const t =
|
|
458
|
-
if (!t || !
|
|
459
|
-
|
|
465
|
+
const t = new ResizeObserver(ke);
|
|
466
|
+
return t.observe(ce), () => t.disconnect();
|
|
467
|
+
}, [Se, ce, vt, ke]);
|
|
468
|
+
const Pe = !(Z && ge), J = B === "detached" && Ie !== void 0 && I && !D && (!Z || !Pe), mt = j != null, [Ue, xt] = K(0);
|
|
469
|
+
ae(() => {
|
|
470
|
+
const t = ft.current;
|
|
471
|
+
if (!t || !J || !mt || typeof ResizeObserver > "u") {
|
|
472
|
+
xt(0);
|
|
460
473
|
return;
|
|
461
474
|
}
|
|
462
|
-
const i = new ResizeObserver((
|
|
463
|
-
var
|
|
464
|
-
const a =
|
|
465
|
-
|
|
466
|
-
(
|
|
475
|
+
const i = new ResizeObserver((c) => {
|
|
476
|
+
var p, v;
|
|
477
|
+
const a = c[0], u = ((v = (p = a == null ? void 0 : a.borderBoxSize) == null ? void 0 : p[0]) == null ? void 0 : v.blockSize) ?? (a == null ? void 0 : a.contentRect.height) ?? 0;
|
|
478
|
+
xt(
|
|
479
|
+
(S) => Math.abs(S - u) < 1 ? S : u
|
|
467
480
|
);
|
|
468
481
|
});
|
|
469
482
|
return i.observe(t), () => i.disconnect();
|
|
470
|
-
}, [
|
|
471
|
-
const
|
|
472
|
-
const t = (
|
|
473
|
-
if (!
|
|
474
|
-
const
|
|
475
|
-
if (!
|
|
476
|
-
if (typeof
|
|
477
|
-
const
|
|
478
|
-
return
|
|
483
|
+
}, [J, mt]);
|
|
484
|
+
const rn = J ? (Ie ?? 0) + Ue : void 0, { sortedData: T, sectionDividers: Ge } = _t(() => {
|
|
485
|
+
const t = (p) => {
|
|
486
|
+
if (!E) return p;
|
|
487
|
+
const v = e.find((U) => U.key === E.key);
|
|
488
|
+
if (!v || v.sorter === "server") return p;
|
|
489
|
+
if (typeof v.sorter == "function") {
|
|
490
|
+
const U = [...p].sort(v.sorter);
|
|
491
|
+
return E.direction === "asc" ? U : U.reverse();
|
|
479
492
|
}
|
|
480
|
-
const
|
|
481
|
-
return [...
|
|
482
|
-
const l =
|
|
483
|
-
return l <
|
|
493
|
+
const S = v.dataIndex ?? E.key;
|
|
494
|
+
return [...p].sort((U, M) => {
|
|
495
|
+
const l = U[S], s = M[S];
|
|
496
|
+
return l < s ? E.direction === "asc" ? -1 : 1 : l > s ? E.direction === "asc" ? 1 : -1 : 0;
|
|
484
497
|
});
|
|
485
498
|
};
|
|
486
|
-
if (!
|
|
499
|
+
if (!Oe)
|
|
487
500
|
return {
|
|
488
501
|
sortedData: t(n),
|
|
489
502
|
sectionDividers: /* @__PURE__ */ new Map()
|
|
490
503
|
};
|
|
491
|
-
const i = [],
|
|
492
|
-
for (const
|
|
493
|
-
const
|
|
494
|
-
let
|
|
495
|
-
|
|
504
|
+
const i = [], c = /* @__PURE__ */ new Map();
|
|
505
|
+
for (const p of n) {
|
|
506
|
+
const v = Oe(p);
|
|
507
|
+
let S = c.get(v);
|
|
508
|
+
S === void 0 && (S = i.length, c.set(v, S), i.push({ key: v, records: [] })), i[S].records.push(p);
|
|
496
509
|
}
|
|
497
|
-
const a = [],
|
|
498
|
-
for (const
|
|
499
|
-
const
|
|
500
|
-
|
|
510
|
+
const a = [], u = /* @__PURE__ */ new Map();
|
|
511
|
+
for (const p of i) {
|
|
512
|
+
const v = t(p.records);
|
|
513
|
+
u.set(a.length, { key: p.key, records: v }), a.push(...v);
|
|
501
514
|
}
|
|
502
|
-
return { sortedData: a, sectionDividers:
|
|
503
|
-
}, [n,
|
|
504
|
-
|
|
505
|
-
},
|
|
506
|
-
var a,
|
|
507
|
-
|
|
508
|
-
},
|
|
509
|
-
|
|
510
|
-
if (!
|
|
515
|
+
return { sortedData: a, sectionDividers: u };
|
|
516
|
+
}, [n, E, e, Oe]), ln = (t) => {
|
|
517
|
+
qt((i) => (i == null ? void 0 : i.key) === t ? i.direction === "asc" ? { key: t, direction: "desc" } : null : { key: t, direction: "asc" });
|
|
518
|
+
}, yt = (t, i) => (c) => {
|
|
519
|
+
var a, u, p;
|
|
520
|
+
ln(t.key), (p = (u = (a = t.onHeaderCell) == null ? void 0 : a.call(t, t, i)) == null ? void 0 : u.onClick) == null || p.call(u, c);
|
|
521
|
+
}, je = (t, i) => typeof g == "function" ? g(t) : String(t[g] ?? i), St = typeof g == "function" ? null : g, kt = q(void 0), $e = q(void 0);
|
|
522
|
+
ae(() => {
|
|
523
|
+
if (!Me)
|
|
511
524
|
return;
|
|
512
|
-
|
|
513
|
-
const t =
|
|
514
|
-
i &&
|
|
515
|
-
}, [T,
|
|
516
|
-
const
|
|
517
|
-
if (
|
|
525
|
+
$e.current ?? ($e.current = { ids: /* @__PURE__ */ new WeakMap(), next: 0 });
|
|
526
|
+
const t = In(T, g, $e.current), i = kt.current;
|
|
527
|
+
i && Cn(i, t) || (kt.current = t, Me(T));
|
|
528
|
+
}, [T, St, Me]);
|
|
529
|
+
const le = Math.min(Vt, Math.max(0, T.length - 1)), F = _t(() => {
|
|
530
|
+
if (j == null)
|
|
518
531
|
return -1;
|
|
519
|
-
const t = String(
|
|
520
|
-
return T.findIndex((i,
|
|
521
|
-
}, [
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
}, [
|
|
525
|
-
const
|
|
526
|
-
|
|
527
|
-
if (
|
|
528
|
-
|
|
532
|
+
const t = String(j);
|
|
533
|
+
return T.findIndex((i, c) => je(i, c) === t);
|
|
534
|
+
}, [j, T, St]);
|
|
535
|
+
ae(() => {
|
|
536
|
+
F >= 0 && Ae(F);
|
|
537
|
+
}, [F]);
|
|
538
|
+
const Ye = q(void 0);
|
|
539
|
+
ae(() => {
|
|
540
|
+
if (j == null) {
|
|
541
|
+
Ye.current = void 0;
|
|
529
542
|
return;
|
|
530
543
|
}
|
|
531
|
-
if (!
|
|
544
|
+
if (!at || F < 0)
|
|
532
545
|
return;
|
|
533
|
-
const t =
|
|
534
|
-
if (t && t.key ===
|
|
546
|
+
const t = Ye.current;
|
|
547
|
+
if (t && t.key === j && t.index === F || o || d || Z && !He)
|
|
535
548
|
return;
|
|
536
|
-
const i =
|
|
549
|
+
const i = Fe.current;
|
|
537
550
|
if (!i)
|
|
538
551
|
return;
|
|
539
|
-
const
|
|
540
|
-
`[data-table-id="${
|
|
541
|
-
),
|
|
542
|
-
const
|
|
543
|
-
l.scrollIntoView({ block: "nearest", inline: "nearest" }),
|
|
544
|
-
},
|
|
545
|
-
if (
|
|
546
|
-
|
|
552
|
+
const c = J && Ue === 0, a = (l) => i.querySelector(
|
|
553
|
+
`[data-table-id="${Q}"][data-row-index="${l}"]`
|
|
554
|
+
), u = (l) => {
|
|
555
|
+
const s = de.current, f = ge, H = s == null ? void 0 : s.scrollLeft, N = f == null ? void 0 : f.scrollLeft;
|
|
556
|
+
l.scrollIntoView({ block: "nearest", inline: "nearest" }), s && H !== void 0 && (s.scrollLeft = H), f && N !== void 0 && (f.scrollLeft = N), c || (Ye.current = { key: j, index: F });
|
|
557
|
+
}, p = a(F);
|
|
558
|
+
if (p) {
|
|
559
|
+
u(p);
|
|
547
560
|
return;
|
|
548
561
|
}
|
|
549
|
-
if (!
|
|
562
|
+
if (!Z)
|
|
550
563
|
return;
|
|
551
|
-
const
|
|
552
|
-
(l) =>
|
|
564
|
+
const v = [...ze.current.values()].find(
|
|
565
|
+
(l) => F >= l.startIndex && F < l.startIndex + l.count
|
|
553
566
|
);
|
|
554
|
-
if (!
|
|
567
|
+
if (!v)
|
|
555
568
|
return;
|
|
556
|
-
|
|
557
|
-
let
|
|
558
|
-
const
|
|
559
|
-
const l = a(
|
|
569
|
+
v.scrollToIndex(F - v.startIndex);
|
|
570
|
+
let S = 0, U = 0;
|
|
571
|
+
const M = () => {
|
|
572
|
+
const l = a(F);
|
|
560
573
|
if (l) {
|
|
561
|
-
|
|
574
|
+
u(l);
|
|
562
575
|
return;
|
|
563
576
|
}
|
|
564
|
-
++
|
|
577
|
+
++U < Qn && (S = requestAnimationFrame(M));
|
|
565
578
|
};
|
|
566
|
-
return
|
|
579
|
+
return S = requestAnimationFrame(M), () => cancelAnimationFrame(S);
|
|
567
580
|
}, [
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
581
|
+
j,
|
|
582
|
+
F,
|
|
583
|
+
Z,
|
|
584
|
+
He,
|
|
585
|
+
ge,
|
|
586
|
+
J,
|
|
587
|
+
Ue,
|
|
575
588
|
o,
|
|
576
589
|
d,
|
|
577
|
-
|
|
578
|
-
|
|
590
|
+
Q,
|
|
591
|
+
at
|
|
579
592
|
]);
|
|
580
|
-
const
|
|
581
|
-
|
|
593
|
+
const Je = q(null), $t = (t, i) => {
|
|
594
|
+
Je.current = t, Ae(Math.min(Math.max(0, i), T.length - 1));
|
|
582
595
|
};
|
|
583
|
-
|
|
584
|
-
const t =
|
|
596
|
+
Ft(() => {
|
|
597
|
+
const t = Je.current;
|
|
585
598
|
if (!t)
|
|
586
599
|
return;
|
|
587
|
-
|
|
588
|
-
const i = t.getRootNode(), a = ((
|
|
589
|
-
`[data-table-id="${
|
|
590
|
-
))(
|
|
600
|
+
Je.current = null;
|
|
601
|
+
const i = t.getRootNode(), a = ((v) => i.querySelector(
|
|
602
|
+
`[data-table-id="${Q}"][data-row-index="${v}"]`
|
|
603
|
+
))(le);
|
|
591
604
|
if (a) {
|
|
592
605
|
a.focus();
|
|
593
606
|
return;
|
|
594
607
|
}
|
|
595
|
-
const
|
|
596
|
-
`[data-table-id="${
|
|
597
|
-
),
|
|
598
|
-
|
|
599
|
-
}, [
|
|
600
|
-
const
|
|
601
|
-
const a = { ArrowDown: 1, ArrowUp: -1 }[
|
|
608
|
+
const u = i.querySelectorAll(
|
|
609
|
+
`[data-table-id="${Q}"][data-row-index]`
|
|
610
|
+
), p = le > 0 ? u[u.length - 1] : u[0];
|
|
611
|
+
p && (Ae(Number(p.dataset.rowIndex)), p.focus());
|
|
612
|
+
}, [le, Q]);
|
|
613
|
+
const Nt = (t, i) => (c) => {
|
|
614
|
+
const a = { ArrowDown: 1, ArrowUp: -1 }[c.key];
|
|
602
615
|
if (a !== void 0) {
|
|
603
|
-
|
|
616
|
+
c.preventDefault(), $t(c.currentTarget, t + a);
|
|
604
617
|
return;
|
|
605
618
|
}
|
|
606
|
-
if (!
|
|
607
|
-
|
|
619
|
+
if (!Z && (c.key === "Home" || c.key === "End")) {
|
|
620
|
+
c.preventDefault(), $t(c.currentTarget, c.key === "Home" ? 0 : T.length - 1);
|
|
608
621
|
return;
|
|
609
622
|
}
|
|
610
|
-
i &&
|
|
623
|
+
i && Nn(c, i, "enter");
|
|
611
624
|
};
|
|
612
|
-
|
|
625
|
+
B !== "detached" && Ot({ title: O, subtitle: re, extra: ie }) && xn(
|
|
613
626
|
"table-title-inline",
|
|
614
627
|
'Table `title`, `subtitle` and `extra` draw only on the detached header. Pass `headerVariant="detached"` or leave them out.'
|
|
615
|
-
), P === "detached" && (p || v) && Et(
|
|
616
|
-
`table-name-detached:${p ?? v}`,
|
|
617
|
-
"Table `aria-label` and `aria-labelledby` name only the inline table. The detached layout has no table role to name."
|
|
618
628
|
);
|
|
619
|
-
const
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
),
|
|
623
|
-
|
|
629
|
+
const qe = tr(
|
|
630
|
+
h,
|
|
631
|
+
B === "detached" && (w != null && w.pageSize) ? Math.min(w.pageSize, 10) : 5
|
|
632
|
+
), wt = En(w == null ? void 0 : w.position), Ne = (t) => w && !o && wt[t] ? /* @__PURE__ */ r(
|
|
633
|
+
wn,
|
|
624
634
|
{
|
|
625
635
|
current: w.current ?? 1,
|
|
626
636
|
pageSize: w.pageSize ?? 10,
|
|
@@ -632,225 +642,235 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
632
642
|
onChange: w.onChange,
|
|
633
643
|
onShowSizeChange: w.onShowSizeChange,
|
|
634
644
|
edge: t,
|
|
635
|
-
align:
|
|
645
|
+
align: wt[t]
|
|
636
646
|
}
|
|
637
647
|
) : null;
|
|
638
|
-
if (
|
|
639
|
-
const t =
|
|
640
|
-
...
|
|
641
|
-
...
|
|
642
|
-
}),
|
|
648
|
+
if (B === "detached") {
|
|
649
|
+
const t = Y ? { minWidth: vt } : {}, i = (l, s) => ({
|
|
650
|
+
...Y && l.width === void 0 ? { minWidth: l.minWidth ?? Pt } : {},
|
|
651
|
+
...Hn(ye.offsets.get(l.key), s)
|
|
652
|
+
}), c = (l) => l.key === ye.edgeKey && tn ? /* @__PURE__ */ r(
|
|
643
653
|
"span",
|
|
644
654
|
{
|
|
645
655
|
"aria-hidden": "true",
|
|
646
656
|
className: "shrink-0",
|
|
647
657
|
style: {
|
|
648
658
|
position: "sticky",
|
|
649
|
-
right:
|
|
659
|
+
right: ye.extent,
|
|
650
660
|
zIndex: 1
|
|
651
661
|
},
|
|
652
|
-
children: /* @__PURE__ */ r("span", { style:
|
|
662
|
+
children: /* @__PURE__ */ r("span", { style: An })
|
|
653
663
|
}
|
|
654
|
-
) : null, a =
|
|
655
|
-
border:
|
|
656
|
-
borderRadius:
|
|
664
|
+
) : null, a = `${Q}-caption`, u = Ot({ title: O, subtitle: re, extra: ie }) ? /* @__PURE__ */ r("div", { role: "caption", id: a, className: "w-full", children: /* @__PURE__ */ r(vn, { title: O, subtitle: re, extra: ie }) }) : null, p = J ? et : "var(--malachite-table-background, #f7f7f7)", v = {
|
|
665
|
+
border: kn,
|
|
666
|
+
borderRadius: he,
|
|
657
667
|
overflow: "clip",
|
|
658
668
|
flexShrink: 0,
|
|
659
669
|
...t
|
|
660
|
-
},
|
|
661
|
-
const
|
|
662
|
-
var
|
|
663
|
-
|
|
664
|
-
} : void 0,
|
|
665
|
-
return /* @__PURE__ */
|
|
670
|
+
}, S = (l, s, f = !1, H = !1, N, X = le) => {
|
|
671
|
+
const ee = je(l, s), y = (P == null ? void 0 : P(l, s)) || {}, sn = L == null ? void 0 : L(l, s), we = s === F, Ee = G || y.onClick ? () => {
|
|
672
|
+
var k;
|
|
673
|
+
G == null || G(l, s), (k = y.onClick) == null || k.call(y, l, s);
|
|
674
|
+
} : void 0, oe = !!Ee, dn = f ? {} : Wt;
|
|
675
|
+
return /* @__PURE__ */ $(
|
|
666
676
|
"div",
|
|
667
677
|
{
|
|
668
|
-
ref:
|
|
669
|
-
"data-index":
|
|
670
|
-
"data-table-id":
|
|
671
|
-
"data-row-index":
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
678
|
+
ref: N == null ? void 0 : N.measureRef,
|
|
679
|
+
"data-index": N == null ? void 0 : N.index,
|
|
680
|
+
"data-table-id": Q,
|
|
681
|
+
"data-row-index": s,
|
|
682
|
+
role: "row",
|
|
683
|
+
"aria-labelledby": oe ? me(s) : void 0,
|
|
684
|
+
"aria-current": we ? "true" : void 0,
|
|
685
|
+
tabIndex: oe ? s === X ? 0 : -1 : void 0,
|
|
686
|
+
onKeyDown: oe ? Nt(s, Ee) : void 0,
|
|
675
687
|
className: `
|
|
676
688
|
group bg-[var(--malachite-table-row-background,#fff)] flex items-stretch relative w-full
|
|
677
|
-
${
|
|
678
|
-
${(
|
|
689
|
+
${oe ? `cursor-pointer hover:bg-[var(--malachite-table-row-hover-background,#fafafa)] ${It}` : ""}
|
|
690
|
+
${(W == null ? void 0 : W(l, s)) || ""}
|
|
679
691
|
`,
|
|
680
692
|
style: {
|
|
681
|
-
...
|
|
693
|
+
...dn,
|
|
682
694
|
...t,
|
|
683
|
-
minHeight:
|
|
684
|
-
scrollMarginTop:
|
|
695
|
+
minHeight: We,
|
|
696
|
+
scrollMarginTop: rn,
|
|
685
697
|
// Echo the card's clip, or it cuts the accent bar's end into a stub.
|
|
686
|
-
...
|
|
687
|
-
borderTopLeftRadius:
|
|
688
|
-
borderTopRightRadius:
|
|
698
|
+
...H ? {
|
|
699
|
+
borderTopLeftRadius: he,
|
|
700
|
+
borderTopRightRadius: he
|
|
689
701
|
} : {},
|
|
690
|
-
...
|
|
691
|
-
borderBottomLeftRadius:
|
|
692
|
-
borderBottomRightRadius:
|
|
702
|
+
...f ? {
|
|
703
|
+
borderBottomLeftRadius: he,
|
|
704
|
+
borderBottomRightRadius: he
|
|
693
705
|
} : {},
|
|
694
706
|
// Set unconditionally it would beat `hover:bg-*` on every row.
|
|
695
|
-
...
|
|
696
|
-
...
|
|
707
|
+
...Bn(sn, we),
|
|
708
|
+
...we ? {
|
|
697
709
|
// Inset box-shadow, not `ring-*` — see the classic cell.
|
|
698
|
-
boxShadow: `inset 2px 0 0 ${
|
|
710
|
+
boxShadow: `inset 2px 0 0 ${At}`
|
|
699
711
|
} : {}
|
|
700
712
|
},
|
|
701
|
-
onClick:
|
|
702
|
-
|
|
713
|
+
onClick: Ee ? (k) => {
|
|
714
|
+
Tt(k) || Ee();
|
|
703
715
|
} : void 0,
|
|
704
|
-
onDoubleClick:
|
|
705
|
-
var
|
|
706
|
-
return (
|
|
716
|
+
onDoubleClick: y.onDoubleClick ? () => {
|
|
717
|
+
var k;
|
|
718
|
+
return (k = y.onDoubleClick) == null ? void 0 : k.call(y, l, s);
|
|
707
719
|
} : void 0,
|
|
708
|
-
onContextMenu:
|
|
709
|
-
var
|
|
710
|
-
return (
|
|
720
|
+
onContextMenu: y.onContextMenu ? () => {
|
|
721
|
+
var k;
|
|
722
|
+
return (k = y.onContextMenu) == null ? void 0 : k.call(y, l, s);
|
|
711
723
|
} : void 0,
|
|
712
|
-
onMouseEnter:
|
|
713
|
-
var
|
|
714
|
-
return (
|
|
724
|
+
onMouseEnter: y.onMouseEnter ? () => {
|
|
725
|
+
var k;
|
|
726
|
+
return (k = y.onMouseEnter) == null ? void 0 : k.call(y, l, s);
|
|
715
727
|
} : void 0,
|
|
716
|
-
onMouseLeave:
|
|
717
|
-
var
|
|
718
|
-
return (
|
|
728
|
+
onMouseLeave: y.onMouseLeave ? () => {
|
|
729
|
+
var k;
|
|
730
|
+
return (k = y.onMouseLeave) == null ? void 0 : k.call(y, l, s);
|
|
719
731
|
} : void 0,
|
|
720
732
|
children: [
|
|
721
|
-
e.map((
|
|
722
|
-
|
|
733
|
+
e.map((k) => /* @__PURE__ */ $(Re.Fragment, { children: [
|
|
734
|
+
c(k),
|
|
723
735
|
/* @__PURE__ */ r(
|
|
724
|
-
|
|
736
|
+
ar,
|
|
725
737
|
{
|
|
726
|
-
column:
|
|
727
|
-
record:
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
738
|
+
column: k,
|
|
739
|
+
record: l,
|
|
740
|
+
id: oe && k.key === ht ? me(s) : void 0,
|
|
741
|
+
paddingClass: se,
|
|
742
|
+
index: s,
|
|
743
|
+
size: V,
|
|
744
|
+
isSelected: we,
|
|
745
|
+
cellStyle: i(k, "row")
|
|
733
746
|
}
|
|
734
747
|
)
|
|
735
|
-
] },
|
|
736
|
-
|
|
748
|
+
] }, k.key)),
|
|
749
|
+
oe && Se ? /* @__PURE__ */ r("span", { "aria-hidden": "true", className: yn }) : null
|
|
737
750
|
]
|
|
738
751
|
},
|
|
739
|
-
|
|
752
|
+
ee
|
|
740
753
|
);
|
|
741
|
-
},
|
|
754
|
+
}, U = (l, s = !1) => /* @__PURE__ */ r(
|
|
742
755
|
"div",
|
|
743
756
|
{
|
|
757
|
+
"aria-hidden": "true",
|
|
744
758
|
className: "bg-[var(--malachite-table-row-background,#fff)] flex items-stretch w-full",
|
|
745
759
|
style: {
|
|
746
|
-
...
|
|
760
|
+
...s ? {} : Wt,
|
|
747
761
|
...t,
|
|
748
|
-
minHeight:
|
|
762
|
+
minHeight: We
|
|
749
763
|
},
|
|
750
|
-
children: e.map((
|
|
751
|
-
const
|
|
764
|
+
children: e.map((f) => {
|
|
765
|
+
const X = (f.title === "" || f.title == null) && f.width !== void 0 ? /* @__PURE__ */ r(
|
|
752
766
|
"div",
|
|
753
767
|
{
|
|
754
|
-
className: `flex items-center ${
|
|
768
|
+
className: `flex items-center ${Gt(f.align)} shrink-0 overflow-clip ${se}`,
|
|
755
769
|
style: {
|
|
756
|
-
...
|
|
757
|
-
...i(
|
|
770
|
+
...ot(f),
|
|
771
|
+
...i(f, "row")
|
|
758
772
|
},
|
|
759
773
|
children: /* @__PURE__ */ r("div", { className: "table-skeleton-bar h-3 rounded animate-pulse w-2/5" })
|
|
760
774
|
}
|
|
761
775
|
) : /* @__PURE__ */ r(
|
|
762
776
|
"div",
|
|
763
777
|
{
|
|
764
|
-
className: `flex flex-[1_0_0] items-center ${
|
|
778
|
+
className: `flex flex-[1_0_0] items-center ${te(f.align)} min-w-0 overflow-clip ${se}`,
|
|
765
779
|
style: {
|
|
766
|
-
...
|
|
767
|
-
...i(
|
|
780
|
+
...pe(f),
|
|
781
|
+
...i(f, "row")
|
|
768
782
|
},
|
|
769
783
|
children: /* @__PURE__ */ r("div", { className: "table-skeleton-bar h-3 rounded animate-pulse w-3/5" })
|
|
770
784
|
}
|
|
771
785
|
);
|
|
772
|
-
return /* @__PURE__ */
|
|
773
|
-
f
|
|
774
|
-
|
|
775
|
-
] },
|
|
786
|
+
return /* @__PURE__ */ $(Re.Fragment, { children: [
|
|
787
|
+
c(f),
|
|
788
|
+
X
|
|
789
|
+
] }, f.key);
|
|
776
790
|
})
|
|
777
791
|
},
|
|
778
|
-
`skeleton-${
|
|
779
|
-
),
|
|
792
|
+
`skeleton-${l}`
|
|
793
|
+
), M = I ? /* @__PURE__ */ r(
|
|
780
794
|
"div",
|
|
781
795
|
{
|
|
796
|
+
role: "row",
|
|
782
797
|
className: "flex items-stretch w-full",
|
|
783
|
-
style: { ...t, minHeight:
|
|
784
|
-
children: e.map((
|
|
785
|
-
|
|
798
|
+
style: { ...t, minHeight: Un[A] },
|
|
799
|
+
children: e.map((l, s) => /* @__PURE__ */ $(Re.Fragment, { children: [
|
|
800
|
+
c(l),
|
|
786
801
|
/* @__PURE__ */ r(
|
|
787
|
-
|
|
802
|
+
or,
|
|
788
803
|
{
|
|
789
|
-
column:
|
|
790
|
-
paddingClass:
|
|
791
|
-
sortDirection: (
|
|
792
|
-
onSort:
|
|
793
|
-
cellStyle: i(
|
|
804
|
+
column: l,
|
|
805
|
+
paddingClass: De,
|
|
806
|
+
sortDirection: (E == null ? void 0 : E.key) === l.key ? E.direction : null,
|
|
807
|
+
onSort: l.sorter ? yt(l, s) : void 0,
|
|
808
|
+
cellStyle: i(l, p)
|
|
794
809
|
}
|
|
795
810
|
)
|
|
796
|
-
] },
|
|
811
|
+
] }, l.key))
|
|
797
812
|
}
|
|
798
813
|
) : null;
|
|
799
|
-
return /* @__PURE__ */
|
|
814
|
+
return /* @__PURE__ */ $(
|
|
800
815
|
"div",
|
|
801
816
|
{
|
|
802
|
-
ref:
|
|
803
|
-
className: `w-full ${
|
|
804
|
-
style: { ...
|
|
817
|
+
ref: Fe,
|
|
818
|
+
className: `w-full ${dt}`,
|
|
819
|
+
style: { ...Ke, ..._e },
|
|
805
820
|
children: [
|
|
806
|
-
|
|
807
|
-
/* @__PURE__ */
|
|
821
|
+
Ne("top"),
|
|
822
|
+
/* @__PURE__ */ $(
|
|
808
823
|
"div",
|
|
809
824
|
{
|
|
810
|
-
|
|
825
|
+
role: "table",
|
|
826
|
+
"aria-label": b,
|
|
827
|
+
"aria-labelledby": x ?? (b || !u ? void 0 : a),
|
|
828
|
+
"aria-busy": o || void 0,
|
|
829
|
+
className: `${Sn} flex flex-col items-start ${J ? "" : "overflow-clip"} relative w-full`,
|
|
811
830
|
children: [
|
|
812
|
-
!
|
|
813
|
-
|
|
831
|
+
!I && u,
|
|
832
|
+
I && /* @__PURE__ */ $(
|
|
814
833
|
"div",
|
|
815
834
|
{
|
|
816
|
-
ref:
|
|
835
|
+
ref: ft,
|
|
817
836
|
style: {
|
|
818
|
-
...
|
|
837
|
+
...J ? {
|
|
819
838
|
position: "sticky",
|
|
820
|
-
top:
|
|
839
|
+
top: Ie,
|
|
821
840
|
zIndex: 8,
|
|
822
841
|
// A title row sits on the frame, as a framed Card's
|
|
823
842
|
// does; the header colour goes behind the column
|
|
824
843
|
// headers alone.
|
|
825
|
-
backgroundColor:
|
|
826
|
-
marginInline: -
|
|
827
|
-
width: `calc(100% + ${
|
|
828
|
-
paddingInline:
|
|
844
|
+
backgroundColor: u ? "var(--malachite-table-background, #f7f7f7)" : et,
|
|
845
|
+
marginInline: -fe,
|
|
846
|
+
width: `calc(100% + ${fe * 2}px)`,
|
|
847
|
+
paddingInline: fe,
|
|
829
848
|
// Vertically too, or the card's top frame sits above
|
|
830
849
|
// the docked header and rows scroll through it.
|
|
831
|
-
marginTop: -
|
|
832
|
-
paddingTop:
|
|
850
|
+
marginTop: -fe,
|
|
851
|
+
paddingTop: fe
|
|
833
852
|
} : { width: "100%" }
|
|
834
853
|
},
|
|
835
854
|
children: [
|
|
836
|
-
|
|
837
|
-
|
|
855
|
+
J && /* @__PURE__ */ r(Zn, {}),
|
|
856
|
+
u,
|
|
838
857
|
/* @__PURE__ */ r(
|
|
839
858
|
"div",
|
|
840
859
|
{
|
|
841
|
-
ref:
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
860
|
+
ref: Le,
|
|
861
|
+
role: "rowgroup",
|
|
862
|
+
onScroll: Y ? () => Lt(
|
|
863
|
+
Le.current,
|
|
864
|
+
de.current
|
|
845
865
|
) : void 0,
|
|
846
866
|
style: {
|
|
847
|
-
...
|
|
848
|
-
...
|
|
849
|
-
paddingRight:
|
|
867
|
+
...Y ? {
|
|
868
|
+
...Ln,
|
|
869
|
+
paddingRight: nn
|
|
850
870
|
} : {},
|
|
851
|
-
...
|
|
871
|
+
...J && u ? { backgroundColor: et } : {}
|
|
852
872
|
},
|
|
853
|
-
children:
|
|
873
|
+
children: M
|
|
854
874
|
}
|
|
855
875
|
)
|
|
856
876
|
]
|
|
@@ -859,82 +879,114 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
859
879
|
/* @__PURE__ */ r(
|
|
860
880
|
"div",
|
|
861
881
|
{
|
|
862
|
-
ref:
|
|
863
|
-
|
|
864
|
-
|
|
882
|
+
ref: Xt,
|
|
883
|
+
role: "rowgroup",
|
|
884
|
+
onScroll: Y ? () => {
|
|
885
|
+
Lt(de.current, Le.current), Se && ke();
|
|
865
886
|
} : void 0,
|
|
866
|
-
className: `flex flex-col items-start ${
|
|
887
|
+
className: `flex flex-col items-start ${Y ? "overflow-x-auto" : "overflow-x-clip"} ${Pe ? "overflow-y-auto" : "overflow-y-visible"} w-full`,
|
|
867
888
|
style: {
|
|
868
889
|
// Firefox + modern Chromium only; older Webkit keeps its default.
|
|
869
890
|
scrollbarWidth: "thin",
|
|
870
891
|
scrollbarColor: "var(--malachite-text-placeholder, rgb(187, 187, 187)) transparent",
|
|
871
892
|
// With an external virtual scroller the body is overflow-visible and
|
|
872
893
|
// a bounded box would overlap content below it.
|
|
873
|
-
...
|
|
874
|
-
maxHeight:
|
|
894
|
+
...D && Pe ? {
|
|
895
|
+
maxHeight: xe ? Be : Xn(D, !!w)
|
|
875
896
|
} : {}
|
|
876
897
|
},
|
|
877
|
-
children: d ? /* @__PURE__ */ r("div", { className: "flex flex-col w-full", style:
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
898
|
+
children: d ? /* @__PURE__ */ r("div", { className: "flex flex-col w-full", style: v, children: /* @__PURE__ */ r(
|
|
899
|
+
"div",
|
|
900
|
+
{
|
|
901
|
+
role: "row",
|
|
902
|
+
className: "flex flex-col items-center justify-center bg-[var(--malachite-table-row-background,#fff)] w-full px-4 py-12 text-center",
|
|
903
|
+
children: /* @__PURE__ */ $(
|
|
904
|
+
"div",
|
|
905
|
+
{
|
|
906
|
+
role: "cell",
|
|
907
|
+
"aria-colspan": e.length,
|
|
908
|
+
className: "flex flex-col items-center",
|
|
909
|
+
children: [
|
|
910
|
+
/* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[14px] font-medium mb-1", children: R }),
|
|
911
|
+
/* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[13px]", children: m })
|
|
912
|
+
]
|
|
913
|
+
}
|
|
914
|
+
)
|
|
915
|
+
}
|
|
916
|
+
) }) : o ? /* @__PURE__ */ r("div", { className: "flex flex-col w-full", style: v, children: Array.from({ length: qe }).map(
|
|
917
|
+
(l, s) => U(s, s === qe - 1)
|
|
918
|
+
) }) : T.length === 0 ? /* @__PURE__ */ r("div", { className: "flex flex-col w-full", style: v, children: /* @__PURE__ */ r(
|
|
919
|
+
"div",
|
|
920
|
+
{
|
|
921
|
+
role: "row",
|
|
922
|
+
className: "flex flex-col items-center justify-center bg-[var(--malachite-table-row-background,#fff)] w-full px-4 py-12 text-center",
|
|
923
|
+
children: /* @__PURE__ */ $(
|
|
924
|
+
"div",
|
|
925
|
+
{
|
|
926
|
+
role: "cell",
|
|
927
|
+
"aria-colspan": e.length,
|
|
928
|
+
className: "flex flex-col items-center",
|
|
929
|
+
children: [
|
|
930
|
+
/* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[14px] font-medium", children: C }),
|
|
931
|
+
z && /* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[13px] mt-1", children: z })
|
|
932
|
+
]
|
|
933
|
+
}
|
|
934
|
+
)
|
|
935
|
+
}
|
|
936
|
+
) }) : (() => {
|
|
937
|
+
const l = (f, H, N) => Z ? /* @__PURE__ */ r(
|
|
938
|
+
Kn,
|
|
888
939
|
{
|
|
889
|
-
cardKey:
|
|
890
|
-
records:
|
|
891
|
-
startIndex:
|
|
892
|
-
scrollElement:
|
|
893
|
-
estimateRowHeight:
|
|
894
|
-
style:
|
|
895
|
-
renderRow:
|
|
896
|
-
registerHandle:
|
|
897
|
-
rovingIndex:
|
|
940
|
+
cardKey: N,
|
|
941
|
+
records: f,
|
|
942
|
+
startIndex: H,
|
|
943
|
+
scrollElement: He,
|
|
944
|
+
estimateRowHeight: Zt,
|
|
945
|
+
style: v,
|
|
946
|
+
renderRow: S,
|
|
947
|
+
registerHandle: Qt,
|
|
948
|
+
rovingIndex: le
|
|
898
949
|
},
|
|
899
|
-
`section-card-${
|
|
950
|
+
`section-card-${N}`
|
|
900
951
|
) : /* @__PURE__ */ r(
|
|
901
952
|
"div",
|
|
902
953
|
{
|
|
903
954
|
className: "flex flex-col w-full",
|
|
904
|
-
style:
|
|
905
|
-
children:
|
|
906
|
-
(
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
955
|
+
style: v,
|
|
956
|
+
children: f.map(
|
|
957
|
+
(X, ee) => S(
|
|
958
|
+
X,
|
|
959
|
+
H + ee,
|
|
960
|
+
ee === f.length - 1,
|
|
961
|
+
ee === 0
|
|
911
962
|
)
|
|
912
963
|
)
|
|
913
964
|
},
|
|
914
|
-
`section-card-${
|
|
965
|
+
`section-card-${N}`
|
|
915
966
|
);
|
|
916
|
-
if (
|
|
917
|
-
return
|
|
918
|
-
const
|
|
919
|
-
return
|
|
920
|
-
const
|
|
921
|
-
if (!
|
|
967
|
+
if (Ge.size === 0)
|
|
968
|
+
return l(T, 0, "all");
|
|
969
|
+
const s = [...Ge.keys()].sort((f, H) => f - H);
|
|
970
|
+
return s.map((f, H) => {
|
|
971
|
+
const N = Ge.get(f);
|
|
972
|
+
if (!N)
|
|
922
973
|
return null;
|
|
923
|
-
const
|
|
924
|
-
|
|
925
|
-
|
|
974
|
+
const X = H + 1 < s.length ? s[H + 1] : T.length, ee = T.slice(f, X), y = Te == null ? void 0 : Te(
|
|
975
|
+
N.key,
|
|
976
|
+
N.records
|
|
926
977
|
);
|
|
927
|
-
return /* @__PURE__ */
|
|
928
|
-
|
|
978
|
+
return /* @__PURE__ */ $(Re.Fragment, { children: [
|
|
979
|
+
y != null ? /* @__PURE__ */ r(
|
|
929
980
|
"div",
|
|
930
981
|
{
|
|
982
|
+
role: "row",
|
|
931
983
|
className: "table-section-divider",
|
|
932
|
-
style:
|
|
933
|
-
children:
|
|
984
|
+
style: Y ? Fn : void 0,
|
|
985
|
+
children: /* @__PURE__ */ r("div", { role: "cell", "aria-colspan": e.length, children: y })
|
|
934
986
|
}
|
|
935
987
|
) : null,
|
|
936
|
-
|
|
937
|
-
] }, `section-${
|
|
988
|
+
l(ee, f, N.key)
|
|
989
|
+
] }, `section-${N.key}`);
|
|
938
990
|
});
|
|
939
991
|
})()
|
|
940
992
|
}
|
|
@@ -942,28 +994,28 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
942
994
|
]
|
|
943
995
|
}
|
|
944
996
|
),
|
|
945
|
-
|
|
997
|
+
Ne("bottom")
|
|
946
998
|
]
|
|
947
999
|
}
|
|
948
1000
|
);
|
|
949
1001
|
}
|
|
950
|
-
const
|
|
951
|
-
const
|
|
1002
|
+
const Qe = ne === "fixed" || e.some((t) => t.width), Et = Y && (o || T.length > 0), on = Et && Qe ? Mn(e) : void 0, Ve = (t) => Et && !Qe ? t.minWidth : void 0, an = (t, i) => {
|
|
1003
|
+
const c = t.sorter, u = (E == null ? void 0 : E.key) === t.key ? E == null ? void 0 : E.direction : null, p = /* @__PURE__ */ $("div", { className: `flex min-w-0 items-center gap-2 ${te(t.align)}`, children: [
|
|
952
1004
|
/* @__PURE__ */ r("span", { className: t.titleShrinks ? "min-w-0" : void 0, children: t.title }),
|
|
953
|
-
t.info && /* @__PURE__ */ r(
|
|
954
|
-
|
|
1005
|
+
t.info && /* @__PURE__ */ r(Ce, { info: t.info }),
|
|
1006
|
+
c && /* @__PURE__ */ $("div", { className: "flex flex-col", children: [
|
|
955
1007
|
/* @__PURE__ */ r(
|
|
956
|
-
|
|
1008
|
+
hn,
|
|
957
1009
|
{
|
|
958
1010
|
size: 12,
|
|
959
|
-
className:
|
|
1011
|
+
className: u === "asc" ? nt : rt
|
|
960
1012
|
}
|
|
961
1013
|
),
|
|
962
1014
|
/* @__PURE__ */ r(
|
|
963
|
-
|
|
1015
|
+
zt,
|
|
964
1016
|
{
|
|
965
1017
|
size: 12,
|
|
966
|
-
className: `-mt-1 ${
|
|
1018
|
+
className: `-mt-1 ${u === "desc" ? nt : rt}`
|
|
967
1019
|
}
|
|
968
1020
|
)
|
|
969
1021
|
] })
|
|
@@ -972,58 +1024,58 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
972
1024
|
"th",
|
|
973
1025
|
{
|
|
974
1026
|
className: `
|
|
975
|
-
table-header table-cell ${
|
|
976
|
-
${
|
|
977
|
-
${
|
|
1027
|
+
table-header table-cell ${De} font-semibold border-0 first:rounded-tl-lg last:rounded-tr-lg
|
|
1028
|
+
${ue(V)}
|
|
1029
|
+
${ve(t.align)}
|
|
978
1030
|
`,
|
|
979
|
-
style: { width: t.width, minWidth:
|
|
980
|
-
"aria-sort":
|
|
981
|
-
children:
|
|
1031
|
+
style: { width: t.width, minWidth: Ve(t) },
|
|
1032
|
+
"aria-sort": c ? Ut(u) : void 0,
|
|
1033
|
+
children: c ? /* @__PURE__ */ r(
|
|
982
1034
|
"button",
|
|
983
1035
|
{
|
|
984
|
-
...
|
|
985
|
-
className: `flex w-full items-center ${
|
|
986
|
-
children:
|
|
1036
|
+
...jt(t.title, yt(t, i)),
|
|
1037
|
+
className: `flex w-full items-center ${te(t.align)} cursor-pointer hover:opacity-80 appearance-none bg-transparent border-0 p-0 font-semibold text-inherit ${ve(t.align)}`,
|
|
1038
|
+
children: p
|
|
987
1039
|
}
|
|
988
|
-
) :
|
|
1040
|
+
) : p
|
|
989
1041
|
},
|
|
990
1042
|
t.key
|
|
991
1043
|
);
|
|
992
1044
|
};
|
|
993
|
-
return d ? /* @__PURE__ */ r("div", { className: "w-full", style: { ...
|
|
1045
|
+
return d ? /* @__PURE__ */ r("div", { className: "w-full", style: { ...Ke, ..._e }, children: /* @__PURE__ */ r(
|
|
994
1046
|
"div",
|
|
995
1047
|
{
|
|
996
|
-
ref:
|
|
1048
|
+
ref: ut,
|
|
997
1049
|
className: "overflow-x-auto",
|
|
998
1050
|
style: {
|
|
999
|
-
...
|
|
1051
|
+
...D ? { maxHeight: xe ? Be : D } : {}
|
|
1000
1052
|
},
|
|
1001
|
-
children: /* @__PURE__ */
|
|
1053
|
+
children: /* @__PURE__ */ $(
|
|
1002
1054
|
"table",
|
|
1003
1055
|
{
|
|
1004
|
-
"aria-label":
|
|
1005
|
-
"aria-labelledby":
|
|
1056
|
+
"aria-label": b,
|
|
1057
|
+
"aria-labelledby": x,
|
|
1006
1058
|
className: "w-full border-collapse rounded-lg overflow-hidden",
|
|
1007
1059
|
children: [
|
|
1008
|
-
|
|
1060
|
+
I && /* @__PURE__ */ r("thead", { children: /* @__PURE__ */ r("tr", { children: e.map((t) => /* @__PURE__ */ r(
|
|
1009
1061
|
"th",
|
|
1010
1062
|
{
|
|
1011
1063
|
className: `
|
|
1012
|
-
table-header table-cell ${
|
|
1013
|
-
${
|
|
1014
|
-
${
|
|
1015
|
-
${
|
|
1016
|
-
${
|
|
1017
|
-
${
|
|
1064
|
+
table-header table-cell ${De} font-semibold border-0 first:rounded-tl-lg last:rounded-tr-lg
|
|
1065
|
+
${_ ? "table-cell-bordered table-cell-bordered-top" : ""}
|
|
1066
|
+
${_ && t === e[0] ? "table-cell-bordered-left" : ""}
|
|
1067
|
+
${_ && t === e[e.length - 1] ? "table-cell-bordered-right" : ""}
|
|
1068
|
+
${ue(V)}
|
|
1069
|
+
${ve(t.align)}
|
|
1018
1070
|
`,
|
|
1019
1071
|
style: { width: t.width },
|
|
1020
|
-
children: /* @__PURE__ */
|
|
1072
|
+
children: /* @__PURE__ */ $(
|
|
1021
1073
|
"div",
|
|
1022
1074
|
{
|
|
1023
|
-
className: `flex items-center gap-2 ${
|
|
1075
|
+
className: `flex items-center gap-2 ${te(t.align)}`,
|
|
1024
1076
|
children: [
|
|
1025
1077
|
/* @__PURE__ */ r("span", { children: t.title }),
|
|
1026
|
-
t.info && /* @__PURE__ */ r(
|
|
1078
|
+
t.info && /* @__PURE__ */ r(Ce, { info: t.info })
|
|
1027
1079
|
]
|
|
1028
1080
|
}
|
|
1029
1081
|
)
|
|
@@ -1033,12 +1085,12 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
1033
1085
|
/* @__PURE__ */ r("tbody", { children: /* @__PURE__ */ r("tr", { children: /* @__PURE__ */ r(
|
|
1034
1086
|
"td",
|
|
1035
1087
|
{
|
|
1036
|
-
colSpan: e.length + (
|
|
1088
|
+
colSpan: e.length + (st ? 1 : 0),
|
|
1037
1089
|
className: "px-4 py-12 text-center",
|
|
1038
|
-
children: /* @__PURE__ */
|
|
1039
|
-
/* @__PURE__ */ r("div", { className: "table-error-icon w-12 h-12 rounded-full flex items-center justify-center mb-4", children: /* @__PURE__ */ r(
|
|
1040
|
-
/* @__PURE__ */ r("div", { className: "table-error-title text-lg font-semibold mb-2", children:
|
|
1041
|
-
/* @__PURE__ */ r("div", { className: "table-error-subtitle text-sm", children:
|
|
1090
|
+
children: /* @__PURE__ */ $("div", { className: "flex flex-col items-center justify-center", children: [
|
|
1091
|
+
/* @__PURE__ */ r("div", { className: "table-error-icon w-12 h-12 rounded-full flex items-center justify-center mb-4", children: /* @__PURE__ */ r(pn, { size: 24 }) }),
|
|
1092
|
+
/* @__PURE__ */ r("div", { className: "table-error-title text-lg font-semibold mb-2", children: R }),
|
|
1093
|
+
/* @__PURE__ */ r("div", { className: "table-error-subtitle text-sm", children: m })
|
|
1042
1094
|
] })
|
|
1043
1095
|
}
|
|
1044
1096
|
) }) })
|
|
@@ -1046,73 +1098,73 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
1046
1098
|
}
|
|
1047
1099
|
)
|
|
1048
1100
|
}
|
|
1049
|
-
) }) : /* @__PURE__ */
|
|
1101
|
+
) }) : /* @__PURE__ */ $(
|
|
1050
1102
|
"div",
|
|
1051
1103
|
{
|
|
1052
|
-
ref:
|
|
1053
|
-
className: `w-full ${
|
|
1054
|
-
style: { ...
|
|
1104
|
+
ref: Fe,
|
|
1105
|
+
className: `w-full ${dt}`,
|
|
1106
|
+
style: { ...Ke, ..._e },
|
|
1055
1107
|
children: [
|
|
1056
|
-
|
|
1108
|
+
Ne("top"),
|
|
1057
1109
|
/* @__PURE__ */ r(
|
|
1058
1110
|
"div",
|
|
1059
1111
|
{
|
|
1060
|
-
className: `overflow-hidden rounded-lg ${
|
|
1061
|
-
"data-bordered":
|
|
1112
|
+
className: `overflow-hidden rounded-lg ${_ ? "table-bordered-container" : "table-container-border"}`,
|
|
1113
|
+
"data-bordered": _ ? "true" : "false",
|
|
1062
1114
|
children: /* @__PURE__ */ r(
|
|
1063
1115
|
"div",
|
|
1064
1116
|
{
|
|
1065
|
-
ref:
|
|
1117
|
+
ref: ut,
|
|
1066
1118
|
className: "overflow-x-auto",
|
|
1067
1119
|
style: {
|
|
1068
|
-
...
|
|
1120
|
+
...D ? { maxHeight: xe ? Be : D } : {}
|
|
1069
1121
|
},
|
|
1070
|
-
children: /* @__PURE__ */
|
|
1122
|
+
children: /* @__PURE__ */ $(
|
|
1071
1123
|
"table",
|
|
1072
1124
|
{
|
|
1073
|
-
"aria-label":
|
|
1074
|
-
"aria-labelledby":
|
|
1125
|
+
"aria-label": b,
|
|
1126
|
+
"aria-labelledby": x,
|
|
1075
1127
|
"aria-busy": o || void 0,
|
|
1076
|
-
className: `w-full ${
|
|
1128
|
+
className: `w-full ${Qe ? "table-fixed" : "table-auto"} ${_ ? "border-separate table-bordered" : "border-collapse"} rounded-lg overflow-hidden`,
|
|
1077
1129
|
style: {
|
|
1078
1130
|
borderSpacing: "0",
|
|
1079
|
-
minWidth:
|
|
1131
|
+
minWidth: on
|
|
1080
1132
|
},
|
|
1081
1133
|
children: [
|
|
1082
|
-
|
|
1083
|
-
/* @__PURE__ */ r("tbody", { children: o ? Array.from({ length:
|
|
1134
|
+
I && /* @__PURE__ */ r("thead", { children: /* @__PURE__ */ r("tr", { children: e.map((t, i) => an(t, i)) }) }),
|
|
1135
|
+
/* @__PURE__ */ r("tbody", { children: o ? Array.from({ length: qe }).map((t, i) => /* @__PURE__ */ r(
|
|
1084
1136
|
"tr",
|
|
1085
1137
|
{
|
|
1086
|
-
className: `table-row ${
|
|
1087
|
-
children: e.map((
|
|
1138
|
+
className: `table-row ${_ ? "table-row-bordered" : ""}`,
|
|
1139
|
+
children: e.map((c) => /* @__PURE__ */ r(
|
|
1088
1140
|
"td",
|
|
1089
1141
|
{
|
|
1090
|
-
className: `table-cell ${
|
|
1142
|
+
className: `table-cell ${se} text-left ${ue(V)}`,
|
|
1091
1143
|
style: {
|
|
1092
|
-
width:
|
|
1093
|
-
minWidth:
|
|
1094
|
-
height:
|
|
1144
|
+
width: c.width,
|
|
1145
|
+
minWidth: Ve(c),
|
|
1146
|
+
height: ct
|
|
1095
1147
|
},
|
|
1096
1148
|
children: /* @__PURE__ */ r("div", { className: "table-skeleton-bar h-4 rounded animate-pulse" })
|
|
1097
1149
|
},
|
|
1098
|
-
|
|
1150
|
+
c.key
|
|
1099
1151
|
))
|
|
1100
1152
|
},
|
|
1101
1153
|
i
|
|
1102
1154
|
)) : T.length === 0 ? /* @__PURE__ */ r("tr", { children: /* @__PURE__ */ r(
|
|
1103
1155
|
"td",
|
|
1104
1156
|
{
|
|
1105
|
-
colSpan: e.length + (
|
|
1157
|
+
colSpan: e.length + (st ? 1 : 0),
|
|
1106
1158
|
className: "px-4 py-12 text-center",
|
|
1107
|
-
children: /* @__PURE__ */
|
|
1108
|
-
/* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[14px] font-medium", children:
|
|
1109
|
-
|
|
1159
|
+
children: /* @__PURE__ */ $("div", { className: "flex flex-col items-center justify-center", children: [
|
|
1160
|
+
/* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[14px] font-medium", children: C }),
|
|
1161
|
+
z && /* @__PURE__ */ r("div", { className: "text-[var(--malachite-text-secondary)] text-[13px] mt-1", children: z })
|
|
1110
1162
|
] })
|
|
1111
1163
|
}
|
|
1112
1164
|
) }) : T.map((t, i) => {
|
|
1113
|
-
const
|
|
1165
|
+
const c = je(t, i), a = (P == null ? void 0 : P(t, i)) || {}, u = L == null ? void 0 : L(t, i), p = i === 0, v = i === n.length - 1, S = i === F, U = u ? `var(--malachite-table-row-variant-${u}-background)` : void 0, M = G || a.onClick ? () => {
|
|
1114
1166
|
var l;
|
|
1115
|
-
|
|
1167
|
+
G == null || G(t, i), (l = a.onClick) == null || l.call(a, t, i);
|
|
1116
1168
|
} : void 0;
|
|
1117
1169
|
return (
|
|
1118
1170
|
// Keeps `row` semantics: `role="button"` would strip the table
|
|
@@ -1120,18 +1172,19 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
1120
1172
|
/* @__PURE__ */ r(
|
|
1121
1173
|
"tr",
|
|
1122
1174
|
{
|
|
1123
|
-
"data-table-id":
|
|
1175
|
+
"data-table-id": Q,
|
|
1124
1176
|
"data-row-index": i,
|
|
1125
|
-
"aria-current":
|
|
1126
|
-
|
|
1127
|
-
|
|
1177
|
+
"aria-current": S ? "true" : void 0,
|
|
1178
|
+
"aria-labelledby": M ? me(i) : void 0,
|
|
1179
|
+
tabIndex: M ? i === le ? 0 : -1 : void 0,
|
|
1180
|
+
onKeyDown: M ? Nt(i, M) : void 0,
|
|
1128
1181
|
className: `
|
|
1129
|
-
${
|
|
1130
|
-
${(
|
|
1131
|
-
${
|
|
1182
|
+
${_ ? "table-row-bordered" : `table-row ${S ? "" : "hover:opacity-80"}`}
|
|
1183
|
+
${(W == null ? void 0 : W(t, i)) || ""}
|
|
1184
|
+
${M ? `cursor-pointer ${It}` : ""}
|
|
1132
1185
|
`,
|
|
1133
|
-
onClick:
|
|
1134
|
-
|
|
1186
|
+
onClick: M ? (l) => {
|
|
1187
|
+
Tt(l) || M();
|
|
1135
1188
|
} : void 0,
|
|
1136
1189
|
onDoubleClick: a.onDoubleClick ? () => {
|
|
1137
1190
|
var l;
|
|
@@ -1150,31 +1203,32 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
1150
1203
|
return (l = a.onMouseLeave) == null ? void 0 : l.call(a, t, i);
|
|
1151
1204
|
} : void 0,
|
|
1152
1205
|
children: e.map((l) => {
|
|
1153
|
-
const
|
|
1206
|
+
const s = l === e[0], f = l === e[e.length - 1];
|
|
1154
1207
|
return /* @__PURE__ */ r(
|
|
1155
|
-
|
|
1208
|
+
lr,
|
|
1156
1209
|
{
|
|
1157
1210
|
column: l,
|
|
1158
1211
|
record: t,
|
|
1159
1212
|
index: i,
|
|
1160
|
-
size:
|
|
1161
|
-
paddingClass:
|
|
1162
|
-
height:
|
|
1163
|
-
bordered:
|
|
1164
|
-
isFirstRow:
|
|
1165
|
-
isLastRow:
|
|
1166
|
-
isFirstColumn:
|
|
1167
|
-
isLastColumn:
|
|
1168
|
-
variantBackground:
|
|
1169
|
-
isSelected:
|
|
1170
|
-
showSelectedAccent:
|
|
1171
|
-
minWidth:
|
|
1213
|
+
size: V,
|
|
1214
|
+
paddingClass: se,
|
|
1215
|
+
height: ct,
|
|
1216
|
+
bordered: _,
|
|
1217
|
+
isFirstRow: p,
|
|
1218
|
+
isLastRow: v,
|
|
1219
|
+
isFirstColumn: s,
|
|
1220
|
+
isLastColumn: f,
|
|
1221
|
+
variantBackground: U,
|
|
1222
|
+
isSelected: S,
|
|
1223
|
+
showSelectedAccent: S && s,
|
|
1224
|
+
minWidth: Ve(l),
|
|
1225
|
+
id: M && l.key === ht ? me(i) : void 0
|
|
1172
1226
|
},
|
|
1173
1227
|
l.key
|
|
1174
1228
|
);
|
|
1175
1229
|
})
|
|
1176
1230
|
},
|
|
1177
|
-
|
|
1231
|
+
c
|
|
1178
1232
|
)
|
|
1179
1233
|
);
|
|
1180
1234
|
}) })
|
|
@@ -1185,12 +1239,12 @@ const zt = 160, kn = (e, n) => e.length === n.length && e.every((o, u) => o ===
|
|
|
1185
1239
|
)
|
|
1186
1240
|
}
|
|
1187
1241
|
),
|
|
1188
|
-
|
|
1242
|
+
Ne("bottom")
|
|
1189
1243
|
]
|
|
1190
1244
|
}
|
|
1191
1245
|
);
|
|
1192
1246
|
};
|
|
1193
1247
|
export {
|
|
1194
|
-
|
|
1248
|
+
Cr as default
|
|
1195
1249
|
};
|
|
1196
1250
|
//# sourceMappingURL=Table.js.map
|