fix:表头错位问题
This commit is contained in:
parent
4b4bdcd588
commit
cc103f4e69
|
@ -330,7 +330,6 @@ var Table = function (_Component) {
|
|||
}
|
||||
// 是否传入 scroll中的y属性,如果传入判断是否是整数,如果是则进行比较 。bodyTable 的clientHeight进行判断
|
||||
this.isShowScrollY();
|
||||
this.scrollbarWidth = (0, _utils.measureScrollbar)();
|
||||
};
|
||||
|
||||
Table.prototype.componentWillUnmount = function componentWillUnmount() {
|
||||
|
|
|
@ -47,8 +47,7 @@ function measureScrollbar() {
|
|||
if (typeof document === 'undefined' || typeof window === 'undefined') {
|
||||
return 0;
|
||||
}
|
||||
var tableDom = document.querySelector('.u-table');
|
||||
var currentDom = tableDom ? tableDom : document.body;
|
||||
var currentDom = document.body;
|
||||
|
||||
if (scrollbarSize) {
|
||||
return scrollbarSize;
|
||||
|
|
|
@ -34182,7 +34182,6 @@
|
|||
}
|
||||
// 是否传入 scroll中的y属性,如果传入判断是否是整数,如果是则进行比较 。bodyTable 的clientHeight进行判断
|
||||
this.isShowScrollY();
|
||||
this.scrollbarWidth = (0, _utils.measureScrollbar)();
|
||||
};
|
||||
|
||||
Table.prototype.componentWillUnmount = function componentWillUnmount() {
|
||||
|
@ -37223,8 +37222,7 @@
|
|||
if (typeof document === 'undefined' || typeof window === 'undefined') {
|
||||
return 0;
|
||||
}
|
||||
var tableDom = document.querySelector('.u-table');
|
||||
var currentDom = tableDom ? tableDom : document.body;
|
||||
var currentDom = document.body;
|
||||
|
||||
if (scrollbarSize) {
|
||||
return scrollbarSize;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -221,7 +221,6 @@ class Table extends Component {
|
|||
}
|
||||
// 是否传入 scroll中的y属性,如果传入判断是否是整数,如果是则进行比较 。bodyTable 的clientHeight进行判断
|
||||
this.isShowScrollY();
|
||||
this.scrollbarWidth = measureScrollbar();
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
|
|
|
@ -17,8 +17,7 @@ export function measureScrollbar(direction = 'vertical') {
|
|||
if (typeof document === 'undefined' || typeof window === 'undefined') {
|
||||
return 0;
|
||||
}
|
||||
const tableDom =document.querySelector('.u-table');
|
||||
let currentDom = tableDom?tableDom:document.body;
|
||||
let currentDom = document.body;
|
||||
|
||||
if (scrollbarSize) {
|
||||
return scrollbarSize;
|
||||
|
|
Loading…
Reference in New Issue