@elliemae/ds-data-table 2.4.1-rc.9 → 2.4.2-rc.1
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.
- package/cjs/addons/Editables/ComboboxEditableCell/ComboboxEditableCell.js +3 -4
- package/cjs/addons/Filters/Components/SelectFilter/BaseSelectFilter.js +8 -12
- package/esm/addons/Editables/ComboboxEditableCell/ComboboxEditableCell.js +3 -4
- package/esm/addons/Filters/Components/SelectFilter/BaseSelectFilter.js +9 -13
- package/package.json +19 -19
|
@@ -86,8 +86,6 @@ const ComboboxEditableCell = props => {
|
|
|
86
86
|
}, []);
|
|
87
87
|
}, [flattenedData, columnId]);
|
|
88
88
|
|
|
89
|
-
const filterOptions = newFilter => uniqueOptions.filter(option => option.type === 'separator' || option.label.toLowerCase().includes(newFilter.toLowerCase()));
|
|
90
|
-
|
|
91
89
|
const [currentOptions, setCurrentOptions] = React.useState(uniqueOptions);
|
|
92
90
|
const handleOnBlur = React.useCallback(() => {
|
|
93
91
|
const property = columnId;
|
|
@@ -105,8 +103,9 @@ const ComboboxEditableCell = props => {
|
|
|
105
103
|
withoutPortal: false,
|
|
106
104
|
onBlur: handleOnBlur,
|
|
107
105
|
onChange: setValue,
|
|
108
|
-
|
|
109
|
-
|
|
106
|
+
allOptions: uniqueOptions,
|
|
107
|
+
onFilter: setCurrentOptions,
|
|
108
|
+
filteredOptions: currentOptions
|
|
110
109
|
}),
|
|
111
110
|
cell: cell,
|
|
112
111
|
isRowSelected: isRowSelected
|
|
@@ -22,9 +22,6 @@ require('core-js/modules/esnext.set.reduce.js');
|
|
|
22
22
|
require('core-js/modules/esnext.set.some.js');
|
|
23
23
|
require('core-js/modules/esnext.set.symmetric-difference.js');
|
|
24
24
|
require('core-js/modules/esnext.set.union.js');
|
|
25
|
-
require('core-js/modules/esnext.async-iterator.filter.js');
|
|
26
|
-
require('core-js/modules/esnext.iterator.constructor.js');
|
|
27
|
-
require('core-js/modules/esnext.iterator.filter.js');
|
|
28
25
|
var React = require('react');
|
|
29
26
|
var Grid = require('@elliemae/ds-grid');
|
|
30
27
|
var dsControlledForm = require('@elliemae/ds-controlled-form');
|
|
@@ -37,6 +34,9 @@ require('styled-components');
|
|
|
37
34
|
require('@elliemae/ds-button');
|
|
38
35
|
require('@elliemae/ds-utilities');
|
|
39
36
|
var constants = require('../../../../configs/constants.js');
|
|
37
|
+
require('core-js/modules/esnext.async-iterator.filter.js');
|
|
38
|
+
require('core-js/modules/esnext.iterator.constructor.js');
|
|
39
|
+
require('core-js/modules/esnext.iterator.filter.js');
|
|
40
40
|
require('core-js/modules/esnext.async-iterator.reduce.js');
|
|
41
41
|
require('core-js/modules/esnext.iterator.reduce.js');
|
|
42
42
|
require('react-virtual');
|
|
@@ -107,10 +107,6 @@ const BaseSelectFilter = props => {
|
|
|
107
107
|
React.useEffect(() => {
|
|
108
108
|
setFilteredOptions(filterOptions);
|
|
109
109
|
}, [filterOptions]);
|
|
110
|
-
const filteredOptions = React.useCallback(filter => filterOptions.filter(option => option.type === 'separator' || option.label.toLowerCase().includes(filter.toLowerCase())), [filterOptions]);
|
|
111
|
-
const handleOnFilter = React.useCallback(newFilter => {
|
|
112
|
-
setFilteredOptions(filteredOptions(newFilter));
|
|
113
|
-
}, [filteredOptions]);
|
|
114
110
|
|
|
115
111
|
const Select = /*#__PURE__*/_jsx__default["default"](Grid.Grid, {
|
|
116
112
|
"data-testid": isMulti ? constants.DATA_TESTID.DATA_TABLE_MULTISELECT_CONTROLLER : constants.DATA_TESTID.DATA_TABLE_SINGLESELECT_CONTROLLER,
|
|
@@ -121,15 +117,16 @@ const BaseSelectFilter = props => {
|
|
|
121
117
|
}, void 0, /*#__PURE__*/_jsx__default["default"](dsControlledForm.DSComboBox, {
|
|
122
118
|
inline: true,
|
|
123
119
|
autoFocus: true,
|
|
124
|
-
|
|
120
|
+
allOptions: filterOptions,
|
|
121
|
+
filteredOptions: filters,
|
|
125
122
|
onChange: handleOnChange,
|
|
126
123
|
selectedValues: selectedItems,
|
|
127
|
-
onFilter:
|
|
124
|
+
onFilter: setFilteredOptions,
|
|
128
125
|
menuMaxHeight: 300
|
|
129
126
|
}));
|
|
130
127
|
|
|
131
128
|
const handleOnClickOutside = () => {
|
|
132
|
-
setFilteredOptions(
|
|
129
|
+
setFilteredOptions(filterOptions);
|
|
133
130
|
};
|
|
134
131
|
|
|
135
132
|
return /*#__PURE__*/_jsx__default["default"](FilterPopover.FilterPopover, {
|
|
@@ -140,8 +137,7 @@ const BaseSelectFilter = props => {
|
|
|
140
137
|
triggerIcon: _SearchXsmall || (_SearchXsmall = /*#__PURE__*/_jsx__default["default"](dsIcons.SearchXsmall, {})),
|
|
141
138
|
innerRef: innerRef,
|
|
142
139
|
ariaLabel: "Open Selection Filter",
|
|
143
|
-
onClickOutsideMenu: handleOnClickOutside
|
|
144
|
-
customStyles: {}
|
|
140
|
+
onClickOutsideMenu: handleOnClickOutside
|
|
145
141
|
});
|
|
146
142
|
};
|
|
147
143
|
|
|
@@ -78,8 +78,6 @@ const ComboboxEditableCell = props => {
|
|
|
78
78
|
}, []);
|
|
79
79
|
}, [flattenedData, columnId]);
|
|
80
80
|
|
|
81
|
-
const filterOptions = newFilter => uniqueOptions.filter(option => option.type === 'separator' || option.label.toLowerCase().includes(newFilter.toLowerCase()));
|
|
82
|
-
|
|
83
81
|
const [currentOptions, setCurrentOptions] = useState(uniqueOptions);
|
|
84
82
|
const handleOnBlur = useCallback(() => {
|
|
85
83
|
const property = columnId;
|
|
@@ -97,8 +95,9 @@ const ComboboxEditableCell = props => {
|
|
|
97
95
|
withoutPortal: false,
|
|
98
96
|
onBlur: handleOnBlur,
|
|
99
97
|
onChange: setValue,
|
|
100
|
-
|
|
101
|
-
|
|
98
|
+
allOptions: uniqueOptions,
|
|
99
|
+
onFilter: setCurrentOptions,
|
|
100
|
+
filteredOptions: currentOptions
|
|
102
101
|
}),
|
|
103
102
|
cell: cell,
|
|
104
103
|
isRowSelected: isRowSelected
|
|
@@ -18,10 +18,7 @@ import 'core-js/modules/esnext.set.reduce.js';
|
|
|
18
18
|
import 'core-js/modules/esnext.set.some.js';
|
|
19
19
|
import 'core-js/modules/esnext.set.symmetric-difference.js';
|
|
20
20
|
import 'core-js/modules/esnext.set.union.js';
|
|
21
|
-
import '
|
|
22
|
-
import 'core-js/modules/esnext.iterator.constructor.js';
|
|
23
|
-
import 'core-js/modules/esnext.iterator.filter.js';
|
|
24
|
-
import { useMemo, useState, useEffect, useCallback } from 'react';
|
|
21
|
+
import { useMemo, useState, useEffect } from 'react';
|
|
25
22
|
import { Grid } from '@elliemae/ds-grid';
|
|
26
23
|
import { DSComboBox } from '@elliemae/ds-controlled-form';
|
|
27
24
|
import { SearchXsmall } from '@elliemae/ds-icons';
|
|
@@ -33,6 +30,9 @@ import 'styled-components';
|
|
|
33
30
|
import '@elliemae/ds-button';
|
|
34
31
|
import '@elliemae/ds-utilities';
|
|
35
32
|
import { DATA_TESTID } from '../../../../configs/constants.js';
|
|
33
|
+
import 'core-js/modules/esnext.async-iterator.filter.js';
|
|
34
|
+
import 'core-js/modules/esnext.iterator.constructor.js';
|
|
35
|
+
import 'core-js/modules/esnext.iterator.filter.js';
|
|
36
36
|
import 'core-js/modules/esnext.async-iterator.reduce.js';
|
|
37
37
|
import 'core-js/modules/esnext.iterator.reduce.js';
|
|
38
38
|
import 'react-virtual';
|
|
@@ -99,10 +99,6 @@ const BaseSelectFilter = props => {
|
|
|
99
99
|
useEffect(() => {
|
|
100
100
|
setFilteredOptions(filterOptions);
|
|
101
101
|
}, [filterOptions]);
|
|
102
|
-
const filteredOptions = useCallback(filter => filterOptions.filter(option => option.type === 'separator' || option.label.toLowerCase().includes(filter.toLowerCase())), [filterOptions]);
|
|
103
|
-
const handleOnFilter = useCallback(newFilter => {
|
|
104
|
-
setFilteredOptions(filteredOptions(newFilter));
|
|
105
|
-
}, [filteredOptions]);
|
|
106
102
|
|
|
107
103
|
const Select = /*#__PURE__*/_jsx(Grid, {
|
|
108
104
|
"data-testid": isMulti ? DATA_TESTID.DATA_TABLE_MULTISELECT_CONTROLLER : DATA_TESTID.DATA_TABLE_SINGLESELECT_CONTROLLER,
|
|
@@ -113,15 +109,16 @@ const BaseSelectFilter = props => {
|
|
|
113
109
|
}, void 0, /*#__PURE__*/_jsx(DSComboBox, {
|
|
114
110
|
inline: true,
|
|
115
111
|
autoFocus: true,
|
|
116
|
-
|
|
112
|
+
allOptions: filterOptions,
|
|
113
|
+
filteredOptions: filters,
|
|
117
114
|
onChange: handleOnChange,
|
|
118
115
|
selectedValues: selectedItems,
|
|
119
|
-
onFilter:
|
|
116
|
+
onFilter: setFilteredOptions,
|
|
120
117
|
menuMaxHeight: 300
|
|
121
118
|
}));
|
|
122
119
|
|
|
123
120
|
const handleOnClickOutside = () => {
|
|
124
|
-
setFilteredOptions(
|
|
121
|
+
setFilteredOptions(filterOptions);
|
|
125
122
|
};
|
|
126
123
|
|
|
127
124
|
return /*#__PURE__*/_jsx(FilterPopover, {
|
|
@@ -132,8 +129,7 @@ const BaseSelectFilter = props => {
|
|
|
132
129
|
triggerIcon: _SearchXsmall || (_SearchXsmall = /*#__PURE__*/_jsx(SearchXsmall, {})),
|
|
133
130
|
innerRef: innerRef,
|
|
134
131
|
ariaLabel: "Open Selection Filter",
|
|
135
|
-
onClickOutsideMenu: handleOnClickOutside
|
|
136
|
-
customStyles: {}
|
|
132
|
+
onClickOutsideMenu: handleOnClickOutside
|
|
137
133
|
});
|
|
138
134
|
};
|
|
139
135
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-data-table",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.2-rc.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Data Table",
|
|
6
6
|
"module": "./esm/index.js",
|
|
@@ -570,24 +570,24 @@
|
|
|
570
570
|
"dependencies": {
|
|
571
571
|
"@dnd-kit/core": "~4.0.1",
|
|
572
572
|
"@dnd-kit/sortable": "~5.0.0",
|
|
573
|
-
"@elliemae/ds-button": "2.4.
|
|
574
|
-
"@elliemae/ds-circular-progress-indicator": "2.4.
|
|
575
|
-
"@elliemae/ds-controlled-form": "2.4.
|
|
576
|
-
"@elliemae/ds-drag-and-drop": "2.4.
|
|
577
|
-
"@elliemae/ds-dropdownmenu": "2.4.
|
|
578
|
-
"@elliemae/ds-form": "2.4.
|
|
579
|
-
"@elliemae/ds-form-layout-blocks": "2.4.
|
|
580
|
-
"@elliemae/ds-grid": "2.4.
|
|
581
|
-
"@elliemae/ds-icons": "2.4.
|
|
582
|
-
"@elliemae/ds-indeterminate-progress-indicator": "2.4.
|
|
583
|
-
"@elliemae/ds-pagination": "2.4.
|
|
584
|
-
"@elliemae/ds-pills": "2.4.
|
|
585
|
-
"@elliemae/ds-popperjs": "2.4.
|
|
586
|
-
"@elliemae/ds-props-helpers": "2.4.
|
|
587
|
-
"@elliemae/ds-system": "2.4.
|
|
588
|
-
"@elliemae/ds-toolbar": "2.4.
|
|
589
|
-
"@elliemae/ds-truncated-tooltip-text": "2.4.
|
|
590
|
-
"@elliemae/ds-utilities": "2.4.
|
|
573
|
+
"@elliemae/ds-button": "2.4.2-rc.1",
|
|
574
|
+
"@elliemae/ds-circular-progress-indicator": "2.4.2-rc.1",
|
|
575
|
+
"@elliemae/ds-controlled-form": "2.4.2-rc.1",
|
|
576
|
+
"@elliemae/ds-drag-and-drop": "2.4.2-rc.1",
|
|
577
|
+
"@elliemae/ds-dropdownmenu": "2.4.2-rc.1",
|
|
578
|
+
"@elliemae/ds-form": "2.4.2-rc.1",
|
|
579
|
+
"@elliemae/ds-form-layout-blocks": "2.4.2-rc.1",
|
|
580
|
+
"@elliemae/ds-grid": "2.4.2-rc.1",
|
|
581
|
+
"@elliemae/ds-icons": "2.4.2-rc.1",
|
|
582
|
+
"@elliemae/ds-indeterminate-progress-indicator": "2.4.2-rc.1",
|
|
583
|
+
"@elliemae/ds-pagination": "2.4.2-rc.1",
|
|
584
|
+
"@elliemae/ds-pills": "2.4.2-rc.1",
|
|
585
|
+
"@elliemae/ds-popperjs": "2.4.2-rc.1",
|
|
586
|
+
"@elliemae/ds-props-helpers": "2.4.2-rc.1",
|
|
587
|
+
"@elliemae/ds-system": "2.4.2-rc.1",
|
|
588
|
+
"@elliemae/ds-toolbar": "2.4.2-rc.1",
|
|
589
|
+
"@elliemae/ds-truncated-tooltip-text": "2.4.2-rc.1",
|
|
590
|
+
"@elliemae/ds-utilities": "2.4.2-rc.1",
|
|
591
591
|
"@reduxjs/toolkit": "~1.6.2",
|
|
592
592
|
"csstype": "~3.0.9",
|
|
593
593
|
"moment": "~2.29.1",
|