mirror of
https://github.com/GiriNeko/YesPlayMusic.git
synced 2025-12-18 06:07:48 +00:00
refactor: 将 player.ts 里面的Mode.PLAYLIST改为 Mode.TrackList
This commit is contained in:
parent
7b6579e068
commit
0061a66124
6 changed files with 22 additions and 12 deletions
|
|
@ -37,10 +37,15 @@ const PlayButton = ({
|
|||
const playerSnapshot = useSnapshot(player)
|
||||
const isThisAlbumPlaying = useMemo(
|
||||
() =>
|
||||
playerSnapshot.mode === PlayerMode.PLAYLIST &&
|
||||
playerSnapshot.mode === PlayerMode.TrackList &&
|
||||
playerSnapshot.trackListSource?.type === TrackListSourceType.ALBUM &&
|
||||
playerSnapshot.trackListSource?.id === album?.id,
|
||||
[playerSnapshot.trackListSource, album?.id]
|
||||
[
|
||||
playerSnapshot.mode,
|
||||
playerSnapshot.trackListSource?.type,
|
||||
playerSnapshot.trackListSource?.id,
|
||||
album?.id,
|
||||
]
|
||||
)
|
||||
|
||||
const isPlaying =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue