diff --git a/src/renderer/features/albums/components/album-detail-content.tsx b/src/renderer/features/albums/components/album-detail-content.tsx index 00c44123..2a0b457d 100644 --- a/src/renderer/features/albums/components/album-detail-content.tsx +++ b/src/renderer/features/albums/components/album-detail-content.tsx @@ -13,9 +13,10 @@ import type { AgGridReact as AgGridReactType } from '@ag-grid-community/react/li import { Box, Group, Stack } from '@mantine/core'; import { useSetState } from '@mantine/hooks'; import { RiHeartFill, RiHeartLine, RiMoreFill } from 'react-icons/ri'; -import { useParams } from 'react-router'; +import { generatePath, useParams } from 'react-router'; import { useAlbumDetail } from '/@/renderer/features/albums/queries/album-detail-query'; import { useSongListStore } from '/@/renderer/store'; +import { Link } from 'react-router-dom'; import styled from 'styled-components'; import { AppRoute } from '/@/renderer/router/routes'; import { useContainerQuery } from '/@/renderer/hooks'; @@ -177,58 +178,85 @@ export const AlbumDetailContent = ({ tableRef }: AlbumDetailContentProps) => { } }; + const showGenres = detailQuery?.data?.genres ? detailQuery?.data?.genres.length !== 0 : false; + const { intersectRef, tableContainerRef } = useFixedTableHeader(); return ( - - handlePlay(playButtonBehavior)} /> - - - - - - - - {PLAY_TYPES.filter((type) => type.play !== playButtonBehavior).map((type) => ( - handlePlay(type.play)} + + + handlePlay(playButtonBehavior)} /> + + + + + + + + {PLAY_TYPES.filter((type) => type.play !== playButtonBehavior).map((type) => ( + handlePlay(type.play)} + > + {type.label} + + ))} + + Add to playlist + + + - + + {showGenres && ( + + + {detailQuery?.data?.genres?.map((genre) => ( + + ))} + + + )}