@yilianjituan/yilian_dgerm 1.0.5-alpha.2 → 1.0.5-alpha.4
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.
|
@@ -456,8 +456,8 @@ var PageTemplate = function PageTemplate(props, ref) {
|
|
|
456
456
|
tableLayout: (tableProps === null || tableProps === void 0 ? void 0 : tableProps.tableLayout) || 'auto'
|
|
457
457
|
}, tableProps, {
|
|
458
458
|
scroll: {
|
|
459
|
-
x: (tableProps === null || tableProps === void 0 || (_tableProps$scroll = tableProps.scroll) === null || _tableProps$scroll === void 0 ? void 0 : _tableProps$scroll.x) || 1500,
|
|
460
|
-
y: (tableProps === null || tableProps === void 0 || (_tableProps$scroll2 = tableProps.scroll) === null || _tableProps$scroll2 === void 0 ? void 0 : _tableProps$scroll2.y) ||
|
|
459
|
+
x: dataSource.length > 0 ? (tableProps === null || tableProps === void 0 || (_tableProps$scroll = tableProps.scroll) === null || _tableProps$scroll === void 0 ? void 0 : _tableProps$scroll.x) || 'max-content' : 1500,
|
|
460
|
+
y: dataSource.length > 0 ? (tableProps === null || tableProps === void 0 || (_tableProps$scroll2 = tableProps.scroll) === null || _tableProps$scroll2 === void 0 ? void 0 : _tableProps$scroll2.y) || 'max-content' : 1500
|
|
461
461
|
}
|
|
462
462
|
// components={{ header: { cell: ResizableTitle } }}
|
|
463
463
|
// columns={mergedColumns(columns, tableRef, (_columns) =>
|
|
@@ -216,8 +216,8 @@ var CustomTable = function CustomTable(props) {
|
|
|
216
216
|
tableLayout: tableLayout || 'auto'
|
|
217
217
|
}, restProps, {
|
|
218
218
|
scroll: {
|
|
219
|
-
x: (restProps === null || restProps === void 0 || (_restProps$scroll = restProps.scroll) === null || _restProps$scroll === void 0 ? void 0 : _restProps$scroll.x) || 1500,
|
|
220
|
-
y: (restProps === null || restProps === void 0 || (_restProps$scroll2 = restProps.scroll) === null || _restProps$scroll2 === void 0 ? void 0 : _restProps$scroll2.y) ||
|
|
219
|
+
x: dataSource && dataSource.length > 0 ? (restProps === null || restProps === void 0 || (_restProps$scroll = restProps.scroll) === null || _restProps$scroll === void 0 ? void 0 : _restProps$scroll.x) || 'max-content' : 1500,
|
|
220
|
+
y: dataSource && dataSource.length > 0 ? (restProps === null || restProps === void 0 || (_restProps$scroll2 = restProps.scroll) === null || _restProps$scroll2 === void 0 ? void 0 : _restProps$scroll2.y) || 'max-content' : 1500
|
|
221
221
|
}
|
|
222
222
|
})));
|
|
223
223
|
};
|