diff options
| author | soaos <soaos@soaos.dev> | 2025-11-25 08:30:53 -0500 |
|---|---|---|
| committer | soaos <soaos@soaos.dev> | 2025-11-25 08:30:53 -0500 |
| commit | 27e2bc6928666ced9a402f589e56e8fbc9f78f81 (patch) | |
| tree | b6a024b530b43651884f4863193bb13051a977da /templates/blog.html | |
| parent | 53bbac67cfc300f86d8c836e5f6ce7be1afd7b0e (diff) | |
Album tree view on about page
Diffstat (limited to 'templates/blog.html')
| -rw-r--r-- | templates/blog.html | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/templates/blog.html b/templates/blog.html index f659571..ff44e08 100644 --- a/templates/blog.html +++ b/templates/blog.html @@ -15,18 +15,16 @@ <h2>Latest Posts</h2> <div class="sunken-panel"> <ul class="tree-view" style="height: 8rem; overflow-y: scroll"> - {% set current_year = now() | date(format="%Y") | int %} {% for i in - range(start=0, end=current_year - 2024) %} + {% for year, posts in section.pages | group_by(attribute="year") %} <li> <details open> - <summary><b>{{current_year - i}}</b></summary> + <summary><b>{{ year }}</b></summary> <ul> - {% for post in section.pages %} {% if post.year == current_year - - i %} + {% for post in posts %} <li> <a href="{{post.permalink}}">{{post.title}}</a> - {{post.date}} </li> - {% endif %} {% endfor %} + {% endfor %} </ul> </details> </li> |
