Fix: ratings display on player bar and mobile player (#1646)

* fix(playerbar): use settings to display ratings

* fix(mobile player): use settings to display ratings
This commit is contained in:
T
2026-02-03 22:50:43 -08:00
committed by GitHub
parent b4ecf5d257
commit 1f9223b476
2 changed files with 6 additions and 1 deletions
@@ -31,6 +31,7 @@ import {
useCurrentServer,
useFullScreenPlayerStore,
useFullScreenPlayerStoreActions,
useGeneralSettings,
usePlayerData,
usePlayerSong,
useSetFullScreenPlayerStore,
@@ -377,6 +378,7 @@ export const MobileFullscreenPlayer = () => {
const { currentSong: currentSongData } = usePlayerData();
const server = useCurrentServer();
const setFavorite = useSetFavorite();
const { showRatings: showRatingsSetting } = useGeneralSettings();
const setRating = useSetRating();
const [isPageHovered, setIsPageHovered] = useState(false);
@@ -435,6 +437,7 @@ export const MobileFullscreenPlayer = () => {
const isLyricsState = activeTab === 'lyrics';
const isSongDefined = Boolean(currentSong?.id);
const showRating =
showRatingsSetting &&
isSongDefined &&
(server?.type === ServerType.NAVIDROME || server?.type === ServerType.SUBSONIC);
@@ -14,6 +14,7 @@ import {
useAutoDJSettings,
useCurrentServer,
useFullScreenPlayerStore,
useGeneralSettings,
useHotkeySettings,
usePlayerData,
usePlayerMuted,
@@ -63,10 +64,11 @@ const calculateVolumeDown = (volume: number, volumeWheelStep: number) => {
};
export const RightControls = () => {
const { showRatings } = useGeneralSettings();
return (
<Flex align="flex-end" direction="column" h="100%" px="1rem" py="0.5rem">
<Group h="calc(100% / 3)">
<RatingButton />
{showRatings && <RatingButton />}
<AutoDJButton />
</Group>
<Group align="center" gap="xs" wrap="nowrap">