@carbon/ibm-products 2.42.1-canary.21 → 2.42.1-canary.23
Sign up to get free protection for your applications and to get access to all the features.
- package/es/components/Datagrid/useFiltering.d.ts +8 -1
- package/es/components/Datagrid/useFiltering.js +8 -7
- package/es/components/Datagrid/useSelectRows.d.ts +8 -1
- package/es/components/Datagrid/useSelectRows.js +3 -2
- package/lib/components/Datagrid/useFiltering.d.ts +8 -1
- package/lib/components/Datagrid/useFiltering.js +8 -7
- package/lib/components/Datagrid/useSelectRows.d.ts +8 -1
- package/lib/components/Datagrid/useSelectRows.js +3 -2
- package/package.json +2 -2
@@ -1,2 +1,9 @@
|
|
1
|
+
/**
|
2
|
+
* Copyright IBM Corp. 2022, 2024
|
3
|
+
*
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
6
|
+
*/
|
7
|
+
import { Hooks } from 'react-table';
|
8
|
+
declare const useFiltering: (hooks: Hooks) => void;
|
1
9
|
export default useFiltering;
|
2
|
-
declare function useFiltering(hooks: any): void;
|
@@ -63,12 +63,13 @@ var useFiltering = function useFiltering(hooks) {
|
|
63
63
|
});
|
64
64
|
}, []);
|
65
65
|
hooks.useInstance.push(function (instance) {
|
66
|
-
var
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
66
|
+
var _ref4 = instance,
|
67
|
+
filterProps = _ref4.filterProps,
|
68
|
+
setAllFilters = _ref4.setAllFilters,
|
69
|
+
setFilter = _ref4.setFilter,
|
70
|
+
headers = _ref4.headers,
|
71
|
+
data = _ref4.data,
|
72
|
+
state = _ref4.state;
|
72
73
|
var defaultProps = {
|
73
74
|
variation: 'flyout',
|
74
75
|
updateMethod: BATCH,
|
@@ -84,7 +85,7 @@ var useFiltering = function useFiltering(hooks) {
|
|
84
85
|
});
|
85
86
|
};
|
86
87
|
Object.assign(instance, {
|
87
|
-
filterProps: _objectSpread2(_objectSpread2({}, defaultProps), instance.filterProps),
|
88
|
+
filterProps: _objectSpread2(_objectSpread2({}, defaultProps), instance === null || instance === void 0 ? void 0 : instance.filterProps),
|
88
89
|
filterTypes: filterTypes,
|
89
90
|
getFilterFlyoutProps: getFilterFlyoutProps,
|
90
91
|
FilterFlyout: FilterFlyout
|
@@ -1,2 +1,9 @@
|
|
1
|
+
/**
|
2
|
+
* Copyright IBM Corp. 2020, 2023
|
3
|
+
*
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
6
|
+
*/
|
7
|
+
import { Hooks } from 'react-table';
|
8
|
+
declare const useSelectRows: (hooks: Hooks) => void;
|
1
9
|
export default useSelectRows;
|
2
|
-
declare function useSelectRows(hooks: any): void;
|
@@ -108,7 +108,8 @@ var SelectRow = function SelectRow(datagridState) {
|
|
108
108
|
dispatch: dispatch,
|
109
109
|
rowData: row,
|
110
110
|
isChecked: event.target.checked,
|
111
|
-
getRowId: getRowId
|
111
|
+
getRowId: getRowId,
|
112
|
+
selectAll: null
|
112
113
|
});
|
113
114
|
};
|
114
115
|
var selectDisabled = isFetching || row.getRowProps().disabled;
|
@@ -128,7 +129,7 @@ var SelectRow = function SelectRow(datagridState) {
|
|
128
129
|
onSelect: onSelectHandler,
|
129
130
|
id: rowId,
|
130
131
|
name: "".concat(rowId, "-name"),
|
131
|
-
className: cx([checkboxClass, cellProps.className, _defineProperty({}, "".concat(checkboxClass, "-sticky-left"), isFirstColumnStickyLeft && windowSize > 671)]),
|
132
|
+
className: cx([checkboxClass, cellProps.className, _defineProperty({}, "".concat(checkboxClass, "-sticky-left"), isFirstColumnStickyLeft && Number(windowSize) > 671)]),
|
132
133
|
ariaLabel: title,
|
133
134
|
disabled: selectDisabled
|
134
135
|
}));
|
@@ -1,2 +1,9 @@
|
|
1
|
+
/**
|
2
|
+
* Copyright IBM Corp. 2022, 2024
|
3
|
+
*
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
6
|
+
*/
|
7
|
+
import { Hooks } from 'react-table';
|
8
|
+
declare const useFiltering: (hooks: Hooks) => void;
|
1
9
|
export default useFiltering;
|
2
|
-
declare function useFiltering(hooks: any): void;
|
@@ -67,12 +67,13 @@ var useFiltering = function useFiltering(hooks) {
|
|
67
67
|
});
|
68
68
|
}, []);
|
69
69
|
hooks.useInstance.push(function (instance) {
|
70
|
-
var
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
70
|
+
var _ref4 = instance,
|
71
|
+
filterProps = _ref4.filterProps,
|
72
|
+
setAllFilters = _ref4.setAllFilters,
|
73
|
+
setFilter = _ref4.setFilter,
|
74
|
+
headers = _ref4.headers,
|
75
|
+
data = _ref4.data,
|
76
|
+
state = _ref4.state;
|
76
77
|
var defaultProps = {
|
77
78
|
variation: 'flyout',
|
78
79
|
updateMethod: constants.BATCH,
|
@@ -88,7 +89,7 @@ var useFiltering = function useFiltering(hooks) {
|
|
88
89
|
});
|
89
90
|
};
|
90
91
|
Object.assign(instance, {
|
91
|
-
filterProps: _rollupPluginBabelHelpers.objectSpread2(_rollupPluginBabelHelpers.objectSpread2({}, defaultProps), instance.filterProps),
|
92
|
+
filterProps: _rollupPluginBabelHelpers.objectSpread2(_rollupPluginBabelHelpers.objectSpread2({}, defaultProps), instance === null || instance === void 0 ? void 0 : instance.filterProps),
|
92
93
|
filterTypes: filterTypes,
|
93
94
|
getFilterFlyoutProps: getFilterFlyoutProps,
|
94
95
|
FilterFlyout: FilterFlyout["default"]
|
@@ -1,2 +1,9 @@
|
|
1
|
+
/**
|
2
|
+
* Copyright IBM Corp. 2020, 2023
|
3
|
+
*
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
6
|
+
*/
|
7
|
+
import { Hooks } from 'react-table';
|
8
|
+
declare const useSelectRows: (hooks: Hooks) => void;
|
1
9
|
export default useSelectRows;
|
2
|
-
declare function useSelectRows(hooks: any): void;
|
@@ -117,7 +117,8 @@ var SelectRow = function SelectRow(datagridState) {
|
|
117
117
|
dispatch: dispatch,
|
118
118
|
rowData: row,
|
119
119
|
isChecked: event.target.checked,
|
120
|
-
getRowId: getRowId
|
120
|
+
getRowId: getRowId,
|
121
|
+
selectAll: null
|
121
122
|
});
|
122
123
|
};
|
123
124
|
var selectDisabled = isFetching || row.getRowProps().disabled;
|
@@ -137,7 +138,7 @@ var SelectRow = function SelectRow(datagridState) {
|
|
137
138
|
onSelect: onSelectHandler,
|
138
139
|
id: rowId,
|
139
140
|
name: "".concat(rowId, "-name"),
|
140
|
-
className: cx__default["default"]([checkboxClass, cellProps.className, _rollupPluginBabelHelpers.defineProperty({}, "".concat(checkboxClass, "-sticky-left"), isFirstColumnStickyLeft && windowSize > 671)]),
|
141
|
+
className: cx__default["default"]([checkboxClass, cellProps.className, _rollupPluginBabelHelpers.defineProperty({}, "".concat(checkboxClass, "-sticky-left"), isFirstColumnStickyLeft && Number(windowSize) > 671)]),
|
141
142
|
ariaLabel: title,
|
142
143
|
disabled: selectDisabled
|
143
144
|
}));
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@carbon/ibm-products",
|
3
3
|
"description": "Carbon for IBM Products",
|
4
|
-
"version": "2.42.1-canary.
|
4
|
+
"version": "2.42.1-canary.23+21c921e30",
|
5
5
|
"license": "Apache-2.0",
|
6
6
|
"main": "lib/index.js",
|
7
7
|
"module": "es/index.js",
|
@@ -121,5 +121,5 @@
|
|
121
121
|
"react": "^16.8.6 || ^17.0.1 || ^18.2.0",
|
122
122
|
"react-dom": "^16.8.6 || ^17.0.1 || ^18.2.0"
|
123
123
|
},
|
124
|
-
"gitHead": "
|
124
|
+
"gitHead": "21c921e30c1f0164ad93d214cd310480a29222ab"
|
125
125
|
}
|