feat: genre pages

This commit is contained in:
Cory Dransfeldt 2024-05-26 14:25:03 -07:00
parent f6ec72f469
commit 086a7bf6c9
No known key found for this signature in database
29 changed files with 165 additions and 67 deletions

View file

@ -10,6 +10,6 @@ schema: music
---
<a class="back-link-header link-icon flex-centered" href="/music">{% tablericon "arrow-left" "Go back" %} Go back</a>
<h2 class="page-header">{{ title }}</h2>
<p>I've listened to <strong class="highlight-text">{{ music.threeMonth.artists.size }} artists</strong> over the last 3 months and most of what I've listened to has been <strong class="highlight-text">{{ music.threeMonth.genres | genresToString: 5 }}</strong>.</p>
<p>I've listened to <strong class="highlight-text">{{ music.threeMonth.artists.size }} artists</strong> over the last 3 months and most of what I've listened to has been {{ music.threeMonth.genres | sortByPlaysDescending | genreStrings: "genre" | genreLinks: 5 }}.</p>
<p><strong class="highlight-text">See my</strong> <a href="/music/albums/three-months/">albums</a> or <a href="/music/tracks/three-months/">tracks</a> for this period.</p>
{% render "partials/media/music/period/grid.liquid" data:pagination %}

View file

@ -10,6 +10,6 @@ schema: music
---
<a class="back-link-header link-icon flex-centered" href="/music">{% tablericon "arrow-left" "Go back" %} Go back</a>
<h2 class="page-header">{{ title }}</h2>
<p>I've listened to <strong class="highlight-text">{{ music.allTime.artists.size }} artists</strong> and most of what I listen to is <strong class="highlight-text">{{ music.allTime.genres | genresToString: 5 }}</strong>.</p>
<p>I've listened to <strong class="highlight-text">{{ music.allTime.artists.size }} artists</strong> and most of what I listen to is {{ music.allTime.genres | sortByPlaysDescending | genreStrings: "genre" | genreLinks: 5 }}.</p>
<p><strong class="highlight-text">See my</strong> <a href="/music/albums/all-time/">albums</a> or <a href="/music/tracks/all-time/">tracks</a> for this period.</p>
{% render "partials/media/music/period/grid.liquid" data:pagination %}

View file

@ -4,7 +4,7 @@ pagination:
data: artists
size: 1
alias: artist
permalink: /music/artists/{{ artist.name_string | slugify | downcase }}-{{ artist.country | slugify | downcase}}/
permalink: /music/artists/{{ artist.name_string | slugify | downcase }}-{{ artist.country | slugify | downcase}}/index.html
updated: "now"
schema: artist
---
@ -28,14 +28,18 @@ schema: artist
{%- if artist.total_plays > 0 -%}
<p class="sub-meta"><strong class="highlight-text">{{ artist.total_plays }} plays</strong></p>
{%- endif -%}
<p class="sub-meta">{{ artist.genre }}</p>
<p class="sub-meta">
<a href="https://coryd.dev/music/genre/{{ artist.genre | slugify | downcase }}">
{{ artist.genre }}
</a>
</p>
<p class="sub-meta">
<a class="brain" href="https://musicbrainz.org/artist/{{ artist.mbid }}">{% tablericon "brain" "MusicBrainz" %}</a>
</p>
</div>
</div>
{%- if artist.description -%}
<div data-toggle-content class="text-toggle-hidden">{{ artist.description | markdown }}</div>
<div data-toggle-content class="text-toggle-hidden"><em>{{ artist.description | markdown }}</em></div>
<button data-toggle-button>Show more</button>
{%- endif -%}
<table>

View file

@ -10,6 +10,6 @@ schema: music
---
<a class="back-link-header link-icon flex-centered" href="/music">{% tablericon "arrow-left" "Go back" %} Go back</a>
<h2 class="page-header">{{ title }}</h2>
<p>I've listened to <strong class="highlight-text">{{ music.month.artists.size }} artists</strong> this month and most of what I've listened to has been <strong class="highlight-text">{{ music.month.genres | genresToString: 5 }}</strong>.</p>
<p>I've listened to <strong class="highlight-text">{{ music.month.artists.size }} artists</strong> this month and most of what I've listened to has been {{ music.month.genres | sortByPlaysDescending | genreStrings: "genre" | genreLinks: 5 }}.</p>
<p><strong class="highlight-text">See my</strong> <a href="/music/albums/this-month/">albums</a> or <a href="/music/tracks/this-month/">tracks</a> for this period.</p>
{% render "partials/media/music/period/grid.liquid" data:pagination %}

View file

@ -10,6 +10,6 @@ schema: music
---
<a class="back-link-header link-icon flex-centered" href="/music">{% tablericon "arrow-left" "Go back" %} Go back</a>
<h2 class="page-header">{{ title }}</h2>
<p>I've listened to <strong class="highlight-text">{{ music.week.artists.size }} artists</strong> this week and most of what I've listened to has been <strong class="highlight-text">{{ music.week.genres | genresToString: 5 }}</strong>.</p>
<p>I've listened to <strong class="highlight-text">{{ music.week.artists.size }} artists</strong> this week and most of what I've listened to has been {{ music.week.genres | sortByPlaysDescending | genreStrings: "genre" | genreLinks: 5 }}.</p>
<p><strong class="highlight-text">See my</strong> <a href="/music/albums/this-week/">albums</a> or <a href="/music/tracks/this-week/">tracks</a> for this period.</p>
{% render "partials/media/music/period/grid.liquid" data:pagination %}