@elliemae/ds-datagrids 2.0.0-next.7 → 2.0.0-rc.2

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 (198) hide show
  1. package/cjs/DSDataGrid.js +246 -243
  2. package/cjs/DataGridImpl.js +16 -8
  3. package/cjs/PaginatedDataGrid.js +5 -0
  4. package/cjs/columns/IconColumn.js +19 -17
  5. package/cjs/columns/NumberColumn.js +2 -4
  6. package/cjs/components/BodyCell.js +17 -10
  7. package/cjs/components/BodyList.js +7 -0
  8. package/cjs/components/ColumnVisibilityMenuOption.js +10 -6
  9. package/cjs/components/ColumnsOptionsMenuSection.js +34 -28
  10. package/cjs/components/EmptyState.js +19 -17
  11. package/cjs/components/HeaderCell.js +14 -8
  12. package/cjs/components/List.js +5 -0
  13. package/cjs/components/ListItem.js +7 -0
  14. package/cjs/components/NoResults.js +5 -0
  15. package/cjs/components/RowsLoader.js +5 -4
  16. package/cjs/components/Table.js +5 -0
  17. package/cjs/components/TableBody.js +5 -0
  18. package/cjs/components/TableHeader.js +5 -0
  19. package/cjs/components/footer/addOptionalFooterComponents.js +5 -4
  20. package/cjs/components/header/PrimaryControls.js +20 -15
  21. package/cjs/components/header/addOptionalHeaderComponents.js +4 -3
  22. package/cjs/components/renderers/defaultClassedRenderers.js +33 -21
  23. package/cjs/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js +46 -35
  24. package/cjs/plugins/column-dnd/DndColumnsPlugin.js +9 -5
  25. package/cjs/plugins/column-dnd/decorateGridWithDndColumns.js +2 -3
  26. package/cjs/plugins/column-sizing/ColumnSizingPlugin.js +10 -8
  27. package/cjs/plugins/column-sizing/columnMeasurerTransformer.js +13 -6
  28. package/cjs/plugins/column-sizing/ext-points/decorateColumn.js +3 -3
  29. package/cjs/plugins/column-sizing/ext-points/getTableProps.js +22 -17
  30. package/cjs/plugins/column-sizing/useColumnSizeService.js +9 -0
  31. package/cjs/plugins/column-sizing/useStylesheetHelpers.js +56 -40
  32. package/cjs/plugins/column-sizing/utils.js +10 -6
  33. package/cjs/plugins/custom-cell-renderer/addCustomRendererToCell.js +9 -4
  34. package/cjs/plugins/custom-cell-renderer/getRendererComponent.js +20 -21
  35. package/cjs/plugins/editable/EditableComponents/ComboBox.js +7 -3
  36. package/cjs/plugins/editable/EditableComponents/TextBox.js +20 -14
  37. package/cjs/plugins/editable/EditablePlugin.js +15 -15
  38. package/cjs/plugins/editable/decorateEditable.js +18 -11
  39. package/cjs/plugins/editable/getEditorComponent.js +45 -34
  40. package/cjs/plugins/expandable-grid/ExpandableColumn.js +57 -50
  41. package/cjs/plugins/expandable-grid/ExpandablePlugin.js +37 -26
  42. package/cjs/plugins/expandable-grid/ExpandedRow.js +28 -18
  43. package/cjs/plugins/expandable-grid/ExpandedRowExtra.js +16 -10
  44. package/cjs/plugins/expandable-grid/useExpandGridState.js +3 -8
  45. package/cjs/plugins/export-data/ExportDataPlugin.js +23 -10
  46. package/cjs/plugins/filterable/FilterablePlugin.js +7 -6
  47. package/cjs/plugins/filterable/addFilterToColumn.js +5 -0
  48. package/cjs/plugins/filterable/components/FilterableHeader.js +35 -27
  49. package/cjs/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js +38 -32
  50. package/cjs/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js +26 -22
  51. package/cjs/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js +119 -154
  52. package/cjs/plugins/filterable/components/filterable-menus/TextFilterMenu.js +28 -20
  53. package/cjs/plugins/filterable/filterableFormatter.js +15 -10
  54. package/cjs/plugins/filterable/filtering-helper/filterRowsByQuery.js +16 -4
  55. package/cjs/plugins/filterable/filtering-helper/strategiesOperators.js +7 -4
  56. package/cjs/plugins/filterable/helper.js +16 -7
  57. package/cjs/plugins/filterable/useFilterableState.js +11 -5
  58. package/cjs/plugins/grouping-by/GroupingByPlugin.js +2 -0
  59. package/cjs/plugins/grouping-grid/GroupingPlugin.js +9 -0
  60. package/cjs/plugins/grouping-grid/walkStrategy.js +11 -9
  61. package/cjs/plugins/infinite-scrolling/InfiniteScrollPlugin.js +7 -1
  62. package/cjs/plugins/pagination/PaginationPlugin.js +9 -2
  63. package/cjs/plugins/pagination/components/Pagination.js +10 -9
  64. package/cjs/plugins/pagination/components/Paginator.js +8 -7
  65. package/cjs/plugins/pagination/components/PerPageDropdown.js +20 -13
  66. package/cjs/plugins/pagination/helper.js +10 -7
  67. package/cjs/plugins/pagination/usePaginationState.js +7 -3
  68. package/cjs/plugins/resizable/ResizablePlugin.js +5 -4
  69. package/cjs/plugins/resizable/decorateResizable.js +14 -8
  70. package/cjs/plugins/resizable/useResizeHandle.js +21 -16
  71. package/cjs/plugins/resizable/utils.js +8 -5
  72. package/cjs/plugins/row-dnd/DndRowsPlugin.js +23 -16
  73. package/cjs/plugins/selectable/SelectablePlugin.js +10 -8
  74. package/cjs/plugins/selectable/addSelectableColumn.js +24 -16
  75. package/cjs/plugins/selectable/helper.js +12 -3
  76. package/cjs/plugins/selectable/selectableFormatter.js +80 -71
  77. package/cjs/plugins/selectable/useSelectableState.js +24 -11
  78. package/cjs/plugins/sortable/SortablePlugin.js +8 -7
  79. package/cjs/plugins/sortable/sortHeaderFormatter.js +14 -15
  80. package/cjs/plugins/sortable/sortTree.js +13 -3
  81. package/cjs/plugins/sortable/sorter.js +151 -134
  82. package/cjs/plugins/sortable/useSortableState.js +7 -0
  83. package/cjs/plugins/toolbar/RowRenderer.js +7 -2
  84. package/cjs/plugins/toolbar/ToolbarTrigger.js +15 -10
  85. package/cjs/plugins/virtualization/AutoHeightList.js +10 -8
  86. package/cjs/plugins/virtualization/VirtualizationPlugin.js +32 -25
  87. package/cjs/plugins/virtualization/VirtualizedBody.js +18 -9
  88. package/cjs/plugins/virtualization/VirtualizedBodyRow.js +8 -7
  89. package/cjs/renders/CellWithAddons.js +20 -18
  90. package/cjs/renders/styled.js +3 -2
  91. package/cjs/utilities/getPluginsFromProps.js +5 -1
  92. package/cjs/utilities/getScrollbarSize.js +2 -1
  93. package/cjs/utilities/normalizeData.js +7 -1
  94. package/esm/DSDataGrid.js +246 -243
  95. package/esm/DataGridImpl.js +16 -8
  96. package/esm/PaginatedDataGrid.js +5 -0
  97. package/esm/columns/IconColumn.js +18 -16
  98. package/esm/columns/NumberColumn.js +2 -4
  99. package/esm/components/BodyCell.js +17 -10
  100. package/esm/components/BodyList.js +7 -0
  101. package/esm/components/ColumnVisibilityMenuOption.js +10 -6
  102. package/esm/components/ColumnsOptionsMenuSection.js +34 -28
  103. package/esm/components/EmptyState.js +18 -15
  104. package/esm/components/HeaderCell.js +14 -8
  105. package/esm/components/List.js +5 -0
  106. package/esm/components/ListItem.js +7 -0
  107. package/esm/components/NoResults.js +5 -0
  108. package/esm/components/RowsLoader.js +5 -4
  109. package/esm/components/Table.js +5 -0
  110. package/esm/components/TableBody.js +5 -0
  111. package/esm/components/TableHeader.js +5 -0
  112. package/esm/components/footer/addOptionalFooterComponents.js +5 -4
  113. package/esm/components/header/PrimaryControls.js +20 -14
  114. package/esm/components/header/addOptionalHeaderComponents.js +4 -3
  115. package/esm/components/renderers/defaultClassedRenderers.js +33 -21
  116. package/esm/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js +46 -35
  117. package/esm/plugins/column-dnd/DndColumnsPlugin.js +6 -2
  118. package/esm/plugins/column-dnd/decorateGridWithDndColumns.js +1 -1
  119. package/esm/plugins/column-sizing/ColumnSizingPlugin.js +9 -7
  120. package/esm/plugins/column-sizing/columnMeasurerTransformer.js +12 -5
  121. package/esm/plugins/column-sizing/ext-points/decorateColumn.js +1 -1
  122. package/esm/plugins/column-sizing/ext-points/getTableProps.js +21 -15
  123. package/esm/plugins/column-sizing/useColumnSizeService.js +9 -0
  124. package/esm/plugins/column-sizing/useStylesheetHelpers.js +54 -38
  125. package/esm/plugins/column-sizing/utils.js +8 -4
  126. package/esm/plugins/custom-cell-renderer/addCustomRendererToCell.js +6 -1
  127. package/esm/plugins/custom-cell-renderer/getRendererComponent.js +15 -11
  128. package/esm/plugins/editable/EditableComponents/ComboBox.js +6 -1
  129. package/esm/plugins/editable/EditableComponents/TextBox.js +19 -12
  130. package/esm/plugins/editable/EditablePlugin.js +13 -12
  131. package/esm/plugins/editable/decorateEditable.js +16 -8
  132. package/esm/plugins/editable/getEditorComponent.js +49 -38
  133. package/esm/plugins/expandable-grid/ExpandableColumn.js +56 -47
  134. package/esm/plugins/expandable-grid/ExpandablePlugin.js +33 -20
  135. package/esm/plugins/expandable-grid/ExpandedRow.js +27 -17
  136. package/esm/plugins/expandable-grid/ExpandedRowExtra.js +15 -9
  137. package/esm/plugins/expandable-grid/useExpandGridState.js +1 -2
  138. package/esm/plugins/export-data/ExportDataPlugin.js +22 -9
  139. package/esm/plugins/filterable/FilterablePlugin.js +5 -4
  140. package/esm/plugins/filterable/addFilterToColumn.js +5 -0
  141. package/esm/plugins/filterable/components/FilterableHeader.js +31 -22
  142. package/esm/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js +38 -31
  143. package/esm/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js +26 -21
  144. package/esm/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js +118 -152
  145. package/esm/plugins/filterable/components/filterable-menus/TextFilterMenu.js +27 -18
  146. package/esm/plugins/filterable/filterableFormatter.js +15 -10
  147. package/esm/plugins/filterable/filtering-helper/filterRowsByQuery.js +14 -2
  148. package/esm/plugins/filterable/filtering-helper/strategiesOperators.js +7 -4
  149. package/esm/plugins/filterable/helper.js +10 -1
  150. package/esm/plugins/filterable/useFilterableState.js +11 -5
  151. package/esm/plugins/grouping-by/GroupingByPlugin.js +2 -0
  152. package/esm/plugins/grouping-grid/GroupingPlugin.js +9 -0
  153. package/esm/plugins/grouping-grid/walkStrategy.js +11 -9
  154. package/esm/plugins/infinite-scrolling/InfiniteScrollPlugin.js +7 -1
  155. package/esm/plugins/pagination/PaginationPlugin.js +8 -1
  156. package/esm/plugins/pagination/components/Pagination.js +10 -9
  157. package/esm/plugins/pagination/components/Paginator.js +8 -7
  158. package/esm/plugins/pagination/components/PerPageDropdown.js +17 -9
  159. package/esm/plugins/pagination/helper.js +10 -7
  160. package/esm/plugins/pagination/usePaginationState.js +6 -1
  161. package/esm/plugins/resizable/ResizablePlugin.js +4 -3
  162. package/esm/plugins/resizable/decorateResizable.js +14 -8
  163. package/esm/plugins/resizable/useResizeHandle.js +21 -16
  164. package/esm/plugins/resizable/utils.js +6 -3
  165. package/esm/plugins/row-dnd/DndRowsPlugin.js +21 -13
  166. package/esm/plugins/selectable/SelectablePlugin.js +9 -7
  167. package/esm/plugins/selectable/addSelectableColumn.js +24 -16
  168. package/esm/plugins/selectable/helper.js +10 -1
  169. package/esm/plugins/selectable/selectableFormatter.js +79 -68
  170. package/esm/plugins/selectable/useSelectableState.js +19 -5
  171. package/esm/plugins/sortable/SortablePlugin.js +5 -4
  172. package/esm/plugins/sortable/sortHeaderFormatter.js +12 -11
  173. package/esm/plugins/sortable/sortTree.js +13 -3
  174. package/esm/plugins/sortable/sorter.js +151 -134
  175. package/esm/plugins/sortable/useSortableState.js +7 -0
  176. package/esm/plugins/toolbar/RowRenderer.js +6 -1
  177. package/esm/plugins/toolbar/ToolbarTrigger.js +14 -8
  178. package/esm/plugins/virtualization/AutoHeightList.js +6 -3
  179. package/esm/plugins/virtualization/VirtualizationPlugin.js +31 -24
  180. package/esm/plugins/virtualization/VirtualizedBody.js +14 -5
  181. package/esm/plugins/virtualization/VirtualizedBodyRow.js +8 -7
  182. package/esm/renders/CellWithAddons.js +15 -14
  183. package/esm/renders/styled.js +1 -1
  184. package/esm/utilities/getPluginsFromProps.js +5 -1
  185. package/esm/utilities/getScrollbarSize.js +2 -1
  186. package/esm/utilities/normalizeData.js +7 -1
  187. package/package.json +19 -18
  188. package/types/components/BodyCell.d.ts +1 -1
  189. package/types/components/HeaderCell.d.ts +1 -1
  190. package/types/plugins/column-sizing/columnMeasurerTransformer.d.ts +1 -1
  191. package/types/plugins/column-sizing/ext-points/getTableProps.d.ts +1 -1
  192. package/types/plugins/expandable-grid/ExpandedRowExtra.d.ts +1 -1
  193. package/types/plugins/expandable-grid/useExpandGridState.d.ts +4 -4
  194. package/types/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.d.ts +1 -1
  195. package/types/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.d.ts +1 -1
  196. package/types/plugins/filterable/components/filterable-menus/TextFilterMenu.d.ts +1 -1
  197. package/types/plugins/filterable/helper.d.ts +15 -3
  198. package/types/plugins/pagination/components/PerPageDropdown.d.ts +1 -1
@@ -1,8 +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 _objectWithoutProperties from '@babel/runtime/helpers/esm/objectWithoutProperties';
2
7
  import _jsx from '@babel/runtime/helpers/esm/jsx';
3
8
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
4
9
  import { useMemo, useRef, useEffect } from 'react';
5
- import { mergeRefs } from '@elliemae/ds-utilities/system';
10
+ import { mergeRefs } from '@elliemae/ds-utilities';
6
11
  import { ScrollSync, ScrollSyncPane } from '@elliemae/ds-shared/ScrollSync';
7
12
  import createInstancePlugin from '@elliemae/ds-shared/createDataInstance/createInstancePlugin';
8
13
  import { getScrollbarWidth } from '../../utilities/getScrollbarSize.js';
@@ -15,13 +20,16 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
15
20
  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; }
16
21
  getScrollbarWidth(2);
17
22
 
18
- const HeaderSyncHoc = Component => props => /*#__PURE__*/_jsx(ScrollSyncPane, {}, void 0, ({
19
- registerPane
20
- }) => /*#__PURE__*/jsx(Component, _objectSpread(_objectSpread({}, props), {}, {
21
- innerRef: mergeRefs(props.innerRef, registerPane)
22
- })));
23
+ const HeaderSyncHoc = Component => props => /*#__PURE__*/_jsx(ScrollSyncPane, {}, void 0, _ref => {
24
+ let {
25
+ registerPane
26
+ } = _ref;
27
+ return /*#__PURE__*/jsx(Component, _objectSpread(_objectSpread({}, props), {}, {
28
+ innerRef: mergeRefs(props.innerRef, registerPane)
29
+ }));
30
+ });
23
31
 
24
- const BodySyncHoc = (Component, notPaginated, grid) => _ref => {
32
+ const BodySyncHoc = (Component, notPaginated, grid) => _ref2 => {
25
33
  let {
26
34
  children,
27
35
  classProps,
@@ -44,8 +52,8 @@ const BodySyncHoc = (Component, notPaginated, grid) => _ref => {
44
52
  useDragHandle,
45
53
  className,
46
54
  listComponent
47
- } = _ref,
48
- rest = _objectWithoutProperties(_ref, _excluded);
55
+ } = _ref2,
56
+ rest = _objectWithoutProperties(_ref2, _excluded);
49
57
 
50
58
  const t = useRef();
51
59
 
@@ -65,32 +73,35 @@ const BodySyncHoc = (Component, notPaginated, grid) => _ref => {
65
73
  });
66
74
  return /*#__PURE__*/_jsx(ScrollSyncPane, {
67
75
  notPaginated: notPaginated
68
- }, void 0, ({
69
- registerPane
70
- }) => /*#__PURE__*/jsx(Component, _objectSpread({
71
- ref: t,
72
- classProps: classProps,
73
- className: className,
74
- listComponent: listComponent,
75
- columns: columns,
76
- getContainer: getContainer,
77
- helperClass: helperClass,
78
- innerBodyRef: innerBodyRef // innerRef={innerRef}
79
- ,
80
- isPlaceholderActive: isPlaceholderActive,
81
- listProps: listProps,
82
- lockAxis: lockAxis,
83
- noResultsPlaceholder: noResultsPlaceholder,
84
- numRowsVisible: numRowsVisible,
85
- onSortEnd: onSortEnd,
86
- onSortOver: onSortOver,
87
- onSortStart: onSortStart,
88
- rowKey: rowKey,
89
- rowRenderer: rowRenderer,
90
- rows: rows,
91
- useDragHandle: useDragHandle,
92
- innerRef: mergeRefs(innerRef, registerPane, t)
93
- }, rest)));
76
+ }, void 0, _ref3 => {
77
+ let {
78
+ registerPane
79
+ } = _ref3;
80
+ return /*#__PURE__*/jsx(Component, _objectSpread({
81
+ ref: t,
82
+ classProps: classProps,
83
+ className: className,
84
+ listComponent: listComponent,
85
+ columns: columns,
86
+ getContainer: getContainer,
87
+ helperClass: helperClass,
88
+ innerBodyRef: innerBodyRef // innerRef={innerRef}
89
+ ,
90
+ isPlaceholderActive: isPlaceholderActive,
91
+ listProps: listProps,
92
+ lockAxis: lockAxis,
93
+ noResultsPlaceholder: noResultsPlaceholder,
94
+ numRowsVisible: numRowsVisible,
95
+ onSortEnd: onSortEnd,
96
+ onSortOver: onSortOver,
97
+ onSortStart: onSortStart,
98
+ rowKey: rowKey,
99
+ rowRenderer: rowRenderer,
100
+ rows: rows,
101
+ useDragHandle: useDragHandle,
102
+ innerRef: mergeRefs(innerRef, registerPane, t)
103
+ }, rest));
104
+ });
94
105
  };
95
106
 
96
107
  const TableSyncHoc = Component => props => /*#__PURE__*/_jsx(ScrollSync, {
@@ -1,8 +1,12 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
3
+ import 'core-js/modules/esnext.iterator.constructor.js';
4
+ import 'core-js/modules/esnext.iterator.for-each.js';
5
+ import 'core-js/modules/esnext.async-iterator.filter.js';
6
+ import 'core-js/modules/esnext.iterator.filter.js';
2
7
  import { useRef, useEffect, useMemo } from 'react';
3
8
  import { SortableContainer, SortableElement } from 'react-sortable-hoc';
4
- import { omit, arrayMove } from '@elliemae/ds-utilities/utils';
5
- import { mergeRefs } from '@elliemae/ds-utilities/system';
9
+ import { mergeRefs, omit, arrayMove } from '@elliemae/ds-utilities';
6
10
  import createInstancePlugin from '@elliemae/ds-shared/createDataInstance/createInstancePlugin';
7
11
  import { addDragAndDropToColumn } from './decorateGridWithDndColumns.js';
8
12
  import { jsx } from 'react/jsx-runtime';
@@ -1,7 +1,7 @@
1
1
  import _jsx from '@babel/runtime/helpers/esm/jsx';
2
2
  import 'react';
3
3
  import { SortableHandle } from 'react-sortable-hoc';
4
- import GripperVertical from '@elliemae/ds-icons/GripperVertical';
4
+ import { GripperVertical } from '@elliemae/ds-icons';
5
5
  import { appendHeaderFormatter, mergeClassNameToColumnHeader } from '@elliemae/ds-shared/useDataGrid/initColumnDefinition';
6
6
  import { jsxs, Fragment } from 'react/jsx-runtime';
7
7
 
@@ -1,5 +1,5 @@
1
1
  import { useRef } from 'react';
2
- import { cx } from '@elliemae/ds-utilities/utils';
2
+ import { cx } from '@elliemae/ds-utilities';
3
3
  import createInstancePlugin from '@elliemae/ds-shared/createDataInstance/createInstancePlugin';
4
4
  import { useStylesheetHelpers } from './useStylesheetHelpers.js';
5
5
  import useColumnSizeService from './useColumnSizeService.js';
@@ -8,16 +8,18 @@ import { decorateColumn } from './ext-points/decorateColumn.js';
8
8
 
9
9
  /* eslint-disable no-param-reassign */
10
10
 
11
- const getHeaderRowProps = (rowProps, {
12
- rowsStylesheet
13
- }) => {
11
+ const getHeaderRowProps = (rowProps, _ref) => {
12
+ let {
13
+ rowsStylesheet
14
+ } = _ref;
14
15
  rowProps.className = "".concat(rowsStylesheet.getRowClassName(), "-header");
15
16
  return rowProps;
16
17
  };
17
18
 
18
- const getRowProps = (rowProps, {
19
- rowsStylesheet
20
- }) => {
19
+ const getRowProps = (rowProps, _ref2) => {
20
+ let {
21
+ rowsStylesheet
22
+ } = _ref2;
21
23
  rowProps.className = cx(rowProps.className, rowsStylesheet.getRowClassName());
22
24
  return rowProps;
23
25
  };
@@ -1,14 +1,21 @@
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 { useRef, useLayoutEffect } from 'react';
3
- import { mergeRefs } from '@elliemae/ds-utilities/system';
8
+ import { mergeRefs } from '@elliemae/ds-utilities';
4
9
 
5
10
  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
11
 
7
12
  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 columnMeasurerTransformer = columnSizeService => (value, {
9
- column,
10
- grid
11
- }, props = {}) => {
13
+ const columnMeasurerTransformer = columnSizeService => function (value, _ref) {
14
+ let {
15
+ column,
16
+ grid
17
+ } = _ref;
18
+ let props = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
12
19
  const {
13
20
  registerColumn
14
21
  } = columnSizeService;
@@ -1,4 +1,4 @@
1
- import { get, set } from '@elliemae/ds-utilities/utils';
1
+ import { get, set } from '@elliemae/ds-utilities';
2
2
  import { columnMeasurerTransformer } from '../columnMeasurerTransformer.js';
3
3
 
4
4
  function decorateColumn(column, grid, index) {
@@ -1,27 +1,33 @@
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 'core-js/modules/web.dom-collections.iterator.js';
3
8
  import { useState, useEffect } from 'react';
4
- import useResizeObserver from '@elliemae/ds-utilities/hooks/useResizeObserver';
5
- import { mergeRefs } from '@elliemae/ds-utilities/system';
9
+ import { useResizeObserver, mergeRefs } from '@elliemae/ds-utilities';
6
10
  import { getScrollbarSizeFromHeaderAndBody } from '../utils.js';
7
11
 
8
12
  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; }
9
13
 
10
14
  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; }
11
- function getTableProps(tableProps, {
12
- refs,
13
- tableRef,
14
- bodyWidth,
15
- scrollbarWidth,
16
- isDragging,
17
- columnSizeService,
18
- updateRowWidth,
19
- columns
20
- }) {
15
+ function getTableProps(tableProps, _ref) {
16
+ let {
17
+ refs,
18
+ tableRef,
19
+ bodyWidth,
20
+ scrollbarWidth,
21
+ isDragging,
22
+ columnSizeService,
23
+ updateRowWidth,
24
+ columns
25
+ } = _ref;
21
26
  const [tableNode, tableRefCallback] = useState();
22
- useResizeObserver(({
23
- width
24
- }) => {
27
+ useResizeObserver(_ref2 => {
28
+ let {
29
+ width
30
+ } = _ref2;
25
31
  if (!refs.header.current) return;
26
32
  if (typeof scrollbarWidth.current !== 'number') scrollbarWidth.current = getScrollbarSizeFromHeaderAndBody(refs);
27
33
  if (typeof bodyWidth.current !== 'number') bodyWidth.current = refs.body.offsetWidth; // DataGrid: header with width 0 after redirect from details page (https://jira.elliemae.io/browse/PUI-2162)
@@ -1,5 +1,14 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
2
  import 'core-js/modules/web.dom-collections.iterator.js';
3
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
4
+ import 'core-js/modules/esnext.iterator.constructor.js';
5
+ import 'core-js/modules/esnext.iterator.for-each.js';
6
+ import 'core-js/modules/esnext.async-iterator.map.js';
7
+ import 'core-js/modules/esnext.iterator.map.js';
8
+ import 'core-js/modules/esnext.async-iterator.filter.js';
9
+ import 'core-js/modules/esnext.iterator.filter.js';
10
+ import 'core-js/modules/esnext.async-iterator.reduce.js';
11
+ import 'core-js/modules/esnext.iterator.reduce.js';
3
12
  import { useRef, useState, useLayoutEffect } from 'react';
4
13
  import { getColumnWidthSize, getPercentageValue } from './utils.js';
5
14
 
@@ -1,15 +1,18 @@
1
+ import 'core-js/modules/esnext.async-iterator.map.js';
2
+ import 'core-js/modules/esnext.iterator.map.js';
1
3
  import 'core-js/modules/web.dom-collections.iterator.js';
2
4
  import * as stylesheet from 'stylesheet-helpers';
3
5
  import { useState, useEffect } from 'react';
4
- import { set } from '@elliemae/ds-utilities/utils';
6
+ import { set } from '@elliemae/ds-utilities';
5
7
  import getColumnFromProperty from './getColumnNameFromProperty.js';
6
8
  import { getScrollbarWidth } from '../../utilities/getScrollbarSize.js';
7
9
 
8
10
  const SCROLLBAR_WIDTH = getScrollbarWidth();
9
- const RowStylesheetHelper = ({
10
- grid,
11
- className
12
- }) => {
11
+ const RowStylesheetHelper = _ref => {
12
+ let {
13
+ grid,
14
+ className
15
+ } = _ref;
13
16
  const {
14
17
  styleSheet,
15
18
  styleSheetElement
@@ -52,19 +55,23 @@ const RowStylesheetHelper = ({
52
55
  };
53
56
  };
54
57
 
55
- const getColumnClassName = ({
56
- globalId,
57
- column,
58
- isHeader = false,
59
- getId
60
- }) => "column-".concat(globalId, "-").concat(getId(column)).concat(isHeader ? '-header' : '');
61
-
62
- function setWidth({
63
- styleSheet,
64
- className,
65
- width,
66
- minWidth
67
- }) {
58
+ const getColumnClassName = _ref2 => {
59
+ let {
60
+ globalId,
61
+ column,
62
+ isHeader = false,
63
+ getId
64
+ } = _ref2;
65
+ return "column-".concat(globalId, "-").concat(getId(column)).concat(isHeader ? '-header' : '');
66
+ };
67
+
68
+ function setWidth(_ref3) {
69
+ let {
70
+ styleSheet,
71
+ className,
72
+ width,
73
+ minWidth
74
+ } = _ref3;
68
75
  let widths;
69
76
  if (typeof width === 'string') widths = width;
70
77
  if (typeof width === 'number') widths = "".concat(width, "px");
@@ -79,31 +86,37 @@ function setWidth({
79
86
  });
80
87
  }
81
88
 
82
- function updateStyle({
83
- styleSheet,
84
- className,
85
- style
86
- }) {
89
+ function updateStyle(_ref4) {
90
+ let {
91
+ styleSheet,
92
+ className,
93
+ style
94
+ } = _ref4;
87
95
  stylesheet.updateProperties(window, styleSheet, className, style);
88
96
  }
89
97
 
90
- function columnSizesHelperImpl({
91
- globalId,
92
- getId = ({
93
- property
94
- }) => getColumnFromProperty(property)
95
- }) {
98
+ function columnSizesHelperImpl(_ref5) {
99
+ let {
100
+ globalId,
101
+ getId = _ref6 => {
102
+ let {
103
+ property
104
+ } = _ref6;
105
+ return getColumnFromProperty(property);
106
+ }
107
+ } = _ref5;
96
108
  const {
97
109
  styleSheetElement,
98
110
  styleSheet
99
111
  } = stylesheet.create();
100
112
 
101
- const updateBodyHeaderWidth = ({
102
- className,
103
- headerClassName,
104
- width,
105
- minWidth
106
- }) => {
113
+ const updateBodyHeaderWidth = _ref7 => {
114
+ let {
115
+ className,
116
+ headerClassName,
117
+ width,
118
+ minWidth
119
+ } = _ref7;
107
120
  setWidth({
108
121
  styleSheet,
109
122
  className,
@@ -210,9 +223,12 @@ function useStylesheetHelpers(grid) {
210
223
  } = grid;
211
224
  const [columnsStylesheet] = useState(() => columnSizesHelperImpl({
212
225
  globalId: bindColumnsSizeTo || grid.uuid,
213
- getId: ({
214
- uuid
215
- }) => getColumnFromProperty(uuid)
226
+ getId: _ref8 => {
227
+ let {
228
+ uuid
229
+ } = _ref8;
230
+ return getColumnFromProperty(uuid);
231
+ }
216
232
  }));
217
233
  const rowClassName = "row-".concat(bindRowSizeTo || grid.uuid);
218
234
  const [rowsStylesheet] = useState(() => RowStylesheetHelper({
@@ -1,4 +1,7 @@
1
- import { get } from '@elliemae/ds-utilities/utils';
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';
4
+ import { get } from '@elliemae/ds-utilities';
2
5
 
3
6
  function getScrollbarSizeFromHeaderAndBody(refs) {
4
7
  const innerBodyOffsetWidth = get(refs, ['innerBody', 'current', 'offsetWidth']);
@@ -21,9 +24,10 @@ const getColumnWidthSize = (width, minWidth, column) => {
21
24
  };
22
25
  const calculateMinWidthForWrappedText = columns => {
23
26
  let longestWord = 0;
24
- columns.forEach(({
25
- label
26
- }) => {
27
+ columns.forEach(_ref => {
28
+ let {
29
+ label
30
+ } = _ref;
27
31
  const localLongestWord = label.split(' ').sort((a, b) => b.length - a.length)[0].length;
28
32
  if (localLongestWord > longestWord) longestWord = localLongestWord;
29
33
  });
@@ -1,5 +1,10 @@
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
- import { get, isFunction } from '@elliemae/ds-utilities/utils';
7
+ import { get, isFunction } from '@elliemae/ds-utilities';
3
8
  import { appendCellFormatter } from '@elliemae/ds-shared/useDataGrid/initColumnDefinition';
4
9
  import getRendererComponent from './getRendererComponent.js';
5
10
 
@@ -1,12 +1,13 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
2
2
  import _objectWithoutProperties from '@babel/runtime/helpers/esm/objectWithoutProperties';
3
+ import 'core-js/modules/esnext.async-iterator.for-each.js';
4
+ import 'core-js/modules/esnext.iterator.constructor.js';
5
+ import 'core-js/modules/esnext.iterator.for-each.js';
6
+ import 'core-js/modules/esnext.async-iterator.filter.js';
7
+ import 'core-js/modules/esnext.iterator.filter.js';
3
8
  import 'react';
4
- import DSButton from '@elliemae/ds-basic/Button';
5
- import DSCheckbox from '@elliemae/ds-basic/form/Checkbox';
6
- import DSComboBox from '@elliemae/ds-basic/form/ComboBox';
7
- import DSRadio from '@elliemae/ds-basic/form/Radio';
8
- import DSTextBox from '@elliemae/ds-basic/form/TextBox';
9
- import DSToggle from '@elliemae/ds-basic/form/Toggle';
9
+ import DSButton from '@elliemae/ds-button';
10
+ import { DSCheckbox, DSComboBox, DSRadio, DSTextBox, DSToggle } from '@elliemae/ds-form';
10
11
  import DSDropdownMenu from '@elliemae/ds-dropdownmenu';
11
12
  import * as index from '../../components/renderers/index.js';
12
13
  import { jsx } from 'react/jsx-runtime';
@@ -26,11 +27,14 @@ const components = {
26
27
  DSDropdownMenu
27
28
  };
28
29
 
29
- const getRendererComponent = ({
30
- props
31
- }, _ref, {
32
- rowData
33
- }) => {
30
+ const getRendererComponent = (_ref2, _ref, _ref3) => {
31
+ let {
32
+ props
33
+ } = _ref2;
34
+ let {
35
+ rowData
36
+ } = _ref3;
37
+
34
38
  let {
35
39
  type = 'DSTextBox',
36
40
  handlers
@@ -1,6 +1,11 @@
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 { Component } from 'react';
3
- import DSComboBox from '@elliemae/ds-basic/form/ComboBox';
8
+ import { DSComboBox } from '@elliemae/ds-form';
4
9
  import { jsx } from 'react/jsx-runtime';
5
10
 
6
11
  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; }
@@ -1,6 +1,11 @@
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 React, { Component } from 'react';
3
- import DSTextBox from '@elliemae/ds-basic/form/TextBox';
8
+ import { DSTextBox } from '@elliemae/ds-form';
4
9
  import { jsx } from 'react/jsx-runtime';
5
10
 
6
11
  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; }
@@ -27,12 +32,13 @@ class TextBox extends Component {
27
32
  }, 50);
28
33
  }
29
34
 
30
- handleKeyUp({
31
- key,
32
- target: {
33
- value
34
- }
35
- }) {
35
+ handleKeyUp(_ref) {
36
+ let {
37
+ key,
38
+ target: {
39
+ value
40
+ }
41
+ } = _ref;
36
42
  const {
37
43
  onValue
38
44
  } = this.props;
@@ -61,11 +67,12 @@ class TextBox extends Component {
61
67
  onValue(value);
62
68
  }
63
69
 
64
- handleChange({
65
- target: {
66
- value
67
- }
68
- }) {
70
+ handleChange(_ref2) {
71
+ let {
72
+ target: {
73
+ value
74
+ }
75
+ } = _ref2;
69
76
  this.setState({
70
77
  value
71
78
  });
@@ -1,6 +1,5 @@
1
1
  import 'core-js/modules/web.dom-collections.iterator.js';
2
- import useDerivedStateFromProps from '@elliemae/ds-utilities/hooks/useDerivedStateFromProps';
3
- import { toggleInObject } from '@elliemae/ds-utilities/utils';
2
+ import { useDerivedStateFromProps, toggleInObject } from '@elliemae/ds-utilities';
4
3
  import createInstancePlugin from '@elliemae/ds-shared/createDataInstance/createInstancePlugin';
5
4
  import { makeEditableConfig, addEditableToCell } from './decorateEditable.js';
6
5
 
@@ -31,12 +30,13 @@ const registerStateHook = grid => {
31
30
  });
32
31
  };
33
32
 
34
- const editValue = ({
35
- value,
36
- rowData,
37
- property,
38
- rowIndex
39
- }) => {
33
+ const editValue = _ref => {
34
+ let {
35
+ value,
36
+ rowData,
37
+ property,
38
+ rowIndex
39
+ } = _ref;
40
40
  setEditingRows({});
41
41
  onColumnRowEdited({
42
42
  value,
@@ -79,10 +79,11 @@ const EditablePlugin = createInstancePlugin('editable', {
79
79
  registerHotKeys(grid) {
80
80
  return {
81
81
  key: 'enter',
82
- handler: ({
83
- rowIndex,
84
- cellIndex
85
- }) => {
82
+ handler: _ref2 => {
83
+ let {
84
+ rowIndex,
85
+ cellIndex
86
+ } = _ref2;
86
87
  const {
87
88
  composedRows,
88
89
  decoratedColumns,
@@ -1,11 +1,16 @@
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 _objectWithoutProperties from '@babel/runtime/helpers/esm/objectWithoutProperties';
4
9
  import 'core-js/modules/web.dom-collections.iterator.js';
5
10
  import 'react';
6
11
  import * as edit from 'react-edit';
7
- import EditPencil from '@elliemae/ds-icons/EditPencil';
8
- import { cx } from '@elliemae/ds-utilities/utils';
12
+ import { EditPencil } from '@elliemae/ds-icons';
13
+ import { cx } from '@elliemae/ds-utilities';
9
14
  import { appendCellFormatter } from '@elliemae/ds-shared/useDataGrid/initColumnDefinition';
10
15
  import getEditorComponent from './getEditorComponent.js';
11
16
  import { jsx, Fragment } from 'react/jsx-runtime';
@@ -48,14 +53,17 @@ const makeEditableConfig = grid => edit.edit({
48
53
  return editingRows[rowData[rowKey]] === columnIndex || column.alwaysEditing || isCustomEditing;
49
54
  },
50
55
  onActivate: () => null,
51
- onValue: (...args) => grid.getInstance().actions.editValue(...args)
56
+ onValue: function () {
57
+ return grid.getInstance().actions.editValue(...arguments);
58
+ }
52
59
  });
53
60
 
54
- const addEditableToCell = ({
55
- column,
56
- config,
57
- handlers
58
- }, grid) => {
61
+ const addEditableToCell = (_ref2, grid) => {
62
+ let {
63
+ column,
64
+ config,
65
+ handlers
66
+ } = _ref2;
59
67
  column.cell.transforms.push(config(getEditorComponent(column.customEditor, handlers)));
60
68
  column.cell.props.className = cx(column.cell.props.className, "editable".concat(column.customEditor ? ' customEditor' : ''));
61
69
  return appendCellFormatter([(value, extraParams) => /*#__PURE__*/jsx(Fragment, {