feat: 修改滚动问题

pull/269/head
raoyongjun 1 year ago
parent 0d7deafeb0
commit 908fc9c799

@ -322,17 +322,20 @@ async function loadMore() {
// listData.value.push(...more)
if (pagination.pageNo == 1) {
listData.value = []
listData.value = listData.value.concat(more)
console.log('listData.value出来了', listData.value)
waterfallRef.value?.resize()
}
else {
setTimeout(() => {
const height = document.getElementsByClassName('vue-waterfall-column')[0].style.height - 300
console.log('listData.value出来了height', document.getElementById('vueWaterfall').style.height)
el.value?.scrollTo({ top: height, behavior: 'smooth' })
}, 50)
}
// setTimeout(() => {
// const height = el.value?.scrollHeight - 1000
// console.log('listData.valueheight', height)
// el.value?.scrollTo({ top: height, behavior: 'smooth' })
// }, 50)
listData.value = listData.value.concat(more)
waterfallRef.value?.resize()
console.log('listData.value出来了', listData.value)
waterfallRef.value?.mix()
}
}
const gridHeight = computed(() => {

Loading…
Cancel
Save