]> littlesong.place Git - littlesongplace.git/commitdiff
Prevent shuffling song lists with 0 or 1 songs
authorChris Fulljames <christianfulljames@gmail.com>
Sun, 2 Mar 2025 19:23:51 +0000 (14:23 -0500)
committerChris Fulljames <christianfulljames@gmail.com>
Sun, 2 Mar 2025 19:23:51 +0000 (14:23 -0500)
templates/song-list.html
todo.txt

index d135fc72a294b2f47eeb8e4237adbbf58f31e216..19784a4ea28760c0c691d3951fa4bd963f5375e5 100644 (file)
@@ -1,9 +1,11 @@
 {% from "song-macros.html" import song_info, song_details %}
 
 <div class="song-list">
+    {% if songs|length > 1 %}
     <div class="song-list-controls">
         <label><input type="checkbox" name="shuffle" onchange="shuffleSongList(event)">Shuffle</label>
     </div>
+    {% endif %}
 
     <div class="song-list-songs">
         {% for song in songs %}
index 2177b71c8437b94b056a3253cce75b8b1ae2aa6a..66208ad63a4500648d59e497f392b7ad77e38128 100644 (file)
--- a/todo.txt
+++ b/todo.txt
@@ -1,5 +1,4 @@
 NOW
-- Hide shuffle button for song lists with 1 song or fewer
 - Pinned profile playlists
 - Player minimize button