@wallarm-org/design-system 2.4.1-rc-fix-code-snippet-fullscreen-in-dialog.1 → 2.6.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/dist/components/Table/StickyGroupParent.js +11 -4
- package/dist/components/Table/TableBody/TableRowOverlay.js +46 -30
- package/dist/components/Table/TableContext/TableProvider.js +318 -304
- package/dist/components/Table/TableContext/types.d.ts +3 -0
- package/dist/components/Table/TableRow.d.ts +12 -1
- package/dist/components/Table/TableRow.js +264 -177
- package/dist/components/Table/lib/createDragHandleColumn.js +5 -24
- package/dist/components/Table/lib/createExpandColumn.d.ts +6 -2
- package/dist/components/Table/lib/createExpandColumn.js +2 -2
- package/dist/components/Table/lib/useRowDnd.d.ts +2 -0
- package/dist/components/Table/lib/useRowDnd.js +46 -41
- package/dist/components/Table/types.d.ts +46 -0
- package/dist/metadata/components.json +38 -3
- package/package.json +1 -1
|
@@ -16,16 +16,18 @@ const toTanStackPinning = (p, pinnedLeft)=>({
|
|
|
16
16
|
end: p?.right ?? []
|
|
17
17
|
});
|
|
18
18
|
const TableProvider = (props)=>{
|
|
19
|
-
const $ = compiler_runtime_c(
|
|
20
|
-
const { data, columns, isLoading: t0, isLoadingPrevious: t1, skeletonCount: t2, children, getRowId, sorting: sortingProp, onSortingChange, manualSorting: t3, rowSelection: rowSelectionProp, onRowSelectionChange, enableSelectAllRows: t4, onSelectAllRows, columnSizing: columnSizingProp, onColumnSizingChange, columnPinning: columnPinningProp, onColumnPinningChange, columnOrder: columnOrderProp, onColumnOrderChange, grouping: groupingProp, onGroupingChange, expanded: expandedProp, onExpandedChange, renderGroupRow, getSubRows, showEmptyGroups:
|
|
19
|
+
const $ = compiler_runtime_c(168);
|
|
20
|
+
const { data, columns, isLoading: t0, isLoadingPrevious: t1, skeletonCount: t2, children, getRowId, sorting: sortingProp, onSortingChange, manualSorting: t3, rowSelection: rowSelectionProp, onRowSelectionChange, enableSelectAllRows: t4, onSelectAllRows, columnSizing: columnSizingProp, onColumnSizingChange, columnPinning: columnPinningProp, onColumnPinningChange, columnOrder: columnOrderProp, onColumnOrderChange, grouping: groupingProp, onGroupingChange, expanded: expandedProp, onExpandedChange, renderGroupRow, groupRowSpan: t5, groupExpandColumn: t6, getSubRows, showEmptyGroups: t7, renderExpandedRow, columnVisibility: columnVisibilityProp, onColumnVisibilityChange, defaultColumnVisibility, defaultColumnOrder, columnGroups, virtualized, stretch: t8, estimateRowHeight, overscan: t9, onEndReached, onEndReachedThreshold, onStartReached, onStartReachedThreshold, initialScrollToRowId, onRowReorder, getRowCanDrag, renderFullWidthRow, onMasterCellClick, activeRowId: activeRowIdProp, onSettingsOpenChange } = props;
|
|
21
21
|
const isLoading = void 0 === t0 ? false : t0;
|
|
22
22
|
const isLoadingPrevious = void 0 === t1 ? false : t1;
|
|
23
23
|
const skeletonCount = void 0 === t2 ? TABLE_SKELETON_ROWS : t2;
|
|
24
24
|
const manualSorting = void 0 === t3 ? false : t3;
|
|
25
25
|
const enableSelectAllRows = void 0 === t4 ? true : t4;
|
|
26
|
-
const
|
|
27
|
-
const
|
|
28
|
-
const
|
|
26
|
+
const groupRowSpan = void 0 === t5 ? "master" : t5;
|
|
27
|
+
const groupExpandColumn = void 0 === t6 ? false : t6;
|
|
28
|
+
const showEmptyGroups = void 0 === t7 ? false : t7;
|
|
29
|
+
const stretch = void 0 === t8 ? true : t8;
|
|
30
|
+
const overscan = void 0 === t9 ? TABLE_VIRTUALIZATION_OVERSCAN : t9;
|
|
29
31
|
const masterCellActiveRowId = activeRowIdProp ?? null;
|
|
30
32
|
const sortingEnabled = !!onSortingChange;
|
|
31
33
|
const selectionEnabled = !!onRowSelectionChange;
|
|
@@ -37,47 +39,51 @@ const TableProvider = (props)=>{
|
|
|
37
39
|
const rowDndEnabled = !!onRowReorder;
|
|
38
40
|
const expandingEnabled = !!renderExpandedRow || !!onExpandedChange || subRowGroupingEnabled;
|
|
39
41
|
const visibilityEnabled = !!onColumnVisibilityChange;
|
|
40
|
-
|
|
41
|
-
|
|
42
|
+
const expandColumnEnabled = expandingEnabled && (!subRowGroupingEnabled || groupExpandColumn);
|
|
43
|
+
let t10;
|
|
44
|
+
if ($[0] !== columns || $[1] !== data[0] || $[2] !== expandColumnEnabled || $[3] !== rowDndEnabled || $[4] !== selectionEnabled || $[5] !== subRowGroupingEnabled) {
|
|
42
45
|
bb0: {
|
|
43
46
|
const cols = columns;
|
|
44
47
|
let prefix;
|
|
45
|
-
if ($[7] !==
|
|
48
|
+
if ($[7] !== expandColumnEnabled || $[8] !== rowDndEnabled || $[9] !== selectionEnabled || $[10] !== subRowGroupingEnabled) {
|
|
46
49
|
prefix = [];
|
|
47
|
-
if (
|
|
48
|
-
let
|
|
49
|
-
if ($[12]
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
50
|
+
if (expandColumnEnabled) {
|
|
51
|
+
let t11;
|
|
52
|
+
if ($[12] !== subRowGroupingEnabled) {
|
|
53
|
+
t11 = createExpandColumn({
|
|
54
|
+
groupsOnly: subRowGroupingEnabled
|
|
55
|
+
});
|
|
56
|
+
$[12] = subRowGroupingEnabled;
|
|
57
|
+
$[13] = t11;
|
|
58
|
+
} else t11 = $[13];
|
|
59
|
+
prefix.push(t11);
|
|
54
60
|
}
|
|
55
61
|
if (selectionEnabled) {
|
|
56
|
-
let
|
|
57
|
-
if ($[
|
|
58
|
-
|
|
59
|
-
$[
|
|
60
|
-
} else
|
|
61
|
-
prefix.push(
|
|
62
|
+
let t11;
|
|
63
|
+
if ($[14] === Symbol.for("react.memo_cache_sentinel")) {
|
|
64
|
+
t11 = createSelectionColumn();
|
|
65
|
+
$[14] = t11;
|
|
66
|
+
} else t11 = $[14];
|
|
67
|
+
prefix.push(t11);
|
|
62
68
|
}
|
|
63
69
|
if (rowDndEnabled) {
|
|
64
|
-
let
|
|
65
|
-
if ($[
|
|
66
|
-
|
|
67
|
-
$[
|
|
68
|
-
} else
|
|
69
|
-
prefix.push(
|
|
70
|
+
let t11;
|
|
71
|
+
if ($[15] === Symbol.for("react.memo_cache_sentinel")) {
|
|
72
|
+
t11 = createDragHandleColumn();
|
|
73
|
+
$[15] = t11;
|
|
74
|
+
} else t11 = $[15];
|
|
75
|
+
prefix.push(t11);
|
|
70
76
|
}
|
|
71
|
-
$[7] =
|
|
77
|
+
$[7] = expandColumnEnabled;
|
|
72
78
|
$[8] = rowDndEnabled;
|
|
73
79
|
$[9] = selectionEnabled;
|
|
74
80
|
$[10] = subRowGroupingEnabled;
|
|
75
81
|
$[11] = prefix;
|
|
76
82
|
} else prefix = $[11];
|
|
77
83
|
const firstRow = data[0];
|
|
78
|
-
let
|
|
79
|
-
if ($[
|
|
80
|
-
|
|
84
|
+
let t11;
|
|
85
|
+
if ($[16] !== firstRow) {
|
|
86
|
+
t11 = (col)=>{
|
|
81
87
|
if (!firstRow || !("accessorKey" in col) || col.meta?.sortType) return col;
|
|
82
88
|
const value = firstRow[col.accessorKey];
|
|
83
89
|
if ("number" == typeof value) return {
|
|
@@ -89,17 +95,17 @@ const TableProvider = (props)=>{
|
|
|
89
95
|
};
|
|
90
96
|
return col;
|
|
91
97
|
};
|
|
92
|
-
$[
|
|
93
|
-
$[
|
|
94
|
-
} else
|
|
95
|
-
const withAutoMeta = cols.map(
|
|
98
|
+
$[16] = firstRow;
|
|
99
|
+
$[17] = t11;
|
|
100
|
+
} else t11 = $[17];
|
|
101
|
+
const withAutoMeta = cols.map(t11);
|
|
96
102
|
const masterOverrides = {
|
|
97
103
|
enableColumnPinning: false,
|
|
98
104
|
enableHiding: false
|
|
99
105
|
};
|
|
100
106
|
if (0 === prefix.length) {
|
|
101
107
|
if (withAutoMeta.length > 0) {
|
|
102
|
-
|
|
108
|
+
t10 = [
|
|
103
109
|
{
|
|
104
110
|
...withAutoMeta[0],
|
|
105
111
|
...masterOverrides
|
|
@@ -108,118 +114,117 @@ const TableProvider = (props)=>{
|
|
|
108
114
|
];
|
|
109
115
|
break bb0;
|
|
110
116
|
}
|
|
111
|
-
|
|
117
|
+
t10 = withAutoMeta;
|
|
112
118
|
break bb0;
|
|
113
119
|
}
|
|
114
120
|
const userCols = withAutoMeta.length > 0 ? withAutoMeta.map((col_0, index)=>0 === index ? {
|
|
115
121
|
...col_0,
|
|
116
122
|
...masterOverrides
|
|
117
123
|
} : col_0) : withAutoMeta;
|
|
118
|
-
|
|
124
|
+
t10 = [
|
|
119
125
|
...prefix,
|
|
120
126
|
...userCols
|
|
121
127
|
];
|
|
122
128
|
}
|
|
123
129
|
$[0] = columns;
|
|
124
130
|
$[1] = data[0];
|
|
125
|
-
$[2] =
|
|
131
|
+
$[2] = expandColumnEnabled;
|
|
126
132
|
$[3] = rowDndEnabled;
|
|
127
133
|
$[4] = selectionEnabled;
|
|
128
134
|
$[5] = subRowGroupingEnabled;
|
|
129
|
-
$[6] =
|
|
130
|
-
} else
|
|
131
|
-
const mergedColumns =
|
|
132
|
-
let
|
|
135
|
+
$[6] = t10;
|
|
136
|
+
} else t10 = $[6];
|
|
137
|
+
const mergedColumns = t10;
|
|
138
|
+
let t11;
|
|
133
139
|
bb1: {
|
|
134
140
|
if (0 === columns.length) {
|
|
135
|
-
|
|
141
|
+
t11 = null;
|
|
136
142
|
break bb1;
|
|
137
143
|
}
|
|
138
144
|
const firstCol = columns[0];
|
|
139
145
|
if (!firstCol) {
|
|
140
|
-
|
|
146
|
+
t11 = null;
|
|
141
147
|
break bb1;
|
|
142
148
|
}
|
|
143
|
-
|
|
149
|
+
t11 = ("accessorKey" in firstCol ? String(firstCol.accessorKey) : firstCol.id) ?? null;
|
|
144
150
|
}
|
|
145
|
-
const masterColumnId =
|
|
151
|
+
const masterColumnId = t11;
|
|
146
152
|
let ids;
|
|
147
|
-
if ($[
|
|
153
|
+
if ($[18] !== expandColumnEnabled || $[19] !== masterColumnId || $[20] !== rowDndEnabled || $[21] !== selectionEnabled) {
|
|
148
154
|
ids = [];
|
|
149
|
-
if (
|
|
155
|
+
if (expandColumnEnabled) ids.push(TABLE_EXPAND_COLUMN_ID);
|
|
150
156
|
if (selectionEnabled) ids.push(TABLE_SELECT_COLUMN_ID);
|
|
151
157
|
if (rowDndEnabled) ids.push(TABLE_DRAG_HANDLE_COLUMN_ID);
|
|
152
158
|
if (masterColumnId) ids.push(masterColumnId);
|
|
153
|
-
$[
|
|
154
|
-
$[
|
|
155
|
-
$[
|
|
156
|
-
$[
|
|
157
|
-
$[21] = subRowGroupingEnabled;
|
|
159
|
+
$[18] = expandColumnEnabled;
|
|
160
|
+
$[19] = masterColumnId;
|
|
161
|
+
$[20] = rowDndEnabled;
|
|
162
|
+
$[21] = selectionEnabled;
|
|
158
163
|
$[22] = ids;
|
|
159
164
|
} else ids = $[22];
|
|
160
165
|
const alwaysPinnedLeft = ids;
|
|
161
|
-
let
|
|
166
|
+
let t12;
|
|
162
167
|
if ($[23] === Symbol.for("react.memo_cache_sentinel")) {
|
|
163
|
-
|
|
164
|
-
$[23] =
|
|
165
|
-
} else
|
|
166
|
-
const [sorting, handleSortingChange] = useTableState(sortingProp,
|
|
167
|
-
let
|
|
168
|
+
t12 = [];
|
|
169
|
+
$[23] = t12;
|
|
170
|
+
} else t12 = $[23];
|
|
171
|
+
const [sorting, handleSortingChange] = useTableState(sortingProp, t12, onSortingChange);
|
|
172
|
+
let t13;
|
|
168
173
|
if ($[24] === Symbol.for("react.memo_cache_sentinel")) {
|
|
169
|
-
|
|
170
|
-
$[24] =
|
|
171
|
-
} else
|
|
172
|
-
const [rowSelection, handleRowSelectionChange] = useTableState(rowSelectionProp,
|
|
173
|
-
let
|
|
174
|
+
t13 = {};
|
|
175
|
+
$[24] = t13;
|
|
176
|
+
} else t13 = $[24];
|
|
177
|
+
const [rowSelection, handleRowSelectionChange] = useTableState(rowSelectionProp, t13, onRowSelectionChange);
|
|
178
|
+
let t14;
|
|
174
179
|
if ($[25] === Symbol.for("react.memo_cache_sentinel")) {
|
|
175
|
-
|
|
176
|
-
$[25] =
|
|
177
|
-
} else
|
|
178
|
-
const [columnSizing, handleColumnSizingChange] = useTableState(columnSizingProp,
|
|
179
|
-
let
|
|
180
|
+
t14 = {};
|
|
181
|
+
$[25] = t14;
|
|
182
|
+
} else t14 = $[25];
|
|
183
|
+
const [columnSizing, handleColumnSizingChange] = useTableState(columnSizingProp, t14, onColumnSizingChange);
|
|
184
|
+
let t15;
|
|
180
185
|
if ($[26] !== defaultColumnOrder) {
|
|
181
|
-
|
|
186
|
+
t15 = defaultColumnOrder ?? [];
|
|
182
187
|
$[26] = defaultColumnOrder;
|
|
183
|
-
$[27] =
|
|
184
|
-
} else
|
|
185
|
-
const [columnOrder, handleColumnOrderChange] = useTableState(columnOrderProp,
|
|
186
|
-
let
|
|
188
|
+
$[27] = t15;
|
|
189
|
+
} else t15 = $[27];
|
|
190
|
+
const [columnOrder, handleColumnOrderChange] = useTableState(columnOrderProp, t15, onColumnOrderChange);
|
|
191
|
+
let t16;
|
|
187
192
|
if ($[28] === Symbol.for("react.memo_cache_sentinel")) {
|
|
188
|
-
|
|
189
|
-
$[28] =
|
|
190
|
-
} else
|
|
191
|
-
const [grouping, handleGroupingChange] = useTableState(groupingProp,
|
|
192
|
-
let
|
|
193
|
+
t16 = [];
|
|
194
|
+
$[28] = t16;
|
|
195
|
+
} else t16 = $[28];
|
|
196
|
+
const [grouping, handleGroupingChange] = useTableState(groupingProp, t16, onGroupingChange);
|
|
197
|
+
let t17;
|
|
193
198
|
if ($[29] === Symbol.for("react.memo_cache_sentinel")) {
|
|
194
|
-
|
|
195
|
-
$[29] =
|
|
196
|
-
} else
|
|
197
|
-
const [expanded, handleExpandedChange] = useTableState(expandedProp,
|
|
198
|
-
let
|
|
199
|
+
t17 = {};
|
|
200
|
+
$[29] = t17;
|
|
201
|
+
} else t17 = $[29];
|
|
202
|
+
const [expanded, handleExpandedChange] = useTableState(expandedProp, t17, onExpandedChange);
|
|
203
|
+
let t18;
|
|
199
204
|
if ($[30] !== defaultColumnVisibility) {
|
|
200
|
-
|
|
205
|
+
t18 = defaultColumnVisibility ?? {};
|
|
201
206
|
$[30] = defaultColumnVisibility;
|
|
202
|
-
$[31] =
|
|
203
|
-
} else
|
|
204
|
-
const [columnVisibility, handleColumnVisibilityChange] = useTableState(columnVisibilityProp,
|
|
205
|
-
let
|
|
207
|
+
$[31] = t18;
|
|
208
|
+
} else t18 = $[31];
|
|
209
|
+
const [columnVisibility, handleColumnVisibilityChange] = useTableState(columnVisibilityProp, t18, onColumnVisibilityChange);
|
|
210
|
+
let t19;
|
|
206
211
|
if ($[32] === Symbol.for("react.memo_cache_sentinel")) {
|
|
207
|
-
|
|
208
|
-
$[32] =
|
|
209
|
-
} else
|
|
210
|
-
let
|
|
212
|
+
t19 = {};
|
|
213
|
+
$[32] = t19;
|
|
214
|
+
} else t19 = $[32];
|
|
215
|
+
let t20;
|
|
211
216
|
if ($[33] !== columnPinningProp) {
|
|
212
|
-
|
|
217
|
+
t20 = {
|
|
213
218
|
controlled: columnPinningProp,
|
|
214
|
-
default:
|
|
219
|
+
default: t19
|
|
215
220
|
};
|
|
216
221
|
$[33] = columnPinningProp;
|
|
217
|
-
$[34] =
|
|
218
|
-
} else
|
|
219
|
-
const [columnPinning, setColumnPinningInternal] = useControlled(
|
|
220
|
-
let
|
|
222
|
+
$[34] = t20;
|
|
223
|
+
} else t20 = $[34];
|
|
224
|
+
const [columnPinning, setColumnPinningInternal] = useControlled(t20);
|
|
225
|
+
let t21;
|
|
221
226
|
if ($[35] !== alwaysPinnedLeft || $[36] !== columnPinning || $[37] !== onColumnPinningChange || $[38] !== setColumnPinningInternal) {
|
|
222
|
-
|
|
227
|
+
t21 = (updater)=>{
|
|
223
228
|
const prevTanStackShape = toTanStackPinning(columnPinning, alwaysPinnedLeft);
|
|
224
229
|
const newValue = "function" == typeof updater ? updater(prevTanStackShape) : updater;
|
|
225
230
|
const enforcedStart = [
|
|
@@ -237,12 +242,12 @@ const TableProvider = (props)=>{
|
|
|
237
242
|
$[36] = columnPinning;
|
|
238
243
|
$[37] = onColumnPinningChange;
|
|
239
244
|
$[38] = setColumnPinningInternal;
|
|
240
|
-
$[39] =
|
|
241
|
-
} else
|
|
242
|
-
const handleColumnPinningChange =
|
|
243
|
-
let
|
|
245
|
+
$[39] = t21;
|
|
246
|
+
} else t21 = $[39];
|
|
247
|
+
const handleColumnPinningChange = t21;
|
|
248
|
+
let t22;
|
|
244
249
|
if ($[40] !== alwaysPinnedLeft || $[41] !== handleColumnOrderChange) {
|
|
245
|
-
|
|
250
|
+
t22 = (newOrder)=>{
|
|
246
251
|
const rest = newOrder.filter((id_0)=>!alwaysPinnedLeft.includes(id_0));
|
|
247
252
|
handleColumnOrderChange([
|
|
248
253
|
...alwaysPinnedLeft,
|
|
@@ -251,142 +256,142 @@ const TableProvider = (props)=>{
|
|
|
251
256
|
};
|
|
252
257
|
$[40] = alwaysPinnedLeft;
|
|
253
258
|
$[41] = handleColumnOrderChange;
|
|
254
|
-
$[42] =
|
|
255
|
-
} else
|
|
256
|
-
const setColumnOrder =
|
|
257
|
-
let
|
|
259
|
+
$[42] = t22;
|
|
260
|
+
} else t22 = $[42];
|
|
261
|
+
const setColumnOrder = t22;
|
|
262
|
+
let t23;
|
|
258
263
|
if ($[43] !== sorting) {
|
|
259
|
-
|
|
264
|
+
t23 = sorting ?? [];
|
|
260
265
|
$[43] = sorting;
|
|
261
|
-
$[44] =
|
|
262
|
-
} else
|
|
263
|
-
let
|
|
266
|
+
$[44] = t23;
|
|
267
|
+
} else t23 = $[44];
|
|
268
|
+
let t24;
|
|
264
269
|
if ($[45] !== rowSelection) {
|
|
265
|
-
|
|
270
|
+
t24 = rowSelection ?? {};
|
|
266
271
|
$[45] = rowSelection;
|
|
267
|
-
$[46] =
|
|
268
|
-
} else
|
|
269
|
-
let
|
|
272
|
+
$[46] = t24;
|
|
273
|
+
} else t24 = $[46];
|
|
274
|
+
let t25;
|
|
270
275
|
if ($[47] !== columnSizing) {
|
|
271
|
-
|
|
276
|
+
t25 = columnSizing ?? {};
|
|
272
277
|
$[47] = columnSizing;
|
|
273
|
-
$[48] =
|
|
274
|
-
} else
|
|
275
|
-
let
|
|
278
|
+
$[48] = t25;
|
|
279
|
+
} else t25 = $[48];
|
|
280
|
+
let t26;
|
|
276
281
|
if ($[49] !== alwaysPinnedLeft || $[50] !== columnPinning) {
|
|
277
|
-
|
|
282
|
+
t26 = toTanStackPinning(columnPinning, alwaysPinnedLeft);
|
|
278
283
|
$[49] = alwaysPinnedLeft;
|
|
279
284
|
$[50] = columnPinning;
|
|
280
|
-
$[51] =
|
|
281
|
-
} else
|
|
282
|
-
let
|
|
285
|
+
$[51] = t26;
|
|
286
|
+
} else t26 = $[51];
|
|
287
|
+
let t27;
|
|
283
288
|
if ($[52] !== columnOrder) {
|
|
284
|
-
|
|
289
|
+
t27 = columnOrder ?? [];
|
|
285
290
|
$[52] = columnOrder;
|
|
286
|
-
$[53] =
|
|
287
|
-
} else
|
|
288
|
-
let
|
|
291
|
+
$[53] = t27;
|
|
292
|
+
} else t27 = $[53];
|
|
293
|
+
let t28;
|
|
289
294
|
if ($[54] !== grouping) {
|
|
290
|
-
|
|
295
|
+
t28 = grouping ?? [];
|
|
291
296
|
$[54] = grouping;
|
|
292
|
-
$[55] =
|
|
293
|
-
} else
|
|
294
|
-
let
|
|
297
|
+
$[55] = t28;
|
|
298
|
+
} else t28 = $[55];
|
|
299
|
+
let t29;
|
|
295
300
|
if ($[56] !== expanded) {
|
|
296
|
-
|
|
301
|
+
t29 = expanded ?? {};
|
|
297
302
|
$[56] = expanded;
|
|
298
|
-
$[57] =
|
|
299
|
-
} else
|
|
300
|
-
let
|
|
303
|
+
$[57] = t29;
|
|
304
|
+
} else t29 = $[57];
|
|
305
|
+
let t30;
|
|
301
306
|
if ($[58] !== columnVisibility) {
|
|
302
|
-
|
|
307
|
+
t30 = columnVisibility ?? {};
|
|
303
308
|
$[58] = columnVisibility;
|
|
304
|
-
$[59] =
|
|
305
|
-
} else
|
|
306
|
-
let
|
|
307
|
-
if ($[60] !==
|
|
308
|
-
|
|
309
|
-
sorting:
|
|
310
|
-
rowSelection:
|
|
311
|
-
columnSizing:
|
|
312
|
-
columnPinning:
|
|
313
|
-
columnOrder:
|
|
314
|
-
grouping:
|
|
315
|
-
expanded:
|
|
316
|
-
columnVisibility:
|
|
309
|
+
$[59] = t30;
|
|
310
|
+
} else t30 = $[59];
|
|
311
|
+
let t31;
|
|
312
|
+
if ($[60] !== t23 || $[61] !== t24 || $[62] !== t25 || $[63] !== t26 || $[64] !== t27 || $[65] !== t28 || $[66] !== t29 || $[67] !== t30) {
|
|
313
|
+
t31 = {
|
|
314
|
+
sorting: t23,
|
|
315
|
+
rowSelection: t24,
|
|
316
|
+
columnSizing: t25,
|
|
317
|
+
columnPinning: t26,
|
|
318
|
+
columnOrder: t27,
|
|
319
|
+
grouping: t28,
|
|
320
|
+
expanded: t29,
|
|
321
|
+
columnVisibility: t30
|
|
317
322
|
};
|
|
318
|
-
$[60] =
|
|
319
|
-
$[61] =
|
|
320
|
-
$[62] =
|
|
321
|
-
$[63] =
|
|
322
|
-
$[64] =
|
|
323
|
-
$[65] =
|
|
324
|
-
$[66] =
|
|
325
|
-
$[67] =
|
|
326
|
-
$[68] =
|
|
327
|
-
} else
|
|
328
|
-
const
|
|
329
|
-
const
|
|
330
|
-
const
|
|
331
|
-
const
|
|
332
|
-
const
|
|
333
|
-
const
|
|
334
|
-
const
|
|
335
|
-
const
|
|
336
|
-
let
|
|
323
|
+
$[60] = t23;
|
|
324
|
+
$[61] = t24;
|
|
325
|
+
$[62] = t25;
|
|
326
|
+
$[63] = t26;
|
|
327
|
+
$[64] = t27;
|
|
328
|
+
$[65] = t28;
|
|
329
|
+
$[66] = t29;
|
|
330
|
+
$[67] = t30;
|
|
331
|
+
$[68] = t31;
|
|
332
|
+
} else t31 = $[68];
|
|
333
|
+
const t32 = sortingEnabled ? handleSortingChange : void 0;
|
|
334
|
+
const t33 = selectionEnabled ? handleRowSelectionChange : void 0;
|
|
335
|
+
const t34 = resizingEnabled ? handleColumnSizingChange : void 0;
|
|
336
|
+
const t35 = pinningEnabled ? handleColumnPinningChange : void 0;
|
|
337
|
+
const t36 = columnDndEnabled ? handleColumnOrderChange : void 0;
|
|
338
|
+
const t37 = groupingEnabled ? handleGroupingChange : void 0;
|
|
339
|
+
const t38 = expandingEnabled ? handleExpandedChange : void 0;
|
|
340
|
+
const t39 = visibilityEnabled ? handleColumnVisibilityChange : void 0;
|
|
341
|
+
let t40;
|
|
337
342
|
if ($[69] !== expandingEnabled) {
|
|
338
|
-
|
|
343
|
+
t40 = expandingEnabled ? {
|
|
339
344
|
autoResetExpanded: false
|
|
340
345
|
} : {};
|
|
341
346
|
$[69] = expandingEnabled;
|
|
342
|
-
$[70] =
|
|
343
|
-
} else
|
|
344
|
-
let
|
|
347
|
+
$[70] = t40;
|
|
348
|
+
} else t40 = $[70];
|
|
349
|
+
let t41;
|
|
345
350
|
if ($[71] !== expandingEnabled || $[72] !== renderExpandedRow || $[73] !== subRowGroupingEnabled) {
|
|
346
|
-
|
|
351
|
+
t41 = expandingEnabled && (renderExpandedRow || subRowGroupingEnabled) ? {
|
|
347
352
|
getRowCanExpand: _temp
|
|
348
353
|
} : {};
|
|
349
354
|
$[71] = expandingEnabled;
|
|
350
355
|
$[72] = renderExpandedRow;
|
|
351
356
|
$[73] = subRowGroupingEnabled;
|
|
352
|
-
$[74] =
|
|
353
|
-
} else
|
|
354
|
-
let
|
|
357
|
+
$[74] = t41;
|
|
358
|
+
} else t41 = $[74];
|
|
359
|
+
let t42;
|
|
355
360
|
if ($[75] === Symbol.for("react.memo_cache_sentinel")) {
|
|
356
|
-
|
|
361
|
+
t42 = {
|
|
357
362
|
minSize: TABLE_MIN_COLUMN_WIDTH
|
|
358
363
|
};
|
|
359
|
-
$[75] =
|
|
360
|
-
} else
|
|
361
|
-
let
|
|
362
|
-
if ($[76] !== data || $[77] !== expandingEnabled || $[78] !== getRowId || $[79] !== getSubRows || $[80] !== groupingEnabled || $[81] !== manualSorting || $[82] !== mergedColumns || $[83] !== resizingEnabled || $[84] !== selectionEnabled || $[85] !== sortingEnabled || $[86] !==
|
|
363
|
-
|
|
364
|
+
$[75] = t42;
|
|
365
|
+
} else t42 = $[75];
|
|
366
|
+
let t43;
|
|
367
|
+
if ($[76] !== data || $[77] !== expandingEnabled || $[78] !== getRowId || $[79] !== getSubRows || $[80] !== groupingEnabled || $[81] !== manualSorting || $[82] !== mergedColumns || $[83] !== resizingEnabled || $[84] !== selectionEnabled || $[85] !== sortingEnabled || $[86] !== t31 || $[87] !== t32 || $[88] !== t33 || $[89] !== t34 || $[90] !== t35 || $[91] !== t36 || $[92] !== t37 || $[93] !== t38 || $[94] !== t39 || $[95] !== t40 || $[96] !== t41 || $[97] !== visibilityEnabled) {
|
|
368
|
+
t43 = {
|
|
364
369
|
features: dsTableFeatures,
|
|
365
370
|
data,
|
|
366
371
|
columns: mergedColumns,
|
|
367
372
|
getRowId,
|
|
368
373
|
getSubRows,
|
|
369
374
|
manualSorting,
|
|
370
|
-
state:
|
|
371
|
-
onSortingChange:
|
|
372
|
-
onRowSelectionChange:
|
|
373
|
-
onColumnSizingChange:
|
|
374
|
-
onColumnPinningChange:
|
|
375
|
-
onColumnOrderChange:
|
|
376
|
-
onGroupingChange:
|
|
377
|
-
onExpandedChange:
|
|
378
|
-
onColumnVisibilityChange:
|
|
375
|
+
state: t31,
|
|
376
|
+
onSortingChange: t32,
|
|
377
|
+
onRowSelectionChange: t33,
|
|
378
|
+
onColumnSizingChange: t34,
|
|
379
|
+
onColumnPinningChange: t35,
|
|
380
|
+
onColumnOrderChange: t36,
|
|
381
|
+
onGroupingChange: t37,
|
|
382
|
+
onExpandedChange: t38,
|
|
383
|
+
onColumnVisibilityChange: t39,
|
|
379
384
|
enableSorting: sortingEnabled,
|
|
380
385
|
enableRowSelection: selectionEnabled,
|
|
381
386
|
enableColumnResizing: resizingEnabled,
|
|
382
387
|
enableColumnPinning: true,
|
|
383
388
|
enableGrouping: groupingEnabled,
|
|
384
389
|
enableExpanding: expandingEnabled,
|
|
385
|
-
...
|
|
386
|
-
...
|
|
390
|
+
...t40,
|
|
391
|
+
...t41,
|
|
387
392
|
enableHiding: visibilityEnabled,
|
|
388
393
|
columnResizeMode: "onChange",
|
|
389
|
-
defaultColumn:
|
|
394
|
+
defaultColumn: t42
|
|
390
395
|
};
|
|
391
396
|
$[76] = data;
|
|
392
397
|
$[77] = expandingEnabled;
|
|
@@ -398,38 +403,41 @@ const TableProvider = (props)=>{
|
|
|
398
403
|
$[83] = resizingEnabled;
|
|
399
404
|
$[84] = selectionEnabled;
|
|
400
405
|
$[85] = sortingEnabled;
|
|
401
|
-
$[86] =
|
|
402
|
-
$[87] =
|
|
403
|
-
$[88] =
|
|
404
|
-
$[89] =
|
|
405
|
-
$[90] =
|
|
406
|
-
$[91] =
|
|
407
|
-
$[92] =
|
|
408
|
-
$[93] =
|
|
409
|
-
$[94] =
|
|
410
|
-
$[95] =
|
|
411
|
-
$[96] =
|
|
406
|
+
$[86] = t31;
|
|
407
|
+
$[87] = t32;
|
|
408
|
+
$[88] = t33;
|
|
409
|
+
$[89] = t34;
|
|
410
|
+
$[90] = t35;
|
|
411
|
+
$[91] = t36;
|
|
412
|
+
$[92] = t37;
|
|
413
|
+
$[93] = t38;
|
|
414
|
+
$[94] = t39;
|
|
415
|
+
$[95] = t40;
|
|
416
|
+
$[96] = t41;
|
|
412
417
|
$[97] = visibilityEnabled;
|
|
413
|
-
$[98] =
|
|
414
|
-
} else
|
|
415
|
-
const table = useTable(
|
|
416
|
-
let
|
|
418
|
+
$[98] = t43;
|
|
419
|
+
} else t43 = $[98];
|
|
420
|
+
const table = useTable(t43);
|
|
421
|
+
let t44;
|
|
417
422
|
if ($[99] !== table) {
|
|
418
|
-
|
|
423
|
+
t44 = table.getAllLeafColumns();
|
|
419
424
|
$[99] = table;
|
|
420
|
-
$[100] =
|
|
421
|
-
} else
|
|
422
|
-
const allLeafColumns =
|
|
425
|
+
$[100] = t44;
|
|
426
|
+
} else t44 = $[100];
|
|
427
|
+
const allLeafColumns = t44;
|
|
423
428
|
const lastSelectedRowIndexRef = useRef(null);
|
|
424
429
|
const containerRef = useRef(null);
|
|
425
430
|
const headerScrollRef = useRef(null);
|
|
426
431
|
const tbodyRef = useRef(null);
|
|
427
432
|
const virtualizerRef = useRef(null);
|
|
428
|
-
const
|
|
429
|
-
const
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
+
const t45 = !!getSubRows;
|
|
434
|
+
const t46 = renderExpandedRow;
|
|
435
|
+
const t47 = getRowCanDrag;
|
|
436
|
+
const t48 = "full" === groupRowSpan ? renderGroupRow : void 0;
|
|
437
|
+
const t49 = renderFullWidthRow;
|
|
438
|
+
let t50;
|
|
439
|
+
if ($[101] !== allLeafColumns || $[102] !== alwaysPinnedLeft || $[103] !== columnDndEnabled || $[104] !== columnGroups || $[105] !== defaultColumnOrder || $[106] !== defaultColumnVisibility || $[107] !== enableSelectAllRows || $[108] !== estimateRowHeight || $[109] !== expandingEnabled || $[110] !== groupingEnabled || $[111] !== initialScrollToRowId || $[112] !== isLoading || $[113] !== isLoadingPrevious || $[114] !== masterCellActiveRowId || $[115] !== masterColumnId || $[116] !== onEndReached || $[117] !== onEndReachedThreshold || $[118] !== onMasterCellClick || $[119] !== onRowReorder || $[120] !== onSelectAllRows || $[121] !== onSettingsOpenChange || $[122] !== onStartReached || $[123] !== onStartReachedThreshold || $[124] !== overscan || $[125] !== pinningEnabled || $[126] !== resizingEnabled || $[127] !== rowDndEnabled || $[128] !== selectionEnabled || $[129] !== setColumnOrder || $[130] !== showEmptyGroups || $[131] !== skeletonCount || $[132] !== sortingEnabled || $[133] !== stretch || $[134] !== t45 || $[135] !== t46 || $[136] !== t47 || $[137] !== t48 || $[138] !== t49 || $[139] !== table || $[140] !== virtualized || $[141] !== visibilityEnabled) {
|
|
440
|
+
t50 = {
|
|
433
441
|
table,
|
|
434
442
|
isLoading,
|
|
435
443
|
isLoadingPrevious,
|
|
@@ -443,11 +451,11 @@ const TableProvider = (props)=>{
|
|
|
443
451
|
groupingEnabled,
|
|
444
452
|
expandingEnabled,
|
|
445
453
|
visibilityEnabled,
|
|
446
|
-
hasSubRowGrouping:
|
|
454
|
+
hasSubRowGrouping: t45,
|
|
447
455
|
showEmptyGroups,
|
|
448
456
|
virtualized,
|
|
449
457
|
stretch,
|
|
450
|
-
renderExpandedRow:
|
|
458
|
+
renderExpandedRow: t46,
|
|
451
459
|
estimateRowHeight,
|
|
452
460
|
overscan,
|
|
453
461
|
allLeafColumns,
|
|
@@ -470,6 +478,9 @@ const TableProvider = (props)=>{
|
|
|
470
478
|
onStartReachedThreshold,
|
|
471
479
|
initialScrollToRowId,
|
|
472
480
|
onRowReorder,
|
|
481
|
+
getRowCanDrag: t47,
|
|
482
|
+
renderFullWidthGroupRow: t48,
|
|
483
|
+
renderFullWidthRow: t49,
|
|
473
484
|
onMasterCellClick,
|
|
474
485
|
activeRowId: masterCellActiveRowId,
|
|
475
486
|
onSettingsOpenChange
|
|
@@ -507,18 +518,21 @@ const TableProvider = (props)=>{
|
|
|
507
518
|
$[131] = skeletonCount;
|
|
508
519
|
$[132] = sortingEnabled;
|
|
509
520
|
$[133] = stretch;
|
|
510
|
-
$[134] =
|
|
511
|
-
$[135] =
|
|
512
|
-
$[136] =
|
|
513
|
-
$[137] =
|
|
514
|
-
$[138] =
|
|
515
|
-
$[139] =
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
521
|
+
$[134] = t45;
|
|
522
|
+
$[135] = t46;
|
|
523
|
+
$[136] = t47;
|
|
524
|
+
$[137] = t48;
|
|
525
|
+
$[138] = t49;
|
|
526
|
+
$[139] = table;
|
|
527
|
+
$[140] = virtualized;
|
|
528
|
+
$[141] = visibilityEnabled;
|
|
529
|
+
$[142] = t50;
|
|
530
|
+
} else t50 = $[142];
|
|
531
|
+
const contextValue = t50;
|
|
532
|
+
let t51;
|
|
533
|
+
let t52;
|
|
534
|
+
if ($[143] !== selectionEnabled || $[144] !== table) {
|
|
535
|
+
t51 = ()=>{
|
|
522
536
|
if (!selectionEnabled) return;
|
|
523
537
|
const container = containerRef.current;
|
|
524
538
|
if (!container) return;
|
|
@@ -528,39 +542,39 @@ const TableProvider = (props)=>{
|
|
|
528
542
|
container.addEventListener("keydown", handleKeyDown);
|
|
529
543
|
return ()=>container.removeEventListener("keydown", handleKeyDown);
|
|
530
544
|
};
|
|
531
|
-
|
|
545
|
+
t52 = [
|
|
532
546
|
selectionEnabled,
|
|
533
547
|
table
|
|
534
548
|
];
|
|
535
|
-
$[
|
|
536
|
-
$[
|
|
537
|
-
$[
|
|
538
|
-
$[
|
|
549
|
+
$[143] = selectionEnabled;
|
|
550
|
+
$[144] = table;
|
|
551
|
+
$[145] = t51;
|
|
552
|
+
$[146] = t52;
|
|
539
553
|
} else {
|
|
540
|
-
|
|
541
|
-
|
|
554
|
+
t51 = $[145];
|
|
555
|
+
t52 = $[146];
|
|
542
556
|
}
|
|
543
|
-
useEffect(
|
|
544
|
-
let
|
|
545
|
-
if ($[
|
|
546
|
-
|
|
557
|
+
useEffect(t51, t52);
|
|
558
|
+
let t53;
|
|
559
|
+
if ($[147] === Symbol.for("react.memo_cache_sentinel")) {
|
|
560
|
+
t53 = {
|
|
547
561
|
activationConstraint: {
|
|
548
562
|
distance: 5
|
|
549
563
|
}
|
|
550
564
|
};
|
|
551
|
-
$[
|
|
552
|
-
} else
|
|
553
|
-
let
|
|
554
|
-
if ($[
|
|
555
|
-
|
|
565
|
+
$[147] = t53;
|
|
566
|
+
} else t53 = $[147];
|
|
567
|
+
let t54;
|
|
568
|
+
if ($[148] === Symbol.for("react.memo_cache_sentinel")) {
|
|
569
|
+
t54 = {
|
|
556
570
|
coordinateGetter: sortableKeyboardCoordinates
|
|
557
571
|
};
|
|
558
|
-
$[
|
|
559
|
-
} else
|
|
560
|
-
const sensors = useSensors(useSensor(PointerSensor,
|
|
561
|
-
let
|
|
562
|
-
if ($[
|
|
563
|
-
|
|
572
|
+
$[148] = t54;
|
|
573
|
+
} else t54 = $[148];
|
|
574
|
+
const sensors = useSensors(useSensor(PointerSensor, t53), useSensor(KeyboardSensor, t54));
|
|
575
|
+
let t55;
|
|
576
|
+
if ($[149] !== allLeafColumns || $[150] !== setColumnOrder || $[151] !== table.atoms) {
|
|
577
|
+
t55 = (event)=>{
|
|
564
578
|
const { active, over } = event;
|
|
565
579
|
if (!over || active.id === over.id) return;
|
|
566
580
|
const columnOrderAtom = table.atoms.columnOrder.get();
|
|
@@ -570,60 +584,60 @@ const TableProvider = (props)=>{
|
|
|
570
584
|
const newOrder_0 = arrayMove(currentOrder, oldIndex, newIndex);
|
|
571
585
|
setColumnOrder(newOrder_0);
|
|
572
586
|
};
|
|
573
|
-
$[
|
|
574
|
-
$[
|
|
575
|
-
$[
|
|
576
|
-
$[
|
|
577
|
-
} else
|
|
578
|
-
const handleDragEnd =
|
|
579
|
-
let
|
|
580
|
-
if ($[
|
|
581
|
-
|
|
582
|
-
$[
|
|
583
|
-
$[
|
|
584
|
-
$[
|
|
585
|
-
$[
|
|
586
|
-
} else
|
|
587
|
-
const columnIds =
|
|
588
|
-
const
|
|
589
|
-
const
|
|
590
|
-
const
|
|
591
|
-
let
|
|
592
|
-
if ($[
|
|
593
|
-
|
|
587
|
+
$[149] = allLeafColumns;
|
|
588
|
+
$[150] = setColumnOrder;
|
|
589
|
+
$[151] = table.atoms;
|
|
590
|
+
$[152] = t55;
|
|
591
|
+
} else t55 = $[152];
|
|
592
|
+
const handleDragEnd = t55;
|
|
593
|
+
let t56;
|
|
594
|
+
if ($[153] !== allLeafColumns || $[154] !== alwaysPinnedLeft || $[155] !== columnDndEnabled) {
|
|
595
|
+
t56 = columnDndEnabled ? allLeafColumns.filter((c_0)=>!alwaysPinnedLeft.includes(c_0.id)).map(_temp3) : [];
|
|
596
|
+
$[153] = allLeafColumns;
|
|
597
|
+
$[154] = alwaysPinnedLeft;
|
|
598
|
+
$[155] = columnDndEnabled;
|
|
599
|
+
$[156] = t56;
|
|
600
|
+
} else t56 = $[156];
|
|
601
|
+
const columnIds = t56;
|
|
602
|
+
const t57 = columnDndEnabled ? sensors : void 0;
|
|
603
|
+
const t58 = columnDndEnabled ? closestCenter : void 0;
|
|
604
|
+
const t59 = columnDndEnabled ? handleDragEnd : void 0;
|
|
605
|
+
let t60;
|
|
606
|
+
if ($[157] !== children || $[158] !== columnIds) {
|
|
607
|
+
t60 = /*#__PURE__*/ jsx(SortableContext, {
|
|
594
608
|
items: columnIds,
|
|
595
609
|
strategy: horizontalListSortingStrategy,
|
|
596
610
|
children: children
|
|
597
611
|
});
|
|
598
|
-
$[
|
|
599
|
-
$[
|
|
600
|
-
$[
|
|
601
|
-
} else
|
|
602
|
-
let
|
|
603
|
-
if ($[
|
|
604
|
-
|
|
605
|
-
sensors:
|
|
606
|
-
collisionDetection:
|
|
607
|
-
onDragEnd:
|
|
608
|
-
children:
|
|
612
|
+
$[157] = children;
|
|
613
|
+
$[158] = columnIds;
|
|
614
|
+
$[159] = t60;
|
|
615
|
+
} else t60 = $[159];
|
|
616
|
+
let t61;
|
|
617
|
+
if ($[160] !== t57 || $[161] !== t58 || $[162] !== t59 || $[163] !== t60) {
|
|
618
|
+
t61 = /*#__PURE__*/ jsx(DndContext, {
|
|
619
|
+
sensors: t57,
|
|
620
|
+
collisionDetection: t58,
|
|
621
|
+
onDragEnd: t59,
|
|
622
|
+
children: t60
|
|
609
623
|
});
|
|
610
|
-
$[
|
|
611
|
-
$[
|
|
612
|
-
$[
|
|
613
|
-
$[
|
|
614
|
-
$[
|
|
615
|
-
} else
|
|
616
|
-
let
|
|
617
|
-
if ($[
|
|
618
|
-
|
|
624
|
+
$[160] = t57;
|
|
625
|
+
$[161] = t58;
|
|
626
|
+
$[162] = t59;
|
|
627
|
+
$[163] = t60;
|
|
628
|
+
$[164] = t61;
|
|
629
|
+
} else t61 = $[164];
|
|
630
|
+
let t62;
|
|
631
|
+
if ($[165] !== contextValue || $[166] !== t61) {
|
|
632
|
+
t62 = /*#__PURE__*/ jsx(TableContext.Provider, {
|
|
619
633
|
value: contextValue,
|
|
620
|
-
children:
|
|
634
|
+
children: t61
|
|
621
635
|
});
|
|
622
|
-
$[
|
|
623
|
-
$[
|
|
624
|
-
$[
|
|
625
|
-
} else
|
|
626
|
-
return
|
|
636
|
+
$[165] = contextValue;
|
|
637
|
+
$[166] = t61;
|
|
638
|
+
$[167] = t62;
|
|
639
|
+
} else t62 = $[167];
|
|
640
|
+
return t62;
|
|
627
641
|
};
|
|
628
642
|
function _temp() {
|
|
629
643
|
return true;
|