diff --git a/index.html b/index.html index 1c4e866..83952e1 100644 --- a/index.html +++ b/index.html @@ -640,38 +640,59 @@ ); }; - const PlaylistDrawer = ({ playlist, currentSong, playSong, onClose, clearPlaylist, deleteSong }) => ( -
-
e.stopPropagation()}> -
-

当前播放 ({playlist.length})

-
- - + const PlaylistDrawer = ({ playlist, currentSong, playSong, onClose, clearPlaylist, deleteSong, mode, toggleMode }) => { + const getModeText = () => { + switch(mode) { + case 'one': return '单曲循环'; + case 'shuffle': return '随机播放'; + default: return '列表循环'; + } + }; + + return ( +
+
e.stopPropagation()}> +
+
+

当前播放 ({playlist.length})

+ {playlist.length > 0 && ( + + )} +
+
+ + +
+
+
+ {playlist.length === 0 ? ( +
+ +

播放列表为空

+
+ ) : ( + playlist.map((song, idx) => ( + playSong(song)} + onDelete={() => deleteSong(idx)} + /> + )) + )}
-
- {playlist.length === 0 ? ( -
- -

播放列表为空

-
- ) : ( - playlist.map((song, idx) => ( - playSong(song)} - onDelete={() => deleteSong(idx)} - /> - )) - )} -
-
- ); + ); + }; const TopListPage = ({ source, onBack, onPlaySong, onLike, isLiked }) => { const [lists, setLists] = useState([]); @@ -1316,13 +1337,15 @@ )} {showPlaylist && ( - { setCurrentSong(song); setIsPlaying(true); }} onClose={() => setShowPlaylist(false)} clearPlaylist={() => { setPlaylist([]); setCurrentSong(null); setIsPlaying(false); }} deleteSong={deleteFromPlaylist} + mode={mode} + toggleMode={toggleMode} /> )}