@elliemae/ds-shuttle 1.55.0-next.7 → 2.0.0-alpha.10
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/AnimationState.js +25 -42
- package/cjs/DSShuttle.js +89 -189
- package/cjs/SearchState.js +9 -22
- package/cjs/Shuttle.actions.js +57 -75
- package/cjs/ShuttleContainer.js +44 -79
- package/cjs/ShuttleImpl.js +236 -342
- package/cjs/ShuttleRenderer.js +114 -188
- package/cjs/ShuttleState.js +19 -41
- package/cjs/animation/animationConfig.js +58 -65
- package/cjs/classedComponents.js +37 -49
- package/cjs/components/LoadingIndicator.js +11 -12
- package/cjs/components/OverflowList.js +27 -34
- package/cjs/components/ShuttleBreadcrumb.js +23 -35
- package/cjs/components/ShuttleInfiniteScrollIndicator.js +21 -23
- package/cjs/components/ShuttleListItem/ActionButtons.js +34 -34
- package/cjs/components/ShuttleListItem/ShuttleListItem.js +57 -64
- package/cjs/components/ShuttleListItem/ShuttleSourceListItem.js +34 -64
- package/cjs/components/ShuttleListItem/ShuttleTargetListItem.js +30 -53
- package/cjs/components/ShuttleListPanel.js +11 -24
- package/cjs/components/ShuttleSearchBox.js +81 -107
- package/cjs/components/ShuttleSource.js +93 -175
- package/cjs/components/ShuttleTarget.js +55 -85
- package/cjs/components/VirtualizedItem.js +22 -22
- package/cjs/components/VirtualizedList.js +56 -66
- package/cjs/components/VirtualizedSortableList.js +20 -23
- package/cjs/helper.js +37 -89
- package/cjs/index.js +1 -64
- package/cjs/package.json +7 -0
- package/cjs/updateShuttleStateFromProps.js +31 -40
- package/cjs/utils.js +4 -9
- package/cjs/withProviders.js +10 -16
- package/esm/AnimationState.js +24 -40
- package/esm/DSShuttle.js +86 -186
- package/esm/SearchState.js +8 -20
- package/esm/Shuttle.actions.js +56 -73
- package/esm/ShuttleContainer.js +42 -77
- package/esm/ShuttleImpl.js +240 -337
- package/esm/ShuttleRenderer.js +110 -183
- package/esm/ShuttleState.js +14 -34
- package/esm/animation/animationConfig.js +58 -65
- package/esm/classedComponents.js +31 -43
- package/esm/components/LoadingIndicator.js +10 -11
- package/esm/components/OverflowList.js +23 -30
- package/esm/components/ShuttleBreadcrumb.js +21 -33
- package/esm/components/ShuttleInfiniteScrollIndicator.js +20 -22
- package/esm/components/ShuttleListItem/ActionButtons.js +32 -32
- package/esm/components/ShuttleListItem/ShuttleListItem.js +55 -62
- package/esm/components/ShuttleListItem/ShuttleSourceListItem.js +30 -59
- package/esm/components/ShuttleListItem/ShuttleTargetListItem.js +26 -49
- package/esm/components/ShuttleListPanel.js +10 -23
- package/esm/components/ShuttleSearchBox.js +79 -99
- package/esm/components/ShuttleSource.js +82 -162
- package/esm/components/ShuttleTarget.js +49 -79
- package/esm/components/VirtualizedItem.js +20 -20
- package/esm/components/VirtualizedList.js +52 -62
- package/esm/components/VirtualizedSortableList.js +16 -18
- package/esm/helper.js +35 -85
- package/esm/index.js +0 -63
- package/esm/package.json +7 -0
- package/esm/updateShuttleStateFromProps.js +30 -38
- package/esm/utils.js +1 -4
- package/esm/withProviders.js +8 -15
- package/package.json +150 -13
- package/types/AnimationState.d.ts +26 -0
- package/types/DSShuttle.d.ts +119 -0
- package/types/SearchState.d.ts +22 -0
- package/types/Shuttle.actions.d.ts +11 -0
- package/types/ShuttleContainer.d.ts +3 -0
- package/types/ShuttleImpl.d.ts +3 -0
- package/types/ShuttleRenderer.d.ts +37 -0
- package/types/ShuttleState.d.ts +53 -0
- package/types/animation/animationConfig.d.ts +68 -0
- package/types/classedComponents.d.ts +14 -0
- package/types/components/LoadingIndicator.d.ts +3 -0
- package/types/components/OverflowList.d.ts +7 -0
- package/types/components/ShuttleBreadcrumb.d.ts +7 -0
- package/types/components/ShuttleInfiniteScrollIndicator.d.ts +5 -0
- package/types/components/ShuttleListItem/ActionButtons.d.ts +4 -0
- package/types/components/ShuttleListItem/ShuttleListItem.d.ts +14 -0
- package/types/components/ShuttleListItem/ShuttleSourceListItem.d.ts +13 -0
- package/types/components/ShuttleListItem/ShuttleTargetListItem.d.ts +13 -0
- package/types/components/ShuttleListPanel.d.ts +7 -0
- package/types/components/ShuttleSearchBox.d.ts +20 -0
- package/types/components/ShuttleSource.d.ts +54 -0
- package/types/components/ShuttleTarget.d.ts +16 -0
- package/types/components/VirtualizedItem.d.ts +3 -0
- package/types/components/VirtualizedList.d.ts +12 -0
- package/types/components/VirtualizedSortableList.d.ts +6 -0
- package/types/helper.d.ts +16 -0
- package/types/index.d.ts +1 -0
- package/types/tests/DSShuttle.events.test.d.ts +1 -0
- package/types/tests/DSShuttle.test.d.ts +1 -0
- package/types/tests/utils.d.ts +116 -0
- package/types/updateShuttleStateFromProps.d.ts +1 -0
- package/types/utils.d.ts +2 -0
- package/types/withProviders.d.ts +3 -0
- package/AnimationState/package.json +0 -10
- package/DSShuttle/package.json +0 -10
- package/SearchState/package.json +0 -10
- package/Shuttle.actions/package.json +0 -10
- package/ShuttleContainer/package.json +0 -10
- package/ShuttleImpl/package.json +0 -10
- package/ShuttleRenderer/package.json +0 -10
- package/ShuttleState/package.json +0 -10
- package/animation/animationConfig/package.json +0 -10
- package/cjs/AnimationState.js.map +0 -1
- package/cjs/DSShuttle.js.map +0 -1
- package/cjs/SearchState.js.map +0 -1
- package/cjs/Shuttle.actions.js.map +0 -1
- package/cjs/ShuttleContainer.js.map +0 -1
- package/cjs/ShuttleImpl.js.map +0 -1
- package/cjs/ShuttleRenderer.js.map +0 -1
- package/cjs/ShuttleState.js.map +0 -1
- package/cjs/animation/animationConfig.js.map +0 -1
- package/cjs/classedComponents.js.map +0 -1
- package/cjs/components/LoadingIndicator.js.map +0 -1
- package/cjs/components/OverflowList.js.map +0 -1
- package/cjs/components/ShuttleBreadcrumb.js.map +0 -1
- package/cjs/components/ShuttleInfiniteScrollIndicator.js.map +0 -1
- package/cjs/components/ShuttleListItem/ActionButtons.js.map +0 -1
- package/cjs/components/ShuttleListItem/ShuttleListItem.js.map +0 -1
- package/cjs/components/ShuttleListItem/ShuttleSourceListItem.js.map +0 -1
- package/cjs/components/ShuttleListItem/ShuttleTargetListItem.js.map +0 -1
- package/cjs/components/ShuttleListPanel.js.map +0 -1
- package/cjs/components/ShuttleSearchBox.js.map +0 -1
- package/cjs/components/ShuttleSource.js.map +0 -1
- package/cjs/components/ShuttleTarget.js.map +0 -1
- package/cjs/components/VirtualizedItem.js.map +0 -1
- package/cjs/components/VirtualizedList.js.map +0 -1
- package/cjs/components/VirtualizedSortableList.js.map +0 -1
- package/cjs/helper.js.map +0 -1
- package/cjs/index.js.map +0 -1
- package/cjs/tests/utils.js +0 -1112
- package/cjs/tests/utils.js.map +0 -1
- package/cjs/updateShuttleStateFromProps.js.map +0 -1
- package/cjs/utils.js.map +0 -1
- package/cjs/withProviders.js.map +0 -1
- package/classedComponents/package.json +0 -10
- package/components/LoadingIndicator/package.json +0 -10
- package/components/OverflowList/package.json +0 -10
- package/components/ShuttleBreadcrumb/package.json +0 -10
- package/components/ShuttleInfiniteScrollIndicator/package.json +0 -10
- package/components/ShuttleListItem/ActionButtons/package.json +0 -10
- package/components/ShuttleListItem/ShuttleListItem/package.json +0 -10
- package/components/ShuttleListItem/ShuttleSourceListItem/package.json +0 -10
- package/components/ShuttleListItem/ShuttleTargetListItem/package.json +0 -10
- package/components/ShuttleListPanel/package.json +0 -10
- package/components/ShuttleSearchBox/package.json +0 -10
- package/components/ShuttleSource/package.json +0 -10
- package/components/ShuttleTarget/package.json +0 -10
- package/components/VirtualizedItem/package.json +0 -10
- package/components/VirtualizedList/package.json +0 -10
- package/components/VirtualizedSortableList/package.json +0 -10
- package/esm/AnimationState.js.map +0 -1
- package/esm/DSShuttle.js.map +0 -1
- package/esm/SearchState.js.map +0 -1
- package/esm/Shuttle.actions.js.map +0 -1
- package/esm/ShuttleContainer.js.map +0 -1
- package/esm/ShuttleImpl.js.map +0 -1
- package/esm/ShuttleRenderer.js.map +0 -1
- package/esm/ShuttleState.js.map +0 -1
- package/esm/animation/animationConfig.js.map +0 -1
- package/esm/classedComponents.js.map +0 -1
- package/esm/components/LoadingIndicator.js.map +0 -1
- package/esm/components/OverflowList.js.map +0 -1
- package/esm/components/ShuttleBreadcrumb.js.map +0 -1
- package/esm/components/ShuttleInfiniteScrollIndicator.js.map +0 -1
- package/esm/components/ShuttleListItem/ActionButtons.js.map +0 -1
- package/esm/components/ShuttleListItem/ShuttleListItem.js.map +0 -1
- package/esm/components/ShuttleListItem/ShuttleSourceListItem.js.map +0 -1
- package/esm/components/ShuttleListItem/ShuttleTargetListItem.js.map +0 -1
- package/esm/components/ShuttleListPanel.js.map +0 -1
- package/esm/components/ShuttleSearchBox.js.map +0 -1
- package/esm/components/ShuttleSource.js.map +0 -1
- package/esm/components/ShuttleTarget.js.map +0 -1
- package/esm/components/VirtualizedItem.js.map +0 -1
- package/esm/components/VirtualizedList.js.map +0 -1
- package/esm/components/VirtualizedSortableList.js.map +0 -1
- package/esm/helper.js.map +0 -1
- package/esm/index.js.map +0 -1
- package/esm/tests/utils.js +0 -1100
- package/esm/tests/utils.js.map +0 -1
- package/esm/updateShuttleStateFromProps.js.map +0 -1
- package/esm/utils.js.map +0 -1
- package/esm/withProviders.js.map +0 -1
- package/helper/package.json +0 -10
- package/tests/utils/package.json +0 -10
- package/updateShuttleStateFromProps/package.json +0 -10
- package/utils/package.json +0 -10
- package/withProviders/package.json +0 -10
|
@@ -1,86 +1,78 @@
|
|
|
1
|
-
import _toConsumableArray from '@babel/runtime/helpers/esm/toConsumableArray';
|
|
2
1
|
import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
|
|
3
2
|
import { compose, isEqual, hashArray } from '@elliemae/ds-utilities/utils';
|
|
4
3
|
import { getItemsById, pipe, prepareItems } from './helper.js';
|
|
5
4
|
import { addToTarget, resetMovedItems } from './Shuttle.actions.js';
|
|
6
|
-
import 'treetabular';
|
|
7
|
-
import './utils.js';
|
|
8
5
|
|
|
9
6
|
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; }
|
|
10
7
|
|
|
11
8
|
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; }
|
|
12
9
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
});
|
|
17
|
-
};
|
|
10
|
+
const mergeToPrevState = (prevState, nextState) => _objectSpread(_objectSpread(_objectSpread({}, prevState), nextState), {}, {
|
|
11
|
+
prevProps: _objectSpread(_objectSpread({}, prevState.prevProps), nextState.prevProps)
|
|
12
|
+
});
|
|
18
13
|
|
|
19
14
|
function compareSelectedItems(nextProps, prevProps) {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
15
|
+
const {
|
|
16
|
+
selectedItems,
|
|
17
|
+
idField
|
|
18
|
+
} = nextProps;
|
|
19
|
+
return nextState => {
|
|
23
20
|
if (isEqual(selectedItems, prevProps.selectedItems)) return nextState; // if we are using nonSelectedItems skip this legacy logic and paint just what's passed
|
|
24
21
|
// to nonSelectedItems (source) and selectedItems (target)
|
|
25
22
|
// TODO make controlledV2 the default behavior for controlled shuttle
|
|
26
23
|
|
|
27
24
|
if (nextProps.nonSelectedItems) return nextState;
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
return mergeToPrevState(nextState, _objectSpread(_objectSpread({}, pipe([resetMovedItems()]
|
|
25
|
+
const {
|
|
26
|
+
preparedItems
|
|
27
|
+
} = nextState;
|
|
28
|
+
const prevSelectedItemsHash = hashArray(prevProps.selectedItems || []);
|
|
29
|
+
const itemsToMove = getItemsById(selectedItems, preparedItems);
|
|
30
|
+
const actions = itemsToMove.map(item => prevSelectedItemsHash[item[idField]] ? addToTarget(item, nextState.targetItems) : addToTarget(item));
|
|
31
|
+
return mergeToPrevState(nextState, _objectSpread(_objectSpread({}, pipe([resetMovedItems(), ...actions])(nextState, nextProps)), {}, {
|
|
35
32
|
prevProps: _objectSpread(_objectSpread({}, nextState.prevProps), {}, {
|
|
36
|
-
selectedItems
|
|
33
|
+
selectedItems
|
|
37
34
|
})
|
|
38
35
|
}));
|
|
39
36
|
};
|
|
40
37
|
}
|
|
41
38
|
|
|
42
39
|
function compareItems(nextProps, prevProps) {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
40
|
+
const {
|
|
41
|
+
items
|
|
42
|
+
} = nextProps;
|
|
43
|
+
return nextState => {
|
|
44
|
+
const preparedItems = prepareItems(items);
|
|
45
|
+
const isControlledV2 = nextProps.nonSelectedItems; // TODO make controlledV2 the default behavior for controlled shuttle
|
|
47
46
|
|
|
48
47
|
if (isControlledV2) {
|
|
49
|
-
|
|
50
|
-
return preparedItems.find(function (it) {
|
|
51
|
-
return it.id === id;
|
|
52
|
-
});
|
|
53
|
-
});
|
|
48
|
+
const targetItems = nextProps.selectedItems.map(id => preparedItems.find(it => it.id === id));
|
|
54
49
|
return mergeToPrevState(nextState, {
|
|
55
|
-
preparedItems
|
|
50
|
+
preparedItems,
|
|
56
51
|
// PUI-4462 on async load and items change, the shuttle loads
|
|
57
52
|
// all children from currently selected targetItems from items prop
|
|
58
53
|
// (items prop update)
|
|
59
|
-
targetItems
|
|
54
|
+
targetItems,
|
|
60
55
|
movedItems: targetItems,
|
|
61
56
|
prevProps: {
|
|
62
|
-
items
|
|
57
|
+
items
|
|
63
58
|
}
|
|
64
59
|
});
|
|
65
60
|
}
|
|
66
61
|
|
|
67
62
|
if (isEqual(items, prevProps.items)) return nextState;
|
|
68
63
|
return mergeToPrevState(nextState, {
|
|
69
|
-
preparedItems
|
|
64
|
+
preparedItems,
|
|
70
65
|
prevProps: {
|
|
71
|
-
items
|
|
66
|
+
items
|
|
72
67
|
}
|
|
73
68
|
});
|
|
74
69
|
};
|
|
75
70
|
}
|
|
76
71
|
|
|
77
72
|
function updateShuttleStateFromProps (nextProps, prevState) {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
});
|
|
81
|
-
var nextState = compose.apply(void 0, _toConsumableArray(stateReducers))(prevState);
|
|
73
|
+
const stateReducers = [compareSelectedItems, compareItems].map(fn => fn(nextProps, prevState.prevProps));
|
|
74
|
+
const nextState = compose(...stateReducers)(prevState);
|
|
82
75
|
return !isEqual(nextState, prevState) ? nextState : null;
|
|
83
76
|
}
|
|
84
77
|
|
|
85
78
|
export { updateShuttleStateFromProps as default };
|
|
86
|
-
//# sourceMappingURL=updateShuttleStateFromProps.js.map
|
package/esm/utils.js
CHANGED
|
@@ -7,10 +7,7 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
7
7
|
|
|
8
8
|
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; }
|
|
9
9
|
var utils = _objectSpread({
|
|
10
|
-
prepareItems:
|
|
11
|
-
return compose(tree.fixOrder(options), prepareItems)(items);
|
|
12
|
-
}
|
|
10
|
+
prepareItems: (items, options) => compose(tree.fixOrder(options), prepareItems)(items)
|
|
13
11
|
}, tree);
|
|
14
12
|
|
|
15
13
|
export { utils as default };
|
|
16
|
-
//# sourceMappingURL=utils.js.map
|
package/esm/withProviders.js
CHANGED
|
@@ -1,24 +1,17 @@
|
|
|
1
|
-
import
|
|
1
|
+
import _jsx from '@babel/runtime/helpers/esm/jsx';
|
|
2
|
+
import _defineProperty from '@babel/runtime/helpers/esm/defineProperty';
|
|
3
|
+
import 'react';
|
|
2
4
|
import AnimationContext from './AnimationState.js';
|
|
3
5
|
import SearchState from './SearchState.js';
|
|
4
6
|
import useShuttleState from './ShuttleState.js';
|
|
5
|
-
import '
|
|
6
|
-
import 'constate';
|
|
7
|
-
import '@babel/runtime/helpers/esm/toConsumableArray';
|
|
8
|
-
import './helper.js';
|
|
9
|
-
import '@babel/runtime/helpers/esm/defineProperty';
|
|
10
|
-
import '@elliemae/ds-utilities/utils';
|
|
11
|
-
import 'treetabular';
|
|
12
|
-
import './Shuttle.actions.js';
|
|
13
|
-
import './utils.js';
|
|
7
|
+
import { jsx } from 'react/jsx-runtime';
|
|
14
8
|
|
|
15
|
-
|
|
9
|
+
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; }
|
|
10
|
+
|
|
11
|
+
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
12
|
|
|
17
13
|
function withProviders(Component) {
|
|
18
|
-
return
|
|
19
|
-
return /*#__PURE__*/React.createElement(useShuttleState.Provider, null, /*#__PURE__*/React.createElement(AnimationContext.Provider, null, /*#__PURE__*/React.createElement(SearchState.Provider, null, /*#__PURE__*/React.createElement(Component, props))));
|
|
20
|
-
};
|
|
14
|
+
return props => /*#__PURE__*/_jsx(useShuttleState.Provider, {}, void 0, /*#__PURE__*/_jsx(AnimationContext.Provider, {}, void 0, /*#__PURE__*/_jsx(SearchState.Provider, {}, void 0, /*#__PURE__*/jsx(Component, _objectSpread({}, props)))));
|
|
21
15
|
}
|
|
22
16
|
|
|
23
17
|
export { withProviders as default };
|
|
24
|
-
//# sourceMappingURL=withProviders.js.map
|
package/package.json
CHANGED
|
@@ -1,14 +1,150 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-shuttle",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0-alpha.10",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"description": "
|
|
6
|
-
"
|
|
7
|
-
"
|
|
5
|
+
"description": "ICE MT - Dimsum - Shuttle",
|
|
6
|
+
"module": "./esm/index.js",
|
|
7
|
+
"main": "./cjs/index.js",
|
|
8
|
+
"types": "./types/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"import": "./esm/index.js",
|
|
12
|
+
"require": "./cjs/index.js"
|
|
13
|
+
},
|
|
14
|
+
"./withProviders": {
|
|
15
|
+
"import": "./esm/withProviders.js",
|
|
16
|
+
"require": "./cjs/withProviders.js"
|
|
17
|
+
},
|
|
18
|
+
"./utils": {
|
|
19
|
+
"import": "./esm/utils.js",
|
|
20
|
+
"require": "./cjs/utils.js"
|
|
21
|
+
},
|
|
22
|
+
"./updateShuttleStateFromProps": {
|
|
23
|
+
"import": "./esm/updateShuttleStateFromProps.js",
|
|
24
|
+
"require": "./cjs/updateShuttleStateFromProps.js"
|
|
25
|
+
},
|
|
26
|
+
"./tests/utils": {
|
|
27
|
+
"import": "./esm/tests/utils.js",
|
|
28
|
+
"require": "./cjs/tests/utils.js"
|
|
29
|
+
},
|
|
30
|
+
"./ShuttleState": {
|
|
31
|
+
"import": "./esm/ShuttleState.js",
|
|
32
|
+
"require": "./cjs/ShuttleState.js"
|
|
33
|
+
},
|
|
34
|
+
"./ShuttleRenderer": {
|
|
35
|
+
"import": "./esm/ShuttleRenderer.js",
|
|
36
|
+
"require": "./cjs/ShuttleRenderer.js"
|
|
37
|
+
},
|
|
38
|
+
"./ShuttleImpl": {
|
|
39
|
+
"import": "./esm/ShuttleImpl.js",
|
|
40
|
+
"require": "./cjs/ShuttleImpl.js"
|
|
41
|
+
},
|
|
42
|
+
"./ShuttleContainer": {
|
|
43
|
+
"import": "./esm/ShuttleContainer.js",
|
|
44
|
+
"require": "./cjs/ShuttleContainer.js"
|
|
45
|
+
},
|
|
46
|
+
"./Shuttle.actions": {
|
|
47
|
+
"import": "./esm/Shuttle.actions.js",
|
|
48
|
+
"require": "./cjs/Shuttle.actions.js"
|
|
49
|
+
},
|
|
50
|
+
"./SearchState": {
|
|
51
|
+
"import": "./esm/SearchState.js",
|
|
52
|
+
"require": "./cjs/SearchState.js"
|
|
53
|
+
},
|
|
54
|
+
"./helper": {
|
|
55
|
+
"import": "./esm/helper.js",
|
|
56
|
+
"require": "./cjs/helper.js"
|
|
57
|
+
},
|
|
58
|
+
"./DSShuttle": {
|
|
59
|
+
"import": "./esm/DSShuttle.js",
|
|
60
|
+
"require": "./cjs/DSShuttle.js"
|
|
61
|
+
},
|
|
62
|
+
"./components/VirtualizedSortableList": {
|
|
63
|
+
"import": "./esm/components/VirtualizedSortableList.js",
|
|
64
|
+
"require": "./cjs/components/VirtualizedSortableList.js"
|
|
65
|
+
},
|
|
66
|
+
"./components/VirtualizedList": {
|
|
67
|
+
"import": "./esm/components/VirtualizedList.js",
|
|
68
|
+
"require": "./cjs/components/VirtualizedList.js"
|
|
69
|
+
},
|
|
70
|
+
"./components/VirtualizedItem": {
|
|
71
|
+
"import": "./esm/components/VirtualizedItem.js",
|
|
72
|
+
"require": "./cjs/components/VirtualizedItem.js"
|
|
73
|
+
},
|
|
74
|
+
"./components/ShuttleTarget": {
|
|
75
|
+
"import": "./esm/components/ShuttleTarget.js",
|
|
76
|
+
"require": "./cjs/components/ShuttleTarget.js"
|
|
77
|
+
},
|
|
78
|
+
"./components/ShuttleSource": {
|
|
79
|
+
"import": "./esm/components/ShuttleSource.js",
|
|
80
|
+
"require": "./cjs/components/ShuttleSource.js"
|
|
81
|
+
},
|
|
82
|
+
"./components/ShuttleSearchBox": {
|
|
83
|
+
"import": "./esm/components/ShuttleSearchBox.js",
|
|
84
|
+
"require": "./cjs/components/ShuttleSearchBox.js"
|
|
85
|
+
},
|
|
86
|
+
"./components/ShuttleListPanel": {
|
|
87
|
+
"import": "./esm/components/ShuttleListPanel.js",
|
|
88
|
+
"require": "./cjs/components/ShuttleListPanel.js"
|
|
89
|
+
},
|
|
90
|
+
"./components/ShuttleListItem/ShuttleTargetListItem": {
|
|
91
|
+
"import": "./esm/components/ShuttleListItem/ShuttleTargetListItem.js",
|
|
92
|
+
"require": "./cjs/components/ShuttleListItem/ShuttleTargetListItem.js"
|
|
93
|
+
},
|
|
94
|
+
"./components/ShuttleListItem/ShuttleSourceListItem": {
|
|
95
|
+
"import": "./esm/components/ShuttleListItem/ShuttleSourceListItem.js",
|
|
96
|
+
"require": "./cjs/components/ShuttleListItem/ShuttleSourceListItem.js"
|
|
97
|
+
},
|
|
98
|
+
"./components/ShuttleListItem/ShuttleListItem": {
|
|
99
|
+
"import": "./esm/components/ShuttleListItem/ShuttleListItem.js",
|
|
100
|
+
"require": "./cjs/components/ShuttleListItem/ShuttleListItem.js"
|
|
101
|
+
},
|
|
102
|
+
"./components/ShuttleListItem/ActionButtons": {
|
|
103
|
+
"import": "./esm/components/ShuttleListItem/ActionButtons.js",
|
|
104
|
+
"require": "./cjs/components/ShuttleListItem/ActionButtons.js"
|
|
105
|
+
},
|
|
106
|
+
"./components/ShuttleInfiniteScrollIndicator": {
|
|
107
|
+
"import": "./esm/components/ShuttleInfiniteScrollIndicator.js",
|
|
108
|
+
"require": "./cjs/components/ShuttleInfiniteScrollIndicator.js"
|
|
109
|
+
},
|
|
110
|
+
"./components/ShuttleBreadcrumb": {
|
|
111
|
+
"import": "./esm/components/ShuttleBreadcrumb.js",
|
|
112
|
+
"require": "./cjs/components/ShuttleBreadcrumb.js"
|
|
113
|
+
},
|
|
114
|
+
"./components/OverflowList": {
|
|
115
|
+
"import": "./esm/components/OverflowList.js",
|
|
116
|
+
"require": "./cjs/components/OverflowList.js"
|
|
117
|
+
},
|
|
118
|
+
"./components/LoadingIndicator": {
|
|
119
|
+
"import": "./esm/components/LoadingIndicator.js",
|
|
120
|
+
"require": "./cjs/components/LoadingIndicator.js"
|
|
121
|
+
},
|
|
122
|
+
"./classedComponents": {
|
|
123
|
+
"import": "./esm/classedComponents.js",
|
|
124
|
+
"require": "./cjs/classedComponents.js"
|
|
125
|
+
},
|
|
126
|
+
"./AnimationState": {
|
|
127
|
+
"import": "./esm/AnimationState.js",
|
|
128
|
+
"require": "./cjs/AnimationState.js"
|
|
129
|
+
},
|
|
130
|
+
"./animation/animationConfig": {
|
|
131
|
+
"import": "./esm/animation/animationConfig.js",
|
|
132
|
+
"require": "./cjs/animation/animationConfig.js"
|
|
133
|
+
}
|
|
134
|
+
},
|
|
8
135
|
"sideEffects": [
|
|
9
136
|
"*.css",
|
|
10
137
|
"*.scss"
|
|
11
138
|
],
|
|
139
|
+
"repository": {
|
|
140
|
+
"type": "git",
|
|
141
|
+
"url": "https://git.elliemae.io/platform-ui/dimsum.git"
|
|
142
|
+
},
|
|
143
|
+
"engines": {
|
|
144
|
+
"npm": ">=7",
|
|
145
|
+
"node": ">=14"
|
|
146
|
+
},
|
|
147
|
+
"author": "ICE MT",
|
|
12
148
|
"scripts": {
|
|
13
149
|
"dev": "cross-env NODE_ENV=development && node ../../scripts/build/build.js -w",
|
|
14
150
|
"prebuild": "exit 0",
|
|
@@ -16,25 +152,26 @@
|
|
|
16
152
|
"build": "node ../../scripts/build/build.js"
|
|
17
153
|
},
|
|
18
154
|
"dependencies": {
|
|
19
|
-
"@elliemae/ds-basic": "
|
|
20
|
-
"@elliemae/ds-classnames": "
|
|
21
|
-
"@elliemae/ds-utilities": "
|
|
155
|
+
"@elliemae/ds-basic": "2.0.0-alpha.10",
|
|
156
|
+
"@elliemae/ds-classnames": "2.0.0-alpha.10",
|
|
157
|
+
"@elliemae/ds-utilities": "2.0.0-alpha.10",
|
|
22
158
|
"constate": "~1.3.2",
|
|
23
159
|
"memoize-one": "~4.0.3",
|
|
24
160
|
"prop-types": "~15.7.2",
|
|
25
161
|
"react-sortable-hoc": "~1.9.1",
|
|
26
162
|
"react-spring": "~8.0.27",
|
|
27
|
-
"react-window": "~1.8.
|
|
28
|
-
"react-window-infinite-loader": "~1.0.
|
|
163
|
+
"react-window": "~1.8.6",
|
|
164
|
+
"react-window-infinite-loader": "~1.0.7",
|
|
29
165
|
"treetabular": "~3.6.0"
|
|
30
166
|
},
|
|
31
167
|
"publishConfig": {
|
|
32
168
|
"access": "public",
|
|
33
|
-
"directory": "dist"
|
|
169
|
+
"directory": "dist",
|
|
170
|
+
"generateSubmodules": true
|
|
34
171
|
},
|
|
35
172
|
"peerDependencies": {
|
|
36
|
-
"lodash": "^4.17.
|
|
37
|
-
"react": "~17.0.
|
|
38
|
-
"react-dom": "^17.0.
|
|
173
|
+
"lodash": "^4.17.21",
|
|
174
|
+
"react": "~17.0.2",
|
|
175
|
+
"react-dom": "^17.0.2"
|
|
39
176
|
}
|
|
40
177
|
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
declare const _default: import("constate/dist/ts/src/types").ContextHookReturn<unknown, {
|
|
2
|
+
state: {
|
|
3
|
+
isMoving: boolean;
|
|
4
|
+
isMovingBack: boolean;
|
|
5
|
+
isDrillingDown: boolean;
|
|
6
|
+
};
|
|
7
|
+
setIsMoving: () => void;
|
|
8
|
+
setIsMovingBack: () => void;
|
|
9
|
+
setIsDrillingDown: () => void;
|
|
10
|
+
reset: () => void;
|
|
11
|
+
}, [(value: {
|
|
12
|
+
state: {
|
|
13
|
+
isMoving: boolean;
|
|
14
|
+
isMovingBack: boolean;
|
|
15
|
+
isDrillingDown: boolean;
|
|
16
|
+
};
|
|
17
|
+
setIsMoving: () => void;
|
|
18
|
+
setIsMovingBack: () => void;
|
|
19
|
+
setIsDrillingDown: () => void;
|
|
20
|
+
reset: () => void;
|
|
21
|
+
}) => {
|
|
22
|
+
isMoving: boolean;
|
|
23
|
+
isMovingBack: boolean;
|
|
24
|
+
isDrillingDown: boolean;
|
|
25
|
+
}[]]>;
|
|
26
|
+
export default _default;
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import utils from './utils';
|
|
3
|
+
declare const DSShuttle: {
|
|
4
|
+
({ containerProps, idField, parentIdField, showIcons, items, selectedItems, nonSelectedItems, onSearch, onSearchOpen, onSearchClose, onDrillDown, onDrillDownTarget, onTargetSortEnd, setGetStatus, targetSortable, sourceEmptyMessage, sourceRootTitle, targetEmptyMessage, targetRootTitle, composeSourceItemProps, composeTargetItemProps, onAddToTarget, onAddCheckedItems, onRemoveFromTarget, onRemoveAllFromTarget, onChange, renderSourceCounter, renderTargetCounter, sourceClearItemsText, targetClearItemsText, searchPlaceholder, loadingSource, loadingTarget, onGetMoreItems, hasNextPage, moreItemsLoading, }: {
|
|
5
|
+
containerProps?: {} | undefined;
|
|
6
|
+
idField?: string | undefined;
|
|
7
|
+
parentIdField?: string | undefined;
|
|
8
|
+
showIcons?: boolean | undefined;
|
|
9
|
+
items?: never[] | undefined;
|
|
10
|
+
selectedItems?: undefined;
|
|
11
|
+
nonSelectedItems?: undefined;
|
|
12
|
+
onSearch?: (() => void) | undefined;
|
|
13
|
+
onSearchOpen?: (() => void) | undefined;
|
|
14
|
+
onSearchClose?: (() => void) | undefined;
|
|
15
|
+
onDrillDown?: (() => void) | undefined;
|
|
16
|
+
onDrillDownTarget?: (() => void) | undefined;
|
|
17
|
+
onTargetSortEnd?: (() => void) | undefined;
|
|
18
|
+
setGetStatus?: (() => void) | undefined;
|
|
19
|
+
targetSortable?: boolean | undefined;
|
|
20
|
+
sourceEmptyMessage?: string | undefined;
|
|
21
|
+
sourceRootTitle?: string | undefined;
|
|
22
|
+
targetEmptyMessage?: string | undefined;
|
|
23
|
+
targetRootTitle?: string | undefined;
|
|
24
|
+
composeSourceItemProps?: (() => {}) | undefined;
|
|
25
|
+
composeTargetItemProps?: (() => {}) | undefined;
|
|
26
|
+
onAddToTarget?: (() => void) | undefined;
|
|
27
|
+
onAddCheckedItems?: (() => void) | undefined;
|
|
28
|
+
onRemoveFromTarget?: (() => void) | undefined;
|
|
29
|
+
onRemoveAllFromTarget?: (() => void) | undefined;
|
|
30
|
+
onChange?: (() => void) | undefined;
|
|
31
|
+
renderSourceCounter?: (() => void) | undefined;
|
|
32
|
+
renderTargetCounter?: (() => void) | undefined;
|
|
33
|
+
sourceClearItemsText?: string | undefined;
|
|
34
|
+
targetClearItemsText?: string | undefined;
|
|
35
|
+
searchPlaceholder?: string | undefined;
|
|
36
|
+
loadingSource?: boolean | undefined;
|
|
37
|
+
loadingTarget?: boolean | undefined;
|
|
38
|
+
onGetMoreItems?: (() => null) | undefined;
|
|
39
|
+
hasNextPage?: boolean | undefined;
|
|
40
|
+
moreItemsLoading: any;
|
|
41
|
+
}): JSX.Element;
|
|
42
|
+
propTypes: {
|
|
43
|
+
/** inject props to shuttle wrapper */
|
|
44
|
+
containerProps: any;
|
|
45
|
+
/** The identifier field for the item object */
|
|
46
|
+
idField: any;
|
|
47
|
+
/** The parent identifier field for the item object */
|
|
48
|
+
parentIdField: any;
|
|
49
|
+
/** Whether to show the icons or not */
|
|
50
|
+
showIcons: any;
|
|
51
|
+
/** List of items */
|
|
52
|
+
items: any;
|
|
53
|
+
/** Array of item ids that are selected. If passed the component behaves as controlled */
|
|
54
|
+
selectedItems: any;
|
|
55
|
+
/** Array of item ids that aren't selected. Should include ALL non selected items, even those not rendered */
|
|
56
|
+
nonSelectedItems: any;
|
|
57
|
+
/** Handler on search */
|
|
58
|
+
onSearch: any;
|
|
59
|
+
/** Handler when the searchbox is visible */
|
|
60
|
+
onSearchOpen: any;
|
|
61
|
+
/** Handler when the searchbox is not visible */
|
|
62
|
+
onSearchClose: any;
|
|
63
|
+
/** Source handler when a user navigates to a level down on the nested structure. First param: item drilled. Second param: direction ("up" | "down") */
|
|
64
|
+
onDrillDown: any;
|
|
65
|
+
/** Target handler when a user navigates to a level down on the nested structure. First param: item drilled. Second param: direction ("up" | "down") */
|
|
66
|
+
onDrillDownTarget: any;
|
|
67
|
+
/** Target handler when user stops dragging an item */
|
|
68
|
+
onTargetSortEnd: any;
|
|
69
|
+
/** Callback function that gets more items for Infinite Scroll */
|
|
70
|
+
onGetMoreItems: any;
|
|
71
|
+
/** Wheter there are mor items loading for Infinite Scroll */
|
|
72
|
+
moreItemsLoading: any;
|
|
73
|
+
/** Wheter there is a next page for Infinite Scroll, controls when to trigger onGetMoreItems */
|
|
74
|
+
hasNextPage: any;
|
|
75
|
+
/** Function that takes as a parameter an internal getter for the state */
|
|
76
|
+
setGetStatus: any;
|
|
77
|
+
/** Whether the target can be sortable with DnD */
|
|
78
|
+
targetSortable: any;
|
|
79
|
+
/** Handler when the searchbox is visible */
|
|
80
|
+
sourceRootTitle: any;
|
|
81
|
+
/** Source text when there is no items */
|
|
82
|
+
sourceEmptyMessage: any;
|
|
83
|
+
/** Target text when there is no items */
|
|
84
|
+
targetEmptyMessage: any;
|
|
85
|
+
/** Target text for the first hierarchy item */
|
|
86
|
+
targetRootTitle: any;
|
|
87
|
+
/** Function that allow to compose the item props in the source */
|
|
88
|
+
composeSourceItemProps: any;
|
|
89
|
+
/** Function that allow to compose the item props in the target */
|
|
90
|
+
composeTargetItemProps: any;
|
|
91
|
+
/** Handler when a users moves an item to the target */
|
|
92
|
+
onAddToTarget: any;
|
|
93
|
+
/** Handler when a users moves all the 'checked' items to the target */
|
|
94
|
+
onAddCheckedItems: any;
|
|
95
|
+
/** Handler when a user removes an item from the target */
|
|
96
|
+
onRemoveFromTarget: any;
|
|
97
|
+
/** Handler when a user removes all the items from the target */
|
|
98
|
+
onRemoveAllFromTarget: any;
|
|
99
|
+
/** Handler for every change on the state */
|
|
100
|
+
onChange: any;
|
|
101
|
+
/** Function that returns an element for the source counter */
|
|
102
|
+
renderSourceCounter: any;
|
|
103
|
+
/** Function that returns an element for the target counter */
|
|
104
|
+
renderTargetCounter: any;
|
|
105
|
+
/** Source text for the clear items button */
|
|
106
|
+
sourceClearItemsText: any;
|
|
107
|
+
/** Target text for the clear items button */
|
|
108
|
+
targetClearItemsText: any;
|
|
109
|
+
/** Searchbox placeholder */
|
|
110
|
+
searchPlaceholder: any;
|
|
111
|
+
/** Displays loading indicator on source section */
|
|
112
|
+
loadingSource: any;
|
|
113
|
+
/** Displays loading indicator on target section */
|
|
114
|
+
loadingTarget: any;
|
|
115
|
+
};
|
|
116
|
+
};
|
|
117
|
+
declare const DSShuttleWithSchema: any;
|
|
118
|
+
export { utils, DSShuttleWithSchema };
|
|
119
|
+
export default DSShuttle;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare const _default: import("constate/dist/ts/src/types").ContextHookReturn<unknown, {
|
|
3
|
+
state: {
|
|
4
|
+
searchTerm: string;
|
|
5
|
+
searching: boolean;
|
|
6
|
+
};
|
|
7
|
+
setSearchTerm: import("react").Dispatch<import("react").SetStateAction<string>>;
|
|
8
|
+
toggleSearchBox: (userVisible: any) => void;
|
|
9
|
+
reset: () => void;
|
|
10
|
+
}, [(value: {
|
|
11
|
+
state: {
|
|
12
|
+
searchTerm: string;
|
|
13
|
+
searching: boolean;
|
|
14
|
+
};
|
|
15
|
+
setSearchTerm: import("react").Dispatch<import("react").SetStateAction<string>>;
|
|
16
|
+
toggleSearchBox: (userVisible: any) => void;
|
|
17
|
+
reset: () => void;
|
|
18
|
+
}) => {
|
|
19
|
+
searchTerm: string;
|
|
20
|
+
searching: boolean;
|
|
21
|
+
}[]]>;
|
|
22
|
+
export default _default;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export function toggleItemSelection(itemId: any): (state: any) => any;
|
|
2
|
+
export function navigateTo(item: any, dest: any): (state: any) => any;
|
|
3
|
+
export function moveItem(item: any): (state: any) => any;
|
|
4
|
+
export function addToTarget(itemToAdd: any, collection: any): (state: any, { idField }: {
|
|
5
|
+
idField: any;
|
|
6
|
+
}) => any;
|
|
7
|
+
export function removeFromTarget(itemToRemove: any): (state: any, { idField }: {
|
|
8
|
+
idField: any;
|
|
9
|
+
}) => any;
|
|
10
|
+
export function resetCheckedItems(): (state: any) => any;
|
|
11
|
+
export function resetMovedItems(): (state: any) => any;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare function ShuttleRenderer({ containerProps, onNavigateOnTargetTo, onNavigateOnSourceTo, onMoveItemToSource, onMoveItemToTarget, onClearMovedItems, onMoveCheckedItems, onClearCheckedItems, onToggleSearch, onSearch, onSearchClose, onSearchOpen, searching, onCheckItem, hierarchy, hierarchyDest, checkedItems, sourceItems, targetItems, sourceEmptyMessage, targetEmptyMessage, composeTargetItemProps, composeSourceItemProps, targetSortable, sourceSortable, onSourceSortEnd, onTargetSortEnd, loadingSource, loadingTarget, onGetMoreItems, moreItemsLoading, hasNextPage, ...otherProps }: {
|
|
3
|
+
[x: string]: any;
|
|
4
|
+
containerProps: any;
|
|
5
|
+
onNavigateOnTargetTo?: (() => void) | undefined;
|
|
6
|
+
onNavigateOnSourceTo?: (() => void) | undefined;
|
|
7
|
+
onMoveItemToSource?: (() => void) | undefined;
|
|
8
|
+
onMoveItemToTarget?: (() => void) | undefined;
|
|
9
|
+
onClearMovedItems?: (() => void) | undefined;
|
|
10
|
+
onMoveCheckedItems?: (() => void) | undefined;
|
|
11
|
+
onClearCheckedItems?: (() => void) | undefined;
|
|
12
|
+
onToggleSearch?: (() => void) | undefined;
|
|
13
|
+
onSearch?: (() => void) | undefined;
|
|
14
|
+
onSearchClose?: (() => void) | undefined;
|
|
15
|
+
onSearchOpen?: (() => void) | undefined;
|
|
16
|
+
searching?: boolean | undefined;
|
|
17
|
+
onCheckItem?: (() => void) | undefined;
|
|
18
|
+
hierarchy?: never[] | undefined;
|
|
19
|
+
hierarchyDest?: never[] | undefined;
|
|
20
|
+
checkedItems?: never[] | undefined;
|
|
21
|
+
sourceItems?: never[] | undefined;
|
|
22
|
+
targetItems?: never[] | undefined;
|
|
23
|
+
sourceEmptyMessage: any;
|
|
24
|
+
targetEmptyMessage: any;
|
|
25
|
+
composeTargetItemProps: any;
|
|
26
|
+
composeSourceItemProps: any;
|
|
27
|
+
targetSortable: any;
|
|
28
|
+
sourceSortable: any;
|
|
29
|
+
onSourceSortEnd: any;
|
|
30
|
+
onTargetSortEnd: any;
|
|
31
|
+
loadingSource?: boolean | undefined;
|
|
32
|
+
loadingTarget?: boolean | undefined;
|
|
33
|
+
onGetMoreItems?: (() => void) | undefined;
|
|
34
|
+
moreItemsLoading?: boolean | undefined;
|
|
35
|
+
hasNextPage?: boolean | undefined;
|
|
36
|
+
}): JSX.Element;
|
|
37
|
+
export default ShuttleRenderer;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
declare const _default: import("constate/dist/ts/src/types").ContextHookReturn<unknown, {
|
|
2
|
+
state: {
|
|
3
|
+
checkedItems: never[];
|
|
4
|
+
movedItems: {};
|
|
5
|
+
hierarchy: {
|
|
6
|
+
name: string;
|
|
7
|
+
id: null;
|
|
8
|
+
}[];
|
|
9
|
+
hierarchyDest: {
|
|
10
|
+
name: string;
|
|
11
|
+
id: null;
|
|
12
|
+
}[];
|
|
13
|
+
};
|
|
14
|
+
toggleItemSelection: (item: any) => void;
|
|
15
|
+
moveCheckedItems: (items: any, dest?: boolean) => void;
|
|
16
|
+
moveItem: (item: any, dest: any) => void;
|
|
17
|
+
resetMovedItems: () => void;
|
|
18
|
+
resetCheckedItems: () => void;
|
|
19
|
+
navigate: (item: any, dest: any) => void;
|
|
20
|
+
setMovedItems: (itemsIds?: never[], items?: never[]) => void;
|
|
21
|
+
}, [(value: {
|
|
22
|
+
state: {
|
|
23
|
+
checkedItems: never[];
|
|
24
|
+
movedItems: {};
|
|
25
|
+
hierarchy: {
|
|
26
|
+
name: string;
|
|
27
|
+
id: null;
|
|
28
|
+
}[];
|
|
29
|
+
hierarchyDest: {
|
|
30
|
+
name: string;
|
|
31
|
+
id: null;
|
|
32
|
+
}[];
|
|
33
|
+
};
|
|
34
|
+
toggleItemSelection: (item: any) => void;
|
|
35
|
+
moveCheckedItems: (items: any, dest?: boolean) => void;
|
|
36
|
+
moveItem: (item: any, dest: any) => void;
|
|
37
|
+
resetMovedItems: () => void;
|
|
38
|
+
resetCheckedItems: () => void;
|
|
39
|
+
navigate: (item: any, dest: any) => void;
|
|
40
|
+
setMovedItems: (itemsIds?: never[], items?: never[]) => void;
|
|
41
|
+
}) => {
|
|
42
|
+
checkedItems: never[];
|
|
43
|
+
movedItems: {};
|
|
44
|
+
hierarchy: {
|
|
45
|
+
name: string;
|
|
46
|
+
id: null;
|
|
47
|
+
}[];
|
|
48
|
+
hierarchyDest: {
|
|
49
|
+
name: string;
|
|
50
|
+
id: null;
|
|
51
|
+
}[];
|
|
52
|
+
}[]]>;
|
|
53
|
+
export default _default;
|