@steroidsjs/core 3.0.29 → 3.0.30
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/hooks/useList.js +3 -1
- package/package.json +1 -1
- package/reducers/list.js +2 -1
- package/ui/list/Grid/Grid.d.ts +1 -0
package/hooks/useList.js
CHANGED
|
@@ -266,7 +266,9 @@ function useList(config) {
|
|
|
266
266
|
}, [dispatch, config.items, config.listId]);
|
|
267
267
|
// Destroy
|
|
268
268
|
(0, react_use_1.useUnmount)(function () {
|
|
269
|
-
var autoDestroy = typeof config.autoDestroy === 'boolean'
|
|
269
|
+
var autoDestroy = typeof config.autoDestroy === 'boolean'
|
|
270
|
+
? config.autoDestroy
|
|
271
|
+
: exports.defaultConfig.autoDestroy;
|
|
270
272
|
if (autoDestroy) {
|
|
271
273
|
dispatch([
|
|
272
274
|
(0, list_2.listDestroy)(config.listId),
|
package/package.json
CHANGED
package/reducers/list.js
CHANGED
|
@@ -95,7 +95,8 @@ var reducerMap = (_a = {},
|
|
|
95
95
|
},
|
|
96
96
|
_a[list_1.LIST_DESTROY] = function (state, action) {
|
|
97
97
|
delete state.lists[action.listId];
|
|
98
|
-
|
|
98
|
+
delete state.selectedIds[action.listId];
|
|
99
|
+
return __assign(__assign({}, state), { lists: __assign({}, state.lists), selectedIds: __assign({}, state.selectedIds) });
|
|
99
100
|
},
|
|
100
101
|
_a[list_1.LIST_TOGGLE_ITEM] = function (state, action) {
|
|
101
102
|
var _a;
|