Commit d87fb5be by limin

Merge branch 'master' of http://192.168.3.233:8090/npm/glsx-components into master

2 parents 8ce31181 84d3dfd4
This diff could not be displayed because it is too large.
......@@ -225,7 +225,8 @@ export default {
showClass: false,
tableHeightValues: null,
bAntiShike: false, //防抖
componentKey: Date.now() //用于更新组件
componentKey: Date.now(), //用于更新组件
hightCell:''
}
},
......@@ -243,10 +244,16 @@ export default {
},
methods: {
handleScroll() {
requestAnimationFrame(()=>{
this.hoverFn('','',this.hightCell)
})
},
// 竖线高亮实现
hoverFn(row, column, cell, event) {
// console.log('row, column, cell, event: ', cell.offsetHeight)
setTimeout(() => {
requestAnimationFrame(() => {
this.hightCell = cell
const height = cell.offsetHeight
const offsetTop = cell.getBoundingClientRect().y
if (!hignLigihtLine) {
......@@ -402,10 +409,15 @@ export default {
}, 300)
}
}
//监听滚动事件
window.addEventListener("scroll", this.handleScroll, true);
},
beforeDestroy() {
// 事件注销
window.onresize = null
//监听滚动事件
window.removeEventListener("scroll", this.handleScroll, true);
}
}
</script>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!