summaryrefslogtreecommitdiff
path: root/templates/taxonomy_list.html
diff options
context:
space:
mode:
Diffstat (limited to 'templates/taxonomy_list.html')
-rw-r--r--templates/taxonomy_list.html32
1 files changed, 26 insertions, 6 deletions
diff --git a/templates/taxonomy_list.html b/templates/taxonomy_list.html
index 9182c43..222711c 100644
--- a/templates/taxonomy_list.html
+++ b/templates/taxonomy_list.html
@@ -1,12 +1,32 @@
{% extends "base.html" %}
{% block content %}
-<section class="posts">
- <h1 class="post-title">Tags</h1>
- <section class="terms">
+<section class="archive">
{% for term in terms %}
- <div class="post-content"><a href="{{ term.permalink }}" class="post-title-link">#{{ term.name }}</a></div>
+ <ul class="post-archive">
+ {# Group the posts by year #}
+ {% set map = term.pages | group_by(attribute="year") %}
+ {% set_global years = [] %}
+ {# Convert the years map to an array (since maps do not have determined order) #}
+ {% for year, ignored in map %}
+ {% set_global years = years | concat(with=year) %}
+ {% endfor %}
+
+ <div class="term-name"><a href="{{ term.permalink }}" class="term-name">#{{ term.name }}</a></div>
+
+ {% for year in years | sort | reverse %}
+ <div class="years">
+ {% set posts = map[year] %}
+ <div class="year">{{ year }}</div>
+ {% for post in posts %}
+ <li class="post-item">
+ <span class="post-date">{{ post.date | date(format="%m/%d") }}</span>
+ <a href="{{ post.permalink }}" class="post-title">{{ post.title }}</a>
+ </li>
+ {% endfor %}
+ </div>
+ {% endfor %}
+ </ul>
{% endfor %}
- </section>
</section>
-{% endblock %}
+{% endblock %} \ No newline at end of file