|
|
|
@ -25,7 +25,6 @@ interface Props {
|
|
|
|
|
/** 收藏按钮的显示逻辑 always: 总是显示 playing: 播放时显示 */
|
|
|
|
|
collectType?: 'always' | 'playing';
|
|
|
|
|
className?: string;
|
|
|
|
|
style?: React.CSSProperties;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default function SongCardList({ height, listInfo, songList, className, collectType = 'always', style }: Props) {
|
|
|
|
@ -66,12 +65,11 @@ export default function SongCardList({ height, listInfo, songList, className, co
|
|
|
|
|
setAudioId(id);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
function Item({ index }: { index: number }) {
|
|
|
|
|
function Item({ index, style }: { index: number; style: React.CSSProperties }) {
|
|
|
|
|
const item = songList[index];
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<div key={item?.id} style={style}>
|
|
|
|
|
<SongCard
|
|
|
|
|
key={item?.id}
|
|
|
|
|
{...item}
|
|
|
|
|
playState={playState}
|
|
|
|
|
showEq={item?.id === audioId}
|
|
|
|
|