取消自动滚动
This commit is contained in:
@@ -142,7 +142,7 @@ Vue.component("scrollTable", {
|
||||
const dom = this.$el.querySelector('.el-table__body-wrapper')
|
||||
this.scroll = new SimpleBar(dom)
|
||||
dom.addEventListener('mouseover', this.stopAutoScroll)
|
||||
dom.addEventListener('mouseout', this.autoScroll)
|
||||
// dom.addEventListener('mouseout', this.autoScroll)
|
||||
// this.scroll.refresh();
|
||||
},
|
||||
autoScroll() {
|
||||
@@ -162,14 +162,14 @@ Vue.component("scrollTable", {
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.initScroll()
|
||||
this.autoScroll()
|
||||
this.initScroll()
|
||||
// this.autoScroll()
|
||||
},
|
||||
beforeDestroy() {
|
||||
this.stopAutoScroll()
|
||||
const dom = this.$el.querySelector('.el-table__body-wrapper')
|
||||
dom.removeEventListener("mouseover", this.stopAutoScroll)
|
||||
dom.removeEventListener("mouseout", this.autoScroll)
|
||||
// dom.removeEventListener("mouseout", this.autoScroll)
|
||||
}
|
||||
})
|
||||
Vue.component("tableColumn", {
|
||||
|
||||
Reference in New Issue
Block a user