rsuite-table
Advanced tools
Comparing version 3.12.0 to 3.12.1
105
es/Table.js
@@ -926,5 +926,3 @@ import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose"; | ||
_proto.calculateRowMaxHeight = function calculateRowMaxHeight() { | ||
var _this$props19 = this.props, | ||
wordWrap = _this$props19.wordWrap, | ||
rowHeight = _this$props19.rowHeight; | ||
var wordWrap = this.props.wordWrap; | ||
@@ -937,4 +935,3 @@ if (wordWrap) { | ||
var _tableRows$i = tableRows[i], | ||
row = _tableRows$i[0], | ||
rowData = _tableRows$i[1]; | ||
row = _tableRows$i[0]; | ||
@@ -944,3 +941,3 @@ if (row) { | ||
var cellArray = Array.from(cells); | ||
var maxHeight = typeof rowHeight === 'function' ? rowHeight(rowData) : rowHeight; | ||
var maxHeight = 0; | ||
@@ -989,6 +986,6 @@ for (var j = 0; j < cellArray.length; j++) { | ||
var rows = table.querySelectorAll("." + this.addPrefix('row')) || []; | ||
var _this$props20 = this.props, | ||
height = _this$props20.height, | ||
autoHeight = _this$props20.autoHeight, | ||
rowHeight = _this$props20.rowHeight; | ||
var _this$props19 = this.props, | ||
height = _this$props19.height, | ||
autoHeight = _this$props19.autoHeight, | ||
rowHeight = _this$props19.rowHeight; | ||
var headerHeight = this.getTableHeaderHeight(); | ||
@@ -1056,7 +1053,7 @@ var contentHeight = rows.length ? Array.from(rows).map(function (row) { | ||
_proto.renderRowData = function renderRowData(bodyCells, rowData, props, shouldRenderExpandedRow) { | ||
var _this$props21 = this.props, | ||
renderTreeToggle = _this$props21.renderTreeToggle, | ||
rowKey = _this$props21.rowKey, | ||
wordWrap = _this$props21.wordWrap, | ||
isTree = _this$props21.isTree; | ||
var _this$props20 = this.props, | ||
renderTreeToggle = _this$props20.renderTreeToggle, | ||
rowKey = _this$props20.rowKey, | ||
wordWrap = _this$props20.wordWrap, | ||
isTree = _this$props20.isTree; | ||
var hasChildren = isTree && rowData.children && Array.isArray(rowData.children); | ||
@@ -1175,5 +1172,5 @@ var nextRowKey = typeof rowData[rowKey] !== 'undefined' ? rowData[rowKey] : props.key; | ||
_proto.renderRowExpanded = function renderRowExpanded(rowData) { | ||
var _this$props22 = this.props, | ||
renderRowExpanded = _this$props22.renderRowExpanded, | ||
rowExpandedHeight = _this$props22.rowExpandedHeight; | ||
var _this$props21 = this.props, | ||
renderRowExpanded = _this$props21.renderRowExpanded, | ||
rowExpandedHeight = _this$props21.rowExpandedHeight; | ||
var styles = { | ||
@@ -1243,10 +1240,10 @@ height: rowExpandedHeight | ||
_proto.renderTableBody = function renderTableBody(bodyCells, rowWidth) { | ||
var _this$props23 = this.props, | ||
rowExpandedHeight = _this$props23.rowExpandedHeight, | ||
renderRowExpanded = _this$props23.renderRowExpanded, | ||
isTree = _this$props23.isTree, | ||
rowKey = _this$props23.rowKey, | ||
wordWrap = _this$props23.wordWrap, | ||
virtualized = _this$props23.virtualized, | ||
rowHeight = _this$props23.rowHeight; | ||
var _this$props22 = this.props, | ||
rowExpandedHeight = _this$props22.rowExpandedHeight, | ||
renderRowExpanded = _this$props22.renderRowExpanded, | ||
isTree = _this$props22.isTree, | ||
rowKey = _this$props22.rowKey, | ||
wordWrap = _this$props22.wordWrap, | ||
virtualized = _this$props22.virtualized, | ||
rowHeight = _this$props22.rowHeight; | ||
var headerHeight = this.getTableHeaderHeight(); | ||
@@ -1291,3 +1288,3 @@ var _this$state7 = this.state, | ||
} else { | ||
nextRowHeight = maxHeight ? maxHeight + CELL_PADDING_HEIGHT : rowHeight; | ||
nextRowHeight = maxHeight ? Math.max(maxHeight + CELL_PADDING_HEIGHT, rowHeight) : rowHeight; | ||
@@ -1389,6 +1386,6 @@ if (shouldRenderExpandedRow) { | ||
_proto.renderInfo = function renderInfo() { | ||
var _this$props24 = this.props, | ||
locale = _this$props24.locale, | ||
renderEmpty = _this$props24.renderEmpty, | ||
loading = _this$props24.loading; | ||
var _this$props23 = this.props, | ||
locale = _this$props23.locale, | ||
renderEmpty = _this$props23.renderEmpty, | ||
loading = _this$props23.loading; | ||
@@ -1406,5 +1403,5 @@ if (this._visibleRows.length || loading) { | ||
_proto.renderScrollbar = function renderScrollbar() { | ||
var _this$props25 = this.props, | ||
disabledScroll = _this$props25.disabledScroll, | ||
affixHorizontalScrollbar = _this$props25.affixHorizontalScrollbar; | ||
var _this$props24 = this.props, | ||
disabledScroll = _this$props24.disabledScroll, | ||
affixHorizontalScrollbar = _this$props24.affixHorizontalScrollbar; | ||
var _this$state8 = this.state, | ||
@@ -1449,7 +1446,7 @@ contentWidth = _this$state8.contentWidth, | ||
_proto.renderLoading = function renderLoading() { | ||
var _this$props26 = this.props, | ||
locale = _this$props26.locale, | ||
loading = _this$props26.loading, | ||
loadAnimation = _this$props26.loadAnimation, | ||
renderLoading = _this$props26.renderLoading; | ||
var _this$props25 = this.props, | ||
locale = _this$props25.locale, | ||
loading = _this$props25.loading, | ||
loadAnimation = _this$props25.loadAnimation, | ||
renderLoading = _this$props25.renderLoading; | ||
@@ -1475,17 +1472,17 @@ if (!loadAnimation && !loading) { | ||
var _this$props27 = this.props, | ||
children = _this$props27.children, | ||
className = _this$props27.className, | ||
_this$props27$width = _this$props27.width, | ||
width = _this$props27$width === void 0 ? 0 : _this$props27$width, | ||
style = _this$props27.style, | ||
isTree = _this$props27.isTree, | ||
hover = _this$props27.hover, | ||
bordered = _this$props27.bordered, | ||
cellBordered = _this$props27.cellBordered, | ||
wordWrap = _this$props27.wordWrap, | ||
classPrefix = _this$props27.classPrefix, | ||
loading = _this$props27.loading, | ||
showHeader = _this$props27.showHeader, | ||
rest = _objectWithoutPropertiesLoose(_this$props27, ["children", "className", "width", "style", "isTree", "hover", "bordered", "cellBordered", "wordWrap", "classPrefix", "loading", "showHeader"]); | ||
var _this$props26 = this.props, | ||
children = _this$props26.children, | ||
className = _this$props26.className, | ||
_this$props26$width = _this$props26.width, | ||
width = _this$props26$width === void 0 ? 0 : _this$props26$width, | ||
style = _this$props26.style, | ||
isTree = _this$props26.isTree, | ||
hover = _this$props26.hover, | ||
bordered = _this$props26.bordered, | ||
cellBordered = _this$props26.cellBordered, | ||
wordWrap = _this$props26.wordWrap, | ||
classPrefix = _this$props26.classPrefix, | ||
loading = _this$props26.loading, | ||
showHeader = _this$props26.showHeader, | ||
rest = _objectWithoutPropertiesLoose(_this$props26, ["children", "className", "width", "style", "isTree", "hover", "bordered", "cellBordered", "wordWrap", "classPrefix", "loading", "showHeader"]); | ||
@@ -1492,0 +1489,0 @@ var isColumnResizing = this.state.isColumnResizing; |
105
lib/Table.js
@@ -957,5 +957,3 @@ "use strict"; | ||
_proto.calculateRowMaxHeight = function calculateRowMaxHeight() { | ||
var _this$props19 = this.props, | ||
wordWrap = _this$props19.wordWrap, | ||
rowHeight = _this$props19.rowHeight; | ||
var wordWrap = this.props.wordWrap; | ||
@@ -968,4 +966,3 @@ if (wordWrap) { | ||
var _tableRows$i = tableRows[i], | ||
row = _tableRows$i[0], | ||
rowData = _tableRows$i[1]; | ||
row = _tableRows$i[0]; | ||
@@ -975,3 +972,3 @@ if (row) { | ||
var cellArray = Array.from(cells); | ||
var maxHeight = typeof rowHeight === 'function' ? rowHeight(rowData) : rowHeight; | ||
var maxHeight = 0; | ||
@@ -1020,6 +1017,6 @@ for (var j = 0; j < cellArray.length; j++) { | ||
var rows = table.querySelectorAll("." + this.addPrefix('row')) || []; | ||
var _this$props20 = this.props, | ||
height = _this$props20.height, | ||
autoHeight = _this$props20.autoHeight, | ||
rowHeight = _this$props20.rowHeight; | ||
var _this$props19 = this.props, | ||
height = _this$props19.height, | ||
autoHeight = _this$props19.autoHeight, | ||
rowHeight = _this$props19.rowHeight; | ||
var headerHeight = this.getTableHeaderHeight(); | ||
@@ -1087,7 +1084,7 @@ var contentHeight = rows.length ? Array.from(rows).map(function (row) { | ||
_proto.renderRowData = function renderRowData(bodyCells, rowData, props, shouldRenderExpandedRow) { | ||
var _this$props21 = this.props, | ||
renderTreeToggle = _this$props21.renderTreeToggle, | ||
rowKey = _this$props21.rowKey, | ||
wordWrap = _this$props21.wordWrap, | ||
isTree = _this$props21.isTree; | ||
var _this$props20 = this.props, | ||
renderTreeToggle = _this$props20.renderTreeToggle, | ||
rowKey = _this$props20.rowKey, | ||
wordWrap = _this$props20.wordWrap, | ||
isTree = _this$props20.isTree; | ||
var hasChildren = isTree && rowData.children && Array.isArray(rowData.children); | ||
@@ -1204,5 +1201,5 @@ var nextRowKey = typeof rowData[rowKey] !== 'undefined' ? rowData[rowKey] : props.key; | ||
_proto.renderRowExpanded = function renderRowExpanded(rowData) { | ||
var _this$props22 = this.props, | ||
renderRowExpanded = _this$props22.renderRowExpanded, | ||
rowExpandedHeight = _this$props22.rowExpandedHeight; | ||
var _this$props21 = this.props, | ||
renderRowExpanded = _this$props21.renderRowExpanded, | ||
rowExpandedHeight = _this$props21.rowExpandedHeight; | ||
var styles = { | ||
@@ -1272,10 +1269,10 @@ height: rowExpandedHeight | ||
_proto.renderTableBody = function renderTableBody(bodyCells, rowWidth) { | ||
var _this$props23 = this.props, | ||
rowExpandedHeight = _this$props23.rowExpandedHeight, | ||
renderRowExpanded = _this$props23.renderRowExpanded, | ||
isTree = _this$props23.isTree, | ||
rowKey = _this$props23.rowKey, | ||
wordWrap = _this$props23.wordWrap, | ||
virtualized = _this$props23.virtualized, | ||
rowHeight = _this$props23.rowHeight; | ||
var _this$props22 = this.props, | ||
rowExpandedHeight = _this$props22.rowExpandedHeight, | ||
renderRowExpanded = _this$props22.renderRowExpanded, | ||
isTree = _this$props22.isTree, | ||
rowKey = _this$props22.rowKey, | ||
wordWrap = _this$props22.wordWrap, | ||
virtualized = _this$props22.virtualized, | ||
rowHeight = _this$props22.rowHeight; | ||
var headerHeight = this.getTableHeaderHeight(); | ||
@@ -1320,3 +1317,3 @@ var _this$state7 = this.state, | ||
} else { | ||
nextRowHeight = maxHeight ? maxHeight + _constants.CELL_PADDING_HEIGHT : rowHeight; | ||
nextRowHeight = maxHeight ? Math.max(maxHeight + _constants.CELL_PADDING_HEIGHT, rowHeight) : rowHeight; | ||
@@ -1418,6 +1415,6 @@ if (shouldRenderExpandedRow) { | ||
_proto.renderInfo = function renderInfo() { | ||
var _this$props24 = this.props, | ||
locale = _this$props24.locale, | ||
renderEmpty = _this$props24.renderEmpty, | ||
loading = _this$props24.loading; | ||
var _this$props23 = this.props, | ||
locale = _this$props23.locale, | ||
renderEmpty = _this$props23.renderEmpty, | ||
loading = _this$props23.loading; | ||
@@ -1435,5 +1432,5 @@ if (this._visibleRows.length || loading) { | ||
_proto.renderScrollbar = function renderScrollbar() { | ||
var _this$props25 = this.props, | ||
disabledScroll = _this$props25.disabledScroll, | ||
affixHorizontalScrollbar = _this$props25.affixHorizontalScrollbar; | ||
var _this$props24 = this.props, | ||
disabledScroll = _this$props24.disabledScroll, | ||
affixHorizontalScrollbar = _this$props24.affixHorizontalScrollbar; | ||
var _this$state8 = this.state, | ||
@@ -1478,7 +1475,7 @@ contentWidth = _this$state8.contentWidth, | ||
_proto.renderLoading = function renderLoading() { | ||
var _this$props26 = this.props, | ||
locale = _this$props26.locale, | ||
loading = _this$props26.loading, | ||
loadAnimation = _this$props26.loadAnimation, | ||
renderLoading = _this$props26.renderLoading; | ||
var _this$props25 = this.props, | ||
locale = _this$props25.locale, | ||
loading = _this$props25.loading, | ||
loadAnimation = _this$props25.loadAnimation, | ||
renderLoading = _this$props25.renderLoading; | ||
@@ -1504,17 +1501,17 @@ if (!loadAnimation && !loading) { | ||
var _this$props27 = this.props, | ||
children = _this$props27.children, | ||
className = _this$props27.className, | ||
_this$props27$width = _this$props27.width, | ||
width = _this$props27$width === void 0 ? 0 : _this$props27$width, | ||
style = _this$props27.style, | ||
isTree = _this$props27.isTree, | ||
hover = _this$props27.hover, | ||
bordered = _this$props27.bordered, | ||
cellBordered = _this$props27.cellBordered, | ||
wordWrap = _this$props27.wordWrap, | ||
classPrefix = _this$props27.classPrefix, | ||
loading = _this$props27.loading, | ||
showHeader = _this$props27.showHeader, | ||
rest = (0, _objectWithoutPropertiesLoose2["default"])(_this$props27, ["children", "className", "width", "style", "isTree", "hover", "bordered", "cellBordered", "wordWrap", "classPrefix", "loading", "showHeader"]); | ||
var _this$props26 = this.props, | ||
children = _this$props26.children, | ||
className = _this$props26.className, | ||
_this$props26$width = _this$props26.width, | ||
width = _this$props26$width === void 0 ? 0 : _this$props26$width, | ||
style = _this$props26.style, | ||
isTree = _this$props26.isTree, | ||
hover = _this$props26.hover, | ||
bordered = _this$props26.bordered, | ||
cellBordered = _this$props26.cellBordered, | ||
wordWrap = _this$props26.wordWrap, | ||
classPrefix = _this$props26.classPrefix, | ||
loading = _this$props26.loading, | ||
showHeader = _this$props26.showHeader, | ||
rest = (0, _objectWithoutPropertiesLoose2["default"])(_this$props26, ["children", "className", "width", "style", "isTree", "hover", "bordered", "cellBordered", "wordWrap", "classPrefix", "loading", "showHeader"]); | ||
var isColumnResizing = this.state.isColumnResizing; | ||
@@ -1521,0 +1518,0 @@ |
{ | ||
"name": "rsuite-table", | ||
"version": "3.12.0", | ||
"version": "3.12.1", | ||
"description": "A React table component", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
Sorry, the diff of this file is not supported yet
390743
8380