diff options
Diffstat (limited to 'templates/food_archive.html')
-rw-r--r-- | templates/food_archive.html | 42 |
1 files changed, 32 insertions, 10 deletions
diff --git a/templates/food_archive.html b/templates/food_archive.html index b298815..e8dab8e 100644 --- a/templates/food_archive.html +++ b/templates/food_archive.html @@ -1,20 +1,42 @@ {% extends "base.html" %} {% block title %} +{% if lang == "ru" %} +Архив рецептов - Книга рецептов Ярослава +{% elif lang == "es" %} +Archivo del recetario - Recetario de Yaroslav +{% else %} Recipe archive - Yaroslav's recipe book +{% endif %} {% endblock %} {% block header %} -<h1>Yaroslav's recipe archive</h1> +<h1> + {% if lang == "ru" %} + Архив рецептов Ярослава + {% elif lang == "es" %} + Archivo del recetario de Yaroslav + {% else %} + Yaroslav's recipe archive + {% endif %} +</h1> {% endblock %} {% block content %} -{% set section = get_section(path="food/_index.md") %} +{% if lang != "en" %} +{% set section_path = "food/_index." ~ lang ~ ".md" %} +{% else %} +{% set section_path = "food/_index.md" %} +{% endif %} +{% set section = get_section(path=section_path) %} <div class="post-container"> - {% for year, posts in section.pages | group_by(attribute="year") %} - <h2>{{ year }}</h2> - <ul> - {% for post in posts %} - <li><span class="publish-date">{{ post.date | date }}</span> - <a href="{{ post.permalink }}">{{ post.title }}</a></li> - {% endfor %} - </ul> - {% endfor %} + {% for year, posts in section.pages | group_by(attribute="year") %} + <h2>{{ year }}</h2> + <ul> + {% for post in posts %} + <li> + <span class="publish-date">{{ post.date | date }}</span> - + <a href="{{ post.permalink }}">{{ post.title }}</a> + </li> + {% endfor %} + </ul> + {% endfor %} </div> {% endblock %} |