1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

apply suggestion

This commit is contained in:
grafixeyehero 2023-06-25 03:15:21 +03:00
parent 17e8ccc93a
commit 00ec92cc02
7 changed files with 31 additions and 61 deletions

View file

@ -18,8 +18,8 @@ const GenresItemsContainer: FC<GenresItemsContainerProps> = ({
itemType
}) => {
const { isLoading, data: genresResult } = useGetGenres(
parentId,
itemType
itemType,
parentId
);
if (isLoading) {
@ -34,8 +34,7 @@ const GenresItemsContainer: FC<GenresItemsContainerProps> = ({
<p>{globalize.translate('MessageNoGenresAvailable')}</p>
</div>
) : (
genresResult?.Items
&& genresResult?.Items.map((genre) => (
genresResult?.Items?.map((genre) => (
<GenresSectionContainer
key={genre.Id}
collectionType={collectionType}

View file

@ -52,7 +52,12 @@ const RecommendationContainer: FC<RecommendationContainerProps> = ({
items={recommendation.Items || []}
cardOptions={{
shape: 'overflowPortrait',
showYear: true
showYear: true,
scalable: true,
overlayPlayButton: true,
showTitle: true,
centerText: true,
cardLayout: false
}}
/>
);

View file

@ -39,7 +39,7 @@ const SuggestionsView: FC<LibraryViewProps> = ({ parentId }) => {
return (
<RecommendationContainer
// eslint-disable-next-line react/no-array-index-key
key={index} // use a unique id return value may have duplicate id
key={`${recommendation.CategoryId}-${index}`} // use a unique id return value may have duplicate id
recommendation={recommendation}
/>
);