@bento-core/facet-filter 1.0.1-CDS.7 → 1.0.1-CDS.8
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.
|
@@ -12,10 +12,13 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
12
12
|
// import FacetView from './FacetView';
|
|
13
13
|
|
|
14
14
|
const ReduxFacetModal = props => /*#__PURE__*/_react.default.createElement(_FacetModal.default, props);
|
|
15
|
-
const mapStateToProps = (state, ownProps) =>
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
const mapStateToProps = (state, ownProps) => {
|
|
16
|
+
var _state$statusReducer, _state$statusReducer$, _state$statusReducer2, _state$statusReducer3;
|
|
17
|
+
return {
|
|
18
|
+
searchText: (state === null || state === void 0 ? void 0 : (_state$statusReducer = state.statusReducer) === null || _state$statusReducer === void 0 ? void 0 : (_state$statusReducer$ = _state$statusReducer.searchState) === null || _state$statusReducer$ === void 0 ? void 0 : _state$statusReducer$[ownProps.facet.datafield]) || '',
|
|
19
|
+
sortBy: (state === null || state === void 0 ? void 0 : (_state$statusReducer2 = state.statusReducer) === null || _state$statusReducer2 === void 0 ? void 0 : (_state$statusReducer3 = _state$statusReducer2.sortState) === null || _state$statusReducer3 === void 0 ? void 0 : _state$statusReducer3[ownProps.facet.datafield]) || null
|
|
20
|
+
};
|
|
21
|
+
};
|
|
19
22
|
const mapDispatchToProps = dispatch => ({
|
|
20
23
|
onClearFacetSection: facet => {
|
|
21
24
|
dispatch((0, _Actions.clearFacetSection)(facet));
|
|
@@ -13,10 +13,10 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
13
13
|
|
|
14
14
|
const ReduxSearchFacetView = props => /*#__PURE__*/_react.default.createElement(_SearchFacetView.default, props);
|
|
15
15
|
const mapStateToProps = (state, ownProps) => {
|
|
16
|
-
var _state$statusReducer;
|
|
16
|
+
var _state$statusReducer, _state$statusReducer$, _state$statusReducer2, _state$statusReducer3;
|
|
17
17
|
return {
|
|
18
|
-
searchText: ((_state$statusReducer = state.statusReducer) === null || _state$statusReducer === void 0 ? void 0 : _state$statusReducer.searchState[ownProps.facet.datafield]) || '',
|
|
19
|
-
sortBy: state.statusReducer.sortState[ownProps.facet.datafield] || null
|
|
18
|
+
searchText: (state === null || state === void 0 ? void 0 : (_state$statusReducer = state.statusReducer) === null || _state$statusReducer === void 0 ? void 0 : (_state$statusReducer$ = _state$statusReducer.searchState) === null || _state$statusReducer$ === void 0 ? void 0 : _state$statusReducer$[ownProps.facet.datafield]) || '',
|
|
19
|
+
sortBy: (state === null || state === void 0 ? void 0 : (_state$statusReducer2 = state.statusReducer) === null || _state$statusReducer2 === void 0 ? void 0 : (_state$statusReducer3 = _state$statusReducer2.sortState) === null || _state$statusReducer3 === void 0 ? void 0 : _state$statusReducer3[ownProps.facet.datafield]) || null
|
|
20
20
|
};
|
|
21
21
|
};
|
|
22
22
|
const mapDispatchToProps = dispatch => ({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bento-core/facet-filter",
|
|
3
|
-
"version": "1.0.1-CDS.
|
|
3
|
+
"version": "1.0.1-CDS.8",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -25,5 +25,5 @@
|
|
|
25
25
|
},
|
|
26
26
|
"author": "CTOS Bento Team",
|
|
27
27
|
"license": "ISC",
|
|
28
|
-
"gitHead": "
|
|
28
|
+
"gitHead": "ca5d70a6c4f195a6bf5c7fc15cc5b118eec78173"
|
|
29
29
|
}
|
|
@@ -11,8 +11,8 @@ import FacetModal from './FacetModal';
|
|
|
11
11
|
const ReduxFacetModal = ((props) => <FacetModal {...props} />);
|
|
12
12
|
|
|
13
13
|
const mapStateToProps = (state, ownProps) => ({
|
|
14
|
-
searchText: state
|
|
15
|
-
sortBy: state
|
|
14
|
+
searchText: state?.statusReducer?.searchState?.[ownProps.facet.datafield] || '',
|
|
15
|
+
sortBy: state?.statusReducer?.sortState?.[ownProps.facet.datafield] || null,
|
|
16
16
|
});
|
|
17
17
|
|
|
18
18
|
const mapDispatchToProps = (dispatch) => ({
|
|
@@ -12,8 +12,8 @@ import SearchFacetView from './SearchFacetView';
|
|
|
12
12
|
const ReduxSearchFacetView = ((props) => <SearchFacetView {...props} />);
|
|
13
13
|
|
|
14
14
|
const mapStateToProps = (state, ownProps) => ({
|
|
15
|
-
searchText: state
|
|
16
|
-
sortBy: state
|
|
15
|
+
searchText: state?.statusReducer?.searchState?.[ownProps.facet.datafield] || '',
|
|
16
|
+
sortBy: state?.statusReducer?.sortState?.[ownProps.facet.datafield] || null,
|
|
17
17
|
});
|
|
18
18
|
|
|
19
19
|
const mapDispatchToProps = (dispatch) => ({
|