chore: reorganize home page to put media + activity in single section
This commit is contained in:
parent
965c48fc3e
commit
0ccc749cd8
5 changed files with 85 additions and 92 deletions
4
package-lock.json
generated
4
package-lock.json
generated
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "coryd.dev",
|
||||
"version": "3.7.4",
|
||||
"version": "3.8.4",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "coryd.dev",
|
||||
"version": "3.7.4",
|
||||
"version": "3.8.4",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"html-minifier-terser": "7.2.0",
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "coryd.dev",
|
||||
"version": "3.7.4",
|
||||
"version": "3.8.4",
|
||||
"description": "The source for my personal site. Built using 11ty (and other tools).",
|
||||
"type": "module",
|
||||
"engines": {
|
||||
|
|
|
@ -1,62 +1,56 @@
|
|||
<article>
|
||||
<h2>
|
||||
{% tablericon "activity" %}
|
||||
Recent activity
|
||||
</h2>
|
||||
{%- for item in items -%}
|
||||
<article class="{{ item.type }}">
|
||||
<aside>
|
||||
{%- if item.featured -%}
|
||||
{% tablericon "star" %}
|
||||
{%- endif -%}
|
||||
<time datetime="{{ item.content_date }}">
|
||||
{{ item.content_date | date:"%B %e, %Y" }}
|
||||
</time>
|
||||
• {{ item.label }}
|
||||
{%- if item.notes -%}
|
||||
{% assign notes = item.notes | markdown %}
|
||||
{% render "blocks/dialog.liquid",
|
||||
icon:"info-circle",
|
||||
label:"View info about this concert"
|
||||
dynamic:"optimized_concerts",
|
||||
markdown:"concert_notes",
|
||||
id:item.id
|
||||
%}
|
||||
{%- endif -%}
|
||||
</aside>
|
||||
<h3>
|
||||
{%- if item.type == "concerts" -%}
|
||||
{%- capture artistName -%}
|
||||
{%- if item.artist_url -%}
|
||||
<a href="{{ item.artist_url }}">{{ item.title | split: ' at ' | first }}</a>
|
||||
{%- else -%}
|
||||
{{ item.title | split: ' at ' | first }}
|
||||
{%- endif -%}
|
||||
{%- endcapture -%}
|
||||
{%- capture venue -%}
|
||||
{%- if item.venue_lat and item.venue_lon -%}
|
||||
<a href="https://www.openstreetmap.org/?mlat={{ item.venue_lat }}&mlon={{ item.venue_lon }}#map=18/{{ item.venue_lat }}/{{ item.venue_lon }}">{{ item.venue_name }}</a>
|
||||
{%- else -%}
|
||||
{{ item.venue_name }}
|
||||
{%- endif -%}
|
||||
{%- endcapture -%}
|
||||
{{ artistName }}
|
||||
{% if venue %} at {{ venue }}{% endif %}
|
||||
{%- else -%}
|
||||
<a href="{{ item.url | prepend: globals.url }}">{{ item.title }}</a>
|
||||
{%- if item.type == "link" and item.author -%}
|
||||
<span> via </span>
|
||||
{%- if item.author.url -%}
|
||||
<a href="{{ item.author.url }}">{{ item.author.name }}</a>
|
||||
{%- else -%}
|
||||
{{ item.author.name }}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
</h3>
|
||||
{% render "blocks/tags.liquid",
|
||||
tags:item.tags
|
||||
{%- for item in items -%}
|
||||
<article class="{{ item.type }}">
|
||||
<aside>
|
||||
{%- if item.featured -%}
|
||||
{% tablericon "star" %}
|
||||
{%- endif -%}
|
||||
<time datetime="{{ item.content_date }}">
|
||||
{{ item.content_date | date:"%B %e, %Y" }}
|
||||
</time>
|
||||
• {{ item.label }}
|
||||
{%- if item.notes -%}
|
||||
{% assign notes = item.notes | markdown %}
|
||||
{% render "blocks/dialog.liquid",
|
||||
icon:"info-circle",
|
||||
label:"View info about this concert"
|
||||
dynamic:"optimized_concerts",
|
||||
markdown:"concert_notes",
|
||||
id:item.id
|
||||
%}
|
||||
</article>
|
||||
{%- endfor -%}
|
||||
{%- endif -%}
|
||||
</aside>
|
||||
<h3>
|
||||
{%- if item.type == "concerts" -%}
|
||||
{%- capture artistName -%}
|
||||
{%- if item.artist_url -%}
|
||||
<a href="{{ item.artist_url }}">{{ item.title | split: ' at ' | first }}</a>
|
||||
{%- else -%}
|
||||
{{ item.title | split: ' at ' | first }}
|
||||
{%- endif -%}
|
||||
{%- endcapture -%}
|
||||
{%- capture venue -%}
|
||||
{%- if item.venue_lat and item.venue_lon -%}
|
||||
<a href="https://www.openstreetmap.org/?mlat={{ item.venue_lat }}&mlon={{ item.venue_lon }}#map=18/{{ item.venue_lat }}/{{ item.venue_lon }}">{{ item.venue_name }}</a>
|
||||
{%- else -%}
|
||||
{{ item.venue_name }}
|
||||
{%- endif -%}
|
||||
{%- endcapture -%}
|
||||
{{ artistName }}
|
||||
{% if venue %} at {{ venue }}{% endif %}
|
||||
{%- else -%}
|
||||
<a href="{{ item.url | prepend: globals.url }}">{{ item.title }}</a>
|
||||
{%- if item.type == "link" and item.author -%}
|
||||
<span> via </span>
|
||||
{%- if item.author.url -%}
|
||||
<a href="{{ item.author.url }}">{{ item.author.name }}</a>
|
||||
{%- else -%}
|
||||
{{ item.author.name }}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
</h3>
|
||||
{% render "blocks/tags.liquid",
|
||||
tags:item.tags
|
||||
%}
|
||||
</article>
|
||||
{%- endfor -%}
|
||||
|
|
|
@ -1,22 +1,15 @@
|
|||
<article>
|
||||
<h2>
|
||||
{% tablericon "activity" %}
|
||||
Recent media
|
||||
</h2>
|
||||
<p>My top <a href="/music/this-week/artists/" class="music">artists</a>, <a href="/music/this-week/albums/" class="music">albums</a>, recently <a href="/books/years/{{ "now" | date: "%Y" }}/" class="books">read books</a>, watched <a href="/watching/recent/movies/" class="tv">movies</a> and <a href="/watching/recent/shows/" class="tv">shows</a>. A living snapshot, if you will.</p>
|
||||
{% render "media/grid.liquid",
|
||||
globals:globals,
|
||||
data:media.recentMusic,
|
||||
loading:"eager"
|
||||
%}
|
||||
{% render "media/grid.liquid",
|
||||
globals:globals,
|
||||
data:media.recentWatchedRead,
|
||||
shape:"vertical",
|
||||
loading:"eager"
|
||||
%}
|
||||
{% render "blocks/banners/rss.liquid",
|
||||
url:"/feeds",
|
||||
text:"Subscribe to my movies, books, links or activity feed(s)"
|
||||
%}
|
||||
</article>
|
||||
{% render "media/grid.liquid",
|
||||
globals:globals,
|
||||
data:media.recentMusic,
|
||||
loading:"eager"
|
||||
%}
|
||||
{% render "media/grid.liquid",
|
||||
globals:globals,
|
||||
data:media.recentWatchedRead,
|
||||
shape:"vertical",
|
||||
loading:"eager"
|
||||
%}
|
||||
{% render "blocks/banners/rss.liquid",
|
||||
url:"/feeds",
|
||||
text:"Subscribe to my posts, movies, books, links or activity feed(s)"
|
||||
%}
|
||||
|
|
|
@ -6,10 +6,16 @@ updated: "now"
|
|||
intro:globals.intro,
|
||||
nowPlaying:nowPlaying.content
|
||||
%}
|
||||
{% render "home/recent-media.liquid"
|
||||
media:recentMedia,
|
||||
globals:globals
|
||||
%}
|
||||
{% render "home/recent-activity.liquid"
|
||||
items:recentActivity
|
||||
%}
|
||||
<article>
|
||||
<h2>
|
||||
{% tablericon "activity" %}
|
||||
Recent activity
|
||||
</h2>
|
||||
{% render "home/recent-media.liquid"
|
||||
media:recentMedia,
|
||||
globals:globals
|
||||
%}
|
||||
{% render "home/recent-activity.liquid"
|
||||
items:recentActivity
|
||||
%}
|
||||
</article>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue