Add cross-language links in the index template.

This commit is contained in:
Julien Palard 2023-01-25 16:07:24 +01:00
parent d9c1fd07ab
commit 42624e9e48
No known key found for this signature in database
GPG key ID: 0EFC1AC1006886F8
3 changed files with 24 additions and 9 deletions

View file

@ -12,6 +12,17 @@
</script>
{% endif %}
<header>
{% if extra_siteurls %}
<div class="translations">
<a class="active" href="{{ articles_page.url }}">{{ DEFAULT_LANG }}</a>
{% for lang, url in extra_siteurls.items() %}
<a href="{{ url }}/{{ articles_page.url }}">{{ lang }}</a>
{% endfor %}
</div>
{% endif %}
</header>
{% for article in articles_page.object_list %}
<article>
<header>