1
0
Fork 0
forked from github/pelican
pelican-theme/templates/archives.html

28 lines
1.1 KiB
HTML
Raw Normal View History

{% extends "base.html" %}
2018-06-13 00:20:55 +00:00
2025-07-08 10:51:34 +02:00
{% block title %}Blog archive - {{ SITENAME|striptags }}{% endblock %}
2018-06-13 00:20:55 +00:00
{% block content %}
2024-12-19 09:56:25 +01:00
<div class="md:text-base lg:text-lg">
2025-07-08 10:51:34 +02:00
<h1 class="text-3xl md:text-5xl">Blog post archive</h1>
<ul class="hyphens-auto list-outside list-disc">
{% for article in dates %}
{% set year = article.date.strftime('%Y') %}
{% if loop.first %}
<h2 class="text-2xl md:text-3xl mt-6 mb-2" id="{{year }}"><a href="#{{year}}">{{ year }}</a></h2>
{% else %}
{% set prevyear = loop.previtem.date.strftime('%Y') %}
{% if prevyear != year %}
<h2 class="text-2xl md:text-3xl mt-6 mb-2" id="{{year }}"><a href="#{{year}}">{{ year }}</a></h2>
{% endif %}
{% endif %}
{% set month = article.date.strftime('%m') %}
{% set day = article.date.strftime('%d') %}
<li>{{ article.locale_date }}: <a href="{{ SITEURL }}/{{ article.url }}#content">{{ article.title }}</a></li>
{%if article.subtitle %}
{{ article.subtitle }}
{% endif %}
{% endfor %}
</ul>
2024-12-19 09:56:25 +01:00
</div>
{% endblock %}