@progress/kendo-react-grid 11.0.0-develop.6 → 11.0.0-develop.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/GridClientContextReader.js +1 -1
- package/GridClientContextReader.mjs +16 -13
- package/GridClientWrapper.js +1 -1
- package/GridClientWrapper.mjs +419 -421
- package/GridComponent.js +1 -1
- package/GridComponent.mjs +402 -395
- package/VirtualScroll.js +1 -1
- package/VirtualScroll.mjs +65 -107
- package/cells/GridDetailHierarchyCell.js +1 -1
- package/cells/GridDetailHierarchyCell.mjs +4 -4
- package/cells/datacell/GridCell.js +9 -0
- package/cells/datacell/GridCell.mjs +29 -0
- package/cells/datacell/GridCellServer.js +8 -0
- package/cells/datacell/GridCellServer.mjs +27 -0
- package/cells/datacell/GridCellServerContainer.js +9 -0
- package/cells/datacell/GridCellServerContainer.mjs +26 -0
- package/cells/datacell/useCellClientTdProps.js +9 -0
- package/cells/datacell/useCellClientTdProps.mjs +30 -0
- package/cells/datacell/utils.js +8 -0
- package/cells/datacell/utils.mjs +47 -0
- package/cells/detailcell/GridDetailCell.js +9 -0
- package/cells/detailcell/GridDetailCell.mjs +18 -0
- package/cells/detailcell/GridDetailCellServer.js +8 -0
- package/cells/detailcell/GridDetailCellServer.mjs +17 -0
- package/cells/detailcell/GridDetailCellServerContainer.js +9 -0
- package/cells/detailcell/GridDetailCellServerContainer.mjs +19 -0
- package/cells/detailcell/useDetailCellClientTdProps.js +9 -0
- package/cells/detailcell/useDetailCellClientTdProps.mjs +20 -0
- package/cells/detailcell/utils.js +8 -0
- package/cells/detailcell/utils.mjs +20 -0
- package/cells/editcell/GridEditCell.js +9 -0
- package/cells/editcell/GridEditCell.mjs +26 -0
- package/cells/editcell/GridEditCellServer.js +8 -0
- package/cells/editcell/GridEditCellServer.mjs +32 -0
- package/cells/editcell/GridEditCellServerContainer.js +9 -0
- package/cells/editcell/GridEditCellServerContainer.mjs +26 -0
- package/cells/editcell/useEditCellClientTdProps.js +9 -0
- package/cells/editcell/useEditCellClientTdProps.mjs +21 -0
- package/cells/editcell/utils.js +8 -0
- package/cells/editcell/utils.mjs +29 -0
- package/cells/groupcell/GridGroupCell.js +9 -0
- package/cells/groupcell/GridGroupCell.mjs +24 -0
- package/cells/groupcell/GridGroupCellServer.js +8 -0
- package/cells/groupcell/GridGroupCellServer.mjs +44 -0
- package/cells/groupcell/GridGroupCellServerContainer.js +9 -0
- package/cells/groupcell/GridGroupCellServerContainer.mjs +38 -0
- package/cells/groupcell/useGroupCellClientTdProps.js +9 -0
- package/cells/groupcell/useGroupCellClientTdProps.mjs +44 -0
- package/cells/groupcell/utils.js +8 -0
- package/cells/groupcell/utils.mjs +48 -0
- package/cells/hierarchycell/GridHierarchyCell.js +9 -0
- package/cells/hierarchycell/GridHierarchyCell.mjs +25 -0
- package/cells/hierarchycell/GridHierarchyCellServer.js +8 -0
- package/cells/hierarchycell/GridHierarchyCellServer.mjs +32 -0
- package/cells/hierarchycell/GridHierarchyCellServerContainer.js +9 -0
- package/cells/hierarchycell/GridHierarchyCellServerContainer.mjs +26 -0
- package/cells/hierarchycell/useHierarchyCellClientTdProps.js +9 -0
- package/cells/hierarchycell/useHierarchyCellClientTdProps.mjs +35 -0
- package/cells/hierarchycell/utils.js +8 -0
- package/cells/hierarchycell/utils.mjs +30 -0
- package/cells/hooks.js +9 -0
- package/cells/hooks.mjs +41 -0
- package/cells/rowreordercell/GridRowReorderCell.js +9 -0
- package/cells/rowreordercell/GridRowReorderCell.mjs +19 -0
- package/cells/rowreordercell/GridRowReorderCellServer.js +8 -0
- package/cells/rowreordercell/GridRowReorderCellServer.mjs +18 -0
- package/cells/rowreordercell/GridRowReorderCellServerContainer.js +9 -0
- package/cells/rowreordercell/GridRowReorderCellServerContainer.mjs +19 -0
- package/cells/rowreordercell/useRowReorderCellClientTdProps.js +9 -0
- package/cells/rowreordercell/useRowReorderCellClientTdProps.mjs +26 -0
- package/cells/rowreordercell/utils.js +8 -0
- package/cells/rowreordercell/utils.mjs +30 -0
- package/cells/selectioncell/GridSelectionCell.js +9 -0
- package/cells/selectioncell/GridSelectionCell.mjs +26 -0
- package/cells/selectioncell/GridSelectionCellServer.js +8 -0
- package/cells/selectioncell/GridSelectionCellServer.mjs +33 -0
- package/cells/selectioncell/GridSelectionCellServerContainer.js +9 -0
- package/cells/selectioncell/GridSelectionCellServerContainer.mjs +26 -0
- package/cells/selectioncell/useSelectionCellClientTdProps.js +9 -0
- package/cells/selectioncell/useSelectionCellClientTdProps.mjs +21 -0
- package/cells/selectioncell/utils.js +8 -0
- package/cells/selectioncell/utils.mjs +25 -0
- package/components/GridDraggableRowsContainer.js +1 -1
- package/components/GridDraggableRowsContainer.mjs +71 -67
- package/components/VirtualScrollHeightContainer.js +1 -1
- package/components/VirtualScrollHeightContainer.mjs +4 -4
- package/components/table/GridTableScrollable.js +1 -1
- package/components/table/GridTableScrollable.mjs +16 -15
- package/components/utils.js +1 -1
- package/components/utils.mjs +9 -10
- package/dist/cdn/js/kendo-react-grid.js +1 -1
- package/index.d.mts +19 -5
- package/index.d.ts +19 -5
- package/index.js +1 -1
- package/index.mjs +5 -5
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +16 -16
- package/utils/index.js +1 -1
- package/utils/index.mjs +112 -104
- package/VirtualScrollFixed.js +0 -8
- package/VirtualScrollFixed.mjs +0 -52
- package/cells/GridCell.js +0 -8
- package/cells/GridCell.mjs +0 -52
- package/cells/GridDetailCell.js +0 -8
- package/cells/GridDetailCell.mjs +0 -26
- package/cells/GridEditCell.js +0 -8
- package/cells/GridEditCell.mjs +0 -35
- package/cells/GridGroupCell.js +0 -8
- package/cells/GridGroupCell.mjs +0 -74
- package/cells/GridHierarchyCell.js +0 -8
- package/cells/GridHierarchyCell.mjs +0 -33
- package/cells/GridRowReorderCell.js +0 -8
- package/cells/GridRowReorderCell.mjs +0 -42
- package/cells/GridSelectionCell.js +0 -8
- package/cells/GridSelectionCell.mjs +0 -30
- package/cells/client/DetailCellContainer.js +0 -9
- package/cells/client/DetailCellContainer.mjs +0 -27
- package/cells/client/GridCellContainer.js +0 -9
- package/cells/client/GridCellContainer.mjs +0 -69
- package/cells/client/GridEditCellContainer.js +0 -9
- package/cells/client/GridEditCellContainer.mjs +0 -61
- package/cells/client/GridGroupCellContainer.js +0 -9
- package/cells/client/GridGroupCellContainer.mjs +0 -88
- package/cells/client/GridHierarchyCellContainer.js +0 -9
- package/cells/client/GridHierarchyCellContainer.mjs +0 -64
- package/cells/client/GridRowReorderContainer.js +0 -9
- package/cells/client/GridRowReorderContainer.mjs +0 -31
- package/cells/client/GridSelectionCellContainer.js +0 -9
- package/cells/client/GridSelectionCellContainer.mjs +0 -61
- /package/cells/{client → editcell}/GridEditCellEditor.js +0 -0
- /package/cells/{client → editcell}/GridEditCellEditor.mjs +0 -0
- /package/cells/{client → groupcell}/GridGroupCellToggle.js +0 -0
- /package/cells/{client → groupcell}/GridGroupCellToggle.mjs +0 -0
- /package/cells/{client → hierarchycell}/GridHierarchyCellToggle.js +0 -0
- /package/cells/{client → hierarchycell}/GridHierarchyCellToggle.mjs +0 -0
- /package/cells/{client → selectioncell}/GridSelectionCellInput.js +0 -0
- /package/cells/{client → selectioncell}/GridSelectionCellInput.mjs +0 -0
package/GridComponent.mjs
CHANGED
|
@@ -6,121 +6,126 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
import * as l from "react";
|
|
9
|
-
import { uGrid as
|
|
10
|
-
import { process as
|
|
11
|
-
import { combineFilters as
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import { GridDetailCell as rl } from "./cells/GridDetailCell.mjs";
|
|
9
|
+
import { uGrid as Nt, validatePackage as Ft, getter as H, classNames as f, WatermarkOverlay as $e } from "@progress/kendo-react-common";
|
|
10
|
+
import { process as Dt } from "@progress/kendo-data-query";
|
|
11
|
+
import { combineFilters as Tt, getDetailExpandableOptions as Pt, getGroupExpandableOptions as Ht, getSelectionOptions as Kt, tableKeyboardNavigationTools as O, Pager as At, tableKeyboardNavigationBodyAttributes as Bt, tableKeyboardNavigationScopeAttributes as je } from "@progress/kendo-react-data-tools";
|
|
12
|
+
import { GridHierarchyCell as Lt } from "./cells/hierarchycell/GridHierarchyCell.mjs";
|
|
13
|
+
import { GridEditCell as Mt } from "./cells/editcell/GridEditCell.mjs";
|
|
14
|
+
import { Header as Ot } from "./header/Header.mjs";
|
|
15
|
+
import { HeaderRow as zt } from "./header/HeaderRow.mjs";
|
|
16
|
+
import { FilterRow as _t } from "./header/FilterRow.mjs";
|
|
17
|
+
import { GroupPanel as Vt } from "./header/GroupPanel.mjs";
|
|
18
|
+
import { Footer as Wt } from "./footer/Footer.mjs";
|
|
19
|
+
import { isRowReorderEnabled as $t, getRowSpanOptions as Ue, getColumnWidth as re, isSorted as qe, flatData as jt, autoGenerateColumns as Ut, mapColumns as qt, clientColumn as Jt, getFlatColumnsState as Qt, getColumnState as ie, getColSpan as Xt, getNestedValue as Je, resolveCells as Yt, isClientReference as Zt, readColumns as pt } from "./utils/index.mjs";
|
|
20
|
+
import { GridCell as el } from "./cells/datacell/GridCell.mjs";
|
|
21
|
+
import { GridGroupCell as Qe } from "./cells/groupcell/GridGroupCell.mjs";
|
|
22
|
+
import { GridRow as tl } from "./rows/GridRow.mjs";
|
|
23
|
+
import { GridHeaderSelectionCell as ll } from "./header/GridHeaderSelectionCell.mjs";
|
|
24
|
+
import { GridNoRecords as Xe } from "./components/noRecords/GridNoRecords.mjs";
|
|
25
|
+
import { operators as Ye } from "./filterCommon.mjs";
|
|
26
|
+
import { FooterRow as al } from "./footer/FooterRow.mjs";
|
|
27
|
+
import { normalize as nl } from "./paging/GridPagerSettings.mjs";
|
|
28
|
+
import { packageMetadata as rl } from "./package-metadata.mjs";
|
|
29
|
+
import { GridDetailCell as il } from "./cells/detailcell/GridDetailCell.mjs";
|
|
31
30
|
import { GridDetailHierarchyCell as ol } from "./cells/GridDetailHierarchyCell.mjs";
|
|
32
|
-
import { GridNoRecordsContainer as
|
|
33
|
-
import { GridClientWrapper as
|
|
34
|
-
import { GridColGroup as
|
|
35
|
-
import { GridTable as
|
|
36
|
-
import { GridDropClue as
|
|
37
|
-
import { GridDragClue as
|
|
38
|
-
import { GridTableBody as
|
|
39
|
-
import { PagerContainer as
|
|
40
|
-
import { GridTableScrollable as
|
|
41
|
-
import { GridElementContainer as
|
|
42
|
-
import { GridContainerElementContainer as
|
|
43
|
-
import { VirtualScrollHeightContainer as
|
|
44
|
-
import { gridAriaLabel as
|
|
45
|
-
import { VirtualScrollFixed as q } from "./VirtualScrollFixed.mjs";
|
|
46
|
-
import { VirtualScroll as gl } from "./VirtualScroll.mjs";
|
|
31
|
+
import { GridNoRecordsContainer as Ze } from "./components/noRecords/GridNoRecordsContainer.mjs";
|
|
32
|
+
import { GridClientWrapper as pe } from "./GridClientWrapper.mjs";
|
|
33
|
+
import { GridColGroup as dl } from "./components/colGroup/GridColGroup.mjs";
|
|
34
|
+
import { GridTable as cl } from "./components/table/GridTable.mjs";
|
|
35
|
+
import { GridDropClue as et } from "./components/GridDropClue.mjs";
|
|
36
|
+
import { GridDragClue as tt } from "./components/GridDragClue.mjs";
|
|
37
|
+
import { GridTableBody as lt } from "./components/table/GridTableBody.mjs";
|
|
38
|
+
import { PagerContainer as ml } from "./components/PagerContainer.mjs";
|
|
39
|
+
import { GridTableScrollable as ul } from "./components/table/GridTableScrollable.mjs";
|
|
40
|
+
import { GridElementContainer as at } from "./components/GridElementContainer.mjs";
|
|
41
|
+
import { GridContainerElementContainer as sl } from "./components/GridContainerElementContainer.mjs";
|
|
42
|
+
import { VirtualScrollHeightContainer as fl } from "./components/VirtualScrollHeightContainer.mjs";
|
|
43
|
+
import { gridAriaLabel as nt, messages as gl } from "./messages/index.mjs";
|
|
47
44
|
import { GridCustomCellClientContainer as bl } from "./components/GridCustomCellClientContainer.mjs";
|
|
48
|
-
import { GridReorderableRowsContainer as
|
|
49
|
-
import { GridRowReorderCell as
|
|
50
|
-
import { GridHeaderRowReorderCell as
|
|
51
|
-
import { GridLoader as
|
|
52
|
-
import { gridPremiumFeatures as
|
|
45
|
+
import { GridReorderableRowsContainer as Cl } from "./components/GridDraggableRowsContainer.mjs";
|
|
46
|
+
import { GridRowReorderCell as hl } from "./cells/rowreordercell/GridRowReorderCell.mjs";
|
|
47
|
+
import { GridHeaderRowReorderCell as yl } from "./header/client/GridHeaderRowReorderCell.mjs";
|
|
48
|
+
import { GridLoader as rt } from "./components/GridLoader.mjs";
|
|
49
|
+
import { gridPremiumFeatures as wl } from "./utils/premium.mjs";
|
|
53
50
|
import { LocalizationService as El, IntlService as Il } from "@progress/kendo-react-intl";
|
|
54
51
|
import { getVirtualCellsToRender as Sl } from "./utils/virtualColumns.mjs";
|
|
55
52
|
import { GridEditDialog as Rl } from "./components/GridEditDialog.mjs";
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
53
|
+
import { GridCellServer as vl } from "./cells/datacell/GridCellServer.mjs";
|
|
54
|
+
import { GridEditCellServer as xl } from "./cells/editcell/GridEditCellServer.mjs";
|
|
55
|
+
import { GridSelectionCellServer as Gl } from "./cells/selectioncell/GridSelectionCellServer.mjs";
|
|
56
|
+
import { GridSelectionCell as kl } from "./cells/selectioncell/GridSelectionCell.mjs";
|
|
57
|
+
import { GridHierarchyCellServer as Nl } from "./cells/hierarchycell/GridHierarchyCellServer.mjs";
|
|
58
|
+
import { GridRowReorderCellServer as Fl } from "./cells/rowreordercell/GridRowReorderCellServer.mjs";
|
|
59
|
+
import { GridDetailCellServer as Dl } from "./cells/detailcell/GridDetailCellServer.mjs";
|
|
60
|
+
import { GridGroupCellServer as Tl } from "./cells/groupcell/GridGroupCellServer.mjs";
|
|
61
|
+
const Pl = l.forwardRef((e, oe) => {
|
|
62
|
+
var De, Te, Pe, He, Ke, Ae, Be, Le, Me, Oe, ze, _e;
|
|
63
|
+
const G = e.id + "-role-element-id", k = e.navigatable ? G : "";
|
|
64
|
+
let S = e.columnsState || [];
|
|
65
|
+
const it = (t, i, r, c, o, d, a, m) => {
|
|
66
|
+
const w = [], n = jt(
|
|
67
|
+
w,
|
|
64
68
|
t,
|
|
69
|
+
i,
|
|
65
70
|
{ index: r },
|
|
66
|
-
|
|
71
|
+
c !== void 0,
|
|
67
72
|
o,
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
73
|
+
d,
|
|
74
|
+
a,
|
|
75
|
+
Et.defaultExpand,
|
|
76
|
+
m
|
|
72
77
|
);
|
|
73
|
-
return { flattedData:
|
|
74
|
-
},
|
|
75
|
-
const
|
|
76
|
-
(
|
|
78
|
+
return { flattedData: w, resolvedGroupsCount: n };
|
|
79
|
+
}, ot = (t) => {
|
|
80
|
+
const i = t.filter(
|
|
81
|
+
(r) => r && r.type && r.type.displayName === "KendoReactGridColumn"
|
|
77
82
|
);
|
|
78
|
-
return
|
|
79
|
-
},
|
|
80
|
-
const t = [],
|
|
81
|
-
const
|
|
83
|
+
return pt(i, S, { prevId: 0, idPrefix: k });
|
|
84
|
+
}, dt = () => {
|
|
85
|
+
const t = [], i = (r, c) => r == null ? void 0 : r.forEach((o) => {
|
|
86
|
+
const d = o.hidden || c;
|
|
82
87
|
t.push({
|
|
83
|
-
...
|
|
84
|
-
hidden:
|
|
85
|
-
}),
|
|
88
|
+
...o,
|
|
89
|
+
hidden: d
|
|
90
|
+
}), i(o.children, d);
|
|
86
91
|
});
|
|
87
|
-
return
|
|
88
|
-
},
|
|
89
|
-
const
|
|
90
|
-
return t.filter((
|
|
91
|
-
var
|
|
92
|
-
return !
|
|
92
|
+
return i(S, !1), t;
|
|
93
|
+
}, ct = (t) => {
|
|
94
|
+
const i = dt();
|
|
95
|
+
return t.filter((r) => {
|
|
96
|
+
var c;
|
|
97
|
+
return !r.hidden && !((c = i.find((o) => o.id === r.id)) != null && c.hidden);
|
|
93
98
|
});
|
|
94
|
-
},
|
|
95
|
-
var
|
|
96
|
-
u =
|
|
99
|
+
}, mt = (t, i) => {
|
|
100
|
+
var r;
|
|
101
|
+
u = ot(t), u.filter((c) => !c.hidden).length === 0 && (u = Ut(
|
|
97
102
|
y,
|
|
98
103
|
e.group,
|
|
99
104
|
{
|
|
100
|
-
column: (
|
|
105
|
+
column: (r = K.column) != null ? r : e.expandField
|
|
101
106
|
},
|
|
102
107
|
{
|
|
103
108
|
prevId: 0,
|
|
104
|
-
idPrefix:
|
|
109
|
+
idPrefix: k
|
|
105
110
|
}
|
|
106
|
-
)),
|
|
107
|
-
},
|
|
108
|
-
const
|
|
109
|
-
var
|
|
110
|
-
const
|
|
111
|
-
return
|
|
111
|
+
)), st(u, i), u = ct(u), N = qt(u, !0), me = u.map(Jt);
|
|
112
|
+
}, ut = (t, i) => {
|
|
113
|
+
const r = (c) => {
|
|
114
|
+
var d;
|
|
115
|
+
const o = i.find((a) => a.id === c.id);
|
|
116
|
+
return o ? (o.children = (d = c.children) == null ? void 0 : d.map(r), o) : ie(c);
|
|
112
117
|
};
|
|
113
|
-
|
|
114
|
-
},
|
|
115
|
-
var
|
|
118
|
+
S = t.filter((c) => c.parentIndex === -1).map(r);
|
|
119
|
+
}, st = (t, i) => {
|
|
120
|
+
var d;
|
|
116
121
|
t.filter((a) => e.selectedField && a.field === e.selectedField || a.columnType === "checkbox").forEach((a) => {
|
|
117
|
-
a.width = a.width || "50px", a.
|
|
118
|
-
}),
|
|
119
|
-
a.width = a.width || "50px", a.
|
|
122
|
+
a.width = a.width || "50px", a.defaultCell = e.isClient ? kl : Gl, a._type = "edit", a.headerCell = a.headerCell || ll;
|
|
123
|
+
}), D !== void 0 && t.filter((a) => a.columnType === "reorder").forEach((a) => {
|
|
124
|
+
a.width = a.width || "50px", a.defaultCell = e.isClient ? hl : Fl, a.headerCell = a.headerCell || yl, a.sortable = !1, a.filterable = !1, a.editable = !1;
|
|
120
125
|
});
|
|
121
|
-
const
|
|
122
|
-
|
|
123
|
-
const
|
|
126
|
+
const r = Qt(S);
|
|
127
|
+
ut(t, r);
|
|
128
|
+
const c = {
|
|
124
129
|
id: "",
|
|
125
130
|
resizable: !0,
|
|
126
131
|
width: "32px",
|
|
@@ -140,189 +145,197 @@ const vl = l.forwardRef((e, ie) => {
|
|
|
140
145
|
ariaColumnIndex: 0,
|
|
141
146
|
isAccessible: !0
|
|
142
147
|
};
|
|
143
|
-
let
|
|
148
|
+
let o = 0;
|
|
144
149
|
if ((e.expandField || K.enabled) && e.detail) {
|
|
145
150
|
const a = {
|
|
146
|
-
...
|
|
151
|
+
...c,
|
|
147
152
|
_type: "expand",
|
|
148
|
-
id:
|
|
149
|
-
|
|
150
|
-
field: (
|
|
153
|
+
id: O.generateNavigatableId(`${o++}`, "expand", "column"),
|
|
154
|
+
defaultCell: e.isClient ? Lt : Nl,
|
|
155
|
+
field: (d = K.column) != null ? d : e.expandField,
|
|
151
156
|
headerClassName: f(s.hierarchyCell({}))
|
|
152
157
|
};
|
|
153
|
-
t.unshift(a),
|
|
158
|
+
t.unshift(a), S.unshift(r.find((m) => m.id === a.id) || ie(a));
|
|
154
159
|
}
|
|
155
|
-
for (let a = 0; a <
|
|
160
|
+
for (let a = 0; a < i; a++) {
|
|
156
161
|
const m = {
|
|
157
|
-
...
|
|
162
|
+
...c,
|
|
158
163
|
isAccessible: !1,
|
|
159
|
-
|
|
160
|
-
id:
|
|
164
|
+
defaultCell: e.isClient ? Qe : Tl,
|
|
165
|
+
id: O.generateNavigatableId(`${o++}`, "group", "column"),
|
|
161
166
|
field: "value",
|
|
162
167
|
locked: e.lockGroups
|
|
163
168
|
};
|
|
164
|
-
t.unshift(m),
|
|
169
|
+
t.unshift(m), S.unshift(r.find((w) => w.id === m.id) || ie(m));
|
|
165
170
|
}
|
|
166
|
-
t.slice(
|
|
167
|
-
a.parentIndex >= 0 && (a.parentIndex +=
|
|
171
|
+
t.slice(o).forEach((a) => {
|
|
172
|
+
a.parentIndex >= 0 && (a.parentIndex += o), a.rowSpannable = a.rowSpannable !== void 0 ? Ue(a.rowSpannable) : fe;
|
|
168
173
|
});
|
|
169
|
-
},
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
const r = [];
|
|
177
|
-
let d = null, o = 0;
|
|
178
|
-
if (b.forEach((i, c) => {
|
|
179
|
-
const a = parseFloat((i.width || "").toString()) || 10;
|
|
180
|
-
if (o) {
|
|
181
|
-
o--, d && (d.width += a);
|
|
174
|
+
}, U = () => e.isClient ? u : me, de = (t) => {
|
|
175
|
+
const i = [];
|
|
176
|
+
let r = null, c = 0;
|
|
177
|
+
if (g.forEach((o, d) => {
|
|
178
|
+
const a = parseFloat((o.width || "").toString()) || 10;
|
|
179
|
+
if (c) {
|
|
180
|
+
c--, r && (r.width += a);
|
|
182
181
|
return;
|
|
183
182
|
}
|
|
184
|
-
const m = Math.min(
|
|
185
|
-
|
|
183
|
+
const m = Math.min(Xt(o, t), g.length - d);
|
|
184
|
+
c = m - 1, r = {
|
|
186
185
|
width: a,
|
|
187
186
|
colSpan: m,
|
|
188
|
-
columnIndex:
|
|
189
|
-
},
|
|
187
|
+
columnIndex: d
|
|
188
|
+
}, i.push(r);
|
|
190
189
|
}), e.columnVirtualization) {
|
|
191
|
-
const
|
|
190
|
+
const o = gt.current || 0, d = bt.current || parseFloat(((e.style || {}).width || "").toString());
|
|
192
191
|
return Sl({
|
|
193
|
-
cellModels:
|
|
194
|
-
columns:
|
|
195
|
-
tableViewPortWidth:
|
|
196
|
-
scrollLeft:
|
|
192
|
+
cellModels: i,
|
|
193
|
+
columns: g,
|
|
194
|
+
tableViewPortWidth: d,
|
|
195
|
+
scrollLeft: o
|
|
197
196
|
});
|
|
198
197
|
}
|
|
199
|
-
return
|
|
198
|
+
return i;
|
|
199
|
+
}, ft = () => {
|
|
200
|
+
const { pageable: t, take: i, pageSize: r } = e;
|
|
201
|
+
if (!h)
|
|
202
|
+
return 0;
|
|
203
|
+
if (!t) {
|
|
204
|
+
if (i)
|
|
205
|
+
return i;
|
|
206
|
+
if (r)
|
|
207
|
+
return r;
|
|
208
|
+
}
|
|
209
|
+
const c = e.rowHeight || ht.current, o = Ct.current;
|
|
210
|
+
return o && c ? Math.ceil(o / c * 1.5) : 0;
|
|
200
211
|
};
|
|
201
|
-
let
|
|
202
|
-
const
|
|
212
|
+
let b = [], ce, u = [], me = [], N = [[]];
|
|
213
|
+
const gt = e.scrollLeftRef || { current: 0 }, bt = e.widthRef || { current: 0 }, Ct = e.containerHeightRef || { current: 0 }, ht = e.minRowHeightRef || { current: 0 }, z = e.localization || new El(e.language), yt = e.intl || new Il((De = e.locale) != null ? De : "en"), F = e.unstyled, s = F && F.uGrid ? F.uGrid : Nt, D = $t(e.rowReorderable), h = e.scrollable === "virtual", T = e.autoProcessData === !0 ? {
|
|
203
214
|
group: !0,
|
|
204
215
|
sort: !0,
|
|
205
216
|
filter: !0,
|
|
206
217
|
search: !0,
|
|
207
218
|
page: !0
|
|
208
219
|
} : e.autoProcessData;
|
|
209
|
-
let y,
|
|
210
|
-
if (Array.isArray(e.data) ? (y = e.data,
|
|
211
|
-
const { data:
|
|
212
|
-
group:
|
|
213
|
-
sort:
|
|
214
|
-
filter:
|
|
215
|
-
|
|
216
|
-
|
|
220
|
+
let y, x;
|
|
221
|
+
if (Array.isArray(e.data) ? (y = e.data, x = (Te = e.total) != null ? Te : y.length) : (y = ((Pe = e.data) == null ? void 0 : Pe.data) || [], x = (Ae = (Ke = e.total) != null ? Ke : (He = e.data) == null ? void 0 : He.total) != null ? Ae : y.length), T) {
|
|
222
|
+
const t = T.page && !(h && !e.pageable), { data: i, total: r } = Dt(y, {
|
|
223
|
+
group: T.group ? e.group : void 0,
|
|
224
|
+
sort: T.sort ? e.sort : void 0,
|
|
225
|
+
filter: Tt(
|
|
226
|
+
T.filter ? e.filter : void 0,
|
|
227
|
+
T.search ? e.search : void 0
|
|
217
228
|
),
|
|
218
|
-
...
|
|
219
|
-
take: e.take,
|
|
220
|
-
skip: e.skip
|
|
229
|
+
...t ? {
|
|
230
|
+
take: e.pageable ? e.take || 10 : e.take,
|
|
231
|
+
skip: e.skip || 0
|
|
221
232
|
} : {}
|
|
222
233
|
});
|
|
223
|
-
y =
|
|
234
|
+
y = i, x = (Be = e.total) != null ? Be : r;
|
|
224
235
|
}
|
|
225
|
-
const { size:
|
|
236
|
+
const _ = y.length === x, { size: R = "medium" } = e, wt = typeof e.groupable == "object" && e.groupable.footer || "none", V = e.groupable === !0 || typeof e.groupable == "object" && e.groupable.enabled !== !1, K = Pt(!!e.detail), Et = Ht(
|
|
226
237
|
typeof e.groupable == "object" && e.groupable.enabled !== !1 ? e.groupable.expandable : e.groupable
|
|
227
|
-
), { resolvedGroupsCount:
|
|
238
|
+
), ue = !!((Le = e.group) != null && Le.length), { resolvedGroupsCount: It, flattedData: St } = it(
|
|
239
|
+
y,
|
|
228
240
|
wt,
|
|
229
|
-
e.skip || 0,
|
|
241
|
+
_ ? 0 : e.skip || 0,
|
|
230
242
|
e.group,
|
|
231
243
|
e.expandField,
|
|
232
244
|
e.detailExpand,
|
|
233
245
|
e.groupExpand,
|
|
234
246
|
e.dataItemKey
|
|
235
247
|
);
|
|
236
|
-
|
|
237
|
-
const
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
248
|
+
b = St;
|
|
249
|
+
const q = ft(), J = ((Me = e.virtualSkipRef) == null ? void 0 : Me.current) || 0;
|
|
250
|
+
let Q = x;
|
|
251
|
+
if (h) {
|
|
252
|
+
let t = e.skip || 0;
|
|
253
|
+
(ue || e.pageable) && (t = J, Q = b.length), (_ || ue || e.pageable) && (ce = b.slice(t, t + q));
|
|
254
|
+
}
|
|
255
|
+
const se = Kt(e.selectable || !!e.selectedField), fe = Ue(e.rowSpannable), Rt = se && se.drag ? "none" : void 0, W = l.useMemo(() => l.Children.toArray(e.children), [e.children]);
|
|
256
|
+
mt(W, It);
|
|
257
|
+
const X = l.useMemo(() => {
|
|
258
|
+
const t = wl(e, u);
|
|
246
259
|
return {
|
|
247
260
|
premium: t.length > 0,
|
|
248
261
|
features: t
|
|
249
262
|
};
|
|
250
|
-
}, [e, u]),
|
|
263
|
+
}, [e, u]), ge = l.useMemo(() => X.premium ? !Ft(rl, { component: "Grid", features: X.features }) : !1, [X.premium]), be = W.map((t) => t && t.type && t.type.displayName === "KendoReactGridToolbar" ? l.cloneElement(t, { ...t.props, ariaControls: G }) : null), $ = W.filter((t) => t && t.type && t.type.displayName === "KendoReactGridNoRecords"), Ce = W.filter(
|
|
251
264
|
(t) => t && t.type && t.type.displayName === "KendoReactGridStatusBar"
|
|
252
|
-
),
|
|
253
|
-
|
|
265
|
+
), g = u.filter((t) => t.children.length === 0), he = V && /* @__PURE__ */ l.createElement(Vt, { columns: U(), group: e.group || [], ariaControls: G }), ye = /* @__PURE__ */ l.createElement(
|
|
266
|
+
Ot,
|
|
254
267
|
{
|
|
255
|
-
size:
|
|
268
|
+
size: R,
|
|
256
269
|
staticHeaders: e.scrollable !== "none",
|
|
257
|
-
draggable: e.reorderable ||
|
|
270
|
+
draggable: e.reorderable || V,
|
|
258
271
|
headerRow: /* @__PURE__ */ l.createElement(
|
|
259
|
-
|
|
272
|
+
zt,
|
|
260
273
|
{
|
|
261
274
|
cells: e.cells,
|
|
262
275
|
sort: e.sort,
|
|
263
276
|
sortable: e.sortable,
|
|
264
277
|
group: e.group || [],
|
|
265
|
-
groupable:
|
|
278
|
+
groupable: V,
|
|
266
279
|
filter: e.filter,
|
|
267
280
|
filterable: e.filterable,
|
|
268
|
-
filterOperators: e.filterOperators ||
|
|
281
|
+
filterOperators: e.filterOperators || Ye,
|
|
269
282
|
columnMenu: e.columnMenu,
|
|
270
283
|
columnMenuIcon: e.columnMenuIcon,
|
|
271
284
|
columns: u,
|
|
272
|
-
columnsMap:
|
|
285
|
+
columnsMap: N,
|
|
273
286
|
cellRender: e.headerCellRender,
|
|
274
287
|
navigatable: !!e.navigatable,
|
|
275
|
-
localization:
|
|
276
|
-
unstyled:
|
|
277
|
-
headerSelectionValue: !!(e.select &&
|
|
278
|
-
(t) => e.select && e.dataItemKey &&
|
|
288
|
+
localization: z,
|
|
289
|
+
unstyled: F,
|
|
290
|
+
headerSelectionValue: !!(e.select && b.filter((t) => t.rowType === "data").every(
|
|
291
|
+
(t) => e.select && e.dataItemKey && H(e.dataItemKey)(t.dataItem) !== void 0 ? e.select[H(e.dataItemKey)(t.dataItem)] : void 0
|
|
279
292
|
))
|
|
280
293
|
}
|
|
281
294
|
),
|
|
282
295
|
filterRow: e.filterable && /* @__PURE__ */ l.createElement(
|
|
283
|
-
|
|
296
|
+
_t,
|
|
284
297
|
{
|
|
285
298
|
cells: e.cells,
|
|
286
|
-
size:
|
|
299
|
+
size: R,
|
|
287
300
|
columns: u,
|
|
288
301
|
filter: e.filter,
|
|
289
|
-
filterOperators: e.filterOperators ||
|
|
302
|
+
filterOperators: e.filterOperators || Ye,
|
|
290
303
|
sort: e.sort,
|
|
291
304
|
cellRender: e.filterCellRender,
|
|
292
305
|
navigatable: !!e.navigatable,
|
|
293
|
-
ariaRowIndex:
|
|
294
|
-
localization:
|
|
306
|
+
ariaRowIndex: N.length + 1,
|
|
307
|
+
localization: z
|
|
295
308
|
}
|
|
296
309
|
) || void 0,
|
|
297
|
-
cols:
|
|
310
|
+
cols: g.map((t, i) => /* @__PURE__ */ l.createElement("col", { key: i.toString(), width: re(t) }))
|
|
298
311
|
}
|
|
299
|
-
),
|
|
300
|
-
let
|
|
301
|
-
|
|
302
|
-
const
|
|
303
|
-
let
|
|
304
|
-
const a = e.selectedField ?
|
|
305
|
-
return
|
|
306
|
-
row:
|
|
307
|
-
var
|
|
308
|
-
const n =
|
|
309
|
-
let
|
|
310
|
-
if ((
|
|
311
|
-
const
|
|
312
|
-
|
|
312
|
+
), we = g.findIndex((t) => typeof t.colSpan == "function") > -1;
|
|
313
|
+
let Y;
|
|
314
|
+
we || (Y = de(null));
|
|
315
|
+
const Z = ((Oe = e.editable) == null ? void 0 : Oe.mode) === "dialog", vt = (ze = e.editable) == null ? void 0 : ze.enabled, xt = (t, i, r, c, o) => {
|
|
316
|
+
let d = !1;
|
|
317
|
+
const a = e.selectedField ? Je(e.selectedField, t.dataItem) : e.select && e.dataItemKey && H(e.dataItemKey)(t.dataItem) !== void 0 ? e.select[H(e.dataItemKey)(t.dataItem)] : void 0;
|
|
318
|
+
return we && (Y = de(t.dataItem)), {
|
|
319
|
+
row: Y.map(({ columnIndex: m, colSpan: w }) => {
|
|
320
|
+
var j, M, Ve, We;
|
|
321
|
+
const n = g[m];
|
|
322
|
+
let E;
|
|
323
|
+
if ((j = n.rowSpannable) != null && j.enabled && t.rowType === "data" && n.field && o) {
|
|
324
|
+
const v = n.field ? (Ve = (M = n.rowSpannable).valueGetter) == null ? void 0 : Ve.call(M, t.dataItem, n.field) : null;
|
|
325
|
+
E = { value: v, count: 1 }, o[n.field] && ((We = o[n.field]) == null ? void 0 : We.value) === v && o[n.field] !== null ? (o[n.field].count++, E.count = null) : o[n.field] = E;
|
|
313
326
|
}
|
|
314
|
-
const
|
|
315
|
-
let
|
|
327
|
+
const P = n.id ? n.id : m, I = f(s.contentSticky({ locked: n.locked }), n.className), le = n.left !== void 0 ? { left: n.left, right: n.right } : {};
|
|
328
|
+
let B = !1;
|
|
316
329
|
if (n.editable && (e.editable || e.editField)) {
|
|
317
|
-
const
|
|
318
|
-
ne && n.columnType === "data" && (ne === !0 || ne === n.field) && (
|
|
330
|
+
const v = e.editField ? Je(e.editField, t.dataItem) : e.edit && e.dataItemKey ? e.edit[H(e.dataItemKey)(t.dataItem)] : void 0, ne = typeof v == "boolean" ? v : Array.isArray(v) ? v.indexOf(n.field) > -1 : n.field !== void 0 && v === n.field;
|
|
331
|
+
ne && n.columnType === "data" && (ne === !0 || ne === n.field) && (d = !0, Z || (B = !0));
|
|
319
332
|
}
|
|
320
|
-
const
|
|
333
|
+
const ae = e.expandField && e.detail && n.field === e.expandField || n._type === "expand", C = {
|
|
321
334
|
locked: e.lockGroups,
|
|
322
|
-
id:
|
|
323
|
-
`${
|
|
324
|
-
|
|
325
|
-
|
|
335
|
+
id: O.generateNavigatableId(
|
|
336
|
+
`${i}-${String(m)}`,
|
|
337
|
+
k,
|
|
338
|
+
ae || t.rowType === "groupHeader" || t.rowType === "groupFooter" || n.field === "value" ? "nodata" : "cell"
|
|
326
339
|
),
|
|
327
340
|
colSpan: w,
|
|
328
341
|
dataItem: t.dataItem,
|
|
@@ -330,143 +343,140 @@ const vl = l.forwardRef((e, ie) => {
|
|
|
330
343
|
editor: n.editor,
|
|
331
344
|
format: n.format,
|
|
332
345
|
columnType: n.columnType,
|
|
333
|
-
rowReorderable:
|
|
334
|
-
className:
|
|
346
|
+
rowReorderable: D,
|
|
347
|
+
className: I,
|
|
335
348
|
render: e.cellRender,
|
|
336
|
-
cells:
|
|
349
|
+
cells: Yt(e.cells, n.cells),
|
|
337
350
|
columnIndex: m,
|
|
338
|
-
columnsCount:
|
|
351
|
+
columnsCount: g.length,
|
|
339
352
|
rowType: t.rowType,
|
|
340
353
|
level: t.level,
|
|
341
354
|
expanded: t.expanded,
|
|
342
355
|
dataIndex: t.dataIndex,
|
|
343
|
-
rowDataIndex:
|
|
344
|
-
columnPosition:
|
|
356
|
+
rowDataIndex: r,
|
|
357
|
+
columnPosition: le,
|
|
345
358
|
style: {},
|
|
346
359
|
ariaColumnIndex: n.ariaColumnIndex,
|
|
347
360
|
isSelected: (n == null ? void 0 : n._type) === "edit" ? a : Array.isArray(a) && a.indexOf(m) > -1,
|
|
348
|
-
isSorted: !!
|
|
349
|
-
isInEdit:
|
|
350
|
-
isAlt:
|
|
351
|
-
unstyled:
|
|
361
|
+
isSorted: !!qe(n.field, e.sort),
|
|
362
|
+
isInEdit: B,
|
|
363
|
+
isAlt: c,
|
|
364
|
+
unstyled: F,
|
|
352
365
|
group: t.group,
|
|
353
|
-
localization:
|
|
366
|
+
localization: z,
|
|
354
367
|
intl: yt,
|
|
355
|
-
_rowSpan:
|
|
368
|
+
_rowSpan: E
|
|
356
369
|
};
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
370
|
+
if (n.cell)
|
|
371
|
+
return /* @__PURE__ */ l.createElement(
|
|
372
|
+
bl,
|
|
373
|
+
{
|
|
374
|
+
key: P,
|
|
375
|
+
isClient: Zt(n.cell),
|
|
376
|
+
dataItem: C.dataItem,
|
|
377
|
+
rowDataIndex: C.rowDataIndex,
|
|
378
|
+
columnIndex: C.columnIndex,
|
|
379
|
+
columnPosition: C.columnPosition
|
|
380
|
+
},
|
|
381
|
+
/* @__PURE__ */ l.createElement(n.cell, { ...C })
|
|
382
|
+
);
|
|
383
|
+
const L = n.defaultCell || B && (e.isClient ? Mt : xl) || (e.isClient ? el : vl);
|
|
384
|
+
return /* @__PURE__ */ l.createElement(L, { key: P, cellProps: C });
|
|
369
385
|
}),
|
|
370
|
-
isInEdit:
|
|
386
|
+
isInEdit: d,
|
|
371
387
|
isSelected: typeof a == "boolean" && a
|
|
372
388
|
};
|
|
373
389
|
};
|
|
374
|
-
let
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
let Ee = e.skip || 0;
|
|
386
|
-
const te = [], Ie = !h.length, Se = G.length + (e.filterable ? 1 : 0) + 1;
|
|
387
|
-
let H = 0;
|
|
388
|
-
if (h.length) {
|
|
389
|
-
let t = -1, r = 0;
|
|
390
|
-
const d = ue.enabled ? {} : void 0;
|
|
391
|
-
(M || h).forEach((o, i) => {
|
|
392
|
-
o.rowType === "data" && (Ee++, t++);
|
|
393
|
-
const c = Ee % 2 === 0, a = i + (e.skip || 0), m = e.dataItemKey && A(e.dataItemKey)(o.dataItem), w = m || "ai" + a, n = w + "_1", g = vt(o, w, t, c, d);
|
|
394
|
-
if (H = a + Se + r, p && Rt && g.isInEdit && (ee = o.dataItem), te.push(
|
|
390
|
+
let Gt = 0, p = null;
|
|
391
|
+
const Ee = (t) => t >= b.length - Gt, ee = [], Ie = !b.length;
|
|
392
|
+
let A = 0;
|
|
393
|
+
if (b.length) {
|
|
394
|
+
const t = N.length + (e.filterable ? 1 : 0) + 1;
|
|
395
|
+
let i = e.skip || 0, r = -1, c = 0;
|
|
396
|
+
const o = fe.enabled ? {} : void 0;
|
|
397
|
+
h && (r += J, i += J, e.pageable || (r += e.skip || 0)), (ce || b).forEach((d, a) => {
|
|
398
|
+
d.rowType === "data" && r++;
|
|
399
|
+
const m = d.dataIndex % 2 !== 0, w = e.dataItemKey && H(e.dataItemKey)(d.dataItem), n = a + i, E = w || "ai" + n, P = E + "_1", I = xt(d, E, r, m, o);
|
|
400
|
+
if (A = n + t + c, Z && vt && I.isInEdit && (p = d.dataItem), ee.push(
|
|
395
401
|
/* @__PURE__ */ l.createElement(
|
|
396
|
-
|
|
402
|
+
tl,
|
|
397
403
|
{
|
|
398
|
-
key:
|
|
399
|
-
dataItem:
|
|
400
|
-
isAltRow:
|
|
401
|
-
isInEdit:
|
|
402
|
-
rowType:
|
|
403
|
-
isRowReorderable:
|
|
404
|
-
isHidden:
|
|
404
|
+
key: E,
|
|
405
|
+
dataItem: d.dataItem,
|
|
406
|
+
isAltRow: m,
|
|
407
|
+
isInEdit: I.isInEdit && !Z,
|
|
408
|
+
rowType: d.rowType,
|
|
409
|
+
isRowReorderable: D,
|
|
410
|
+
isHidden: Ee(a),
|
|
405
411
|
onClick: null,
|
|
406
412
|
onDoubleClick: null,
|
|
407
413
|
selectedField: e.selectedField,
|
|
408
414
|
rowHeight: e.rowHeight,
|
|
409
415
|
render: e.rowRender,
|
|
410
|
-
ariaRowIndex:
|
|
411
|
-
absoluteRowIndex:
|
|
412
|
-
dataIndex:
|
|
413
|
-
isSelected:
|
|
416
|
+
ariaRowIndex: A,
|
|
417
|
+
absoluteRowIndex: n,
|
|
418
|
+
dataIndex: r,
|
|
419
|
+
isSelected: I.isSelected,
|
|
414
420
|
rows: e.rows
|
|
415
421
|
},
|
|
416
|
-
|
|
422
|
+
I.row
|
|
417
423
|
)
|
|
418
|
-
), e.detail &&
|
|
419
|
-
const
|
|
420
|
-
|
|
424
|
+
), e.detail && d.rowType === "data" && d.expanded) {
|
|
425
|
+
const le = g.length - (e.expandField || K.enabled ? 1 : 0) - (e.group ? e.group.length : 0) || 1;
|
|
426
|
+
c++, A = n + t + c;
|
|
427
|
+
const B = e.isClient ? il : Dl;
|
|
428
|
+
ee.push(
|
|
421
429
|
/* @__PURE__ */ l.createElement(
|
|
422
430
|
"tr",
|
|
423
431
|
{
|
|
424
|
-
key:
|
|
425
|
-
className: f(s.detailTr({ isAlt:
|
|
432
|
+
key: P,
|
|
433
|
+
className: f(s.detailTr({ isAlt: m })),
|
|
426
434
|
style: {
|
|
427
|
-
visibility:
|
|
435
|
+
visibility: Ee(a) ? "hidden" : "",
|
|
428
436
|
height: e.detailRowHeight
|
|
429
437
|
},
|
|
430
438
|
role: "row",
|
|
431
|
-
"aria-rowindex":
|
|
439
|
+
"aria-rowindex": A
|
|
432
440
|
},
|
|
433
|
-
e.group && e.group.map((ae,
|
|
434
|
-
var
|
|
435
|
-
const
|
|
441
|
+
e.group && e.group.map((ae, C) => {
|
|
442
|
+
var M;
|
|
443
|
+
const L = (M = I == null ? void 0 : I.row[C]) == null ? void 0 : M.props.style, j = L ? { left: L.left, right: L.right } : {};
|
|
436
444
|
return /* @__PURE__ */ l.createElement(
|
|
437
|
-
|
|
445
|
+
Qe,
|
|
438
446
|
{
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
447
|
+
key: C,
|
|
448
|
+
cellProps: {
|
|
449
|
+
id: "",
|
|
450
|
+
dataItem: d.dataItem,
|
|
451
|
+
field: ae.field,
|
|
452
|
+
dataIndex: d.dataIndex,
|
|
453
|
+
columnPosition: j,
|
|
454
|
+
style: {},
|
|
455
|
+
ariaColumnIndex: 1 + C,
|
|
456
|
+
isSelected: !1,
|
|
457
|
+
locked: e.lockGroups,
|
|
458
|
+
cells: e.cells,
|
|
459
|
+
group: d.group
|
|
460
|
+
}
|
|
451
461
|
}
|
|
452
462
|
);
|
|
453
463
|
}),
|
|
454
464
|
(e.expandField || K.enabled) && /* @__PURE__ */ l.createElement(
|
|
455
465
|
ol,
|
|
456
466
|
{
|
|
457
|
-
unstyled:
|
|
458
|
-
id:
|
|
467
|
+
unstyled: F,
|
|
468
|
+
id: O.generateNavigatableId(`${P}-dhcell`, k)
|
|
459
469
|
}
|
|
460
470
|
),
|
|
461
471
|
/* @__PURE__ */ l.createElement(
|
|
462
|
-
|
|
472
|
+
B,
|
|
463
473
|
{
|
|
464
|
-
dataItem:
|
|
465
|
-
dataIndex:
|
|
466
|
-
colSpan:
|
|
474
|
+
dataItem: d.dataItem,
|
|
475
|
+
dataIndex: d.dataIndex,
|
|
476
|
+
colSpan: le,
|
|
467
477
|
ariaColIndex: 2 + (e.group ? e.group.length : 0),
|
|
468
478
|
detail: e.detail,
|
|
469
|
-
id:
|
|
479
|
+
id: O.generateNavigatableId(`${P}-dcell`, k)
|
|
470
480
|
}
|
|
471
481
|
)
|
|
472
482
|
)
|
|
@@ -474,182 +484,179 @@ const vl = l.forwardRef((e, ie) => {
|
|
|
474
484
|
}
|
|
475
485
|
});
|
|
476
486
|
}
|
|
477
|
-
const
|
|
478
|
-
size:
|
|
479
|
-
total:
|
|
487
|
+
const Se = {
|
|
488
|
+
size: R,
|
|
489
|
+
total: x,
|
|
480
490
|
skip: e.skip || 0,
|
|
481
491
|
take: (e.take !== void 0 ? e.take : e.pageSize) || 10,
|
|
482
|
-
...
|
|
483
|
-
},
|
|
484
|
-
var
|
|
485
|
-
return !!(t.footerCell || (
|
|
492
|
+
...nl(e.pageable || {})
|
|
493
|
+
}, Re = /* @__PURE__ */ l.createElement(ml, null, e.pager ? /* @__PURE__ */ l.createElement(e.pager, { ...Se }) : /* @__PURE__ */ l.createElement(At, { className: f(s.pager({})), ...Se })), kt = (t, i) => /* @__PURE__ */ l.createElement("col", { key: i.toString(), width: re(t) }), ve = (_e = e.cells) != null && _e.footerCell || u.some((t) => {
|
|
494
|
+
var i;
|
|
495
|
+
return !!(t.footerCell || (i = t.cells) != null && i.footerCell);
|
|
486
496
|
}) ? /* @__PURE__ */ l.createElement(
|
|
487
|
-
|
|
497
|
+
Wt,
|
|
488
498
|
{
|
|
489
|
-
size:
|
|
499
|
+
size: R,
|
|
490
500
|
staticHeaders: e.scrollable !== "none",
|
|
491
501
|
row: /* @__PURE__ */ l.createElement(
|
|
492
|
-
|
|
502
|
+
al,
|
|
493
503
|
{
|
|
494
504
|
cells: e.cells,
|
|
495
|
-
idPrefix:
|
|
505
|
+
idPrefix: k,
|
|
496
506
|
columns: u,
|
|
497
|
-
ariaRowIndex:
|
|
507
|
+
ariaRowIndex: A + 1
|
|
498
508
|
}
|
|
499
509
|
),
|
|
500
|
-
cols:
|
|
510
|
+
cols: g.map(kt)
|
|
501
511
|
}
|
|
502
|
-
) : null,
|
|
512
|
+
) : null, xe = /* @__PURE__ */ l.createElement(dl, null, g.map((t, i) => /* @__PURE__ */ l.createElement(
|
|
503
513
|
"col",
|
|
504
514
|
{
|
|
505
|
-
key:
|
|
506
|
-
className:
|
|
515
|
+
key: i.toString(),
|
|
516
|
+
className: qe(t.field, e.sort) ? f(s.sorted({})) : void 0,
|
|
507
517
|
width: re(t)
|
|
508
518
|
}
|
|
509
|
-
))),
|
|
519
|
+
))), Ge = e.reorderable || V, { detail: Hl, cells: Kl, rows: Al, ...ke } = e, Ne = /* @__PURE__ */ l.createElement(
|
|
510
520
|
"tbody",
|
|
511
521
|
{
|
|
512
522
|
role: "rowgroup",
|
|
513
523
|
className: f(s.tbody({})),
|
|
514
|
-
...
|
|
524
|
+
...Bt
|
|
515
525
|
},
|
|
516
|
-
|
|
517
|
-
), Fe =
|
|
518
|
-
let
|
|
519
|
-
|
|
520
|
-
|
|
526
|
+
ee
|
|
527
|
+
), Fe = p ? /* @__PURE__ */ l.createElement(Rl, { columns: g, customEditDialog: e.editDialog, dataItem: p }) : null;
|
|
528
|
+
let te = Ne;
|
|
529
|
+
return D && (te = /* @__PURE__ */ l.createElement(
|
|
530
|
+
Cl,
|
|
521
531
|
{
|
|
522
532
|
unstyled: s,
|
|
523
533
|
columns: u,
|
|
524
534
|
rowReorderSettings: e.rowReorderable
|
|
525
535
|
},
|
|
526
|
-
|
|
527
|
-
)), e.scrollable === "none"
|
|
528
|
-
|
|
529
|
-
|
|
536
|
+
Ne
|
|
537
|
+
)), e.scrollable === "none" ? /* @__PURE__ */ l.createElement(
|
|
538
|
+
pe,
|
|
539
|
+
{
|
|
540
|
+
gridRef: oe,
|
|
541
|
+
gridProps: ke,
|
|
542
|
+
columnsRef: U(),
|
|
543
|
+
columnsMapRef: N,
|
|
544
|
+
columnsState: S,
|
|
545
|
+
dataRef: b,
|
|
546
|
+
id: G,
|
|
547
|
+
virtualTotal: Q,
|
|
548
|
+
isAllData: _,
|
|
549
|
+
virtualPageSize: q,
|
|
550
|
+
isVirtualScroll: h,
|
|
551
|
+
detailExpandable: !!e.detail
|
|
552
|
+
},
|
|
553
|
+
/* @__PURE__ */ l.createElement(at, null, /* @__PURE__ */ l.createElement(
|
|
554
|
+
"div",
|
|
530
555
|
{
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
dataRef: h,
|
|
537
|
-
slicedData: M,
|
|
538
|
-
isFixedVirtualScroll: X === q,
|
|
539
|
-
id: v,
|
|
540
|
-
total: S,
|
|
541
|
-
isAllData: O(),
|
|
542
|
-
detailExpandable: !!e.detail
|
|
556
|
+
id: e.id,
|
|
557
|
+
style: e.style,
|
|
558
|
+
className: f(s.wrapper({ size: R }), e.className),
|
|
559
|
+
"aria-label": e.ariaLabel,
|
|
560
|
+
...je
|
|
543
561
|
},
|
|
544
|
-
|
|
545
|
-
|
|
562
|
+
be,
|
|
563
|
+
he,
|
|
564
|
+
/* @__PURE__ */ l.createElement(
|
|
565
|
+
cl,
|
|
546
566
|
{
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
className: f(s.wrapper({ size: E }), e.className),
|
|
550
|
-
"aria-label": e.ariaLabel,
|
|
551
|
-
...Ue
|
|
567
|
+
selectable: e.selectable,
|
|
568
|
+
className: f(s.table({ size: R }))
|
|
552
569
|
},
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
/* @__PURE__ */ l.createElement(
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
)),
|
|
569
|
-
ge,
|
|
570
|
-
e.pageable && ve,
|
|
571
|
-
/* @__PURE__ */ l.createElement(ot, { loader: e.loader, showLoader: e.showLoader }),
|
|
572
|
-
Fe,
|
|
573
|
-
se && /* @__PURE__ */ l.createElement(je, null)
|
|
574
|
-
);
|
|
575
|
-
let $ = e.style || {};
|
|
576
|
-
return F && ($.height || ($ = Object.assign({}, $, { height: "450px" }))), /* @__PURE__ */ l.createElement(
|
|
577
|
-
et,
|
|
570
|
+
xe,
|
|
571
|
+
ye,
|
|
572
|
+
/* @__PURE__ */ l.createElement(lt, { rowReorderable: D }, te),
|
|
573
|
+
ve
|
|
574
|
+
),
|
|
575
|
+
Ie && /* @__PURE__ */ l.createElement(Ze, null, $.length ? $ : /* @__PURE__ */ l.createElement(Xe, null)),
|
|
576
|
+
Ge && /* @__PURE__ */ l.createElement(l.Fragment, null, /* @__PURE__ */ l.createElement(et, null), /* @__PURE__ */ l.createElement(tt, null))
|
|
577
|
+
)),
|
|
578
|
+
Ce,
|
|
579
|
+
e.pageable && Re,
|
|
580
|
+
/* @__PURE__ */ l.createElement(rt, { loader: e.loader, showLoader: e.showLoader }),
|
|
581
|
+
Fe,
|
|
582
|
+
ge && /* @__PURE__ */ l.createElement($e, null)
|
|
583
|
+
) : /* @__PURE__ */ l.createElement(
|
|
584
|
+
pe,
|
|
578
585
|
{
|
|
579
|
-
gridRef:
|
|
580
|
-
gridProps:
|
|
581
|
-
columnsRef:
|
|
582
|
-
columnsMapRef:
|
|
583
|
-
columnsState:
|
|
584
|
-
dataRef:
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
586
|
+
gridRef: oe,
|
|
587
|
+
gridProps: ke,
|
|
588
|
+
columnsRef: U(),
|
|
589
|
+
columnsMapRef: N,
|
|
590
|
+
columnsState: S,
|
|
591
|
+
dataRef: b,
|
|
592
|
+
id: G,
|
|
593
|
+
virtualTotal: Q,
|
|
594
|
+
isAllData: _,
|
|
595
|
+
virtualPageSize: q,
|
|
596
|
+
isVirtualScroll: h,
|
|
590
597
|
detailExpandable: !!e.detail
|
|
591
598
|
},
|
|
592
|
-
/* @__PURE__ */ l.createElement(
|
|
599
|
+
/* @__PURE__ */ l.createElement(at, null, /* @__PURE__ */ l.createElement(
|
|
593
600
|
"div",
|
|
594
601
|
{
|
|
595
602
|
id: e.id,
|
|
596
|
-
style:
|
|
603
|
+
style: e.style,
|
|
597
604
|
className: f(
|
|
598
605
|
s.wrapper({
|
|
599
|
-
size:
|
|
600
|
-
virtual:
|
|
606
|
+
size: R,
|
|
607
|
+
virtual: h
|
|
601
608
|
}),
|
|
602
609
|
e.className
|
|
603
610
|
),
|
|
604
611
|
"aria-label": e.ariaLabel,
|
|
605
|
-
...
|
|
612
|
+
...je
|
|
606
613
|
},
|
|
607
|
-
fe,
|
|
608
614
|
be,
|
|
615
|
+
he,
|
|
609
616
|
/* @__PURE__ */ l.createElement(
|
|
610
617
|
"div",
|
|
611
618
|
{
|
|
612
619
|
className: f(s.ariaRoot({})),
|
|
613
620
|
role: "grid",
|
|
614
|
-
"aria-colcount":
|
|
615
|
-
"aria-rowcount":
|
|
616
|
-
id:
|
|
617
|
-
"aria-label":
|
|
621
|
+
"aria-colcount": g.length,
|
|
622
|
+
"aria-rowcount": x,
|
|
623
|
+
id: G,
|
|
624
|
+
"aria-label": z.toLanguageString(nt, gl[nt])
|
|
618
625
|
},
|
|
619
|
-
|
|
620
|
-
/* @__PURE__ */ l.createElement("div", { className: f(s.container({})), role: "presentation" }, /* @__PURE__ */ l.createElement(
|
|
621
|
-
|
|
626
|
+
ye,
|
|
627
|
+
/* @__PURE__ */ l.createElement("div", { className: f(s.container({})), role: "presentation" }, /* @__PURE__ */ l.createElement(sl, null, /* @__PURE__ */ l.createElement("div", { className: f(s.content({})), role: "presentation" }, /* @__PURE__ */ l.createElement("div", { className: f(s.tableWrap({})), role: "presentation" }, /* @__PURE__ */ l.createElement(
|
|
628
|
+
ul,
|
|
622
629
|
{
|
|
623
630
|
selectable: e.selectable,
|
|
624
631
|
tableClassName: f(
|
|
625
632
|
s.table({
|
|
626
|
-
size:
|
|
633
|
+
size: R
|
|
627
634
|
})
|
|
628
635
|
),
|
|
629
|
-
tableStyle: { userSelect:
|
|
636
|
+
tableStyle: { userSelect: Rt }
|
|
630
637
|
},
|
|
631
|
-
|
|
632
|
-
/* @__PURE__ */ l.createElement(
|
|
633
|
-
), Ie && /* @__PURE__ */ l.createElement(
|
|
638
|
+
xe,
|
|
639
|
+
/* @__PURE__ */ l.createElement(lt, { rowReorderable: D }, te)
|
|
640
|
+
), Ie && /* @__PURE__ */ l.createElement(Ze, null, $.length ? $ : /* @__PURE__ */ l.createElement(Xe, null))), h && /* @__PURE__ */ l.createElement(
|
|
634
641
|
"div",
|
|
635
642
|
{
|
|
636
643
|
className: f(s.heightContainer({})),
|
|
637
644
|
role: "presentation"
|
|
638
645
|
},
|
|
639
|
-
/* @__PURE__ */ l.createElement(
|
|
646
|
+
/* @__PURE__ */ l.createElement(fl, { isVirtualScroll: h })
|
|
640
647
|
)))),
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
648
|
+
ve,
|
|
649
|
+
Ge && /* @__PURE__ */ l.createElement(l.Fragment, null, /* @__PURE__ */ l.createElement(et, null), /* @__PURE__ */ l.createElement(tt, null)),
|
|
650
|
+
ge && /* @__PURE__ */ l.createElement($e, null)
|
|
644
651
|
),
|
|
645
|
-
|
|
646
|
-
e.pageable &&
|
|
647
|
-
/* @__PURE__ */ l.createElement(
|
|
652
|
+
Ce,
|
|
653
|
+
e.pageable && Re,
|
|
654
|
+
/* @__PURE__ */ l.createElement(rt, { loader: e.loader, showLoader: e.showLoader }),
|
|
648
655
|
Fe
|
|
649
656
|
))
|
|
650
657
|
);
|
|
651
658
|
});
|
|
652
|
-
|
|
659
|
+
Pl.displayName = "KendoReactGridComponent";
|
|
653
660
|
export {
|
|
654
|
-
|
|
661
|
+
Pl as GridComponent
|
|
655
662
|
};
|