feat: eleventy transform for images

This commit is contained in:
Cory Dransfeldt 2024-02-13 15:28:28 -08:00
parent 243b1103e4
commit 7e1597b36a
No known key found for this signature in database
36 changed files with 179 additions and 1262 deletions

View file

@ -8,13 +8,13 @@ layout: default
{% endcapture %}
<style>{{ css }}</style>
{{ content }}
{% render "partials/now/media-grid.liquid", data:artists, icon: "microphone-2", title: "Artists", shape: "square", count: 8, loading: 'eager', imageMaxWidth: 320 %}
{% render "partials/now/media-grid.liquid", data:albums, icon: "vinyl", title: "Albums", shape: "square", count: 8, imageMaxWidth: 320 %}
{% render "partials/now/media-grid.liquid", data:artists, icon: "microphone-2", title: "Artists", shape: "square", count: 8, loading: 'eager' %}
{% render "partials/now/media-grid.liquid", data:albums, icon: "vinyl", title: "Albums", shape: "square", count: 8 %}
{% render "partials/now/albumReleases.liquid", albumReleases:albumReleases %}
{% render "partials/now/media-grid.liquid", data:books, icon: "books", title: "Books", shape: "vertical", count: 6, imageMaxWidth: 320 %}
{% render "partials/now/media-grid.liquid", data:books, icon: "books", title: "Books", shape: "vertical", count: 6 %}
{% render "partials/now/links.liquid", links:links %}
{% render "partials/now/media-grid.liquid", data:movies, icon: "movie", title: "Movies", shape: "vertical", count: 6, imageMaxWidth: 320 %}
{% render "partials/now/media-grid.liquid", data:tv, icon: "device-tv", title: "TV", shape: "vertical", count: 6, imageMaxWidth: 320 %}
{% render "partials/now/media-grid.liquid", data:movies, icon: "movie", title: "Movies", shape: "vertical", count: 6 %}
{% render "partials/now/media-grid.liquid", data:tv, icon: "device-tv", title: "TV", shape: "vertical", count: 6 %}
<p class="now__explainer text-center">
This is a <a href="https://nownownow.com/about">now page</a>, and if you have your own site, <a href="https://nownownow.com/about">you should make one too</a>.
</p>

View file

@ -37,12 +37,7 @@
'lazy'
{%- endif -%}
{%- endcapture -%}
{% capture fallbackIcon %}{% tablericon icon alt %}{% endcapture %}
{% if imageMaxWidth %}
{% image item.image, alt, '', loadingStrategy, shape, fallbackIcon, imageMaxWidth %}
{% else %}
{% image item.image, alt, '', loadingStrategy, shape, fallbackIcon, 1248 %}
{% endif %}
<img src="{{ item.image }}" alt="{{ alt }}" loading="{{ loadingStrategy }}" />
</div>
</a>
{% endfor %}

View file

@ -1,6 +1,6 @@
<div class="webring__wrapper">
<div class="webring__centered flex--centered">
{% image './src/assets/img/webrings/theclaw.png', 'The Claw Webring' %}
<img src="/assets/img/webrings/theclaw.png" alt="The Claw Webring" />
</div>
<h3 class="text-center">The Claw Webring</h3>
<div class="webring__centered flex--centered">