@elliemae/ds-data-table 3.57.0-next.1 → 3.57.0-next.11

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 (98) hide show
  1. package/dist/cjs/addons/Columns/ColumnExpand/ColumnExpand.js +2 -2
  2. package/dist/cjs/addons/Columns/ColumnExpand/ColumnExpand.js.map +3 -3
  3. package/dist/cjs/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js +2 -2
  4. package/dist/cjs/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js.map +3 -3
  5. package/dist/cjs/addons/Editables/TextEditableCell/TextEditableCell.js +2 -2
  6. package/dist/cjs/addons/Editables/TextEditableCell/TextEditableCell.js.map +2 -2
  7. package/dist/cjs/addons/Filters/Components/FreeTextSearchFilter/index.js +36 -24
  8. package/dist/cjs/addons/Filters/Components/FreeTextSearchFilter/index.js.map +3 -3
  9. package/dist/cjs/configs/constants.js +1 -0
  10. package/dist/cjs/configs/constants.js.map +2 -2
  11. package/dist/cjs/{DSDataTableDefinitions.js → constants/index.js} +41 -7
  12. package/dist/cjs/constants/index.js.map +7 -0
  13. package/dist/cjs/constants/legacyToBeDeprecated.js +75 -0
  14. package/dist/cjs/constants/legacyToBeDeprecated.js.map +7 -0
  15. package/dist/cjs/exported-related/FilterPopover/index.js +20 -8
  16. package/dist/cjs/exported-related/FilterPopover/index.js.map +3 -3
  17. package/dist/cjs/exported-related/Toolbar/Toolbar.js +7 -7
  18. package/dist/cjs/exported-related/Toolbar/Toolbar.js.map +3 -3
  19. package/dist/cjs/index.js +6 -2
  20. package/dist/cjs/index.js.map +2 -2
  21. package/dist/cjs/parts/DnDHandle.js +4 -4
  22. package/dist/cjs/parts/DnDHandle.js.map +3 -3
  23. package/dist/cjs/parts/DropIndicator.js +14 -14
  24. package/dist/cjs/parts/DropIndicator.js.map +3 -3
  25. package/dist/cjs/parts/EmptyContent.js +8 -8
  26. package/dist/cjs/parts/EmptyContent.js.map +2 -2
  27. package/dist/cjs/parts/FilterBar/styled.js +2 -2
  28. package/dist/cjs/parts/FilterBar/styled.js.map +2 -2
  29. package/dist/cjs/parts/Headers/EmptyChildrenGroup.js +2 -2
  30. package/dist/cjs/parts/Headers/EmptyChildrenGroup.js.map +2 -2
  31. package/dist/cjs/parts/Headers/HeaderCellGroup.js +2 -2
  32. package/dist/cjs/parts/Headers/HeaderCellGroup.js.map +2 -2
  33. package/dist/cjs/parts/Headers/useHeaderResizer.js +21 -19
  34. package/dist/cjs/parts/Headers/useHeaderResizer.js.map +3 -3
  35. package/dist/cjs/parts/Loader.js +2 -2
  36. package/dist/cjs/parts/Loader.js.map +2 -2
  37. package/dist/cjs/parts/Row.js +2 -2
  38. package/dist/cjs/parts/Row.js.map +2 -2
  39. package/dist/cjs/react-desc-prop-types.js +2 -2
  40. package/dist/cjs/react-desc-prop-types.js.map +3 -3
  41. package/dist/cjs/styled.js +43 -43
  42. package/dist/cjs/styled.js.map +3 -3
  43. package/dist/esm/addons/Columns/ColumnExpand/ColumnExpand.js +1 -1
  44. package/dist/esm/addons/Columns/ColumnExpand/ColumnExpand.js.map +1 -1
  45. package/dist/esm/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js +1 -1
  46. package/dist/esm/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js.map +1 -1
  47. package/dist/esm/addons/Editables/TextEditableCell/TextEditableCell.js +1 -1
  48. package/dist/esm/addons/Editables/TextEditableCell/TextEditableCell.js.map +1 -1
  49. package/dist/esm/addons/Filters/Components/FreeTextSearchFilter/index.js +34 -22
  50. package/dist/esm/addons/Filters/Components/FreeTextSearchFilter/index.js.map +2 -2
  51. package/dist/esm/configs/constants.js +1 -0
  52. package/dist/esm/configs/constants.js.map +2 -2
  53. package/dist/esm/constants/index.js +89 -0
  54. package/dist/esm/constants/index.js.map +7 -0
  55. package/dist/esm/constants/legacyToBeDeprecated.js +45 -0
  56. package/dist/esm/constants/legacyToBeDeprecated.js.map +7 -0
  57. package/dist/esm/exported-related/FilterPopover/index.js +14 -2
  58. package/dist/esm/exported-related/FilterPopover/index.js.map +2 -2
  59. package/dist/esm/exported-related/Toolbar/Toolbar.js +1 -1
  60. package/dist/esm/exported-related/Toolbar/Toolbar.js.map +1 -1
  61. package/dist/esm/index.js +12 -1
  62. package/dist/esm/index.js.map +2 -2
  63. package/dist/esm/parts/DnDHandle.js +1 -1
  64. package/dist/esm/parts/DnDHandle.js.map +1 -1
  65. package/dist/esm/parts/DropIndicator.js +1 -1
  66. package/dist/esm/parts/DropIndicator.js.map +1 -1
  67. package/dist/esm/parts/EmptyContent.js +1 -1
  68. package/dist/esm/parts/EmptyContent.js.map +1 -1
  69. package/dist/esm/parts/FilterBar/styled.js +1 -1
  70. package/dist/esm/parts/FilterBar/styled.js.map +1 -1
  71. package/dist/esm/parts/Headers/EmptyChildrenGroup.js +1 -1
  72. package/dist/esm/parts/Headers/EmptyChildrenGroup.js.map +1 -1
  73. package/dist/esm/parts/Headers/HeaderCellGroup.js +1 -1
  74. package/dist/esm/parts/Headers/HeaderCellGroup.js.map +1 -1
  75. package/dist/esm/parts/Headers/useHeaderResizer.js +21 -19
  76. package/dist/esm/parts/Headers/useHeaderResizer.js.map +3 -3
  77. package/dist/esm/parts/Loader.js +1 -1
  78. package/dist/esm/parts/Loader.js.map +1 -1
  79. package/dist/esm/parts/Row.js +1 -1
  80. package/dist/esm/parts/Row.js.map +1 -1
  81. package/dist/esm/react-desc-prop-types.js +5 -2
  82. package/dist/esm/react-desc-prop-types.js.map +2 -2
  83. package/dist/esm/styled.js +1 -1
  84. package/dist/esm/styled.js.map +1 -1
  85. package/dist/types/configs/constants.d.ts +1 -0
  86. package/dist/types/constants/index.d.ts +269 -0
  87. package/dist/types/constants/legacyToBeDeprecated.d.ts +38 -0
  88. package/dist/types/index.d.ts +1 -1
  89. package/dist/types/parts/Headers/useHeaderResizer.d.ts +1 -0
  90. package/dist/types/react-desc-prop-types.d.ts +5 -59
  91. package/dist/types/tests/DSDataTable.exports.test.d.ts +1 -0
  92. package/dist/types/tests/data-testid/DSDataTable.data-testid.test.d.ts +1 -0
  93. package/dist/types/tests/data-testid/Renderers.d.ts +36 -0
  94. package/package.json +30 -30
  95. package/dist/cjs/DSDataTableDefinitions.js.map +0 -7
  96. package/dist/esm/DSDataTableDefinitions.js +0 -55
  97. package/dist/esm/DSDataTableDefinitions.js.map +0 -7
  98. package/dist/types/DSDataTableDefinitions.d.ts +0 -91
@@ -33,7 +33,7 @@ __export(useHeaderResizer_exports, {
33
33
  module.exports = __toCommonJS(useHeaderResizer_exports);
34
34
  var React = __toESM(require("react"));
35
35
  var import_lodash_es = require("lodash-es");
36
- var import_react = require("react");
36
+ var import_react = __toESM(require("react"));
37
37
  var import_createInternalAndPropsContext = require("../../configs/useStore/createInternalAndPropsContext.js");
38
38
  var import_gridLayoutHelpers = require("../../helpers/gridLayoutHelpers.js");
39
39
  const narrow = (value, min, max) => Math.min(Math.max(value, min ?? 30), max ?? Infinity);
@@ -72,43 +72,45 @@ const useHeaderResizer = ({
72
72
  () => visibleColumnsOnGridLayout.findIndex((col) => col.id === columnId),
73
73
  [columnId, visibleColumnsOnGridLayout]
74
74
  );
75
+ const realColumnIndexRef = import_react.default.useRef(realColumnIndex);
76
+ realColumnIndexRef.current = realColumnIndex;
75
77
  const pushColumnSizeChange = (0, import_react.useCallback)(
76
78
  (nextWidth) => {
77
- if (nextWidth === visibleColumnsCopy[realColumnIndex].width) return;
79
+ if (nextWidth === visibleColumnsOnGridLayout[realColumnIndexRef.current].width) return;
78
80
  onColumnResize?.(columnId, nextWidth);
79
- visibleColumnsOnGridLayout[realColumnIndex].width = nextWidth;
81
+ visibleColumnsOnGridLayout[realColumnIndexRef.current].width = nextWidth;
80
82
  onColumnSizeChange(visibleColumnsCopy, columnId, nextWidth);
81
83
  },
82
- [columnId, onColumnResize, onColumnSizeChange, realColumnIndex, visibleColumnsCopy, visibleColumnsOnGridLayout]
84
+ [columnId, onColumnResize, onColumnSizeChange, realColumnIndexRef, visibleColumnsCopy, visibleColumnsOnGridLayout]
83
85
  );
84
86
  const onResizeStart = (0, import_react.useCallback)(() => {
85
87
  setIsResizing(true);
86
88
  }, []);
87
89
  const onResizeEnd = (0, import_react.useCallback)(() => {
88
90
  setIsResizing(false);
89
- pushColumnSizeChange((0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndex]);
91
+ pushColumnSizeChange((0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndexRef.current]);
90
92
  (0, import_gridLayoutHelpers.removeGridLayout)(virtualListRef.current);
91
- }, [pushColumnSizeChange, virtualListRef, realColumnIndex]);
93
+ }, [pushColumnSizeChange, virtualListRef, realColumnIndexRef]);
92
94
  const onResizeHandler = (0, import_react.useCallback)(
93
95
  (e) => {
94
- if (realColumnIndex === -1) return;
96
+ if (realColumnIndexRef.current === -1) return;
95
97
  const delta = ("clientX" in e ? e.clientX : e.touches[0].clientX) - (innerRef.current?.getBoundingClientRect().x ?? 0);
96
- const originalWidth = (0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndex];
98
+ const originalWidth = (0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndexRef.current];
97
99
  const widthWithDelta = narrow(
98
100
  originalWidth + delta,
99
- visibleColumnsOnGridLayout[realColumnIndex].minWidth,
100
- visibleColumnsOnGridLayout[realColumnIndex].maxWidth
101
+ visibleColumnsOnGridLayout[realColumnIndexRef.current].minWidth,
102
+ visibleColumnsOnGridLayout[realColumnIndexRef.current].maxWidth
101
103
  );
102
- (0, import_gridLayoutHelpers.changeGridLayout)(virtualListRef.current, realColumnIndex, widthWithDelta);
104
+ (0, import_gridLayoutHelpers.changeGridLayout)(virtualListRef.current, realColumnIndexRef.current, widthWithDelta);
103
105
  (0, import_gridLayoutHelpers.setSubColumnsGridLayout)(virtualListRef.current, visibleColumnsCopy);
104
106
  e.preventDefault();
105
107
  e.stopPropagation();
106
108
  },
107
- [realColumnIndex, innerRef, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout]
109
+ [innerRef, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout]
108
110
  );
109
111
  const handleKeyboardResize = (0, import_react.useCallback)(
110
112
  (e) => {
111
- if (realColumnIndex === -1) return;
113
+ if (realColumnIndexRef.current === -1) return;
112
114
  if (e.key === "Enter") {
113
115
  e.stopPropagation();
114
116
  }
@@ -117,18 +119,18 @@ const useHeaderResizer = ({
117
119
  }
118
120
  const delta = getCorrectDelta(e);
119
121
  if (delta === 0) return;
120
- const originalWidth = (0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndex];
122
+ const originalWidth = (0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndexRef.current];
121
123
  const widthWithDelta = narrow(
122
124
  originalWidth + delta,
123
- visibleColumnsOnGridLayout[realColumnIndex].minWidth,
124
- visibleColumnsOnGridLayout[realColumnIndex].maxWidth
125
+ visibleColumnsOnGridLayout[realColumnIndexRef.current].minWidth,
126
+ visibleColumnsOnGridLayout[realColumnIndexRef.current].maxWidth
125
127
  );
126
- (0, import_gridLayoutHelpers.changeGridLayout)(virtualListRef.current, realColumnIndex, widthWithDelta);
128
+ (0, import_gridLayoutHelpers.changeGridLayout)(virtualListRef.current, realColumnIndexRef.current, widthWithDelta);
127
129
  (0, import_gridLayoutHelpers.setSubColumnsGridLayout)(virtualListRef.current, visibleColumnsCopy);
128
- pushColumnSizeChange((0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndex] + delta);
130
+ pushColumnSizeChange((0, import_gridLayoutHelpers.getGridLayout)(virtualListRef.current)[realColumnIndexRef.current] + delta);
129
131
  (0, import_gridLayoutHelpers.removeGridLayout)(virtualListRef.current);
130
132
  },
131
- [pushColumnSizeChange, realColumnIndex, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout]
133
+ [pushColumnSizeChange, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout]
132
134
  );
133
135
  return {
134
136
  isResizing,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/parts/Headers/useHeaderResizer.ts", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { cloneDeep } from 'lodash-es';\nimport { useCallback, useMemo, useState } from 'react';\nimport { usePropsStore } from '../../configs/useStore/createInternalAndPropsContext.js';\nimport {\n changeGridLayout,\n getGridLayout,\n removeGridLayout,\n setSubColumnsGridLayout,\n} from '../../helpers/gridLayoutHelpers.js';\nimport type { DSDataTableT } from '../../react-desc-prop-types.js';\n\n// if number > max => max\n// if number < min => min\n// else => number\nconst narrow = (value: number, min: number | undefined, max: number | undefined): number =>\n Math.min(Math.max(value, min ?? 30), max ?? Infinity);\n\n// Returns the delta of the keyboard event\nconst getCorrectDelta = (e: React.KeyboardEvent) => {\n let multiplier = 1;\n\n if (e.shiftKey) multiplier *= 5;\n if (e.altKey) multiplier *= 10;\n\n if (e.code === 'ArrowLeft') {\n return -multiplier;\n }\n if (e.code === 'ArrowRight') {\n return multiplier;\n }\n return 0;\n};\n\nexport const useHeaderResizer = ({\n columnId,\n innerRef,\n}: {\n columnId: string;\n innerRef: React.MutableRefObject<HTMLInputElement | null>;\n}) => {\n const visibleColumns = usePropsStore((state) => state.visibleColumns);\n const onColumnResize = usePropsStore((state) => state.onColumnResize);\n const onColumnSizeChange = usePropsStore((state) => state.onColumnSizeChange);\n const virtualListRef = usePropsStore((state) => state.virtualListRef);\n\n const [isResizing, setIsResizing] = useState(false);\n\n const visibleColumnsCopy = useMemo(() => cloneDeep(visibleColumns), [visibleColumns]);\n\n const visibleColumnsOnGridLayout = useMemo(\n () =>\n visibleColumnsCopy.reduce((acc, cur) => {\n if (cur.columns) {\n return acc.concat(cur.columns);\n }\n return acc.concat(cur);\n }, [] as DSDataTableT.InternalColumn[]),\n [visibleColumnsCopy],\n );\n\n const realColumnIndex = useMemo(\n () => visibleColumnsOnGridLayout.findIndex((col) => col.id === columnId),\n [columnId, visibleColumnsOnGridLayout],\n );\n\n // Notifies the user of the change in the column size\n const pushColumnSizeChange = useCallback(\n (nextWidth: number) => {\n // PUI-12695: Avoid unnecessary calls to onColumnResize\n // Avoid calling onColumnResize if the width of the column has not changed\n // unnecessary calls to onColumnResize can cause performance issues (next resizes were not working)\n if (nextWidth === visibleColumnsCopy[realColumnIndex].width) return;\n onColumnResize?.(columnId, nextWidth);\n // this next line is updating also the visibleColumnsCopy\n visibleColumnsOnGridLayout[realColumnIndex].width = nextWidth;\n onColumnSizeChange(visibleColumnsCopy, columnId, nextWidth);\n },\n [columnId, onColumnResize, onColumnSizeChange, realColumnIndex, visibleColumnsCopy, visibleColumnsOnGridLayout],\n );\n\n const onResizeStart = useCallback(() => {\n setIsResizing(true);\n }, []);\n\n const onResizeEnd = useCallback(() => {\n setIsResizing(false);\n pushColumnSizeChange(getGridLayout(virtualListRef.current)[realColumnIndex]);\n removeGridLayout(virtualListRef.current);\n }, [pushColumnSizeChange, virtualListRef, realColumnIndex]);\n\n // Mouse resize\n const onResizeHandler = useCallback(\n (e: MouseEvent | TouchEvent) => {\n if (realColumnIndex === -1) return;\n\n const delta =\n ('clientX' in e ? e.clientX : e.touches[0].clientX) - (innerRef.current?.getBoundingClientRect().x ?? 0); // delta in pixels\n\n const originalWidth = getGridLayout(virtualListRef.current)[realColumnIndex];\n\n const widthWithDelta = narrow(\n originalWidth + delta,\n visibleColumnsOnGridLayout[realColumnIndex].minWidth,\n visibleColumnsOnGridLayout[realColumnIndex].maxWidth,\n );\n\n changeGridLayout(virtualListRef.current, realColumnIndex, widthWithDelta);\n setSubColumnsGridLayout(virtualListRef.current, visibleColumnsCopy);\n\n // We will notify the user of the change in the column size only when the user releases the mouse button\n\n // To prevent text selection\n e.preventDefault();\n e.stopPropagation();\n },\n [realColumnIndex, innerRef, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout],\n );\n\n // Keyboard resize\n const handleKeyboardResize = useCallback(\n (e: React.KeyboardEvent) => {\n if (realColumnIndex === -1) return;\n\n if (e.key === 'Enter') {\n e.stopPropagation();\n }\n\n if (e.code === 'ArrowLeft' || e.code === 'ArrowRight') {\n e.preventDefault();\n }\n\n const delta = getCorrectDelta(e);\n\n if (delta === 0) return;\n\n const originalWidth = getGridLayout(virtualListRef.current)[realColumnIndex];\n\n const widthWithDelta = narrow(\n originalWidth + delta,\n visibleColumnsOnGridLayout[realColumnIndex].minWidth,\n visibleColumnsOnGridLayout[realColumnIndex].maxWidth,\n );\n\n changeGridLayout(virtualListRef.current, realColumnIndex, widthWithDelta);\n setSubColumnsGridLayout(virtualListRef.current, visibleColumnsCopy);\n\n pushColumnSizeChange(getGridLayout(virtualListRef.current)[realColumnIndex] + delta);\n removeGridLayout(virtualListRef.current);\n },\n [pushColumnSizeChange, realColumnIndex, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout],\n );\n\n return {\n isResizing,\n onResizeStart,\n onResizeEnd,\n onResizeHandler,\n handleKeyboardResize,\n };\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAA0B;AAC1B,mBAA+C;AAC/C,2CAA8B;AAC9B,+BAKO;AAMP,MAAM,SAAS,CAAC,OAAe,KAAyB,QACtD,KAAK,IAAI,KAAK,IAAI,OAAO,OAAO,EAAE,GAAG,OAAO,QAAQ;AAGtD,MAAM,kBAAkB,CAAC,MAA2B;AAClD,MAAI,aAAa;AAEjB,MAAI,EAAE,SAAU,eAAc;AAC9B,MAAI,EAAE,OAAQ,eAAc;AAE5B,MAAI,EAAE,SAAS,aAAa;AAC1B,WAAO,CAAC;AAAA,EACV;AACA,MAAI,EAAE,SAAS,cAAc;AAC3B,WAAO;AAAA,EACT;AACA,SAAO;AACT;AAEO,MAAM,mBAAmB,CAAC;AAAA,EAC/B;AAAA,EACA;AACF,MAGM;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AAgB,oBAAoB,0BAA0B;AAAA,EACxG;AAEA,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;",
6
- "names": []
4
+ "sourcesContent": ["import { cloneDeep } from 'lodash-es';\nimport React, { useCallback, useMemo, useState } from 'react';\nimport { usePropsStore } from '../../configs/useStore/createInternalAndPropsContext.js';\nimport {\n changeGridLayout,\n getGridLayout,\n removeGridLayout,\n setSubColumnsGridLayout,\n} from '../../helpers/gridLayoutHelpers.js';\nimport type { DSDataTableT } from '../../react-desc-prop-types.js';\n\n// if number > max => max\n// if number < min => min\n// else => number\nconst narrow = (value: number, min: number | undefined, max: number | undefined): number =>\n Math.min(Math.max(value, min ?? 30), max ?? Infinity);\n\n// Returns the delta of the keyboard event\nconst getCorrectDelta = (e: React.KeyboardEvent) => {\n let multiplier = 1;\n\n if (e.shiftKey) multiplier *= 5;\n if (e.altKey) multiplier *= 10;\n\n if (e.code === 'ArrowLeft') {\n return -multiplier;\n }\n if (e.code === 'ArrowRight') {\n return multiplier;\n }\n return 0;\n};\n\nexport const useHeaderResizer = ({\n columnId,\n innerRef,\n}: {\n columnId: string;\n innerRef: React.MutableRefObject<HTMLInputElement | null>;\n}) => {\n const visibleColumns = usePropsStore((state) => state.visibleColumns);\n const onColumnResize = usePropsStore((state) => state.onColumnResize);\n const onColumnSizeChange = usePropsStore((state) => state.onColumnSizeChange);\n const virtualListRef = usePropsStore((state) => state.virtualListRef);\n\n const [isResizing, setIsResizing] = useState(false);\n\n const visibleColumnsCopy = useMemo(() => cloneDeep(visibleColumns), [visibleColumns]);\n\n const visibleColumnsOnGridLayout = useMemo(\n () =>\n visibleColumnsCopy.reduce((acc, cur) => {\n if (cur.columns) {\n return acc.concat(cur.columns);\n }\n return acc.concat(cur);\n }, [] as DSDataTableT.InternalColumn[]),\n [visibleColumnsCopy],\n );\n\n const realColumnIndex = useMemo(\n () => visibleColumnsOnGridLayout.findIndex((col) => col.id === columnId),\n [columnId, visibleColumnsOnGridLayout],\n );\n\n const realColumnIndexRef = React.useRef(realColumnIndex);\n realColumnIndexRef.current = realColumnIndex;\n\n // Notifies the user of the change in the column size\n const pushColumnSizeChange = useCallback(\n (nextWidth: number) => {\n // PUI-12695: Avoid unnecessary calls to onColumnResize\n // Avoid calling onColumnResize if the width of the column has not changed\n // unnecessary calls to onColumnResize can cause performance issues (next resizes were not working)\n if (nextWidth === visibleColumnsOnGridLayout[realColumnIndexRef.current].width) return;\n onColumnResize?.(columnId, nextWidth);\n // this next line is updating also the visibleColumnsCopy via mutable changes\n // the mutable changes here works because what we mutate is a cloneDeep of the columns\n visibleColumnsOnGridLayout[realColumnIndexRef.current].width = nextWidth;\n onColumnSizeChange(visibleColumnsCopy, columnId, nextWidth);\n },\n [columnId, onColumnResize, onColumnSizeChange, realColumnIndexRef, visibleColumnsCopy, visibleColumnsOnGridLayout],\n );\n\n const onResizeStart = useCallback(() => {\n setIsResizing(true);\n }, []);\n\n const onResizeEnd = useCallback(() => {\n setIsResizing(false);\n pushColumnSizeChange(getGridLayout(virtualListRef.current)[realColumnIndexRef.current]);\n removeGridLayout(virtualListRef.current);\n }, [pushColumnSizeChange, virtualListRef, realColumnIndexRef]);\n\n // Mouse resize\n const onResizeHandler = useCallback(\n (e: MouseEvent | TouchEvent) => {\n if (realColumnIndexRef.current === -1) return;\n\n const delta =\n ('clientX' in e ? e.clientX : e.touches[0].clientX) - (innerRef.current?.getBoundingClientRect().x ?? 0); // delta in pixels\n\n const originalWidth = getGridLayout(virtualListRef.current)[realColumnIndexRef.current];\n\n const widthWithDelta = narrow(\n originalWidth + delta,\n visibleColumnsOnGridLayout[realColumnIndexRef.current].minWidth,\n visibleColumnsOnGridLayout[realColumnIndexRef.current].maxWidth,\n );\n\n changeGridLayout(virtualListRef.current, realColumnIndexRef.current, widthWithDelta);\n setSubColumnsGridLayout(virtualListRef.current, visibleColumnsCopy);\n\n // We will notify the user of the change in the column size only when the user releases the mouse button\n\n // To prevent text selection\n e.preventDefault();\n e.stopPropagation();\n },\n [innerRef, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout],\n );\n\n // Keyboard resize\n const handleKeyboardResize = useCallback(\n (e: React.KeyboardEvent) => {\n if (realColumnIndexRef.current === -1) return;\n\n if (e.key === 'Enter') {\n e.stopPropagation();\n }\n\n if (e.code === 'ArrowLeft' || e.code === 'ArrowRight') {\n e.preventDefault();\n }\n\n const delta = getCorrectDelta(e);\n\n if (delta === 0) return;\n\n const originalWidth = getGridLayout(virtualListRef.current)[realColumnIndexRef.current];\n\n const widthWithDelta = narrow(\n originalWidth + delta,\n visibleColumnsOnGridLayout[realColumnIndexRef.current].minWidth,\n visibleColumnsOnGridLayout[realColumnIndexRef.current].maxWidth,\n );\n\n changeGridLayout(virtualListRef.current, realColumnIndexRef.current, widthWithDelta);\n setSubColumnsGridLayout(virtualListRef.current, visibleColumnsCopy);\n\n pushColumnSizeChange(getGridLayout(virtualListRef.current)[realColumnIndexRef.current] + delta);\n removeGridLayout(virtualListRef.current);\n },\n [pushColumnSizeChange, virtualListRef, visibleColumnsCopy, visibleColumnsOnGridLayout],\n );\n\n return {\n isResizing,\n onResizeStart,\n onResizeEnd,\n onResizeHandler,\n handleKeyboardResize,\n };\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAA0B;AAC1B,mBAAsD;AACtD,2CAA8B;AAC9B,+BAKO;AAMP,MAAM,SAAS,CAAC,OAAe,KAAyB,QACtD,KAAK,IAAI,KAAK,IAAI,OAAO,OAAO,EAAE,GAAG,OAAO,QAAQ;AAGtD,MAAM,kBAAkB,CAAC,MAA2B;AAClD,MAAI,aAAa;AAEjB,MAAI,EAAE,SAAU,eAAc;AAC9B,MAAI,EAAE,OAAQ,eAAc;AAE5B,MAAI,EAAE,SAAS,aAAa;AAC1B,WAAO,CAAC;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2BAA2B,mBAAmB,OAAO,EAAE;AAAA,QACvD,2BAA2B,mBAAmB,OAAO,EAAE;AAAA,MACzD;AAEA,qDAAiB,eAAe,SAAS,mBAAmB,SAAS,cAAc;AACnF,4DAAwB,eAAe,SAAS,kBAAkB;AAElE,+BAAqB,wCAAc,eAAe,OAAO,EAAE,mBAAmB,OAAO,IAAI,KAAK;AAC9F,qDAAiB,eAAe,OAAO;AAAA,IACzC;AAAA,IACA,CAAC,sBAAsB,gBAAgB,oBAAoB,0BAA0B;AAAA,EACvF;AAEA,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;",
6
+ "names": ["React"]
7
7
  }
@@ -37,9 +37,9 @@ var import_ds_circular_progress_indicator = require("@elliemae/ds-circular-progr
37
37
  var import_ds_grid = require("@elliemae/ds-grid");
38
38
  var import_ds_system = require("@elliemae/ds-system");
39
39
  var import_react = require("react");
40
- var import_DSDataTableDefinitions = require("../DSDataTableDefinitions.js");
40
+ var import_constants = require("../constants/index.js");
41
41
  var import_createInternalAndPropsContext = require("../configs/useStore/createInternalAndPropsContext.js");
42
- const StyledLoaderWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_DSDataTableDefinitions.DSDataTableName, slot: import_DSDataTableDefinitions.DSDataTableSlots.LOADER_WRAPPER })`
42
+ const StyledLoaderWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, { name: import_constants.DSDataTableName, slot: import_constants.DSDataTableSlots.LOADER_WRAPPER })`
43
43
  place-items: center;
44
44
  z-index: 0;
45
45
  background-color: white;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/parts/Loader.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { DSCircularProgressIndicator } from '@elliemae/ds-circular-progress-indicator';\nimport { Grid } from '@elliemae/ds-grid';\nimport { styled } from '@elliemae/ds-system';\nimport { memo } from 'react';\nimport { DSDataTableName, DSDataTableSlots } from '../DSDataTableDefinitions.js';\nimport { usePropsStore } from '../configs/useStore/createInternalAndPropsContext.js';\n\nconst StyledLoaderWrapper = styled(Grid, { name: DSDataTableName, slot: DSDataTableSlots.LOADER_WRAPPER })`\n place-items: center;\n z-index: 0;\n background-color: white;\n`;\n\n/**\n * we need to keep the semantic table structure\n * @returns Loader\n */\nconst Loader = () => {\n const getOwnerProps = usePropsStore((store) => store.get);\n return (\n <StyledLoaderWrapper role=\"row\" aria-live=\"polite\" getOwnerProps={getOwnerProps}>\n <div role=\"cell\">\n <DSCircularProgressIndicator size=\"xl\" loading showLabel waiting={false} showTooltip={false} />\n </div>\n </StyledLoaderWrapper>\n );\n};\nexport const MemoizedLoader = memo(Loader);\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADsBf;AAtBR,4CAA4C;AAC5C,qBAAqB;AACrB,uBAAuB;AACvB,mBAAqB;AACrB,oCAAkD;AAClD,2CAA8B;AAE9B,MAAM,0BAAsB,yBAAO,qBAAM,EAAE,MAAM,+CAAiB,MAAM,+CAAiB,eAAe,CAAC;AAAA;AAAA;AAAA;AAAA;AAUzG,MAAM,SAAS,MAAM;AACnB,QAAM,oBAAgB,oDAAc,CAAC,UAAU,MAAM,GAAG;AACxD,SACE,4CAAC,uBAAoB,MAAK,OAAM,aAAU,UAAS,eACjD,sDAAC,SAAI,MAAK,QACR,sDAAC,qEAA4B,MAAK,MAAK,SAAO,MAAC,WAAS,MAAC,SAAS,OAAO,aAAa,OAAO,GAC/F,GACF;AAEJ;AACO,MAAM,qBAAiB,mBAAK,MAAM;",
4
+ "sourcesContent": ["import { DSCircularProgressIndicator } from '@elliemae/ds-circular-progress-indicator';\nimport { Grid } from '@elliemae/ds-grid';\nimport { styled } from '@elliemae/ds-system';\nimport { memo } from 'react';\nimport { DSDataTableName, DSDataTableSlots } from '../constants/index.js';\nimport { usePropsStore } from '../configs/useStore/createInternalAndPropsContext.js';\n\nconst StyledLoaderWrapper = styled(Grid, { name: DSDataTableName, slot: DSDataTableSlots.LOADER_WRAPPER })`\n place-items: center;\n z-index: 0;\n background-color: white;\n`;\n\n/**\n * we need to keep the semantic table structure\n * @returns Loader\n */\nconst Loader = () => {\n const getOwnerProps = usePropsStore((store) => store.get);\n return (\n <StyledLoaderWrapper role=\"row\" aria-live=\"polite\" getOwnerProps={getOwnerProps}>\n <div role=\"cell\">\n <DSCircularProgressIndicator size=\"xl\" loading showLabel waiting={false} showTooltip={false} />\n </div>\n </StyledLoaderWrapper>\n );\n};\nexport const MemoizedLoader = memo(Loader);\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADsBf;AAtBR,4CAA4C;AAC5C,qBAAqB;AACrB,uBAAuB;AACvB,mBAAqB;AACrB,uBAAkD;AAClD,2CAA8B;AAE9B,MAAM,0BAAsB,yBAAO,qBAAM,EAAE,MAAM,kCAAiB,MAAM,kCAAiB,eAAe,CAAC;AAAA;AAAA;AAAA;AAAA;AAUzG,MAAM,SAAS,MAAM;AACnB,QAAM,oBAAgB,oDAAc,CAAC,UAAU,MAAM,GAAG;AACxD,SACE,4CAAC,uBAAoB,MAAK,OAAM,aAAU,UAAS,eACjD,sDAAC,SAAI,MAAK,QACR,sDAAC,qEAA4B,MAAK,MAAK,SAAO,MAAC,WAAS,MAAC,SAAS,OAAO,aAAa,OAAO,GAC/F,GACF;AAEJ;AACO,MAAM,qBAAiB,mBAAK,MAAM;",
6
6
  "names": []
7
7
  }
@@ -37,11 +37,11 @@ var import_jsx_runtime = require("react/jsx-runtime");
37
37
  var import_ds_system = require("@elliemae/ds-system");
38
38
  var import_react = require("react");
39
39
  var import_createInternalAndPropsContext = require("../configs/useStore/createInternalAndPropsContext.js");
40
- var import_DSDataTableDefinitions = require("../DSDataTableDefinitions.js");
40
+ var import_constants = require("../constants/index.js");
41
41
  var import_SortableItemContext = require("./HoC/SortableItemContext.js");
42
42
  var import_withDnDSortableRowContext = require("./HoC/withDnDSortableRowContext.js");
43
43
  var import_RowVariants = require("./RowVariants/index.js");
44
- const StyledRow = (0, import_ds_system.styled)("div", { name: import_DSDataTableDefinitions.DSDataTableName, slot: import_DSDataTableDefinitions.DSDataTableSlots.ROW })`
44
+ const StyledRow = (0, import_ds_system.styled)("div", { name: import_constants.DSDataTableName, slot: import_constants.DSDataTableSlots.ROW })`
45
45
  cursor: ${({ isDisabled }) => isDisabled ? "not-allowed" : "normal"};
46
46
  `;
47
47
  const Row = (props) => {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/parts/Row.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { mergeRefs, styled } from '@elliemae/ds-system';\nimport React, { useCallback, useContext } from 'react';\nimport { useInternalStore, usePropsStore } from '../configs/useStore/createInternalAndPropsContext.js';\nimport { DSDataTableName, DSDataTableSlots } from '../DSDataTableDefinitions.js';\nimport type { DSDataTableT } from '../react-desc-prop-types.js';\nimport { SortableItemContext } from './HoC/SortableItemContext.js';\nimport { withDnDSortableRowContext } from './HoC/withDnDSortableRowContext.js';\nimport { RowVariantMapItem } from './RowVariants/index.js';\n\nconst StyledRow = styled('div', { name: DSDataTableName, slot: DSDataTableSlots.ROW })<{ isDisabled: boolean }>`\n cursor: ${({ isDisabled }) => (isDisabled ? 'not-allowed' : 'normal')};\n`;\n\nexport const Row: React.ComponentType<{\n row: DSDataTableT.InternalRow;\n measureRef?: (el: HTMLElement | null) => void;\n itemWrapperStyle?: React.CSSProperties;\n isDragOverlay: boolean;\n}> = (props) => {\n const { row, measureRef, itemWrapperStyle, isDragOverlay } = props;\n const disabledRows = usePropsStore((state) => state.disabledRows);\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = useCallback(() => row, [row]);\n const focusedRowId = useInternalStore((state) => state.focusedRowId);\n const drilldownRowId = useInternalStore((state) => state.drilldownRowId);\n\n const { draggableProps } = useContext(SortableItemContext);\n const draggableRef = draggableProps && draggableProps.setNodeRef;\n return (\n <StyledRow\n isDisabled={disabledRows[row.uid]}\n style={!isDragOverlay ? itemWrapperStyle : {}}\n innerRef={mergeRefs(measureRef, draggableRef)}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <RowVariantMapItem\n row={row}\n itemIndex={row.realIndex}\n isDragOverlay={isDragOverlay}\n focusedRowId={focusedRowId}\n drilldownRowId={drilldownRowId}\n />\n </StyledRow>\n );\n};\n\nconst RowWithContext = withDnDSortableRowContext(Row);\nexport { RowWithContext };\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADoCjB;AApCN,uBAAkC;AAClC,mBAA+C;AAC/C,2CAAgD;AAChD,oCAAkD;AAElD,iCAAoC;AACpC,uCAA0C;AAC1C,yBAAkC;AAElC,MAAM,gBAAY,yBAAO,OAAO,EAAE,MAAM,+CAAiB,MAAM,+CAAiB,IAAI,CAAC;AAAA,YACzE,CAAC,EAAE,WAAW,MAAO,aAAa,gBAAgB,QAAS;AAAA;AAGhE,MAAM,MAKR,CAAC,UAAU;AACd,QAAM,EAAE,KAAK,YAAY,kBAAkB,cAAc,IAAI;AAC7D,QAAM,mBAAe,oDAAc,CAAC,UAAU,MAAM,YAAY;AAChE,QAAM,oBAAgB,oDAAc,CAAC,UAAU,MAAM,GAAG;AACxD,QAAM,6BAAyB,0BAAY,MAAM,KAAK,CAAC,GAAG,CAAC;AAC3D,QAAM,mBAAe,uDAAiB,CAAC,UAAU,MAAM,YAAY;AACnE,QAAM,qBAAiB,uDAAiB,CAAC,UAAU,MAAM,cAAc;AAEvE,QAAM,EAAE,eAAe,QAAI,yBAAW,8CAAmB;AACzD,QAAM,eAAe,kBAAkB,eAAe;AACtD,SACE;AAAA,IAAC;AAAA;AAAA,MACC,YAAY,aAAa,IAAI,GAAG;AAAA,MAChC,OAAO,CAAC,gBAAgB,mBAAmB,CAAC;AAAA,MAC5C,cAAU,4BAAU,YAAY,YAAY;AAAA,MAC5C;AAAA,MACA;AAAA,MAEA;AAAA,QAAC;AAAA;AAAA,UACC;AAAA,UACA,WAAW,IAAI;AAAA,UACf;AAAA,UACA;AAAA,UACA;AAAA;AAAA,MACF;AAAA;AAAA,EACF;AAEJ;AAEA,MAAM,qBAAiB,4DAA0B,GAAG;",
4
+ "sourcesContent": ["import { mergeRefs, styled } from '@elliemae/ds-system';\nimport React, { useCallback, useContext } from 'react';\nimport { useInternalStore, usePropsStore } from '../configs/useStore/createInternalAndPropsContext.js';\nimport { DSDataTableName, DSDataTableSlots } from '../constants/index.js';\nimport type { DSDataTableT } from '../react-desc-prop-types.js';\nimport { SortableItemContext } from './HoC/SortableItemContext.js';\nimport { withDnDSortableRowContext } from './HoC/withDnDSortableRowContext.js';\nimport { RowVariantMapItem } from './RowVariants/index.js';\n\nconst StyledRow = styled('div', { name: DSDataTableName, slot: DSDataTableSlots.ROW })<{ isDisabled: boolean }>`\n cursor: ${({ isDisabled }) => (isDisabled ? 'not-allowed' : 'normal')};\n`;\n\nexport const Row: React.ComponentType<{\n row: DSDataTableT.InternalRow;\n measureRef?: (el: HTMLElement | null) => void;\n itemWrapperStyle?: React.CSSProperties;\n isDragOverlay: boolean;\n}> = (props) => {\n const { row, measureRef, itemWrapperStyle, isDragOverlay } = props;\n const disabledRows = usePropsStore((state) => state.disabledRows);\n const getOwnerProps = usePropsStore((store) => store.get);\n const getOwnerPropsArguments = useCallback(() => row, [row]);\n const focusedRowId = useInternalStore((state) => state.focusedRowId);\n const drilldownRowId = useInternalStore((state) => state.drilldownRowId);\n\n const { draggableProps } = useContext(SortableItemContext);\n const draggableRef = draggableProps && draggableProps.setNodeRef;\n return (\n <StyledRow\n isDisabled={disabledRows[row.uid]}\n style={!isDragOverlay ? itemWrapperStyle : {}}\n innerRef={mergeRefs(measureRef, draggableRef)}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <RowVariantMapItem\n row={row}\n itemIndex={row.realIndex}\n isDragOverlay={isDragOverlay}\n focusedRowId={focusedRowId}\n drilldownRowId={drilldownRowId}\n />\n </StyledRow>\n );\n};\n\nconst RowWithContext = withDnDSortableRowContext(Row);\nexport { RowWithContext };\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADoCjB;AApCN,uBAAkC;AAClC,mBAA+C;AAC/C,2CAAgD;AAChD,uBAAkD;AAElD,iCAAoC;AACpC,uCAA0C;AAC1C,yBAAkC;AAElC,MAAM,gBAAY,yBAAO,OAAO,EAAE,MAAM,kCAAiB,MAAM,kCAAiB,IAAI,CAAC;AAAA,YACzE,CAAC,EAAE,WAAW,MAAO,aAAa,gBAAgB,QAAS;AAAA;AAGhE,MAAM,MAKR,CAAC,UAAU;AACd,QAAM,EAAE,KAAK,YAAY,kBAAkB,cAAc,IAAI;AAC7D,QAAM,mBAAe,oDAAc,CAAC,UAAU,MAAM,YAAY;AAChE,QAAM,oBAAgB,oDAAc,CAAC,UAAU,MAAM,GAAG;AACxD,QAAM,6BAAyB,0BAAY,MAAM,KAAK,CAAC,GAAG,CAAC;AAC3D,QAAM,mBAAe,uDAAiB,CAAC,UAAU,MAAM,YAAY;AACnE,QAAM,qBAAiB,uDAAiB,CAAC,UAAU,MAAM,cAAc;AAEvE,QAAM,EAAE,eAAe,QAAI,yBAAW,8CAAmB;AACzD,QAAM,eAAe,kBAAkB,eAAe;AACtD,SACE;AAAA,IAAC;AAAA;AAAA,MACC,YAAY,aAAa,IAAI,GAAG;AAAA,MAChC,OAAO,CAAC,gBAAgB,mBAAmB,CAAC;AAAA,MAC5C,cAAU,4BAAU,YAAY,YAAY;AAAA,MAC5C;AAAA,MACA;AAAA,MAEA;AAAA,QAAC;AAAA;AAAA,UACC;AAAA,UACA,WAAW,IAAI;AAAA,UACf;AAAA,UACA;AAAA,UACA;AAAA;AAAA,MACF;AAAA;AAAA,EACF;AAEJ;AAEA,MAAM,qBAAiB,4DAA0B,GAAG;",
6
6
  "names": []
7
7
  }
@@ -38,7 +38,7 @@ var import_uid = require("uid");
38
38
  var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
39
39
  var import_exported_related = require("./exported-related/index.js");
40
40
  var import_constants = require("./configs/constants.js");
41
- var import_DSDataTableDefinitions = require("./DSDataTableDefinitions.js");
41
+ var import_constants2 = require("./constants/index.js");
42
42
  const defaultProps = () => ({
43
43
  height: "100%",
44
44
  width: "100%",
@@ -79,7 +79,7 @@ const defaultProps = () => ({
79
79
  domIdAffix: (0, import_uid.uid)(4)
80
80
  });
81
81
  const DSDataTablePropTypes = {
82
- ...(0, import_ds_props_helpers.getPropsPerSlotPropTypes)(import_DSDataTableDefinitions.DSDataTableName, import_DSDataTableDefinitions.DSDataTableSlots),
82
+ ...(0, import_ds_props_helpers.getPropsPerSlotPropTypes)(import_constants2.DSDataTableName, import_constants2.DSDataTableSlots),
83
83
  columns: import_ds_props_helpers.PropTypes.arrayOf(
84
84
  import_ds_props_helpers.PropTypes.shape({
85
85
  Header: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.string, import_ds_props_helpers.PropTypes.func, import_ds_props_helpers.PropTypes.node]).description(
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/react-desc-prop-types.ts", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable max-lines */\n/* eslint-disable @typescript-eslint/no-empty-interface */\nimport { uid } from 'uid';\nimport type { WeakValidationMap } from 'react';\nimport type { Range, useVirtual } from 'react-virtual/types';\nimport type { ZustandT } from '@elliemae/ds-zustand-helpers';\nimport type { DSPaginationT } from '@elliemae/ds-pagination';\nimport { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { DnDKitTree, useSortable } from '@elliemae/ds-drag-and-drop';\nimport type { DSControlledCheckboxT } from '@elliemae/ds-form-checkbox';\nimport type { DSComboboxT } from '@elliemae/ds-form-combobox';\nimport { PropTypes, getPropsPerSlotPropTypes } from '@elliemae/ds-props-helpers';\nimport { FILTER_TYPES } from './exported-related/index.js';\nimport { type DropIndicatorPosition, ColsLayoutStyle } from './configs/constants.js';\nimport { DSDataTableName, DSDataTableSlots } from './DSDataTableDefinitions.js';\n\nexport namespace DSDataTableT {\n // ===========================================================================\n // Typescript definition for auxiliary types\n // ===========================================================================\n type PropsT<D, R, O> = Partial<D> & R & O;\n\n type InternalPropsT<D, R, O> = D & R & O;\n\n // ===========================================================================\n // Typescript definition for zustand store\n // ===========================================================================\n\n export type InternalAtoms = {\n drilldownRowId: string | null;\n focusedRowId: string | null;\n isShiftPressed: boolean;\n reduxHeaders: Record<string, ReduxHeader>;\n isHeaderCellDragging: boolean;\n };\n export type UseAutoCalculatedT = {\n /**\n * visibleRangeRef: React.MutableRefObject<Range>\n * We can use this ref to get the visible range of the virtual list\n * taking in consideration the end-start and overscan.\n */\n visibleRangeRef: React.MutableRefObject<Range>;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: ReturnType<typeof useVirtual>;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n lastSelected: React.MutableRefObject<number>;\n bodyClientWidth: number | string;\n setBodyClientWidth: React.Dispatch<React.SetStateAction<number | string>>;\n };\n export type Selectors = Record<string, never>;\n export type Reducers = {\n patchHeader: (headerId: string, newHeader: Partial<ReduxHeader>) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n };\n export type ShuttleInternalStore = ZustandT.InternalStore<InternalAtoms, Selectors, Reducers>;\n\n // ===========================================================================\n // Typescript definition for data table related things\n // ===========================================================================\n\n export interface Filter {\n id: string;\n type: string;\n value: unknown;\n }\n\n export type FilterFn<T> = (unfilteredData: Row[], filterKey: string, filterValue: T) => Row[];\n export type FilterFnOutOfTheBoxCurrencyRange = DSDataTableT.FilterFn<{ from: string; to: string }>;\n export type FilterFnOutOfTheBoxDateRange = DSDataTableT.FilterFn<{ startDate: string; endDate: string }>;\n export type FilterFnOutOfTheBoxDateSwitcher = DSDataTableT.FilterFn<{\n startDate: string;\n endDate: string;\n isDateRange: boolean;\n }>;\n export type FilterFnOutOfTheBoxMultiSelect = DSDataTableT.FilterFn<{ label: string; value: string }[]>;\n export type FilterFnOutOfTheBoxNumberRange = DSDataTableT.FilterFn<{ from?: number; to?: number }>;\n export type FilterFnOutOfTheBoxSingleDate = DSDataTableT.FilterFn<string>;\n export type FilterFnOutOfTheBoxSingleSelect = DSDataTableT.FilterFn<{ label: string; value: string }>;\n export type FilterFnOutOfTheBoxFreeTextSearch = DSDataTableT.FilterFn<string>;\n export interface FilterItemProps {\n column: InternalColumn;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n referenceColumn?: HTMLDivElement | null;\n }\n\n export interface FilterProps<T> {\n column: InternalColumn;\n referenceColumn?: HTMLDivElement | null;\n onValueChange: (type: string, value: T | undefined) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, newState: boolean) => void;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n filterValue: T;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n domIdAffix?: string;\n }\n\n export interface FilterPillProps<T> {\n columnHeader: string;\n column: string;\n value: T;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n prevRef: React.RefObject<HTMLElement>;\n innerRef: React.RefObject<HTMLElement>;\n nextRef: React.RefObject<HTMLElement>;\n }\n\n export interface ReduxHeader {\n hideFilterMenu?: boolean;\n hideFilterButton?: boolean;\n showDnDHandle?: boolean;\n withTabStops?: boolean;\n showSortCaret?: boolean;\n }\n\n export type SelectionItem = boolean | 'mixed';\n\n export type Selection = Record<string | number, SelectionItem>;\n\n export type UniqueRowAccessorType = string | string[] | ((row: Row) => string) | undefined;\n\n export interface SortBy {\n id: string;\n desc: boolean;\n }\n\n export interface Pagination extends DSPaginationT.Props {\n hasPagination: boolean;\n pageIndex?: number;\n canPreviousPage?: boolean;\n canNextPage?: boolean;\n pageSize?: number;\n dataIsPage?: boolean;\n showPerPageSelector?: boolean;\n perPageOptions?: number[];\n perPageStep?: number;\n minPerPage?: number;\n maxPerPage?: number;\n onPageSizeChange?: (pageSize: number) => void;\n onPreviousPage?: () => void;\n onNextPage?: () => void;\n onPageChange?: (page: number) => void;\n pageCount?: number | string;\n isLoadingPageCount?: boolean;\n pageDetails?: string[];\n pageDetailsTitle?: string;\n }\n\n export type RowVariant = 'ds-header-group-row' | 'ds-primary-row' | 'ds-secondary-row';\n\n export interface RenderRowActionsConfig {\n columnWidth: number;\n renderer: React.ComponentType<CellProps>;\n }\n\n export type RenderRowActions = false | RenderRowActionsConfig;\n\n export type DropIndicatorPositionValues = TypescriptHelpersT.ObjectValues<typeof DropIndicatorPosition>;\n\n export type ColsLayoutStyleValues = TypescriptHelpersT.ObjectValues<typeof ColsLayoutStyle>;\n\n export type DraggablePropsT =\n | false\n | (ReturnType<typeof useSortable> & {\n dropIndicatorPosition: DropIndicatorPositionValues;\n shouldShowDropIndicatorPosition: boolean;\n isDropValid: boolean;\n });\n\n export type FilterOptionT = DSComboboxT.Props['allOptions'][number];\n export type EditOptionT = DSComboboxT.Props['allOptions'][number];\n\n // ===========================================================================\n // Typescript definition for the row and columns\n // ===========================================================================\n\n export interface Row {\n [key: string]: unknown;\n id: string;\n subRows?: Row[];\n tableRowDetails?: React.ComponentType<DetailsProps>;\n dimsumHeaderValue?: string;\n }\n export interface EditableCellProps<T extends HTMLElement = HTMLElement> extends CellProps<T> {\n DefaultCellRender: JSX.Element;\n }\n\n export interface Column {\n id?: string;\n Header: string | React.ComponentType<HeaderProps>;\n accessor?: string;\n filter?: string;\n filterOptions?: FilterOptionT[] | (() => FilterOptionT[]);\n disableFirstOptionFocusOnFilter?: boolean;\n editOptions?: EditOptionT[] | (() => EditOptionT[]);\n filterMinWidth?: number | string;\n Filter?: React.ComponentType<FilterProps<unknown>>;\n Cell?: React.ComponentType<CellRendererProps>;\n editable?: string | React.ComponentType<EditableCellProps>;\n disableDnD?: boolean;\n width?: number;\n minWidth?: number;\n maxWidth?: number;\n padding?: number;\n columns?: Column[];\n canSort?: boolean;\n isSortedDesc?: boolean;\n canResize?: boolean;\n isFocuseable?: boolean;\n textWrap?: 'wrap' | 'wrap-all' | 'truncate';\n ref?: React.MutableRefObject<HTMLTableColElement | null>;\n required?: boolean;\n cellStyle?: React.CSSProperties;\n alwaysDisplayEditIcon?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the row and columns\n // ===========================================================================\n\n export interface InternalRow {\n id: string;\n uid: string;\n index: number;\n realIndex: number;\n parent: InternalRow | null;\n parentId: string | null;\n parentIndex: number | null;\n depth: number;\n isExpanded: boolean;\n subRows: Row[];\n childrenCount: number;\n original: Row;\n cells: Cell[];\n }\n\n export interface InternalColumn extends Column {\n index: number;\n id: string;\n parentId: string | null;\n depth: number;\n ref: React.MutableRefObject<HTMLTableColElement | null>;\n columns?: InternalColumn[];\n persistFilterInputAfterSubmit?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the cell\n // ===========================================================================\n\n export interface CellRendererProps {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n // cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n domIdAffix?: string;\n }\n\n export interface Cell<T extends HTMLElement = HTMLElement> {\n column: InternalColumn;\n value: unknown;\n render: React.ComponentType<CellRendererProps>;\n row: InternalRow;\n ref: React.MutableRefObject<T | null>;\n id: string;\n }\n\n // ===========================================================================\n // Typescript definition for all component props\n // ===========================================================================\n\n export interface HeaderProps {\n column: InternalColumn;\n draggableProps: DraggablePropsT;\n }\n\n export interface CellProps<T extends HTMLElement = HTMLElement> {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell<T>;\n domIdAffix?: string;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n }\n\n export interface DetailsProps {\n detailsIndent: number;\n row: InternalRow;\n }\n export interface RowVariantProps {\n row: DSDataTableT.InternalRow;\n itemIndex: number;\n isDragOverlay: boolean;\n focusedRowId: string | null;\n drilldownRowId: string | null;\n }\n\n // ===========================================================================\n // Typescript definition for the React Context\n // ===========================================================================\n\n export interface Context {\n tableProps: InternalProps;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: ReturnType<typeof useVirtual>;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n drilldownRowId: string | null;\n setDrilldownRowId: React.Dispatch<React.SetStateAction<string | null>>;\n focusedRowId: string | null;\n setFocusedRowId: React.Dispatch<React.SetStateAction<string | null>>;\n reduxHeaders: Record<string, ReduxHeader>;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n isShiftPressed: boolean;\n setIsShiftPressed: React.Dispatch<React.SetStateAction<boolean>>;\n lastSelected: React.MutableRefObject<number>;\n isHeaderCellDragging: boolean;\n setIsHeaderCellDragging: React.Dispatch<React.SetStateAction<boolean>>;\n }\n\n export interface DefaultProps {\n height: string;\n width: string;\n renderRowActions: false | RenderRowActionsConfig;\n getRowVariant: (\n row: InternalRow,\n defaultCellRenderer: React.ComponentType<{\n row: DSDataTableT.InternalRow;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n }>,\n ) => RowVariant | React.ComponentType<RowVariantProps>;\n withFilterBar: boolean;\n isExpandable: boolean;\n expandedRows: Record<string, boolean>;\n disabledRows: Record<string, boolean>;\n isResizeable: boolean;\n isLoading: boolean;\n pagination: false | Pagination;\n filters: Filter[];\n colsLayoutStyle: ColsLayoutStyleValues;\n hiddenColumns: string[];\n noResultsMessage: string;\n dragAndDropRows: boolean;\n maxDragAndDropLevel: number;\n onRowsReorder: (\n newData: Row[],\n indexes: { targetIndex: number; fromIndex: number },\n considerExpanding: string | null,\n extraData: { flattenedData: InternalRow[]; allDataFlattened: InternalRow[] },\n ) => void;\n dragAndDropColumns: boolean;\n onColumnsReorder: (newData: Column[], indexes: { targetIndex: number; fromIndex: number }) => void;\n getIsDropValid: (\n active: DnDKitTree.Item<Row>,\n over: DnDKitTree.Item<Row>,\n dropIndicatorPosition: DropIndicatorPositionValues,\n ) => boolean;\n onColumnResize: (headerId: string, width: number) => void;\n onColumnSizeChange: (newColumns: Column[], headerId: string, width: number) => void;\n onRowClick: TypescriptHelpersT.GenericFunc;\n onRowFocus: TypescriptHelpersT.GenericFunc;\n noSelectionColumn: boolean;\n selectSingle: boolean;\n onSelectionChange: (\n newSelection: Selection,\n selectedControl: string,\n event: React.ChangeEvent | React.MouseEvent | React.KeyboardEvent,\n ) => void;\n textWrap: 'wrap' | 'wrap-all' | 'truncate';\n onCellValueChange: (cellChange: { value: unknown; property: unknown; rowIndex: number }) => void;\n onFiltersChange: TypescriptHelpersT.GenericFunc;\n onPageChanged: TypescriptHelpersT.GenericFunc;\n onRowExpand: (expandedRows: Record<string, boolean>, toggledRow: string) => void;\n onColumnSortChange: (newSortRequest: { column: unknown; direction: unknown }) => void;\n onColumnSort: (newColumns: Column[], headerId: string, direction: 'ASC' | 'DESC') => void;\n isSkeleton: boolean;\n domIdAffix?: string;\n }\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSDataTableName, typeof DSDataTableSlots> {\n uniqueRowAccessor?: UniqueRowAccessorType;\n cellRendererProps?: Record<string, unknown>;\n selection?: Selection;\n groupedRowsRenderHeader?:\n | ((dimsumHeaderValue: string | undefined, subRows: Row[] | undefined) => JSX.Element)\n | string;\n filterBarProps?: {\n filterBarAddonRenderer?: React.ComponentType<{ innerRef: React.MutableRefObject<HTMLButtonElement | null> }>;\n customPillRenderer?: React.ComponentType<FilterPillProps<unknown>>;\n onClearAllFiltersClick?: () => void;\n onDropdownMenuToggle?: (isOpen: boolean, eventType: string) => void;\n onDropdownMenuClickOutside?: () => void;\n onDropdownMenuTriggerClick?: () => void;\n isDropdownMenuOpen?: boolean;\n extraOptions?: { type: string; id: string; label: string; onClick?: TypescriptHelpersT.GenericFunc }[];\n };\n actionRef?: React.MutableRefObject<{\n scrollToIndex: ReturnType<typeof useVirtual>['scrollToIndex'];\n scrollToOffset: ReturnType<typeof useVirtual>['scrollToOffset'];\n }>;\n noResultsSecondaryMessage?: string;\n noResultsButtonLabel?: string;\n noResultsPlaceholder?: React.ReactElement;\n onNoResultsButtonClick?: TypescriptHelpersT.GenericFunc;\n onTableResize?: TypescriptHelpersT.GenericFunc;\n Pagination?: React.ComponentType<Record<string, never>>;\n getAriaLabelForRow?: (args: {\n row: InternalRow;\n selected: boolean;\n disabled: boolean;\n expandable: boolean;\n expanded: boolean;\n }) => string;\n checkboxSelectAllProps?: DSControlledCheckboxT.Props;\n }\n export interface RequiredProps {\n columns: Column[];\n data: Row[];\n }\n\n export type Props = PropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type InternalProps = InternalPropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type GetOwnerPropsT = () => ZustandT.PropsStore<\n DefaultProps & RequiredProps & OptionalProps & UseAutoCalculatedT\n >;\n}\n\n// default props is a function to ensure that the uid is unique for each instance of the component\n// this is supported by the useMemoMergePropsWithDefault function.\nexport const defaultProps: () => DSDataTableT.DefaultProps = () => ({\n height: '100%',\n width: '100%',\n renderRowActions: false,\n getRowVariant: () => 'ds-primary-row',\n isExpandable: false,\n expandedRows: {},\n disabledRows: {},\n isResizeable: false,\n isLoading: false,\n pagination: false,\n withFilterBar: false,\n filters: [],\n getIsDropValid: () => true,\n onColumnResize: () => null,\n onColumnSortChange: () => null,\n colsLayoutStyle: ColsLayoutStyle.Fixed,\n hiddenColumns: [],\n noResultsMessage: 'No Results Found',\n dragAndDropRows: false,\n maxDragAndDropLevel: 1,\n onRowsReorder: () => null,\n dragAndDropColumns: false,\n onColumnsReorder: () => null,\n onColumnSizeChange: () => null,\n onRowClick: () => null,\n onRowFocus: () => null,\n noSelectionColumn: false,\n selectSingle: false,\n onSelectionChange: () => null,\n textWrap: 'wrap',\n onCellValueChange: () => null,\n onFiltersChange: () => null,\n onPageChanged: () => null,\n onRowExpand: () => null,\n onColumnSort: () => null,\n isSkeleton: false,\n domIdAffix: uid(4),\n});\n\nexport const DSDataTablePropTypes = {\n ...getPropsPerSlotPropTypes(DSDataTableName, DSDataTableSlots),\n columns: PropTypes.arrayOf(\n PropTypes.shape({\n Header: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'Header name or component',\n ).isRequired,\n accessor: PropTypes.string.description('The entry of the data that this column will display'),\n id: PropTypes.string.description('The id of the column, will default to the Header or accessor if not present'),\n filter: PropTypes.oneOf(Object.values(FILTER_TYPES)).description('out-of-the-box filters'),\n Filter: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'The custom component to render as a filter',\n ),\n Cell: PropTypes.oneOfType([PropTypes.object, PropTypes.func]).description('The custom cell renderer component'),\n editable: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'The editable out-of-the-box or component to render',\n ),\n disableDnD: PropTypes.bool.description('Whereas this column should be draggable'),\n canResize: PropTypes.bool.description('Whereas this column should be resizable'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of this column'),\n minWidth: PropTypes.number.description('Minimum width of this column, useful when resizing'),\n maxWidth: PropTypes.number.description('Maximum width of this column, useful when resizing'),\n canSort: PropTypes.bool.description('Whereas this column is sortable'),\n disableFirstOptionFocusOnFilter: PropTypes.bool.description(\n 'Whereas the first option should not be focused on filter',\n ),\n filterMinWidth: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description(\n 'Minimum width of the filter',\n ),\n filterOptions: PropTypes.arrayOf(\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.string,\n label: PropTypes.string,\n }),\n ).description('Filter options'),\n isSortedDesc: PropTypes.bool.description('Whereas this column is sorted descendingly'),\n required: PropTypes.bool.description('Whereas this column is required'),\n alwaysDisplayEditIcon: PropTypes.bool.description(\n 'Whereas to always show the edit icon on this column if it is editable',\n ),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('How to wrap the text in the column'),\n }),\n ).description('Array of columns').isRequired,\n data: PropTypes.arrayOf(\n PropTypes.shape({\n tableRowDetails: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description('Component for row details'),\n dimsumHeaderValue: PropTypes.string.description('Header displayed on the header variant of the row'),\n }),\n ).description('Array of rows'),\n height: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Height of the datatable component'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of the datatable component'),\n renderRowActions: PropTypes.oneOfType([PropTypes.object, PropTypes.bool]).description(\n 'The renderer to use for the action toolbar',\n ),\n isExpandable: PropTypes.bool.description('Whether the datatable is expandable').defaultValue(false),\n uniqueRowAccessor: PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.arrayOf(PropTypes.string),\n PropTypes.func,\n ]).description(\n 'Column / Combination of columns / Function to call to produce a unique identifier for each row.' +\n ' This is necessary for the selectable and drag and drop features',\n ),\n disabledRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is disabled or not',\n ),\n expandedRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is expanded or not',\n ),\n onRowExpand: PropTypes.func.description('Function invoked when a row is (un)expanded'),\n cellRendererProps: PropTypes.object.description(\n 'Object with all the props you want the cells to have available when rendering',\n ),\n selectSingle: PropTypes.bool.description('Whether the selectable feature is single').defaultValue(false),\n selection: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is selected or not',\n ),\n onSelectionChange: PropTypes.func.description('Function invoked when a row is selected'),\n groupedRowsRenderHeader: PropTypes.oneOfType([PropTypes.string, PropTypes.func]).description(\n 'String | Function to call which will display in the row headers',\n ),\n isResizeable: PropTypes.bool.description(\"Whether the datatable's columns are resizeable\"),\n filters: PropTypes.arrayOf(\n PropTypes.shape({\n id: PropTypes.string,\n type: PropTypes.string,\n value: PropTypes.any,\n }),\n ).description('Array of filter keys and values'),\n withFilterBar: PropTypes.bool.description('Whether to display the filter bar'),\n filterBarProps: PropTypes.shape({\n filterBarAddonRenderer: PropTypes.func.description('Render filterbar right addon component'),\n customPillRenderer: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'If you specify custom filters, you will need to render their pills here',\n ),\n isDropdownMenuOpen: PropTypes.bool.description('Wether the DropdownMenu is Open or not.'),\n onDropdownMenuToggle: PropTypes.func.description('Callback to toggle the DropdownMenu.'),\n onClearAllFiltersClick: PropTypes.func.description('Callback for Clear Al Filters option.'),\n onDropdownMenuClickOutside: PropTypes.func.description('Callback triggered when clicking outside DropdownMenu.'),\n onDropdownMenuTriggerClick: PropTypes.func.description('Callback triggered when clicking DropdownMenu ellipsis.'),\n extraOptions: PropTypes.arrayOf(\n PropTypes.shape({\n type: PropTypes.string,\n id: PropTypes.string,\n label: PropTypes.string,\n onClick: PropTypes.func,\n }),\n ).description('Any extra option you want in the dropdownmenu of the filter bar'),\n }).description('Props for the filter bar'),\n onFiltersChange: PropTypes.func.description('Function invoked when filters change'),\n pagination: PropTypes.oneOfType([\n PropTypes.oneOf([false]),\n PropTypes.shape({\n pageCount: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('How many pages are there'),\n isLoadingPageCount: PropTypes.bool.description('Whether the page count is loading'),\n pageIndex: PropTypes.number.description('Index of the current page, starting from 1').defaultValue(1),\n canPreviousPage: PropTypes.bool.description('Whether the previous button is disabled or not').defaultValue(true),\n canNextPage: PropTypes.bool.description('Whether the next button is disabled or not').defaultValue(true),\n pageSize: PropTypes.number.description('The current page size').defaultValue(10),\n showPerPageSelector: PropTypes.bool.description('Whether to show the page selector').defaultValue(true),\n perPageOptions: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.number,\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.number,\n label: PropTypes.string,\n type: PropTypes.oneOf(['single']),\n }),\n ]),\n )\n .description('The available options for page size')\n .defaultValue([10]),\n perPageStep: PropTypes.number.description('Step for the per page options').defaultValue(5),\n minPerPage: PropTypes.number.description('Step for the per page options').defaultValue(0),\n maxPerPage: PropTypes.number.description('Step for the per page options').defaultValue(100),\n onPageSizeChange: PropTypes.func\n .description('Function invoked when the page size changes')\n .defaultValue(() => null),\n onPreviousPage: PropTypes.func\n .description('Function invoked when the previous button is pressed')\n .defaultValue(() => null),\n onPageChange: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNextPage: PropTypes.func.description('Function invoked when next button is pressed').defaultValue(() => null),\n pageDetails: PropTypes.arrayOf(PropTypes.string).description('Details to provide for each page').defaultValue([]),\n dataIsPage: PropTypes.bool.description('Whether to treat data as a page').defaultValue(false),\n pageDetailsTitle: PropTypes.string\n .description('The title of the details (usually a column of your dataset)')\n .defaultValue(''),\n }),\n ]).description('Object containing the data for the pagination'),\n Pagination: PropTypes.func.description('Custom component to show in place of the pagination'),\n colsLayoutStyle: PropTypes.oneOf(['auto', 'fixed']).description('Whether the datatable fills its container or not'),\n hiddenColumns: PropTypes.arrayOf(PropTypes.string).description('IDs of columns not to render'),\n dragAndDropRows: PropTypes.bool.description('Whether to turn on the d&d feature for the rows').defaultValue(false),\n onRowsReorder: PropTypes.func.description('Function invoked when a row is reordered'),\n maxDragAndDropLevel: PropTypes.number.description('Which level is the maximum allowed to drop into'),\n dragAndDropColumns: PropTypes.bool.description('Whether to turn on the d&d feature for the columns'),\n onColumnsReorder: PropTypes.func.description('Function invoked when a column is reordered'),\n getIsDropValid: PropTypes.func.description('Function to determine if a drop is valid'),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('Global wrapping rule'),\n noResultsMessage: PropTypes.string.description('Message to show when no more data is available'),\n noResultsSecondaryMessage: PropTypes.string.description('Secondary message to show when no more data is available'),\n noResultsButtonLabel: PropTypes.string.description('Label of the button when no more data is available'),\n noResultsPlaceholder: PropTypes.oneOfType([PropTypes.node]).description(\n 'Custom content to show when dataset is empty',\n ),\n isLoading: PropTypes.bool.description('Whether to show a global loader in the datatable'),\n onColumnResize: PropTypes.func\n .description('Function invoked when a column is resized')\n .deprecated({ version: '4.x', message: 'Use onColumnSizeChange' }),\n onColumnSizeChange: PropTypes.func.description('Function invoked when a column is resized'),\n onRowClick: PropTypes.func.description('Function invoked when clicking a row'),\n onRowFocus: PropTypes.func.description('Function invoked when focusing a row'),\n onCellValueChange: PropTypes.func.description(\"Function invoked when an editable cell's content is changed\"),\n onColumnSortChange: PropTypes.func\n .description('Function invoked when a column is sorted')\n .deprecated({ version: '4.x', message: 'Use onColumnSort' }),\n onColumnSort: PropTypes.func.description('Function invoked when a column is sorted'),\n onTableResize: PropTypes.func.description(\n 'Function invoked when the size of the internal table changes, e.g. when a the browser window is resized',\n ),\n actionRef: PropTypes.object.description('Reference where all the exposed action callbacks will be exposed'),\n getRowVariant: PropTypes.func\n .description(\"Function invoked to determine a row's variant\")\n .defaultValue(`() => 'ds-primary-row'`),\n noSelectionColumn: PropTypes.bool.description('Whether to show the selection column or not').defaultValue(false),\n onPageChanged: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNoResultsButtonClick: PropTypes.func\n .description('Function invoked when the no results button is clicked')\n .defaultValue(() => null),\n isSkeleton: PropTypes.bool.description('Whether to show a skeleton loader in the datatable'),\n getAriaLabelForRow: PropTypes.func.description('Function invoked to determine a row aria-label'),\n domIdAffix: PropTypes.string\n .description('Affix to avoid duplicate ids')\n .defaultValue('4 randomly generated characters'),\n checkboxSelectAllProps: PropTypes.object.description('Props for the select all checkbox'),\n};\n\nexport const DSDataTablePropTypesSchema = DSDataTablePropTypes as unknown as WeakValidationMap<DSDataTableT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,iBAAoB;AASpB,8BAAoD;AACpD,8BAA6B;AAC7B,uBAA4D;AAC5D,oCAAkD;AAmc3C,MAAM,eAAgD,OAAO;AAAA,EAClE,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,kBAAkB;AAAA,EAClB,eAAe,MAAM;AAAA,EACrB,cAAc;AAAA,EACd,cAAc,CAAC;AAAA,EACf,cAAc,CAAC;AAAA,EACf,cAAc;AAAA,EACd,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,eAAe;AAAA,EACf,SAAS,CAAC;AAAA,EACV,gBAAgB,MAAM;AAAA,EACtB,gBAAgB,MAAM;AAAA,EACtB,oBAAoB,MAAM;AAAA,EAC1B,iBAAiB,iCAAgB;AAAA,EACjC,eAAe,CAAC;AAAA,EAChB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AAY,+CAA+C,EAC3D,aAAa,wBAAwB;AAAA,EACxC,mBAAmB,kCAAU,KAAK,YAAY,6CAA6C,EAAE,aAAa,KAAK;AAAA,EAC/G,eAAe,kCAAU,KAAK,YAAY,wCAAwC,EAAE,aAAa,MAAM,IAAI;AAAA,EAC3G,wBAAwB,kCAAU,KAC/B,YAAY,wDAAwD,EACpE,aAAa,MAAM,IAAI;AAAA,EAC1B,YAAY,kCAAU,KAAK,YAAY,oDAAoD;AAAA,EAC3F,oBAAoB,kCAAU,KAAK,YAAY,gDAAgD;AAAA,EAC/F,YAAY,kCAAU,OACnB,YAAY,8BAA8B,EAC1C,aAAa,iCAAiC;AAAA,EACjD,wBAAwB,kCAAU,OAAO,YAAY,mCAAmC;AAC1F;AAEO,MAAM,6BAA6B;",
6
- "names": []
4
+ "sourcesContent": ["/* eslint-disable max-lines */\n/* eslint-disable @typescript-eslint/no-empty-interface */\nimport { uid } from 'uid';\nimport type { Range, useVirtual } from 'react-virtual/types';\nimport type { ZustandT } from '@elliemae/ds-zustand-helpers';\nimport type { DSPaginationT } from '@elliemae/ds-pagination';\nimport { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { DnDKitTree, useSortable } from '@elliemae/ds-drag-and-drop';\nimport type { DSControlledCheckboxT } from '@elliemae/ds-form-checkbox';\nimport type { DSComboboxT } from '@elliemae/ds-form-combobox';\nimport {\n PropTypes,\n getPropsPerSlotPropTypes,\n type DSPropTypesSchema,\n type ValidationMap,\n} from '@elliemae/ds-props-helpers';\nimport { FILTER_TYPES } from './exported-related/index.js';\nimport { type DropIndicatorPosition, ColsLayoutStyle } from './configs/constants.js';\nimport { DSDataTableName, DSDataTableSlots } from './constants/index.js';\nexport namespace DSDataTableT {\n // ===========================================================================\n // Typescript definition for auxiliary types\n // ===========================================================================\n type PropsT<D, R, O> = Partial<D> & R & O;\n\n type InternalPropsT<D, R, O> = D & R & O;\n\n // ===========================================================================\n // Typescript definition for zustand store\n // ===========================================================================\n\n export type InternalAtoms = {\n drilldownRowId: string | null;\n focusedRowId: string | null;\n isShiftPressed: boolean;\n reduxHeaders: Record<string, ReduxHeader>;\n isHeaderCellDragging: boolean;\n };\n export type UseAutoCalculatedT = {\n /**\n * visibleRangeRef: React.MutableRefObject<Range>\n * We can use this ref to get the visible range of the virtual list\n * taking in consideration the end-start and overscan.\n */\n visibleRangeRef: React.MutableRefObject<Range>;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: ReturnType<typeof useVirtual>;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n lastSelected: React.MutableRefObject<number>;\n bodyClientWidth: number | string;\n setBodyClientWidth: React.Dispatch<React.SetStateAction<number | string>>;\n };\n export type Selectors = Record<string, never>;\n export type Reducers = {\n patchHeader: (headerId: string, newHeader: Partial<ReduxHeader>) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n };\n export type ShuttleInternalStore = ZustandT.InternalStore<InternalAtoms, Selectors, Reducers>;\n\n // ===========================================================================\n // Typescript definition for data table related things\n // ===========================================================================\n\n export interface Filter {\n id: string;\n type: string;\n value: unknown;\n }\n\n export type FilterFn<T> = (unfilteredData: Row[], filterKey: string, filterValue: T) => Row[];\n export type FilterFnOutOfTheBoxCurrencyRange = DSDataTableT.FilterFn<{ from: string; to: string }>;\n export type FilterFnOutOfTheBoxDateRange = DSDataTableT.FilterFn<{ startDate: string; endDate: string }>;\n export type FilterFnOutOfTheBoxDateSwitcher = DSDataTableT.FilterFn<{\n startDate: string;\n endDate: string;\n isDateRange: boolean;\n }>;\n export type FilterFnOutOfTheBoxMultiSelect = DSDataTableT.FilterFn<{ label: string; value: string }[]>;\n export type FilterFnOutOfTheBoxNumberRange = DSDataTableT.FilterFn<{ from?: number; to?: number }>;\n export type FilterFnOutOfTheBoxSingleDate = DSDataTableT.FilterFn<string>;\n export type FilterFnOutOfTheBoxSingleSelect = DSDataTableT.FilterFn<{ label: string; value: string }>;\n export type FilterFnOutOfTheBoxFreeTextSearch = DSDataTableT.FilterFn<string>;\n export interface FilterItemProps {\n column: InternalColumn;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n referenceColumn?: HTMLDivElement | null;\n }\n\n export interface FilterProps<T> {\n column: InternalColumn;\n referenceColumn?: HTMLDivElement | null;\n onValueChange: (type: string, value: T | undefined) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, newState: boolean) => void;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n filterValue: T;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n domIdAffix?: string;\n }\n\n export interface FilterPillProps<T> {\n columnHeader: string;\n column: string;\n value: T;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n prevRef: React.RefObject<HTMLElement>;\n innerRef: React.RefObject<HTMLElement>;\n nextRef: React.RefObject<HTMLElement>;\n }\n\n export interface ReduxHeader {\n hideFilterMenu?: boolean;\n hideFilterButton?: boolean;\n showDnDHandle?: boolean;\n withTabStops?: boolean;\n showSortCaret?: boolean;\n }\n\n export type SelectionItem = boolean | 'mixed';\n\n export type Selection = Record<string | number, SelectionItem>;\n\n export type UniqueRowAccessorType = string | string[] | ((row: Row) => string) | undefined;\n\n export interface SortBy {\n id: string;\n desc: boolean;\n }\n\n export interface Pagination extends DSPaginationT.Props {\n hasPagination: boolean;\n pageIndex?: number;\n canPreviousPage?: boolean;\n canNextPage?: boolean;\n pageSize?: number;\n dataIsPage?: boolean;\n showPerPageSelector?: boolean;\n perPageOptions?: number[];\n perPageStep?: number;\n minPerPage?: number;\n maxPerPage?: number;\n onPageSizeChange?: (pageSize: number) => void;\n onPreviousPage?: () => void;\n onNextPage?: () => void;\n onPageChange?: (page: number) => void;\n pageCount?: number | string;\n isLoadingPageCount?: boolean;\n pageDetails?: string[];\n pageDetailsTitle?: string;\n }\n\n export type RowVariant = 'ds-header-group-row' | 'ds-primary-row' | 'ds-secondary-row';\n\n export interface RenderRowActionsConfig {\n columnWidth: number;\n renderer: React.ComponentType<CellProps>;\n }\n\n export type RenderRowActions = false | RenderRowActionsConfig;\n\n export type DropIndicatorPositionValues = TypescriptHelpersT.ObjectValues<typeof DropIndicatorPosition>;\n\n export type ColsLayoutStyleValues = TypescriptHelpersT.ObjectValues<typeof ColsLayoutStyle>;\n\n export type DraggablePropsT =\n | false\n | (ReturnType<typeof useSortable> & {\n dropIndicatorPosition: DropIndicatorPositionValues;\n shouldShowDropIndicatorPosition: boolean;\n isDropValid: boolean;\n });\n\n export type FilterOptionT = DSComboboxT.Props['allOptions'][number];\n export type EditOptionT = DSComboboxT.Props['allOptions'][number];\n\n // ===========================================================================\n // Typescript definition for the row and columns\n // ===========================================================================\n\n export interface Row {\n [key: string]: unknown;\n id: string;\n subRows?: Row[];\n tableRowDetails?: React.ComponentType<DetailsProps>;\n dimsumHeaderValue?: string;\n }\n export interface EditableCellProps<T extends HTMLElement = HTMLElement> extends CellProps<T> {\n DefaultCellRender: JSX.Element;\n }\n\n export interface Column {\n id?: string;\n Header: string | React.ComponentType<HeaderProps>;\n accessor?: string;\n filter?: string;\n filterOptions?: FilterOptionT[] | (() => FilterOptionT[]);\n disableFirstOptionFocusOnFilter?: boolean;\n editOptions?: EditOptionT[] | (() => EditOptionT[]);\n filterMinWidth?: number | string;\n Filter?: React.ComponentType<FilterProps<unknown>>;\n Cell?: React.ComponentType<CellRendererProps>;\n editable?: string | React.ComponentType<EditableCellProps>;\n disableDnD?: boolean;\n width?: number;\n minWidth?: number;\n maxWidth?: number;\n padding?: number;\n columns?: Column[];\n canSort?: boolean;\n isSortedDesc?: boolean;\n canResize?: boolean;\n isFocuseable?: boolean;\n textWrap?: 'wrap' | 'wrap-all' | 'truncate';\n ref?: React.MutableRefObject<HTMLTableColElement | null>;\n required?: boolean;\n cellStyle?: React.CSSProperties;\n alwaysDisplayEditIcon?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the row and columns\n // ===========================================================================\n\n export interface InternalRow {\n id: string;\n uid: string;\n index: number;\n realIndex: number;\n parent: InternalRow | null;\n parentId: string | null;\n parentIndex: number | null;\n depth: number;\n isExpanded: boolean;\n subRows: Row[];\n childrenCount: number;\n original: Row;\n cells: Cell[];\n }\n\n export interface InternalColumn extends Column {\n index?: number;\n id: string;\n parentId: string | null;\n depth: number;\n ref: React.MutableRefObject<HTMLTableColElement | null>;\n columns?: InternalColumn[];\n persistFilterInputAfterSubmit?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the cell\n // ===========================================================================\n\n export interface CellRendererProps {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n // cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n domIdAffix?: string;\n }\n\n export interface Cell<T extends HTMLElement = HTMLElement> {\n column: InternalColumn;\n value: unknown;\n render: React.ComponentType<CellRendererProps>;\n row: InternalRow;\n ref: React.MutableRefObject<T | null>;\n id: string;\n }\n\n // ===========================================================================\n // Typescript definition for all component props\n // ===========================================================================\n\n export interface HeaderProps {\n column: InternalColumn;\n draggableProps: DraggablePropsT;\n }\n\n export interface CellProps<T extends HTMLElement = HTMLElement> {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell<T>;\n domIdAffix?: string;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n }\n\n export interface DetailsProps {\n detailsIndent: number;\n row: InternalRow;\n }\n export interface RowVariantProps {\n row: DSDataTableT.InternalRow;\n itemIndex: number;\n isDragOverlay: boolean;\n focusedRowId: string | null;\n drilldownRowId: string | null;\n }\n\n // ===========================================================================\n // Typescript definition for the React Context\n // ===========================================================================\n\n export interface Context {\n tableProps: InternalProps;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: ReturnType<typeof useVirtual>;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n drilldownRowId: string | null;\n setDrilldownRowId: React.Dispatch<React.SetStateAction<string | null>>;\n focusedRowId: string | null;\n setFocusedRowId: React.Dispatch<React.SetStateAction<string | null>>;\n reduxHeaders: Record<string, ReduxHeader>;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n isShiftPressed: boolean;\n setIsShiftPressed: React.Dispatch<React.SetStateAction<boolean>>;\n lastSelected: React.MutableRefObject<number>;\n isHeaderCellDragging: boolean;\n setIsHeaderCellDragging: React.Dispatch<React.SetStateAction<boolean>>;\n }\n\n export interface DefaultProps {\n height: string;\n width: string;\n renderRowActions: false | RenderRowActionsConfig;\n getRowVariant: (\n row: InternalRow,\n defaultCellRenderer: React.ComponentType<{\n row: DSDataTableT.InternalRow;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n }>,\n ) => RowVariant | React.ComponentType<RowVariantProps>;\n withFilterBar: boolean;\n isExpandable: boolean;\n expandedRows: Record<string, boolean>;\n disabledRows: Record<string, boolean>;\n isResizeable: boolean;\n isLoading: boolean;\n pagination: false | Pagination;\n filters: Filter[];\n colsLayoutStyle: ColsLayoutStyleValues;\n hiddenColumns: string[];\n noResultsMessage: string;\n dragAndDropRows: boolean;\n maxDragAndDropLevel: number;\n onRowsReorder: (\n newData: Row[],\n indexes: { targetIndex: number; fromIndex: number },\n considerExpanding: string | null,\n extraData: { flattenedData: InternalRow[]; allDataFlattened: InternalRow[] },\n ) => void;\n dragAndDropColumns: boolean;\n onColumnsReorder: (newData: Column[], indexes: { targetIndex: number; fromIndex: number }) => void;\n getIsDropValid: (\n active: DnDKitTree.Item<Row>,\n over: DnDKitTree.Item<Row>,\n dropIndicatorPosition: DropIndicatorPositionValues,\n ) => boolean;\n onColumnResize: (headerId: string, width: number) => void;\n onColumnSizeChange: (newColumns: Column[], headerId: string, width: number) => void;\n onRowClick: TypescriptHelpersT.GenericFunc;\n onRowFocus: TypescriptHelpersT.GenericFunc;\n noSelectionColumn: boolean;\n selectSingle: boolean;\n onSelectionChange: (\n newSelection: Selection,\n selectedControl: string,\n event: React.ChangeEvent | React.MouseEvent | React.KeyboardEvent,\n ) => void;\n textWrap: 'wrap' | 'wrap-all' | 'truncate';\n onCellValueChange: (cellChange: { value: unknown; property: unknown; rowIndex: number }) => void;\n onFiltersChange: TypescriptHelpersT.GenericFunc;\n onPageChanged: TypescriptHelpersT.GenericFunc;\n onRowExpand: (expandedRows: Record<string, boolean>, toggledRow: string) => void;\n onColumnSortChange: (newSortRequest: { column: unknown; direction: unknown }) => void;\n onColumnSort: (newColumns: Column[], headerId: string, direction: 'ASC' | 'DESC') => void;\n isSkeleton: boolean;\n domIdAffix?: string;\n }\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSDataTableName, typeof DSDataTableSlots> {\n uniqueRowAccessor?: UniqueRowAccessorType;\n cellRendererProps?: Record<string, unknown>;\n selection?: Selection;\n groupedRowsRenderHeader?:\n | ((dimsumHeaderValue: string | undefined, subRows: Row[] | undefined) => JSX.Element)\n | string;\n filterBarProps?: {\n filterBarAddonRenderer?: React.ComponentType<{ innerRef: React.MutableRefObject<HTMLButtonElement | null> }>;\n customPillRenderer?: React.ComponentType<FilterPillProps<unknown>>;\n onClearAllFiltersClick?: () => void;\n onDropdownMenuToggle?: (isOpen: boolean, eventType: string) => void;\n onDropdownMenuClickOutside?: () => void;\n onDropdownMenuTriggerClick?: () => void;\n isDropdownMenuOpen?: boolean;\n extraOptions?: { type: string; id: string; label: string; onClick?: TypescriptHelpersT.GenericFunc }[];\n };\n actionRef?: React.MutableRefObject<{\n scrollToIndex: ReturnType<typeof useVirtual>['scrollToIndex'];\n scrollToOffset: ReturnType<typeof useVirtual>['scrollToOffset'];\n }>;\n noResultsSecondaryMessage?: string;\n noResultsButtonLabel?: string;\n noResultsPlaceholder?: React.ReactElement;\n onNoResultsButtonClick?: TypescriptHelpersT.GenericFunc;\n onTableResize?: TypescriptHelpersT.GenericFunc;\n Pagination?: React.ComponentType<Record<string, never>>;\n getAriaLabelForRow?: (args: {\n row: InternalRow;\n selected: boolean;\n disabled: boolean;\n expandable: boolean;\n expanded: boolean;\n }) => string;\n checkboxSelectAllProps?: DSControlledCheckboxT.Props;\n }\n export interface RequiredProps {\n columns: Column[];\n data: Row[];\n }\n\n export type Props = PropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type InternalProps = InternalPropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type GetOwnerPropsT = () => ZustandT.PropsStore<\n DefaultProps & RequiredProps & OptionalProps & UseAutoCalculatedT\n >;\n}\n\n// default props is a function to ensure that the uid is unique for each instance of the component\n// this is supported by the useMemoMergePropsWithDefault function.\nexport const defaultProps: () => DSDataTableT.DefaultProps = () => ({\n height: '100%',\n width: '100%',\n renderRowActions: false,\n getRowVariant: () => 'ds-primary-row',\n isExpandable: false,\n expandedRows: {},\n disabledRows: {},\n isResizeable: false,\n isLoading: false,\n pagination: false,\n withFilterBar: false,\n filters: [],\n getIsDropValid: () => true,\n onColumnResize: () => null,\n onColumnSortChange: () => null,\n colsLayoutStyle: ColsLayoutStyle.Fixed,\n hiddenColumns: [],\n noResultsMessage: 'No Results Found',\n dragAndDropRows: false,\n maxDragAndDropLevel: 1,\n onRowsReorder: () => null,\n dragAndDropColumns: false,\n onColumnsReorder: () => null,\n onColumnSizeChange: () => null,\n onRowClick: () => null,\n onRowFocus: () => null,\n noSelectionColumn: false,\n selectSingle: false,\n onSelectionChange: () => null,\n textWrap: 'wrap',\n onCellValueChange: () => null,\n onFiltersChange: () => null,\n onPageChanged: () => null,\n onRowExpand: () => null,\n onColumnSort: () => null,\n isSkeleton: false,\n domIdAffix: uid(4),\n});\n\nexport const DSDataTablePropTypes: DSPropTypesSchema<DSDataTableT.Props> = {\n ...getPropsPerSlotPropTypes(DSDataTableName, DSDataTableSlots),\n columns: PropTypes.arrayOf(\n PropTypes.shape({\n Header: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'Header name or component',\n ).isRequired,\n accessor: PropTypes.string.description('The entry of the data that this column will display'),\n id: PropTypes.string.description('The id of the column, will default to the Header or accessor if not present'),\n filter: PropTypes.oneOf(Object.values(FILTER_TYPES)).description('out-of-the-box filters'),\n Filter: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'The custom component to render as a filter',\n ),\n Cell: PropTypes.oneOfType([PropTypes.object, PropTypes.func]).description('The custom cell renderer component'),\n editable: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'The editable out-of-the-box or component to render',\n ),\n disableDnD: PropTypes.bool.description('Whereas this column should be draggable'),\n canResize: PropTypes.bool.description('Whereas this column should be resizable'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of this column'),\n minWidth: PropTypes.number.description('Minimum width of this column, useful when resizing'),\n maxWidth: PropTypes.number.description('Maximum width of this column, useful when resizing'),\n canSort: PropTypes.bool.description('Whereas this column is sortable'),\n disableFirstOptionFocusOnFilter: PropTypes.bool.description(\n 'Whereas the first option should not be focused on filter',\n ),\n filterMinWidth: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description(\n 'Minimum width of the filter',\n ),\n filterOptions: PropTypes.arrayOf(\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.string,\n label: PropTypes.string,\n }),\n ).description('Filter options'),\n isSortedDesc: PropTypes.bool.description('Whereas this column is sorted descendingly'),\n required: PropTypes.bool.description('Whereas this column is required'),\n alwaysDisplayEditIcon: PropTypes.bool.description(\n 'Whereas to always show the edit icon on this column if it is editable',\n ),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('How to wrap the text in the column'),\n }),\n ).description('Array of columns').isRequired,\n data: PropTypes.arrayOf(\n PropTypes.shape({\n tableRowDetails: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description('Component for row details'),\n dimsumHeaderValue: PropTypes.string.description('Header displayed on the header variant of the row'),\n }),\n ).description('Array of rows'),\n height: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Height of the datatable component'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of the datatable component'),\n renderRowActions: PropTypes.oneOfType([PropTypes.object, PropTypes.bool]).description(\n 'The renderer to use for the action toolbar',\n ),\n isExpandable: PropTypes.bool.description('Whether the datatable is expandable').defaultValue(false),\n uniqueRowAccessor: PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.arrayOf(PropTypes.string),\n PropTypes.func,\n ]).description(\n 'Column / Combination of columns / Function to call to produce a unique identifier for each row.' +\n ' This is necessary for the selectable and drag and drop features',\n ),\n disabledRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is disabled or not',\n ),\n expandedRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is expanded or not',\n ),\n onRowExpand: PropTypes.func.description('Function invoked when a row is (un)expanded'),\n cellRendererProps: PropTypes.object.description(\n 'Object with all the props you want the cells to have available when rendering',\n ),\n selectSingle: PropTypes.bool.description('Whether the selectable feature is single').defaultValue(false),\n selection: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is selected or not',\n ),\n onSelectionChange: PropTypes.func.description('Function invoked when a row is selected'),\n groupedRowsRenderHeader: PropTypes.oneOfType([PropTypes.string, PropTypes.func]).description(\n 'String | Function to call which will display in the row headers',\n ),\n isResizeable: PropTypes.bool.description(\"Whether the datatable's columns are resizeable\"),\n filters: PropTypes.arrayOf(\n PropTypes.shape({\n id: PropTypes.string,\n type: PropTypes.string,\n value: PropTypes.any,\n }),\n ).description('Array of filter keys and values'),\n withFilterBar: PropTypes.bool.description('Whether to display the filter bar'),\n filterBarProps: PropTypes.shape({\n filterBarAddonRenderer: PropTypes.func.description('Render filterbar right addon component'),\n customPillRenderer: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'If you specify custom filters, you will need to render their pills here',\n ),\n isDropdownMenuOpen: PropTypes.bool.description('Wether the DropdownMenu is Open or not.'),\n onDropdownMenuToggle: PropTypes.func.description('Callback to toggle the DropdownMenu.'),\n onClearAllFiltersClick: PropTypes.func.description('Callback for Clear Al Filters option.'),\n onDropdownMenuClickOutside: PropTypes.func.description('Callback triggered when clicking outside DropdownMenu.'),\n onDropdownMenuTriggerClick: PropTypes.func.description('Callback triggered when clicking DropdownMenu ellipsis.'),\n extraOptions: PropTypes.arrayOf(\n PropTypes.shape({\n type: PropTypes.string,\n id: PropTypes.string,\n label: PropTypes.string,\n onClick: PropTypes.func,\n }),\n ).description('Any extra option you want in the dropdownmenu of the filter bar'),\n }).description('Props for the filter bar'),\n onFiltersChange: PropTypes.func.description('Function invoked when filters change'),\n pagination: PropTypes.oneOfType([\n PropTypes.oneOf([false]),\n PropTypes.shape({\n pageCount: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('How many pages are there'),\n isLoadingPageCount: PropTypes.bool.description('Whether the page count is loading'),\n pageIndex: PropTypes.number.description('Index of the current page, starting from 1').defaultValue(1),\n canPreviousPage: PropTypes.bool.description('Whether the previous button is disabled or not').defaultValue(true),\n canNextPage: PropTypes.bool.description('Whether the next button is disabled or not').defaultValue(true),\n pageSize: PropTypes.number.description('The current page size').defaultValue(10),\n showPerPageSelector: PropTypes.bool.description('Whether to show the page selector').defaultValue(true),\n perPageOptions: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.number,\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.number,\n label: PropTypes.string,\n type: PropTypes.oneOf(['single']),\n }),\n ]),\n )\n .description('The available options for page size')\n .defaultValue([10]),\n perPageStep: PropTypes.number.description('Step for the per page options').defaultValue(5),\n minPerPage: PropTypes.number.description('Step for the per page options').defaultValue(0),\n maxPerPage: PropTypes.number.description('Step for the per page options').defaultValue(100),\n onPageSizeChange: PropTypes.func\n .description('Function invoked when the page size changes')\n .defaultValue(() => null),\n onPreviousPage: PropTypes.func\n .description('Function invoked when the previous button is pressed')\n .defaultValue(() => null),\n onPageChange: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNextPage: PropTypes.func.description('Function invoked when next button is pressed').defaultValue(() => null),\n pageDetails: PropTypes.arrayOf(PropTypes.string).description('Details to provide for each page').defaultValue([]),\n dataIsPage: PropTypes.bool.description('Whether to treat data as a page').defaultValue(false),\n pageDetailsTitle: PropTypes.string\n .description('The title of the details (usually a column of your dataset)')\n .defaultValue(''),\n }),\n ]).description('Object containing the data for the pagination'),\n Pagination: PropTypes.func.description('Custom component to show in place of the pagination'),\n colsLayoutStyle: PropTypes.oneOf(['auto', 'fixed']).description('Whether the datatable fills its container or not'),\n hiddenColumns: PropTypes.arrayOf(PropTypes.string).description('IDs of columns not to render'),\n dragAndDropRows: PropTypes.bool.description('Whether to turn on the d&d feature for the rows').defaultValue(false),\n onRowsReorder: PropTypes.func.description('Function invoked when a row is reordered'),\n maxDragAndDropLevel: PropTypes.number.description('Which level is the maximum allowed to drop into'),\n dragAndDropColumns: PropTypes.bool.description('Whether to turn on the d&d feature for the columns'),\n onColumnsReorder: PropTypes.func.description('Function invoked when a column is reordered'),\n getIsDropValid: PropTypes.func.description('Function to determine if a drop is valid'),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('Global wrapping rule'),\n noResultsMessage: PropTypes.string.description('Message to show when no more data is available'),\n noResultsSecondaryMessage: PropTypes.string.description('Secondary message to show when no more data is available'),\n noResultsButtonLabel: PropTypes.string.description('Label of the button when no more data is available'),\n noResultsPlaceholder: PropTypes.oneOfType([PropTypes.node]).description(\n 'Custom content to show when dataset is empty',\n ),\n isLoading: PropTypes.bool.description('Whether to show a global loader in the datatable'),\n onColumnResize: PropTypes.func\n .description('Function invoked when a column is resized')\n .deprecated({ version: '4.x', message: 'Use onColumnSizeChange' }),\n onColumnSizeChange: PropTypes.func.description('Function invoked when a column is resized'),\n onRowClick: PropTypes.func.description('Function invoked when clicking a row'),\n onRowFocus: PropTypes.func.description('Function invoked when focusing a row'),\n onCellValueChange: PropTypes.func.description(\"Function invoked when an editable cell's content is changed\"),\n onColumnSortChange: PropTypes.func\n .description('Function invoked when a column is sorted')\n .deprecated({ version: '4.x', message: 'Use onColumnSort' }),\n onColumnSort: PropTypes.func.description('Function invoked when a column is sorted'),\n onTableResize: PropTypes.func.description(\n 'Function invoked when the size of the internal table changes, e.g. when a the browser window is resized',\n ),\n actionRef: PropTypes.object.description('Reference where all the exposed action callbacks will be exposed'),\n getRowVariant: PropTypes.func\n .description(\"Function invoked to determine a row's variant\")\n .defaultValue(`() => 'ds-primary-row'`),\n noSelectionColumn: PropTypes.bool.description('Whether to show the selection column or not').defaultValue(false),\n onPageChanged: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNoResultsButtonClick: PropTypes.func\n .description('Function invoked when the no results button is clicked')\n .defaultValue(() => null),\n isSkeleton: PropTypes.bool.description('Whether to show a skeleton loader in the datatable'),\n getAriaLabelForRow: PropTypes.func.description('Function invoked to determine a row aria-label'),\n domIdAffix: PropTypes.string\n .description('Affix to avoid duplicate ids')\n .defaultValue('4 randomly generated characters'),\n checkboxSelectAllProps: PropTypes.object.description('Props for the select all checkbox'),\n};\n\nexport const DSDataTablePropTypesSchema = DSDataTablePropTypes as unknown as ValidationMap<DSDataTableT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,iBAAoB;AAQpB,8BAKO;AACP,8BAA6B;AAC7B,uBAA4D;AAC5D,IAAAA,oBAAkD;AAkc3C,MAAM,eAAgD,OAAO;AAAA,EAClE,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,kBAAkB;AAAA,EAClB,eAAe,MAAM;AAAA,EACrB,cAAc;AAAA,EACd,cAAc,CAAC;AAAA,EACf,cAAc,CAAC;AAAA,EACf,cAAc;AAAA,EACd,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,eAAe;AAAA,EACf,SAAS,CAAC;AAAA,EACV,gBAAgB,MAAM;AAAA,EACtB,gBAAgB,MAAM;AAAA,EACtB,oBAAoB,MAAM;AAAA,EAC1B,iBAAiB,iCAAgB;AAAA,EACjC,eAAe,CAAC;AAAA,EAChB,kBAAkB;AAAA,EAClB,iBAAiB;AAAA,EACjB,qBAAqB;AAAA,EACrB,eAAe,MAAM;AAAA,EACrB,oBAAoB;AAAA,EACpB,kBAAkB,MAAM;AAAA,EACxB,oBAAoB,MAAM;AAAA,EAC1B,YAAY,MAAM;AAAA,EAClB,YAAY,MAAM;AAAA,EAClB,mBAAmB;AAAA,EACnB,cAAc;AAAA,EACd,mBAAmB,MAAM;AAAA,EACzB,UAAU;AAAA,EACV,mBAAmB,MAAM;AAAA,EACzB,iBAAiB,MAAM;AAAA,EACvB,eAAe,MAAM;AAAA,EACrB,aAAa,MAAM;AAAA,EACnB,cAAc,MAAM;AAAA,EACpB,YAAY;AAAA,EACZ,gBAAY,gBAAI,CAAC;AACnB;AAEO,MAAM,uBAA8D;AAAA,EACzE,OAAG,kDAAyB,mCAAiB,kCAAgB;AAAA,EAC7D,SAAS,kCAAU;AAAA,IACjB,k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