diff --git a/src/renderer/features/albums/components/album-detail-content.tsx b/src/renderer/features/albums/components/album-detail-content.tsx index 605313a4..91cba79a 100644 --- a/src/renderer/features/albums/components/album-detail-content.tsx +++ b/src/renderer/features/albums/components/album-detail-content.tsx @@ -194,6 +194,7 @@ export const AlbumDetailContent = ({ tableRef }: AlbumDetailContentProps) => { const carousels = [ { data: artistQuery?.data?.items, + isHidden: !artistQuery?.data?.items.length, loading: artistQuery?.isLoading || artistQuery.isFetching, pagination: { handleNextPage: () => handleNextPage('artist'), @@ -205,7 +206,6 @@ export const AlbumDetailContent = ({ tableRef }: AlbumDetailContentProps) => { uniqueId: 'mostPlayed', }, ]; - const playButtonBehavior = usePlayButtonBehavior(); const handlePlay = async (playType?: Play) => { @@ -370,46 +370,51 @@ export const AlbumDetailContent = ({ tableRef }: AlbumDetailContentProps) => { <> {cq.height || cq.width ? ( <> - {carousels.map((carousel, index) => ( - !c.isHidden) + .map((carousel, index) => ( + - ))} + ]} + data={carousel.data} + isLoading={carousel.loading} + itemType={LibraryItem.ALBUM} + route={{ + route: AppRoute.LIBRARY_ALBUMS_DETAIL, + slugs: [{ idProperty: 'id', slugProperty: 'albumId' }], + }} + title={{ + label: carousel.title, + }} + uniqueId={carousel.uniqueId} + /> + ))} ) : null}