@elliemae/ds-datagrids 2.0.0-alpha.1 → 2.0.0-alpha.13

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 (213) hide show
  1. package/cjs/DSDataGrid.js +247 -244
  2. package/cjs/DataGridImpl.js +22 -13
  3. package/cjs/PaginatedDataGrid.js +11 -6
  4. package/cjs/blockNames.js +2 -2
  5. package/cjs/columns/IconColumn.js +23 -21
  6. package/cjs/columns/NumberColumn.js +2 -4
  7. package/cjs/components/BodyCell.js +23 -15
  8. package/cjs/components/BodyList.js +11 -4
  9. package/cjs/components/ColumnVisibilityMenuOption.js +12 -6
  10. package/cjs/components/ColumnsOptionsMenuSection.js +35 -28
  11. package/cjs/components/EmptyState.js +23 -21
  12. package/cjs/components/HeaderCell.js +17 -11
  13. package/cjs/components/List.js +6 -1
  14. package/cjs/components/ListItem.js +8 -1
  15. package/cjs/components/NoResults.js +8 -3
  16. package/cjs/components/RowsLoader.js +6 -5
  17. package/cjs/components/Table.js +9 -4
  18. package/cjs/components/TableBody.js +8 -3
  19. package/cjs/components/TableHeader.js +6 -1
  20. package/cjs/components/footer/addOptionalFooterComponents.js +6 -5
  21. package/cjs/components/header/PrimaryControls.js +20 -15
  22. package/cjs/components/header/addOptionalHeaderComponents.js +5 -4
  23. package/cjs/components/renderers/defaultClassedRenderers.js +35 -23
  24. package/cjs/components/renderers/renderRowsLoader.js +1 -1
  25. package/cjs/components/tableContext.js +1 -1
  26. package/cjs/index.js +1 -1
  27. package/cjs/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js +54 -43
  28. package/cjs/plugins/column-dnd/DndColumnsPlugin.js +13 -9
  29. package/cjs/plugins/column-dnd/decorateGridWithDndColumns.js +3 -4
  30. package/cjs/plugins/column-sizing/ColumnSizingPlugin.js +12 -10
  31. package/cjs/plugins/column-sizing/columnMeasurerTransformer.js +14 -7
  32. package/cjs/plugins/column-sizing/ext-points/decorateColumn.js +3 -3
  33. package/cjs/plugins/column-sizing/ext-points/getTableProps.js +24 -18
  34. package/cjs/plugins/column-sizing/useColumnSizeService.js +14 -4
  35. package/cjs/plugins/column-sizing/useStylesheetHelpers.js +70 -56
  36. package/cjs/plugins/column-sizing/utils.js +10 -6
  37. package/cjs/plugins/custom-cell-renderer/CustomRendererPlugin.js +2 -2
  38. package/cjs/plugins/custom-cell-renderer/addCustomRendererToCell.js +11 -6
  39. package/cjs/plugins/custom-cell-renderer/getRendererComponent.js +24 -25
  40. package/cjs/plugins/editable/EditableComponents/ComboBox.js +10 -7
  41. package/cjs/plugins/editable/EditableComponents/TextBox.js +24 -19
  42. package/cjs/plugins/editable/EditablePlugin.js +17 -16
  43. package/cjs/plugins/editable/decorateEditable.js +25 -19
  44. package/cjs/plugins/editable/getEditorComponent.js +46 -35
  45. package/cjs/plugins/expandable-grid/ExpandableColumn.js +66 -59
  46. package/cjs/plugins/expandable-grid/ExpandablePlugin.js +42 -30
  47. package/cjs/plugins/expandable-grid/ExpandedRow.js +41 -31
  48. package/cjs/plugins/expandable-grid/ExpandedRowExtra.js +22 -16
  49. package/cjs/plugins/expandable-grid/useExpandGridState.js +4 -8
  50. package/cjs/plugins/export-data/ExportDataPlugin.js +34 -19
  51. package/cjs/plugins/filterable/FilterablePlugin.js +9 -8
  52. package/cjs/plugins/filterable/addFilterToColumn.js +6 -1
  53. package/cjs/plugins/filterable/components/FilterableHeader.js +39 -30
  54. package/cjs/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js +52 -45
  55. package/cjs/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js +38 -33
  56. package/cjs/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js +127 -161
  57. package/cjs/plugins/filterable/components/filterable-menus/TextFilterMenu.js +38 -29
  58. package/cjs/plugins/filterable/filterableFormatter.js +16 -11
  59. package/cjs/plugins/filterable/filtering-helper/filterRowsByQuery.js +18 -6
  60. package/cjs/plugins/filterable/filtering-helper/strategiesOperators.js +11 -8
  61. package/cjs/plugins/filterable/helper.js +18 -8
  62. package/cjs/plugins/filterable/useFilterableState.js +13 -6
  63. package/cjs/plugins/grouping-by/GroupingByPlugin.js +4 -2
  64. package/cjs/plugins/grouping-grid/GroupingPlugin.js +14 -5
  65. package/cjs/plugins/grouping-grid/walkStrategy.js +13 -9
  66. package/cjs/plugins/infinite-scrolling/InfiniteScrollPlugin.js +11 -4
  67. package/cjs/plugins/pagination/PaginationPlugin.js +17 -10
  68. package/cjs/plugins/pagination/components/Pagination.js +12 -11
  69. package/cjs/plugins/pagination/components/Paginator.js +23 -22
  70. package/cjs/plugins/pagination/components/PerPageDropdown.js +24 -17
  71. package/cjs/plugins/pagination/helper.js +11 -8
  72. package/cjs/plugins/pagination/usePaginationState.js +9 -4
  73. package/cjs/plugins/resizable/ResizablePlugin.js +6 -5
  74. package/cjs/plugins/resizable/decorateResizable.js +16 -10
  75. package/cjs/plugins/resizable/useResizeHandle.js +21 -16
  76. package/cjs/plugins/resizable/utils.js +9 -6
  77. package/cjs/plugins/row-dnd/DndRowsPlugin.js +27 -19
  78. package/cjs/plugins/selectable/SelectablePlugin.js +13 -12
  79. package/cjs/plugins/selectable/addSelectableColumn.js +25 -17
  80. package/cjs/plugins/selectable/helper.js +13 -4
  81. package/cjs/plugins/selectable/selectableFormatter.js +83 -74
  82. package/cjs/plugins/selectable/useSelectableState.js +26 -12
  83. package/cjs/plugins/sortable/SortablePlugin.js +11 -12
  84. package/cjs/plugins/sortable/checkIfSortable.js +1 -1
  85. package/cjs/plugins/sortable/sortHeaderFormatter.js +17 -18
  86. package/cjs/plugins/sortable/sortTree.js +16 -8
  87. package/cjs/plugins/sortable/sorter.js +153 -135
  88. package/cjs/plugins/sortable/useSortableState.js +12 -6
  89. package/cjs/plugins/toolbar/RowRenderer.js +13 -7
  90. package/cjs/plugins/toolbar/ToolbarPlugin.js +3 -2
  91. package/cjs/plugins/toolbar/ToolbarTrigger.js +26 -21
  92. package/cjs/plugins/virtualization/AutoHeightList.js +12 -10
  93. package/cjs/plugins/virtualization/VirtualizationPlugin.js +35 -28
  94. package/cjs/plugins/virtualization/VirtualizedBody.js +23 -13
  95. package/cjs/plugins/virtualization/VirtualizedBodyRow.js +8 -7
  96. package/cjs/renders/CellWithAddons.js +23 -21
  97. package/cjs/renders/styled.js +7 -18
  98. package/cjs/utilities/getPluginsFromProps.js +5 -1
  99. package/cjs/utilities/getScrollbarSize.js +2 -1
  100. package/cjs/utilities/normalizeData.js +8 -2
  101. package/esm/DSDataGrid.js +246 -243
  102. package/esm/DataGridImpl.js +18 -9
  103. package/esm/PaginatedDataGrid.js +5 -0
  104. package/esm/blockNames.js +2 -2
  105. package/esm/columns/IconColumn.js +19 -17
  106. package/esm/columns/NumberColumn.js +2 -4
  107. package/esm/components/BodyCell.js +20 -12
  108. package/esm/components/BodyList.js +7 -0
  109. package/esm/components/ColumnVisibilityMenuOption.js +12 -6
  110. package/esm/components/ColumnsOptionsMenuSection.js +35 -28
  111. package/esm/components/EmptyState.js +18 -15
  112. package/esm/components/HeaderCell.js +15 -9
  113. package/esm/components/List.js +5 -0
  114. package/esm/components/ListItem.js +7 -0
  115. package/esm/components/NoResults.js +5 -0
  116. package/esm/components/RowsLoader.js +5 -4
  117. package/esm/components/Table.js +5 -0
  118. package/esm/components/TableBody.js +5 -0
  119. package/esm/components/TableHeader.js +5 -0
  120. package/esm/components/footer/addOptionalFooterComponents.js +5 -4
  121. package/esm/components/header/PrimaryControls.js +20 -14
  122. package/esm/components/header/addOptionalHeaderComponents.js +4 -3
  123. package/esm/components/renderers/defaultClassedRenderers.js +35 -23
  124. package/esm/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js +50 -39
  125. package/esm/plugins/column-dnd/DndColumnsPlugin.js +8 -4
  126. package/esm/plugins/column-dnd/decorateGridWithDndColumns.js +1 -1
  127. package/esm/plugins/column-sizing/ColumnSizingPlugin.js +10 -8
  128. package/esm/plugins/column-sizing/columnMeasurerTransformer.js +12 -5
  129. package/esm/plugins/column-sizing/ext-points/decorateColumn.js +1 -1
  130. package/esm/plugins/column-sizing/ext-points/getTableProps.js +22 -15
  131. package/esm/plugins/column-sizing/useColumnSizeService.js +13 -3
  132. package/esm/plugins/column-sizing/useStylesheetHelpers.js +67 -51
  133. package/esm/plugins/column-sizing/utils.js +8 -4
  134. package/esm/plugins/custom-cell-renderer/addCustomRendererToCell.js +6 -1
  135. package/esm/plugins/custom-cell-renderer/getRendererComponent.js +15 -11
  136. package/esm/plugins/editable/EditableComponents/ComboBox.js +8 -4
  137. package/esm/plugins/editable/EditableComponents/TextBox.js +21 -15
  138. package/esm/plugins/editable/EditablePlugin.js +14 -12
  139. package/esm/plugins/editable/decorateEditable.js +18 -9
  140. package/esm/plugins/editable/getEditorComponent.js +49 -38
  141. package/esm/plugins/expandable-grid/ExpandableColumn.js +59 -50
  142. package/esm/plugins/expandable-grid/ExpandablePlugin.js +34 -20
  143. package/esm/plugins/expandable-grid/ExpandedRow.js +27 -17
  144. package/esm/plugins/expandable-grid/ExpandedRowExtra.js +17 -11
  145. package/esm/plugins/expandable-grid/useExpandGridState.js +2 -2
  146. package/esm/plugins/export-data/ExportDataPlugin.js +31 -16
  147. package/esm/plugins/filterable/FilterablePlugin.js +5 -4
  148. package/esm/plugins/filterable/addFilterToColumn.js +5 -0
  149. package/esm/plugins/filterable/components/FilterableHeader.js +32 -22
  150. package/esm/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js +41 -33
  151. package/esm/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js +28 -22
  152. package/esm/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js +121 -154
  153. package/esm/plugins/filterable/components/filterable-menus/TextFilterMenu.js +28 -18
  154. package/esm/plugins/filterable/filterableFormatter.js +15 -10
  155. package/esm/plugins/filterable/filtering-helper/filterRowsByQuery.js +14 -2
  156. package/esm/plugins/filterable/filtering-helper/strategiesOperators.js +7 -4
  157. package/esm/plugins/filterable/helper.js +11 -1
  158. package/esm/plugins/filterable/useFilterableState.js +12 -5
  159. package/esm/plugins/grouping-by/GroupingByPlugin.js +3 -1
  160. package/esm/plugins/grouping-grid/GroupingPlugin.js +10 -1
  161. package/esm/plugins/grouping-grid/walkStrategy.js +13 -9
  162. package/esm/plugins/infinite-scrolling/InfiniteScrollPlugin.js +8 -1
  163. package/esm/plugins/pagination/PaginationPlugin.js +8 -1
  164. package/esm/plugins/pagination/components/Pagination.js +10 -9
  165. package/esm/plugins/pagination/components/Paginator.js +20 -19
  166. package/esm/plugins/pagination/components/PerPageDropdown.js +17 -9
  167. package/esm/plugins/pagination/helper.js +10 -7
  168. package/esm/plugins/pagination/usePaginationState.js +7 -1
  169. package/esm/plugins/resizable/ResizablePlugin.js +4 -3
  170. package/esm/plugins/resizable/decorateResizable.js +14 -8
  171. package/esm/plugins/resizable/useResizeHandle.js +21 -16
  172. package/esm/plugins/resizable/utils.js +7 -4
  173. package/esm/plugins/row-dnd/DndRowsPlugin.js +22 -13
  174. package/esm/plugins/selectable/SelectablePlugin.js +10 -9
  175. package/esm/plugins/selectable/addSelectableColumn.js +24 -16
  176. package/esm/plugins/selectable/helper.js +10 -1
  177. package/esm/plugins/selectable/selectableFormatter.js +79 -68
  178. package/esm/plugins/selectable/useSelectableState.js +20 -5
  179. package/esm/plugins/sortable/SortablePlugin.js +5 -4
  180. package/esm/plugins/sortable/sortHeaderFormatter.js +12 -11
  181. package/esm/plugins/sortable/sortTree.js +13 -3
  182. package/esm/plugins/sortable/sorter.js +152 -134
  183. package/esm/plugins/sortable/useSortableState.js +8 -0
  184. package/esm/plugins/toolbar/RowRenderer.js +8 -2
  185. package/esm/plugins/toolbar/ToolbarPlugin.js +1 -0
  186. package/esm/plugins/toolbar/ToolbarTrigger.js +17 -11
  187. package/esm/plugins/virtualization/AutoHeightList.js +6 -3
  188. package/esm/plugins/virtualization/VirtualizationPlugin.js +31 -24
  189. package/esm/plugins/virtualization/VirtualizedBody.js +16 -6
  190. package/esm/plugins/virtualization/VirtualizedBodyRow.js +8 -7
  191. package/esm/renders/CellWithAddons.js +15 -14
  192. package/esm/renders/styled.js +3 -15
  193. package/esm/utilities/getPluginsFromProps.js +5 -1
  194. package/esm/utilities/getScrollbarSize.js +2 -1
  195. package/esm/utilities/normalizeData.js +7 -1
  196. package/package.json +27 -18
  197. package/types/DSDataGrid.d.ts +744 -105
  198. package/types/components/BodyCell.d.ts +1 -1
  199. package/types/components/HeaderCell.d.ts +1 -1
  200. package/types/plugins/column-sizing/columnMeasurerTransformer.d.ts +1 -1
  201. package/types/plugins/column-sizing/ext-points/getTableProps.d.ts +1 -1
  202. package/types/plugins/expandable-grid/ExpandedRowExtra.d.ts +1 -1
  203. package/types/plugins/expandable-grid/useExpandGridState.d.ts +4 -4
  204. package/types/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.d.ts +1 -1
  205. package/types/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.d.ts +1 -1
  206. package/types/plugins/filterable/components/filterable-menus/TextFilterMenu.d.ts +1 -1
  207. package/types/plugins/filterable/helper.d.ts +15 -3
  208. package/types/plugins/pagination/components/Paginator.d.ts +1 -1
  209. package/types/plugins/pagination/components/PerPageDropdown.d.ts +1 -1
  210. package/types/plugins/sortable/sorter.d.ts +1 -1
  211. package/types/renders/styled.d.ts +3 -3
  212. package/cjs/package.json +0 -7
  213. package/esm/package.json +0 -7
@@ -1,148 +1,166 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
- import { get } from '@elliemae/ds-utilities/utils';
2
+ import 'core-js/modules/esnext.async-iterator.filter.js';
3
+ import 'core-js/modules/esnext.iterator.constructor.js';
4
+ import 'core-js/modules/esnext.iterator.filter.js';
5
+ import 'core-js/modules/esnext.async-iterator.some.js';
6
+ import 'core-js/modules/esnext.iterator.some.js';
7
+ import 'core-js/modules/web.dom-collections.iterator.js';
8
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
9
+ import 'core-js/modules/esnext.iterator.for-each.js';
10
+ import 'core-js/modules/esnext.async-iterator.find.js';
11
+ import 'core-js/modules/esnext.iterator.find.js';
12
+ import 'core-js/modules/esnext.async-iterator.map.js';
13
+ import 'core-js/modules/esnext.iterator.map.js';
14
+ import { get } from '@elliemae/ds-utilities';
3
15
  import moment from 'moment';
4
16
 
5
17
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
6
18
 
7
19
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
8
- const sorter = ({
9
- columns,
10
- sortingColumns,
11
- sort,
12
- emptyLast
13
- } = {}) => data => {
14
- if (!columns) {
15
- throw new Error('sort.sorter - Missing "columns" argument!');
16
- }
17
-
18
- if (!sort) {
19
- throw new Error('sort.sorter - Missing "sort" argument!');
20
- }
21
-
22
- if (!sortingColumns) {
23
- return data;
24
- }
25
-
26
- const columnIndexList = new Array(sortingColumns.length);
27
- const orderList = new Array(sortingColumns.length);
28
- let actualSortFunction = sort;
29
-
30
- if (emptyLast) {
31
- actualSortFunction = (innerData, innerColumnIndexList, innerOrderList) => {
32
- const sortedData = sort(innerData, innerColumnIndexList, innerOrderList);
33
- const keys = Object.keys(sortingColumns);
34
- const withData = sortedData.filter(r => keys.some(key => !!r[key]));
35
- const withoutData = sortedData.filter(r => keys.some(key => !r[key]));
36
- return [...withData, ...withoutData];
37
- };
38
- }
39
-
40
- Object.keys(sortingColumns).forEach(sortingColumnKey => {
41
- const realColumn = columns.find(column => column.property === sortingColumnKey);
42
- if (!realColumn) return;
43
-
44
- const columnSorter = realColumn.sort || function resolveValue(row) {
45
- const {
46
- property,
47
- sortBy
48
- } = realColumn;
49
- const value = row[sortBy || property]; // Pick resolved value by convention
50
-
51
- const resolvedValue = get(row, `_${property}`, value);
52
-
53
- if (realColumn.type === 'DateTime') {
54
- return moment(resolvedValue);
55
- }
20
+ const sorter = function () {
21
+ let {
22
+ columns,
23
+ sortingColumns,
24
+ sort,
25
+ emptyLast
26
+ } = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
27
+ return data => {
28
+ if (!columns) {
29
+ throw new Error('sort.sorter - Missing "columns" argument!');
30
+ }
31
+
32
+ if (!sort) {
33
+ throw new Error('sort.sorter - Missing "sort" argument!');
34
+ }
35
+
36
+ if (!sortingColumns) {
37
+ return data;
38
+ }
39
+
40
+ const columnIndexList = new Array(sortingColumns.length);
41
+ const orderList = new Array(sortingColumns.length);
42
+ let actualSortFunction = sort;
43
+
44
+ if (emptyLast) {
45
+ actualSortFunction = (innerData, innerColumnIndexList, innerOrderList) => {
46
+ const sortedData = sort(innerData, innerColumnIndexList, innerOrderList);
47
+ const keys = Object.keys(sortingColumns);
48
+ const withData = sortedData.filter(r => keys.some(key => !!r[key]));
49
+ const withoutData = sortedData.filter(r => keys.some(key => !r[key]));
50
+ return [...withData, ...withoutData];
51
+ };
52
+ }
53
+
54
+ Object.keys(sortingColumns).forEach(sortingColumnKey => {
55
+ const realColumn = columns.find(column => column.property === sortingColumnKey);
56
+ if (!realColumn) return;
57
+
58
+ const columnSorter = realColumn.sort || function resolveValue(row) {
59
+ const {
60
+ property,
61
+ sortBy
62
+ } = realColumn;
63
+ const value = row[sortBy || property]; // Pick resolved value by convention
56
64
 
57
- return typeof resolvedValue === 'string' ? resolvedValue.toLowerCase() : resolvedValue;
58
- };
65
+ const resolvedValue = get(row, "_".concat(property), value);
59
66
 
60
- const sortingColumn = sortingColumns[sortingColumnKey];
61
- columnIndexList[sortingColumn.position] = columnSorter;
62
- orderList[sortingColumn.position] = sortingColumn.direction;
63
- });
64
- return actualSortFunction(data, columnIndexList, orderList);
67
+ if (realColumn.type === 'DateTime') {
68
+ return moment(resolvedValue);
69
+ }
70
+
71
+ return typeof resolvedValue === 'string' ? resolvedValue.toLowerCase() : resolvedValue;
72
+ };
73
+
74
+ const sortingColumn = sortingColumns[sortingColumnKey];
75
+ columnIndexList[sortingColumn.position] = columnSorter;
76
+ orderList[sortingColumn.position] = sortingColumn.direction;
77
+ });
78
+ return actualSortFunction(data, columnIndexList, orderList);
79
+ };
65
80
  };
66
- const sorterGroups = ({
67
- columns,
68
- sortingColumns,
69
- sort,
70
- emptyLast
71
- } = {}) => (data, rowsData) => {
72
- if (!columns) {
73
- throw new Error('sort.sorter - Missing "columns" argument!');
74
- }
75
-
76
- if (!sort) {
77
- throw new Error('sort.sorter - Missing "sort" argument!');
78
- }
79
-
80
- if (!sortingColumns) {
81
- return data;
82
- }
83
-
84
- const columnIndexList = new Array(sortingColumns.length);
85
- const orderList = new Array(sortingColumns.length);
86
- let actualSortFunction = sort;
87
-
88
- if (emptyLast) {
89
- actualSortFunction = (innerData, innerColumnIndexList, innerOrderList) => {
90
- const sortedData = sort(innerData, innerColumnIndexList, innerOrderList);
91
- const keys = Object.keys(sortingColumns);
92
- const withData = sortedData.filter(r => keys.some(key => !!r[key]));
93
- const withoutData = sortedData.filter(r => keys.some(key => !r[key]));
94
- return [...withData, ...withoutData];
95
- };
96
- }
97
-
98
- Object.keys(sortingColumns).forEach(sortingColumnKey => {
99
- const realColumn = columns.find(column => column.property === sortingColumnKey);
100
- if (!realColumn) return;
101
-
102
- const columnSorter = realColumn.sort || function resolveValue(row) {
103
- const {
104
- property,
105
- sortBy
106
- } = realColumn;
107
- const value = row[sortBy || property]; // Pick resolved value by convention
108
-
109
- const resolvedValue = get(row, `_${property}`, value);
110
-
111
- if (realColumn.type === 'DateTime') {
112
- return moment(resolvedValue);
113
- }
81
+ const sorterGroups = function () {
82
+ let {
83
+ columns,
84
+ sortingColumns,
85
+ sort,
86
+ emptyLast
87
+ } = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
88
+ return (data, rowsData) => {
89
+ if (!columns) {
90
+ throw new Error('sort.sorter - Missing "columns" argument!');
91
+ }
92
+
93
+ if (!sort) {
94
+ throw new Error('sort.sorter - Missing "sort" argument!');
95
+ }
96
+
97
+ if (!sortingColumns) {
98
+ return data;
99
+ }
114
100
 
115
- return typeof resolvedValue === 'string' ? resolvedValue.toLowerCase() : resolvedValue;
116
- };
117
-
118
- const sortingColumn = sortingColumns[sortingColumnKey];
119
- columnIndexList[sortingColumn.position] = columnSorter;
120
- orderList[sortingColumn.position] = sortingColumn.direction;
121
- });
122
- const groups = {};
123
- const preserveData = {};
124
- data.forEach(c => {
125
- preserveData[c.id] = _objectSpread({}, c);
126
- });
127
- rowsData.forEach(group => {
128
- groups[group.id] = {
129
- children: actualSortFunction(group.children.map(c => _objectSpread({
130
- parentNode: preserveData[c.id].parentNode,
131
- data: c
132
- }, c)), columnIndexList, orderList) // sort internally
133
-
134
- };
135
- });
136
- const sorted = actualSortFunction(data.map(r => _objectSpread(_objectSpread({}, r.data), r)), columnIndexList, orderList); // sort global
137
-
138
- let ssortGlobal = [];
139
- sorted.filter(s => !s.isGroup).forEach(sr => {
140
- if (groups[sr.parentNode.id]) {
141
- ssortGlobal = [...ssortGlobal, preserveData[sr.parentNode.id], ...groups[sr.parentNode.id].children];
142
- delete groups[sr.parentNode.id];
101
+ const columnIndexList = new Array(sortingColumns.length);
102
+ const orderList = new Array(sortingColumns.length);
103
+ let actualSortFunction = sort;
104
+
105
+ if (emptyLast) {
106
+ actualSortFunction = (innerData, innerColumnIndexList, innerOrderList) => {
107
+ const sortedData = sort(innerData, innerColumnIndexList, innerOrderList);
108
+ const keys = Object.keys(sortingColumns);
109
+ const withData = sortedData.filter(r => keys.some(key => !!r[key]));
110
+ const withoutData = sortedData.filter(r => keys.some(key => !r[key]));
111
+ return [...withData, ...withoutData];
112
+ };
143
113
  }
144
- });
145
- return ssortGlobal;
114
+
115
+ Object.keys(sortingColumns).forEach(sortingColumnKey => {
116
+ const realColumn = columns.find(column => column.property === sortingColumnKey);
117
+ if (!realColumn) return;
118
+
119
+ const columnSorter = realColumn.sort || function resolveValue(row) {
120
+ const {
121
+ property,
122
+ sortBy
123
+ } = realColumn;
124
+ const value = row[sortBy || property]; // Pick resolved value by convention
125
+
126
+ const resolvedValue = get(row, "_".concat(property), value);
127
+
128
+ if (realColumn.type === 'DateTime') {
129
+ return moment(resolvedValue);
130
+ }
131
+
132
+ return typeof resolvedValue === 'string' ? resolvedValue.toLowerCase() : resolvedValue;
133
+ };
134
+
135
+ const sortingColumn = sortingColumns[sortingColumnKey];
136
+ columnIndexList[sortingColumn.position] = columnSorter;
137
+ orderList[sortingColumn.position] = sortingColumn.direction;
138
+ });
139
+ const groups = {};
140
+ const preserveData = {};
141
+ data.forEach(c => {
142
+ preserveData[c.id] = _objectSpread({}, c);
143
+ });
144
+ rowsData.forEach(group => {
145
+ groups[group.id] = {
146
+ children: actualSortFunction(group.children.map(c => _objectSpread({
147
+ parentNode: preserveData[c.id].parentNode,
148
+ data: c
149
+ }, c)), columnIndexList, orderList) // sort internally
150
+
151
+ };
152
+ });
153
+ const sorted = actualSortFunction(data.map(r => _objectSpread(_objectSpread({}, r.data), r)), columnIndexList, orderList); // sort global
154
+
155
+ let ssortGlobal = [];
156
+ sorted.filter(s => !s.isGroup).forEach(sr => {
157
+ if (groups[sr.parentNode.id]) {
158
+ ssortGlobal = [...ssortGlobal, preserveData[sr.parentNode.id], ...groups[sr.parentNode.id].children];
159
+ delete groups[sr.parentNode.id];
160
+ }
161
+ });
162
+ return ssortGlobal;
163
+ };
146
164
  };
147
165
 
148
166
  export { sorter, sorterGroups };
@@ -1,4 +1,12 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
+ import 'core-js/modules/web.dom-collections.iterator.js';
3
+ import 'core-js/modules/esnext.async-iterator.find.js';
4
+ import 'core-js/modules/esnext.iterator.constructor.js';
5
+ import 'core-js/modules/esnext.iterator.find.js';
6
+ import 'core-js/modules/esnext.async-iterator.filter.js';
7
+ import 'core-js/modules/esnext.iterator.filter.js';
8
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
9
+ import 'core-js/modules/esnext.iterator.for-each.js';
2
10
  import * as sortabular from 'sortabular/dist/index.js';
3
11
  import useDerivedStateFromProps from '@elliemae/ds-utilities/hooks/useDerivedStateFromProps';
4
12
  import { checkIfSortable } from './checkIfSortable.js';
@@ -1,8 +1,14 @@
1
+ import 'core-js/modules/esnext.async-iterator.filter.js';
2
+ import 'core-js/modules/esnext.iterator.constructor.js';
3
+ import 'core-js/modules/esnext.iterator.filter.js';
4
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
5
+ import 'core-js/modules/esnext.iterator.for-each.js';
1
6
  import _jsx from '@babel/runtime/helpers/esm/jsx';
2
7
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
8
+ import 'core-js/modules/web.dom-collections.iterator.js';
3
9
  import { useRef, useState, useEffect } from 'react';
4
10
  import { isEmpty } from 'lodash';
5
- import { omit } from '@elliemae/ds-utilities/utils';
11
+ import { omit } from '@elliemae/ds-utilities';
6
12
  import { ToolbarTrigger } from './ToolbarTrigger.js';
7
13
  import { RowSizes } from '../../rowSizes.js';
8
14
  import { jsx } from 'react/jsx-runtime';
@@ -62,7 +68,7 @@ const RowRenderer = (Row, grid) => {
62
68
  }, props), {}, {
63
69
  style: rowStyle
64
70
  })), isEmpty(rowData) && !rowData.index && !rowData.rowIndex ? null : /*#__PURE__*/_jsx("div", {
65
- className: `toolbar-trigger-container ${style ? 'move' : 'stay'}`,
71
+ className: "toolbar-trigger-container ".concat(style ? 'move' : 'stay'),
66
72
  style: _objectSpread({}, popStyle)
67
73
  }, void 0, /*#__PURE__*/_jsx(ToolbarTrigger, {
68
74
  grid: grid,
@@ -1,4 +1,5 @@
1
1
  import _jsx from '@babel/runtime/helpers/esm/jsx';
2
+ import 'core-js/modules/web.dom-collections.iterator.js';
2
3
  import 'react';
3
4
  import createInstancePlugin from '@elliemae/ds-shared/createDataInstance/createInstancePlugin';
4
5
  import { appendCellFormatter } from '@elliemae/ds-shared/useDataGrid/initColumnDefinition';
@@ -1,9 +1,15 @@
1
+ import 'core-js/modules/esnext.async-iterator.filter.js';
2
+ import 'core-js/modules/esnext.iterator.constructor.js';
3
+ import 'core-js/modules/esnext.iterator.filter.js';
4
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
5
+ import 'core-js/modules/esnext.iterator.for-each.js';
1
6
  import _jsx from '@babel/runtime/helpers/esm/jsx';
2
7
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
8
+ import 'core-js/modules/web.dom-collections.iterator.js';
3
9
  import { useState } from 'react';
4
10
  import styled from 'styled-components';
5
- import DSButton from '@elliemae/ds-basic/Button';
6
- import MoreOptionsVert from '@elliemae/ds-icons/MoreOptionsVert';
11
+ import DSButton from '@elliemae/ds-button';
12
+ import { MoreOptionsVert } from '@elliemae/ds-icons';
7
13
 
8
14
  var _MoreOptionsVert;
9
15
 
@@ -15,18 +21,18 @@ const ToolbarBtns = /*#__PURE__*/styled.div.withConfig({
15
21
  })(["& > .em-ds-toolbar{box-shadow:none;}"]);
16
22
  const ToolbarWrapper = /*#__PURE__*/styled.div.withConfig({
17
23
  componentId: "sc-pm75g5-1"
18
- })(["display:flex;align-items:center;height:", ";margin-left:-4px;margin-right:", ";padding-right:4px;pointer-events:all;background:white;", " &:hover{box-shadow:-1px 0px 1px 0px rgba(0,0,0,0.2),1px 0px 2px 0px rgba(0,0,0,0.2);& > .toolbar-trigger{border:none;}}"], props => props.rowSize === 'normal' ? '36px' : '28px', props => props.hasScrollBar ? '0' : '-10px', props => props.showShadow ? `box-shadow: -1px 0px 1px 0px rgba(0, 0, 0, 0.2),
19
- 1px 0px 2px 0px rgba(0, 0, 0, 0.2);` : '');
24
+ })(["display:flex;align-items:center;height:", ";margin-left:-4px;margin-right:", ";padding-right:4px;pointer-events:all;background:white;", " &:hover{box-shadow:-1px 0px 1px 0px rgba(0,0,0,0.2),1px 0px 2px 0px rgba(0,0,0,0.2);& > .toolbar-trigger{border:none;}}"], props => props.rowSize === 'normal' ? '36px' : '28px', props => props.hasScrollBar ? '0' : '-10px', props => props.showShadow ? "box-shadow: -1px 0px 1px 0px rgba(0, 0, 0, 0.2),\n 1px 0px 2px 0px rgba(0, 0, 0, 0.2);" : '');
20
25
  const ToolbarPosition = /*#__PURE__*/styled.div.withConfig({
21
26
  componentId: "sc-pm75g5-2"
22
- })(["position:absolute;z-index:10;display:flex;justify-content:flex-end;align-items:center;width:0;pointer-events:none;top:0;height:", ";margin-top:", ";"], props => props.rowRef.current ? `${props.rowRef.current.offsetHeight}px` : '36px', props => props.rowSize === 'normal' ? '0' : '0'); // eslint-disable-next-line react/prop-types
27
+ })(["position:absolute;z-index:10;display:flex;justify-content:flex-end;align-items:center;width:0;pointer-events:none;top:0;height:", ";margin-top:", ";"], props => props.rowRef.current ? "".concat(props.rowRef.current.offsetHeight, "px") : '36px', props => props.rowSize === 'normal' ? '0' : '0'); // eslint-disable-next-line react/prop-types
23
28
 
24
- const ToolbarTrigger = ({
25
- grid,
26
- rowData,
27
- hasScrollBar,
28
- rowRef
29
- }) => {
29
+ const ToolbarTrigger = _ref => {
30
+ let {
31
+ grid,
32
+ rowData,
33
+ hasScrollBar,
34
+ rowRef
35
+ } = _ref;
30
36
  const {
31
37
  props: {
32
38
  renderToolbar,
@@ -1,10 +1,13 @@
1
+ import 'core-js/modules/esnext.async-iterator.filter.js';
2
+ import 'core-js/modules/esnext.iterator.constructor.js';
3
+ import 'core-js/modules/esnext.iterator.filter.js';
4
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
5
+ import 'core-js/modules/esnext.iterator.for-each.js';
1
6
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
7
  import _objectWithoutProperties from '@babel/runtime/helpers/esm/objectWithoutProperties';
3
8
  import { forwardRef, useRef } from 'react';
4
9
  import { FixedSizeList } from 'react-window';
5
- import { cx } from '@elliemae/ds-utilities/utils';
6
- import { mergeRefs } from '@elliemae/ds-utilities/system';
7
- import useWindowScrollerList from '@elliemae/ds-utilities/hooks/useWindowScrollerList';
10
+ import { useWindowScrollerList, mergeRefs, cx } from '@elliemae/ds-utilities';
8
11
  import { jsx } from 'react/jsx-runtime';
9
12
 
10
13
  const _excluded = ["itemCount", "className", "innerRef", "itemData", "itemKey", "itemSize", "outerRef", "component"];
@@ -1,10 +1,14 @@
1
+ import 'core-js/modules/esnext.async-iterator.filter.js';
2
+ import 'core-js/modules/esnext.iterator.constructor.js';
3
+ import 'core-js/modules/esnext.iterator.filter.js';
4
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
5
+ import 'core-js/modules/esnext.iterator.for-each.js';
1
6
  import _jsx from '@babel/runtime/helpers/esm/jsx';
2
7
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
3
8
  import { useMemo, useRef } from 'react';
4
9
  import { get } from 'lodash';
5
10
  import FocusGridManager from '@elliemae/ds-shared/FocusGroup/FocusGrid';
6
- import { runAll } from '@elliemae/ds-utilities/utils';
7
- import { mergeRefs } from '@elliemae/ds-utilities/system';
11
+ import { mergeRefs, runAll } from '@elliemae/ds-utilities';
8
12
  import createInstancePlugin from '@elliemae/ds-shared/createDataInstance/createInstancePlugin';
9
13
  import VirtualizedBody from './VirtualizedBody.js';
10
14
  import { jsx } from 'react/jsx-runtime';
@@ -46,28 +50,31 @@ const VirtualizationPlugin = createInstancePlugin('virtualization', {
46
50
 
47
51
  return /*#__PURE__*/_jsx(FocusGridManager, {
48
52
  hotKeys: hotKeys,
49
- keyBindings: ({
50
- defaultBindings
51
- }) => _objectSpread(_objectSpread({}, defaultBindings), {}, {
52
- // todo: this is kind of hacky, since it's virtualized and there's
53
- // the possibility that the firsts or lasts rows aren't rendered
54
- Home: runAll(e => {
55
- if (e.ctrlKey) {
56
- listRef.current.scrollToItem(0);
57
- setTimeout(() => defaultBindings.Home(e), 10);
58
- } else {
59
- defaultBindings.Home(e);
60
- }
61
- }),
62
- End: runAll(e => {
63
- if (e.ctrlKey) {
64
- listRef.current.scrollToItem(rows.length - 1);
65
- setTimeout(() => defaultBindings.End(e), 10);
66
- } else {
67
- defaultBindings.End(e);
68
- }
69
- })
70
- }),
53
+ keyBindings: _ref => {
54
+ let {
55
+ defaultBindings
56
+ } = _ref;
57
+ return _objectSpread(_objectSpread({}, defaultBindings), {}, {
58
+ // todo: this is kind of hacky, since it's virtualized and there's
59
+ // the possibility that the firsts or lasts rows aren't rendered
60
+ Home: runAll(e => {
61
+ if (e.ctrlKey) {
62
+ listRef.current.scrollToItem(0);
63
+ setTimeout(() => defaultBindings.Home(e), 10);
64
+ } else {
65
+ defaultBindings.Home(e);
66
+ }
67
+ }),
68
+ End: runAll(e => {
69
+ if (e.ctrlKey) {
70
+ listRef.current.scrollToItem(rows.length - 1);
71
+ setTimeout(() => defaultBindings.End(e), 10);
72
+ } else {
73
+ defaultBindings.End(e);
74
+ }
75
+ })
76
+ });
77
+ },
71
78
  shouldRefocus: false
72
79
  }, void 0, /*#__PURE__*/jsx(VirtualizedBody, _objectSpread(_objectSpread({}, props), {}, {
73
80
  autoScrollToId: autoScrollToId,
@@ -1,8 +1,17 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
2
  import _jsx from '@babel/runtime/helpers/esm/jsx';
3
+ import 'core-js/modules/web.dom-collections.iterator.js';
4
+ import 'core-js/modules/esnext.async-iterator.reduce.js';
5
+ import 'core-js/modules/esnext.iterator.constructor.js';
6
+ import 'core-js/modules/esnext.iterator.reduce.js';
7
+ import 'core-js/modules/esnext.async-iterator.map.js';
8
+ import 'core-js/modules/esnext.iterator.map.js';
9
+ import 'core-js/modules/esnext.async-iterator.filter.js';
10
+ import 'core-js/modules/esnext.iterator.filter.js';
11
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
12
+ import 'core-js/modules/esnext.iterator.for-each.js';
3
13
  import { useState, useRef, useCallback, useEffect, useLayoutEffect } from 'react';
4
- import { mergeRefs } from '@elliemae/ds-utilities/system';
5
- import { debounce, isNaN } from '@elliemae/ds-utilities/utils';
14
+ import { debounce, isNaN, mergeRefs } from '@elliemae/ds-utilities';
6
15
  import NoResults from '../../components/NoResults.js';
7
16
  import VirtualizedBodyRow from './VirtualizedBodyRow.js';
8
17
  import { RowSizes } from '../../rowSizes.js';
@@ -90,9 +99,10 @@ const VirtualizedBody = props => {
90
99
  useEffect(() => {
91
100
  autoScrollTo(visibleHeight);
92
101
  }, [autoScrollToId, visibleHeight]);
93
- const handler = useCallback(debounce(({
94
- target
95
- }) => {
102
+ const handler = useCallback(debounce(_ref => {
103
+ let {
104
+ target
105
+ } = _ref;
96
106
  // Update coordinates
97
107
  setScrollTop(target.scrollTop || 0);
98
108
  }, 100), [setScrollTop]);
@@ -236,7 +246,7 @@ const VirtualizedBody = props => {
236
246
  },
237
247
  children: /*#__PURE__*/jsx("div", {
238
248
  "data-testid": "virtualized-body",
239
- className: `virtualized-body${hasScrollBar ? ' with-scrollbar' : ''}`,
249
+ className: "virtualized-body".concat(hasScrollBar ? ' with-scrollbar' : ''),
240
250
  style: bodyStyle,
241
251
  ref: r => {
242
252
  mergeRefs(innerBody)(r);
@@ -1,10 +1,11 @@
1
- function VirtualizedBodyRow({
2
- data,
3
- index,
4
- style,
5
- key,
6
- isScrolling
7
- }) {
1
+ function VirtualizedBodyRow(_ref) {
2
+ let {
3
+ data,
4
+ index,
5
+ style,
6
+ key,
7
+ isScrolling
8
+ } = _ref;
8
9
  const {
9
10
  rows,
10
11
  renderer: {
@@ -1,22 +1,23 @@
1
1
  import _jsx from '@babel/runtime/helpers/esm/jsx';
2
2
  import 'react';
3
3
  import { get } from 'lodash';
4
- import { Grid } from '@elliemae/ds-basic/Grid';
5
- import DSTruncatedTooltipText from '@elliemae/ds-basic/TruncatedTooltipText';
4
+ import Grid from '@elliemae/ds-grid';
5
+ import DSTruncatedTooltipText from '@elliemae/ds-truncated-tooltip-text';
6
6
  import { CellWrapper, ValueWrapper } from './styled.js';
7
7
 
8
- const CellWithAddons = ({
9
- leftAddon,
10
- keepLeftPadding,
11
- rightAddon,
12
- badgeAddon,
13
- highLight,
14
- isEdit,
15
- editComponent,
16
- value,
17
- neutralText,
18
- metaData
19
- }) => {
8
+ const CellWithAddons = _ref => {
9
+ let {
10
+ leftAddon,
11
+ keepLeftPadding,
12
+ rightAddon,
13
+ badgeAddon,
14
+ highLight,
15
+ isEdit,
16
+ editComponent,
17
+ value,
18
+ neutralText,
19
+ metaData
20
+ } = _ref;
20
21
  const hasLeftAddon = !!leftAddon || keepLeftPadding;
21
22
  const hasRightAddon = !!rightAddon && !isEdit;
22
23
  const cols = [1];
@@ -1,26 +1,14 @@
1
1
  import styled from 'styled-components';
2
- import { Grid } from '@elliemae/ds-basic/Grid';
2
+ import Grid from '@elliemae/ds-grid';
3
3
 
4
4
  const m = '0.61538rem';
5
5
  const m2 = '1.23076rem';
6
6
  const CellWrapper = /*#__PURE__*/styled.div.withConfig({
7
7
  componentId: "sc-1n8exyf-0"
8
- })(["max-height:36px;height:100%;width:", ";margin-left:", ";margin-right:", ";padding-left:", ";padding-right:", ";", ";", ""], props => props.noPadding ? `calc(100% + ${m2})` : '100%', props => props.noPadding ? `-${m}` : '0', props => props.noPadding ? `-${m}` : '0', props => !props.hasLeftAddon && (props.badgeAddon || props.highLight || props.hasRightAddon) ? m : '0', props => !props.hasRightAddon && (props.badgeAddon || props.highLight || props.hasLeftAddon) ? m : '0', props => props.highLight ? `background: ${props.theme.colors.brand['200']}` : '', props => props.badgeAddon ? `
9
- position: relative;
10
- &::before {
11
- display: block;
12
- content: '';
13
- position: absolute;
14
- top: 0;
15
- left:0;
16
- border-style: solid;
17
- border-width: ${props.theme.space.xxs} ${props.theme.space.xxs} ${props.theme.space.xxs} 0;
18
- border-color: ${props.theme.colors.brand['600']} transparent transparent ${props.theme.colors.brand['600']};
19
- }
20
- ` : '');
8
+ })(["max-height:36px;height:100%;width:", ";margin-left:", ";margin-right:", ";padding-left:", ";padding-right:", ";", ";", ""], props => props.noPadding ? "calc(100% + ".concat(m2, ")") : '100%', props => props.noPadding ? "-".concat(m) : '0', props => props.noPadding ? "-".concat(m) : '0', props => !props.hasLeftAddon && (props.badgeAddon || props.highLight || props.hasRightAddon) ? m : '0', props => !props.hasRightAddon && (props.badgeAddon || props.highLight || props.hasLeftAddon) ? m : '0', props => props.highLight ? "background: ".concat(props.theme.colors.brand['200']) : '', props => props.badgeAddon ? "\n position: relative; \n &::before {\n display: block;\n content: '';\n position: absolute;\n top: 0;\n left:0;\n border-style: solid;\n border-width: ".concat(props.theme.space.xxs, " ").concat(props.theme.space.xxs, " ").concat(props.theme.space.xxs, " 0;\n border-color: ").concat(props.theme.colors.brand['600'], " transparent transparent ").concat(props.theme.colors.brand['600'], ";\n }\n ") : '');
21
9
  const ValueWrapper = /*#__PURE__*/styled.div.withConfig({
22
10
  componentId: "sc-1n8exyf-1"
23
- })(["display:flex;align-items:center;overflow:hidden;& > span{display:inline-flex;align-items:center;}", ""], props => props.grayText ? `color: ${props.theme.colors.neutral['500']};` : '');
11
+ })(["display:flex;align-items:center;overflow:hidden;& > span{display:inline-flex;align-items:center;}", ""], props => props.grayText ? "color: ".concat(props.theme.colors.neutral['500'], ";") : '');
24
12
  const CellContainer = /*#__PURE__*/styled(Grid).withConfig({
25
13
  componentId: "sc-1n8exyf-2"
26
14
  })(["padding-left:", ";padding-right:", ";position:relative;"], m, m);
@@ -1,3 +1,6 @@
1
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
2
+ import 'core-js/modules/esnext.iterator.constructor.js';
3
+ import 'core-js/modules/esnext.iterator.for-each.js';
1
4
  import { DndRowsPlugin } from '../plugins/row-dnd/DndRowsPlugin.js';
2
5
  import { DndColumnsPlugin } from '../plugins/column-dnd/DndColumnsPlugin.js';
3
6
  import { InfiniteScrollPlugin } from '../plugins/infinite-scrolling/InfiniteScrollPlugin.js';
@@ -27,7 +30,8 @@ const mapPropToPlugin = {
27
30
  groupedRows: GroupingPlugin,
28
31
  dragAndDropRows: DndRowsPlugin
29
32
  };
30
- function getPluginsFromProps(props, omit = {}) {
33
+ function getPluginsFromProps(props) {
34
+ let omit = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
31
35
  const plugins = [];
32
36
  Object.keys(mapPropToPlugin).forEach(key => {
33
37
  if (props[key] && !omit[key]) plugins.push(mapPropToPlugin[key]);
@@ -1,4 +1,5 @@
1
- function getScrollbarWidth(compensatePixels = 0) {
1
+ function getScrollbarWidth() {
2
+ let compensatePixels = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
2
3
  // Creating invisible container
3
4
  const outer = document.createElement('div');
4
5
  outer.style.visibility = 'hidden';