@bento-core/table 1.0.0-c3dc.32 → 1.0.0-c3dc.34
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.
|
@@ -30,8 +30,13 @@ const defaultTheme = () => ({
|
|
|
30
30
|
MuiList: {
|
|
31
31
|
root: {
|
|
32
32
|
'&.viewColumnList': {
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
paddingLeft: '19.5px'
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
padding: {
|
|
37
|
+
'&.viewColumnList': {
|
|
38
|
+
paddingTop: '0px',
|
|
39
|
+
paddingBottom: '0px'
|
|
35
40
|
}
|
|
36
41
|
}
|
|
37
42
|
},
|
|
@@ -14,6 +14,10 @@ var _Hidden_Column = _interopRequireDefault(require("./assets/Hidden_Column.svg"
|
|
|
14
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
15
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
16
16
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
17
|
+
// Height threshold to trigger scrolling behavior
|
|
18
|
+
const SCROLL_THRESHOLD_HEIGHT = 400;
|
|
19
|
+
// Maximum height of scrollable content area when scroll is needed
|
|
20
|
+
const SCROLLABLE_MAX_HEIGHT = '253px';
|
|
17
21
|
const ManageColumnView = _ref => {
|
|
18
22
|
let {
|
|
19
23
|
table,
|
|
@@ -30,8 +34,10 @@ const ManageColumnView = _ref => {
|
|
|
30
34
|
} = table;
|
|
31
35
|
const [listDisplay, setListDisplay] = (0, _react.useState)('none');
|
|
32
36
|
const [selectAll, setSelectAll] = (0, _react.useState)(false);
|
|
37
|
+
const [needsScroll, setNeedsScroll] = (0, _react.useState)(false);
|
|
33
38
|
const viewColumns = columns.filter(col => col.role === _Types.cellTypes.DISPLAY && col.disableInManageView !== true);
|
|
34
39
|
const dropdownSelection = (0, _react.useRef)(null);
|
|
40
|
+
const formGroupRef = (0, _react.useRef)(null);
|
|
35
41
|
const handleClose = () => {
|
|
36
42
|
setListDisplay('none');
|
|
37
43
|
};
|
|
@@ -60,6 +66,12 @@ const ManageColumnView = _ref => {
|
|
|
60
66
|
setSelectAll(!selectAll);
|
|
61
67
|
onAllColumnViewChange(!selectAll);
|
|
62
68
|
};
|
|
69
|
+
(0, _react.useEffect)(() => {
|
|
70
|
+
if (formGroupRef.current && listDisplay === 'block') {
|
|
71
|
+
const contentHeight = formGroupRef.current.scrollHeight;
|
|
72
|
+
setNeedsScroll(contentHeight > SCROLL_THRESHOLD_HEIGHT);
|
|
73
|
+
}
|
|
74
|
+
}, [viewColumns, listDisplay]);
|
|
63
75
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
64
76
|
ref: dropdownSelection,
|
|
65
77
|
className: listDisplay === 'none' ? classes.columnDropdown : classes.columnDropdownActive
|
|
@@ -82,15 +94,23 @@ const ManageColumnView = _ref => {
|
|
|
82
94
|
className: classes.arrowDownIcon
|
|
83
95
|
}))), /*#__PURE__*/_react.default.createElement("div", {
|
|
84
96
|
className: listDisplay === 'none' ? classes.dropdownListHidden : classes.dropdownListVisible
|
|
97
|
+
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
98
|
+
className: classes.dropdownHeader
|
|
85
99
|
}, /*#__PURE__*/_react.default.createElement(_core.Typography, {
|
|
86
100
|
variant: "caption",
|
|
87
101
|
className: classes.titleText
|
|
88
102
|
}, manageViewColumns.title), /*#__PURE__*/_react.default.createElement(_core.IconButton, {
|
|
89
103
|
onClick: handleClose,
|
|
90
104
|
className: classes.closeIconButton
|
|
91
|
-
}, /*#__PURE__*/_react.default.createElement(_icons.Close, null)), /*#__PURE__*/_react.default.createElement(_core.List, {
|
|
105
|
+
}, /*#__PURE__*/_react.default.createElement(_icons.Close, null))), /*#__PURE__*/_react.default.createElement(_core.List, {
|
|
92
106
|
className: "viewColumnList",
|
|
93
107
|
id: "dropdownListItemTitle"
|
|
108
|
+
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
109
|
+
ref: formGroupRef,
|
|
110
|
+
className: classes.formGroup,
|
|
111
|
+
style: needsScroll ? {
|
|
112
|
+
maxHeight: SCROLLABLE_MAX_HEIGHT
|
|
113
|
+
} : {}
|
|
94
114
|
}, viewColumns.map((column, index) => /*#__PURE__*/_react.default.createElement(_core.ListItem, {
|
|
95
115
|
width: 1,
|
|
96
116
|
className: "viewColumnListItem",
|
|
@@ -127,19 +147,12 @@ const ManageColumnView = _ref => {
|
|
|
127
147
|
className: classes.textStyle
|
|
128
148
|
}, column.header),
|
|
129
149
|
id: "dropdownListItem-".concat(index, "-label"),
|
|
130
|
-
className:
|
|
131
|
-
|
|
132
|
-
marginLeft: '13px',
|
|
133
|
-
alignItems: 'flex-start'
|
|
134
|
-
}
|
|
135
|
-
}))), /*#__PURE__*/_react.default.createElement(_core.Divider, {
|
|
150
|
+
className: classes.checkboxItemLabel
|
|
151
|
+
})))), /*#__PURE__*/_react.default.createElement(_core.Divider, {
|
|
136
152
|
className: classes.dividerStyle
|
|
137
153
|
}), /*#__PURE__*/_react.default.createElement(_core.ListItem, {
|
|
138
154
|
width: 1,
|
|
139
|
-
className: "viewColumnListItem"
|
|
140
|
-
style: {
|
|
141
|
-
height: '20px'
|
|
142
|
-
}
|
|
155
|
+
className: "viewColumnListItem"
|
|
143
156
|
}, /*#__PURE__*/_react.default.createElement(_core.FormControlLabel, {
|
|
144
157
|
control: /*#__PURE__*/_react.default.createElement(_core.Checkbox, {
|
|
145
158
|
icon: /*#__PURE__*/_react.default.createElement(_icons.CheckBoxOutlineBlank, {
|
|
@@ -170,10 +183,9 @@ const ManageColumnView = _ref => {
|
|
|
170
183
|
className: classes.textStyle
|
|
171
184
|
}, selectAll ? 'Deselect All' : 'Select All'),
|
|
172
185
|
id: "dropdownListItem-all-label",
|
|
186
|
+
className: classes.checkboxItemLabel,
|
|
173
187
|
style: {
|
|
174
|
-
|
|
175
|
-
alignItems: 'flex-start',
|
|
176
|
-
paddingTop: 7
|
|
188
|
+
padding: '2px 0px'
|
|
177
189
|
}
|
|
178
190
|
})))));
|
|
179
191
|
};
|
|
@@ -239,44 +251,34 @@ const styles = () => ({
|
|
|
239
251
|
borderRadius: '5px',
|
|
240
252
|
background: '#ffffff',
|
|
241
253
|
display: 'block',
|
|
242
|
-
maxHeight: '
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
'
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
'&::-webkit-scrollbar-track': {
|
|
250
|
-
background: '#CECECE',
|
|
251
|
-
// Track color
|
|
252
|
-
borderRadius: '5px'
|
|
253
|
-
},
|
|
254
|
-
'&::-webkit-scrollbar-thumb': {
|
|
255
|
-
backgroundColor: '#8B98AF',
|
|
256
|
-
// Thumb color
|
|
257
|
-
borderRadius: '5px'
|
|
258
|
-
}
|
|
254
|
+
maxHeight: '473px'
|
|
255
|
+
},
|
|
256
|
+
dropdownHeader: {
|
|
257
|
+
display: 'flex',
|
|
258
|
+
alignItems: 'center',
|
|
259
|
+
justifyContent: 'space-between',
|
|
260
|
+
padding: '16px 15px 0px 21px'
|
|
259
261
|
},
|
|
260
262
|
titleText: {
|
|
261
263
|
fontFamily: 'Poppins',
|
|
262
264
|
fontWeight: '400',
|
|
263
265
|
fontSize: '14px',
|
|
264
|
-
|
|
265
|
-
position: 'relative',
|
|
266
|
-
top: '15px',
|
|
267
|
-
left: '34px',
|
|
266
|
+
lineHeight: '100%',
|
|
268
267
|
color: '#000000'
|
|
269
268
|
},
|
|
270
269
|
closeIconButton: {
|
|
271
|
-
|
|
272
|
-
bottom: '
|
|
273
|
-
|
|
270
|
+
scale: '0.75',
|
|
271
|
+
bottom: '14.5px',
|
|
272
|
+
left: '12.5px'
|
|
273
|
+
},
|
|
274
|
+
checkboxItemLabel: {
|
|
275
|
+
marginLeft: '0px !important'
|
|
274
276
|
},
|
|
275
277
|
textStyle: {
|
|
276
278
|
fontFamily: 'Poppins',
|
|
277
279
|
fontSize: '14px',
|
|
278
280
|
fontWeight: '400',
|
|
279
|
-
|
|
281
|
+
marginBottom: '3px',
|
|
280
282
|
lineHeight: '15px'
|
|
281
283
|
},
|
|
282
284
|
dividerStyle: {
|
|
@@ -296,7 +298,20 @@ const styles = () => ({
|
|
|
296
298
|
fontWeight: 500
|
|
297
299
|
},
|
|
298
300
|
formGroup: {
|
|
299
|
-
marginTop: '8px'
|
|
301
|
+
marginTop: '8px',
|
|
302
|
+
overflowY: 'auto',
|
|
303
|
+
overflowX: 'hidden',
|
|
304
|
+
'&::-webkit-scrollbar': {
|
|
305
|
+
width: '6px'
|
|
306
|
+
},
|
|
307
|
+
'&::-webkit-scrollbar-track': {
|
|
308
|
+
background: 'transparent',
|
|
309
|
+
borderRadius: '5px'
|
|
310
|
+
},
|
|
311
|
+
'&::-webkit-scrollbar-thumb': {
|
|
312
|
+
backgroundColor: '#707070',
|
|
313
|
+
borderRadius: '5px'
|
|
314
|
+
}
|
|
300
315
|
},
|
|
301
316
|
formControl: {},
|
|
302
317
|
checkbox: {
|
|
@@ -76,18 +76,27 @@ function downloadData(tableData, table, downloadFileName) {
|
|
|
76
76
|
} = table;
|
|
77
77
|
const filterColumns = columns.filter(_ref => {
|
|
78
78
|
let {
|
|
79
|
-
cellType
|
|
80
|
-
doNotDownload
|
|
79
|
+
cellType
|
|
81
80
|
} = _ref;
|
|
82
|
-
return !_Types.actionCellTypes.includes(cellType)
|
|
81
|
+
return !_Types.actionCellTypes.includes(cellType);
|
|
82
|
+
}).filter(_ref2 => {
|
|
83
|
+
let {
|
|
84
|
+
doNotDownload
|
|
85
|
+
} = _ref2;
|
|
86
|
+
return !doNotDownload;
|
|
87
|
+
}).filter(_ref3 => {
|
|
88
|
+
let {
|
|
89
|
+
display
|
|
90
|
+
} = _ref3;
|
|
91
|
+
return display;
|
|
83
92
|
});
|
|
84
93
|
let formatDataVal = (0, _Dataformat.formatColumnValues)(filterColumns, tableData);
|
|
85
94
|
formatDataVal = formatDataVal.map(item => {
|
|
86
95
|
const updatedItem = {};
|
|
87
|
-
filterColumns.forEach(
|
|
96
|
+
filterColumns.forEach(_ref4 => {
|
|
88
97
|
let {
|
|
89
98
|
dataField
|
|
90
|
-
} =
|
|
99
|
+
} = _ref4;
|
|
91
100
|
updatedItem[dataField] = item[dataField];
|
|
92
101
|
});
|
|
93
102
|
return updatedItem;
|
|
@@ -112,27 +121,27 @@ function downloadData(tableData, table, downloadFileName) {
|
|
|
112
121
|
fileType = 'application/json';
|
|
113
122
|
} else {
|
|
114
123
|
const jsonse = JSON.stringify(formatDataVal);
|
|
115
|
-
const keysToInclude = filterColumns.filter(
|
|
124
|
+
const keysToInclude = filterColumns.filter(_ref5 => {
|
|
116
125
|
let {
|
|
117
126
|
dataField
|
|
118
|
-
} =
|
|
127
|
+
} = _ref5;
|
|
119
128
|
return dataField;
|
|
120
|
-
}).map(
|
|
129
|
+
}).map(_ref6 => {
|
|
121
130
|
let {
|
|
122
131
|
dataField
|
|
123
|
-
} =
|
|
132
|
+
} = _ref6;
|
|
124
133
|
return dataField;
|
|
125
134
|
});
|
|
126
|
-
const headers = filterColumns.filter(
|
|
135
|
+
const headers = filterColumns.filter(_ref7 => {
|
|
127
136
|
let {
|
|
128
137
|
dataField
|
|
129
|
-
} =
|
|
138
|
+
} = _ref7;
|
|
130
139
|
return dataField;
|
|
131
|
-
}).map(
|
|
140
|
+
}).map(_ref8 => {
|
|
132
141
|
let {
|
|
133
142
|
header,
|
|
134
143
|
downloadHeader
|
|
135
|
-
} =
|
|
144
|
+
} = _ref8;
|
|
136
145
|
return downloadHeader || header;
|
|
137
146
|
});
|
|
138
147
|
fileContent = convertToCSV(jsonse, keysToInclude, headers);
|
package/package.json
CHANGED
package/src/DefaultThemConfig.js
CHANGED
|
@@ -24,8 +24,13 @@ const defaultTheme = () => ({
|
|
|
24
24
|
MuiList: {
|
|
25
25
|
root: {
|
|
26
26
|
'&.viewColumnList': {
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
paddingLeft: '19.5px',
|
|
28
|
+
},
|
|
29
|
+
},
|
|
30
|
+
padding: {
|
|
31
|
+
'&.viewColumnList': {
|
|
32
|
+
paddingTop: '0px',
|
|
33
|
+
paddingBottom: '0px',
|
|
29
34
|
},
|
|
30
35
|
},
|
|
31
36
|
},
|
|
@@ -20,6 +20,11 @@ import { cellTypes } from '../util/Types';
|
|
|
20
20
|
import viewColumnsIcon from './assets/View_Columns.svg';
|
|
21
21
|
import hiddenColumnsIcon from './assets/Hidden_Column.svg';
|
|
22
22
|
|
|
23
|
+
// Height threshold to trigger scrolling behavior
|
|
24
|
+
const SCROLL_THRESHOLD_HEIGHT = 400;
|
|
25
|
+
// Maximum height of scrollable content area when scroll is needed
|
|
26
|
+
const SCROLLABLE_MAX_HEIGHT = '253px';
|
|
27
|
+
|
|
23
28
|
const ManageColumnView = ({
|
|
24
29
|
table,
|
|
25
30
|
onColumnViewChange,
|
|
@@ -33,11 +38,13 @@ const ManageColumnView = ({
|
|
|
33
38
|
const { columns } = table;
|
|
34
39
|
const [listDisplay, setListDisplay] = useState('none');
|
|
35
40
|
const [selectAll, setSelectAll] = useState(false);
|
|
41
|
+
const [needsScroll, setNeedsScroll] = useState(false);
|
|
36
42
|
|
|
37
43
|
const viewColumns = columns.filter((col) => col.role === cellTypes.DISPLAY
|
|
38
44
|
&& col.disableInManageView !== true);
|
|
39
45
|
|
|
40
46
|
const dropdownSelection = useRef(null);
|
|
47
|
+
const formGroupRef = useRef(null);
|
|
41
48
|
|
|
42
49
|
const handleClose = () => {
|
|
43
50
|
setListDisplay('none');
|
|
@@ -71,6 +78,13 @@ const ManageColumnView = ({
|
|
|
71
78
|
onAllColumnViewChange(!selectAll);
|
|
72
79
|
};
|
|
73
80
|
|
|
81
|
+
useEffect(() => {
|
|
82
|
+
if (formGroupRef.current && listDisplay === 'block') {
|
|
83
|
+
const contentHeight = formGroupRef.current.scrollHeight;
|
|
84
|
+
setNeedsScroll(contentHeight > SCROLL_THRESHOLD_HEIGHT);
|
|
85
|
+
}
|
|
86
|
+
}, [viewColumns, listDisplay]);
|
|
87
|
+
|
|
74
88
|
return (
|
|
75
89
|
<div ref={dropdownSelection} className={listDisplay === 'none' ? classes.columnDropdown : classes.columnDropdownActive}>
|
|
76
90
|
<Tooltip title="Columns may be hidden">
|
|
@@ -83,63 +97,70 @@ const ManageColumnView = ({
|
|
|
83
97
|
</IconButton>
|
|
84
98
|
</Tooltip>
|
|
85
99
|
<div className={listDisplay === 'none' ? classes.dropdownListHidden : classes.dropdownListVisible}>
|
|
86
|
-
<
|
|
87
|
-
{
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
100
|
+
<div className={classes.dropdownHeader}>
|
|
101
|
+
<Typography variant="caption" className={classes.titleText}>
|
|
102
|
+
{manageViewColumns.title}
|
|
103
|
+
</Typography>
|
|
104
|
+
<IconButton
|
|
105
|
+
onClick={handleClose}
|
|
106
|
+
className={classes.closeIconButton}
|
|
107
|
+
>
|
|
108
|
+
<Close />
|
|
109
|
+
</IconButton>
|
|
110
|
+
</div>
|
|
111
|
+
|
|
95
112
|
<List className="viewColumnList" id="dropdownListItemTitle">
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
<
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
113
|
+
<div
|
|
114
|
+
ref={formGroupRef}
|
|
115
|
+
className={classes.formGroup}
|
|
116
|
+
style={needsScroll ? { maxHeight: SCROLLABLE_MAX_HEIGHT } : {}}
|
|
117
|
+
>
|
|
118
|
+
{viewColumns.map((column, index) => (
|
|
119
|
+
<ListItem
|
|
120
|
+
width={1}
|
|
121
|
+
className="viewColumnListItem"
|
|
122
|
+
id={`dropdownListItem-${index}`}
|
|
123
|
+
>
|
|
124
|
+
<FormControlLabel
|
|
125
|
+
control={(
|
|
126
|
+
<Checkbox
|
|
127
|
+
icon={(
|
|
128
|
+
<CheckBoxBlankIcon
|
|
129
|
+
style={{ fontSize: 18 }}
|
|
130
|
+
className="checkBoxIcon"
|
|
131
|
+
/>
|
|
132
|
+
)}
|
|
133
|
+
onClick={() => onColumnViewChange(column)}
|
|
134
|
+
checked={column.display}
|
|
135
|
+
id={`dropdownListItemCheckbox-${index}`}
|
|
136
|
+
checkedIcon={(
|
|
137
|
+
<CheckBoxIcon
|
|
138
|
+
style={{
|
|
139
|
+
fontSize: 18,
|
|
140
|
+
color: column.hideable ? 'rgba(109, 95, 91, 1)' : 'rgba(109, 95, 91, 0.38)',
|
|
141
|
+
}}
|
|
142
|
+
className="checkBoxIcon"
|
|
143
|
+
/>
|
|
144
|
+
)}
|
|
145
|
+
disableRipple
|
|
146
|
+
color="secondary"
|
|
147
|
+
className="checkBox"
|
|
148
|
+
disabled={!column.hideable}
|
|
149
|
+
style={{ paddingTop: 0 }}
|
|
150
|
+
/>
|
|
151
|
+
)}
|
|
152
|
+
disabled={!column.hideable}
|
|
153
|
+
label={<Typography id={`dropdownListItemLabel-${index}`} className={classes.textStyle}>{column.header}</Typography>}
|
|
154
|
+
id={`dropdownListItem-${index}-label`}
|
|
155
|
+
className={classes.checkboxItemLabel}
|
|
156
|
+
/>
|
|
157
|
+
</ListItem>
|
|
158
|
+
))}
|
|
159
|
+
</div>
|
|
138
160
|
<Divider className={classes.dividerStyle} />
|
|
139
161
|
<ListItem
|
|
140
162
|
width={1}
|
|
141
163
|
className="viewColumnListItem"
|
|
142
|
-
style={{ height: '20px' }}
|
|
143
164
|
>
|
|
144
165
|
<FormControlLabel
|
|
145
166
|
control={(
|
|
@@ -174,7 +195,8 @@ const ManageColumnView = ({
|
|
|
174
195
|
</Typography>
|
|
175
196
|
)}
|
|
176
197
|
id="dropdownListItem-all-label"
|
|
177
|
-
|
|
198
|
+
className={classes.checkboxItemLabel}
|
|
199
|
+
style={{ padding: '2px 0px' }}
|
|
178
200
|
/>
|
|
179
201
|
</ListItem>
|
|
180
202
|
</List>
|
|
@@ -245,41 +267,34 @@ const styles = () => ({
|
|
|
245
267
|
borderRadius: '5px',
|
|
246
268
|
background: '#ffffff',
|
|
247
269
|
display: 'block',
|
|
248
|
-
maxHeight: '
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
'
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
'
|
|
255
|
-
background: '#CECECE', // Track color
|
|
256
|
-
borderRadius: '5px',
|
|
257
|
-
},
|
|
258
|
-
'&::-webkit-scrollbar-thumb': {
|
|
259
|
-
backgroundColor: '#8B98AF', // Thumb color
|
|
260
|
-
borderRadius: '5px',
|
|
261
|
-
},
|
|
270
|
+
maxHeight: '473px',
|
|
271
|
+
},
|
|
272
|
+
dropdownHeader: {
|
|
273
|
+
display: 'flex',
|
|
274
|
+
alignItems: 'center',
|
|
275
|
+
justifyContent: 'space-between',
|
|
276
|
+
padding: '16px 15px 0px 21px',
|
|
262
277
|
},
|
|
263
278
|
titleText: {
|
|
264
279
|
fontFamily: 'Poppins',
|
|
265
280
|
fontWeight: '400',
|
|
266
281
|
fontSize: '14px',
|
|
267
|
-
|
|
268
|
-
position: 'relative',
|
|
269
|
-
top: '15px',
|
|
270
|
-
left: '34px',
|
|
282
|
+
lineHeight: '100%',
|
|
271
283
|
color: '#000000',
|
|
272
284
|
},
|
|
273
285
|
closeIconButton: {
|
|
274
|
-
float: 'right',
|
|
275
|
-
bottom: '20px',
|
|
276
286
|
scale: '0.75',
|
|
287
|
+
bottom: '14.5px',
|
|
288
|
+
left: '12.5px',
|
|
289
|
+
},
|
|
290
|
+
checkboxItemLabel: {
|
|
291
|
+
marginLeft: '0px !important',
|
|
277
292
|
},
|
|
278
293
|
textStyle: {
|
|
279
294
|
fontFamily: 'Poppins',
|
|
280
295
|
fontSize: '14px',
|
|
281
296
|
fontWeight: '400',
|
|
282
|
-
|
|
297
|
+
marginBottom: '3px',
|
|
283
298
|
lineHeight: '15px',
|
|
284
299
|
},
|
|
285
300
|
dividerStyle: {
|
|
@@ -300,6 +315,19 @@ const styles = () => ({
|
|
|
300
315
|
},
|
|
301
316
|
formGroup: {
|
|
302
317
|
marginTop: '8px',
|
|
318
|
+
overflowY: 'auto',
|
|
319
|
+
overflowX: 'hidden',
|
|
320
|
+
'&::-webkit-scrollbar': {
|
|
321
|
+
width: '6px',
|
|
322
|
+
},
|
|
323
|
+
'&::-webkit-scrollbar-track': {
|
|
324
|
+
background: 'transparent',
|
|
325
|
+
borderRadius: '5px',
|
|
326
|
+
},
|
|
327
|
+
'&::-webkit-scrollbar-thumb': {
|
|
328
|
+
backgroundColor: '#707070',
|
|
329
|
+
borderRadius: '5px',
|
|
330
|
+
},
|
|
303
331
|
},
|
|
304
332
|
formControl: {},
|
|
305
333
|
checkbox: {
|
|
@@ -63,8 +63,10 @@ export function convertToCSV(jsonse, keysToInclude, header) {
|
|
|
63
63
|
|
|
64
64
|
export function downloadData(tableData, table, downloadFileName, format = 'csv') {
|
|
65
65
|
const { columns = [] } = table;
|
|
66
|
-
const filterColumns = columns
|
|
67
|
-
|
|
66
|
+
const filterColumns = columns
|
|
67
|
+
.filter(({ cellType }) => !actionCellTypes.includes(cellType))
|
|
68
|
+
.filter(({ doNotDownload }) => !doNotDownload)
|
|
69
|
+
.filter(({ display }) => display);
|
|
68
70
|
let formatDataVal = formatColumnValues(filterColumns, tableData);
|
|
69
71
|
|
|
70
72
|
formatDataVal = formatDataVal.map((item) => {
|