NEZ-2842 feat: 添加历史记录 以及国际化补充

This commit is contained in:
zhangyu
2023-06-06 17:09:01 +08:00
parent 8c0ea18ad9
commit 97937b4989
5 changed files with 269 additions and 163 deletions

View File

@@ -1102,12 +1102,15 @@ export const loadMore = {
console.log(el, binding, el.parentNode, 'bind')
// 获取element定义scroll
const selectDom = binding.dom ? el.querySelector(binding.dom) : el
heightLoad = function () {
const height = this.scrollHeight - this.scrollTop - 20 <= this.clientHeight
if (height && el.hasMore) {
heightLoad = bus.debounce(function () {
if (!el.hasMore) {
return
}
const height = this.scrollHeight - this.scrollTop - 10 <= this.clientHeight
if (height) {
binding.value.load()
}
}
}, 100)
selectDom.addEventListener('scroll', heightLoad)
},
update (el, binding) {