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

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 (194) hide show
  1. package/Grid.js +1 -1
  2. package/Grid.mjs +80 -1043
  3. package/GridClientContextReader.js +9 -0
  4. package/GridClientContextReader.mjs +31 -0
  5. package/GridClientWrapper.js +9 -0
  6. package/GridClientWrapper.mjs +793 -0
  7. package/GridColumn.js +1 -1
  8. package/GridColumn.mjs +4 -5
  9. package/GridComponent.js +8 -0
  10. package/GridComponent.mjs +594 -0
  11. package/GridSearchBox.js +8 -0
  12. package/GridSearchBox.mjs +35 -0
  13. package/GridState.js +9 -0
  14. package/GridState.mjs +99 -0
  15. package/GridToolbar.js +1 -1
  16. package/GridToolbar.mjs +5 -6
  17. package/GridWatermarkOverlay.js +9 -0
  18. package/{GridNoRecords.js → GridWatermarkOverlay.mjs} +8 -1
  19. package/StatusBar.js +1 -1
  20. package/StatusBar.mjs +24 -25
  21. package/VirtualScroll.js +1 -1
  22. package/VirtualScroll.mjs +0 -1
  23. package/VirtualScrollFixed.js +1 -1
  24. package/VirtualScrollFixed.mjs +9 -10
  25. package/cells/GridCell.js +1 -1
  26. package/cells/GridCell.mjs +22 -34
  27. package/cells/GridDetailCell.js +1 -1
  28. package/cells/GridDetailCell.mjs +12 -20
  29. package/cells/GridDetailHierarchyCell.js +1 -1
  30. package/cells/GridDetailHierarchyCell.mjs +6 -7
  31. package/cells/GridEditCell.js +1 -1
  32. package/cells/GridEditCell.mjs +22 -131
  33. package/cells/GridFilterCell.js +2 -1
  34. package/cells/GridGroupCell.js +1 -1
  35. package/cells/GridGroupCell.mjs +60 -96
  36. package/cells/GridHierarchyCell.js +1 -1
  37. package/cells/GridHierarchyCell.mjs +22 -62
  38. package/cells/GridRowReorderCell.js +8 -0
  39. package/cells/GridRowReorderCell.mjs +41 -0
  40. package/cells/GridSelectionCell.js +1 -1
  41. package/cells/GridSelectionCell.mjs +18 -37
  42. package/cells/client/DetailCellContainer.js +9 -0
  43. package/cells/client/DetailCellContainer.mjs +26 -0
  44. package/cells/client/GridCellContainer.js +9 -0
  45. package/cells/client/GridCellContainer.mjs +68 -0
  46. package/cells/client/GridEditCellContainer.js +9 -0
  47. package/cells/client/GridEditCellContainer.mjs +60 -0
  48. package/cells/client/GridEditCellEditor.js +9 -0
  49. package/cells/client/GridEditCellEditor.mjs +81 -0
  50. package/cells/client/GridGroupCellContainer.js +9 -0
  51. package/cells/client/GridGroupCellContainer.mjs +87 -0
  52. package/cells/client/GridGroupCellToggle.js +9 -0
  53. package/cells/client/GridGroupCellToggle.mjs +52 -0
  54. package/cells/client/GridHierarchyCellContainer.js +9 -0
  55. package/cells/client/GridHierarchyCellContainer.mjs +63 -0
  56. package/cells/client/GridHierarchyCellToggle.js +9 -0
  57. package/cells/client/GridHierarchyCellToggle.mjs +43 -0
  58. package/cells/client/GridRowReorderContainer.js +9 -0
  59. package/cells/client/GridRowReorderContainer.mjs +24 -0
  60. package/cells/client/GridSelectionCellContainer.js +9 -0
  61. package/cells/client/GridSelectionCellContainer.mjs +60 -0
  62. package/cells/client/GridSelectionCellInput.js +9 -0
  63. package/cells/client/GridSelectionCellInput.mjs +43 -0
  64. package/codemods/index.js +8 -0
  65. package/columnMenu/GridColumnMenuCheckboxFilter.js +2 -1
  66. package/columnMenu/GridColumnMenuColumnsList.js +2 -1
  67. package/columnMenu/GridColumnMenuColumnsList.mjs +16 -16
  68. package/columnMenu/GridColumnMenuFilter.js +2 -1
  69. package/columnMenu/GridColumnMenuFilterCell.js +2 -1
  70. package/columnMenu/GridColumnMenuFilterCell.mjs +3 -3
  71. package/columnMenu/GridColumnMenuFilterUI.js +2 -1
  72. package/columnMenu/GridColumnMenuGroup.js +2 -1
  73. package/columnMenu/GridColumnMenuGroup.mjs +5 -5
  74. package/columnMenu/GridColumnMenuItem.js +2 -1
  75. package/columnMenu/GridColumnMenuItem.mjs +2 -2
  76. package/columnMenu/GridColumnMenuItemContent.js +2 -1
  77. package/columnMenu/GridColumnMenuItemContent.mjs +4 -4
  78. package/columnMenu/GridColumnMenuItemGroup.js +2 -1
  79. package/columnMenu/GridColumnMenuItemGroup.mjs +4 -4
  80. package/columnMenu/GridColumnMenuSort.js +2 -1
  81. package/columnMenu/GridColumnMenuSort.mjs +26 -37
  82. package/columnMenu/GridColumnMenuWrapper.js +2 -1
  83. package/components/GridContainerElementContainer.js +9 -0
  84. package/components/GridContainerElementContainer.mjs +21 -0
  85. package/components/GridCustomCellClientContainer.js +9 -0
  86. package/components/GridCustomCellClientContainer.mjs +28 -0
  87. package/components/GridDragClue.js +9 -0
  88. package/components/GridDragClue.mjs +18 -0
  89. package/components/GridDraggableRowsContainer.js +9 -0
  90. package/components/GridDraggableRowsContainer.mjs +127 -0
  91. package/components/GridDropClue.js +9 -0
  92. package/components/GridDropClue.mjs +18 -0
  93. package/components/GridElementContainer.js +9 -0
  94. package/components/GridElementContainer.mjs +22 -0
  95. package/components/GridLoader.js +9 -0
  96. package/components/GridLoader.mjs +22 -0
  97. package/components/PagerContainer.js +9 -0
  98. package/components/PagerContainer.mjs +23 -0
  99. package/components/VirtualScrollHeightContainer.js +9 -0
  100. package/components/VirtualScrollHeightContainer.mjs +17 -0
  101. package/components/colGroup/GridColGroup.js +9 -0
  102. package/components/colGroup/GridColGroup.mjs +25 -0
  103. package/components/icons/reorder-row-svg.js +9 -0
  104. package/components/icons/reorder-row-svg.mjs +14 -0
  105. package/components/noRecords/GridNoRecords.js +9 -0
  106. package/{GridNoRecords.mjs → components/noRecords/GridNoRecords.mjs} +6 -6
  107. package/components/noRecords/GridNoRecordsContainer.js +9 -0
  108. package/components/noRecords/GridNoRecordsContainer.mjs +30 -0
  109. package/components/table/GridTable.js +9 -0
  110. package/components/table/GridTable.mjs +28 -0
  111. package/components/table/GridTableBody.js +9 -0
  112. package/components/table/GridTableBody.mjs +21 -0
  113. package/components/table/GridTableScrollable.js +9 -0
  114. package/components/table/GridTableScrollable.mjs +37 -0
  115. package/components/utils.js +8 -0
  116. package/components/utils.mjs +25 -0
  117. package/constants/index.js +1 -1
  118. package/constants/index.mjs +0 -1
  119. package/contextMenu/GridContextMenu.js +9 -0
  120. package/contextMenu/GridContextMenu.mjs +191 -0
  121. package/contextMenu/enums.js +8 -0
  122. package/contextMenu/enums.mjs +12 -0
  123. package/dist/cdn/js/kendo-react-grid.js +8 -1
  124. package/drag/ColumnDraggable.js +2 -1
  125. package/drag/ColumnDraggable.mjs +7 -7
  126. package/drag/ColumnResize.js +1 -1
  127. package/drag/ColumnResize.mjs +0 -1
  128. package/drag/CommonDragLogic.js +1 -1
  129. package/drag/CommonDragLogic.mjs +0 -1
  130. package/drag/GroupingIndicator.js +2 -1
  131. package/drag/GroupingIndicator.mjs +11 -11
  132. package/filterCommon.js +1 -1
  133. package/filterCommon.mjs +4 -5
  134. package/footer/Footer.js +2 -1
  135. package/footer/Footer.mjs +22 -21
  136. package/footer/FooterCell.js +8 -0
  137. package/footer/FooterCell.mjs +42 -0
  138. package/footer/FooterRow.js +1 -1
  139. package/footer/FooterRow.mjs +10 -40
  140. package/footer/client/FooterCellContainer.js +9 -0
  141. package/footer/client/FooterCellContainer.mjs +26 -0
  142. package/header/FilterRow.js +1 -1
  143. package/header/FilterRow.mjs +57 -55
  144. package/header/GridHeaderCell.js +2 -1
  145. package/header/GridHeaderCell.mjs +11 -11
  146. package/header/GridHeaderSelectionCell.js +2 -1
  147. package/header/GridHeaderSelectionCell.mjs +10 -9
  148. package/header/GroupPanel.js +2 -1
  149. package/header/GroupPanel.mjs +36 -32
  150. package/header/Header.js +2 -1
  151. package/header/Header.mjs +35 -33
  152. package/header/HeaderRow.js +1 -1
  153. package/header/HeaderRow.mjs +96 -126
  154. package/header/client/GridFilterCellContainer.js +9 -0
  155. package/header/client/GridFilterCellContainer.mjs +38 -0
  156. package/header/client/GridFilterCellElementContainer.js +9 -0
  157. package/header/client/GridFilterCellElementContainer.mjs +21 -0
  158. package/header/client/GridHeaderCellContainer.js +9 -0
  159. package/header/client/GridHeaderCellContainer.mjs +54 -0
  160. package/header/client/GridHeaderCellElementContainer.js +9 -0
  161. package/header/client/GridHeaderCellElementContainer.mjs +28 -0
  162. package/header/client/GridHeaderRowContainer.js +9 -0
  163. package/header/client/GridHeaderRowContainer.mjs +35 -0
  164. package/header/client/GridHeaderRowReorderCell.js +9 -0
  165. package/header/client/GridHeaderRowReorderCell.mjs +13 -0
  166. package/header/client/HeaderCellResizer.js +9 -0
  167. package/header/client/HeaderCellResizer.mjs +25 -0
  168. package/header/client/HeaderRowDraggable.js +9 -0
  169. package/header/client/HeaderRowDraggable.mjs +30 -0
  170. package/index.d.mts +601 -25
  171. package/index.d.ts +601 -25
  172. package/index.js +1 -1
  173. package/index.mjs +46 -39
  174. package/messages/index.js +1 -1
  175. package/messages/index.mjs +76 -81
  176. package/messages/messagesMap.js +8 -0
  177. package/messages/messagesMap.mjs +18 -0
  178. package/package-metadata.js +1 -1
  179. package/package-metadata.mjs +2 -3
  180. package/package.json +27 -11
  181. package/paging/GridPagerSettings.js +1 -1
  182. package/paging/GridPagerSettings.mjs +6 -7
  183. package/rows/GridDetailRow.js +1 -1
  184. package/rows/GridDetailRow.mjs +2 -3
  185. package/rows/GridRow.js +2 -1
  186. package/rows/GridRow.mjs +42 -20
  187. package/sortCommon.js +8 -0
  188. package/sortCommon.mjs +27 -0
  189. package/{interfaces/GridSortSettings.js → utils/_clientModule.js} +2 -1
  190. package/{interfaces/GridSortSettings.mjs → utils/_clientModule.mjs} +3 -2
  191. package/utils/_serverModule.js +8 -0
  192. package/utils/_serverModule.mjs +12 -0
  193. package/utils/index.js +1 -1
  194. package/utils/index.mjs +213 -102
@@ -0,0 +1,21 @@
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 n } from "../../GridClientWrapper.mjs";
11
+ import { DragAndDrop as l } from "@progress/kendo-react-common";
12
+ const p = (r) => {
13
+ const o = t.useContext(n), { children: e } = r;
14
+ return /* @__PURE__ */ t.createElement(t.Fragment, null, r.rowReorderable ? /* @__PURE__ */ t.createElement(l, null, t.cloneElement(e, { ...e == null ? void 0 : e.props })) : t.cloneElement(e, {
15
+ ...e == null ? void 0 : e.props,
16
+ ref: o.tableBodyElementRef
17
+ }));
18
+ };
19
+ export {
20
+ p as GridTableBody
21
+ };
@@ -0,0 +1,9 @@
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
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react"),c=require("../../GridClientWrapper.js"),o=require("@progress/kendo-react-data-tools");function i(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const l in e)if(l!=="default"){const a=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(t,l,a.get?a:{enumerable:!0,get:()=>e[l]})}}return t.default=e,Object.freeze(t)}const r=i(n),s=e=>{const t=r.useContext(c.GridContext);return r.createElement(o.TableSelection,{selectable:e.selectable,onRelease:t.selectionRelease,childRef:l=>{t.tableElementRef.current=l}},r.createElement("table",{className:e.tableClassName,role:"presentation",style:e.tableStyle,ref:t.tableElementRef},e.children))};exports.GridTableScrollable=s;
@@ -0,0 +1,37 @@
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 { GridContext as r } from "../../GridClientWrapper.mjs";
11
+ import { TableSelection as n } from "@progress/kendo-react-data-tools";
12
+ const m = (e) => {
13
+ const t = l.useContext(r);
14
+ return /* @__PURE__ */ l.createElement(
15
+ n,
16
+ {
17
+ selectable: e.selectable,
18
+ onRelease: t.selectionRelease,
19
+ childRef: (a) => {
20
+ t.tableElementRef.current = a;
21
+ }
22
+ },
23
+ /* @__PURE__ */ l.createElement(
24
+ "table",
25
+ {
26
+ className: e.tableClassName,
27
+ role: "presentation",
28
+ style: e.tableStyle,
29
+ ref: t.tableElementRef
30
+ },
31
+ e.children
32
+ )
33
+ );
34
+ };
35
+ export {
36
+ m as GridTableScrollable
37
+ };
@@ -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 strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s={before:"before",after:"after",forbidden:"forbidden"},u=(t,n)=>(t==null?void 0:t.parentElement)!==(n==null?void 0:n.parentElement);function r(t){const{clientTop:n,clientLeft:o}=D(t),{pageYOffset:f,pageXOffset:e}=b(t),{top:i,left:c}=t.getBoundingClientRect();return{top:i+f-n,left:c+e-o}}const D=t=>t==null?void 0:t.ownerDocument.documentElement,b=t=>t==null?void 0:t.ownerDocument.defaultView;exports.dropDirection=s;exports.getOffset=r;exports.isDifferentParent=u;
@@ -0,0 +1,25 @@
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
+ const p = {
9
+ before: "before",
10
+ after: "after",
11
+ forbidden: "forbidden"
12
+ }, D = (t, n) => (t == null ? void 0 : t.parentElement) !== (n == null ? void 0 : n.parentElement);
13
+ function b(t) {
14
+ const { clientTop: n, clientLeft: o } = e(t), { pageYOffset: f, pageXOffset: c } = u(t), { top: i, left: s } = t.getBoundingClientRect();
15
+ return {
16
+ top: i + f - n,
17
+ left: s + c - o
18
+ };
19
+ }
20
+ const e = (t) => t == null ? void 0 : t.ownerDocument.documentElement, u = (t) => t == null ? void 0 : t.ownerDocument.defaultView;
21
+ export {
22
+ p as dropDirection,
23
+ b as getOffset,
24
+ D as isDifferentParent
25
+ };
@@ -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 E=require("@progress/kendo-react-data-tools"),T=E.TABLE_ROW_INDEX_ATTRIBUTE,_=E.TABLE_COL_INDEX_ATTRIBUTE,I=E.TABLE_PREVENT_SELECTION_ELEMENT,R=/^(?!.*\bChrome).*\bSafari/i;exports.GRID_COL_INDEX_ATTRIBUTE=_;exports.GRID_PREVENT_SELECTION_ELEMENT=I;exports.GRID_ROW_INDEX_ATTRIBUTE=T;exports.SAFARI_REGEX=R;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("@progress/kendo-react-data-tools"),T=E.TABLE_ROW_INDEX_ATTRIBUTE,_=E.TABLE_COL_INDEX_ATTRIBUTE,I=E.TABLE_PREVENT_SELECTION_ELEMENT,R=/^(?!.*\bChrome).*\bSafari/i;exports.GRID_COL_INDEX_ATTRIBUTE=_;exports.GRID_PREVENT_SELECTION_ELEMENT=I;exports.GRID_ROW_INDEX_ATTRIBUTE=T;exports.SAFARI_REGEX=R;
@@ -5,7 +5,6 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use client";
9
8
  import { TABLE_ROW_INDEX_ATTRIBUTE as E, TABLE_COL_INDEX_ATTRIBUTE as T, TABLE_PREVENT_SELECTION_ELEMENT as _ } from "@progress/kendo-react-data-tools";
10
9
  const R = E, N = T, A = _, L = /^(?!.*\bChrome).*\bSafari/i;
11
10
  export {
@@ -0,0 +1,9 @@
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
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("react"),e=require("@progress/kendo-svg-icons"),R=require("@progress/kendo-react-intl"),f=require("@progress/kendo-react-layout"),t=require("./enums.js");function M(n){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const c in n)if(c!=="default"){const s=Object.getOwnPropertyDescriptor(n,c);Object.defineProperty(r,c,s.get?s:{enumerable:!0,get:()=>n[c]})}}return r.default=n,Object.freeze(r)}const m=M(w),I={[t.GridContextMenuItemNames.create]:{name:"create",text:"Add",icon:"plus",svgIcon:e.plusIcon,data:{action:"AddCommand"}},[t.GridContextMenuItemNames.edit]:{name:"edit",text:"Edit",icon:"pencil",svgIcon:e.pencilIcon,data:{action:"EditCommand"}},[t.GridContextMenuItemNames.delete]:{name:"delete",text:"Delete",icon:"trash",svgIcon:e.trashIcon,data:{action:"DeleteCommand"}},[t.GridContextMenuItemNames.select]:{name:"select",text:"Select",icon:"table-body",svgIcon:e.tableBodyIcon,items:[{name:"selectRow",text:"Row",icon:"table-row-groups",svgIcon:e.tableRowGroupsIcon,data:{action:"SelectRowCommand"}},{name:"selectAllRows",text:"All rows",icon:"grid",svgIcon:e.gridIcon,data:{action:"SelectAllRowsCommand"}},{name:"clearSelection",text:"Clear selection",icon:"table-unmerge",svgIcon:e.tableUnmergeIcon,data:{action:"ClearSelectionCommand"}}]},[t.GridContextMenuItemNames.copySelection]:{name:"copySelection",text:"Copy selection",icon:"page-header-section",svgIcon:e.pageHeaderSectionIcon,data:{action:"CopySelectionCommand"},options:"withHeaders"},[t.GridContextMenuItemNames.copySelectionNoHeaders]:{name:"copySelectionNoHeaders",text:"Copy selection (No Headers)",icon:"file-txt",svgIcon:e.fileTxtIcon,data:{action:"CopySelectionCommand"}},[t.GridContextMenuItemNames.paste]:{name:"paste",text:"Paste (use CTRL/⌘ + V)",icon:"clipboard",svgIcon:e.clipboardIcon,data:{action:"PasteCommand"}},[t.GridContextMenuItemNames.reorderRow]:{name:"reorderRow",text:"Reorder row",icon:"caret-alt-expand",svgIcon:e.caretAltExpandIcon,items:[{name:"reorderRowUp",text:"Up",icon:"caret-alt-up",svgIcon:e.caretAltUpIcon,data:{action:"ReorderRowCommand"}},{name:"reorderRowDown",text:"Down",icon:"caret-alt-down",svgIcon:e.caretAltDownIcon,data:{action:"ReorderRowCommand"}},{name:"reorderRowTop",text:"Top",icon:"caret-alt-to-top",svgIcon:e.caretAltToTopIcon,data:{action:"ReorderRowCommand"}},{name:"reorderRowBottom",text:"Bottom",icon:"caret-alt-to-bottom",svgIcon:e.caretAltToBottomIcon,data:{action:"ReorderRowCommand"}}]},[t.GridContextMenuItemNames.exportPDF]:{name:"exportPDF",text:"Export to PDF",icon:"file-pdf",svgIcon:e.filePdfIcon,data:{action:"ExportPDFCommand"}},[t.GridContextMenuItemNames.exportExcel]:{name:"exportExcel",text:"Export to Excel",icon:"file-excel",svgIcon:e.fileExcelIcon,items:[{name:"exportToExcelAll",text:"All",data:{action:"ExportExcelCommand"}},{name:"exportToExcelSelection",text:"Selection",data:{action:"ExportExcelCommand"},options:"selection,withHeaders"},{name:"exportToExcelSelectionNoHeaders",text:"Selection (No Headers)",data:{action:"ExportExcelCommand"},options:"selection"}]},[t.GridContextMenuItemNames.separator]:{name:"separator",separator:!0},[t.GridContextMenuItemNames.sortAsc]:{name:"sortAsc",text:"Sort Ascending",icon:"sort-asc-small",svgIcon:e.sortAscSmallIcon,data:{action:"SortCommand"}},[t.GridContextMenuItemNames.sortDesc]:{name:"sortDesc",text:"Sort Descending",icon:"sort-desc-small",svgIcon:e.sortDescSmallIcon,data:{action:"SortCommand"}}},v=n=>{const{show:r,offset:c,dataItem:s,field:d,items:i,onClose:u,onSelect:x}=n,p=R.useLocalization(),C=m.useCallback(a=>{x.call(void 0,{event:a,dataItem:s,field:d})},[x,s,d]),l=m.useCallback(a=>{const o=a;return o.text&&o.name&&(o.text=p.toLanguageString(`contextMenu.${o.name}`,o.text||"")),o.items&&Array.isArray(o.items)&&(o.items=o.items.map(S=>l(S))),o},[p]),g=m.useMemo(()=>i&&i.map(a=>{const o=typeof a=="string"?I[a]:a;return l(o)}),[i,l]);return m.createElement(f.ContextMenu,{show:r,offset:c,items:g,onClose:u,onSelect:C})};exports.GridContextMenu=v;exports.contextMenuItemsMap=I;
@@ -0,0 +1,191 @@
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 { plusIcon as w, pencilIcon as S, trashIcon as u, tableBodyIcon as R, tableRowGroupsIcon as f, gridIcon as v, tableUnmergeIcon as E, pageHeaderSectionIcon as A, fileTxtIcon as y, clipboardIcon as D, caretAltExpandIcon as b, caretAltUpIcon as T, caretAltDownIcon as H, caretAltToTopIcon as h, caretAltToBottomIcon as M, filePdfIcon as P, fileExcelIcon as N, sortAscSmallIcon as B, sortDescSmallIcon as F } from "@progress/kendo-svg-icons";
11
+ import { useLocalization as U } from "@progress/kendo-react-intl";
12
+ import { ContextMenu as z } from "@progress/kendo-react-layout";
13
+ import { GridContextMenuItemNames as e } from "./enums.mjs";
14
+ const G = {
15
+ [e.create]: {
16
+ name: "create",
17
+ text: "Add",
18
+ icon: "plus",
19
+ svgIcon: w,
20
+ data: { action: "AddCommand" }
21
+ },
22
+ [e.edit]: {
23
+ name: "edit",
24
+ text: "Edit",
25
+ icon: "pencil",
26
+ svgIcon: S,
27
+ data: { action: "EditCommand" }
28
+ },
29
+ [e.delete]: {
30
+ name: "delete",
31
+ text: "Delete",
32
+ icon: "trash",
33
+ svgIcon: u,
34
+ data: { action: "DeleteCommand" }
35
+ },
36
+ [e.select]: {
37
+ name: "select",
38
+ text: "Select",
39
+ icon: "table-body",
40
+ svgIcon: R,
41
+ items: [
42
+ {
43
+ name: "selectRow",
44
+ text: "Row",
45
+ icon: "table-row-groups",
46
+ svgIcon: f,
47
+ data: { action: "SelectRowCommand" }
48
+ },
49
+ {
50
+ name: "selectAllRows",
51
+ text: "All rows",
52
+ icon: "grid",
53
+ svgIcon: v,
54
+ data: { action: "SelectAllRowsCommand" }
55
+ },
56
+ {
57
+ name: "clearSelection",
58
+ text: "Clear selection",
59
+ icon: "table-unmerge",
60
+ svgIcon: E,
61
+ data: { action: "ClearSelectionCommand" }
62
+ }
63
+ ]
64
+ },
65
+ [e.copySelection]: {
66
+ name: "copySelection",
67
+ text: "Copy selection",
68
+ icon: "page-header-section",
69
+ svgIcon: A,
70
+ data: { action: "CopySelectionCommand" },
71
+ options: "withHeaders"
72
+ },
73
+ [e.copySelectionNoHeaders]: {
74
+ name: "copySelectionNoHeaders",
75
+ text: "Copy selection (No Headers)",
76
+ icon: "file-txt",
77
+ svgIcon: y,
78
+ data: { action: "CopySelectionCommand" }
79
+ },
80
+ [e.paste]: {
81
+ name: "paste",
82
+ text: "Paste (use CTRL/⌘ + V)",
83
+ icon: "clipboard",
84
+ svgIcon: D,
85
+ data: { action: "PasteCommand" }
86
+ },
87
+ [e.reorderRow]: {
88
+ name: "reorderRow",
89
+ text: "Reorder row",
90
+ icon: "caret-alt-expand",
91
+ svgIcon: b,
92
+ items: [
93
+ {
94
+ name: "reorderRowUp",
95
+ text: "Up",
96
+ icon: "caret-alt-up",
97
+ svgIcon: T,
98
+ data: { action: "ReorderRowCommand" }
99
+ },
100
+ {
101
+ name: "reorderRowDown",
102
+ text: "Down",
103
+ icon: "caret-alt-down",
104
+ svgIcon: H,
105
+ data: { action: "ReorderRowCommand" }
106
+ },
107
+ {
108
+ name: "reorderRowTop",
109
+ text: "Top",
110
+ icon: "caret-alt-to-top",
111
+ svgIcon: h,
112
+ data: { action: "ReorderRowCommand" }
113
+ },
114
+ {
115
+ name: "reorderRowBottom",
116
+ text: "Bottom",
117
+ icon: "caret-alt-to-bottom",
118
+ svgIcon: M,
119
+ data: { action: "ReorderRowCommand" }
120
+ }
121
+ ]
122
+ },
123
+ [e.exportPDF]: {
124
+ name: "exportPDF",
125
+ text: "Export to PDF",
126
+ icon: "file-pdf",
127
+ svgIcon: P,
128
+ data: { action: "ExportPDFCommand" }
129
+ },
130
+ [e.exportExcel]: {
131
+ name: "exportExcel",
132
+ text: "Export to Excel",
133
+ icon: "file-excel",
134
+ svgIcon: N,
135
+ items: [
136
+ { name: "exportToExcelAll", text: "All", data: { action: "ExportExcelCommand" } },
137
+ {
138
+ name: "exportToExcelSelection",
139
+ text: "Selection",
140
+ data: { action: "ExportExcelCommand" },
141
+ options: "selection,withHeaders"
142
+ },
143
+ {
144
+ name: "exportToExcelSelectionNoHeaders",
145
+ text: "Selection (No Headers)",
146
+ data: { action: "ExportExcelCommand" },
147
+ options: "selection"
148
+ }
149
+ ]
150
+ },
151
+ [e.separator]: { name: "separator", separator: !0 },
152
+ [e.sortAsc]: {
153
+ name: "sortAsc",
154
+ text: "Sort Ascending",
155
+ icon: "sort-asc-small",
156
+ svgIcon: B,
157
+ data: { action: "SortCommand" }
158
+ },
159
+ [e.sortDesc]: {
160
+ name: "sortDesc",
161
+ text: "Sort Descending",
162
+ icon: "sort-desc-small",
163
+ svgIcon: F,
164
+ data: { action: "SortCommand" }
165
+ }
166
+ }, j = (m) => {
167
+ const { show: d, offset: p, dataItem: r, field: i, items: n, onClose: x, onSelect: s } = m, l = U(), I = a.useCallback(
168
+ (o) => {
169
+ s.call(void 0, {
170
+ event: o,
171
+ dataItem: r,
172
+ field: i
173
+ });
174
+ },
175
+ [s, r, i]
176
+ ), c = a.useCallback(
177
+ (o) => {
178
+ const t = o;
179
+ return t.text && t.name && (t.text = l.toLanguageString(`contextMenu.${t.name}`, t.text || "")), t.items && Array.isArray(t.items) && (t.items = t.items.map((C) => c(C))), t;
180
+ },
181
+ [l]
182
+ ), g = a.useMemo(() => n && n.map((o) => {
183
+ const t = typeof o == "string" ? G[o] : o;
184
+ return c(t);
185
+ }), [n, c]);
186
+ return /* @__PURE__ */ a.createElement(z, { show: d, offset: p, items: g, onClose: x, onSelect: I });
187
+ };
188
+ export {
189
+ j as GridContextMenu,
190
+ G as contextMenuItemsMap
191
+ };
@@ -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 strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var c=(r=>(r.head="head",r.body="body",r))(c||{}),o=(r=>(r.create="create",r.edit="edit",r.delete="delete",r.select="select",r.copySelection="copySelection",r.copySelectionNoHeaders="copySelectionNoHeaders",r.paste="paste",r.reorderRow="reorderRow",r.exportPDF="exportPDF",r.exportExcel="exportExcel",r.separator="separator",r.sortAsc="sortAsc",r.sortDesc="sortDesc",r))(o||{});exports.GridContextMenuAnchorPart=c;exports.GridContextMenuItemNames=o;
@@ -0,0 +1,12 @@
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
+ var r = /* @__PURE__ */ ((c) => (c.head = "head", c.body = "body", c))(r || {}), o = /* @__PURE__ */ ((c) => (c.create = "create", c.edit = "edit", c.delete = "delete", c.select = "select", c.copySelection = "copySelection", c.copySelectionNoHeaders = "copySelectionNoHeaders", c.paste = "paste", c.reorderRow = "reorderRow", c.exportPDF = "exportPDF", c.exportExcel = "exportExcel", c.separator = "separator", c.sortAsc = "sortAsc", c.sortDesc = "sortDesc", c))(o || {});
9
+ export {
10
+ r as GridContextMenuAnchorPart,
11
+ o as GridContextMenuItemNames
12
+ };