remove rating from item card if using jellyfin

This commit is contained in:
Kendall Garner
2025-12-14 16:45:54 -08:00
parent 08a8f7f500
commit f5d6c4983c
@@ -21,6 +21,7 @@ import {
Artist, Artist,
LibraryItem, LibraryItem,
Playlist, Playlist,
ServerType,
Song, Song,
} from '/@/shared/types/domain-types'; } from '/@/shared/types/domain-types';
import { Play } from '/@/shared/types/types'; import { Play } from '/@/shared/types/types';
@@ -265,12 +266,14 @@ export const ItemCardControls = ({
{controls?.onFavorite && ( {controls?.onFavorite && (
<FavoriteButton isFavorite={isFavorite} onClick={favoriteHandler} /> <FavoriteButton isFavorite={isFavorite} onClick={favoriteHandler} />
)} )}
{controls?.onRating && ( {controls?.onRating &&
<RatingButton (item?._serverType === ServerType.NAVIDROME ||
onChange={ratingChangeHandler} item?._serverType === ServerType.SUBSONIC) && (
rating={(item as { userRating: number }).userRating} <RatingButton
/> onChange={ratingChangeHandler}
)} rating={(item as { userRating: number }).userRating}
/>
)}
{controls?.onMore && ( {controls?.onMore && (
<SecondaryButton <SecondaryButton
className={styles.options} className={styles.options}