Add introduction text to the daily email archive

...page
This commit is contained in:
Oliver Davies 2024-03-13 23:16:05 +00:00
parent c473a2c188
commit 52c1bfd148
2 changed files with 12 additions and 3 deletions

View file

@ -1,3 +1,8 @@
{% macro yearsExperience() %} {# Return a rounded count of daily emails I've sent (e.g. the actual number is 449, return 440+). #}
{{- today|date('Y') - 2007 -}} {% macro dailiesCount(dailies) %}
{{- dailies|length|round(-1, 'floor') -}}+
{% endmacro %}
{% macro yearsExperience() %}
{{- today|date('Y') - 2007 -}}
{% endmacro %} {% endmacro %}

View file

@ -9,7 +9,11 @@ use:
--- ---
{% block content %} {% block content %}
<div class="space-y-16"> {% import 'macros' as macros %}
<p>This is an archive of the {{ macros.dailiesCount(data.daily_emails) }} email messages I have sent to <a href="/daily">my daily mailing list</a> since the 12th of August, 2022. Enjoy!</p>
<div class="mt-6 space-y-16">
<div> <div>
<ul> <ul>
{% for email in page.pagination.items %} {% for email in page.pagination.items %}