material-react-table 1.11.3 → 1.11.5

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 (232) hide show
  1. package/README.md +1 -1
  2. package/dist/cjs/index.js +590 -817
  3. package/dist/cjs/index.js.map +1 -1
  4. package/dist/cjs/types/MaterialReactTable.d.ts +4 -5
  5. package/dist/cjs/types/_locales/hu.d.ts +2 -0
  6. package/dist/cjs/types/body/MRT_EditRowModal.d.ts +1 -2
  7. package/dist/cjs/types/body/MRT_TableBody.d.ts +3 -3
  8. package/dist/cjs/types/body/MRT_TableBodyCell.d.ts +3 -3
  9. package/dist/cjs/types/body/MRT_TableBodyCellValue.d.ts +1 -2
  10. package/dist/cjs/types/body/MRT_TableBodyRow.d.ts +3 -3
  11. package/dist/cjs/types/body/MRT_TableBodyRowGrabHandle.d.ts +1 -1
  12. package/dist/cjs/types/body/MRT_TableDetailPanel.d.ts +2 -2
  13. package/dist/cjs/types/buttons/MRT_ColumnPinningButtons.d.ts +1 -2
  14. package/dist/cjs/types/buttons/MRT_CopyButton.d.ts +1 -1
  15. package/dist/cjs/types/buttons/MRT_EditActionButtons.d.ts +1 -2
  16. package/dist/cjs/types/buttons/MRT_ExpandAllButton.d.ts +1 -2
  17. package/dist/cjs/types/buttons/MRT_ExpandButton.d.ts +1 -2
  18. package/dist/cjs/types/buttons/MRT_FullScreenToggleButton.d.ts +1 -2
  19. package/dist/cjs/types/buttons/MRT_GrabHandleButton.d.ts +1 -1
  20. package/dist/cjs/types/buttons/MRT_ShowHideColumnsButton.d.ts +1 -2
  21. package/dist/cjs/types/buttons/MRT_ToggleDensePaddingButton.d.ts +1 -2
  22. package/dist/cjs/types/buttons/MRT_ToggleFiltersButton.d.ts +1 -2
  23. package/dist/cjs/types/buttons/MRT_ToggleGlobalFilterButton.d.ts +1 -2
  24. package/dist/cjs/types/buttons/MRT_ToggleRowActionMenuButton.d.ts +1 -2
  25. package/dist/cjs/types/footer/MRT_TableFooter.d.ts +1 -2
  26. package/dist/cjs/types/footer/MRT_TableFooterCell.d.ts +1 -2
  27. package/dist/cjs/types/footer/MRT_TableFooterRow.d.ts +1 -2
  28. package/dist/cjs/types/head/MRT_TableHead.d.ts +1 -2
  29. package/dist/cjs/types/head/MRT_TableHeadCell.d.ts +1 -2
  30. package/dist/cjs/types/head/MRT_TableHeadCellColumnActionsButton.d.ts +1 -2
  31. package/dist/cjs/types/head/MRT_TableHeadCellFilterContainer.d.ts +1 -2
  32. package/dist/cjs/types/head/MRT_TableHeadCellFilterLabel.d.ts +1 -2
  33. package/dist/cjs/types/head/MRT_TableHeadCellGrabHandle.d.ts +1 -1
  34. package/dist/cjs/types/head/MRT_TableHeadCellResizeHandle.d.ts +1 -2
  35. package/dist/cjs/types/head/MRT_TableHeadCellSortLabel.d.ts +1 -2
  36. package/dist/cjs/types/head/MRT_TableHeadRow.d.ts +1 -2
  37. package/dist/cjs/types/index.d.ts +3 -2
  38. package/dist/cjs/types/inputs/MRT_EditCellTextField.d.ts +1 -2
  39. package/dist/cjs/types/inputs/MRT_FilterCheckbox.d.ts +1 -2
  40. package/dist/cjs/types/inputs/MRT_FilterRangeFields.d.ts +1 -2
  41. package/dist/cjs/types/inputs/MRT_FilterTextField.d.ts +1 -2
  42. package/dist/cjs/types/inputs/MRT_GlobalFilterTextField.d.ts +1 -2
  43. package/dist/cjs/types/inputs/MRT_SelectCheckbox.d.ts +1 -2
  44. package/dist/cjs/types/menus/MRT_ColumnActionMenu.d.ts +1 -2
  45. package/dist/cjs/types/menus/MRT_FilterOptionMenu.d.ts +1 -2
  46. package/dist/cjs/types/menus/MRT_RowActionMenu.d.ts +1 -1
  47. package/dist/cjs/types/menus/MRT_ShowHideColumnsMenu.d.ts +1 -2
  48. package/dist/cjs/types/menus/MRT_ShowHideColumnsMenuItems.d.ts +1 -1
  49. package/dist/cjs/types/table/MRT_Table.d.ts +1 -2
  50. package/dist/cjs/types/table/MRT_TableContainer.d.ts +1 -2
  51. package/dist/cjs/types/table/MRT_TablePaper.d.ts +1 -2
  52. package/dist/cjs/types/toolbar/MRT_BottomToolbar.d.ts +1 -2
  53. package/dist/cjs/types/toolbar/MRT_LinearProgressBar.d.ts +1 -2
  54. package/dist/cjs/types/toolbar/MRT_TablePagination.d.ts +1 -2
  55. package/dist/cjs/types/toolbar/MRT_ToolbarAlertBanner.d.ts +1 -2
  56. package/dist/cjs/types/toolbar/MRT_ToolbarDropZone.d.ts +1 -2
  57. package/dist/cjs/types/toolbar/MRT_ToolbarInternalButtons.d.ts +1 -2
  58. package/dist/cjs/types/toolbar/MRT_TopToolbar.d.ts +1 -2
  59. package/dist/esm/material-react-table.esm.js +511 -738
  60. package/dist/esm/material-react-table.esm.js.map +1 -1
  61. package/dist/esm/types/MaterialReactTable.d.ts +4 -5
  62. package/dist/esm/types/_locales/hu.d.ts +2 -0
  63. package/dist/esm/types/body/MRT_EditRowModal.d.ts +1 -2
  64. package/dist/esm/types/body/MRT_TableBody.d.ts +3 -3
  65. package/dist/esm/types/body/MRT_TableBodyCell.d.ts +3 -3
  66. package/dist/esm/types/body/MRT_TableBodyCellValue.d.ts +1 -2
  67. package/dist/esm/types/body/MRT_TableBodyRow.d.ts +3 -3
  68. package/dist/esm/types/body/MRT_TableBodyRowGrabHandle.d.ts +1 -1
  69. package/dist/esm/types/body/MRT_TableDetailPanel.d.ts +2 -2
  70. package/dist/esm/types/buttons/MRT_ColumnPinningButtons.d.ts +1 -2
  71. package/dist/esm/types/buttons/MRT_CopyButton.d.ts +1 -1
  72. package/dist/esm/types/buttons/MRT_EditActionButtons.d.ts +1 -2
  73. package/dist/esm/types/buttons/MRT_ExpandAllButton.d.ts +1 -2
  74. package/dist/esm/types/buttons/MRT_ExpandButton.d.ts +1 -2
  75. package/dist/esm/types/buttons/MRT_FullScreenToggleButton.d.ts +1 -2
  76. package/dist/esm/types/buttons/MRT_GrabHandleButton.d.ts +1 -1
  77. package/dist/esm/types/buttons/MRT_ShowHideColumnsButton.d.ts +1 -2
  78. package/dist/esm/types/buttons/MRT_ToggleDensePaddingButton.d.ts +1 -2
  79. package/dist/esm/types/buttons/MRT_ToggleFiltersButton.d.ts +1 -2
  80. package/dist/esm/types/buttons/MRT_ToggleGlobalFilterButton.d.ts +1 -2
  81. package/dist/esm/types/buttons/MRT_ToggleRowActionMenuButton.d.ts +1 -2
  82. package/dist/esm/types/footer/MRT_TableFooter.d.ts +1 -2
  83. package/dist/esm/types/footer/MRT_TableFooterCell.d.ts +1 -2
  84. package/dist/esm/types/footer/MRT_TableFooterRow.d.ts +1 -2
  85. package/dist/esm/types/head/MRT_TableHead.d.ts +1 -2
  86. package/dist/esm/types/head/MRT_TableHeadCell.d.ts +1 -2
  87. package/dist/esm/types/head/MRT_TableHeadCellColumnActionsButton.d.ts +1 -2
  88. package/dist/esm/types/head/MRT_TableHeadCellFilterContainer.d.ts +1 -2
  89. package/dist/esm/types/head/MRT_TableHeadCellFilterLabel.d.ts +1 -2
  90. package/dist/esm/types/head/MRT_TableHeadCellGrabHandle.d.ts +1 -1
  91. package/dist/esm/types/head/MRT_TableHeadCellResizeHandle.d.ts +1 -2
  92. package/dist/esm/types/head/MRT_TableHeadCellSortLabel.d.ts +1 -2
  93. package/dist/esm/types/head/MRT_TableHeadRow.d.ts +1 -2
  94. package/dist/esm/types/index.d.ts +3 -2
  95. package/dist/esm/types/inputs/MRT_EditCellTextField.d.ts +1 -2
  96. package/dist/esm/types/inputs/MRT_FilterCheckbox.d.ts +1 -2
  97. package/dist/esm/types/inputs/MRT_FilterRangeFields.d.ts +1 -2
  98. package/dist/esm/types/inputs/MRT_FilterTextField.d.ts +1 -2
  99. package/dist/esm/types/inputs/MRT_GlobalFilterTextField.d.ts +1 -2
  100. package/dist/esm/types/inputs/MRT_SelectCheckbox.d.ts +1 -2
  101. package/dist/esm/types/menus/MRT_ColumnActionMenu.d.ts +1 -2
  102. package/dist/esm/types/menus/MRT_FilterOptionMenu.d.ts +1 -2
  103. package/dist/esm/types/menus/MRT_RowActionMenu.d.ts +1 -1
  104. package/dist/esm/types/menus/MRT_ShowHideColumnsMenu.d.ts +1 -2
  105. package/dist/esm/types/menus/MRT_ShowHideColumnsMenuItems.d.ts +1 -1
  106. package/dist/esm/types/table/MRT_Table.d.ts +1 -2
  107. package/dist/esm/types/table/MRT_TableContainer.d.ts +1 -2
  108. package/dist/esm/types/table/MRT_TablePaper.d.ts +1 -2
  109. package/dist/esm/types/toolbar/MRT_BottomToolbar.d.ts +1 -2
  110. package/dist/esm/types/toolbar/MRT_LinearProgressBar.d.ts +1 -2
  111. package/dist/esm/types/toolbar/MRT_TablePagination.d.ts +1 -2
  112. package/dist/esm/types/toolbar/MRT_ToolbarAlertBanner.d.ts +1 -2
  113. package/dist/esm/types/toolbar/MRT_ToolbarDropZone.d.ts +1 -2
  114. package/dist/esm/types/toolbar/MRT_ToolbarInternalButtons.d.ts +1 -2
  115. package/dist/esm/types/toolbar/MRT_TopToolbar.d.ts +1 -2
  116. package/dist/index.d.ts +39 -34
  117. package/locales/cs.esm.js +91 -89
  118. package/locales/cs.js +91 -89
  119. package/locales/da.esm.js +90 -89
  120. package/locales/da.js +90 -89
  121. package/locales/de.esm.js +90 -89
  122. package/locales/de.js +90 -89
  123. package/locales/en.esm.js +90 -89
  124. package/locales/en.js +90 -89
  125. package/locales/es.esm.js +90 -89
  126. package/locales/es.js +90 -89
  127. package/locales/fa.esm.js +90 -89
  128. package/locales/fa.js +90 -89
  129. package/locales/fi.esm.js +91 -89
  130. package/locales/fi.js +91 -89
  131. package/locales/fr.esm.js +90 -89
  132. package/locales/fr.js +90 -89
  133. package/locales/hu.d.ts +2 -0
  134. package/locales/hu.esm.d.ts +2 -0
  135. package/locales/hu.esm.js +95 -0
  136. package/locales/hu.esm.js.map +1 -0
  137. package/locales/hu.js +99 -0
  138. package/locales/hu.js.map +1 -0
  139. package/locales/id.esm.js +91 -89
  140. package/locales/id.js +91 -89
  141. package/locales/it.esm.js +90 -89
  142. package/locales/it.js +90 -89
  143. package/locales/ja.esm.js +90 -89
  144. package/locales/ja.js +90 -89
  145. package/locales/nl.esm.js +90 -89
  146. package/locales/nl.js +90 -89
  147. package/locales/pl.esm.js +90 -89
  148. package/locales/pl.js +90 -89
  149. package/locales/pt-BR.esm.js +90 -89
  150. package/locales/pt-BR.js +90 -89
  151. package/locales/pt.esm.js +90 -89
  152. package/locales/pt.js +90 -89
  153. package/locales/ro.esm.js +90 -89
  154. package/locales/ro.js +90 -89
  155. package/locales/ru.esm.js +90 -89
  156. package/locales/ru.js +90 -89
  157. package/locales/sk.esm.js +91 -89
  158. package/locales/sk.js +91 -89
  159. package/locales/sr-Cyrl-RS.esm.js +90 -89
  160. package/locales/sr-Cyrl-RS.js +90 -89
  161. package/locales/sr-Latn-RS.esm.js +90 -89
  162. package/locales/sr-Latn-RS.js +90 -89
  163. package/locales/sv.esm.js +90 -89
  164. package/locales/sv.js +90 -89
  165. package/locales/tr.esm.js +90 -89
  166. package/locales/tr.js +90 -89
  167. package/locales/uk.esm.js +90 -89
  168. package/locales/uk.js +90 -89
  169. package/locales/vi.esm.js +90 -89
  170. package/locales/vi.js +90 -89
  171. package/locales/zh-Hans.esm.js +89 -89
  172. package/locales/zh-Hans.js +89 -89
  173. package/locales/zh-Hant.esm.js +89 -89
  174. package/locales/zh-Hant.js +89 -89
  175. package/package.json +33 -15
  176. package/src/MaterialReactTable.tsx +5 -5
  177. package/src/_locales/hu.ts +94 -0
  178. package/src/body/MRT_EditRowModal.tsx +0 -1
  179. package/src/body/MRT_TableBody.tsx +6 -1
  180. package/src/body/MRT_TableBodyCell.tsx +1 -1
  181. package/src/body/MRT_TableBodyCellValue.tsx +1 -1
  182. package/src/body/MRT_TableBodyRow.tsx +1 -1
  183. package/src/body/MRT_TableBodyRowGrabHandle.tsx +1 -1
  184. package/src/body/MRT_TableDetailPanel.tsx +1 -1
  185. package/src/buttons/MRT_ColumnPinningButtons.tsx +0 -1
  186. package/src/buttons/MRT_CopyButton.tsx +1 -1
  187. package/src/buttons/MRT_EditActionButtons.tsx +0 -1
  188. package/src/buttons/MRT_ExpandAllButton.tsx +0 -1
  189. package/src/buttons/MRT_ExpandButton.tsx +1 -1
  190. package/src/buttons/MRT_FullScreenToggleButton.tsx +0 -1
  191. package/src/buttons/MRT_GrabHandleButton.tsx +1 -1
  192. package/src/buttons/MRT_ShowHideColumnsButton.tsx +1 -1
  193. package/src/buttons/MRT_ToggleDensePaddingButton.tsx +0 -1
  194. package/src/buttons/MRT_ToggleFiltersButton.tsx +0 -1
  195. package/src/buttons/MRT_ToggleGlobalFilterButton.tsx +0 -1
  196. package/src/buttons/MRT_ToggleRowActionMenuButton.tsx +1 -1
  197. package/src/column.utils.ts +9 -7
  198. package/src/footer/MRT_TableFooter.tsx +0 -1
  199. package/src/footer/MRT_TableFooterCell.tsx +0 -1
  200. package/src/footer/MRT_TableFooterRow.tsx +0 -1
  201. package/src/head/MRT_TableHead.tsx +0 -1
  202. package/src/head/MRT_TableHeadCell.tsx +1 -1
  203. package/src/head/MRT_TableHeadCellColumnActionsButton.tsx +1 -1
  204. package/src/head/MRT_TableHeadCellFilterContainer.tsx +0 -1
  205. package/src/head/MRT_TableHeadCellFilterLabel.tsx +1 -1
  206. package/src/head/MRT_TableHeadCellGrabHandle.tsx +1 -1
  207. package/src/head/MRT_TableHeadCellResizeHandle.tsx +0 -1
  208. package/src/head/MRT_TableHeadCellSortLabel.tsx +0 -1
  209. package/src/head/MRT_TableHeadRow.tsx +0 -1
  210. package/src/index.tsx +4 -2
  211. package/src/inputs/MRT_EditCellTextField.tsx +1 -1
  212. package/src/inputs/MRT_FilterCheckbox.tsx +0 -1
  213. package/src/inputs/MRT_FilterRangeFields.tsx +0 -1
  214. package/src/inputs/MRT_FilterTextField.tsx +1 -1
  215. package/src/inputs/MRT_GlobalFilterTextField.tsx +1 -1
  216. package/src/inputs/MRT_SelectCheckbox.tsx +1 -1
  217. package/src/menus/MRT_ColumnActionMenu.tsx +21 -16
  218. package/src/menus/MRT_FilterOptionMenu.tsx +1 -1
  219. package/src/menus/MRT_RowActionMenu.tsx +1 -1
  220. package/src/menus/MRT_ShowHideColumnsMenu.tsx +1 -1
  221. package/src/menus/MRT_ShowHideColumnsMenuItems.tsx +1 -7
  222. package/src/table/MRT_Table.tsx +1 -1
  223. package/src/table/MRT_TableContainer.tsx +1 -1
  224. package/src/table/MRT_TablePaper.tsx +0 -1
  225. package/src/table/MRT_TableRoot.tsx +16 -16
  226. package/src/toolbar/MRT_BottomToolbar.tsx +0 -1
  227. package/src/toolbar/MRT_LinearProgressBar.tsx +0 -1
  228. package/src/toolbar/MRT_TablePagination.tsx +1 -1
  229. package/src/toolbar/MRT_ToolbarAlertBanner.tsx +1 -1
  230. package/src/toolbar/MRT_ToolbarDropZone.tsx +1 -1
  231. package/src/toolbar/MRT_ToolbarInternalButtons.tsx +0 -1
  232. package/src/toolbar/MRT_TopToolbar.tsx +0 -1
package/dist/cjs/index.js CHANGED
@@ -2,7 +2,8 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var React = require('react');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+ var react = require('react');
6
7
  var reactTable = require('@tanstack/react-table');
7
8
  var styles = require('@mui/material/styles');
8
9
  var matchSorterUtils = require('@tanstack/match-sorter-utils');
@@ -81,7 +82,6 @@ var Stack = require('@mui/material/Stack');
81
82
 
82
83
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
83
84
 
84
- var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
85
85
  var ArrowDownwardIcon__default = /*#__PURE__*/_interopDefaultLegacy(ArrowDownwardIcon);
86
86
  var ArrowRightIcon__default = /*#__PURE__*/_interopDefaultLegacy(ArrowRightIcon);
87
87
  var CancelIcon__default = /*#__PURE__*/_interopDefaultLegacy(CancelIcon);
@@ -245,8 +245,9 @@ const reorderColumn = (draggedColumn, targetColumn, columnOrder) => {
245
245
  if (draggedColumn.getCanPin()) {
246
246
  draggedColumn.pin(targetColumn.getIsPinned());
247
247
  }
248
- columnOrder.splice(columnOrder.indexOf(targetColumn.id), 0, columnOrder.splice(columnOrder.indexOf(draggedColumn.id), 1)[0]);
249
- return [...columnOrder];
248
+ let newColumnOrder = [...columnOrder];
249
+ newColumnOrder.splice(newColumnOrder.indexOf(targetColumn.id), 0, newColumnOrder.splice(newColumnOrder.indexOf(draggedColumn.id), 1)[0]);
250
+ return newColumnOrder;
250
251
  };
251
252
  const showExpandColumn = (props, grouping) => !!(props.enableExpanding ||
252
253
  (props.enableGrouping && (grouping === undefined || (grouping === null || grouping === void 0 ? void 0 : grouping.length))) ||
@@ -314,7 +315,10 @@ const getIsFirstRightPinnedColumn = (column) => {
314
315
  return column.getIsPinned() === 'right' && column.getPinnedIndex() === 0;
315
316
  };
316
317
  const getTotalRight = (table, column) => {
317
- return ((table.getRightLeafHeaders().length - 1 - column.getPinnedIndex()) * 200);
318
+ return table
319
+ .getRightLeafHeaders()
320
+ .slice(column.getPinnedIndex() + 1)
321
+ .reduce((acc, col) => acc + col.getSize(), 0);
318
322
  };
319
323
  const getCommonCellStyles = ({ column, header, table, tableCellProps, theme, }) => {
320
324
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
@@ -515,16 +519,14 @@ const MRT_ExpandAllButton = ({ table }) => {
515
519
  ? muiExpandAllButtonProps({ table })
516
520
  : muiExpandAllButtonProps;
517
521
  const isAllRowsExpanded = getIsAllRowsExpanded();
518
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: ((_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : isAllRowsExpanded)
522
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: ((_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : isAllRowsExpanded)
519
523
  ? localization.collapseAll
520
- : localization.expandAll },
521
- React__default["default"].createElement("span", null,
522
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.expandAll, disabled: isLoading || (!renderDetailPanel && !getCanSomeRowsExpand()), onClick: () => toggleAllRowsExpanded(!isAllRowsExpanded) }, iconButtonProps, { sx: (theme) => (Object.assign({ height: density === 'compact' ? '1.75rem' : '2.25rem', width: density === 'compact' ? '1.75rem' : '2.25rem', mt: density !== 'compact' ? '-0.25rem' : undefined }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
524
+ : localization.expandAll }, { children: jsxRuntime.jsx("span", { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.expandAll, disabled: isLoading || (!renderDetailPanel && !getCanSomeRowsExpand()), onClick: () => toggleAllRowsExpanded(!isAllRowsExpanded) }, iconButtonProps, { sx: (theme) => (Object.assign({ height: density === 'compact' ? '1.75rem' : '2.25rem', width: density === 'compact' ? '1.75rem' : '2.25rem', mt: density !== 'compact' ? '-0.25rem' : undefined }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
523
525
  ? iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx(theme)
524
- : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }), (_b = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.children) !== null && _b !== void 0 ? _b : (React__default["default"].createElement(KeyboardDoubleArrowDownIcon, { style: {
525
- transform: `rotate(${isAllRowsExpanded ? -180 : getIsSomeRowsExpanded() ? -90 : 0}deg)`,
526
- transition: 'transform 150ms',
527
- } }))))));
526
+ : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }, { children: (_b = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.children) !== null && _b !== void 0 ? _b : (jsxRuntime.jsx(KeyboardDoubleArrowDownIcon, { style: {
527
+ transform: `rotate(${isAllRowsExpanded ? -180 : getIsSomeRowsExpanded() ? -90 : 0}deg)`,
528
+ transition: 'transform 150ms',
529
+ } })) })) }) })));
528
530
  };
529
531
 
530
532
  const MRT_ExpandButton = ({ row, table, }) => {
@@ -542,16 +544,14 @@ const MRT_ExpandButton = ({ row, table, }) => {
542
544
  row.toggleExpanded();
543
545
  (_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.onClick) === null || _a === void 0 ? void 0 : _a.call(iconButtonProps, event);
544
546
  };
545
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, disableHoverListener: !canExpand && !renderDetailPanel, enterDelay: 1000, enterNextDelay: 1000, title: ((_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : isExpanded)
547
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, disableHoverListener: !canExpand && !renderDetailPanel, enterDelay: 1000, enterNextDelay: 1000, title: ((_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : isExpanded)
546
548
  ? localization.collapse
547
- : localization.expand },
548
- React__default["default"].createElement("span", null,
549
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.expand, disabled: !canExpand && !renderDetailPanel }, iconButtonProps, { onClick: handleToggleExpand, sx: (theme) => (Object.assign({ height: density === 'compact' ? '1.75rem' : '2.25rem', width: density === 'compact' ? '1.75rem' : '2.25rem' }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
549
+ : localization.expand }, { children: jsxRuntime.jsx("span", { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.expand, disabled: !canExpand && !renderDetailPanel }, iconButtonProps, { onClick: handleToggleExpand, sx: (theme) => (Object.assign({ height: density === 'compact' ? '1.75rem' : '2.25rem', width: density === 'compact' ? '1.75rem' : '2.25rem' }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
550
550
  ? iconButtonProps.sx(theme)
551
- : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }), (_b = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.children) !== null && _b !== void 0 ? _b : (React__default["default"].createElement(ExpandMoreIcon, { style: {
552
- transform: `rotate(${!canExpand && !renderDetailPanel ? -90 : isExpanded ? -180 : 0}deg)`,
553
- transition: 'transform 150ms',
554
- } }))))));
551
+ : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }, { children: (_b = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.children) !== null && _b !== void 0 ? _b : (jsxRuntime.jsx(ExpandMoreIcon, { style: {
552
+ transform: `rotate(${!canExpand && !renderDetailPanel ? -90 : isExpanded ? -180 : 0}deg)`,
553
+ transition: 'transform 150ms',
554
+ } })) })) }) })));
555
555
  };
556
556
 
557
557
  const mrtFilterOptions = (localization) => [
@@ -651,7 +651,7 @@ const MRT_FilterOptionMenu = ({ anchorEl, header, onSelect, setAnchorEl, setFilt
651
651
  const { columnDef } = column !== null && column !== void 0 ? column : {};
652
652
  const currentFilterValue = column === null || column === void 0 ? void 0 : column.getFilterValue();
653
653
  const allowedColumnFilterOptions = (_a = columnDef === null || columnDef === void 0 ? void 0 : columnDef.columnFilterModeOptions) !== null && _a !== void 0 ? _a : columnFilterModeOptions;
654
- const internalFilterOptions = React.useMemo(() => mrtFilterOptions(localization).filter((filterOption) => columnDef
654
+ const internalFilterOptions = react.useMemo(() => mrtFilterOptions(localization).filter((filterOption) => columnDef
655
655
  ? allowedColumnFilterOptions === undefined ||
656
656
  (allowedColumnFilterOptions === null || allowedColumnFilterOptions === void 0 ? void 0 : allowedColumnFilterOptions.includes(filterOption.option))
657
657
  : (!globalFilterModeOptions ||
@@ -718,33 +718,31 @@ const MRT_FilterOptionMenu = ({ anchorEl, header, onSelect, setAnchorEl, setFilt
718
718
  onSelect === null || onSelect === void 0 ? void 0 : onSelect();
719
719
  };
720
720
  const filterOption = !!header && columnDef ? columnDef._filterFn : globalFilterFn;
721
- return (React__default["default"].createElement(Menu__default["default"], { anchorEl: anchorEl, anchorOrigin: { vertical: 'center', horizontal: 'right' }, onClose: () => setAnchorEl(null), open: !!anchorEl, MenuListProps: {
721
+ return (jsxRuntime.jsx(Menu__default["default"], Object.assign({ anchorEl: anchorEl, anchorOrigin: { vertical: 'center', horizontal: 'right' }, onClose: () => setAnchorEl(null), open: !!anchorEl, MenuListProps: {
722
722
  dense: density === 'compact',
723
- } }, (_d = (header && column && columnDef
724
- ? (_c = (_b = columnDef.renderColumnFilterModeMenuItems) === null || _b === void 0 ? void 0 : _b.call(columnDef, {
725
- column: column,
726
- internalFilterOptions,
727
- onSelectFilterMode: handleSelectFilterMode,
728
- table,
729
- })) !== null && _c !== void 0 ? _c : renderColumnFilterModeMenuItems === null || renderColumnFilterModeMenuItems === void 0 ? void 0 : renderColumnFilterModeMenuItems({
730
- column: column,
731
- internalFilterOptions,
732
- onSelectFilterMode: handleSelectFilterMode,
733
- table,
734
- })
735
- : renderGlobalFilterModeMenuItems === null || renderGlobalFilterModeMenuItems === void 0 ? void 0 : renderGlobalFilterModeMenuItems({
736
- internalFilterOptions,
737
- onSelectFilterMode: handleSelectFilterMode,
738
- table,
739
- }))) !== null && _d !== void 0 ? _d : internalFilterOptions.map(({ option, label, divider, symbol }, index) => (React__default["default"].createElement(MenuItem__default["default"], { divider: divider, key: index, onClick: () => handleSelectFilterMode(option), selected: option === filterOption, sx: {
740
- alignItems: 'center',
741
- display: 'flex',
742
- gap: '2ch',
743
- my: 0,
744
- py: '6px',
745
- }, value: option },
746
- React__default["default"].createElement(Box__default["default"], { sx: { fontSize: '1.25rem', width: '2ch' } }, symbol),
747
- label)))));
723
+ } }, { children: (_d = (header && column && columnDef
724
+ ? (_c = (_b = columnDef.renderColumnFilterModeMenuItems) === null || _b === void 0 ? void 0 : _b.call(columnDef, {
725
+ column: column,
726
+ internalFilterOptions,
727
+ onSelectFilterMode: handleSelectFilterMode,
728
+ table,
729
+ })) !== null && _c !== void 0 ? _c : renderColumnFilterModeMenuItems === null || renderColumnFilterModeMenuItems === void 0 ? void 0 : renderColumnFilterModeMenuItems({
730
+ column: column,
731
+ internalFilterOptions,
732
+ onSelectFilterMode: handleSelectFilterMode,
733
+ table,
734
+ })
735
+ : renderGlobalFilterModeMenuItems === null || renderGlobalFilterModeMenuItems === void 0 ? void 0 : renderGlobalFilterModeMenuItems({
736
+ internalFilterOptions,
737
+ onSelectFilterMode: handleSelectFilterMode,
738
+ table,
739
+ }))) !== null && _d !== void 0 ? _d : internalFilterOptions.map(({ option, label, divider, symbol }, index) => (jsxRuntime.jsxs(MenuItem__default["default"], Object.assign({ divider: divider, onClick: () => handleSelectFilterMode(option), selected: option === filterOption, sx: {
740
+ alignItems: 'center',
741
+ display: 'flex',
742
+ gap: '2ch',
743
+ my: 0,
744
+ py: '6px',
745
+ }, value: option }, { children: [jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: { fontSize: '1.25rem', width: '2ch' } }, { children: symbol })), label] }), index))) })));
748
746
  };
749
747
 
750
748
  const commonMenuItemStyles = {
@@ -759,11 +757,11 @@ const commonListItemStyles = {
759
757
  };
760
758
  const MRT_ColumnActionMenu = ({ anchorEl, header, setAnchorEl, table, }) => {
761
759
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
762
- const { getState, toggleAllColumnsVisible, setColumnOrder, options: { columnFilterModeOptions, enableColumnFilterModes, enableColumnFilters, enableColumnResizing, enableGrouping, enableHiding, enablePinning, enableSorting, icons: { ArrowRightIcon, ClearAllIcon, ViewColumnIcon, DynamicFeedIcon, FilterListIcon, FilterListOffIcon, PushPinIcon, SortIcon, RestartAltIcon, VisibilityOffIcon, }, localization, renderColumnActionsMenuItems, }, refs: { filterInputRefs }, setColumnSizingInfo, setShowColumnFilters, } = table;
760
+ const { getState, toggleAllColumnsVisible, setColumnOrder, options: { columnFilterModeOptions, enableColumnFilterModes, enableColumnFilters, enableColumnResizing, enableGrouping, enableHiding, enablePinning, enableSorting, enableSortingRemoval, icons: { ArrowRightIcon, ClearAllIcon, ViewColumnIcon, DynamicFeedIcon, FilterListIcon, FilterListOffIcon, PushPinIcon, SortIcon, RestartAltIcon, VisibilityOffIcon, }, localization, renderColumnActionsMenuItems, }, refs: { filterInputRefs }, setColumnSizingInfo, setShowColumnFilters, } = table;
763
761
  const { column } = header;
764
762
  const { columnDef } = column;
765
763
  const { columnSizing, columnVisibility, density, showColumnFilters } = getState();
766
- const [filterMenuAnchorEl, setFilterMenuAnchorEl] = React.useState(null);
764
+ const [filterMenuAnchorEl, setFilterMenuAnchorEl] = react.useState(null);
767
765
  const handleClearSort = () => {
768
766
  column.clearSorting();
769
767
  setAnchorEl(null);
@@ -818,120 +816,60 @@ const MRT_ColumnActionMenu = ({ anchorEl, header, setAnchorEl, table, }) => {
818
816
  !isSelectFilter &&
819
817
  (allowedColumnFilterOptions === undefined ||
820
818
  !!(allowedColumnFilterOptions === null || allowedColumnFilterOptions === void 0 ? void 0 : allowedColumnFilterOptions.length));
821
- return (React__default["default"].createElement(Menu__default["default"], { anchorEl: anchorEl, open: !!anchorEl, onClose: () => setAnchorEl(null), MenuListProps: {
819
+ return (jsxRuntime.jsxs(Menu__default["default"], Object.assign({ anchorEl: anchorEl, open: !!anchorEl, onClose: () => setAnchorEl(null), MenuListProps: {
822
820
  dense: density === 'compact',
823
- } }, (_d = (_c = (_b = columnDef.renderColumnActionsMenuItems) === null || _b === void 0 ? void 0 : _b.call(columnDef, {
824
- closeMenu: () => setAnchorEl(null),
825
- column,
826
- table,
827
- })) !== null && _c !== void 0 ? _c : renderColumnActionsMenuItems === null || renderColumnActionsMenuItems === void 0 ? void 0 : renderColumnActionsMenuItems({
828
- closeMenu: () => setAnchorEl(null),
829
- column,
830
- table,
831
- })) !== null && _d !== void 0 ? _d : (enableSorting &&
832
- column.getCanSort() && [
833
- React__default["default"].createElement(MenuItem__default["default"], { disabled: !column.getIsSorted(), key: 0, onClick: handleClearSort, sx: commonMenuItemStyles },
834
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
835
- React__default["default"].createElement(ListItemIcon__default["default"], null,
836
- React__default["default"].createElement(ClearAllIcon, null)),
837
- localization.clearSort)),
838
- React__default["default"].createElement(MenuItem__default["default"], { disabled: column.getIsSorted() === 'asc', key: 1, onClick: handleSortAsc, sx: commonMenuItemStyles },
839
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
840
- React__default["default"].createElement(ListItemIcon__default["default"], null,
841
- React__default["default"].createElement(SortIcon, { style: { transform: 'rotate(180deg) scaleX(-1)' } })), (_e = localization.sortByColumnAsc) === null || _e === void 0 ? void 0 :
842
- _e.replace('{column}', String(columnDef.header)))),
843
- React__default["default"].createElement(MenuItem__default["default"], { divider: enableColumnFilters || enableGrouping || enableHiding, key: 2, disabled: column.getIsSorted() === 'desc', onClick: handleSortDesc, sx: commonMenuItemStyles },
844
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
845
- React__default["default"].createElement(ListItemIcon__default["default"], null,
846
- React__default["default"].createElement(SortIcon, null)), (_f = localization.sortByColumnDesc) === null || _f === void 0 ? void 0 :
847
- _f.replace('{column}', String(columnDef.header)))),
848
- ]),
849
- enableColumnFilters &&
850
- column.getCanFilter() &&
851
- [
852
- React__default["default"].createElement(MenuItem__default["default"], { disabled: !column.getFilterValue(), key: 0, onClick: handleClearFilter, sx: commonMenuItemStyles },
853
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
854
- React__default["default"].createElement(ListItemIcon__default["default"], null,
855
- React__default["default"].createElement(FilterListOffIcon, null)),
856
- localization.clearFilter)),
857
- React__default["default"].createElement(MenuItem__default["default"], { disabled: showColumnFilters && !enableColumnFilterModes, divider: enableGrouping || enableHiding, key: 1, onClick: showColumnFilters
858
- ? handleOpenFilterModeMenu
859
- : handleFilterByColumn, sx: commonMenuItemStyles },
860
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
861
- React__default["default"].createElement(ListItemIcon__default["default"], null,
862
- React__default["default"].createElement(FilterListIcon, null)), (_g = localization.filterByColumn) === null || _g === void 0 ? void 0 :
863
- _g.replace('{column}', String(columnDef.header))),
864
- showFilterModeSubMenu && (React__default["default"].createElement(IconButton__default["default"], { onClick: handleOpenFilterModeMenu, onMouseEnter: handleOpenFilterModeMenu, size: "small", sx: { p: 0 } },
865
- React__default["default"].createElement(ArrowRightIcon, null)))),
866
- showFilterModeSubMenu && (React__default["default"].createElement(MRT_FilterOptionMenu, { anchorEl: filterMenuAnchorEl, header: header, key: 2, onSelect: handleFilterByColumn, setAnchorEl: setFilterMenuAnchorEl, table: table })),
867
- ].filter(Boolean),
868
- enableGrouping &&
869
- column.getCanGroup() && [
870
- React__default["default"].createElement(MenuItem__default["default"], { divider: enablePinning, key: 0, onClick: handleGroupByColumn, sx: commonMenuItemStyles },
871
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
872
- React__default["default"].createElement(ListItemIcon__default["default"], null,
873
- React__default["default"].createElement(DynamicFeedIcon, null)), (_h = localization[column.getIsGrouped() ? 'ungroupByColumn' : 'groupByColumn']) === null || _h === void 0 ? void 0 :
874
- _h.replace('{column}', String(columnDef.header)))),
875
- ],
876
- enablePinning &&
877
- column.getCanPin() && [
878
- React__default["default"].createElement(MenuItem__default["default"], { disabled: column.getIsPinned() === 'left' || !column.getCanPin(), key: 0, onClick: () => handlePinColumn('left'), sx: commonMenuItemStyles },
879
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
880
- React__default["default"].createElement(ListItemIcon__default["default"], null,
881
- React__default["default"].createElement(PushPinIcon, { style: { transform: 'rotate(90deg)' } })),
882
- localization.pinToLeft)),
883
- React__default["default"].createElement(MenuItem__default["default"], { disabled: column.getIsPinned() === 'right' || !column.getCanPin(), key: 1, onClick: () => handlePinColumn('right'), sx: commonMenuItemStyles },
884
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
885
- React__default["default"].createElement(ListItemIcon__default["default"], null,
886
- React__default["default"].createElement(PushPinIcon, { style: { transform: 'rotate(-90deg)' } })),
887
- localization.pinToRight)),
888
- React__default["default"].createElement(MenuItem__default["default"], { disabled: !column.getIsPinned(), divider: enableHiding, key: 2, onClick: () => handlePinColumn(false), sx: commonMenuItemStyles },
889
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
890
- React__default["default"].createElement(ListItemIcon__default["default"], null,
891
- React__default["default"].createElement(PushPinIcon, null)),
892
- localization.unpin)),
893
- ],
894
- enableColumnResizing &&
895
- column.getCanResize() && [
896
- React__default["default"].createElement(MenuItem__default["default"], { disabled: !columnSizing[column.id], key: 0, onClick: handleResetColumnSize, sx: commonMenuItemStyles },
897
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
898
- React__default["default"].createElement(ListItemIcon__default["default"], null,
899
- React__default["default"].createElement(RestartAltIcon, null)),
900
- localization.resetColumnSize)),
901
- ],
902
- enableHiding && [
903
- React__default["default"].createElement(MenuItem__default["default"], { disabled: !column.getCanHide(), key: 0, onClick: handleHideColumn, sx: commonMenuItemStyles },
904
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
905
- React__default["default"].createElement(ListItemIcon__default["default"], null,
906
- React__default["default"].createElement(VisibilityOffIcon, null)), (_j = localization.hideColumn) === null || _j === void 0 ? void 0 :
907
- _j.replace('{column}', String(columnDef.header)))),
908
- React__default["default"].createElement(MenuItem__default["default"], { disabled: !Object.values(columnVisibility).filter((visible) => !visible)
909
- .length, key: 1, onClick: handleShowAllColumns, sx: commonMenuItemStyles },
910
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
911
- React__default["default"].createElement(ListItemIcon__default["default"], null,
912
- React__default["default"].createElement(ViewColumnIcon, null)), (_k = localization.showAllColumns) === null || _k === void 0 ? void 0 :
913
- _k.replace('{column}', String(columnDef.header)))),
914
- ]));
821
+ } }, { children: [(_d = (_c = (_b = columnDef.renderColumnActionsMenuItems) === null || _b === void 0 ? void 0 : _b.call(columnDef, {
822
+ closeMenu: () => setAnchorEl(null),
823
+ column,
824
+ table,
825
+ })) !== null && _c !== void 0 ? _c : renderColumnActionsMenuItems === null || renderColumnActionsMenuItems === void 0 ? void 0 : renderColumnActionsMenuItems({
826
+ closeMenu: () => setAnchorEl(null),
827
+ column,
828
+ table,
829
+ })) !== null && _d !== void 0 ? _d : (enableSorting &&
830
+ column.getCanSort() &&
831
+ [
832
+ enableSortingRemoval !== false && (jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: !column.getIsSorted(), onClick: handleClearSort, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(ClearAllIcon, {}) }), localization.clearSort] })) }), 0)),
833
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: column.getIsSorted() === 'asc', onClick: handleSortAsc, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(SortIcon, { style: { transform: 'rotate(180deg) scaleX(-1)' } }) }), (_e = localization.sortByColumnAsc) === null || _e === void 0 ? void 0 : _e.replace('{column}', String(columnDef.header))] })) }), 1),
834
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ divider: enableColumnFilters || enableGrouping || enableHiding, disabled: column.getIsSorted() === 'desc', onClick: handleSortDesc, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(SortIcon, {}) }), (_f = localization.sortByColumnDesc) === null || _f === void 0 ? void 0 : _f.replace('{column}', String(columnDef.header))] })) }), 2),
835
+ ].filter(Boolean)), enableColumnFilters &&
836
+ column.getCanFilter() &&
837
+ [
838
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: !column.getFilterValue(), onClick: handleClearFilter, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(FilterListOffIcon, {}) }), localization.clearFilter] })) }), 0),
839
+ jsxRuntime.jsxs(MenuItem__default["default"], Object.assign({ disabled: showColumnFilters && !enableColumnFilterModes, divider: enableGrouping || enableHiding, onClick: showColumnFilters
840
+ ? handleOpenFilterModeMenu
841
+ : handleFilterByColumn, sx: commonMenuItemStyles }, { children: [jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(FilterListIcon, {}) }), (_g = localization.filterByColumn) === null || _g === void 0 ? void 0 : _g.replace('{column}', String(columnDef.header))] })), showFilterModeSubMenu && (jsxRuntime.jsx(IconButton__default["default"], Object.assign({ onClick: handleOpenFilterModeMenu, onMouseEnter: handleOpenFilterModeMenu, size: "small", sx: { p: 0 } }, { children: jsxRuntime.jsx(ArrowRightIcon, {}) })))] }), 1),
842
+ showFilterModeSubMenu && (jsxRuntime.jsx(MRT_FilterOptionMenu, { anchorEl: filterMenuAnchorEl, header: header, onSelect: handleFilterByColumn, setAnchorEl: setFilterMenuAnchorEl, table: table }, 2)),
843
+ ].filter(Boolean), enableGrouping &&
844
+ column.getCanGroup() && [
845
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ divider: enablePinning, onClick: handleGroupByColumn, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(DynamicFeedIcon, {}) }), (_h = localization[column.getIsGrouped() ? 'ungroupByColumn' : 'groupByColumn']) === null || _h === void 0 ? void 0 : _h.replace('{column}', String(columnDef.header))] })) }), 0),
846
+ ], enablePinning &&
847
+ column.getCanPin() && [
848
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: column.getIsPinned() === 'left' || !column.getCanPin(), onClick: () => handlePinColumn('left'), sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(PushPinIcon, { style: { transform: 'rotate(90deg)' } }) }), localization.pinToLeft] })) }), 0),
849
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: column.getIsPinned() === 'right' || !column.getCanPin(), onClick: () => handlePinColumn('right'), sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(PushPinIcon, { style: { transform: 'rotate(-90deg)' } }) }), localization.pinToRight] })) }), 1),
850
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: !column.getIsPinned(), divider: enableHiding, onClick: () => handlePinColumn(false), sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(PushPinIcon, {}) }), localization.unpin] })) }), 2),
851
+ ], enableColumnResizing &&
852
+ column.getCanResize() && [
853
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: !columnSizing[column.id], onClick: handleResetColumnSize, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(RestartAltIcon, {}) }), localization.resetColumnSize] })) }), 0),
854
+ ], enableHiding && [
855
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: !column.getCanHide(), onClick: handleHideColumn, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(VisibilityOffIcon, {}) }), (_j = localization.hideColumn) === null || _j === void 0 ? void 0 : _j.replace('{column}', String(columnDef.header))] })) }), 0),
856
+ jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disabled: !Object.values(columnVisibility).filter((visible) => !visible)
857
+ .length, onClick: handleShowAllColumns, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(ViewColumnIcon, {}) }), (_k = localization.showAllColumns) === null || _k === void 0 ? void 0 : _k.replace('{column}', String(columnDef.header))] })) }), 1),
858
+ ]] })));
915
859
  };
916
860
 
917
861
  const MRT_RowActionMenu = ({ anchorEl, handleEdit, row, setAnchorEl, table, }) => {
918
862
  const { getState, options: { icons: { EditIcon }, enableEditing, localization, renderRowActionMenuItems, }, } = table;
919
863
  const { density } = getState();
920
- return (React__default["default"].createElement(Menu__default["default"], { anchorEl: anchorEl, open: !!anchorEl, onClick: (event) => event.stopPropagation(), onClose: () => setAnchorEl(null), MenuListProps: {
864
+ return (jsxRuntime.jsxs(Menu__default["default"], Object.assign({ anchorEl: anchorEl, open: !!anchorEl, onClick: (event) => event.stopPropagation(), onClose: () => setAnchorEl(null), MenuListProps: {
921
865
  dense: density === 'compact',
922
- } },
923
- enableEditing instanceof Function
924
- ? enableEditing(row)
925
- : enableEditing && (React__default["default"].createElement(MenuItem__default["default"], { onClick: handleEdit, sx: commonMenuItemStyles },
926
- React__default["default"].createElement(Box__default["default"], { sx: commonListItemStyles },
927
- React__default["default"].createElement(ListItemIcon__default["default"], null,
928
- React__default["default"].createElement(EditIcon, null)),
929
- localization.edit))), renderRowActionMenuItems === null || renderRowActionMenuItems === void 0 ? void 0 :
930
- renderRowActionMenuItems({
931
- row,
932
- table,
933
- closeMenu: () => setAnchorEl(null),
934
- })));
866
+ } }, { children: [enableEditing instanceof Function
867
+ ? enableEditing(row)
868
+ : enableEditing && (jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ onClick: handleEdit, sx: commonMenuItemStyles }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: commonListItemStyles }, { children: [jsxRuntime.jsx(ListItemIcon__default["default"], { children: jsxRuntime.jsx(EditIcon, {}) }), localization.edit] })) }))), renderRowActionMenuItems === null || renderRowActionMenuItems === void 0 ? void 0 : renderRowActionMenuItems({
869
+ row,
870
+ table,
871
+ closeMenu: () => setAnchorEl(null),
872
+ })] })));
935
873
  };
936
874
 
937
875
  const MRT_EditActionButtons = ({ row, table, variant = 'icon', }) => {
@@ -958,15 +896,7 @@ const MRT_EditActionButtons = ({ row, table, variant = 'icon', }) => {
958
896
  values: (_b = editingRow === null || editingRow === void 0 ? void 0 : editingRow._valuesCache) !== null && _b !== void 0 ? _b : Object.assign({}, row.original),
959
897
  });
960
898
  };
961
- return (React__default["default"].createElement(Box__default["default"], { onClick: (e) => e.stopPropagation(), sx: { display: 'flex', gap: '0.75rem' } }, variant === 'icon' ? (React__default["default"].createElement(React__default["default"].Fragment, null,
962
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.cancel },
963
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.cancel, onClick: handleCancel },
964
- React__default["default"].createElement(CancelIcon, null))),
965
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.save },
966
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.save, color: "info", onClick: handleSave },
967
- React__default["default"].createElement(SaveIcon, null))))) : (React__default["default"].createElement(React__default["default"].Fragment, null,
968
- React__default["default"].createElement(Button__default["default"], { onClick: handleCancel }, localization.cancel),
969
- React__default["default"].createElement(Button__default["default"], { onClick: handleSave, variant: "contained" }, localization.save)))));
899
+ return (jsxRuntime.jsx(Box__default["default"], Object.assign({ onClick: (e) => e.stopPropagation(), sx: { display: 'flex', gap: '0.75rem' } }, { children: variant === 'icon' ? (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.cancel }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.cancel, onClick: handleCancel }, { children: jsxRuntime.jsx(CancelIcon, {}) })) })), jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.save }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.save, color: "info", onClick: handleSave }, { children: jsxRuntime.jsx(SaveIcon, {}) })) }))] })) : (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Button__default["default"], Object.assign({ onClick: handleCancel }, { children: localization.cancel })), jsxRuntime.jsx(Button__default["default"], Object.assign({ onClick: handleSave, variant: "contained" }, { children: localization.save }))] })) })));
970
900
  };
971
901
 
972
902
  const commonIconButtonStyles = {
@@ -982,7 +912,7 @@ const commonIconButtonStyles = {
982
912
  const MRT_ToggleRowActionMenuButton = ({ cell, row, table, }) => {
983
913
  const { getState, options: { editingMode, enableEditing, icons: { EditIcon, MoreHorizIcon }, localization, renderRowActionMenuItems, renderRowActions, }, setEditingRow, } = table;
984
914
  const { editingRow } = getState();
985
- const [anchorEl, setAnchorEl] = React.useState(null);
915
+ const [anchorEl, setAnchorEl] = react.useState(null);
986
916
  const handleOpenRowActionMenu = (event) => {
987
917
  event.stopPropagation();
988
918
  event.preventDefault();
@@ -993,16 +923,10 @@ const MRT_ToggleRowActionMenuButton = ({ cell, row, table, }) => {
993
923
  setEditingRow(Object.assign({}, row));
994
924
  setAnchorEl(null);
995
925
  };
996
- return (React__default["default"].createElement(React__default["default"].Fragment, null, renderRowActions ? (renderRowActions({ cell, row, table })) : row.id === (editingRow === null || editingRow === void 0 ? void 0 : editingRow.id) && editingMode === 'row' ? (React__default["default"].createElement(MRT_EditActionButtons, { row: row, table: table })) : !renderRowActionMenuItems &&
997
- (enableEditing instanceof Function
998
- ? enableEditing(row)
999
- : enableEditing) ? (React__default["default"].createElement(Tooltip__default["default"], { placement: "right", arrow: true, title: localization.edit },
1000
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.edit, sx: commonIconButtonStyles, onClick: handleStartEditMode },
1001
- React__default["default"].createElement(EditIcon, null)))) : renderRowActionMenuItems ? (React__default["default"].createElement(React__default["default"].Fragment, null,
1002
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: localization.rowActions },
1003
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.rowActions, onClick: handleOpenRowActionMenu, size: "small", sx: commonIconButtonStyles },
1004
- React__default["default"].createElement(MoreHorizIcon, null))),
1005
- React__default["default"].createElement(MRT_RowActionMenu, { anchorEl: anchorEl, handleEdit: handleStartEditMode, row: row, setAnchorEl: setAnchorEl, table: table }))) : null));
926
+ return (jsxRuntime.jsx(jsxRuntime.Fragment, { children: renderRowActions ? (renderRowActions({ cell, row, table })) : row.id === (editingRow === null || editingRow === void 0 ? void 0 : editingRow.id) && editingMode === 'row' ? (jsxRuntime.jsx(MRT_EditActionButtons, { row: row, table: table })) : !renderRowActionMenuItems &&
927
+ (enableEditing instanceof Function
928
+ ? enableEditing(row)
929
+ : enableEditing) ? (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ placement: "right", arrow: true, title: localization.edit }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.edit, sx: commonIconButtonStyles, onClick: handleStartEditMode }, { children: jsxRuntime.jsx(EditIcon, {}) })) }))) : renderRowActionMenuItems ? (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: localization.rowActions }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.rowActions, onClick: handleOpenRowActionMenu, size: "small", sx: commonIconButtonStyles }, { children: jsxRuntime.jsx(MoreHorizIcon, {}) })) })), jsxRuntime.jsx(MRT_RowActionMenu, { anchorEl: anchorEl, handleEdit: handleStartEditMode, row: row, setAnchorEl: setAnchorEl, table: table })] })) : null }));
1006
930
  };
1007
931
 
1008
932
  const MRT_SelectCheckbox = ({ row, selectAll, table }) => {
@@ -1036,11 +960,11 @@ const MRT_SelectCheckbox = ({ row, selectAll, table }) => {
1036
960
  }, sx: (theme) => (Object.assign({ height: density === 'compact' ? '1.75rem' : '2.5rem', width: density === 'compact' ? '1.75rem' : '2.5rem', m: density !== 'compact' ? '-0.4rem' : undefined }, ((checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.sx) instanceof Function
1037
961
  ? checkboxProps.sx(theme)
1038
962
  : checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.sx))), title: undefined });
1039
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: (_a = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.title) !== null && _a !== void 0 ? _a : (selectAll
963
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: (_a = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.title) !== null && _a !== void 0 ? _a : (selectAll
1040
964
  ? localization.toggleSelectAll
1041
- : localization.toggleSelectRow) }, enableMultiRowSelection === false ? (React__default["default"].createElement(Radio__default["default"], Object.assign({}, commonProps))) : (React__default["default"].createElement(Checkbox__default["default"], Object.assign({ indeterminate: selectAll
1042
- ? table.getIsSomeRowsSelected() && !allRowsSelected
1043
- : row === null || row === void 0 ? void 0 : row.getIsSomeSelected() }, commonProps)))));
965
+ : localization.toggleSelectRow) }, { children: enableMultiRowSelection === false ? (jsxRuntime.jsx(Radio__default["default"], Object.assign({}, commonProps))) : (jsxRuntime.jsx(Checkbox__default["default"], Object.assign({ indeterminate: selectAll
966
+ ? table.getIsSomeRowsSelected() && !allRowsSelected
967
+ : row === null || row === void 0 ? void 0 : row.getIsSomeSelected() }, commonProps))) })));
1044
968
  };
1045
969
 
1046
970
  const MRT_GlobalFilterTextField = ({ table, }) => {
@@ -1050,10 +974,10 @@ const MRT_GlobalFilterTextField = ({ table, }) => {
1050
974
  const textFieldProps = muiSearchTextFieldProps instanceof Function
1051
975
  ? muiSearchTextFieldProps({ table })
1052
976
  : muiSearchTextFieldProps;
1053
- const isMounted = React.useRef(false);
1054
- const [anchorEl, setAnchorEl] = React.useState(null);
1055
- const [searchValue, setSearchValue] = React.useState(globalFilter !== null && globalFilter !== void 0 ? globalFilter : '');
1056
- const handleChangeDebounced = React.useCallback(utils.debounce((event) => {
977
+ const isMounted = react.useRef(false);
978
+ const [anchorEl, setAnchorEl] = react.useState(null);
979
+ const [searchValue, setSearchValue] = react.useState(globalFilter !== null && globalFilter !== void 0 ? globalFilter : '');
980
+ const handleChangeDebounced = react.useCallback(utils.debounce((event) => {
1057
981
  var _a;
1058
982
  setGlobalFilter((_a = event.target.value) !== null && _a !== void 0 ? _a : undefined);
1059
983
  }, manualFiltering ? 500 : 250), []);
@@ -1068,7 +992,7 @@ const MRT_GlobalFilterTextField = ({ table, }) => {
1068
992
  setSearchValue('');
1069
993
  setGlobalFilter(undefined);
1070
994
  };
1071
- React.useEffect(() => {
995
+ react.useEffect(() => {
1072
996
  if (isMounted.current) {
1073
997
  if (globalFilter === undefined) {
1074
998
  handleClear();
@@ -1079,24 +1003,15 @@ const MRT_GlobalFilterTextField = ({ table, }) => {
1079
1003
  }
1080
1004
  isMounted.current = true;
1081
1005
  }, [globalFilter]);
1082
- return (React__default["default"].createElement(Collapse__default["default"], { in: showGlobalFilter, orientation: "horizontal", unmountOnExit: true, mountOnEnter: true },
1083
- React__default["default"].createElement(TextField__default["default"], Object.assign({ placeholder: localization.search, onChange: handleChange, value: searchValue !== null && searchValue !== void 0 ? searchValue : '', variant: "standard", InputProps: {
1084
- startAdornment: enableGlobalFilterModes ? (React__default["default"].createElement(InputAdornment__default["default"], { position: "start" },
1085
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.changeSearchMode },
1086
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.changeSearchMode, onClick: handleGlobalFilterMenuOpen, size: "small", sx: { height: '1.75rem', width: '1.75rem' } },
1087
- React__default["default"].createElement(SearchIcon, null))))) : (React__default["default"].createElement(SearchIcon, { style: { marginRight: '4px' } })),
1088
- endAdornment: (React__default["default"].createElement(InputAdornment__default["default"], { position: "end" },
1089
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: (_a = localization.clearSearch) !== null && _a !== void 0 ? _a : '' },
1090
- React__default["default"].createElement("span", null,
1091
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.clearSearch, disabled: !(searchValue === null || searchValue === void 0 ? void 0 : searchValue.length), onClick: handleClear, size: "small" },
1092
- React__default["default"].createElement(CloseIcon, null)))))),
1093
- } }, textFieldProps, { inputRef: (inputRef) => {
1094
- searchInputRef.current = inputRef;
1095
- if (textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.inputRef) {
1096
- textFieldProps.inputRef = inputRef;
1097
- }
1098
- } })),
1099
- React__default["default"].createElement(MRT_FilterOptionMenu, { anchorEl: anchorEl, setAnchorEl: setAnchorEl, table: table, onSelect: handleClear })));
1006
+ return (jsxRuntime.jsxs(Collapse__default["default"], Object.assign({ in: showGlobalFilter, orientation: "horizontal", unmountOnExit: true, mountOnEnter: true }, { children: [jsxRuntime.jsx(TextField__default["default"], Object.assign({ placeholder: localization.search, onChange: handleChange, value: searchValue !== null && searchValue !== void 0 ? searchValue : '', variant: "standard", InputProps: {
1007
+ startAdornment: enableGlobalFilterModes ? (jsxRuntime.jsx(InputAdornment__default["default"], Object.assign({ position: "start" }, { children: jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.changeSearchMode }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.changeSearchMode, onClick: handleGlobalFilterMenuOpen, size: "small", sx: { height: '1.75rem', width: '1.75rem' } }, { children: jsxRuntime.jsx(SearchIcon, {}) })) })) }))) : (jsxRuntime.jsx(SearchIcon, { style: { marginRight: '4px' } })),
1008
+ endAdornment: (jsxRuntime.jsx(InputAdornment__default["default"], Object.assign({ position: "end" }, { children: jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: (_a = localization.clearSearch) !== null && _a !== void 0 ? _a : '' }, { children: jsxRuntime.jsx("span", { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.clearSearch, disabled: !(searchValue === null || searchValue === void 0 ? void 0 : searchValue.length), onClick: handleClear, size: "small" }, { children: jsxRuntime.jsx(CloseIcon, {}) })) }) })) }))),
1009
+ } }, textFieldProps, { inputRef: (inputRef) => {
1010
+ searchInputRef.current = inputRef;
1011
+ if (textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.inputRef) {
1012
+ textFieldProps.inputRef = inputRef;
1013
+ }
1014
+ } })), jsxRuntime.jsx(MRT_FilterOptionMenu, { anchorEl: anchorEl, setAnchorEl: setAnchorEl, table: table, onSelect: handleClear })] })));
1100
1015
  };
1101
1016
 
1102
1017
  const MRT_LinearProgressBar = ({ isTopToolbar, table, }) => {
@@ -1105,13 +1020,12 @@ const MRT_LinearProgressBar = ({ isTopToolbar, table, }) => {
1105
1020
  const linearProgressProps = muiLinearProgressProps instanceof Function
1106
1021
  ? muiLinearProgressProps({ isTopToolbar, table })
1107
1022
  : muiLinearProgressProps;
1108
- return (React__default["default"].createElement(Collapse__default["default"], { in: isLoading || showProgressBars, mountOnEnter: true, unmountOnExit: true, sx: {
1023
+ return (jsxRuntime.jsx(Collapse__default["default"], Object.assign({ in: isLoading || showProgressBars, mountOnEnter: true, unmountOnExit: true, sx: {
1109
1024
  bottom: isTopToolbar ? 0 : undefined,
1110
1025
  position: 'absolute',
1111
1026
  top: !isTopToolbar ? 0 : undefined,
1112
1027
  width: '100%',
1113
- } },
1114
- React__default["default"].createElement(LinearProgress__default["default"], Object.assign({ "aria-label": "Loading", "aria-busy": "true", sx: { position: 'relative' } }, linearProgressProps))));
1028
+ } }, { children: jsxRuntime.jsx(LinearProgress__default["default"], Object.assign({ "aria-label": "Loading", "aria-busy": "true", sx: { position: 'relative' } }, linearProgressProps)) })));
1115
1029
  };
1116
1030
 
1117
1031
  const MRT_TablePagination = ({ table, position = 'bottom', }) => {
@@ -1125,7 +1039,7 @@ const MRT_TablePagination = ({ table, position = 'bottom', }) => {
1125
1039
  const handleChangeRowsPerPage = (event) => {
1126
1040
  setPageSize(+event.target.value);
1127
1041
  };
1128
- return (React__default["default"].createElement(TablePagination__default["default"], Object.assign({ component: "div", count: totalRowCount, getItemAriaLabel: (type) => type === 'first'
1042
+ return (jsxRuntime.jsx(TablePagination__default["default"], Object.assign({ component: "div", count: totalRowCount, getItemAriaLabel: (type) => type === 'first'
1129
1043
  ? localization.goToFirstPage
1130
1044
  : type === 'last'
1131
1045
  ? localization.goToLastPage
@@ -1166,27 +1080,14 @@ const MRT_ToolbarAlertBanner = ({ stackAlertBanner, table, }) => {
1166
1080
  const selectMessage = getSelectedRowModel().rows.length > 0
1167
1081
  ? (_b = (_a = localization.selectedCountOfRowCountRowsSelected) === null || _a === void 0 ? void 0 : _a.replace('{selectedCount}', getSelectedRowModel().rows.length.toString())) === null || _b === void 0 ? void 0 : _b.replace('{rowCount}', (rowCount !== null && rowCount !== void 0 ? rowCount : getPrePaginationRowModel().rows.length).toString())
1168
1082
  : null;
1169
- const groupedByMessage = grouping.length > 0 ? (React__default["default"].createElement("span", null,
1170
- localization.groupedBy,
1171
- ' ',
1172
- grouping.map((columnId, index) => (React__default["default"].createElement(React.Fragment, { key: `${index}-${columnId}` },
1173
- index > 0 ? localization.thenBy : '',
1174
- React__default["default"].createElement(Chip__default["default"], Object.assign({ label: table.getColumn(columnId).columnDef.header, onDelete: () => table.getColumn(columnId).toggleGrouping() }, chipProps))))))) : null;
1175
- return (React__default["default"].createElement(Collapse__default["default"], { in: showAlertBanner || !!selectMessage || !!groupedByMessage, timeout: stackAlertBanner ? 200 : 0 },
1176
- React__default["default"].createElement(Alert__default["default"], Object.assign({ color: "info", icon: false }, alertProps, { sx: (theme) => (Object.assign({ borderRadius: 0, fontSize: '1rem', left: 0, p: 0, position: 'relative', mb: stackAlertBanner
1083
+ const groupedByMessage = grouping.length > 0 ? (jsxRuntime.jsxs("span", { children: [localization.groupedBy, ' ', grouping.map((columnId, index) => (jsxRuntime.jsxs(react.Fragment, { children: [index > 0 ? localization.thenBy : '', jsxRuntime.jsx(Chip__default["default"], Object.assign({ label: table.getColumn(columnId).columnDef.header, onDelete: () => table.getColumn(columnId).toggleGrouping() }, chipProps))] }, `${index}-${columnId}`)))] })) : null;
1084
+ return (jsxRuntime.jsx(Collapse__default["default"], Object.assign({ in: showAlertBanner || !!selectMessage || !!groupedByMessage, timeout: stackAlertBanner ? 200 : 0 }, { children: jsxRuntime.jsxs(Alert__default["default"], Object.assign({ color: "info", icon: false }, alertProps, { sx: (theme) => (Object.assign({ borderRadius: 0, fontSize: '1rem', left: 0, p: 0, position: 'relative', mb: stackAlertBanner
1177
1085
  ? 0
1178
1086
  : positionToolbarAlertBanner === 'bottom'
1179
1087
  ? '-1rem'
1180
1088
  : undefined, right: 0, top: 0, width: '100%', zIndex: 2 }, ((alertProps === null || alertProps === void 0 ? void 0 : alertProps.sx) instanceof Function
1181
1089
  ? alertProps.sx(theme)
1182
- : alertProps === null || alertProps === void 0 ? void 0 : alertProps.sx))) }),
1183
- (alertProps === null || alertProps === void 0 ? void 0 : alertProps.title) && React__default["default"].createElement(AlertTitle__default["default"], null, alertProps.title),
1184
- React__default["default"].createElement(Box__default["default"], { sx: { p: '0.5rem 1rem' } }, alertProps === null || alertProps === void 0 ? void 0 :
1185
- alertProps.children,
1186
- (alertProps === null || alertProps === void 0 ? void 0 : alertProps.children) && (selectMessage || groupedByMessage) && (React__default["default"].createElement("br", null)),
1187
- selectMessage,
1188
- selectMessage && groupedByMessage && React__default["default"].createElement("br", null),
1189
- groupedByMessage))));
1090
+ : alertProps === null || alertProps === void 0 ? void 0 : alertProps.sx))) }, { children: [(alertProps === null || alertProps === void 0 ? void 0 : alertProps.title) && jsxRuntime.jsx(AlertTitle__default["default"], { children: alertProps.title }), jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: { p: '0.5rem 1rem' } }, { children: [alertProps === null || alertProps === void 0 ? void 0 : alertProps.children, (alertProps === null || alertProps === void 0 ? void 0 : alertProps.children) && (selectMessage || groupedByMessage) && (jsxRuntime.jsx("br", {})), selectMessage, selectMessage && groupedByMessage && jsxRuntime.jsx("br", {}), groupedByMessage] }))] })) })));
1190
1091
  };
1191
1092
 
1192
1093
  const MRT_FullScreenToggleButton = (_a) => {
@@ -1197,8 +1098,7 @@ const MRT_FullScreenToggleButton = (_a) => {
1197
1098
  const handleToggleFullScreen = () => {
1198
1099
  setIsFullScreen(!isFullScreen);
1199
1100
  };
1200
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.toggleFullScreen },
1201
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.showHideFilters, onClick: handleToggleFullScreen }, rest, { title: undefined }), isFullScreen ? React__default["default"].createElement(FullscreenExitIcon, null) : React__default["default"].createElement(FullscreenIcon, null))));
1101
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.toggleFullScreen }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.showHideFilters, onClick: handleToggleFullScreen }, rest, { title: undefined }, { children: isFullScreen ? jsxRuntime.jsx(FullscreenExitIcon, {}) : jsxRuntime.jsx(FullscreenIcon, {}) })) })));
1202
1102
  };
1203
1103
 
1204
1104
  const MRT_ColumnPinningButtons = ({ column, table, }) => {
@@ -1206,26 +1106,17 @@ const MRT_ColumnPinningButtons = ({ column, table, }) => {
1206
1106
  const handlePinColumn = (pinDirection) => {
1207
1107
  column.pin(pinDirection);
1208
1108
  };
1209
- return (React__default["default"].createElement(Box__default["default"], { sx: { minWidth: '70px', textAlign: 'center' } }, column.getIsPinned() ? (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.unpin },
1210
- React__default["default"].createElement(IconButton__default["default"], { onClick: () => handlePinColumn(false), size: "small" },
1211
- React__default["default"].createElement(PushPinIcon, null)))) : (React__default["default"].createElement(React__default["default"].Fragment, null,
1212
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.pinToLeft },
1213
- React__default["default"].createElement(IconButton__default["default"], { onClick: () => handlePinColumn('left'), size: "small" },
1214
- React__default["default"].createElement(PushPinIcon, { style: {
1215
- transform: 'rotate(90deg)',
1216
- } }))),
1217
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.pinToRight },
1218
- React__default["default"].createElement(IconButton__default["default"], { onClick: () => handlePinColumn('right'), size: "small" },
1219
- React__default["default"].createElement(PushPinIcon, { style: {
1220
- transform: 'rotate(-90deg)',
1221
- } })))))));
1109
+ return (jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: { minWidth: '70px', textAlign: 'center' } }, { children: column.getIsPinned() ? (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.unpin }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ onClick: () => handlePinColumn(false), size: "small" }, { children: jsxRuntime.jsx(PushPinIcon, {}) })) }))) : (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.pinToLeft }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ onClick: () => handlePinColumn('left'), size: "small" }, { children: jsxRuntime.jsx(PushPinIcon, { style: {
1110
+ transform: 'rotate(90deg)',
1111
+ } }) })) })), jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.pinToRight }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ onClick: () => handlePinColumn('right'), size: "small" }, { children: jsxRuntime.jsx(PushPinIcon, { style: {
1112
+ transform: 'rotate(-90deg)',
1113
+ } }) })) }))] })) })));
1222
1114
  };
1223
1115
 
1224
1116
  const MRT_GrabHandleButton = ({ iconButtonProps, onDragEnd, onDragStart, table, }) => {
1225
1117
  var _a;
1226
1118
  const { options: { icons: { DragHandleIcon }, localization, }, } = table;
1227
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, placement: "top", title: (_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : localization.move },
1228
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ disableRipple: true, draggable: "true", size: "small" }, iconButtonProps, { onClick: (e) => {
1119
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, placement: "top", title: (_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : localization.move }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ disableRipple: true, draggable: "true", size: "small" }, iconButtonProps, { onClick: (e) => {
1229
1120
  var _a;
1230
1121
  e.stopPropagation();
1231
1122
  (_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.onClick) === null || _a === void 0 ? void 0 : _a.call(iconButtonProps, e);
@@ -1236,8 +1127,7 @@ const MRT_GrabHandleButton = ({ iconButtonProps, onDragEnd, onDragStart, table,
1236
1127
  cursor: 'grabbing',
1237
1128
  } }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
1238
1129
  ? iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx(theme)
1239
- : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }),
1240
- React__default["default"].createElement(DragHandleIcon, null))));
1130
+ : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }, { children: jsxRuntime.jsx(DragHandleIcon, {}) })) })));
1241
1131
  };
1242
1132
 
1243
1133
  const MRT_ShowHideColumnsMenuItems = ({ allColumns, hoveredColumn, setHoveredColumn, column, table, }) => {
@@ -1260,8 +1150,8 @@ const MRT_ShowHideColumnsMenuItems = ({ allColumns, hoveredColumn, setHoveredCol
1260
1150
  column.toggleVisibility();
1261
1151
  }
1262
1152
  };
1263
- const menuItemRef = React.useRef(null);
1264
- const [isDragging, setIsDragging] = React.useState(false);
1153
+ const menuItemRef = react.useRef(null);
1154
+ const [isDragging, setIsDragging] = react.useState(false);
1265
1155
  const handleDragStart = (e) => {
1266
1156
  setIsDragging(true);
1267
1157
  e.dataTransfer.setDragImage(menuItemRef.current, 0, 0);
@@ -1278,42 +1168,35 @@ const MRT_ShowHideColumnsMenuItems = ({ allColumns, hoveredColumn, setHoveredCol
1278
1168
  setHoveredColumn(column);
1279
1169
  }
1280
1170
  };
1281
- return (React__default["default"].createElement(React__default["default"].Fragment, null,
1282
- React__default["default"].createElement(MenuItem__default["default"], { disableRipple: true, ref: menuItemRef, onDragEnter: handleDragEnter, sx: (theme) => ({
1283
- alignItems: 'center',
1284
- justifyContent: 'flex-start',
1285
- my: 0,
1286
- opacity: isDragging ? 0.5 : 1,
1287
- outlineOffset: '-2px',
1288
- outline: isDragging
1289
- ? `2px dashed ${theme.palette.divider}`
1290
- : (hoveredColumn === null || hoveredColumn === void 0 ? void 0 : hoveredColumn.id) === column.id
1291
- ? `2px dashed ${theme.palette.primary.main}`
1292
- : 'none',
1293
- pl: `${(column.depth + 0.5) * 2}rem`,
1294
- py: '6px',
1295
- }) },
1296
- React__default["default"].createElement(Box__default["default"], { sx: {
1297
- display: 'flex',
1298
- flexWrap: 'nowrap',
1299
- gap: '8px',
1300
- } },
1301
- columnDefType !== 'group' &&
1302
- enableColumnOrdering &&
1303
- !allColumns.some((col) => col.columnDef.columnDefType === 'group') &&
1304
- (columnDef.enableColumnOrdering !== false ? (React__default["default"].createElement(MRT_GrabHandleButton, { onDragEnd: handleDragEnd, onDragStart: handleDragStart, table: table })) : (React__default["default"].createElement(Box__default["default"], { sx: { width: '28px' } }))),
1305
- enablePinning &&
1306
- (column.getCanPin() ? (React__default["default"].createElement(MRT_ColumnPinningButtons, { column: column, table: table })) : (React__default["default"].createElement(Box__default["default"], { sx: { width: '70px' } }))),
1307
- enableHiding ? (React__default["default"].createElement(FormControlLabel__default["default"], { componentsProps: {
1308
- typography: {
1309
- sx: {
1310
- mb: 0,
1311
- opacity: columnDefType !== 'display' ? 1 : 0.5,
1312
- },
1313
- },
1314
- }, checked: switchChecked, control: React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: localization.toggleVisibility },
1315
- React__default["default"].createElement(Switch__default["default"], null)), disabled: !column.getCanHide(), label: columnDef.header, onChange: () => handleToggleColumnHidden(column) })) : (React__default["default"].createElement(Typography__default["default"], { sx: { alignSelf: 'center' } }, columnDef.header)))), (_a = column.columns) === null || _a === void 0 ? void 0 :
1316
- _a.map((c, i) => (React__default["default"].createElement(MRT_ShowHideColumnsMenuItems, { allColumns: allColumns, column: c, hoveredColumn: hoveredColumn, key: `${i}-${c.id}`, setHoveredColumn: setHoveredColumn, table: table })))));
1171
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ disableRipple: true, ref: menuItemRef, onDragEnter: handleDragEnter, sx: (theme) => ({
1172
+ alignItems: 'center',
1173
+ justifyContent: 'flex-start',
1174
+ my: 0,
1175
+ opacity: isDragging ? 0.5 : 1,
1176
+ outlineOffset: '-2px',
1177
+ outline: isDragging
1178
+ ? `2px dashed ${theme.palette.divider}`
1179
+ : (hoveredColumn === null || hoveredColumn === void 0 ? void 0 : hoveredColumn.id) === column.id
1180
+ ? `2px dashed ${theme.palette.primary.main}`
1181
+ : 'none',
1182
+ pl: `${(column.depth + 0.5) * 2}rem`,
1183
+ py: '6px',
1184
+ }) }, { children: jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: {
1185
+ display: 'flex',
1186
+ flexWrap: 'nowrap',
1187
+ gap: '8px',
1188
+ } }, { children: [columnDefType !== 'group' &&
1189
+ enableColumnOrdering &&
1190
+ !allColumns.some((col) => col.columnDef.columnDefType === 'group') &&
1191
+ (columnDef.enableColumnOrdering !== false ? (jsxRuntime.jsx(MRT_GrabHandleButton, { onDragEnd: handleDragEnd, onDragStart: handleDragStart, table: table })) : (jsxRuntime.jsx(Box__default["default"], { sx: { width: '28px' } }))), enablePinning &&
1192
+ (column.getCanPin() ? (jsxRuntime.jsx(MRT_ColumnPinningButtons, { column: column, table: table })) : (jsxRuntime.jsx(Box__default["default"], { sx: { width: '70px' } }))), enableHiding ? (jsxRuntime.jsx(FormControlLabel__default["default"], { componentsProps: {
1193
+ typography: {
1194
+ sx: {
1195
+ mb: 0,
1196
+ opacity: columnDefType !== 'display' ? 1 : 0.5,
1197
+ },
1198
+ },
1199
+ }, checked: switchChecked, control: jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: localization.toggleVisibility }, { children: jsxRuntime.jsx(Switch__default["default"], {}) })), disabled: !column.getCanHide(), label: columnDef.header, onChange: () => handleToggleColumnHidden(column) })) : (jsxRuntime.jsx(Typography__default["default"], Object.assign({ sx: { alignSelf: 'center' } }, { children: columnDef.header })))] })) })), (_a = column.columns) === null || _a === void 0 ? void 0 : _a.map((c, i) => (jsxRuntime.jsx(MRT_ShowHideColumnsMenuItems, { allColumns: allColumns, column: c, hoveredColumn: hoveredColumn, setHoveredColumn: setHoveredColumn, table: table }, `${i}-${c.id}`)))] }));
1317
1200
  };
1318
1201
 
1319
1202
  const MRT_ShowHideColumnsMenu = ({ anchorEl, setAnchorEl, table, }) => {
@@ -1324,7 +1207,7 @@ const MRT_ShowHideColumnsMenu = ({ anchorEl, setAnchorEl, table, }) => {
1324
1207
  .filter((col) => col.columnDef.enableHiding !== false)
1325
1208
  .forEach((col) => col.toggleVisibility(false));
1326
1209
  };
1327
- const allColumns = React.useMemo(() => {
1210
+ const allColumns = react.useMemo(() => {
1328
1211
  const columns = getAllColumns();
1329
1212
  if (columnOrder.length > 0 &&
1330
1213
  !columns.some((col) => col.columnDef.columnDefType === 'group')) {
@@ -1343,37 +1226,26 @@ const MRT_ShowHideColumnsMenu = ({ anchorEl, setAnchorEl, table, }) => {
1343
1226
  getLeftLeafColumns(),
1344
1227
  getRightLeafColumns(),
1345
1228
  ]);
1346
- const [hoveredColumn, setHoveredColumn] = React.useState(null);
1347
- return (React__default["default"].createElement(Menu__default["default"], { anchorEl: anchorEl, open: !!anchorEl, onClose: () => setAnchorEl(null), MenuListProps: {
1229
+ const [hoveredColumn, setHoveredColumn] = react.useState(null);
1230
+ return (jsxRuntime.jsxs(Menu__default["default"], Object.assign({ anchorEl: anchorEl, open: !!anchorEl, onClose: () => setAnchorEl(null), MenuListProps: {
1348
1231
  dense: density === 'compact',
1349
- } },
1350
- React__default["default"].createElement(Box__default["default"], { sx: {
1351
- display: 'flex',
1352
- justifyContent: 'space-between',
1353
- p: '0.5rem',
1354
- pt: 0,
1355
- } },
1356
- enableHiding && (React__default["default"].createElement(Button__default["default"], { disabled: !getIsSomeColumnsVisible(), onClick: hideAllColumns }, localization.hideAll)),
1357
- enableColumnOrdering && (React__default["default"].createElement(Button__default["default"], { onClick: () => table.setColumnOrder(getDefaultColumnOrderIds(table.options)) }, localization.resetOrder)),
1358
- enablePinning && (React__default["default"].createElement(Button__default["default"], { disabled: !getIsSomeColumnsPinned(), onClick: () => table.resetColumnPinning(true) }, localization.unpinAll)),
1359
- enableHiding && (React__default["default"].createElement(Button__default["default"], { disabled: getIsAllColumnsVisible(), onClick: () => toggleAllColumnsVisible(true) }, localization.showAll))),
1360
- React__default["default"].createElement(Divider__default["default"], null),
1361
- allColumns.map((column, index) => (React__default["default"].createElement(MRT_ShowHideColumnsMenuItems, { allColumns: allColumns, column: column, hoveredColumn: hoveredColumn, key: `${index}-${column.id}`, setHoveredColumn: setHoveredColumn, table: table })))));
1232
+ } }, { children: [jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: {
1233
+ display: 'flex',
1234
+ justifyContent: 'space-between',
1235
+ p: '0.5rem',
1236
+ pt: 0,
1237
+ } }, { children: [enableHiding && (jsxRuntime.jsx(Button__default["default"], Object.assign({ disabled: !getIsSomeColumnsVisible(), onClick: hideAllColumns }, { children: localization.hideAll }))), enableColumnOrdering && (jsxRuntime.jsx(Button__default["default"], Object.assign({ onClick: () => table.setColumnOrder(getDefaultColumnOrderIds(table.options)) }, { children: localization.resetOrder }))), enablePinning && (jsxRuntime.jsx(Button__default["default"], Object.assign({ disabled: !getIsSomeColumnsPinned(), onClick: () => table.resetColumnPinning(true) }, { children: localization.unpinAll }))), enableHiding && (jsxRuntime.jsx(Button__default["default"], Object.assign({ disabled: getIsAllColumnsVisible(), onClick: () => toggleAllColumnsVisible(true) }, { children: localization.showAll })))] })), jsxRuntime.jsx(Divider__default["default"], {}), allColumns.map((column, index) => (jsxRuntime.jsx(MRT_ShowHideColumnsMenuItems, { allColumns: allColumns, column: column, hoveredColumn: hoveredColumn, setHoveredColumn: setHoveredColumn, table: table }, `${index}-${column.id}`)))] })));
1362
1238
  };
1363
1239
 
1364
1240
  const MRT_ShowHideColumnsButton = (_a) => {
1365
1241
  var _b;
1366
1242
  var { table } = _a, rest = __rest(_a, ["table"]);
1367
1243
  const { options: { icons: { ViewColumnIcon }, localization, }, } = table;
1368
- const [anchorEl, setAnchorEl] = React.useState(null);
1244
+ const [anchorEl, setAnchorEl] = react.useState(null);
1369
1245
  const handleClick = (event) => {
1370
1246
  setAnchorEl(event.currentTarget);
1371
1247
  };
1372
- return (React__default["default"].createElement(React__default["default"].Fragment, null,
1373
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.showHideColumns },
1374
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.showHideColumns, onClick: handleClick }, rest, { title: undefined }),
1375
- React__default["default"].createElement(ViewColumnIcon, null))),
1376
- anchorEl && (React__default["default"].createElement(MRT_ShowHideColumnsMenu, { anchorEl: anchorEl, setAnchorEl: setAnchorEl, table: table }))));
1248
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.showHideColumns }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.showHideColumns, onClick: handleClick }, rest, { title: undefined }, { children: jsxRuntime.jsx(ViewColumnIcon, {}) })) })), anchorEl && (jsxRuntime.jsx(MRT_ShowHideColumnsMenu, { anchorEl: anchorEl, setAnchorEl: setAnchorEl, table: table }))] }));
1377
1249
  };
1378
1250
 
1379
1251
  const MRT_ToggleDensePaddingButton = (_a) => {
@@ -1389,8 +1261,7 @@ const MRT_ToggleDensePaddingButton = (_a) => {
1389
1261
  : 'comfortable';
1390
1262
  setDensity(nextDensity);
1391
1263
  };
1392
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.toggleDensity },
1393
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.toggleDensity, onClick: handleToggleDensePadding }, rest, { title: undefined }), density === 'compact' ? (React__default["default"].createElement(DensitySmallIcon, null)) : density === 'comfortable' ? (React__default["default"].createElement(DensityMediumIcon, null)) : (React__default["default"].createElement(DensityLargeIcon, null)))));
1264
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.toggleDensity }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.toggleDensity, onClick: handleToggleDensePadding }, rest, { title: undefined }, { children: density === 'compact' ? (jsxRuntime.jsx(DensitySmallIcon, {})) : density === 'comfortable' ? (jsxRuntime.jsx(DensityMediumIcon, {})) : (jsxRuntime.jsx(DensityLargeIcon, {})) })) })));
1394
1265
  };
1395
1266
 
1396
1267
  const MRT_ToggleFiltersButton = (_a) => {
@@ -1401,8 +1272,7 @@ const MRT_ToggleFiltersButton = (_a) => {
1401
1272
  const handleToggleShowFilters = () => {
1402
1273
  setShowColumnFilters(!showColumnFilters);
1403
1274
  };
1404
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.showHideFilters },
1405
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.showHideFilters, onClick: handleToggleShowFilters }, rest, { title: undefined }), showColumnFilters ? React__default["default"].createElement(FilterListOffIcon, null) : React__default["default"].createElement(FilterListIcon, null))));
1275
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.showHideFilters }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.showHideFilters, onClick: handleToggleShowFilters }, rest, { title: undefined }, { children: showColumnFilters ? jsxRuntime.jsx(FilterListOffIcon, {}) : jsxRuntime.jsx(FilterListIcon, {}) })) })));
1406
1276
  };
1407
1277
 
1408
1278
  const MRT_ToggleGlobalFilterButton = (_a) => {
@@ -1414,27 +1284,21 @@ const MRT_ToggleGlobalFilterButton = (_a) => {
1414
1284
  setShowGlobalFilter(!showGlobalFilter);
1415
1285
  queueMicrotask(() => { var _a; return (_a = searchInputRef.current) === null || _a === void 0 ? void 0 : _a.focus(); });
1416
1286
  };
1417
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.showHideSearch },
1418
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": (_c = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _c !== void 0 ? _c : localization.showHideSearch, disabled: !!globalFilter, onClick: handleToggleSearch }, rest, { title: undefined }), showGlobalFilter ? React__default["default"].createElement(SearchOffIcon, null) : React__default["default"].createElement(SearchIcon, null))));
1287
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: (_b = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _b !== void 0 ? _b : localization.showHideSearch }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": (_c = rest === null || rest === void 0 ? void 0 : rest.title) !== null && _c !== void 0 ? _c : localization.showHideSearch, disabled: !!globalFilter, onClick: handleToggleSearch }, rest, { title: undefined }, { children: showGlobalFilter ? jsxRuntime.jsx(SearchOffIcon, {}) : jsxRuntime.jsx(SearchIcon, {}) })) })));
1419
1288
  };
1420
1289
 
1421
1290
  const MRT_ToolbarInternalButtons = ({ table, }) => {
1422
1291
  var _a;
1423
1292
  const { options: { enableColumnFilters, enableColumnOrdering, enableDensityToggle, enableFilters, enableFullScreenToggle, enableGlobalFilter, enableHiding, enablePinning, initialState, renderToolbarInternalActions, }, } = table;
1424
- return (React__default["default"].createElement(Box__default["default"], { sx: {
1293
+ return (jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: {
1425
1294
  alignItems: 'center',
1426
1295
  display: 'flex',
1427
1296
  zIndex: 3,
1428
- } }, (_a = renderToolbarInternalActions === null || renderToolbarInternalActions === void 0 ? void 0 : renderToolbarInternalActions({
1429
- table,
1430
- })) !== null && _a !== void 0 ? _a : (React__default["default"].createElement(React__default["default"].Fragment, null,
1431
- enableFilters &&
1432
- enableGlobalFilter &&
1433
- !(initialState === null || initialState === void 0 ? void 0 : initialState.showGlobalFilter) && (React__default["default"].createElement(MRT_ToggleGlobalFilterButton, { table: table })),
1434
- enableFilters && enableColumnFilters && (React__default["default"].createElement(MRT_ToggleFiltersButton, { table: table })),
1435
- (enableHiding || enableColumnOrdering || enablePinning) && (React__default["default"].createElement(MRT_ShowHideColumnsButton, { table: table })),
1436
- enableDensityToggle && (React__default["default"].createElement(MRT_ToggleDensePaddingButton, { table: table })),
1437
- enableFullScreenToggle && (React__default["default"].createElement(MRT_FullScreenToggleButton, { table: table }))))));
1297
+ } }, { children: (_a = renderToolbarInternalActions === null || renderToolbarInternalActions === void 0 ? void 0 : renderToolbarInternalActions({
1298
+ table,
1299
+ })) !== null && _a !== void 0 ? _a : (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [enableFilters &&
1300
+ enableGlobalFilter &&
1301
+ !(initialState === null || initialState === void 0 ? void 0 : initialState.showGlobalFilter) && (jsxRuntime.jsx(MRT_ToggleGlobalFilterButton, { table: table })), enableFilters && enableColumnFilters && (jsxRuntime.jsx(MRT_ToggleFiltersButton, { table: table })), (enableHiding || enableColumnOrdering || enablePinning) && (jsxRuntime.jsx(MRT_ShowHideColumnsButton, { table: table })), enableDensityToggle && (jsxRuntime.jsx(MRT_ToggleDensePaddingButton, { table: table })), enableFullScreenToggle && (jsxRuntime.jsx(MRT_FullScreenToggleButton, { table: table }))] })) })));
1438
1302
  };
1439
1303
 
1440
1304
  const MRT_ToolbarDropZone = ({ table, }) => {
@@ -1444,7 +1308,7 @@ const MRT_ToolbarDropZone = ({ table, }) => {
1444
1308
  const handleDragEnter = (_event) => {
1445
1309
  setHoveredColumn({ id: 'drop-zone' });
1446
1310
  };
1447
- React.useEffect(() => {
1311
+ react.useEffect(() => {
1448
1312
  var _a;
1449
1313
  if (((_a = table.options.state) === null || _a === void 0 ? void 0 : _a.showToolbarDropZone) !== undefined) {
1450
1314
  setShowToolbarDropZone(!!enableGrouping &&
@@ -1453,8 +1317,7 @@ const MRT_ToolbarDropZone = ({ table, }) => {
1453
1317
  !grouping.includes(draggingColumn.id));
1454
1318
  }
1455
1319
  }, [enableGrouping, draggingColumn, grouping]);
1456
- return (React__default["default"].createElement(Fade__default["default"], { in: showToolbarDropZone },
1457
- React__default["default"].createElement(Box__default["default"], { className: "Mui-ToolbarDropZone", sx: (theme) => ({
1320
+ return (jsxRuntime.jsx(Fade__default["default"], Object.assign({ in: showToolbarDropZone }, { children: jsxRuntime.jsx(Box__default["default"], Object.assign({ className: "Mui-ToolbarDropZone", sx: (theme) => ({
1458
1321
  alignItems: 'center',
1459
1322
  backgroundColor: styles.alpha(theme.palette.info.main, (hoveredColumn === null || hoveredColumn === void 0 ? void 0 : hoveredColumn.id) === 'drop-zone' ? 0.2 : 0.1),
1460
1323
  backdropFilter: 'blur(4px)',
@@ -1466,8 +1329,7 @@ const MRT_ToolbarDropZone = ({ table, }) => {
1466
1329
  position: 'absolute',
1467
1330
  width: '100%',
1468
1331
  zIndex: 4,
1469
- }), onDragEnter: handleDragEnter },
1470
- React__default["default"].createElement(Typography__default["default"], { fontStyle: "italic" }, localization.dropToGroupBy.replace('{column}', (_b = (_a = draggingColumn === null || draggingColumn === void 0 ? void 0 : draggingColumn.columnDef) === null || _a === void 0 ? void 0 : _a.header) !== null && _b !== void 0 ? _b : '')))));
1332
+ }), onDragEnter: handleDragEnter }, { children: jsxRuntime.jsx(Typography__default["default"], Object.assign({ fontStyle: "italic" }, { children: localization.dropToGroupBy.replace('{column}', (_b = (_a = draggingColumn === null || draggingColumn === void 0 ? void 0 : draggingColumn.columnDef) === null || _a === void 0 ? void 0 : _a.header) !== null && _b !== void 0 ? _b : '') })) })) })));
1471
1333
  };
1472
1334
 
1473
1335
  const commonToolbarStyles = ({ theme }) => ({
@@ -1491,7 +1353,7 @@ const MRT_TopToolbar = ({ table, }) => {
1491
1353
  ? muiTopToolbarProps({ table })
1492
1354
  : muiTopToolbarProps;
1493
1355
  const stackAlertBanner = isMobile || !!renderTopToolbarCustomActions || showGlobalFilter;
1494
- return (React__default["default"].createElement(Toolbar__default["default"], Object.assign({ variant: "dense" }, toolbarProps, { ref: (ref) => {
1356
+ return (jsxRuntime.jsxs(Toolbar__default["default"], Object.assign({ variant: "dense" }, toolbarProps, { ref: (ref) => {
1495
1357
  topToolbarRef.current = ref;
1496
1358
  if (toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.ref) {
1497
1359
  // @ts-ignore
@@ -1499,32 +1361,23 @@ const MRT_TopToolbar = ({ table, }) => {
1499
1361
  }
1500
1362
  }, sx: (theme) => (Object.assign(Object.assign({ position: isFullScreen ? 'sticky' : undefined, top: isFullScreen ? '0' : undefined }, commonToolbarStyles({ theme })), ((toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.sx) instanceof Function
1501
1363
  ? toolbarProps.sx(theme)
1502
- : toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.sx))) }),
1503
- positionToolbarAlertBanner === 'top' && (React__default["default"].createElement(MRT_ToolbarAlertBanner, { stackAlertBanner: stackAlertBanner, table: table })),
1504
- ['both', 'top'].includes(positionToolbarDropZone !== null && positionToolbarDropZone !== void 0 ? positionToolbarDropZone : '') && (React__default["default"].createElement(MRT_ToolbarDropZone, { table: table })),
1505
- React__default["default"].createElement(Box__default["default"], { sx: {
1506
- alignItems: 'flex-start',
1507
- boxSizing: 'border-box',
1508
- display: 'flex',
1509
- justifyContent: 'space-between',
1510
- p: '0.5rem',
1511
- position: stackAlertBanner ? 'relative' : 'absolute',
1512
- right: 0,
1513
- top: 0,
1514
- width: '100%',
1515
- } },
1516
- enableGlobalFilter && positionGlobalFilter === 'left' && (React__default["default"].createElement(MRT_GlobalFilterTextField, { table: table })), (_a = renderTopToolbarCustomActions === null || renderTopToolbarCustomActions === void 0 ? void 0 : renderTopToolbarCustomActions({ table })) !== null && _a !== void 0 ? _a : React__default["default"].createElement("span", null),
1517
- enableToolbarInternalActions ? (React__default["default"].createElement(Box__default["default"], { sx: {
1364
+ : toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.sx))) }, { children: [positionToolbarAlertBanner === 'top' && (jsxRuntime.jsx(MRT_ToolbarAlertBanner, { stackAlertBanner: stackAlertBanner, table: table })), ['both', 'top'].includes(positionToolbarDropZone !== null && positionToolbarDropZone !== void 0 ? positionToolbarDropZone : '') && (jsxRuntime.jsx(MRT_ToolbarDropZone, { table: table })), jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: {
1365
+ alignItems: 'flex-start',
1366
+ boxSizing: 'border-box',
1518
1367
  display: 'flex',
1519
- flexWrap: 'wrap-reverse',
1520
- justifyContent: 'flex-end',
1521
- } },
1522
- enableGlobalFilter && positionGlobalFilter === 'right' && (React__default["default"].createElement(MRT_GlobalFilterTextField, { table: table })),
1523
- React__default["default"].createElement(MRT_ToolbarInternalButtons, { table: table }))) : (enableGlobalFilter &&
1524
- positionGlobalFilter === 'right' && (React__default["default"].createElement(MRT_GlobalFilterTextField, { table: table })))),
1525
- enablePagination &&
1526
- ['top', 'both'].includes(positionPagination !== null && positionPagination !== void 0 ? positionPagination : '') && (React__default["default"].createElement(MRT_TablePagination, { table: table, position: "top" })),
1527
- React__default["default"].createElement(MRT_LinearProgressBar, { isTopToolbar: true, table: table })));
1368
+ justifyContent: 'space-between',
1369
+ p: '0.5rem',
1370
+ position: stackAlertBanner ? 'relative' : 'absolute',
1371
+ right: 0,
1372
+ top: 0,
1373
+ width: '100%',
1374
+ } }, { children: [enableGlobalFilter && positionGlobalFilter === 'left' && (jsxRuntime.jsx(MRT_GlobalFilterTextField, { table: table })), (_a = renderTopToolbarCustomActions === null || renderTopToolbarCustomActions === void 0 ? void 0 : renderTopToolbarCustomActions({ table })) !== null && _a !== void 0 ? _a : jsxRuntime.jsx("span", {}), enableToolbarInternalActions ? (jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: {
1375
+ display: 'flex',
1376
+ flexWrap: 'wrap-reverse',
1377
+ justifyContent: 'flex-end',
1378
+ } }, { children: [enableGlobalFilter && positionGlobalFilter === 'right' && (jsxRuntime.jsx(MRT_GlobalFilterTextField, { table: table })), jsxRuntime.jsx(MRT_ToolbarInternalButtons, { table: table })] }))) : (enableGlobalFilter &&
1379
+ positionGlobalFilter === 'right' && (jsxRuntime.jsx(MRT_GlobalFilterTextField, { table: table })))] })), enablePagination &&
1380
+ ['top', 'both'].includes(positionPagination !== null && positionPagination !== void 0 ? positionPagination : '') && (jsxRuntime.jsx(MRT_TablePagination, { table: table, position: "top" })), jsxRuntime.jsx(MRT_LinearProgressBar, { isTopToolbar: true, table: table })] })));
1528
1381
  };
1529
1382
 
1530
1383
  const MRT_BottomToolbar = ({ table, }) => {
@@ -1535,7 +1388,7 @@ const MRT_BottomToolbar = ({ table, }) => {
1535
1388
  ? muiBottomToolbarProps({ table })
1536
1389
  : muiBottomToolbarProps;
1537
1390
  const stackAlertBanner = isMobile || !!renderBottomToolbarCustomActions;
1538
- return (React__default["default"].createElement(Toolbar__default["default"], Object.assign({ variant: "dense" }, toolbarProps, { ref: (node) => {
1391
+ return (jsxRuntime.jsxs(Toolbar__default["default"], Object.assign({ variant: "dense" }, toolbarProps, { ref: (node) => {
1539
1392
  if (node) {
1540
1393
  bottomToolbarRef.current = node;
1541
1394
  if (toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.ref) {
@@ -1545,27 +1398,21 @@ const MRT_BottomToolbar = ({ table, }) => {
1545
1398
  }
1546
1399
  }, sx: (theme) => (Object.assign(Object.assign(Object.assign({}, commonToolbarStyles({ theme })), { bottom: isFullScreen ? '0' : undefined, boxShadow: `0 1px 2px -1px ${styles.alpha(theme.palette.common.black, 0.1)} inset`, left: 0, position: isFullScreen ? 'fixed' : 'relative', right: 0 }), ((toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.sx) instanceof Function
1547
1400
  ? toolbarProps.sx(theme)
1548
- : toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.sx))) }),
1549
- React__default["default"].createElement(MRT_LinearProgressBar, { isTopToolbar: false, table: table }),
1550
- positionToolbarAlertBanner === 'bottom' && (React__default["default"].createElement(MRT_ToolbarAlertBanner, { stackAlertBanner: stackAlertBanner, table: table })),
1551
- ['both', 'bottom'].includes(positionToolbarDropZone !== null && positionToolbarDropZone !== void 0 ? positionToolbarDropZone : '') && (React__default["default"].createElement(MRT_ToolbarDropZone, { table: table })),
1552
- React__default["default"].createElement(Box__default["default"], { sx: {
1553
- alignItems: 'center',
1554
- boxSizing: 'border-box',
1555
- display: 'flex',
1556
- justifyContent: 'space-between',
1557
- p: '0.5rem',
1558
- width: '100%',
1559
- } },
1560
- renderBottomToolbarCustomActions ? (renderBottomToolbarCustomActions({ table })) : (React__default["default"].createElement("span", null)),
1561
- React__default["default"].createElement(Box__default["default"], { sx: {
1401
+ : toolbarProps === null || toolbarProps === void 0 ? void 0 : toolbarProps.sx))) }, { children: [jsxRuntime.jsx(MRT_LinearProgressBar, { isTopToolbar: false, table: table }), positionToolbarAlertBanner === 'bottom' && (jsxRuntime.jsx(MRT_ToolbarAlertBanner, { stackAlertBanner: stackAlertBanner, table: table })), ['both', 'bottom'].includes(positionToolbarDropZone !== null && positionToolbarDropZone !== void 0 ? positionToolbarDropZone : '') && (jsxRuntime.jsx(MRT_ToolbarDropZone, { table: table })), jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: {
1402
+ alignItems: 'center',
1403
+ boxSizing: 'border-box',
1562
1404
  display: 'flex',
1563
- justifyContent: 'flex-end',
1564
- position: stackAlertBanner ? 'relative' : 'absolute',
1565
- right: 0,
1566
- top: 0,
1567
- } }, enablePagination &&
1568
- ['bottom', 'both'].includes(positionPagination !== null && positionPagination !== void 0 ? positionPagination : '') && (React__default["default"].createElement(MRT_TablePagination, { table: table, position: "bottom" }))))));
1405
+ justifyContent: 'space-between',
1406
+ p: '0.5rem',
1407
+ width: '100%',
1408
+ } }, { children: [renderBottomToolbarCustomActions ? (renderBottomToolbarCustomActions({ table })) : (jsxRuntime.jsx("span", {})), jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: {
1409
+ display: 'flex',
1410
+ justifyContent: 'flex-end',
1411
+ position: stackAlertBanner ? 'relative' : 'absolute',
1412
+ right: 0,
1413
+ top: 0,
1414
+ } }, { children: enablePagination &&
1415
+ ['bottom', 'both'].includes(positionPagination !== null && positionPagination !== void 0 ? positionPagination : '') && (jsxRuntime.jsx(MRT_TablePagination, { table: table, position: "bottom" })) }))] }))] })));
1569
1416
  };
1570
1417
 
1571
1418
  const MRT_TableHeadCellColumnActionsButton = ({ header, table, }) => {
@@ -1573,7 +1420,7 @@ const MRT_TableHeadCellColumnActionsButton = ({ header, table, }) => {
1573
1420
  const { options: { icons: { MoreVertIcon }, localization, muiTableHeadCellColumnActionsButtonProps, }, } = table;
1574
1421
  const { column } = header;
1575
1422
  const { columnDef } = column;
1576
- const [anchorEl, setAnchorEl] = React.useState(null);
1423
+ const [anchorEl, setAnchorEl] = react.useState(null);
1577
1424
  const handleClick = (event) => {
1578
1425
  event.stopPropagation();
1579
1426
  event.preventDefault();
@@ -1589,15 +1436,11 @@ const MRT_TableHeadCellColumnActionsButton = ({ header, table, }) => {
1589
1436
  })
1590
1437
  : columnDef.muiTableHeadCellColumnActionsButtonProps;
1591
1438
  const iconButtonProps = Object.assign(Object.assign({}, mTableHeadCellColumnActionsButtonProps), mcTableHeadCellColumnActionsButtonProps);
1592
- return (React__default["default"].createElement(React__default["default"].Fragment, null,
1593
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, placement: "top", title: (_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : localization.columnActions },
1594
- React__default["default"].createElement(IconButton__default["default"], Object.assign({ "aria-label": localization.columnActions, onClick: handleClick, size: "small" }, iconButtonProps, { sx: (theme) => (Object.assign({ height: '2rem', m: '-8px -4px', opacity: 0.5, transform: 'scale(0.85) translateX(-4px)', transition: 'opacity 150ms', width: '2rem', '&:hover': {
1595
- opacity: 1,
1596
- } }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
1597
- ? iconButtonProps.sx(theme)
1598
- : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }),
1599
- React__default["default"].createElement(MoreVertIcon, null))),
1600
- anchorEl && (React__default["default"].createElement(MRT_ColumnActionMenu, { anchorEl: anchorEl, header: header, setAnchorEl: setAnchorEl, table: table }))));
1439
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, placement: "top", title: (_a = iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.title) !== null && _a !== void 0 ? _a : localization.columnActions }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.columnActions, onClick: handleClick, size: "small" }, iconButtonProps, { sx: (theme) => (Object.assign({ height: '2rem', m: '-8px -4px', opacity: 0.5, transform: 'scale(0.85) translateX(-4px)', transition: 'opacity 150ms', width: '2rem', '&:hover': {
1440
+ opacity: 1,
1441
+ } }, ((iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx) instanceof Function
1442
+ ? iconButtonProps.sx(theme)
1443
+ : iconButtonProps === null || iconButtonProps === void 0 ? void 0 : iconButtonProps.sx))), title: undefined }, { children: jsxRuntime.jsx(MoreVertIcon, {}) })) })), anchorEl && (jsxRuntime.jsx(MRT_ColumnActionMenu, { anchorEl: anchorEl, header: header, setAnchorEl: setAnchorEl, table: table }))] }));
1601
1444
  };
1602
1445
 
1603
1446
  const MRT_FilterTextField = ({ header, rangeFilterIndex, table, }) => {
@@ -1644,8 +1487,8 @@ const MRT_FilterTextField = ({ header, rangeFilterIndex, table, }) => {
1644
1487
  !rangeFilterIndex &&
1645
1488
  (allowedColumnFilterOptions === undefined ||
1646
1489
  !!(allowedColumnFilterOptions === null || allowedColumnFilterOptions === void 0 ? void 0 : allowedColumnFilterOptions.length));
1647
- const [anchorEl, setAnchorEl] = React.useState(null);
1648
- const [filterValue, setFilterValue] = React.useState(() => {
1490
+ const [anchorEl, setAnchorEl] = react.useState(null);
1491
+ const [filterValue, setFilterValue] = react.useState(() => {
1649
1492
  var _a, _b;
1650
1493
  return isMultiSelectFilter
1651
1494
  ? column.getFilterValue() || []
@@ -1653,7 +1496,7 @@ const MRT_FilterTextField = ({ header, rangeFilterIndex, table, }) => {
1653
1496
  ? ((_a = column.getFilterValue()) === null || _a === void 0 ? void 0 : _a[rangeFilterIndex]) || []
1654
1497
  : (_b = column.getFilterValue()) !== null && _b !== void 0 ? _b : '';
1655
1498
  });
1656
- const handleChangeDebounced = React.useCallback(utils.debounce((event) => {
1499
+ const handleChangeDebounced = react.useCallback(utils.debounce((event) => {
1657
1500
  const value = textFieldProps.type === 'date'
1658
1501
  ? event.target.valueAsDate
1659
1502
  : textFieldProps.type === 'number'
@@ -1703,8 +1546,8 @@ const MRT_FilterTextField = ({ header, rangeFilterIndex, table, }) => {
1703
1546
  const handleFilterMenuOpen = (event) => {
1704
1547
  setAnchorEl(event.currentTarget);
1705
1548
  };
1706
- const isMounted = React.useRef(false);
1707
- React.useEffect(() => {
1549
+ const isMounted = react.useRef(false);
1550
+ react.useEffect(() => {
1708
1551
  if (isMounted.current) {
1709
1552
  const filterValue = column.getFilterValue();
1710
1553
  if (filterValue === undefined) {
@@ -1720,100 +1563,83 @@ const MRT_FilterTextField = ({ header, rangeFilterIndex, table, }) => {
1720
1563
  isMounted.current = true;
1721
1564
  }, [column.getFilterValue()]);
1722
1565
  if (columnDef.Filter) {
1723
- return (React__default["default"].createElement(React__default["default"].Fragment, null, (_f = columnDef.Filter) === null || _f === void 0 ? void 0 : _f.call(columnDef, { column, header, rangeFilterIndex, table })));
1566
+ return (jsxRuntime.jsx(jsxRuntime.Fragment, { children: (_f = columnDef.Filter) === null || _f === void 0 ? void 0 : _f.call(columnDef, { column, header, rangeFilterIndex, table }) }));
1724
1567
  }
1725
- return (React__default["default"].createElement(React__default["default"].Fragment, null,
1726
- React__default["default"].createElement(TextField__default["default"], Object.assign({ fullWidth: true, inputProps: {
1727
- disabled: !!filterChipLabel,
1728
- sx: {
1729
- textOverflow: 'ellipsis',
1730
- width: filterChipLabel ? 0 : undefined,
1731
- },
1732
- title: filterPlaceholder,
1733
- }, helperText: showChangeModeButton ? (React__default["default"].createElement("label", null, localization.filterMode.replace('{filterType}',
1734
- // @ts-ignore
1735
- localization[`filter${((_g = currentFilterOption === null || currentFilterOption === void 0 ? void 0 : currentFilterOption.charAt(0)) === null || _g === void 0 ? void 0 : _g.toUpperCase()) +
1736
- (currentFilterOption === null || currentFilterOption === void 0 ? void 0 : currentFilterOption.slice(1))}`]))) : null, FormHelperTextProps: {
1737
- sx: {
1738
- fontSize: '0.75rem',
1739
- lineHeight: '0.8rem',
1740
- whiteSpace: 'nowrap',
1741
- },
1742
- }, margin: "none", placeholder: filterChipLabel || isSelectFilter || isMultiSelectFilter
1743
- ? undefined
1744
- : filterPlaceholder, onChange: handleChange, onClick: (e) => e.stopPropagation(), select: isSelectFilter || isMultiSelectFilter, value: filterValue !== null && filterValue !== void 0 ? filterValue : '', variant: "standard", InputProps: {
1745
- startAdornment: showChangeModeButton ? (React__default["default"].createElement(InputAdornment__default["default"], { position: "start" },
1746
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, title: localization.changeFilterMode },
1747
- React__default["default"].createElement("span", null,
1748
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.changeFilterMode, onClick: handleFilterMenuOpen, size: "small", sx: { height: '1.75rem', width: '1.75rem' } },
1749
- React__default["default"].createElement(FilterListIcon, null)))),
1750
- filterChipLabel && (React__default["default"].createElement(Chip__default["default"], { onDelete: handleClearEmptyFilterChip, label: filterChipLabel })))) : null,
1751
- endAdornment: !filterChipLabel && (React__default["default"].createElement(InputAdornment__default["default"], { position: "end" },
1752
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, placement: "right", title: (_h = localization.clearFilter) !== null && _h !== void 0 ? _h : '' },
1753
- React__default["default"].createElement("span", null,
1754
- React__default["default"].createElement(IconButton__default["default"], { "aria-label": localization.clearFilter, disabled: !((_j = filterValue === null || filterValue === void 0 ? void 0 : filterValue.toString()) === null || _j === void 0 ? void 0 : _j.length), onClick: handleClear, size: "small", sx: {
1755
- height: '1.75rem',
1756
- width: '1.75rem',
1757
- } },
1758
- React__default["default"].createElement(CloseIcon, null)))))),
1759
- }, SelectProps: {
1760
- displayEmpty: true,
1761
- multiple: isMultiSelectFilter,
1762
- renderValue: isMultiSelectFilter
1763
- ? (selected) => !(selected === null || selected === void 0 ? void 0 : selected.length) ? (React__default["default"].createElement(Box__default["default"], { sx: { opacity: 0.5 } }, filterPlaceholder)) : (React__default["default"].createElement(Box__default["default"], { sx: { display: 'flex', flexWrap: 'wrap', gap: '2px' } }, selected === null || selected === void 0 ? void 0 : selected.map((value) => {
1568
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsxs(TextField__default["default"], Object.assign({ fullWidth: true, inputProps: {
1569
+ disabled: !!filterChipLabel,
1570
+ sx: {
1571
+ textOverflow: 'ellipsis',
1572
+ width: filterChipLabel ? 0 : undefined,
1573
+ },
1574
+ title: filterPlaceholder,
1575
+ }, helperText: showChangeModeButton ? (jsxRuntime.jsx("label", { children: localization.filterMode.replace('{filterType}',
1576
+ // @ts-ignore
1577
+ localization[`filter${((_g = currentFilterOption === null || currentFilterOption === void 0 ? void 0 : currentFilterOption.charAt(0)) === null || _g === void 0 ? void 0 : _g.toUpperCase()) +
1578
+ (currentFilterOption === null || currentFilterOption === void 0 ? void 0 : currentFilterOption.slice(1))}`]) })) : null, FormHelperTextProps: {
1579
+ sx: {
1580
+ fontSize: '0.75rem',
1581
+ lineHeight: '0.8rem',
1582
+ whiteSpace: 'nowrap',
1583
+ },
1584
+ }, margin: "none", placeholder: filterChipLabel || isSelectFilter || isMultiSelectFilter
1585
+ ? undefined
1586
+ : filterPlaceholder, onChange: handleChange, onClick: (e) => e.stopPropagation(), select: isSelectFilter || isMultiSelectFilter, value: filterValue !== null && filterValue !== void 0 ? filterValue : '', variant: "standard", InputProps: {
1587
+ startAdornment: showChangeModeButton ? (jsxRuntime.jsxs(InputAdornment__default["default"], Object.assign({ position: "start" }, { children: [jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, title: localization.changeFilterMode }, { children: jsxRuntime.jsx("span", { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.changeFilterMode, onClick: handleFilterMenuOpen, size: "small", sx: { height: '1.75rem', width: '1.75rem' } }, { children: jsxRuntime.jsx(FilterListIcon, {}) })) }) })), filterChipLabel && (jsxRuntime.jsx(Chip__default["default"], { onDelete: handleClearEmptyFilterChip, label: filterChipLabel }))] }))) : null,
1588
+ endAdornment: !filterChipLabel && (jsxRuntime.jsx(InputAdornment__default["default"], Object.assign({ position: "end" }, { children: jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, placement: "right", title: (_h = localization.clearFilter) !== null && _h !== void 0 ? _h : '' }, { children: jsxRuntime.jsx("span", { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ "aria-label": localization.clearFilter, disabled: !((_j = filterValue === null || filterValue === void 0 ? void 0 : filterValue.toString()) === null || _j === void 0 ? void 0 : _j.length), onClick: handleClear, size: "small", sx: {
1589
+ height: '1.75rem',
1590
+ width: '1.75rem',
1591
+ } }, { children: jsxRuntime.jsx(CloseIcon, {}) })) }) })) }))),
1592
+ }, SelectProps: {
1593
+ displayEmpty: true,
1594
+ multiple: isMultiSelectFilter,
1595
+ renderValue: isMultiSelectFilter
1596
+ ? (selected) => !(selected === null || selected === void 0 ? void 0 : selected.length) ? (jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: { opacity: 0.5 } }, { children: filterPlaceholder }))) : (jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: { display: 'flex', flexWrap: 'wrap', gap: '2px' } }, { children: selected === null || selected === void 0 ? void 0 : selected.map((value) => {
1597
+ var _a;
1598
+ const selectedValue = (_a = columnDef.filterSelectOptions) === null || _a === void 0 ? void 0 : _a.find((option) => option instanceof Object
1599
+ ? option.value === value
1600
+ : option === value);
1601
+ return (jsxRuntime.jsx(Chip__default["default"], { label: selectedValue instanceof Object
1602
+ ? selectedValue.text
1603
+ : selectedValue }, value));
1604
+ }) })))
1605
+ : undefined,
1606
+ } }, textFieldProps, { inputRef: (inputRef) => {
1607
+ filterInputRefs.current[`${column.id}-${rangeFilterIndex !== null && rangeFilterIndex !== void 0 ? rangeFilterIndex : 0}`] =
1608
+ inputRef;
1609
+ if (textFieldProps.inputRef) {
1610
+ textFieldProps.inputRef = inputRef;
1611
+ }
1612
+ }, sx: (theme) => (Object.assign({ p: 0, minWidth: isRangeFilter
1613
+ ? '100px'
1614
+ : !filterChipLabel
1615
+ ? '120px'
1616
+ : 'auto', width: 'calc(100% + 4px)', mx: '-2px', '& .MuiSelect-icon': {
1617
+ mr: '1.5rem',
1618
+ } }, ((textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.sx) instanceof Function
1619
+ ? textFieldProps.sx(theme)
1620
+ : textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.sx))) }, { children: [(isSelectFilter || isMultiSelectFilter) && (jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ divider: true, disabled: true, hidden: true, value: "" }, { children: jsxRuntime.jsx(Box__default["default"], Object.assign({ sx: { opacity: 0.5 } }, { children: filterPlaceholder })) }))), (_k = textFieldProps.children) !== null && _k !== void 0 ? _k : (_l = columnDef === null || columnDef === void 0 ? void 0 : columnDef.filterSelectOptions) === null || _l === void 0 ? void 0 : _l.map((option) => {
1764
1621
  var _a;
1765
- const selectedValue = (_a = columnDef.filterSelectOptions) === null || _a === void 0 ? void 0 : _a.find((option) => option instanceof Object
1766
- ? option.value === value
1767
- : option === value);
1768
- return (React__default["default"].createElement(Chip__default["default"], { key: value, label: selectedValue instanceof Object
1769
- ? selectedValue.text
1770
- : selectedValue }));
1771
- })))
1772
- : undefined,
1773
- } }, textFieldProps, { inputRef: (inputRef) => {
1774
- filterInputRefs.current[`${column.id}-${rangeFilterIndex !== null && rangeFilterIndex !== void 0 ? rangeFilterIndex : 0}`] =
1775
- inputRef;
1776
- if (textFieldProps.inputRef) {
1777
- textFieldProps.inputRef = inputRef;
1778
- }
1779
- }, sx: (theme) => (Object.assign({ p: 0, minWidth: isRangeFilter
1780
- ? '100px'
1781
- : !filterChipLabel
1782
- ? '120px'
1783
- : 'auto', width: 'calc(100% + 4px)', mx: '-2px', '& .MuiSelect-icon': {
1784
- mr: '1.5rem',
1785
- } }, ((textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.sx) instanceof Function
1786
- ? textFieldProps.sx(theme)
1787
- : textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.sx))) }),
1788
- (isSelectFilter || isMultiSelectFilter) && (React__default["default"].createElement(MenuItem__default["default"], { divider: true, disabled: true, hidden: true, value: "" },
1789
- React__default["default"].createElement(Box__default["default"], { sx: { opacity: 0.5 } }, filterPlaceholder))), (_k = textFieldProps.children) !== null && _k !== void 0 ? _k : (_l = columnDef === null || columnDef === void 0 ? void 0 : columnDef.filterSelectOptions) === null || _l === void 0 ? void 0 : _l.map((option) => {
1790
- var _a;
1791
- let value;
1792
- let text;
1793
- if (typeof option !== 'object') {
1794
- value = option;
1795
- text = option;
1796
- }
1797
- else {
1798
- value = option.value;
1799
- text = option.text;
1800
- }
1801
- return (React__default["default"].createElement(MenuItem__default["default"], { key: value, sx: {
1802
- display: 'flex',
1803
- m: 0,
1804
- alignItems: 'center',
1805
- gap: '0.5rem',
1806
- }, value: value },
1807
- isMultiSelectFilter && (React__default["default"].createElement(Checkbox__default["default"], { checked: ((_a = column.getFilterValue()) !== null && _a !== void 0 ? _a : []).includes(value), sx: { mr: '0.5rem' } })),
1808
- text));
1809
- })),
1810
- React__default["default"].createElement(MRT_FilterOptionMenu, { anchorEl: anchorEl, header: header, setAnchorEl: setAnchorEl, table: table, setFilterValue: setFilterValue })));
1622
+ let value;
1623
+ let text;
1624
+ if (typeof option !== 'object') {
1625
+ value = option;
1626
+ text = option;
1627
+ }
1628
+ else {
1629
+ value = option.value;
1630
+ text = option.text;
1631
+ }
1632
+ return (jsxRuntime.jsxs(MenuItem__default["default"], Object.assign({ sx: {
1633
+ display: 'flex',
1634
+ m: 0,
1635
+ alignItems: 'center',
1636
+ gap: '0.5rem',
1637
+ }, value: value }, { children: [isMultiSelectFilter && (jsxRuntime.jsx(Checkbox__default["default"], { checked: ((_a = column.getFilterValue()) !== null && _a !== void 0 ? _a : []).includes(value), sx: { mr: '0.5rem' } })), text] }), value));
1638
+ })] })), jsxRuntime.jsx(MRT_FilterOptionMenu, { anchorEl: anchorEl, header: header, setAnchorEl: setAnchorEl, table: table, setFilterValue: setFilterValue })] }));
1811
1639
  };
1812
1640
 
1813
1641
  const MRT_FilterRangeFields = ({ header, table }) => {
1814
- return (React__default["default"].createElement(Box__default["default"], { sx: { display: 'grid', gridTemplateColumns: '6fr 6fr', gap: '1rem' } },
1815
- React__default["default"].createElement(MRT_FilterTextField, { header: header, rangeFilterIndex: 0, table: table }),
1816
- React__default["default"].createElement(MRT_FilterTextField, { header: header, rangeFilterIndex: 1, table: table })));
1642
+ return (jsxRuntime.jsxs(Box__default["default"], Object.assign({ sx: { display: 'grid', gridTemplateColumns: '6fr 6fr', gap: '1rem' } }, { children: [jsxRuntime.jsx(MRT_FilterTextField, { header: header, rangeFilterIndex: 0, table: table }), jsxRuntime.jsx(MRT_FilterTextField, { header: header, rangeFilterIndex: 1, table: table })] })));
1817
1643
  };
1818
1644
 
1819
1645
  const MRT_FilterCheckbox = ({ column, table }) => {
@@ -1835,8 +1661,7 @@ const MRT_FilterCheckbox = ({ column, table }) => {
1835
1661
  : columnDef.muiTableHeadCellFilterCheckboxProps;
1836
1662
  const checkboxProps = Object.assign(Object.assign({}, mTableHeadCellFilterCheckboxProps), mcTableHeadCellFilterCheckboxProps);
1837
1663
  const filterLabel = (_a = localization.filterByColumn) === null || _a === void 0 ? void 0 : _a.replace('{column}', columnDef.header);
1838
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: (_b = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.title) !== null && _b !== void 0 ? _b : filterLabel },
1839
- React__default["default"].createElement(FormControlLabel__default["default"], { control: React__default["default"].createElement(Checkbox__default["default"], Object.assign({ checked: column.getFilterValue() === 'true', indeterminate: column.getFilterValue() === undefined, color: column.getFilterValue() === undefined ? 'default' : 'primary', size: density === 'compact' ? 'small' : 'medium' }, checkboxProps, { onClick: (e) => {
1664
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, title: (_b = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.title) !== null && _b !== void 0 ? _b : filterLabel }, { children: jsxRuntime.jsx(FormControlLabel__default["default"], { control: jsxRuntime.jsx(Checkbox__default["default"], Object.assign({ checked: column.getFilterValue() === 'true', indeterminate: column.getFilterValue() === undefined, color: column.getFilterValue() === undefined ? 'default' : 'primary', size: density === 'compact' ? 'small' : 'medium' }, checkboxProps, { onClick: (e) => {
1840
1665
  var _a;
1841
1666
  e.stopPropagation();
1842
1667
  (_a = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.onClick) === null || _a === void 0 ? void 0 : _a.call(checkboxProps, e);
@@ -1850,7 +1675,7 @@ const MRT_FilterCheckbox = ({ column, table }) => {
1850
1675
  (_a = checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.onChange) === null || _a === void 0 ? void 0 : _a.call(checkboxProps, e, checked);
1851
1676
  }, sx: (theme) => (Object.assign({ height: '2.5rem', width: '2.5rem' }, ((checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.sx) instanceof Function
1852
1677
  ? checkboxProps.sx(theme)
1853
- : checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.sx))) })), disableTypography: true, label: (_c = checkboxProps.title) !== null && _c !== void 0 ? _c : filterLabel, sx: { color: 'text.secondary', mt: '-4px', fontWeight: 'normal' }, title: undefined })));
1678
+ : checkboxProps === null || checkboxProps === void 0 ? void 0 : checkboxProps.sx))) })), disableTypography: true, label: (_c = checkboxProps.title) !== null && _c !== void 0 ? _c : filterLabel, sx: { color: 'text.secondary', mt: '-4px', fontWeight: 'normal' }, title: undefined }) })));
1854
1679
  };
1855
1680
 
1856
1681
  const MRT_TableHeadCellFilterContainer = ({ header, table }) => {
@@ -1858,8 +1683,8 @@ const MRT_TableHeadCellFilterContainer = ({ header, table }) => {
1858
1683
  const { showColumnFilters } = getState();
1859
1684
  const { column } = header;
1860
1685
  const { columnDef } = column;
1861
- return (React__default["default"].createElement(Collapse__default["default"], { in: showColumnFilters, mountOnEnter: true, unmountOnExit: true }, columnDef.filterVariant === 'checkbox' ? (React__default["default"].createElement(MRT_FilterCheckbox, { column: column, table: table })) : columnDef.filterVariant === 'range' ||
1862
- ['between', 'betweenInclusive', 'inNumberRange'].includes(columnDef._filterFn) ? (React__default["default"].createElement(MRT_FilterRangeFields, { header: header, table: table })) : (React__default["default"].createElement(MRT_FilterTextField, { header: header, table: table }))));
1686
+ return (jsxRuntime.jsx(Collapse__default["default"], Object.assign({ in: showColumnFilters, mountOnEnter: true, unmountOnExit: true }, { children: columnDef.filterVariant === 'checkbox' ? (jsxRuntime.jsx(MRT_FilterCheckbox, { column: column, table: table })) : columnDef.filterVariant === 'range' ||
1687
+ ['between', 'betweenInclusive', 'inNumberRange'].includes(columnDef._filterFn) ? (jsxRuntime.jsx(MRT_FilterRangeFields, { header: header, table: table })) : (jsxRuntime.jsx(MRT_FilterTextField, { header: header, table: table })) })));
1863
1688
  };
1864
1689
 
1865
1690
  const MRT_TableHeadCellFilterLabel = ({ header, table }) => {
@@ -1880,12 +1705,9 @@ const MRT_TableHeadCellFilterLabel = ({ header, table }) => {
1880
1705
  ? column.getFilterValue().join(`" ${isRangeFilter ? localization.and : localization.or} "`)
1881
1706
  : column.getFilterValue()}"`)
1882
1707
  .replace('" "', '');
1883
- return (React__default["default"].createElement(Grow__default["default"], { unmountOnExit: true, in: (!!column.getFilterValue() && !isRangeFilter) ||
1708
+ return (jsxRuntime.jsx(Grow__default["default"], Object.assign({ unmountOnExit: true, in: (!!column.getFilterValue() && !isRangeFilter) ||
1884
1709
  (isRangeFilter && // @ts-ignore
1885
- (!!((_b = column.getFilterValue()) === null || _b === void 0 ? void 0 : _b[0]) || !!((_c = column.getFilterValue()) === null || _c === void 0 ? void 0 : _c[1]))) },
1886
- React__default["default"].createElement(Box__default["default"], { component: "span", sx: { flex: '0 0' } },
1887
- React__default["default"].createElement(Tooltip__default["default"], { arrow: true, placement: "top", title: filterTooltip },
1888
- React__default["default"].createElement(IconButton__default["default"], { disableRipple: true, onClick: (event) => {
1710
+ (!!((_b = column.getFilterValue()) === null || _b === void 0 ? void 0 : _b[0]) || !!((_c = column.getFilterValue()) === null || _c === void 0 ? void 0 : _c[1]))) }, { children: jsxRuntime.jsx(Box__default["default"], Object.assign({ component: "span", sx: { flex: '0 0' } }, { children: jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, placement: "top", title: filterTooltip }, { children: jsxRuntime.jsx(IconButton__default["default"], Object.assign({ disableRipple: true, onClick: (event) => {
1889
1711
  setShowColumnFilters(true);
1890
1712
  queueMicrotask(() => {
1891
1713
  var _a, _b;
@@ -1900,8 +1722,7 @@ const MRT_TableHeadCellFilterLabel = ({ header, table }) => {
1900
1722
  p: '2px',
1901
1723
  transform: 'scale(0.66)',
1902
1724
  width: '12px',
1903
- } },
1904
- React__default["default"].createElement(FilterAltIcon, null))))));
1725
+ } }, { children: jsxRuntime.jsx(FilterAltIcon, {}) })) })) })) })));
1905
1726
  };
1906
1727
 
1907
1728
  const MRT_TableHeadCellGrabHandle = ({ column, table, tableHeadCellRef, }) => {
@@ -1935,7 +1756,7 @@ const MRT_TableHeadCellGrabHandle = ({ column, table, tableHeadCellRef, }) => {
1935
1756
  setDraggingColumn(null);
1936
1757
  setHoveredColumn(null);
1937
1758
  };
1938
- return (React__default["default"].createElement(MRT_GrabHandleButton, { iconButtonProps: iconButtonProps, onDragStart: handleDragStart, onDragEnd: handleDragEnd, table: table }));
1759
+ return (jsxRuntime.jsx(MRT_GrabHandleButton, { iconButtonProps: iconButtonProps, onDragStart: handleDragStart, onDragEnd: handleDragEnd, table: table }));
1939
1760
  };
1940
1761
 
1941
1762
  const MRT_TableHeadCellResizeHandle = ({ header, table }) => {
@@ -1943,7 +1764,7 @@ const MRT_TableHeadCellResizeHandle = ({ header, table }) => {
1943
1764
  const { getState, options: { columnResizeMode }, setColumnSizingInfo, } = table;
1944
1765
  const { density } = getState();
1945
1766
  const { column } = header;
1946
- return (React__default["default"].createElement(Box__default["default"], { className: "Mui-TableHeadCell-ResizeHandle-Wrapper", onDoubleClick: () => {
1767
+ return (jsxRuntime.jsx(Box__default["default"], Object.assign({ className: "Mui-TableHeadCell-ResizeHandle-Wrapper", onDoubleClick: () => {
1947
1768
  setColumnSizingInfo((old) => (Object.assign(Object.assign({}, old), { isResizingColumn: false })));
1948
1769
  column.resetSize();
1949
1770
  }, onMouseDown: header.getResizeHandler(), onTouchStart: header.getResizeHandler(), sx: (theme) => ({
@@ -1960,8 +1781,7 @@ const MRT_TableHeadCellResizeHandle = ({ header, table }) => {
1960
1781
  transform: column.getIsResizing() && columnResizeMode === 'onEnd'
1961
1782
  ? `translateX(${(_a = getState().columnSizingInfo.deltaOffset) !== null && _a !== void 0 ? _a : 0}px)`
1962
1783
  : undefined,
1963
- } },
1964
- React__default["default"].createElement(Divider__default["default"], { className: "Mui-TableHeadCell-ResizeHandle-Divider", flexItem: true, orientation: "vertical", sx: {
1784
+ } }, { children: jsxRuntime.jsx(Divider__default["default"], { className: "Mui-TableHeadCell-ResizeHandle-Divider", flexItem: true, orientation: "vertical", sx: {
1965
1785
  borderRadius: '2px',
1966
1786
  borderWidth: '2px',
1967
1787
  height: '24px',
@@ -1971,7 +1791,7 @@ const MRT_TableHeadCellResizeHandle = ({ header, table }) => {
1971
1791
  : 'all 150ms ease-in-out',
1972
1792
  userSelect: 'none',
1973
1793
  zIndex: 4,
1974
- } })));
1794
+ } }) })));
1975
1795
  };
1976
1796
 
1977
1797
  const MRT_TableHeadCellSortLabel = ({ header, table, tableCellProps, }) => {
@@ -1984,9 +1804,7 @@ const MRT_TableHeadCellSortLabel = ({ header, table, tableCellProps, }) => {
1984
1804
  ? localization.sortedByColumnDesc.replace('{column}', columnDef.header)
1985
1805
  : localization.sortedByColumnAsc.replace('{column}', columnDef.header)
1986
1806
  : localization.unsorted;
1987
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, placement: "top", title: sortTooltip },
1988
- React__default["default"].createElement(Badge__default["default"], { badgeContent: sorting.length > 1 ? column.getSortIndex() + 1 : 0, overlap: "circular" },
1989
- React__default["default"].createElement(TableSortLabel__default["default"], { "aria-label": sortTooltip, active: !!column.getIsSorted(), direction: column.getIsSorted()
1807
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, placement: "top", title: sortTooltip }, { children: jsxRuntime.jsx(Badge__default["default"], Object.assign({ badgeContent: sorting.length > 1 ? column.getSortIndex() + 1 : 0, overlap: "circular" }, { children: jsxRuntime.jsx(TableSortLabel__default["default"], { "aria-label": sortTooltip, active: !!column.getIsSorted(), direction: column.getIsSorted()
1990
1808
  ? column.getIsSorted()
1991
1809
  : undefined, sx: {
1992
1810
  flex: '0 0',
@@ -1998,7 +1816,7 @@ const MRT_TableHeadCellSortLabel = ({ header, table, tableCellProps, }) => {
1998
1816
  var _a;
1999
1817
  e.stopPropagation();
2000
1818
  (_a = header.column.getToggleSortingHandler()) === null || _a === void 0 ? void 0 : _a(e);
2001
- } }))));
1819
+ } }) })) })));
2002
1820
  };
2003
1821
 
2004
1822
  const MRT_TableHeadCell = ({ header, table }) => {
@@ -2025,7 +1843,7 @@ const MRT_TableHeadCell = ({ header, table }) => {
2025
1843
  (enableGrouping &&
2026
1844
  columnDef.enableGrouping !== false &&
2027
1845
  !grouping.includes(column.id)));
2028
- const headerPL = React.useMemo(() => {
1846
+ const headerPL = react.useMemo(() => {
2029
1847
  let pl = 0;
2030
1848
  if (column.getCanSort())
2031
1849
  pl++;
@@ -2035,7 +1853,7 @@ const MRT_TableHeadCell = ({ header, table }) => {
2035
1853
  pl += 1.25;
2036
1854
  return pl;
2037
1855
  }, [showColumnActions, showDragHandle]);
2038
- const draggingBorder = React.useMemo(() => (draggingColumn === null || draggingColumn === void 0 ? void 0 : draggingColumn.id) === column.id
1856
+ const draggingBorder = react.useMemo(() => (draggingColumn === null || draggingColumn === void 0 ? void 0 : draggingColumn.id) === column.id
2039
1857
  ? `1px dashed ${theme.palette.text.secondary}`
2040
1858
  : (hoveredColumn === null || hoveredColumn === void 0 ? void 0 : hoveredColumn.id) === column.id
2041
1859
  ? `2px dashed ${theme.palette.primary.main}`
@@ -2062,7 +1880,7 @@ const MRT_TableHeadCell = ({ header, table }) => {
2062
1880
  table,
2063
1881
  })
2064
1882
  : (_b = columnDef === null || columnDef === void 0 ? void 0 : columnDef.Header) !== null && _b !== void 0 ? _b : columnDef.header;
2065
- return (React__default["default"].createElement(TableCell__default["default"], Object.assign({ align: columnDefType === 'group' ? 'center' : 'left', colSpan: header.colSpan, onDragEnter: handleDragEnter, ref: (node) => {
1883
+ return (jsxRuntime.jsxs(TableCell__default["default"], Object.assign({ align: columnDefType === 'group' ? 'center' : 'left', colSpan: header.colSpan, onDragEnter: handleDragEnter, ref: (node) => {
2066
1884
  if (node) {
2067
1885
  tableHeadCellRefs.current[column.id] = node;
2068
1886
  }
@@ -2092,49 +1910,39 @@ const MRT_TableHeadCell = ({ header, table }) => {
2092
1910
  table,
2093
1911
  tableCellProps,
2094
1912
  theme,
2095
- })), draggingBorders)) }),
2096
- header.isPlaceholder ? null : (React__default["default"].createElement(Box__default["default"], { className: "Mui-TableHeadCell-Content", sx: {
2097
- alignItems: 'center',
2098
- display: 'flex',
2099
- flexDirection: (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'right' ? 'row-reverse' : 'row',
2100
- justifyContent: columnDefType === 'group' || (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'center'
2101
- ? 'center'
2102
- : column.getCanResize()
2103
- ? 'space-between'
2104
- : 'flex-start',
2105
- position: 'relative',
2106
- width: '100%',
2107
- } },
2108
- React__default["default"].createElement(Box__default["default"], { className: "Mui-TableHeadCell-Content-Labels", onClick: column.getToggleSortingHandler(), sx: {
1913
+ })), draggingBorders)) }, { children: [header.isPlaceholder ? null : (jsxRuntime.jsxs(Box__default["default"], Object.assign({ className: "Mui-TableHeadCell-Content", sx: {
2109
1914
  alignItems: 'center',
2110
- cursor: column.getCanSort() && columnDefType !== 'group'
2111
- ? 'pointer'
2112
- : undefined,
2113
1915
  display: 'flex',
2114
1916
  flexDirection: (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'right' ? 'row-reverse' : 'row',
2115
- overflow: columnDefType === 'data' ? 'hidden' : undefined,
2116
- pl: (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'center'
2117
- ? `${headerPL}rem`
2118
- : undefined,
2119
- } },
2120
- React__default["default"].createElement(Box__default["default"], { className: "Mui-TableHeadCell-Content-Wrapper", sx: {
2121
- minWidth: `${Math.min((_d = (_c = columnDef.header) === null || _c === void 0 ? void 0 : _c.length) !== null && _d !== void 0 ? _d : 0, 5)}ch`,
2122
- overflow: columnDefType === 'data' ? 'hidden' : undefined,
2123
- textOverflow: 'ellipsis',
2124
- whiteSpace: ((_g = (_f = columnDef.header) === null || _f === void 0 ? void 0 : _f.length) !== null && _g !== void 0 ? _g : 0) < 20 ? 'nowrap' : 'normal',
2125
- '&:hover': {
2126
- textOverflow: 'clip',
2127
- },
2128
- }, title: columnDefType === 'data' ? columnDef.header : undefined }, headerElement),
2129
- column.getCanSort() && (React__default["default"].createElement(MRT_TableHeadCellSortLabel, { header: header, table: table, tableCellProps: tableCellProps })),
2130
- column.getCanFilter() && (React__default["default"].createElement(MRT_TableHeadCellFilterLabel, { header: header, table: table }))),
2131
- columnDefType !== 'group' && (React__default["default"].createElement(Box__default["default"], { className: "Mui-TableHeadCell-Content-Actions", sx: { whiteSpace: 'nowrap' } },
2132
- showDragHandle && (React__default["default"].createElement(MRT_TableHeadCellGrabHandle, { column: column, table: table, tableHeadCellRef: {
2133
- current: tableHeadCellRefs.current[column.id],
2134
- } })),
2135
- showColumnActions && (React__default["default"].createElement(MRT_TableHeadCellColumnActionsButton, { header: header, table: table })))),
2136
- column.getCanResize() && (React__default["default"].createElement(MRT_TableHeadCellResizeHandle, { header: header, table: table })))),
2137
- column.getCanFilter() && (React__default["default"].createElement(MRT_TableHeadCellFilterContainer, { header: header, table: table }))));
1917
+ justifyContent: columnDefType === 'group' || (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'center'
1918
+ ? 'center'
1919
+ : column.getCanResize()
1920
+ ? 'space-between'
1921
+ : 'flex-start',
1922
+ position: 'relative',
1923
+ width: '100%',
1924
+ } }, { children: [jsxRuntime.jsxs(Box__default["default"], Object.assign({ className: "Mui-TableHeadCell-Content-Labels", onClick: column.getToggleSortingHandler(), sx: {
1925
+ alignItems: 'center',
1926
+ cursor: column.getCanSort() && columnDefType !== 'group'
1927
+ ? 'pointer'
1928
+ : undefined,
1929
+ display: 'flex',
1930
+ flexDirection: (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'right' ? 'row-reverse' : 'row',
1931
+ overflow: columnDefType === 'data' ? 'hidden' : undefined,
1932
+ pl: (tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.align) === 'center'
1933
+ ? `${headerPL}rem`
1934
+ : undefined,
1935
+ } }, { children: [jsxRuntime.jsx(Box__default["default"], Object.assign({ className: "Mui-TableHeadCell-Content-Wrapper", sx: {
1936
+ minWidth: `${Math.min((_d = (_c = columnDef.header) === null || _c === void 0 ? void 0 : _c.length) !== null && _d !== void 0 ? _d : 0, 5)}ch`,
1937
+ overflow: columnDefType === 'data' ? 'hidden' : undefined,
1938
+ textOverflow: 'ellipsis',
1939
+ whiteSpace: ((_g = (_f = columnDef.header) === null || _f === void 0 ? void 0 : _f.length) !== null && _g !== void 0 ? _g : 0) < 20 ? 'nowrap' : 'normal',
1940
+ '&:hover': {
1941
+ textOverflow: 'clip',
1942
+ },
1943
+ }, title: columnDefType === 'data' ? columnDef.header : undefined }, { children: headerElement })), column.getCanSort() && (jsxRuntime.jsx(MRT_TableHeadCellSortLabel, { header: header, table: table, tableCellProps: tableCellProps })), column.getCanFilter() && (jsxRuntime.jsx(MRT_TableHeadCellFilterLabel, { header: header, table: table }))] })), columnDefType !== 'group' && (jsxRuntime.jsxs(Box__default["default"], Object.assign({ className: "Mui-TableHeadCell-Content-Actions", sx: { whiteSpace: 'nowrap' } }, { children: [showDragHandle && (jsxRuntime.jsx(MRT_TableHeadCellGrabHandle, { column: column, table: table, tableHeadCellRef: {
1944
+ current: tableHeadCellRefs.current[column.id],
1945
+ } })), showColumnActions && (jsxRuntime.jsx(MRT_TableHeadCellColumnActionsButton, { header: header, table: table }))] }))), column.getCanResize() && (jsxRuntime.jsx(MRT_TableHeadCellResizeHandle, { header: header, table: table }))] }))), column.getCanFilter() && (jsxRuntime.jsx(MRT_TableHeadCellFilterContainer, { header: header, table: table }))] })));
2138
1946
  };
2139
1947
 
2140
1948
  const MRT_TableHeadRow = ({ headerGroup, table, virtualColumns, virtualPaddingLeft, virtualPaddingRight, }) => {
@@ -2142,17 +1950,14 @@ const MRT_TableHeadRow = ({ headerGroup, table, virtualColumns, virtualPaddingLe
2142
1950
  const tableRowProps = muiTableHeadRowProps instanceof Function
2143
1951
  ? muiTableHeadRowProps({ headerGroup, table })
2144
1952
  : muiTableHeadRowProps;
2145
- return (React__default["default"].createElement(TableRow__default["default"], Object.assign({}, tableRowProps, { sx: (theme) => (Object.assign({ backgroundColor: styles.lighten(theme.palette.background.default, 0.04), boxShadow: `4px 0 8px ${styles.alpha(theme.palette.common.black, 0.1)}`, display: layoutMode === 'grid' ? 'flex' : 'table-row', top: 0 }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
1953
+ return (jsxRuntime.jsxs(TableRow__default["default"], Object.assign({}, tableRowProps, { sx: (theme) => (Object.assign({ backgroundColor: styles.lighten(theme.palette.background.default, 0.04), boxShadow: `4px 0 8px ${styles.alpha(theme.palette.common.black, 0.1)}`, display: layoutMode === 'grid' ? 'flex' : 'table-row', top: 0 }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
2146
1954
  ? tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx(theme)
2147
- : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx))) }),
2148
- virtualPaddingLeft ? (React__default["default"].createElement("th", { style: { display: 'flex', width: virtualPaddingLeft } })) : null,
2149
- (virtualColumns !== null && virtualColumns !== void 0 ? virtualColumns : headerGroup.headers).map((headerOrVirtualHeader) => {
2150
- const header = virtualColumns
2151
- ? headerGroup.headers[headerOrVirtualHeader.index]
2152
- : headerOrVirtualHeader;
2153
- return (React__default["default"].createElement(MRT_TableHeadCell, { header: header, key: header.id, table: table }));
2154
- }),
2155
- virtualPaddingRight ? (React__default["default"].createElement("th", { style: { display: 'flex', width: virtualPaddingRight } })) : null));
1955
+ : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx))) }, { children: [virtualPaddingLeft ? (jsxRuntime.jsx("th", { style: { display: 'flex', width: virtualPaddingLeft } })) : null, (virtualColumns !== null && virtualColumns !== void 0 ? virtualColumns : headerGroup.headers).map((headerOrVirtualHeader) => {
1956
+ const header = virtualColumns
1957
+ ? headerGroup.headers[headerOrVirtualHeader.index]
1958
+ : headerOrVirtualHeader;
1959
+ return (jsxRuntime.jsx(MRT_TableHeadCell, { header: header, table: table }, header.id));
1960
+ }), virtualPaddingRight ? (jsxRuntime.jsx("th", { style: { display: 'flex', width: virtualPaddingRight } })) : null] })));
2156
1961
  };
2157
1962
 
2158
1963
  const MRT_TableHead = ({ table, virtualColumns, virtualPaddingLeft, virtualPaddingRight, }) => {
@@ -2162,9 +1967,9 @@ const MRT_TableHead = ({ table, virtualColumns, virtualPaddingLeft, virtualPaddi
2162
1967
  ? muiTableHeadProps({ table })
2163
1968
  : muiTableHeadProps;
2164
1969
  const stickyHeader = enableStickyHeader || isFullScreen;
2165
- return (React__default["default"].createElement(TableHead__default["default"], Object.assign({}, tableHeadProps, { sx: (theme) => (Object.assign({ display: layoutMode === 'grid' ? 'grid' : 'table-row-group', opacity: 0.97, position: stickyHeader ? 'sticky' : 'relative', top: stickyHeader && layoutMode === 'grid' ? 0 : undefined, zIndex: stickyHeader ? 2 : undefined }, ((tableHeadProps === null || tableHeadProps === void 0 ? void 0 : tableHeadProps.sx) instanceof Function
1970
+ return (jsxRuntime.jsx(TableHead__default["default"], Object.assign({}, tableHeadProps, { sx: (theme) => (Object.assign({ display: layoutMode === 'grid' ? 'grid' : 'table-row-group', opacity: 0.97, position: stickyHeader ? 'sticky' : 'relative', top: stickyHeader && layoutMode === 'grid' ? 0 : undefined, zIndex: stickyHeader ? 2 : undefined }, ((tableHeadProps === null || tableHeadProps === void 0 ? void 0 : tableHeadProps.sx) instanceof Function
2166
1971
  ? tableHeadProps === null || tableHeadProps === void 0 ? void 0 : tableHeadProps.sx(theme)
2167
- : tableHeadProps === null || tableHeadProps === void 0 ? void 0 : tableHeadProps.sx))) }), getHeaderGroups().map((headerGroup) => (React__default["default"].createElement(MRT_TableHeadRow, { headerGroup: headerGroup, key: headerGroup.id, table: table, virtualColumns: virtualColumns, virtualPaddingLeft: virtualPaddingLeft, virtualPaddingRight: virtualPaddingRight })))));
1972
+ : tableHeadProps === null || tableHeadProps === void 0 ? void 0 : tableHeadProps.sx))) }, { children: getHeaderGroups().map((headerGroup) => (jsxRuntime.jsx(MRT_TableHeadRow, { headerGroup: headerGroup, table: table, virtualColumns: virtualColumns, virtualPaddingLeft: virtualPaddingLeft, virtualPaddingRight: virtualPaddingRight }, headerGroup.id))) })));
2168
1973
  };
2169
1974
 
2170
1975
  const MRT_EditCellTextField = ({ cell, showLabel, table, }) => {
@@ -2173,7 +1978,7 @@ const MRT_EditCellTextField = ({ cell, showLabel, table, }) => {
2173
1978
  const { column, row } = cell;
2174
1979
  const { columnDef } = column;
2175
1980
  const { editingRow } = getState();
2176
- const [value, setValue] = React.useState(() => cell.getValue());
1981
+ const [value, setValue] = react.useState(() => cell.getValue());
2177
1982
  const mTableBodyCellEditTextFieldProps = muiTableBodyCellEditTextFieldProps instanceof Function
2178
1983
  ? muiTableBodyCellEditTextFieldProps({ cell, column, row, table })
2179
1984
  : muiTableBodyCellEditTextFieldProps;
@@ -2214,9 +2019,9 @@ const MRT_EditCellTextField = ({ cell, showLabel, table, }) => {
2214
2019
  }
2215
2020
  };
2216
2021
  if (columnDef.Edit) {
2217
- return React__default["default"].createElement(React__default["default"].Fragment, null, (_a = columnDef.Edit) === null || _a === void 0 ? void 0 : _a.call(columnDef, { cell, column, row, table }));
2022
+ return jsxRuntime.jsx(jsxRuntime.Fragment, { children: (_a = columnDef.Edit) === null || _a === void 0 ? void 0 : _a.call(columnDef, { cell, column, row, table }) });
2218
2023
  }
2219
- return (React__default["default"].createElement(TextField__default["default"], Object.assign({ disabled: (columnDef.enableEditing instanceof Function
2024
+ return (jsxRuntime.jsx(TextField__default["default"], Object.assign({ disabled: (columnDef.enableEditing instanceof Function
2220
2025
  ? columnDef.enableEditing(row)
2221
2026
  : columnDef.enableEditing) === false, fullWidth: true, inputRef: (inputRef) => {
2222
2027
  if (inputRef) {
@@ -2229,24 +2034,24 @@ const MRT_EditCellTextField = ({ cell, showLabel, table, }) => {
2229
2034
  var _a;
2230
2035
  e.stopPropagation();
2231
2036
  (_a = textFieldProps === null || textFieldProps === void 0 ? void 0 : textFieldProps.onClick) === null || _a === void 0 ? void 0 : _a.call(textFieldProps, e);
2232
- }, onBlur: handleBlur, onChange: handleChange, onKeyDown: handleEnterKeyDown }), (_b = textFieldProps.children) !== null && _b !== void 0 ? _b : (_c = columnDef === null || columnDef === void 0 ? void 0 : columnDef.editSelectOptions) === null || _c === void 0 ? void 0 : _c.map((option) => {
2233
- let value;
2234
- let text;
2235
- if (typeof option !== 'object') {
2236
- value = option;
2237
- text = option;
2238
- }
2239
- else {
2240
- value = option.value;
2241
- text = option.text;
2242
- }
2243
- return (React__default["default"].createElement(MenuItem__default["default"], { key: value, sx: {
2244
- display: 'flex',
2245
- m: 0,
2246
- alignItems: 'center',
2247
- gap: '0.5rem',
2248
- }, value: value }, text));
2249
- })));
2037
+ }, onBlur: handleBlur, onChange: handleChange, onKeyDown: handleEnterKeyDown }, { children: (_b = textFieldProps.children) !== null && _b !== void 0 ? _b : (_c = columnDef === null || columnDef === void 0 ? void 0 : columnDef.editSelectOptions) === null || _c === void 0 ? void 0 : _c.map((option) => {
2038
+ let value;
2039
+ let text;
2040
+ if (typeof option !== 'object') {
2041
+ value = option;
2042
+ text = option;
2043
+ }
2044
+ else {
2045
+ value = option.value;
2046
+ text = option.text;
2047
+ }
2048
+ return (jsxRuntime.jsx(MenuItem__default["default"], Object.assign({ sx: {
2049
+ display: 'flex',
2050
+ m: 0,
2051
+ alignItems: 'center',
2052
+ gap: '0.5rem',
2053
+ }, value: value }, { children: text }), value));
2054
+ }) })));
2250
2055
  };
2251
2056
 
2252
2057
  const MRT_CopyButton = ({ cell, children, table, }) => {
@@ -2254,7 +2059,7 @@ const MRT_CopyButton = ({ cell, children, table, }) => {
2254
2059
  const { options: { localization, muiTableBodyCellCopyButtonProps }, } = table;
2255
2060
  const { column, row } = cell;
2256
2061
  const { columnDef } = column;
2257
- const [copied, setCopied] = React.useState(false);
2062
+ const [copied, setCopied] = react.useState(false);
2258
2063
  const handleCopy = (event, text) => {
2259
2064
  event.stopPropagation();
2260
2065
  navigator.clipboard.writeText(text);
@@ -2273,10 +2078,9 @@ const MRT_CopyButton = ({ cell, children, table, }) => {
2273
2078
  })
2274
2079
  : columnDef.muiTableBodyCellCopyButtonProps;
2275
2080
  const buttonProps = Object.assign(Object.assign({}, mTableBodyCellCopyButtonProps), mcTableBodyCellCopyButtonProps);
2276
- return (React__default["default"].createElement(Tooltip__default["default"], { arrow: true, enterDelay: 1000, enterNextDelay: 1000, placement: "top", title: (_a = buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.title) !== null && _a !== void 0 ? _a : (copied ? localization.copiedToClipboard : localization.clickToCopy) },
2277
- React__default["default"].createElement(Button__default["default"], Object.assign({ onClick: (e) => handleCopy(e, cell.getValue()), size: "small", type: "button", variant: "text" }, buttonProps, { sx: (theme) => (Object.assign({ backgroundColor: 'transparent', border: 'none', color: 'inherit', cursor: 'copy', fontFamily: 'inherit', fontSize: 'inherit', letterSpacing: 'inherit', m: '-0.25rem', minWidth: 'unset', textAlign: 'inherit', textTransform: 'inherit' }, ((buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.sx) instanceof Function
2081
+ return (jsxRuntime.jsx(Tooltip__default["default"], Object.assign({ arrow: true, enterDelay: 1000, enterNextDelay: 1000, placement: "top", title: (_a = buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.title) !== null && _a !== void 0 ? _a : (copied ? localization.copiedToClipboard : localization.clickToCopy) }, { children: jsxRuntime.jsx(Button__default["default"], Object.assign({ onClick: (e) => handleCopy(e, cell.getValue()), size: "small", type: "button", variant: "text" }, buttonProps, { sx: (theme) => (Object.assign({ backgroundColor: 'transparent', border: 'none', color: 'inherit', cursor: 'copy', fontFamily: 'inherit', fontSize: 'inherit', letterSpacing: 'inherit', m: '-0.25rem', minWidth: 'unset', textAlign: 'inherit', textTransform: 'inherit' }, ((buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.sx) instanceof Function
2278
2082
  ? buttonProps.sx(theme)
2279
- : buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.sx))), title: undefined }), children)));
2083
+ : buttonProps === null || buttonProps === void 0 ? void 0 : buttonProps.sx))), title: undefined }, { children: children })) })));
2280
2084
  };
2281
2085
 
2282
2086
  const MRT_TableBodyRowGrabHandle = ({ cell, rowRef, table }) => {
@@ -2297,7 +2101,7 @@ const MRT_TableBodyRowGrabHandle = ({ cell, rowRef, table }) => {
2297
2101
  table.setDraggingRow(null);
2298
2102
  table.setHoveredRow(null);
2299
2103
  };
2300
- return (React__default["default"].createElement(MRT_GrabHandleButton, { iconButtonProps: iconButtonProps, onDragStart: handleDragStart, onDragEnd: handleDragEnd, table: table }));
2104
+ return (jsxRuntime.jsx(MRT_GrabHandleButton, { iconButtonProps: iconButtonProps, onDragStart: handleDragStart, onDragEnd: handleDragEnd, table: table }));
2301
2105
  };
2302
2106
 
2303
2107
  const allowedTypes = ['string', 'number'];
@@ -2345,16 +2149,16 @@ const MRT_TableBodyCellValue = ({ cell, table }) => {
2345
2149
  matchExactly: (filterValue ? columnDef._filterFn : globalFilterFn) !== 'fuzzy',
2346
2150
  });
2347
2151
  if ((chunks === null || chunks === void 0 ? void 0 : chunks.length) > 1 || ((_b = chunks === null || chunks === void 0 ? void 0 : chunks[0]) === null || _b === void 0 ? void 0 : _b.match)) {
2348
- renderedCellValue = (React__default["default"].createElement("span", { "aria-label": renderedCellValue, role: "note" }, (_c = chunks === null || chunks === void 0 ? void 0 : chunks.map(({ key, match, text }) => (React__default["default"].createElement(Box__default["default"], { "aria-hidden": "true", component: "span", key: key, sx: match
2349
- ? {
2350
- backgroundColor: (theme) => theme.palette.mode === 'dark'
2351
- ? styles.darken(theme.palette.warning.dark, 0.25)
2352
- : styles.lighten(theme.palette.warning.light, 0.5),
2353
- borderRadius: '2px',
2354
- color: (theme) => theme.palette.mode === 'dark' ? 'white' : 'black',
2355
- padding: '2px 1px',
2356
- }
2357
- : undefined }, text)))) !== null && _c !== void 0 ? _c : renderedCellValue));
2152
+ renderedCellValue = (jsxRuntime.jsx("span", Object.assign({ "aria-label": renderedCellValue, role: "note" }, { children: (_c = chunks === null || chunks === void 0 ? void 0 : chunks.map(({ key, match, text }) => (jsxRuntime.jsx(Box__default["default"], Object.assign({ "aria-hidden": "true", component: "span", sx: match
2153
+ ? {
2154
+ backgroundColor: (theme) => theme.palette.mode === 'dark'
2155
+ ? styles.darken(theme.palette.warning.dark, 0.25)
2156
+ : styles.lighten(theme.palette.warning.light, 0.5),
2157
+ borderRadius: '2px',
2158
+ color: (theme) => theme.palette.mode === 'dark' ? 'white' : 'black',
2159
+ padding: '2px 1px',
2160
+ }
2161
+ : undefined }, { children: text }), key)))) !== null && _c !== void 0 ? _c : renderedCellValue })));
2358
2162
  }
2359
2163
  }
2360
2164
  if (columnDef.Cell && !isGroupedValue) {
@@ -2366,7 +2170,7 @@ const MRT_TableBodyCellValue = ({ cell, table }) => {
2366
2170
  table,
2367
2171
  });
2368
2172
  }
2369
- return React__default["default"].createElement(React__default["default"].Fragment, null, renderedCellValue);
2173
+ return jsxRuntime.jsx(jsxRuntime.Fragment, { children: renderedCellValue });
2370
2174
  };
2371
2175
 
2372
2176
  const MRT_TableBodyCell = ({ cell, measureElement, numRows, rowIndex, rowRef, table, virtualCell, }) => {
@@ -2387,14 +2191,14 @@ const MRT_TableBodyCell = ({ cell, measureElement, numRows, rowIndex, rowRef, ta
2387
2191
  const skeletonProps = muiTableBodyCellSkeletonProps instanceof Function
2388
2192
  ? muiTableBodyCellSkeletonProps({ cell, column, row, table })
2389
2193
  : muiTableBodyCellSkeletonProps;
2390
- const [skeletonWidth, setSkeletonWidth] = React.useState(0);
2391
- React.useEffect(() => setSkeletonWidth(isLoading || showSkeletons
2194
+ const [skeletonWidth, setSkeletonWidth] = react.useState(0);
2195
+ react.useEffect(() => setSkeletonWidth(isLoading || showSkeletons
2392
2196
  ? columnDefType === 'display'
2393
2197
  ? column.getSize() / 2
2394
2198
  : Math.round(Math.random() * (column.getSize() - column.getSize() / 3) +
2395
2199
  column.getSize() / 3)
2396
2200
  : 100), []);
2397
- const draggingBorders = React.useMemo(() => {
2201
+ const draggingBorders = react.useMemo(() => {
2398
2202
  const isDraggingColumn = (draggingColumn === null || draggingColumn === void 0 ? void 0 : draggingColumn.id) === column.id;
2399
2203
  const isHoveredColumn = (hoveredColumn === null || hoveredColumn === void 0 ? void 0 : hoveredColumn.id) === column.id;
2400
2204
  const isDraggingRow = (draggingRow === null || draggingRow === void 0 ? void 0 : draggingRow.id) === row.id;
@@ -2461,7 +2265,7 @@ const MRT_TableBodyCell = ({ cell, measureElement, numRows, rowIndex, rowRef, ta
2461
2265
  setHoveredColumn(columnDef.enableColumnOrdering !== false ? column : null);
2462
2266
  }
2463
2267
  };
2464
- return (React__default["default"].createElement(TableCell__default["default"], Object.assign({ "data-index": virtualCell === null || virtualCell === void 0 ? void 0 : virtualCell.index, ref: (node) => {
2268
+ return (jsxRuntime.jsx(TableCell__default["default"], Object.assign({ "data-index": virtualCell === null || virtualCell === void 0 ? void 0 : virtualCell.index, ref: (node) => {
2465
2269
  if (node) {
2466
2270
  measureElement === null || measureElement === void 0 ? void 0 : measureElement(node);
2467
2271
  }
@@ -2493,28 +2297,21 @@ const MRT_TableBodyCell = ({ cell, measureElement, numRows, rowIndex, rowRef, ta
2493
2297
  table,
2494
2298
  theme,
2495
2299
  tableCellProps,
2496
- })), draggingBorders)) }),
2497
- React__default["default"].createElement(React__default["default"].Fragment, null,
2498
- cell.getIsPlaceholder() ? ((_b = (_a = columnDef.PlaceholderCell) === null || _a === void 0 ? void 0 : _a.call(columnDef, { cell, column, row, table })) !== null && _b !== void 0 ? _b : null) : isLoading || showSkeletons ? (React__default["default"].createElement(Skeleton__default["default"], Object.assign({ animation: "wave", height: 20, width: skeletonWidth }, skeletonProps))) : enableRowNumbers &&
2499
- rowNumberMode === 'static' &&
2500
- column.id === 'mrt-row-numbers' ? (rowIndex + 1) : column.id === 'mrt-row-drag' ? (React__default["default"].createElement(MRT_TableBodyRowGrabHandle, { cell: cell, rowRef: rowRef, table: table })) : columnDefType === 'display' &&
2501
- (column.id === 'mrt-row-select' ||
2502
- column.id === 'mrt-row-expand' ||
2503
- !row.getIsGrouped()) ? ((_c = columnDef.Cell) === null || _c === void 0 ? void 0 : _c.call(columnDef, {
2504
- cell,
2505
- renderedCellValue: cell.renderValue(),
2506
- column,
2507
- row,
2508
- table,
2509
- })) : isEditing ? (React__default["default"].createElement(MRT_EditCellTextField, { cell: cell, table: table })) : (enableClickToCopy || columnDef.enableClickToCopy) &&
2510
- columnDef.enableClickToCopy !== false ? (React__default["default"].createElement(MRT_CopyButton, { cell: cell, table: table },
2511
- React__default["default"].createElement(MRT_TableBodyCellValue, { cell: cell, table: table }))) : (React__default["default"].createElement(MRT_TableBodyCellValue, { cell: cell, table: table })),
2512
- cell.getIsGrouped() && !columnDef.GroupedCell && (React__default["default"].createElement(React__default["default"].Fragment, null,
2513
- " (", (_d = row.subRows) === null || _d === void 0 ? void 0 :
2514
- _d.length,
2515
- ")")))));
2300
+ })), draggingBorders)) }, { children: jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [cell.getIsPlaceholder() ? ((_b = (_a = columnDef.PlaceholderCell) === null || _a === void 0 ? void 0 : _a.call(columnDef, { cell, column, row, table })) !== null && _b !== void 0 ? _b : null) : isLoading || showSkeletons ? (jsxRuntime.jsx(Skeleton__default["default"], Object.assign({ animation: "wave", height: 20, width: skeletonWidth }, skeletonProps))) : enableRowNumbers &&
2301
+ rowNumberMode === 'static' &&
2302
+ column.id === 'mrt-row-numbers' ? (rowIndex + 1) : column.id === 'mrt-row-drag' ? (jsxRuntime.jsx(MRT_TableBodyRowGrabHandle, { cell: cell, rowRef: rowRef, table: table })) : columnDefType === 'display' &&
2303
+ (column.id === 'mrt-row-select' ||
2304
+ column.id === 'mrt-row-expand' ||
2305
+ !row.getIsGrouped()) ? ((_c = columnDef.Cell) === null || _c === void 0 ? void 0 : _c.call(columnDef, {
2306
+ cell,
2307
+ renderedCellValue: cell.renderValue(),
2308
+ column,
2309
+ row,
2310
+ table,
2311
+ })) : isEditing ? (jsxRuntime.jsx(MRT_EditCellTextField, { cell: cell, table: table })) : (enableClickToCopy || columnDef.enableClickToCopy) &&
2312
+ columnDef.enableClickToCopy !== false ? (jsxRuntime.jsx(MRT_CopyButton, Object.assign({ cell: cell, table: table }, { children: jsxRuntime.jsx(MRT_TableBodyCellValue, { cell: cell, table: table }) }))) : (jsxRuntime.jsx(MRT_TableBodyCellValue, { cell: cell, table: table })), cell.getIsGrouped() && !columnDef.GroupedCell && (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [" (", (_d = row.subRows) === null || _d === void 0 ? void 0 : _d.length, ")"] }))] }) })));
2516
2313
  };
2517
- const Memo_MRT_TableBodyCell = React.memo(MRT_TableBodyCell, (prev, next) => next.cell === prev.cell);
2314
+ const Memo_MRT_TableBodyCell = react.memo(MRT_TableBodyCell, (prev, next) => next.cell === prev.cell);
2518
2315
 
2519
2316
  const MRT_TableDetailPanel = ({ parentRowRef, row, rowIndex, table, virtualRow, }) => {
2520
2317
  const { getVisibleLeafColumns, getState, options: { layoutMode, muiTableBodyRowProps, muiTableDetailPanelProps, renderDetailPanel, }, } = table;
@@ -2530,7 +2327,7 @@ const MRT_TableDetailPanel = ({ parentRowRef, row, rowIndex, table, virtualRow,
2530
2327
  const tableCellProps = muiTableDetailPanelProps instanceof Function
2531
2328
  ? muiTableDetailPanelProps({ row, table })
2532
2329
  : muiTableDetailPanelProps;
2533
- return (React__default["default"].createElement(TableRow__default["default"], Object.assign({ className: "Mui-TableBodyCell-DetailPanel" }, tableRowProps, { sx: (theme) => {
2330
+ return (jsxRuntime.jsx(TableRow__default["default"], Object.assign({ className: "Mui-TableBodyCell-DetailPanel" }, tableRowProps, { sx: (theme) => {
2534
2331
  var _a, _b;
2535
2332
  return (Object.assign({ display: layoutMode === 'grid' ? 'flex' : 'table-row', position: virtualRow ? 'absolute' : undefined, top: virtualRow
2536
2333
  ? `${(_b = (_a = parentRowRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect()) === null || _b === void 0 ? void 0 : _b.height}px`
@@ -2539,12 +2336,11 @@ const MRT_TableDetailPanel = ({ parentRowRef, row, rowIndex, table, virtualRow,
2539
2336
  : undefined, width: '100%', zIndex: virtualRow ? 2 : undefined }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
2540
2337
  ? tableRowProps.sx(theme)
2541
2338
  : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx)));
2542
- } }),
2543
- React__default["default"].createElement(TableCell__default["default"], Object.assign({ className: "Mui-TableBodyCell-DetailPanel", colSpan: getVisibleLeafColumns().length }, tableCellProps, { sx: (theme) => (Object.assign({ backgroundColor: virtualRow
2339
+ } }, { children: jsxRuntime.jsx(TableCell__default["default"], Object.assign({ className: "Mui-TableBodyCell-DetailPanel", colSpan: getVisibleLeafColumns().length }, tableCellProps, { sx: (theme) => (Object.assign({ backgroundColor: virtualRow
2544
2340
  ? styles.lighten(theme.palette.background.default, 0.06)
2545
2341
  : undefined, borderBottom: !row.getIsExpanded() ? 'none' : undefined, display: layoutMode === 'grid' ? 'flex' : 'table-cell', pb: row.getIsExpanded() ? '1rem' : 0, pt: row.getIsExpanded() ? '1rem' : 0, transition: 'all 150ms ease-in-out', width: `${table.getTotalSize()}px` }, ((tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.sx) instanceof Function
2546
2342
  ? tableCellProps.sx(theme)
2547
- : tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.sx))) }), renderDetailPanel && (React__default["default"].createElement(Collapse__default["default"], { in: row.getIsExpanded(), mountOnEnter: true, unmountOnExit: true }, !isLoading && renderDetailPanel({ row, table }))))));
2343
+ : tableCellProps === null || tableCellProps === void 0 ? void 0 : tableCellProps.sx))) }, { children: renderDetailPanel && (jsxRuntime.jsx(Collapse__default["default"], Object.assign({ in: row.getIsExpanded(), mountOnEnter: true, unmountOnExit: true }, { children: !isLoading && renderDetailPanel({ row, table }) }))) })) })));
2548
2344
  };
2549
2345
 
2550
2346
  const MRT_TableBodyRow = ({ columnVirtualizer, measureElement, numRows, row, rowIndex, table, virtualColumns, virtualPaddingLeft, virtualPaddingRight, virtualRow, }) => {
@@ -2558,54 +2354,49 @@ const MRT_TableBodyRow = ({ columnVirtualizer, measureElement, numRows, row, row
2558
2354
  setHoveredRow(row);
2559
2355
  }
2560
2356
  };
2561
- const rowRef = React.useRef(null);
2562
- return (React__default["default"].createElement(React__default["default"].Fragment, null,
2563
- React__default["default"].createElement(TableRow__default["default"], Object.assign({ "data-index": virtualRow === null || virtualRow === void 0 ? void 0 : virtualRow.index, onDragEnter: handleDragEnter, selected: row.getIsSelected(), ref: (node) => {
2564
- if (node) {
2565
- rowRef.current = node;
2566
- measureElement === null || measureElement === void 0 ? void 0 : measureElement(node);
2567
- }
2568
- } }, tableRowProps, { sx: (theme) => (Object.assign({ backgroundColor: styles.lighten(theme.palette.background.default, 0.06), boxSizing: 'border-box', display: layoutMode === 'grid' ? 'flex' : 'table-row', opacity: (draggingRow === null || draggingRow === void 0 ? void 0 : draggingRow.id) === row.id || (hoveredRow === null || hoveredRow === void 0 ? void 0 : hoveredRow.id) === row.id ? 0.5 : 1, position: virtualRow ? 'absolute' : undefined, transition: virtualRow ? 'none' : 'all 150ms ease-in-out', top: virtualRow ? 0 : undefined, width: '100%', '&:hover td': {
2569
- backgroundColor: (tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.hover) !== false
2570
- ? row.getIsSelected()
2571
- ? `${styles.alpha(theme.palette.primary.main, 0.2)}`
2572
- : theme.palette.mode === 'dark'
2573
- ? `${styles.lighten(theme.palette.background.default, 0.12)}`
2574
- : `${styles.darken(theme.palette.background.default, 0.05)}`
2575
- : undefined,
2576
- } }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
2577
- ? tableRowProps.sx(theme)
2578
- : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx))), style: Object.assign({ transform: virtualRow
2579
- ? `translateY(${virtualRow === null || virtualRow === void 0 ? void 0 : virtualRow.start}px)`
2580
- : undefined }, tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.style) }),
2581
- virtualPaddingLeft ? (React__default["default"].createElement("td", { style: { display: 'flex', width: virtualPaddingLeft } })) : null,
2582
- (virtualColumns !== null && virtualColumns !== void 0 ? virtualColumns : row.getVisibleCells()).map((cellOrVirtualCell) => {
2583
- const cell = columnVirtualizer
2584
- ? row.getVisibleCells()[cellOrVirtualCell.index]
2585
- : cellOrVirtualCell;
2586
- const props = {
2587
- cell,
2588
- key: cell.id,
2589
- measureElement: columnVirtualizer === null || columnVirtualizer === void 0 ? void 0 : columnVirtualizer.measureElement,
2590
- numRows,
2591
- rowIndex,
2592
- rowRef,
2593
- table,
2594
- virtualCell: columnVirtualizer
2595
- ? cellOrVirtualCell
2596
- : undefined,
2597
- };
2598
- return memoMode === 'cells' &&
2599
- cell.column.columnDef.columnDefType === 'data' &&
2600
- !draggingColumn &&
2601
- !draggingRow &&
2602
- (editingCell === null || editingCell === void 0 ? void 0 : editingCell.id) !== cell.id &&
2603
- (editingRow === null || editingRow === void 0 ? void 0 : editingRow.id) !== row.id ? (React__default["default"].createElement(Memo_MRT_TableBodyCell, Object.assign({}, props))) : (React__default["default"].createElement(MRT_TableBodyCell, Object.assign({}, props)));
2604
- }),
2605
- virtualPaddingRight ? (React__default["default"].createElement("td", { style: { display: 'flex', width: virtualPaddingRight } })) : null),
2606
- renderDetailPanel && !row.getIsGrouped() && (React__default["default"].createElement(MRT_TableDetailPanel, { parentRowRef: rowRef, row: row, rowIndex: rowIndex, table: table, virtualRow: virtualRow }))));
2607
- };
2608
- const Memo_MRT_TableBodyRow = React.memo(MRT_TableBodyRow, (prev, next) => prev.row === next.row && prev.rowIndex === next.rowIndex);
2357
+ const rowRef = react.useRef(null);
2358
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsxs(TableRow__default["default"], Object.assign({ "data-index": virtualRow === null || virtualRow === void 0 ? void 0 : virtualRow.index, onDragEnter: handleDragEnter, selected: row.getIsSelected(), ref: (node) => {
2359
+ if (node) {
2360
+ rowRef.current = node;
2361
+ measureElement === null || measureElement === void 0 ? void 0 : measureElement(node);
2362
+ }
2363
+ } }, tableRowProps, { sx: (theme) => (Object.assign({ backgroundColor: styles.lighten(theme.palette.background.default, 0.06), boxSizing: 'border-box', display: layoutMode === 'grid' ? 'flex' : 'table-row', opacity: (draggingRow === null || draggingRow === void 0 ? void 0 : draggingRow.id) === row.id || (hoveredRow === null || hoveredRow === void 0 ? void 0 : hoveredRow.id) === row.id ? 0.5 : 1, position: virtualRow ? 'absolute' : undefined, transition: virtualRow ? 'none' : 'all 150ms ease-in-out', top: virtualRow ? 0 : undefined, width: '100%', '&:hover td': {
2364
+ backgroundColor: (tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.hover) !== false
2365
+ ? row.getIsSelected()
2366
+ ? `${styles.alpha(theme.palette.primary.main, 0.2)}`
2367
+ : theme.palette.mode === 'dark'
2368
+ ? `${styles.lighten(theme.palette.background.default, 0.12)}`
2369
+ : `${styles.darken(theme.palette.background.default, 0.05)}`
2370
+ : undefined,
2371
+ } }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
2372
+ ? tableRowProps.sx(theme)
2373
+ : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx))), style: Object.assign({ transform: virtualRow
2374
+ ? `translateY(${virtualRow === null || virtualRow === void 0 ? void 0 : virtualRow.start}px)`
2375
+ : undefined }, tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.style) }, { children: [virtualPaddingLeft ? (jsxRuntime.jsx("td", { style: { display: 'flex', width: virtualPaddingLeft } })) : null, (virtualColumns !== null && virtualColumns !== void 0 ? virtualColumns : row.getVisibleCells()).map((cellOrVirtualCell) => {
2376
+ const cell = columnVirtualizer
2377
+ ? row.getVisibleCells()[cellOrVirtualCell.index]
2378
+ : cellOrVirtualCell;
2379
+ const props = {
2380
+ cell,
2381
+ key: cell.id,
2382
+ measureElement: columnVirtualizer === null || columnVirtualizer === void 0 ? void 0 : columnVirtualizer.measureElement,
2383
+ numRows,
2384
+ rowIndex,
2385
+ rowRef,
2386
+ table,
2387
+ virtualCell: columnVirtualizer
2388
+ ? cellOrVirtualCell
2389
+ : undefined,
2390
+ };
2391
+ return memoMode === 'cells' &&
2392
+ cell.column.columnDef.columnDefType === 'data' &&
2393
+ !draggingColumn &&
2394
+ !draggingRow &&
2395
+ (editingCell === null || editingCell === void 0 ? void 0 : editingCell.id) !== cell.id &&
2396
+ (editingRow === null || editingRow === void 0 ? void 0 : editingRow.id) !== row.id ? (jsxRuntime.jsx(Memo_MRT_TableBodyCell, Object.assign({}, props))) : (jsxRuntime.jsx(MRT_TableBodyCell, Object.assign({}, props)));
2397
+ }), virtualPaddingRight ? (jsxRuntime.jsx("td", { style: { display: 'flex', width: virtualPaddingRight } })) : null] })), renderDetailPanel && !row.getIsGrouped() && (jsxRuntime.jsx(MRT_TableDetailPanel, { parentRowRef: rowRef, row: row, rowIndex: rowIndex, table: table, virtualRow: virtualRow }))] }));
2398
+ };
2399
+ const Memo_MRT_TableBodyRow = react.memo(MRT_TableBodyRow, (prev, next) => prev.row === next.row && prev.rowIndex === next.rowIndex);
2609
2400
 
2610
2401
  const MRT_TableBody = ({ columnVirtualizer, table, virtualColumns, virtualPaddingLeft, virtualPaddingRight, }) => {
2611
2402
  var _a, _b, _c, _d;
@@ -2620,7 +2411,7 @@ const MRT_TableBody = ({ columnVirtualizer, table, virtualColumns, virtualPaddin
2620
2411
  const vProps = rowVirtualizerProps instanceof Function
2621
2412
  ? rowVirtualizerProps({ table })
2622
2413
  : rowVirtualizerProps;
2623
- const shouldRankResults = React.useMemo(() => !manualExpanding &&
2414
+ const shouldRankResults = react.useMemo(() => !manualExpanding &&
2624
2415
  !manualFiltering &&
2625
2416
  !manualGrouping &&
2626
2417
  !manualSorting &&
@@ -2639,7 +2430,7 @@ const MRT_TableBody = ({ columnVirtualizer, table, virtualColumns, virtualPaddin
2639
2430
  manualSorting,
2640
2431
  sorting,
2641
2432
  ]);
2642
- const rows = React.useMemo(() => {
2433
+ const rows = react.useMemo(() => {
2643
2434
  if (!shouldRankResults)
2644
2435
  return getRowModel().rows;
2645
2436
  const rankedRows = getPrePaginationRowModel().rows.sort((a, b) => rankGlobalFuzzy(a, b));
@@ -2655,7 +2446,10 @@ const MRT_TableBody = ({ columnVirtualizer, table, virtualColumns, virtualPaddin
2655
2446
  pagination.pageSize,
2656
2447
  ]);
2657
2448
  const rowVirtualizer = enableRowVirtualization
2658
- ? reactVirtual.useVirtualizer(Object.assign(Object.assign({ count: rows.length, estimateSize: () => density === 'compact' ? 37 : density === 'comfortable' ? 58 : 73, getScrollElement: () => tableContainerRef.current, overscan: 4 }, vProps_old), vProps))
2449
+ ? reactVirtual.useVirtualizer(Object.assign(Object.assign({ count: rows.length, estimateSize: () => density === 'compact' ? 37 : density === 'comfortable' ? 58 : 73, getScrollElement: () => tableContainerRef.current, measureElement: typeof window !== 'undefined' &&
2450
+ navigator.userAgent.indexOf('Firefox') === -1
2451
+ ? (element) => element === null || element === void 0 ? void 0 : element.getBoundingClientRect().height
2452
+ : undefined, overscan: 4 }, vProps_old), vProps))
2659
2453
  : undefined;
2660
2454
  if (rowVirtualizerInstanceRef && rowVirtualizer) {
2661
2455
  rowVirtualizerInstanceRef.current = rowVirtualizer;
@@ -2667,45 +2461,44 @@ const MRT_TableBody = ({ columnVirtualizer, table, virtualColumns, virtualPaddin
2667
2461
  const virtualRows = rowVirtualizer
2668
2462
  ? rowVirtualizer.getVirtualItems()
2669
2463
  : undefined;
2670
- return (React__default["default"].createElement(TableBody__default["default"], Object.assign({}, tableBodyProps, { sx: (theme) => (Object.assign({ display: layoutMode === 'grid' ? 'grid' : 'table-row-group', height: rowVirtualizer
2464
+ return (jsxRuntime.jsx(TableBody__default["default"], Object.assign({}, tableBodyProps, { sx: (theme) => (Object.assign({ display: layoutMode === 'grid' ? 'grid' : 'table-row-group', height: rowVirtualizer
2671
2465
  ? `${rowVirtualizer.getTotalSize()}px`
2672
2466
  : 'inherit', minHeight: !rows.length ? '100px' : undefined, position: 'relative' }, ((tableBodyProps === null || tableBodyProps === void 0 ? void 0 : tableBodyProps.sx) instanceof Function
2673
2467
  ? tableBodyProps === null || tableBodyProps === void 0 ? void 0 : tableBodyProps.sx(theme)
2674
- : tableBodyProps === null || tableBodyProps === void 0 ? void 0 : tableBodyProps.sx))) }), (_a = tableBodyProps === null || tableBodyProps === void 0 ? void 0 : tableBodyProps.children) !== null && _a !== void 0 ? _a : (!rows.length ? (React__default["default"].createElement("tr", { style: { display: layoutMode === 'grid' ? 'grid' : 'table-row' } },
2675
- React__default["default"].createElement("td", { colSpan: table.getVisibleLeafColumns().length, style: {
2676
- display: layoutMode === 'grid' ? 'grid' : 'table-cell',
2677
- } }, (_b = renderEmptyRowsFallback === null || renderEmptyRowsFallback === void 0 ? void 0 : renderEmptyRowsFallback({ table })) !== null && _b !== void 0 ? _b : (React__default["default"].createElement(Typography__default["default"], { sx: {
2678
- color: 'text.secondary',
2679
- fontStyle: 'italic',
2680
- maxWidth: `min(100vw, ${(_d = (_c = tablePaperRef.current) === null || _c === void 0 ? void 0 : _c.clientWidth) !== null && _d !== void 0 ? _d : 360}px)`,
2681
- py: '2rem',
2682
- textAlign: 'center',
2683
- width: '100%',
2684
- } }, globalFilter || columnFilters.length
2685
- ? localization.noResultsFound
2686
- : localization.noRecordsToDisplay))))) : (React__default["default"].createElement(React__default["default"].Fragment, null, (virtualRows !== null && virtualRows !== void 0 ? virtualRows : rows).map((rowOrVirtualRow, rowIndex) => {
2687
- const row = rowVirtualizer
2688
- ? rows[rowOrVirtualRow.index]
2689
- : rowOrVirtualRow;
2690
- const props = {
2691
- columnVirtualizer,
2692
- key: row.id,
2693
- measureElement: rowVirtualizer === null || rowVirtualizer === void 0 ? void 0 : rowVirtualizer.measureElement,
2694
- numRows: rows.length,
2695
- row,
2696
- rowIndex: rowVirtualizer ? rowOrVirtualRow.index : rowIndex,
2697
- table,
2698
- virtualColumns,
2699
- virtualPaddingLeft,
2700
- virtualPaddingRight,
2701
- virtualRow: rowVirtualizer
2702
- ? rowOrVirtualRow
2703
- : undefined,
2704
- };
2705
- return memoMode === 'rows' ? (React__default["default"].createElement(Memo_MRT_TableBodyRow, Object.assign({}, props))) : (React__default["default"].createElement(MRT_TableBodyRow, Object.assign({}, props)));
2706
- }))))));
2468
+ : tableBodyProps === null || tableBodyProps === void 0 ? void 0 : tableBodyProps.sx))) }, { children: (_a = tableBodyProps === null || tableBodyProps === void 0 ? void 0 : tableBodyProps.children) !== null && _a !== void 0 ? _a : (!rows.length ? (jsxRuntime.jsx("tr", Object.assign({ style: { display: layoutMode === 'grid' ? 'grid' : 'table-row' } }, { children: jsxRuntime.jsx("td", Object.assign({ colSpan: table.getVisibleLeafColumns().length, style: {
2469
+ display: layoutMode === 'grid' ? 'grid' : 'table-cell',
2470
+ } }, { children: (_b = renderEmptyRowsFallback === null || renderEmptyRowsFallback === void 0 ? void 0 : renderEmptyRowsFallback({ table })) !== null && _b !== void 0 ? _b : (jsxRuntime.jsx(Typography__default["default"], Object.assign({ sx: {
2471
+ color: 'text.secondary',
2472
+ fontStyle: 'italic',
2473
+ maxWidth: `min(100vw, ${(_d = (_c = tablePaperRef.current) === null || _c === void 0 ? void 0 : _c.clientWidth) !== null && _d !== void 0 ? _d : 360}px)`,
2474
+ py: '2rem',
2475
+ textAlign: 'center',
2476
+ width: '100%',
2477
+ } }, { children: globalFilter || columnFilters.length
2478
+ ? localization.noResultsFound
2479
+ : localization.noRecordsToDisplay }))) })) }))) : (jsxRuntime.jsx(jsxRuntime.Fragment, { children: (virtualRows !== null && virtualRows !== void 0 ? virtualRows : rows).map((rowOrVirtualRow, rowIndex) => {
2480
+ const row = rowVirtualizer
2481
+ ? rows[rowOrVirtualRow.index]
2482
+ : rowOrVirtualRow;
2483
+ const props = {
2484
+ columnVirtualizer,
2485
+ key: row.id,
2486
+ measureElement: rowVirtualizer === null || rowVirtualizer === void 0 ? void 0 : rowVirtualizer.measureElement,
2487
+ numRows: rows.length,
2488
+ row,
2489
+ rowIndex: rowVirtualizer ? rowOrVirtualRow.index : rowIndex,
2490
+ table,
2491
+ virtualColumns,
2492
+ virtualPaddingLeft,
2493
+ virtualPaddingRight,
2494
+ virtualRow: rowVirtualizer
2495
+ ? rowOrVirtualRow
2496
+ : undefined,
2497
+ };
2498
+ return memoMode === 'rows' ? (jsxRuntime.jsx(Memo_MRT_TableBodyRow, Object.assign({}, props))) : (jsxRuntime.jsx(MRT_TableBodyRow, Object.assign({}, props)));
2499
+ }) }))) })));
2707
2500
  };
2708
- const Memo_MRT_TableBody = React.memo(MRT_TableBody, (prev, next) => prev.table.options.data === next.table.options.data);
2501
+ const Memo_MRT_TableBody = react.memo(MRT_TableBody, (prev, next) => prev.table.options.data === next.table.options.data);
2709
2502
 
2710
2503
  const MRT_TableFooterCell = ({ footer, table }) => {
2711
2504
  var _a, _b, _c;
@@ -2721,7 +2514,7 @@ const MRT_TableFooterCell = ({ footer, table }) => {
2721
2514
  ? columnDef.muiTableFooterCellProps({ column, table })
2722
2515
  : columnDef.muiTableFooterCellProps;
2723
2516
  const tableCellProps = Object.assign(Object.assign({}, mTableFooterCellProps), mcTableFooterCellProps);
2724
- return (React__default["default"].createElement(TableCell__default["default"], Object.assign({ align: columnDefType === 'group' ? 'center' : 'left', colSpan: footer.colSpan, variant: "head" }, tableCellProps, { sx: (theme) => (Object.assign({ display: layoutMode === 'grid' ? 'grid' : 'table-cell', fontWeight: 'bold', justifyContent: columnDefType === 'group' ? 'center' : undefined, p: density === 'compact'
2517
+ return (jsxRuntime.jsx(TableCell__default["default"], Object.assign({ align: columnDefType === 'group' ? 'center' : 'left', colSpan: footer.colSpan, variant: "head" }, tableCellProps, { sx: (theme) => (Object.assign({ display: layoutMode === 'grid' ? 'grid' : 'table-cell', fontWeight: 'bold', justifyContent: columnDefType === 'group' ? 'center' : undefined, p: density === 'compact'
2725
2518
  ? '0.5rem'
2726
2519
  : density === 'comfortable'
2727
2520
  ? '1rem'
@@ -2730,16 +2523,15 @@ const MRT_TableFooterCell = ({ footer, table }) => {
2730
2523
  table,
2731
2524
  theme,
2732
2525
  tableCellProps,
2733
- }))) }),
2734
- React__default["default"].createElement(React__default["default"].Fragment, null, footer.isPlaceholder
2735
- ? null
2736
- : (_c = (_b = (columnDef.Footer instanceof Function
2737
- ? (_a = columnDef.Footer) === null || _a === void 0 ? void 0 : _a.call(columnDef, {
2738
- column,
2739
- footer,
2740
- table,
2741
- })
2742
- : columnDef.Footer)) !== null && _b !== void 0 ? _b : columnDef.footer) !== null && _c !== void 0 ? _c : null)));
2526
+ }))) }, { children: jsxRuntime.jsx(jsxRuntime.Fragment, { children: footer.isPlaceholder
2527
+ ? null
2528
+ : (_c = (_b = (columnDef.Footer instanceof Function
2529
+ ? (_a = columnDef.Footer) === null || _a === void 0 ? void 0 : _a.call(columnDef, {
2530
+ column,
2531
+ footer,
2532
+ table,
2533
+ })
2534
+ : columnDef.Footer)) !== null && _b !== void 0 ? _b : columnDef.footer) !== null && _c !== void 0 ? _c : null }) })));
2743
2535
  };
2744
2536
 
2745
2537
  const MRT_TableFooterRow = ({ footerGroup, table, virtualColumns, virtualPaddingLeft, virtualPaddingRight, }) => {
@@ -2753,17 +2545,14 @@ const MRT_TableFooterRow = ({ footerGroup, table, virtualColumns, virtualPadding
2753
2545
  const tableRowProps = muiTableFooterRowProps instanceof Function
2754
2546
  ? muiTableFooterRowProps({ footerGroup, table })
2755
2547
  : muiTableFooterRowProps;
2756
- return (React__default["default"].createElement(TableRow__default["default"], Object.assign({}, tableRowProps, { sx: (theme) => (Object.assign({ backgroundColor: styles.lighten(theme.palette.background.default, 0.04), display: layoutMode === 'grid' ? 'flex' : 'table-row', width: '100%' }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
2548
+ return (jsxRuntime.jsxs(TableRow__default["default"], Object.assign({}, tableRowProps, { sx: (theme) => (Object.assign({ backgroundColor: styles.lighten(theme.palette.background.default, 0.04), display: layoutMode === 'grid' ? 'flex' : 'table-row', width: '100%' }, ((tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx) instanceof Function
2757
2549
  ? tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx(theme)
2758
- : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx))) }),
2759
- virtualPaddingLeft ? (React__default["default"].createElement("th", { style: { display: 'flex', width: virtualPaddingLeft } })) : null,
2760
- (virtualColumns !== null && virtualColumns !== void 0 ? virtualColumns : footerGroup.headers).map((footerOrVirtualFooter) => {
2761
- const footer = virtualColumns
2762
- ? footerGroup.headers[footerOrVirtualFooter.index]
2763
- : footerOrVirtualFooter;
2764
- return (React__default["default"].createElement(MRT_TableFooterCell, { footer: footer, key: footer.id, table: table }));
2765
- }),
2766
- virtualPaddingRight ? (React__default["default"].createElement("th", { style: { display: 'flex', width: virtualPaddingRight } })) : null));
2550
+ : tableRowProps === null || tableRowProps === void 0 ? void 0 : tableRowProps.sx))) }, { children: [virtualPaddingLeft ? (jsxRuntime.jsx("th", { style: { display: 'flex', width: virtualPaddingLeft } })) : null, (virtualColumns !== null && virtualColumns !== void 0 ? virtualColumns : footerGroup.headers).map((footerOrVirtualFooter) => {
2551
+ const footer = virtualColumns
2552
+ ? footerGroup.headers[footerOrVirtualFooter.index]
2553
+ : footerOrVirtualFooter;
2554
+ return (jsxRuntime.jsx(MRT_TableFooterCell, { footer: footer, table: table }, footer.id));
2555
+ }), virtualPaddingRight ? (jsxRuntime.jsx("th", { style: { display: 'flex', width: virtualPaddingRight } })) : null] })));
2767
2556
  };
2768
2557
 
2769
2558
  const MRT_TableFooter = ({ table, virtualColumns, virtualPaddingLeft, virtualPaddingRight, }) => {
@@ -2773,13 +2562,13 @@ const MRT_TableFooter = ({ table, virtualColumns, virtualPaddingLeft, virtualPad
2773
2562
  ? muiTableFooterProps({ table })
2774
2563
  : muiTableFooterProps;
2775
2564
  const stickFooter = (isFullScreen || enableStickyFooter) && enableStickyFooter !== false;
2776
- return (React__default["default"].createElement(TableFooter__default["default"], Object.assign({}, tableFooterProps, { sx: (theme) => (Object.assign({ bottom: stickFooter ? 0 : undefined, display: layoutMode === 'grid' ? 'grid' : 'table-row-group', opacity: stickFooter ? 0.97 : undefined, outline: stickFooter
2565
+ return (jsxRuntime.jsx(TableFooter__default["default"], Object.assign({}, tableFooterProps, { sx: (theme) => (Object.assign({ bottom: stickFooter ? 0 : undefined, display: layoutMode === 'grid' ? 'grid' : 'table-row-group', opacity: stickFooter ? 0.97 : undefined, outline: stickFooter
2777
2566
  ? theme.palette.mode === 'light'
2778
2567
  ? `1px solid ${theme.palette.grey[300]}`
2779
2568
  : `1px solid ${theme.palette.grey[700]}`
2780
2569
  : undefined, position: stickFooter ? 'sticky' : undefined, zIndex: stickFooter ? 1 : undefined }, ((tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx) instanceof Function
2781
2570
  ? tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx(theme)
2782
- : tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx))) }), getFooterGroups().map((footerGroup) => (React__default["default"].createElement(MRT_TableFooterRow, { footerGroup: footerGroup, key: footerGroup.id, table: table, virtualColumns: virtualColumns, virtualPaddingLeft: virtualPaddingLeft, virtualPaddingRight: virtualPaddingRight })))));
2571
+ : tableFooterProps === null || tableFooterProps === void 0 ? void 0 : tableFooterProps.sx))) }, { children: getFooterGroups().map((footerGroup) => (jsxRuntime.jsx(MRT_TableFooterRow, { footerGroup: footerGroup, table: table, virtualColumns: virtualColumns, virtualPaddingLeft: virtualPaddingLeft, virtualPaddingRight: virtualPaddingRight }, footerGroup.id))) })));
2783
2572
  };
2784
2573
 
2785
2574
  const MRT_Table = ({ table }) => {
@@ -2792,7 +2581,7 @@ const MRT_Table = ({ table }) => {
2792
2581
  const vProps = columnVirtualizerProps instanceof Function
2793
2582
  ? columnVirtualizerProps({ table })
2794
2583
  : columnVirtualizerProps;
2795
- const columnSizeVars = React.useMemo(() => {
2584
+ const columnSizeVars = react.useMemo(() => {
2796
2585
  const headers = getFlatHeaders();
2797
2586
  const colSizes = {};
2798
2587
  for (let i = 0; i < headers.length; i++) {
@@ -2804,7 +2593,7 @@ const MRT_Table = ({ table }) => {
2804
2593
  return colSizes;
2805
2594
  }, [columns, columnSizing, columnSizingInfo, columnVisibility]);
2806
2595
  //get first 16 column widths and average them
2807
- const averageColumnWidth = React.useMemo(() => {
2596
+ const averageColumnWidth = react.useMemo(() => {
2808
2597
  var _a, _b, _c, _d;
2809
2598
  if (!enableColumnVirtualization)
2810
2599
  return 0;
@@ -2813,7 +2602,7 @@ const MRT_Table = ({ table }) => {
2813
2602
  .rows[0]) === null || _a === void 0 ? void 0 : _a.getCenterVisibleCells()) === null || _b === void 0 ? void 0 : _b.slice(0, 16)) === null || _c === void 0 ? void 0 : _c.map((cell) => cell.column.getSize() * 1.2)) !== null && _d !== void 0 ? _d : [];
2814
2603
  return columnsWidths.reduce((a, b) => a + b, 0) / columnsWidths.length;
2815
2604
  }, [table.getRowModel().rows, columnPinning, columnVisibility]);
2816
- const [leftPinnedIndexes, rightPinnedIndexes] = React.useMemo(() => enableColumnVirtualization && enablePinning
2605
+ const [leftPinnedIndexes, rightPinnedIndexes] = react.useMemo(() => enableColumnVirtualization && enablePinning
2817
2606
  ? [
2818
2607
  table.getLeftLeafColumns().map((c) => c.getPinnedIndex()),
2819
2608
  table
@@ -2822,7 +2611,7 @@ const MRT_Table = ({ table }) => {
2822
2611
  ]
2823
2612
  : [[], []], [columnPinning, enableColumnVirtualization, enablePinning]);
2824
2613
  const columnVirtualizer = enableColumnVirtualization
2825
- ? reactVirtual.useVirtualizer(Object.assign({ count: table.getVisibleLeafColumns().length, estimateSize: () => averageColumnWidth, getScrollElement: () => tableContainerRef.current, horizontal: true, overscan: 3, rangeExtractor: React.useCallback((range) => [
2614
+ ? reactVirtual.useVirtualizer(Object.assign({ count: table.getVisibleLeafColumns().length, estimateSize: () => averageColumnWidth, getScrollElement: () => tableContainerRef.current, horizontal: true, overscan: 3, rangeExtractor: react.useCallback((range) => [
2826
2615
  ...new Set([
2827
2616
  ...leftPinnedIndexes,
2828
2617
  ...reactVirtual.defaultRangeExtractor(range),
@@ -2850,19 +2639,16 @@ const MRT_Table = ({ table }) => {
2850
2639
  virtualPaddingLeft,
2851
2640
  virtualPaddingRight,
2852
2641
  };
2853
- return (React__default["default"].createElement(Table__default["default"], Object.assign({ stickyHeader: enableStickyHeader || isFullScreen }, tableProps, { sx: (theme) => (Object.assign({ borderCollapse: 'separate', display: layoutMode === 'grid' ? 'grid' : 'table', tableLayout: layoutMode !== 'grid' && enableColumnResizing ? 'fixed' : undefined }, ((tableProps === null || tableProps === void 0 ? void 0 : tableProps.sx) instanceof Function
2642
+ return (jsxRuntime.jsxs(Table__default["default"], Object.assign({ stickyHeader: enableStickyHeader || isFullScreen }, tableProps, { sx: (theme) => (Object.assign({ borderCollapse: 'separate', display: layoutMode === 'grid' ? 'grid' : 'table', tableLayout: layoutMode !== 'grid' && enableColumnResizing ? 'fixed' : undefined }, ((tableProps === null || tableProps === void 0 ? void 0 : tableProps.sx) instanceof Function
2854
2643
  ? tableProps.sx(theme)
2855
- : tableProps === null || tableProps === void 0 ? void 0 : tableProps.sx))), style: Object.assign(Object.assign({}, columnSizeVars), tableProps === null || tableProps === void 0 ? void 0 : tableProps.style) }),
2856
- enableTableHead && React__default["default"].createElement(MRT_TableHead, Object.assign({}, props)),
2857
- memoMode === 'table-body' || columnSizingInfo.isResizingColumn ? (React__default["default"].createElement(Memo_MRT_TableBody, Object.assign({ columnVirtualizer: columnVirtualizer }, props))) : (React__default["default"].createElement(MRT_TableBody, Object.assign({ columnVirtualizer: columnVirtualizer }, props))),
2858
- enableTableFooter && React__default["default"].createElement(MRT_TableFooter, Object.assign({}, props))));
2644
+ : tableProps === null || tableProps === void 0 ? void 0 : tableProps.sx))), style: Object.assign(Object.assign({}, columnSizeVars), tableProps === null || tableProps === void 0 ? void 0 : tableProps.style) }, { children: [enableTableHead && jsxRuntime.jsx(MRT_TableHead, Object.assign({}, props)), memoMode === 'table-body' || columnSizingInfo.isResizingColumn ? (jsxRuntime.jsx(Memo_MRT_TableBody, Object.assign({ columnVirtualizer: columnVirtualizer }, props))) : (jsxRuntime.jsx(MRT_TableBody, Object.assign({ columnVirtualizer: columnVirtualizer }, props))), enableTableFooter && jsxRuntime.jsx(MRT_TableFooter, Object.assign({}, props))] })));
2859
2645
  };
2860
2646
 
2861
- const useIsomorphicLayoutEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;
2647
+ const useIsomorphicLayoutEffect = typeof window !== 'undefined' ? react.useLayoutEffect : react.useEffect;
2862
2648
  const MRT_TableContainer = ({ table }) => {
2863
2649
  const { getState, options: { enableStickyHeader, muiTableContainerProps }, refs: { tableContainerRef, bottomToolbarRef, topToolbarRef }, } = table;
2864
2650
  const { isFullScreen } = getState();
2865
- const [totalToolbarHeight, setTotalToolbarHeight] = React.useState(0);
2651
+ const [totalToolbarHeight, setTotalToolbarHeight] = react.useState(0);
2866
2652
  const tableContainerProps = muiTableContainerProps instanceof Function
2867
2653
  ? muiTableContainerProps({ table })
2868
2654
  : muiTableContainerProps;
@@ -2876,7 +2662,7 @@ const MRT_TableContainer = ({ table }) => {
2876
2662
  : 0;
2877
2663
  setTotalToolbarHeight(topToolbarHeight + bottomToolbarHeight);
2878
2664
  });
2879
- return (React__default["default"].createElement(TableContainer__default["default"], Object.assign({}, tableContainerProps, { ref: (node) => {
2665
+ return (jsxRuntime.jsx(TableContainer__default["default"], Object.assign({}, tableContainerProps, { ref: (node) => {
2880
2666
  if (node) {
2881
2667
  tableContainerRef.current = node;
2882
2668
  if (tableContainerProps === null || tableContainerProps === void 0 ? void 0 : tableContainerProps.ref) {
@@ -2890,8 +2676,7 @@ const MRT_TableContainer = ({ table }) => {
2890
2676
  ? tableContainerProps.sx(theme)
2891
2677
  : tableContainerProps === null || tableContainerProps === void 0 ? void 0 : tableContainerProps.sx))), style: Object.assign({ maxHeight: isFullScreen
2892
2678
  ? `calc(100vh - ${totalToolbarHeight}px)`
2893
- : undefined }, tableContainerProps === null || tableContainerProps === void 0 ? void 0 : tableContainerProps.style) }),
2894
- React__default["default"].createElement(MRT_Table, { table: table })));
2679
+ : undefined }, tableContainerProps === null || tableContainerProps === void 0 ? void 0 : tableContainerProps.style) }, { children: jsxRuntime.jsx(MRT_Table, { table: table }) })));
2895
2680
  };
2896
2681
 
2897
2682
  const MRT_TablePaper = ({ table }) => {
@@ -2900,7 +2685,7 @@ const MRT_TablePaper = ({ table }) => {
2900
2685
  const tablePaperProps = muiTablePaperProps instanceof Function
2901
2686
  ? muiTablePaperProps({ table })
2902
2687
  : muiTablePaperProps;
2903
- return (React__default["default"].createElement(Paper__default["default"], Object.assign({ elevation: 2 }, tablePaperProps, { ref: (ref) => {
2688
+ return (jsxRuntime.jsxs(Paper__default["default"], Object.assign({ elevation: 2 }, tablePaperProps, { ref: (ref) => {
2904
2689
  tablePaperRef.current = ref;
2905
2690
  if (tablePaperProps === null || tablePaperProps === void 0 ? void 0 : tablePaperProps.ref) {
2906
2691
  //@ts-ignore
@@ -2917,48 +2702,39 @@ const MRT_TablePaper = ({ table }) => {
2917
2702
  padding: 0,
2918
2703
  width: '100vw',
2919
2704
  }
2920
- : {})) }),
2921
- enableTopToolbar &&
2922
- (renderTopToolbar instanceof Function
2923
- ? renderTopToolbar({ table })
2924
- : renderTopToolbar !== null && renderTopToolbar !== void 0 ? renderTopToolbar : React__default["default"].createElement(MRT_TopToolbar, { table: table })),
2925
- React__default["default"].createElement(MRT_TableContainer, { table: table }),
2926
- enableBottomToolbar &&
2927
- (renderBottomToolbar instanceof Function
2928
- ? renderBottomToolbar({ table })
2929
- : renderBottomToolbar !== null && renderBottomToolbar !== void 0 ? renderBottomToolbar : React__default["default"].createElement(MRT_BottomToolbar, { table: table }))));
2705
+ : {})) }, { children: [enableTopToolbar &&
2706
+ (renderTopToolbar instanceof Function
2707
+ ? renderTopToolbar({ table })
2708
+ : renderTopToolbar !== null && renderTopToolbar !== void 0 ? renderTopToolbar : jsxRuntime.jsx(MRT_TopToolbar, { table: table })), jsxRuntime.jsx(MRT_TableContainer, { table: table }), enableBottomToolbar &&
2709
+ (renderBottomToolbar instanceof Function
2710
+ ? renderBottomToolbar({ table })
2711
+ : renderBottomToolbar !== null && renderBottomToolbar !== void 0 ? renderBottomToolbar : jsxRuntime.jsx(MRT_BottomToolbar, { table: table }))] })));
2930
2712
  };
2931
2713
 
2932
2714
  const MRT_EditRowModal = ({ open, row, table, }) => {
2933
2715
  const { options: { localization }, } = table;
2934
- return (React__default["default"].createElement(Dialog__default["default"], { open: open },
2935
- React__default["default"].createElement(DialogTitle__default["default"], { textAlign: "center" }, localization.edit),
2936
- React__default["default"].createElement(DialogContent__default["default"], null,
2937
- React__default["default"].createElement("form", { onSubmit: (e) => e.preventDefault() },
2938
- React__default["default"].createElement(Stack__default["default"], { sx: {
2939
- gap: '1.5rem',
2940
- minWidth: { xs: '300px', sm: '360px', md: '400px' },
2941
- pt: '1rem',
2942
- width: '100%',
2943
- } }, row
2944
- .getAllCells()
2945
- .filter((cell) => cell.column.columnDef.columnDefType === 'data')
2946
- .map((cell) => (React__default["default"].createElement(MRT_EditCellTextField, { cell: cell, key: cell.id, showLabel: true, table: table })))))),
2947
- React__default["default"].createElement(DialogActions__default["default"], { sx: { p: '1.25rem' } },
2948
- React__default["default"].createElement(MRT_EditActionButtons, { row: row, table: table, variant: "text" }))));
2716
+ return (jsxRuntime.jsxs(Dialog__default["default"], Object.assign({ open: open }, { children: [jsxRuntime.jsx(DialogTitle__default["default"], Object.assign({ textAlign: "center" }, { children: localization.edit })), jsxRuntime.jsx(DialogContent__default["default"], { children: jsxRuntime.jsx("form", Object.assign({ onSubmit: (e) => e.preventDefault() }, { children: jsxRuntime.jsx(Stack__default["default"], Object.assign({ sx: {
2717
+ gap: '1.5rem',
2718
+ minWidth: { xs: '300px', sm: '360px', md: '400px' },
2719
+ pt: '1rem',
2720
+ width: '100%',
2721
+ } }, { children: row
2722
+ .getAllCells()
2723
+ .filter((cell) => cell.column.columnDef.columnDefType === 'data')
2724
+ .map((cell) => (jsxRuntime.jsx(MRT_EditCellTextField, { cell: cell, showLabel: true, table: table }, cell.id))) })) })) }), jsxRuntime.jsx(DialogActions__default["default"], Object.assign({ sx: { p: '1.25rem' } }, { children: jsxRuntime.jsx(MRT_EditActionButtons, { row: row, table: table, variant: "text" }) }))] })));
2949
2725
  };
2950
2726
 
2951
2727
  const MRT_TableRoot = (props) => {
2952
2728
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13;
2953
- const bottomToolbarRef = React.useRef(null);
2954
- const editInputRefs = React.useRef({});
2955
- const filterInputRefs = React.useRef({});
2956
- const searchInputRef = React.useRef(null);
2957
- const tableContainerRef = React.useRef(null);
2958
- const tableHeadCellRefs = React.useRef({});
2959
- const tablePaperRef = React.useRef(null);
2960
- const topToolbarRef = React.useRef(null);
2961
- const initialState = React.useMemo(() => {
2729
+ const bottomToolbarRef = react.useRef(null);
2730
+ const editInputRefs = react.useRef({});
2731
+ const filterInputRefs = react.useRef({});
2732
+ const searchInputRef = react.useRef(null);
2733
+ const tableContainerRef = react.useRef(null);
2734
+ const tableHeadCellRefs = react.useRef({});
2735
+ const tablePaperRef = react.useRef(null);
2736
+ const topToolbarRef = react.useRef(null);
2737
+ const initialState = react.useMemo(() => {
2962
2738
  var _a, _b, _c;
2963
2739
  const initState = (_a = props.initialState) !== null && _a !== void 0 ? _a : {};
2964
2740
  initState.columnOrder =
@@ -2966,7 +2742,7 @@ const MRT_TableRoot = (props) => {
2966
2742
  initState.globalFilterFn = (_c = props.globalFilterFn) !== null && _c !== void 0 ? _c : 'fuzzy';
2967
2743
  return initState;
2968
2744
  }, []);
2969
- const [columnFilterFns, setColumnFilterFns] = React.useState(() => Object.assign({}, ...getAllLeafColumnDefs(props.columns).map((col) => {
2745
+ const [columnFilterFns, setColumnFilterFns] = react.useState(() => Object.assign({}, ...getAllLeafColumnDefs(props.columns).map((col) => {
2970
2746
  var _a, _b, _c, _d;
2971
2747
  return ({
2972
2748
  [getColumnId(col)]: col.filterFn instanceof Function
@@ -2974,32 +2750,32 @@ const MRT_TableRoot = (props) => {
2974
2750
  : (_d = (_b = col.filterFn) !== null && _b !== void 0 ? _b : (_c = initialState === null || initialState === void 0 ? void 0 : initialState.columnFilterFns) === null || _c === void 0 ? void 0 : _c[getColumnId(col)]) !== null && _d !== void 0 ? _d : getDefaultColumnFilterFn(col),
2975
2751
  });
2976
2752
  })));
2977
- const [columnOrder, setColumnOrder] = React.useState((_a = initialState.columnOrder) !== null && _a !== void 0 ? _a : []);
2978
- const [density, setDensity] = React.useState((_b = initialState === null || initialState === void 0 ? void 0 : initialState.density) !== null && _b !== void 0 ? _b : 'comfortable');
2979
- const [draggingColumn, setDraggingColumn] = React.useState((_c = initialState.draggingColumn) !== null && _c !== void 0 ? _c : null);
2980
- const [draggingRow, setDraggingRow] = React.useState((_d = initialState.draggingRow) !== null && _d !== void 0 ? _d : null);
2981
- const [editingCell, setEditingCell] = React.useState((_e = initialState.editingCell) !== null && _e !== void 0 ? _e : null);
2982
- const [editingRow, setEditingRow] = React.useState((_f = initialState.editingRow) !== null && _f !== void 0 ? _f : null);
2983
- const [globalFilterFn, setGlobalFilterFn] = React.useState((_g = initialState.globalFilterFn) !== null && _g !== void 0 ? _g : 'fuzzy');
2984
- const [grouping, setGrouping] = React.useState((_h = initialState.grouping) !== null && _h !== void 0 ? _h : []);
2985
- const [hoveredColumn, setHoveredColumn] = React.useState((_j = initialState.hoveredColumn) !== null && _j !== void 0 ? _j : null);
2986
- const [hoveredRow, setHoveredRow] = React.useState((_k = initialState.hoveredRow) !== null && _k !== void 0 ? _k : null);
2987
- const [isFullScreen, setIsFullScreen] = React.useState((_l = initialState === null || initialState === void 0 ? void 0 : initialState.isFullScreen) !== null && _l !== void 0 ? _l : false);
2988
- const [showAlertBanner, setShowAlertBanner] = React.useState((_o = (_m = props.initialState) === null || _m === void 0 ? void 0 : _m.showAlertBanner) !== null && _o !== void 0 ? _o : false);
2989
- const [showColumnFilters, setShowColumnFilters] = React.useState((_p = initialState === null || initialState === void 0 ? void 0 : initialState.showColumnFilters) !== null && _p !== void 0 ? _p : false);
2990
- const [showGlobalFilter, setShowGlobalFilter] = React.useState((_q = initialState === null || initialState === void 0 ? void 0 : initialState.showGlobalFilter) !== null && _q !== void 0 ? _q : false);
2991
- const [showToolbarDropZone, setShowToolbarDropZone] = React.useState((_r = initialState === null || initialState === void 0 ? void 0 : initialState.showToolbarDropZone) !== null && _r !== void 0 ? _r : false);
2992
- const displayColumns = React.useMemo(() => {
2753
+ const [columnOrder, setColumnOrder] = react.useState((_a = initialState.columnOrder) !== null && _a !== void 0 ? _a : []);
2754
+ const [density, setDensity] = react.useState((_b = initialState === null || initialState === void 0 ? void 0 : initialState.density) !== null && _b !== void 0 ? _b : 'comfortable');
2755
+ const [draggingColumn, setDraggingColumn] = react.useState((_c = initialState.draggingColumn) !== null && _c !== void 0 ? _c : null);
2756
+ const [draggingRow, setDraggingRow] = react.useState((_d = initialState.draggingRow) !== null && _d !== void 0 ? _d : null);
2757
+ const [editingCell, setEditingCell] = react.useState((_e = initialState.editingCell) !== null && _e !== void 0 ? _e : null);
2758
+ const [editingRow, setEditingRow] = react.useState((_f = initialState.editingRow) !== null && _f !== void 0 ? _f : null);
2759
+ const [globalFilterFn, setGlobalFilterFn] = react.useState((_g = initialState.globalFilterFn) !== null && _g !== void 0 ? _g : 'fuzzy');
2760
+ const [grouping, setGrouping] = react.useState((_h = initialState.grouping) !== null && _h !== void 0 ? _h : []);
2761
+ const [hoveredColumn, setHoveredColumn] = react.useState((_j = initialState.hoveredColumn) !== null && _j !== void 0 ? _j : null);
2762
+ const [hoveredRow, setHoveredRow] = react.useState((_k = initialState.hoveredRow) !== null && _k !== void 0 ? _k : null);
2763
+ const [isFullScreen, setIsFullScreen] = react.useState((_l = initialState === null || initialState === void 0 ? void 0 : initialState.isFullScreen) !== null && _l !== void 0 ? _l : false);
2764
+ const [showAlertBanner, setShowAlertBanner] = react.useState((_o = (_m = props.initialState) === null || _m === void 0 ? void 0 : _m.showAlertBanner) !== null && _o !== void 0 ? _o : false);
2765
+ const [showColumnFilters, setShowColumnFilters] = react.useState((_p = initialState === null || initialState === void 0 ? void 0 : initialState.showColumnFilters) !== null && _p !== void 0 ? _p : false);
2766
+ const [showGlobalFilter, setShowGlobalFilter] = react.useState((_q = initialState === null || initialState === void 0 ? void 0 : initialState.showGlobalFilter) !== null && _q !== void 0 ? _q : false);
2767
+ const [showToolbarDropZone, setShowToolbarDropZone] = react.useState((_r = initialState === null || initialState === void 0 ? void 0 : initialState.showToolbarDropZone) !== null && _r !== void 0 ? _r : false);
2768
+ const displayColumns = react.useMemo(() => {
2993
2769
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
2994
2770
  return [
2995
2771
  ((_b = (_a = props.state) === null || _a === void 0 ? void 0 : _a.columnOrder) !== null && _b !== void 0 ? _b : columnOrder).includes('mrt-row-drag') && Object.assign(Object.assign(Object.assign({ header: props.localization.move, size: 60 }, props.defaultDisplayColumn), (_c = props.displayColumnDefOptions) === null || _c === void 0 ? void 0 : _c['mrt-row-drag']), { id: 'mrt-row-drag' }),
2996
- ((_e = (_d = props.state) === null || _d === void 0 ? void 0 : _d.columnOrder) !== null && _e !== void 0 ? _e : columnOrder).includes('mrt-row-actions') && Object.assign(Object.assign(Object.assign({ Cell: ({ cell, row }) => (React__default["default"].createElement(MRT_ToggleRowActionMenuButton, { cell: cell, row: row, table: table })), header: props.localization.actions, size: 70 }, props.defaultDisplayColumn), (_f = props.displayColumnDefOptions) === null || _f === void 0 ? void 0 : _f['mrt-row-actions']), { id: 'mrt-row-actions' }),
2772
+ ((_e = (_d = props.state) === null || _d === void 0 ? void 0 : _d.columnOrder) !== null && _e !== void 0 ? _e : columnOrder).includes('mrt-row-actions') && Object.assign(Object.assign(Object.assign({ Cell: ({ cell, row }) => (jsxRuntime.jsx(MRT_ToggleRowActionMenuButton, { cell: cell, row: row, table: table })), header: props.localization.actions, size: 70 }, props.defaultDisplayColumn), (_f = props.displayColumnDefOptions) === null || _f === void 0 ? void 0 : _f['mrt-row-actions']), { id: 'mrt-row-actions' }),
2997
2773
  ((_h = (_g = props.state) === null || _g === void 0 ? void 0 : _g.columnOrder) !== null && _h !== void 0 ? _h : columnOrder).includes('mrt-row-expand') &&
2998
- showExpandColumn(props, (_k = (_j = props.state) === null || _j === void 0 ? void 0 : _j.grouping) !== null && _k !== void 0 ? _k : grouping) && Object.assign(Object.assign(Object.assign({ Cell: ({ row }) => (React__default["default"].createElement(MRT_ExpandButton, { row: row, table: table })), Header: props.enableExpandAll
2999
- ? () => React__default["default"].createElement(MRT_ExpandAllButton, { table: table })
2774
+ showExpandColumn(props, (_k = (_j = props.state) === null || _j === void 0 ? void 0 : _j.grouping) !== null && _k !== void 0 ? _k : grouping) && Object.assign(Object.assign(Object.assign({ Cell: ({ row }) => (jsxRuntime.jsx(MRT_ExpandButton, { row: row, table: table })), Header: props.enableExpandAll
2775
+ ? () => jsxRuntime.jsx(MRT_ExpandAllButton, { table: table })
3000
2776
  : null, header: props.localization.expand, size: 60 }, props.defaultDisplayColumn), (_l = props.displayColumnDefOptions) === null || _l === void 0 ? void 0 : _l['mrt-row-expand']), { id: 'mrt-row-expand' }),
3001
- ((_o = (_m = props.state) === null || _m === void 0 ? void 0 : _m.columnOrder) !== null && _o !== void 0 ? _o : columnOrder).includes('mrt-row-select') && Object.assign(Object.assign(Object.assign({ Cell: ({ row }) => (React__default["default"].createElement(MRT_SelectCheckbox, { row: row, table: table })), Header: props.enableSelectAll && props.enableMultiRowSelection
3002
- ? () => React__default["default"].createElement(MRT_SelectCheckbox, { selectAll: true, table: table })
2777
+ ((_o = (_m = props.state) === null || _m === void 0 ? void 0 : _m.columnOrder) !== null && _o !== void 0 ? _o : columnOrder).includes('mrt-row-select') && Object.assign(Object.assign(Object.assign({ Cell: ({ row }) => (jsxRuntime.jsx(MRT_SelectCheckbox, { row: row, table: table })), Header: props.enableSelectAll && props.enableMultiRowSelection
2778
+ ? () => jsxRuntime.jsx(MRT_SelectCheckbox, { selectAll: true, table: table })
3003
2779
  : null, header: props.localization.select, size: 60 }, props.defaultDisplayColumn), (_p = props.displayColumnDefOptions) === null || _p === void 0 ? void 0 : _p['mrt-row-select']), { id: 'mrt-row-select' }),
3004
2780
  ((_r = (_q = props.state) === null || _q === void 0 ? void 0 : _q.columnOrder) !== null && _r !== void 0 ? _r : columnOrder).includes('mrt-row-numbers') && Object.assign(Object.assign(Object.assign({ Cell: ({ row }) => row.index + 1, Header: () => props.localization.rowNumber, header: props.localization.rowNumbers, size: 60 }, props.defaultDisplayColumn), (_s = props.displayColumnDefOptions) === null || _s === void 0 ? void 0 : _s['mrt-row-numbers']), { id: 'mrt-row-numbers' }),
3005
2781
  ].filter(Boolean);
@@ -3029,7 +2805,7 @@ const MRT_TableRoot = (props) => {
3029
2805
  (_s = props.state) === null || _s === void 0 ? void 0 : _s.columnOrder,
3030
2806
  (_t = props.state) === null || _t === void 0 ? void 0 : _t.grouping,
3031
2807
  ]);
3032
- const columnDefs = React.useMemo(() => {
2808
+ const columnDefs = react.useMemo(() => {
3033
2809
  var _a, _b, _c;
3034
2810
  return prepareColumns({
3035
2811
  aggregationFns: props.aggregationFns,
@@ -3045,7 +2821,7 @@ const MRT_TableRoot = (props) => {
3045
2821
  props.columns,
3046
2822
  (_u = props.state) === null || _u === void 0 ? void 0 : _u.columnFilterFns,
3047
2823
  ]);
3048
- const data = React.useMemo(() => {
2824
+ const data = react.useMemo(() => {
3049
2825
  var _a, _b, _c, _d, _e;
3050
2826
  return (((_a = props.state) === null || _a === void 0 ? void 0 : _a.isLoading) || ((_b = props.state) === null || _b === void 0 ? void 0 : _b.showSkeletons)) &&
3051
2827
  !props.data.length
@@ -3094,13 +2870,13 @@ const MRT_TableRoot = (props) => {
3094
2870
  if (props.tableInstanceRef) {
3095
2871
  props.tableInstanceRef.current = table;
3096
2872
  }
3097
- const initialBodyHeight = React.useRef();
3098
- React.useEffect(() => {
2873
+ const initialBodyHeight = react.useRef();
2874
+ react.useEffect(() => {
3099
2875
  if (typeof window !== 'undefined') {
3100
2876
  initialBodyHeight.current = document.body.style.height;
3101
2877
  }
3102
2878
  }, []);
3103
- React.useEffect(() => {
2879
+ react.useEffect(() => {
3104
2880
  if (typeof window !== 'undefined') {
3105
2881
  if (table.getState().isFullScreen) {
3106
2882
  document.body.style.height = '100vh';
@@ -3111,7 +2887,7 @@ const MRT_TableRoot = (props) => {
3111
2887
  }
3112
2888
  }, [table.getState().isFullScreen]);
3113
2889
  //if page index is out of bounds, set it to the last page
3114
- React.useEffect(() => {
2890
+ react.useEffect(() => {
3115
2891
  var _a;
3116
2892
  const { pageIndex, pageSize } = table.getState().pagination;
3117
2893
  const totalRowCount = (_a = props.rowCount) !== null && _a !== void 0 ? _a : table.getPrePaginationRowModel().rows.length;
@@ -3120,11 +2896,7 @@ const MRT_TableRoot = (props) => {
3120
2896
  table.setPageIndex(Math.floor(totalRowCount / pageSize));
3121
2897
  }
3122
2898
  }, [props.rowCount, table.getPrePaginationRowModel().rows.length]);
3123
- return (React__default["default"].createElement(React__default["default"].Fragment, null,
3124
- React__default["default"].createElement(Dialog__default["default"], { PaperComponent: Box__default["default"], TransitionComponent: !props.enableRowVirtualization ? Grow__default["default"] : undefined, disablePortal: true, fullScreen: true, keepMounted: false, onClose: () => table.setIsFullScreen(false), open: table.getState().isFullScreen, transitionDuration: 400 },
3125
- React__default["default"].createElement(MRT_TablePaper, { table: table })),
3126
- !table.getState().isFullScreen && (React__default["default"].createElement(MRT_TablePaper, { table: table })),
3127
- editingRow && props.editingMode === 'modal' && (React__default["default"].createElement(MRT_EditRowModal, { row: editingRow, table: table, open: true }))));
2899
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Dialog__default["default"], Object.assign({ PaperComponent: Box__default["default"], TransitionComponent: !props.enableRowVirtualization ? Grow__default["default"] : undefined, disablePortal: true, fullScreen: true, keepMounted: false, onClose: () => table.setIsFullScreen(false), open: table.getState().isFullScreen, transitionDuration: 400 }, { children: jsxRuntime.jsx(MRT_TablePaper, { table: table }) })), !table.getState().isFullScreen && (jsxRuntime.jsx(MRT_TablePaper, { table: table })), editingRow && props.editingMode === 'modal' && (jsxRuntime.jsx(MRT_EditRowModal, { row: editingRow, table: table, open: true }))] }));
3128
2900
  };
3129
2901
 
3130
2902
  const MRT_Localization_EN = {
@@ -3222,13 +2994,13 @@ const MRT_Localization_EN = {
3222
2994
  const MaterialReactTable = (_a) => {
3223
2995
  var _b;
3224
2996
  var { aggregationFns, autoResetExpanded = false, columnResizeMode = 'onChange', defaultColumn, defaultDisplayColumn, editingMode = 'modal', enableBottomToolbar = true, enableColumnActions = true, enableColumnFilters = true, enableColumnOrdering = false, enableColumnResizing = false, enableDensityToggle = true, enableExpandAll = true, enableFilterMatchHighlighting = true, enableFilters = true, enableFullScreenToggle = true, enableGlobalFilter = true, enableGlobalFilterRankedResults = true, enableGrouping = false, enableHiding = true, enableMultiRowSelection = true, enableMultiSort = true, enablePagination = true, enablePinning = false, enableRowSelection = false, enableSelectAll = true, enableSorting = true, enableStickyHeader = false, enableTableFooter = true, enableTableHead = true, enableToolbarInternalActions = true, enableTopToolbar = true, filterFns, icons, layoutMode = 'semantic', localization, manualFiltering, manualGrouping, manualPagination, manualSorting, positionActionsColumn = 'first', positionExpandColumn = 'first', positionGlobalFilter = 'right', positionPagination = 'bottom', positionToolbarAlertBanner = 'top', positionToolbarDropZone = 'top', rowNumberMode = 'original', selectAllMode = 'page', sortingFns } = _a, rest = __rest(_a, ["aggregationFns", "autoResetExpanded", "columnResizeMode", "defaultColumn", "defaultDisplayColumn", "editingMode", "enableBottomToolbar", "enableColumnActions", "enableColumnFilters", "enableColumnOrdering", "enableColumnResizing", "enableDensityToggle", "enableExpandAll", "enableFilterMatchHighlighting", "enableFilters", "enableFullScreenToggle", "enableGlobalFilter", "enableGlobalFilterRankedResults", "enableGrouping", "enableHiding", "enableMultiRowSelection", "enableMultiSort", "enablePagination", "enablePinning", "enableRowSelection", "enableSelectAll", "enableSorting", "enableStickyHeader", "enableTableFooter", "enableTableHead", "enableToolbarInternalActions", "enableTopToolbar", "filterFns", "icons", "layoutMode", "localization", "manualFiltering", "manualGrouping", "manualPagination", "manualSorting", "positionActionsColumn", "positionExpandColumn", "positionGlobalFilter", "positionPagination", "positionToolbarAlertBanner", "positionToolbarDropZone", "rowNumberMode", "selectAllMode", "sortingFns"]);
3225
- const _icons = React.useMemo(() => (Object.assign(Object.assign({}, MRT_Default_Icons), icons)), [icons]);
3226
- const _localization = React.useMemo(() => (Object.assign(Object.assign({}, MRT_Localization_EN), localization)), [localization]);
3227
- const _aggregationFns = React.useMemo(() => (Object.assign(Object.assign({}, MRT_AggregationFns), aggregationFns)), []);
3228
- const _filterFns = React.useMemo(() => (Object.assign(Object.assign({}, MRT_FilterFns), filterFns)), []);
3229
- const _sortingFns = React.useMemo(() => (Object.assign(Object.assign({}, MRT_SortingFns), sortingFns)), []);
3230
- const _defaultColumn = React.useMemo(() => (Object.assign(Object.assign({}, MRT_DefaultColumn), defaultColumn)), [defaultColumn]);
3231
- const _defaultDisplayColumn = React.useMemo(() => (Object.assign(Object.assign({}, MRT_DefaultDisplayColumn), defaultDisplayColumn)), [defaultDisplayColumn]);
2997
+ const _icons = react.useMemo(() => (Object.assign(Object.assign({}, MRT_Default_Icons), icons)), [icons]);
2998
+ const _localization = react.useMemo(() => (Object.assign(Object.assign({}, MRT_Localization_EN), localization)), [localization]);
2999
+ const _aggregationFns = react.useMemo(() => (Object.assign(Object.assign({}, MRT_AggregationFns), aggregationFns)), []);
3000
+ const _filterFns = react.useMemo(() => (Object.assign(Object.assign({}, MRT_FilterFns), filterFns)), []);
3001
+ const _sortingFns = react.useMemo(() => (Object.assign(Object.assign({}, MRT_SortingFns), sortingFns)), []);
3002
+ const _defaultColumn = react.useMemo(() => (Object.assign(Object.assign({}, MRT_DefaultColumn), defaultColumn)), [defaultColumn]);
3003
+ const _defaultDisplayColumn = react.useMemo(() => (Object.assign(Object.assign({}, MRT_DefaultDisplayColumn), defaultDisplayColumn)), [defaultDisplayColumn]);
3232
3004
  if (rest.enableRowVirtualization || rest.enableColumnVirtualization) {
3233
3005
  layoutMode = 'grid';
3234
3006
  }
@@ -3244,7 +3016,7 @@ const MaterialReactTable = (_a) => {
3244
3016
  manualPagination = true;
3245
3017
  manualSorting = true;
3246
3018
  }
3247
- return (React__default["default"].createElement(MRT_TableRoot, Object.assign({ aggregationFns: _aggregationFns, autoResetExpanded: autoResetExpanded, columnResizeMode: columnResizeMode, defaultColumn: _defaultColumn, defaultDisplayColumn: _defaultDisplayColumn, editingMode: editingMode, enableBottomToolbar: enableBottomToolbar, enableColumnActions: enableColumnActions, enableColumnFilters: enableColumnFilters, enableColumnOrdering: enableColumnOrdering, enableColumnResizing: enableColumnResizing, enableDensityToggle: enableDensityToggle, enableExpandAll: enableExpandAll, enableFilterMatchHighlighting: enableFilterMatchHighlighting, enableFilters: enableFilters, enableFullScreenToggle: enableFullScreenToggle, enableGlobalFilter: enableGlobalFilter, enableGlobalFilterRankedResults: enableGlobalFilterRankedResults, enableGrouping: enableGrouping, enableHiding: enableHiding, enableMultiRowSelection: enableMultiRowSelection, enableMultiSort: enableMultiSort, enablePagination: enablePagination, enablePinning: enablePinning, enableRowSelection: enableRowSelection, enableSelectAll: enableSelectAll, enableSorting: enableSorting, enableStickyHeader: enableStickyHeader, enableTableFooter: enableTableFooter, enableTableHead: enableTableHead, enableToolbarInternalActions: enableToolbarInternalActions, enableTopToolbar: enableTopToolbar, filterFns: _filterFns, icons: _icons, layoutMode: layoutMode, localization: _localization, manualFiltering: manualFiltering, manualGrouping: manualGrouping, manualPagination: manualPagination, manualSorting: manualSorting, positionActionsColumn: positionActionsColumn, positionExpandColumn: positionExpandColumn, positionGlobalFilter: positionGlobalFilter, positionPagination: positionPagination, positionToolbarAlertBanner: positionToolbarAlertBanner, positionToolbarDropZone: positionToolbarDropZone, rowNumberMode: rowNumberMode, selectAllMode: selectAllMode, sortingFns: _sortingFns }, rest)));
3019
+ return (jsxRuntime.jsx(MRT_TableRoot, Object.assign({ aggregationFns: _aggregationFns, autoResetExpanded: autoResetExpanded, columnResizeMode: columnResizeMode, defaultColumn: _defaultColumn, defaultDisplayColumn: _defaultDisplayColumn, editingMode: editingMode, enableBottomToolbar: enableBottomToolbar, enableColumnActions: enableColumnActions, enableColumnFilters: enableColumnFilters, enableColumnOrdering: enableColumnOrdering, enableColumnResizing: enableColumnResizing, enableDensityToggle: enableDensityToggle, enableExpandAll: enableExpandAll, enableFilterMatchHighlighting: enableFilterMatchHighlighting, enableFilters: enableFilters, enableFullScreenToggle: enableFullScreenToggle, enableGlobalFilter: enableGlobalFilter, enableGlobalFilterRankedResults: enableGlobalFilterRankedResults, enableGrouping: enableGrouping, enableHiding: enableHiding, enableMultiRowSelection: enableMultiRowSelection, enableMultiSort: enableMultiSort, enablePagination: enablePagination, enablePinning: enablePinning, enableRowSelection: enableRowSelection, enableSelectAll: enableSelectAll, enableSorting: enableSorting, enableStickyHeader: enableStickyHeader, enableTableFooter: enableTableFooter, enableTableHead: enableTableHead, enableToolbarInternalActions: enableToolbarInternalActions, enableTopToolbar: enableTopToolbar, filterFns: _filterFns, icons: _icons, layoutMode: layoutMode, localization: _localization, manualFiltering: manualFiltering, manualGrouping: manualGrouping, manualPagination: manualPagination, manualSorting: manualSorting, positionActionsColumn: positionActionsColumn, positionExpandColumn: positionExpandColumn, positionGlobalFilter: positionGlobalFilter, positionPagination: positionPagination, positionToolbarAlertBanner: positionToolbarAlertBanner, positionToolbarDropZone: positionToolbarDropZone, rowNumberMode: rowNumberMode, selectAllMode: selectAllMode, sortingFns: _sortingFns }, rest)));
3248
3020
  };
3249
3021
 
3250
3022
  exports.MRT_AggregationFns = MRT_AggregationFns;
@@ -3259,6 +3031,7 @@ exports.MRT_GlobalFilterTextField = MRT_GlobalFilterTextField;
3259
3031
  exports.MRT_GrabHandleButton = MRT_GrabHandleButton;
3260
3032
  exports.MRT_ShowHideColumnsButton = MRT_ShowHideColumnsButton;
3261
3033
  exports.MRT_SortingFns = MRT_SortingFns;
3034
+ exports.MRT_TableHeadCellFilterContainer = MRT_TableHeadCellFilterContainer;
3262
3035
  exports.MRT_TablePagination = MRT_TablePagination;
3263
3036
  exports.MRT_ToggleDensePaddingButton = MRT_ToggleDensePaddingButton;
3264
3037
  exports.MRT_ToggleFiltersButton = MRT_ToggleFiltersButton;