diff --git a/Moo/play/templates/alpha-buttons.html b/Moo/play/templates/alpha-buttons.html new file mode 100644 index 0000000..338eeab --- /dev/null +++ b/Moo/play/templates/alpha-buttons.html @@ -0,0 +1,13 @@ +

+ + {% for letter in alpha | sort %} + + {% if request.path == "/alpha/" + letter %} + {{ letter }} + {% else %} + {{ letter }} + {% endif %} + + {% endfor %} + +

diff --git a/Moo/play/templates/audio-controls.html b/Moo/play/templates/audio-controls.html new file mode 100644 index 0000000..b84bb44 --- /dev/null +++ b/Moo/play/templates/audio-controls.html @@ -0,0 +1,7 @@ +{% if request.path.startswith('/track') %} +{% set autoplay = 'autoplay' %} +{% endif %} + + diff --git a/Moo/play/templates/audio-table.html b/Moo/play/templates/audio-table.html new file mode 100644 index 0000000..64c0d4e --- /dev/null +++ b/Moo/play/templates/audio-table.html @@ -0,0 +1,75 @@ +
+ + + + + + + + {% set artist = track.artist or track.album_artist or "None" %} + + {% if (artist | length + track.album | length) < 32 %} + {% set dash = True %} + {% endif %} + + {% if artist | length > 32 %} + {% set artist = artist.split(';')[0].split(',')[0] %} + {% endif %} + + + + + + {% set album = track.album or "ALBUM" | safe %} + + + + + + + + + + + + + +
+ {{ track.title }} +
+ {{ artist }} +
+ + {{ album }} +
+ {% include "audio-controls.html" %} +
+ {{ emoji.app | safe }} + + {{ emoji.prev | safe }} + + + {%- if track.disc %}{{ track.disc }}.{% endif -%} + {{ "{:02d}".format(track.track | int) }} + + {{ emoji.next | safe }} + + {{ emoji.random | safe }} + +
+ +
diff --git a/Moo/play/templates/covers-heading.html b/Moo/play/templates/covers-heading.html new file mode 100644 index 0000000..2ab88d1 --- /dev/null +++ b/Moo/play/templates/covers-heading.html @@ -0,0 +1,17 @@ +{% if request.path != '/' %} +{% set arg = request.path.split('/')[-1] %} +{% endif %} + +

+ + {{ "{:,}".format(albums | length) }} + {% if arg %}{{ arg }}{% endif %} + albums + +

+ + + +{% for counter in counts %} +{% include "counter.html" %} +{% endfor %} diff --git a/Moo/play/templates/emoji-buttons.html b/Moo/play/templates/emoji-buttons.html new file mode 100644 index 0000000..3e21f21 --- /dev/null +++ b/Moo/play/templates/emoji-buttons.html @@ -0,0 +1,8 @@ +
+ + {{ emoji.base | safe }} + {{ emoji.none | safe }} + + {{ emoji.starred | safe }} + {{ emoji.hearted | safe }} +
diff --git a/Moo/play/templates/facet-buttons.html b/Moo/play/templates/facet-buttons.html new file mode 100644 index 0000000..4f939d8 --- /dev/null +++ b/Moo/play/templates/facet-buttons.html @@ -0,0 +1,46 @@ +

+ + {{ emoji.app | safe }} + + + Albums + {{ "{:,}".format(total) }} + + + + Artists + {{ "{:,}".format(counts['artist'] | length) }} + + + + Genres + {{ "{:,}".format(counts['genre'] | length) }} + + + + Years + {{ "{:,}".format(counts['year'] | length) }} + + + + Formats + {{ "{:,}".format(counts['format'] | length) }} + + + {{ emoji.help | safe }} + +

diff --git a/Moo/play/templates/genre-buttons.html b/Moo/play/templates/genre-buttons.html new file mode 100644 index 0000000..44497f7 --- /dev/null +++ b/Moo/play/templates/genre-buttons.html @@ -0,0 +1,14 @@ +
+ + {% for label in genre_buttons %} + + {% if label == request.path.split('/')[-1] %} + {{ label }} + {% else %} + {{ label }} + {% endif %} + + {% endfor %} + +
diff --git a/Moo/play/templates/recently-played.html b/Moo/play/templates/recently-played.html new file mode 100644 index 0000000..64afd74 --- /dev/null +++ b/Moo/play/templates/recently-played.html @@ -0,0 +1,5 @@ +{% if recent %} +

+ Recently played +

+{% endif %} diff --git a/Moo/play/templates/station-buttons.html b/Moo/play/templates/station-buttons.html new file mode 100644 index 0000000..7110da9 --- /dev/null +++ b/Moo/play/templates/station-buttons.html @@ -0,0 +1,13 @@ +
+ {% for station in stations %} + + {% if station == station %} + {{ station }} + {% else %} + {{ station }} + {% endif %} + + {% endfor %} +
+ + diff --git a/Moo/play/templates/tracklist-footer.html b/Moo/play/templates/tracklist-footer.html new file mode 100644 index 0000000..005b2c1 --- /dev/null +++ b/Moo/play/templates/tracklist-footer.html @@ -0,0 +1,16 @@ +

+ + + {{ metadata | length }} + + {{ info.encoding }} + + + + {{ info.size }} + + {{ info.length }} + +

diff --git a/Moo/play/templates/tracklist-heading.html b/Moo/play/templates/tracklist-heading.html new file mode 100644 index 0000000..3407a7a --- /dev/null +++ b/Moo/play/templates/tracklist-heading.html @@ -0,0 +1,15 @@ +

+ + + {{ info['year'] or "YEAR" | safe }} + + + + {{ info['genre'] or "GENRE" | safe }} + + + {{ emoji.star | safe }} {{ emoji.heart | safe }} + +