Skip to content

Commit

Permalink
fix(project): fix missing shelves and cards
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristiaanScheermeijer committed Oct 5, 2022
1 parent 35ff1f1 commit e490487
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/CardGrid/CardGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ function CardGrid({
<InfiniteScroll
pageStart={0}
loadMore={() => setRowCount((current) => current + LOAD_ROWS_COUNT)}
hasMore={rowCount * LOAD_ROWS_COUNT < playlist.playlist.length - 1}
hasMore={rowCount * visibleTiles < playlist.playlist.length}
loader={<InfiniteScrollLoader key="loader" />}
>
<div className={classNames(styles.container, styles[`cols-${visibleTiles}`])} role="grid">
Expand Down
2 changes: 1 addition & 1 deletion src/containers/ShelfList/ShelfList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ const ShelfList = ({ rows }: Props) => {
pageStart={0}
style={{ overflow: 'hidden' }}
loadMore={() => setRowCount((current) => current + LOAD_ROWS_COUNT)}
hasMore={rowCount < rows.length - 1}
hasMore={rowCount < rows.length}
role="grid"
loader={<InfiniteScrollLoader key="loader" />}
>
Expand Down

0 comments on commit e490487

Please sign in to comment.