@progress/kendo-react-grid 9.3.1-develop.1 → 9.4.0-develop.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (148) hide show
  1. package/Grid.js +1 -1
  2. package/Grid.mjs +80 -1042
  3. package/GridClientContextReader.js +8 -0
  4. package/GridClientContextReader.mjs +30 -0
  5. package/GridClientWrapper.js +8 -0
  6. package/GridClientWrapper.mjs +759 -0
  7. package/GridComponent.js +8 -0
  8. package/GridComponent.mjs +584 -0
  9. package/GridState.js +8 -0
  10. package/GridState.mjs +93 -0
  11. package/GridWatermarkOverlay.js +8 -0
  12. package/GridWatermarkOverlay.mjs +15 -0
  13. package/StatusBar.js +1 -1
  14. package/StatusBar.mjs +24 -24
  15. package/cells/GridCell.js +1 -1
  16. package/cells/GridCell.mjs +23 -33
  17. package/cells/GridDetailCell.js +1 -1
  18. package/cells/GridDetailCell.mjs +11 -18
  19. package/cells/GridDetailHierarchyCell.js +1 -1
  20. package/cells/GridDetailHierarchyCell.mjs +5 -5
  21. package/cells/GridEditCell.js +1 -1
  22. package/cells/GridEditCell.mjs +22 -130
  23. package/cells/GridGroupCell.js +1 -1
  24. package/cells/GridGroupCell.mjs +60 -95
  25. package/cells/GridHierarchyCell.js +1 -1
  26. package/cells/GridHierarchyCell.mjs +22 -61
  27. package/cells/GridRowReorderCell.js +8 -0
  28. package/cells/GridRowReorderCell.mjs +42 -0
  29. package/cells/GridSelectionCell.js +1 -1
  30. package/cells/GridSelectionCell.mjs +17 -35
  31. package/cells/client/DetailCellContainer.js +8 -0
  32. package/cells/client/DetailCellContainer.mjs +26 -0
  33. package/cells/client/GridCellContainer.js +8 -0
  34. package/cells/client/GridCellContainer.mjs +68 -0
  35. package/cells/client/GridEditCellContainer.js +8 -0
  36. package/cells/client/GridEditCellContainer.mjs +60 -0
  37. package/cells/client/GridEditCellEditor.js +8 -0
  38. package/cells/client/GridEditCellEditor.mjs +81 -0
  39. package/cells/client/GridGroupCellContainer.js +8 -0
  40. package/cells/client/GridGroupCellContainer.mjs +87 -0
  41. package/cells/client/GridGroupCellToggle.js +8 -0
  42. package/cells/client/GridGroupCellToggle.mjs +52 -0
  43. package/cells/client/GridHierarchyCellContainer.js +8 -0
  44. package/cells/client/GridHierarchyCellContainer.mjs +63 -0
  45. package/cells/client/GridHierarchyCellToggle.js +8 -0
  46. package/cells/client/GridHierarchyCellToggle.mjs +43 -0
  47. package/cells/client/GridRowReorderContainer.js +8 -0
  48. package/cells/client/GridRowReorderContainer.mjs +24 -0
  49. package/cells/client/GridSelectionCellContainer.js +8 -0
  50. package/cells/client/GridSelectionCellContainer.mjs +60 -0
  51. package/cells/client/GridSelectionCellInput.js +8 -0
  52. package/cells/client/GridSelectionCellInput.mjs +43 -0
  53. package/columnMenu/GridColumnMenuSort.js +1 -1
  54. package/columnMenu/GridColumnMenuSort.mjs +23 -34
  55. package/components/GridContainerElementContainer.js +8 -0
  56. package/components/GridContainerElementContainer.mjs +21 -0
  57. package/components/GridCustomCellClientContainer.js +8 -0
  58. package/components/GridCustomCellClientContainer.mjs +28 -0
  59. package/components/GridDragClue.js +8 -0
  60. package/components/GridDragClue.mjs +18 -0
  61. package/components/GridDraggableRowsContainer.js +8 -0
  62. package/components/GridDraggableRowsContainer.mjs +127 -0
  63. package/components/GridDropClue.js +8 -0
  64. package/components/GridDropClue.mjs +18 -0
  65. package/components/GridElementContainer.js +8 -0
  66. package/components/GridElementContainer.mjs +22 -0
  67. package/components/PagerContainer.js +8 -0
  68. package/components/PagerContainer.mjs +23 -0
  69. package/components/VirtualScrollHeightContainer.js +8 -0
  70. package/components/VirtualScrollHeightContainer.mjs +17 -0
  71. package/components/colGroup/GridColGroup.js +8 -0
  72. package/components/colGroup/GridColGroup.mjs +25 -0
  73. package/components/icons/reorder-row-svg.js +8 -0
  74. package/components/icons/reorder-row-svg.mjs +14 -0
  75. package/{GridNoRecords.js → components/noRecords/GridNoRecords.js} +1 -1
  76. package/{GridNoRecords.mjs → components/noRecords/GridNoRecords.mjs} +1 -1
  77. package/components/noRecords/GridNoRecordsContainer.js +8 -0
  78. package/components/noRecords/GridNoRecordsContainer.mjs +30 -0
  79. package/components/table/GridTable.js +8 -0
  80. package/components/table/GridTable.mjs +28 -0
  81. package/components/table/GridTableBody.js +8 -0
  82. package/components/table/GridTableBody.mjs +21 -0
  83. package/components/table/GridTableScrollable.js +8 -0
  84. package/components/table/GridTableScrollable.mjs +37 -0
  85. package/components/utils.js +8 -0
  86. package/components/utils.mjs +26 -0
  87. package/contextMenu/GridContextMenu.js +8 -0
  88. package/contextMenu/GridContextMenu.mjs +191 -0
  89. package/contextMenu/enums.js +8 -0
  90. package/contextMenu/enums.mjs +13 -0
  91. package/dist/cdn/js/kendo-react-grid.js +1 -1
  92. package/footer/Footer.js +1 -1
  93. package/footer/Footer.mjs +22 -21
  94. package/footer/FooterCell.js +8 -0
  95. package/footer/FooterCell.mjs +43 -0
  96. package/footer/FooterRow.js +1 -1
  97. package/footer/FooterRow.mjs +10 -39
  98. package/footer/client/FooterCellContainer.js +8 -0
  99. package/footer/client/FooterCellContainer.mjs +26 -0
  100. package/header/FilterRow.js +1 -1
  101. package/header/FilterRow.mjs +58 -54
  102. package/header/GridHeaderCell.js +1 -1
  103. package/header/GridHeaderCell.mjs +11 -11
  104. package/header/GridHeaderSelectionCell.js +1 -1
  105. package/header/GridHeaderSelectionCell.mjs +10 -9
  106. package/header/GroupPanel.js +1 -1
  107. package/header/GroupPanel.mjs +36 -32
  108. package/header/Header.js +1 -1
  109. package/header/Header.mjs +35 -33
  110. package/header/HeaderRow.js +1 -1
  111. package/header/HeaderRow.mjs +97 -125
  112. package/header/client/GridFilterCellContainer.js +8 -0
  113. package/header/client/GridFilterCellContainer.mjs +38 -0
  114. package/header/client/GridFilterCellElementContainer.js +8 -0
  115. package/header/client/GridFilterCellElementContainer.mjs +21 -0
  116. package/header/client/GridHeaderCellContainer.js +8 -0
  117. package/header/client/GridHeaderCellContainer.mjs +54 -0
  118. package/header/client/GridHeaderCellElementContainer.js +8 -0
  119. package/header/client/GridHeaderCellElementContainer.mjs +28 -0
  120. package/header/client/GridHeaderRowContainer.js +8 -0
  121. package/header/client/GridHeaderRowContainer.mjs +35 -0
  122. package/header/client/GridHeaderRowReorderCell.js +8 -0
  123. package/header/client/GridHeaderRowReorderCell.mjs +13 -0
  124. package/header/client/HeaderCellResizer.js +8 -0
  125. package/header/client/HeaderCellResizer.mjs +25 -0
  126. package/header/client/HeaderRowDraggable.js +8 -0
  127. package/header/client/HeaderRowDraggable.mjs +30 -0
  128. package/index.d.mts +543 -24
  129. package/index.d.ts +543 -24
  130. package/index.js +1 -1
  131. package/index.mjs +58 -52
  132. package/interfaces/GridSortSettings.js +1 -1
  133. package/interfaces/GridSortSettings.mjs +18 -2
  134. package/messages/index.js +1 -1
  135. package/messages/index.mjs +76 -82
  136. package/messages/messagesMap.js +8 -0
  137. package/messages/messagesMap.mjs +19 -0
  138. package/package-metadata.js +1 -1
  139. package/package-metadata.mjs +2 -2
  140. package/package.json +12 -11
  141. package/rows/GridRow.js +1 -1
  142. package/rows/GridRow.mjs +42 -20
  143. package/utils/_clientModule.js +8 -0
  144. package/utils/_clientModule.mjs +13 -0
  145. package/utils/_serverModule.js +8 -0
  146. package/utils/_serverModule.mjs +13 -0
  147. package/utils/index.js +1 -1
  148. package/utils/index.mjs +213 -101
@@ -0,0 +1,81 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as t from "react";
10
+ import { GridContext as i } from "../../GridClientWrapper.mjs";
11
+ import { useId as d, getNestedValue as u } from "@progress/kendo-react-common";
12
+ import { TextBox as E, Checkbox as f, NumericTextBox as N } from "@progress/kendo-react-inputs";
13
+ import { TABLE_PREVENT_SELECTION_ELEMENT as s } from "@progress/kendo-react-data-tools";
14
+ import { DatePicker as h } from "@progress/kendo-react-dateinputs";
15
+ const b = (a) => {
16
+ const { cellProps: e } = a, n = t.useContext(i), r = d(), l = u(e.field, e.dataItem);
17
+ let c = null;
18
+ const m = t.useCallback(
19
+ (o) => {
20
+ n != null && n.itemChange && n.itemChange({
21
+ dataItem: e.dataItem,
22
+ dataIndex: e.dataIndex,
23
+ field: e.field,
24
+ syntheticEvent: o.syntheticEvent,
25
+ value: o.value
26
+ });
27
+ },
28
+ [n, e.dataItem, e.dataIndex, e.field]
29
+ );
30
+ switch (e.editor) {
31
+ case "numeric":
32
+ c = /* @__PURE__ */ t.createElement(
33
+ N,
34
+ {
35
+ className: a.className,
36
+ value: l === void 0 ? null : l,
37
+ onChange: m,
38
+ [s]: !0
39
+ }
40
+ );
41
+ break;
42
+ case "date":
43
+ c = /* @__PURE__ */ t.createElement(
44
+ h,
45
+ {
46
+ className: a.className,
47
+ value: l,
48
+ onChange: m,
49
+ [s]: !0
50
+ }
51
+ );
52
+ break;
53
+ case "boolean":
54
+ c = /* @__PURE__ */ t.createElement(
55
+ f,
56
+ {
57
+ className: a.className,
58
+ checked: l || !1,
59
+ id: r,
60
+ onChange: m,
61
+ [s]: !0
62
+ }
63
+ );
64
+ break;
65
+ default:
66
+ c = /* @__PURE__ */ t.createElement(
67
+ E,
68
+ {
69
+ className: a.className,
70
+ value: l || "",
71
+ onChange: m,
72
+ [s]: !0
73
+ }
74
+ );
75
+ break;
76
+ }
77
+ return c;
78
+ };
79
+ export {
80
+ b as GridEditCellEditor
81
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const y=require("react"),s=require("@progress/kendo-react-data-tools"),g=require("../../GridClientWrapper.js"),x=require("@progress/kendo-react-common");function I(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,a.get?a:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const o=I(y),b=e=>{var u;const{cellProps:t}=e,n=o.useContext(g.GridContext),a=s.useTableKeyboardNavigation(t.id),m=o.useCallback(l=>{l.isDefaultPrevented()||l.keyCode===x.Keys.enter&&(n!=null&&n.itemChange)&&(l.preventDefault(),n.itemChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:l,field:void 0,value:!t.expanded}),n==null||n.dispatchGroupExpand({type:s.GROUP_EXPAND_ACTION.TOGGLE,group:t.group},l))},[n,t.dataItem,t.dataIndex,t.expanded,t.group]),C=e.addKeyDownHandler?{onKeyDown:m}:{},d=o.useCallback(l=>{n!=null&&n.onContextMenu&&n.onContextMenu.call(void 0,l,t.dataItem,t.field)},[n,t.dataItem,t.field]),P=n.getCellPositionStyle(t.columnPosition),f={style:{...(u=e.tdProps)==null?void 0:u.style,...P}},r={...a,...C,onContextMenu:d,...f},c={onContextMenu:n.onContextMenu,onChange:n.itemChange,selectionChange:l=>{n.selectionChange({event:l,dataItem:t.dataItem,dataIndex:t.rowDataIndex,columnIndex:t.columnIndex})}};if(e.isCustom)return n.isClient||e.isClient?o.cloneElement(e.children,{tdProps:e.tdProps?{...e.tdProps,...r}:null,td2Props:e.td2Props?{...e.td2Props,onContextMenu:d}:null,...c}):o.cloneElement(e.children,{...r});const i=e.renderSecondCell?o.createElement("td",{...e.td2Props,onContextMenu:d}):null;if(t.render){const l=e.renderFirstCell&&o.createElement(o.Fragment,null,o.createElement("td",{...e.tdProps,...r},e.content),e.renderSecondCell&&i);return t.render.call(void 0,l,{...t,...c})}return o.createElement(o.Fragment,null,e.children&&o.cloneElement(e.children,{...r}),i)};exports.GridGroupCellContainer=b;
@@ -0,0 +1,87 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as l from "react";
10
+ import { useTableKeyboardNavigation as f, GROUP_EXPAND_ACTION as x } from "@progress/kendo-react-data-tools";
11
+ import { GridContext as I } from "../../GridClientWrapper.mjs";
12
+ import { Keys as y } from "@progress/kendo-react-common";
13
+ const D = (n) => {
14
+ var c;
15
+ const { cellProps: e } = n, t = l.useContext(I), u = f(e.id), s = l.useCallback(
16
+ (o) => {
17
+ o.isDefaultPrevented() || o.keyCode === y.enter && (t != null && t.itemChange) && (o.preventDefault(), t.itemChange({
18
+ dataItem: e.dataItem,
19
+ dataIndex: e.dataIndex,
20
+ syntheticEvent: o,
21
+ field: void 0,
22
+ value: !e.expanded
23
+ }), t == null || t.dispatchGroupExpand(
24
+ {
25
+ type: x.TOGGLE,
26
+ group: e.group
27
+ },
28
+ o
29
+ ));
30
+ },
31
+ [t, e.dataItem, e.dataIndex, e.expanded, e.group]
32
+ ), m = n.addKeyDownHandler ? {
33
+ onKeyDown: s
34
+ } : {}, d = l.useCallback(
35
+ (o) => {
36
+ t != null && t.onContextMenu && t.onContextMenu.call(void 0, o, e.dataItem, e.field);
37
+ },
38
+ [t, e.dataItem, e.field]
39
+ ), C = t.getCellPositionStyle(e.columnPosition), P = {
40
+ style: { ...(c = n.tdProps) == null ? void 0 : c.style, ...C }
41
+ }, a = {
42
+ ...u,
43
+ ...m,
44
+ onContextMenu: d,
45
+ ...P
46
+ }, r = {
47
+ onContextMenu: t.onContextMenu,
48
+ onChange: t.itemChange,
49
+ selectionChange: (o) => {
50
+ t.selectionChange({
51
+ event: o,
52
+ dataItem: e.dataItem,
53
+ dataIndex: e.rowDataIndex,
54
+ columnIndex: e.columnIndex
55
+ });
56
+ }
57
+ };
58
+ if (n.isCustom)
59
+ return t.isClient || n.isClient ? l.cloneElement(n.children, {
60
+ // pass down to tdProps for client templates
61
+ tdProps: n.tdProps ? {
62
+ ...n.tdProps,
63
+ ...a
64
+ } : null,
65
+ td2Props: n.td2Props ? {
66
+ ...n.td2Props,
67
+ onContextMenu: d
68
+ } : null,
69
+ ...r
70
+ }) : l.cloneElement(n.children, {
71
+ ...a
72
+ });
73
+ const i = n.renderSecondCell ? /* @__PURE__ */ l.createElement("td", { ...n.td2Props, onContextMenu: d }) : null;
74
+ if (e.render) {
75
+ const o = n.renderFirstCell && /* @__PURE__ */ l.createElement(l.Fragment, null, /* @__PURE__ */ l.createElement("td", { ...n.tdProps, ...a }, n.content), n.renderSecondCell && i);
76
+ return e.render.call(void 0, o, {
77
+ ...e,
78
+ ...r
79
+ });
80
+ }
81
+ return /* @__PURE__ */ l.createElement(l.Fragment, null, n.children && l.cloneElement(n.children, {
82
+ ...a
83
+ }), i);
84
+ };
85
+ export {
86
+ D as GridGroupCellContainer
87
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),g=require("../../GridClientWrapper.js"),f=require("@progress/kendo-react-common"),o=require("@progress/kendo-svg-icons"),m=require("@progress/kendo-react-intl"),c=require("../../messages/index.js"),p=require("@progress/kendo-react-data-tools");function I(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const n=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(e,a,n.get?n:{enumerable:!0,get:()=>t[a]})}}return e.default=t,Object.freeze(e)}const r=I(s),b=t=>{const e=r.useContext(g.GridContext),a=m.useLocalization(),n=t.expanded?c.groupCollapse:c.groupExpand,d=a.toLanguageString(n,c.messages[n]),l=e.dir==="rtl";return r.createElement("a",{onClick:i=>{var u;i.preventDefault(),e!=null&&e.itemChange&&e.itemChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:i,field:void 0,value:!t.expanded}),(u=e==null?void 0:e.dispatchGroupExpand)==null||u.call(e,{type:p.GROUP_EXPAND_ACTION.TOGGLE,group:t.group})},href:"#",tabIndex:-1,"aria-label":d},r.createElement(f.IconWrap,{name:t.expanded?"caret-alt-down":l?"caret-alt-left":"caret-alt-right",icon:t.expanded?o.caretAltDownIcon:l?o.caretAltLeftIcon:o.caretAltRightIcon}))};exports.GridGroupCellToggle=b;
@@ -0,0 +1,52 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as a from "react";
10
+ import { GridContext as m } from "../../GridClientWrapper.mjs";
11
+ import { IconWrap as d } from "@progress/kendo-react-common";
12
+ import { caretAltDownIcon as s, caretAltLeftIcon as f, caretAltRightIcon as p } from "@progress/kendo-svg-icons";
13
+ import { useLocalization as u } from "@progress/kendo-react-intl";
14
+ import { groupCollapse as g, groupExpand as I, messages as h } from "../../messages/index.mjs";
15
+ import { GROUP_EXPAND_ACTION as x } from "@progress/kendo-react-data-tools";
16
+ const b = (t) => {
17
+ const e = a.useContext(m), l = u(), n = t.expanded ? g : I, i = l.toLanguageString(n, h[n]), o = e.dir === "rtl";
18
+ return (
19
+ // eslint-disable-next-line jsx-a11y/anchor-is-valid
20
+ /* @__PURE__ */ a.createElement(
21
+ "a",
22
+ {
23
+ onClick: (r) => {
24
+ var c;
25
+ r.preventDefault(), e != null && e.itemChange && e.itemChange({
26
+ dataItem: t.dataItem,
27
+ dataIndex: t.dataIndex,
28
+ syntheticEvent: r,
29
+ field: void 0,
30
+ value: !t.expanded
31
+ }), (c = e == null ? void 0 : e.dispatchGroupExpand) == null || c.call(e, {
32
+ type: x.TOGGLE,
33
+ group: t.group
34
+ });
35
+ },
36
+ href: "#",
37
+ tabIndex: -1,
38
+ "aria-label": i
39
+ },
40
+ /* @__PURE__ */ a.createElement(
41
+ d,
42
+ {
43
+ name: t.expanded ? "caret-alt-down" : o ? "caret-alt-left" : "caret-alt-right",
44
+ icon: t.expanded ? s : o ? f : p
45
+ }
46
+ )
47
+ )
48
+ );
49
+ };
50
+ export {
51
+ b as GridGroupCellToggle
52
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),m=require("@progress/kendo-react-data-tools"),f=require("../../GridClientWrapper.js"),C=require("@progress/kendo-react-common");function g(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,a.get?a:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const r=g(s),y=t=>{const{cellProps:e}=t,n=r.useContext(f.GridContext),a=m.useTableKeyboardNavigation(e.id),l=t.expanded,d=r.useCallback(o=>{o.isDefaultPrevented()||o.keyCode===C.Keys.enter&&(n!=null&&n.itemChange)&&(o.preventDefault(),n.itemChange({dataItem:e.dataItem,dataIndex:e.dataIndex,syntheticEvent:o,field:e.field,value:!l}))},[e.dataItem,e.dataIndex,e.field,n,l]),u=e.rowType!=="groupHeader"&&e.rowType!=="groupFooter"?{onKeyDown:d}:{},i={...a,...u},c={onContextMenu:n.onContextMenu,onChange:n.itemChange,selectionChange:o=>{n.selectionChange({event:o,dataItem:e.dataItem,dataIndex:e.rowDataIndex,columnIndex:e.columnIndex})}};if(t.isCustom)return n.isClient||t.isClient?r.cloneElement(t.children,{tdProps:{...t.tdProps,...i},...c}):r.cloneElement(t.children,{...i});if(e.render){const o=e.rowType!=="groupHeader"?r.createElement("td",{...t.tdProps,...i},t.content):null;return e.render.call(void 0,o,{...e,...c})}return t.children&&r.cloneElement(t.children,{...i})};exports.GridHierarchyCellContainer=y;
@@ -0,0 +1,63 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as a from "react";
10
+ import { useTableKeyboardNavigation as u } from "@progress/kendo-react-data-tools";
11
+ import { GridContext as s } from "../../GridClientWrapper.mjs";
12
+ import { Keys as C } from "@progress/kendo-react-common";
13
+ const h = (n) => {
14
+ const { cellProps: e } = n, t = a.useContext(s), l = u(e.id), d = n.expanded, c = a.useCallback(
15
+ (o) => {
16
+ o.isDefaultPrevented() || o.keyCode === C.enter && (t != null && t.itemChange) && (o.preventDefault(), t.itemChange({
17
+ dataItem: e.dataItem,
18
+ dataIndex: e.dataIndex,
19
+ syntheticEvent: o,
20
+ field: e.field,
21
+ value: !d
22
+ }));
23
+ },
24
+ [e.dataItem, e.dataIndex, e.field, t, d]
25
+ ), m = e.rowType !== "groupHeader" && e.rowType !== "groupFooter" ? {
26
+ onKeyDown: c
27
+ } : {}, r = {
28
+ ...l,
29
+ ...m
30
+ }, i = {
31
+ onContextMenu: t.onContextMenu,
32
+ onChange: t.itemChange,
33
+ selectionChange: (o) => {
34
+ t.selectionChange({
35
+ event: o,
36
+ dataItem: e.dataItem,
37
+ dataIndex: e.rowDataIndex,
38
+ columnIndex: e.columnIndex
39
+ });
40
+ }
41
+ };
42
+ if (n.isCustom)
43
+ return t.isClient || n.isClient ? a.cloneElement(n.children, {
44
+ // pass down to tdProps for client templates
45
+ tdProps: { ...n.tdProps, ...r },
46
+ ...i
47
+ }) : a.cloneElement(n.children, {
48
+ ...r
49
+ });
50
+ if (e.render) {
51
+ const o = e.rowType !== "groupHeader" ? /* @__PURE__ */ a.createElement("td", { ...n.tdProps, ...r }, n.content) : null;
52
+ return e.render.call(void 0, o, {
53
+ ...e,
54
+ ...i
55
+ });
56
+ }
57
+ return n.children && a.cloneElement(n.children, {
58
+ ...r
59
+ });
60
+ };
61
+ export {
62
+ h as GridHierarchyCellContainer
63
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react"),u=require("../../GridClientWrapper.js"),m=require("@progress/kendo-react-common"),l=require("@progress/kendo-svg-icons"),g=require("@progress/kendo-react-intl"),c=require("../../messages/index.js"),f=require("@progress/kendo-react-data-tools");function I(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,a.get?a:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const o=I(d),p=t=>{const e=o.useContext(u.GridContext),n=g.useLocalization(),a=t.expanded,r=a?c.detailCollapse:c.detailExpand,s=n.toLanguageString(r,c.messages[r]);return o.createElement("a",{onClick:i=>{i.preventDefault(),e!=null&&e.itemChange&&e.itemChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:i,field:t.field,value:!a,_expand:!0}),e==null||e.dispatchDetailExpand({type:f.DETAIL_EXPAND_ACTION.TOGGLE,id:t.dataItem[e.dataItemKey]})},"aria-label":s,href:"#",tabIndex:-1},o.createElement(m.IconWrap,{name:a?"minus":"plus",icon:a?l.minusIcon:l.plusIcon}))};exports.GridHierarchyCellToggle=p;
@@ -0,0 +1,43 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as n from "react";
10
+ import { GridContext as r } from "../../GridClientWrapper.mjs";
11
+ import { IconWrap as d } from "@progress/kendo-react-common";
12
+ import { minusIcon as s, plusIcon as c } from "@progress/kendo-svg-icons";
13
+ import { useLocalization as f } from "@progress/kendo-react-intl";
14
+ import { messages as p, detailCollapse as u, detailExpand as I } from "../../messages/index.mjs";
15
+ import { DETAIL_EXPAND_ACTION as x } from "@progress/kendo-react-data-tools";
16
+ const G = (a) => {
17
+ const e = n.useContext(r), m = f(), t = a.expanded, i = t ? u : I, l = m.toLanguageString(i, p[i]);
18
+ return /* @__PURE__ */ n.createElement(
19
+ "a",
20
+ {
21
+ onClick: (o) => {
22
+ o.preventDefault(), e != null && e.itemChange && e.itemChange({
23
+ dataItem: a.dataItem,
24
+ dataIndex: a.dataIndex,
25
+ syntheticEvent: o,
26
+ field: a.field,
27
+ value: !t,
28
+ _expand: !0
29
+ }), e == null || e.dispatchDetailExpand({
30
+ type: x.TOGGLE,
31
+ id: a.dataItem[e.dataItemKey]
32
+ });
33
+ },
34
+ "aria-label": l,
35
+ href: "#",
36
+ tabIndex: -1
37
+ },
38
+ /* @__PURE__ */ n.createElement(d, { name: t ? "minus" : "plus", icon: t ? s : c })
39
+ );
40
+ };
41
+ export {
42
+ G as GridHierarchyCellToggle
43
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react"),b=require("@progress/kendo-react-intl"),w=require("@progress/kendo-react-data-tools"),C=require("../../GridClientWrapper.js"),e=require("../../messages/index.js"),m=r=>{const{cellProps:n,rowReorderable:a,children:o}=r,{id:i,dataItem:s}=n,c=b.useLocalization(),l=t.useContext(C.GridContext),d=w.useTableKeyboardNavigation(i),u=a,R=c.toLanguageString(e.gridRowReorderAriaLabel,e.messages[e.gridRowReorderAriaLabel]),g=()=>u?l.activeDragRowDataItemRef.current=s:null;return o&&t.cloneElement(o,{"aria-label":R,...d,onMouseDown:g})};exports.GridRowReorderCellContainer=m;
@@ -0,0 +1,24 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import e from "react";
10
+ import { useLocalization as R } from "@progress/kendo-react-intl";
11
+ import { useTableKeyboardNavigation as f } from "@progress/kendo-react-data-tools";
12
+ import { GridContext as p } from "../../GridClientWrapper.mjs";
13
+ import { gridRowReorderAriaLabel as t, messages as b } from "../../messages/index.mjs";
14
+ const L = (r) => {
15
+ const { cellProps: n, rowReorderable: a, children: o } = r, { id: i, dataItem: s } = n, c = R(), l = e.useContext(p), m = f(i), d = a, u = c.toLanguageString(t, b[t]), g = () => d ? l.activeDragRowDataItemRef.current = s : null;
16
+ return o && e.cloneElement(o, {
17
+ "aria-label": u,
18
+ ...m,
19
+ onMouseDown: g
20
+ });
21
+ };
22
+ export {
23
+ L as GridRowReorderCellContainer
24
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const C=require("react"),m=require("@progress/kendo-react-data-tools"),f=require("../../GridClientWrapper.js");function g(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const o=g(C),P=e=>{var a;const{cellProps:t}=e,n=o.useContext(f.GridContext),r=m.useTableKeyboardNavigation(t.id),d={onContextMenu:o.useCallback(l=>{n!=null&&n.onContextMenu&&n.onContextMenu.call(void 0,l,t.dataItem,t.field)},[n,t.dataItem,t.field])},s=n.getCellPositionStyle(t.columnPosition),u={style:{...(a=e.tdProps)==null?void 0:a.style,...s}},i={...r,...d,...u},c={onContextMenu:n.onContextMenu,onChange:n.itemChange,selectionChange:l=>{n.selectionChange({event:l,dataItem:t.dataItem,dataIndex:t.rowDataIndex,columnIndex:t.columnIndex})}};if(e.isCustom)return n.isClient||e.isClient?o.cloneElement(e.children,{tdProps:{...e.tdProps,...i},...c}):o.cloneElement(e.children,{...i});if(t.render){const l=t.rowType!=="groupHeader"?o.createElement("td",{...e.tdProps,...i},e.content):null;return t.render.call(void 0,l,{...t,...c})}return e.children&&o.cloneElement(e.children,{...i})};exports.GridSelectionCellContainer=P;
@@ -0,0 +1,60 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as o from "react";
10
+ import { useTableKeyboardNavigation as C } from "@progress/kendo-react-data-tools";
11
+ import { GridContext as m } from "../../GridClientWrapper.mjs";
12
+ const g = (n) => {
13
+ var r;
14
+ const { cellProps: e } = n, t = o.useContext(m), c = C(e.id), d = {
15
+ onContextMenu: o.useCallback(
16
+ (l) => {
17
+ t != null && t.onContextMenu && t.onContextMenu.call(void 0, l, e.dataItem, e.field);
18
+ },
19
+ [t, e.dataItem, e.field]
20
+ )
21
+ }, s = t.getCellPositionStyle(e.columnPosition), u = {
22
+ style: { ...(r = n.tdProps) == null ? void 0 : r.style, ...s }
23
+ }, i = {
24
+ ...c,
25
+ ...d,
26
+ ...u
27
+ }, a = {
28
+ onContextMenu: t.onContextMenu,
29
+ onChange: t.itemChange,
30
+ selectionChange: (l) => {
31
+ t.selectionChange({
32
+ event: l,
33
+ dataItem: e.dataItem,
34
+ dataIndex: e.rowDataIndex,
35
+ columnIndex: e.columnIndex
36
+ });
37
+ }
38
+ };
39
+ if (n.isCustom)
40
+ return t.isClient || n.isClient ? o.cloneElement(n.children, {
41
+ // pass down to tdProps for client templates
42
+ tdProps: { ...n.tdProps, ...i },
43
+ ...a
44
+ }) : o.cloneElement(n.children, {
45
+ ...i
46
+ });
47
+ if (e.render) {
48
+ const l = e.rowType !== "groupHeader" ? /* @__PURE__ */ o.createElement("td", { ...n.tdProps, ...i }, n.content) : null;
49
+ return e.render.call(void 0, l, {
50
+ ...e,
51
+ ...a
52
+ });
53
+ }
54
+ return n.children && o.cloneElement(n.children, {
55
+ ...i
56
+ });
57
+ };
58
+ export {
59
+ g as GridSelectionCellContainer
60
+ };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react"),b=require("../../GridClientWrapper.js"),r=require("@progress/kendo-react-common"),I=require("@progress/kendo-react-intl"),o=require("../../messages/index.js");function g(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,a.get?a:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const c=g(m),k=e=>{var i;const t=c.useContext(b.GridContext),n=r.useId(),a=I.useLocalization(),l=(i=e.isSelected)!=null?i:r.getNestedValue(e.field,e.dataItem),d=typeof l=="boolean"&&l,u=c.useCallback(s=>{t==null||t.selectionChange({event:s,dataItem:e.dataItem,dataIndex:e.rowDataIndex,columnIndex:e.columnIndex})},[t,e.columnIndex,e.rowDataIndex,e.dataItem]);return c.createElement("span",{className:"k-checkbox-wrap"},c.createElement("input",{id:n,tabIndex:-1,type:"checkbox",className:"k-checkbox k-checkbox-md k-rounded-md","aria-label":a.toLanguageString(o.selectRow,o.messages[o.selectRow]),"aria-checked":d,checked:d,onChange:u}))};exports.GridSelectionCellInput=k;
@@ -0,0 +1,43 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";
9
+ import * as a from "react";
10
+ import { GridContext as u } from "../../GridClientWrapper.mjs";
11
+ import { useId as r, getNestedValue as I } from "@progress/kendo-react-common";
12
+ import { useLocalization as x } from "@progress/kendo-react-intl";
13
+ import { selectRow as d, messages as k } from "../../messages/index.mjs";
14
+ const C = (e) => {
15
+ var o;
16
+ const t = a.useContext(u), l = r(), m = x(), n = (o = e.isSelected) != null ? o : I(e.field, e.dataItem), c = typeof n == "boolean" && n, i = a.useCallback(
17
+ (s) => {
18
+ t == null || t.selectionChange({
19
+ event: s,
20
+ dataItem: e.dataItem,
21
+ dataIndex: e.rowDataIndex,
22
+ columnIndex: e.columnIndex
23
+ });
24
+ },
25
+ [t, e.columnIndex, e.rowDataIndex, e.dataItem]
26
+ );
27
+ return /* @__PURE__ */ a.createElement("span", { className: "k-checkbox-wrap" }, /* @__PURE__ */ a.createElement(
28
+ "input",
29
+ {
30
+ id: l,
31
+ tabIndex: -1,
32
+ type: "checkbox",
33
+ className: "k-checkbox k-checkbox-md k-rounded-md",
34
+ "aria-label": m.toLanguageString(d, k[d]),
35
+ "aria-checked": c,
36
+ checked: c,
37
+ onChange: i
38
+ }
39
+ ));
40
+ };
41
+ export {
42
+ C as GridSelectionCellInput
43
+ };
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("react"),g=require("./GridColumnMenuItem.js"),O=require("./GridColumnMenuItemGroup.js"),j=require("../interfaces/GridSortSettings.js"),y=require("@progress/kendo-react-intl"),s=require("../messages/index.js"),C=require("@progress/kendo-svg-icons");function R(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const l=R(v),S="asc",M="desc",_={true:{asc:{asc:"",desc:"desc"},desc:{asc:"asc",desc:""},"":{asc:"asc",desc:"desc"}},false:{asc:{asc:"asc",desc:"desc"},desc:{asc:"asc",desc:"desc"},"":{asc:"asc",desc:"desc"}}},I=(e,n)=>n?n.findIndex(t=>t.field===e):-1,D=(e,n)=>!!(n&&e>-1&&n[e].dir===S),G=(e,n)=>!!(n&&e>-1&&n[e].dir===M),z=(e,n)=>{const t=I(e,n);return G(t,n)||D(t,n)},E=e=>{const n=c=>{o(c,S),e.onCloseMenu&&e.onCloseMenu()},t=c=>{o(c,M),e.onCloseMenu&&e.onCloseMenu()},o=(c,k)=>{if(c.preventDefault(),!e.onSortChange)return;const{allowUnsort:q,mode:A}=j.normalize(e.sortable||!1,!1),d=(e.sort||[]).filter(i=>i.field===e.column.field)[0],m=_[q][d&&d.dir||""][k],f=A==="single"?[]:(e.sort||[]).filter(i=>i.field!==e.column.field);m!==""&&e.column.field&&f.push({field:e.column.field,dir:m}),e.onSortChange(f,c)},{sort:r,column:b}=e,u=I(b.field,r),a=y.useLocalization();return l.createElement(O.GridColumnMenuItemGroup,null,l.createElement(g.GridColumnMenuItem,{title:a.toLanguageString(s.sortAscending,s.messages[s.sortAscending]),iconClass:"k-i-sort-asc-sm",svgIcon:C.sortAscSmallIcon,selected:D(u,r),onClick:n}),l.createElement(g.GridColumnMenuItem,{title:a.toLanguageString(s.sortDescending,s.messages[s.sortDescending]),iconClass:"k-i-sort-desc-sm",svgIcon:C.sortDescSmallIcon,selected:G(u,r),onClick:t}))};exports.GridColumnMenuSort=E;exports.isColumnMenuSortActive=z;
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react"),g=require("./GridColumnMenuItem.js"),j=require("./GridColumnMenuItemGroup.js"),C=require("../interfaces/GridSortSettings.js"),y=require("@progress/kendo-react-intl"),c=require("../messages/index.js"),S=require("@progress/kendo-svg-icons");function R(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const l=R(O),M="asc",I="desc",D=(e,n)=>n?n.findIndex(t=>t.field===e):-1,G=(e,n)=>!!(n&&e>-1&&n[e].dir===M),b=(e,n)=>!!(n&&e>-1&&n[e].dir===I),_=(e,n)=>{const t=D(e,n);return b(t,n)||G(t,n)},z=e=>{const n=o=>{r(o,M),e.onCloseMenu&&e.onCloseMenu()},t=o=>{r(o,I),e.onCloseMenu&&e.onCloseMenu()},r=(o,q)=>{if(o.preventDefault(),!e.onSortChange)return;const{allowUnsort:A,mode:v}=C.normalize(e.sortable||!1,!1),d=(e.sort||[]).filter(s=>s.field===e.column.field)[0],m=C.sortSeqMap[A][d&&d.dir||""][q],f=v==="single"?[]:(e.sort||[]).filter(s=>s.field!==e.column.field);m!==""&&e.column.field&&f.push({field:e.column.field,dir:m}),e.onSortChange(f,o)},{sort:i,column:k}=e,u=D(k.field,i),a=y.useLocalization();return l.createElement(j.GridColumnMenuItemGroup,null,l.createElement(g.GridColumnMenuItem,{title:a.toLanguageString(c.sortAscending,c.messages[c.sortAscending]),iconClass:"k-i-sort-asc-sm",svgIcon:S.sortAscSmallIcon,selected:G(u,i),onClick:n}),l.createElement(g.GridColumnMenuItem,{title:a.toLanguageString(c.sortDescending,c.messages[c.sortDescending]),iconClass:"k-i-sort-desc-sm",svgIcon:S.sortDescSmallIcon,selected:b(u,i),onClick:t}))};exports.GridColumnMenuSort=z;exports.isColumnMenuSortActive=_;
@@ -9,52 +9,41 @@
9
9
  import * as l from "react";
10
10
  import { GridColumnMenuItem as f } from "./GridColumnMenuItem.mjs";
11
11
  import { GridColumnMenuItemGroup as x } from "./GridColumnMenuItemGroup.mjs";
12
- import { normalize as z } from "../interfaces/GridSortSettings.mjs";
13
- import { useLocalization as L } from "@progress/kendo-react-intl";
12
+ import { normalize as z, sortSeqMap as L } from "../interfaces/GridSortSettings.mjs";
13
+ import { useLocalization as R } from "@progress/kendo-react-intl";
14
14
  import { sortAscending as C, messages as g, sortDescending as S } from "../messages/index.mjs";
15
- import { sortAscSmallIcon as R, sortDescSmallIcon as w } from "@progress/kendo-svg-icons";
16
- const D = "asc", I = "desc", _ = {
17
- true: {
18
- asc: { asc: "", desc: "desc" },
19
- desc: { asc: "asc", desc: "" },
20
- "": { asc: "asc", desc: "desc" }
21
- },
22
- false: {
23
- asc: { asc: "asc", desc: "desc" },
24
- desc: { asc: "asc", desc: "desc" },
25
- "": { asc: "asc", desc: "desc" }
26
- }
27
- }, M = (e, c) => c ? c.findIndex((n) => n.field === e) : -1, k = (e, c) => !!(c && e > -1 && c[e].dir === D), A = (e, c) => !!(c && e > -1 && c[e].dir === I), F = (e, c) => {
28
- const n = M(e, c);
29
- return A(n, c) || k(n, c);
15
+ import { sortAscSmallIcon as w, sortDescSmallIcon as _ } from "@progress/kendo-svg-icons";
16
+ const D = "asc", I = "desc", M = (e, n) => n ? n.findIndex((o) => o.field === e) : -1, k = (e, n) => !!(n && e > -1 && n[e].dir === D), A = (e, n) => !!(n && e > -1 && n[e].dir === I), F = (e, n) => {
17
+ const o = M(e, n);
18
+ return A(o, n) || k(o, n);
30
19
  }, H = (e) => {
31
- const c = (s) => {
32
- r(s, D), e.onCloseMenu && e.onCloseMenu();
33
- }, n = (s) => {
34
- r(s, I), e.onCloseMenu && e.onCloseMenu();
35
- }, r = (s, G) => {
36
- if (s.preventDefault(), !e.onSortChange)
20
+ const n = (t) => {
21
+ r(t, D), e.onCloseMenu && e.onCloseMenu();
22
+ }, o = (t) => {
23
+ r(t, I), e.onCloseMenu && e.onCloseMenu();
24
+ }, r = (t, G) => {
25
+ if (t.preventDefault(), !e.onSortChange)
37
26
  return;
38
- const { allowUnsort: h, mode: v } = z(e.sortable || !1, !1), d = (e.sort || []).filter((o) => o.field === e.column.field)[0], m = _[h][d && d.dir || ""][G], u = v === "single" ? [] : (e.sort || []).filter((o) => o.field !== e.column.field);
39
- m !== "" && e.column.field && u.push({ field: e.column.field, dir: m }), e.onSortChange(u, s);
40
- }, { sort: t, column: E } = e, i = M(E.field, t), a = L();
27
+ const { allowUnsort: h, mode: v } = z(e.sortable || !1, !1), u = (e.sort || []).filter((i) => i.field === e.column.field)[0], a = L[h][u && u.dir || ""][G], d = v === "single" ? [] : (e.sort || []).filter((i) => i.field !== e.column.field);
28
+ a !== "" && e.column.field && d.push({ field: e.column.field, dir: a }), e.onSortChange(d, t);
29
+ }, { sort: c, column: E } = e, s = M(E.field, c), m = R();
41
30
  return /* @__PURE__ */ l.createElement(x, null, /* @__PURE__ */ l.createElement(
42
31
  f,
43
32
  {
44
- title: a.toLanguageString(C, g[C]),
33
+ title: m.toLanguageString(C, g[C]),
45
34
  iconClass: "k-i-sort-asc-sm",
46
- svgIcon: R,
47
- selected: k(i, t),
48
- onClick: c
35
+ svgIcon: w,
36
+ selected: k(s, c),
37
+ onClick: n
49
38
  }
50
39
  ), /* @__PURE__ */ l.createElement(
51
40
  f,
52
41
  {
53
- title: a.toLanguageString(S, g[S]),
42
+ title: m.toLanguageString(S, g[S]),
54
43
  iconClass: "k-i-sort-desc-sm",
55
- svgIcon: w,
56
- selected: A(i, t),
57
- onClick: n
44
+ svgIcon: _,
45
+ selected: A(s, c),
46
+ onClick: o
58
47
  }
59
48
  ));
60
49
  };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react"),i=require("../GridClientWrapper.js");function l(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(n,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return n.default=t,Object.freeze(n)}const o=l(c),a=t=>{const n=o.useContext(i.GridContext),{children:e}=t;return o.cloneElement(e,{...e==null?void 0:e.props,ref:n.containerElementRef,onScroll:n.scrollHandler})};exports.GridContainerElementContainer=a;