mirror of
https://iceshrimp.dev/crimekillz/trashposs
synced 2024-11-22 00:43:49 +01:00
hmm
This commit is contained in:
parent
082d9d8743
commit
818eb47663
@ -71,11 +71,19 @@ defineExpose({
|
|||||||
scrollTop,
|
scrollTop,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const fetchedRecently = ref(false);
|
||||||
|
|
||||||
setInterval(() => {
|
setInterval(() => {
|
||||||
if (!tlEl.value) return;
|
if (!tlEl.value || fetchedRecently.value) return;
|
||||||
const viewport = document.documentElement.clientHeight;
|
const viewport = document.documentElement.clientHeight;
|
||||||
const left = document.documentElement.scrollHeight - document.documentElement.scrollTop;
|
const left = document.documentElement.scrollHeight - document.documentElement.scrollTop;
|
||||||
if (left <= viewport * 3) pagingComponent.value.fetchMore();
|
if (left <= viewport * 3) {
|
||||||
|
pagingComponent.value.fetchMore();
|
||||||
|
fetchedRecently.value = true;
|
||||||
|
setTimeout(() => {
|
||||||
|
fetchedRecently.value = false;
|
||||||
|
}, 500);
|
||||||
|
}
|
||||||
}, 100);
|
}, 100);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user