固定列滚动条不可拖拽

This commit is contained in:
wanghaoo 2018-12-06 18:24:50 +08:00
parent 29fb01dcf4
commit 1eac3bea4f
7 changed files with 21 additions and 15 deletions

View File

@ -31,7 +31,5 @@
.u-table-filter-column-filter-icon{
right: 15px;
}
.u-table-scroll .u-table-header{
margin-right: 15px;
}
}

2
dist/demo.css vendored
View File

@ -10310,8 +10310,6 @@ li.rc-time-picker-panel-select-option-disabled:hover {
height: 100%; }
.demo25 .u-table-filter-column-filter-icon {
right: 15px; }
.demo25 .u-table-scroll .u-table-header {
margin-right: 15px; }
th .drop-menu .uf {
font-size: 12px;

2
dist/demo.css.map vendored

File diff suppressed because one or more lines are too long

13
dist/demo.js vendored
View File

@ -11482,10 +11482,15 @@
)
);
}
var leftFixedWidth = this.columnManager.getLeftColumnsWidth();
var rightFixedWidth = this.columnManager.getRightColumnsWidth();
var parStyle = {};
if (!fixed) {
parStyle = { 'marginLeft': leftFixedWidth, 'marginRight': rightFixedWidth };
}
return _react2['default'].createElement(
'span',
null,
'div',
{ style: parStyle },
headTable,
BodyTable
);
@ -11692,7 +11697,7 @@
{ className: clsPrefix + '-content' },
_react2['default'].createElement(
'div',
{ className: isTableScroll ? clsPrefix + '-scroll' : '', style: { 'marginLeft': leftFixedWidth } },
{ className: isTableScroll ? clsPrefix + '-scroll' : '' },
this.getTable({ columns: this.columnManager.groupedColumns() }),
this.getEmptyText(),
this.getFooter()

2
dist/demo.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
{
"name": "bee-table",
"version": "1.6.10-beta.0",
"version": "1.6.10-beta.1",
"description": "Table ui component for react",
"keywords": [
"react",

View File

@ -807,8 +807,13 @@ class Table extends Component {
</div>
);
}
return <span>{headTable}{BodyTable}</span>;
const leftFixedWidth = this.columnManager.getLeftColumnsWidth();
const rightFixedWidth = this.columnManager.getRightColumnsWidth();
let parStyle = {}
if(!fixed){
parStyle = {'marginLeft':leftFixedWidth,'marginRight':rightFixedWidth}
}
return <div style={parStyle}>{headTable}{BodyTable}</div>;
}
getTitle() {
@ -988,7 +993,7 @@ class Table extends Component {
{this.getTitle()}
<div className={`${clsPrefix}-content`}>
<div className={isTableScroll ? `${clsPrefix}-scroll` : ''} style={{'marginLeft':leftFixedWidth}}>
<div className={isTableScroll ? `${clsPrefix}-scroll` : ''} >
{this.getTable({ columns: this.columnManager.groupedColumns() })}
{this.getEmptyText()}
{this.getFooter()}