From dc2fe77e40f60527da8783c24e9376e91268e869 Mon Sep 17 00:00:00 2001 From: Adrien Joly <531781+adrienjoly@users.noreply.github.com> Date: Sun, 10 Jun 2018 13:57:24 +0200 Subject: [PATCH] feat(design): display cover art and tags --- _layouts/default.html | 1 + index.css | 33 +++++++++++++++++++++++++++++++++ index.md | 16 ++++++++++++++-- 3 files changed, 48 insertions(+), 2 deletions(-) create mode 100644 index.css diff --git a/_layouts/default.html b/_layouts/default.html index c59a47c..02221fb 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -7,6 +7,7 @@ {% seo %} +
diff --git a/index.css b/index.css new file mode 100644 index 0000000..49e9a39 --- /dev/null +++ b/index.css @@ -0,0 +1,33 @@ +* { + box-sizing: border-box; +} + +article { + display: inline-block; + width: 320px; + height: 420px; + padding: 8px; + overflow: hidden; +} + +article img { + width: 320px; + height: 320px; +} + +.markdown-body article p { + margin-bottom: 0; +} + +.release-date { + color: gray; + font-size: 90%; +} + +.tag { + color: white; + background-color: lightgray; + border-radius: 12px; + font-size: 90%; + padding: 2px 8px; +} diff --git a/index.md b/index.md index 57dc6ef..e523290 100644 --- a/index.md +++ b/index.md @@ -3,6 +3,18 @@ title: My Albums --- {% for album in site.data.albums %} -- [{{ album.title }}, by {{ album.artist }}]({{ album.url }})
- {{ album.release_date | date: "%b %-d, %Y" }} +
+ + {{ album.title }} {{ album.artist }} +

{{ album.title }}

+
+

by {{ album.artist }}

+ {% if album.tags %} + {% for tag in album.tags %} + {{ tag }} + {% endfor %} + {% else %} + {{ album.release_date | date: "%b %-d, %Y" }} + {% endif %} +
{% endfor %}