oops
This commit is contained in:
parent
31a8d62f1d
commit
1599371df5
1 changed files with 2 additions and 2 deletions
|
@ -130,7 +130,7 @@ const Files = component$(() => {
|
||||||
console.log("Loading more files...");
|
console.log("Loading more files...");
|
||||||
|
|
||||||
debounce(async () => {
|
debounce(async () => {
|
||||||
const newFiles = await api.list(page.value, 4); // gotta be a multiple of 4 so pages dont look weird
|
const newFiles = await api.list(page.value, 12); // gotta be a multiple of 4 so pages dont look weird
|
||||||
if (newFiles.length === 0) {
|
if (newFiles.length === 0) {
|
||||||
hasMore.value = false;
|
hasMore.value = false;
|
||||||
if (sentinel.value) observer.unobserve(sentinel.value);
|
if (sentinel.value) observer.unobserve(sentinel.value);
|
||||||
|
@ -160,7 +160,7 @@ const Files = component$(() => {
|
||||||
{hasMore.value && (
|
{hasMore.value && (
|
||||||
<div
|
<div
|
||||||
ref={sentinel}
|
ref={sentinel}
|
||||||
class="absolute bottom-0 left-0 h-56 flex items-center justify-center w-full bg-blue-500"
|
class="absolute bottom-0 left-0 h-56 flex items-center justify-center w-full"
|
||||||
>
|
>
|
||||||
{/* {loadingMore.value && (
|
{/* {loadingMore.value && (
|
||||||
loading spinner?
|
loading spinner?
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue