Commit 6353d33a authored by FuryBean's avatar FuryBean Committed by cinwell.li

Table: fix a script error when show-header is true. (#1248)

parent 34e01710
......@@ -194,11 +194,12 @@
const { bodyWrapper, headerWrapper } = this.$refs;
const refs = this.$refs;
bodyWrapper.addEventListener('scroll', function() {
headerWrapper.scrollLeft = this.scrollLeft;
if (headerWrapper) headerWrapper.scrollLeft = this.scrollLeft;
if (refs.fixedBodyWrapper) refs.fixedBodyWrapper.scrollTop = this.scrollTop;
if (refs.rightFixedBodyWrapper) refs.rightFixedBodyWrapper.scrollTop = this.scrollTop;
});
if (headerWrapper) {
mousewheel(headerWrapper, throttle(16, function(event) {
const deltaX = event.deltaX;
......@@ -208,6 +209,7 @@
bodyWrapper.scrollLeft = bodyWrapper.scrollLeft - 10;
}
}));
}
if (this.fit) {
this.windowResizeListener = throttle(50, () => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment