From 43193e089bc95359f4c3504da822a15ee4f4c9cf Mon Sep 17 00:00:00 2001 From: gx-mac Date: Wed, 3 Mar 2021 22:09:20 +0800 Subject: [PATCH] fix: version update --- build/Table.js | 11 +++++++---- package.json | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/build/Table.js b/build/Table.js index ad15c2c..95b7418 100644 --- a/build/Table.js +++ b/build/Table.js @@ -514,10 +514,10 @@ var Table = function (_Component) { this.isShowScrollY(); if (this.bodyTable) { var currentOverflowX = window.getComputedStyle(this.bodyTable).overflowX; - if (!this.props.scroll.x && currentOverflowX === 'scroll') { + if ((!this.props.scroll.x || this.props.scroll.x === '100%') && currentOverflowX === 'scroll') { this.bodyTable.style.overflowX = 'hidden'; } - if (this.props.scroll.x && currentOverflowX !== 'scroll') { + if (this.props.scroll.x && this.props.scroll.x !== '100%' && currentOverflowX !== 'scroll') { this.bodyTable.style.overflowX = 'scroll'; } } @@ -1215,7 +1215,7 @@ var Table = function (_Component) { if (this.props.data.length == 0 && this.props.headerScroll) { bodyStyle.overflowX = 'hidden'; } - if (!footerScroll) { + if (!footerScroll && scroll.x !== '100%') { bodyStyle.overflowX = bodyStyle.overflowX || 'auto'; } } @@ -1227,7 +1227,7 @@ var Table = function (_Component) { // bodyStyle.height = bodyStyle.height || scroll.y; innerBodyStyle.maxHeight = bodyStyle.maxHeight || scroll.y; innerBodyStyle.overflowY = bodyStyle.overflowY || 'scroll'; - if (scroll.x) { + if (scroll.x && scroll.x !== '100%') { innerBodyStyle.overflowX = 'scroll'; } } else { @@ -1362,6 +1362,9 @@ var Table = function (_Component) { } delete bodyStyle.overflowX; delete bodyStyle.overflowY; + if (scroll.x === '100%') { + delete bodyStyle.marginBottom; + } BodyTable = _react2["default"].createElement( 'div', { diff --git a/package.json b/package.json index ed54056..168b160 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bee-table", - "version": "2.3.15-beta.3", + "version": "2.3.15-beta.4", "description": "Table ui component for react", "keywords": [ "react",