-
Notifications
You must be signed in to change notification settings - Fork 446
/
tag.tmpl
51 lines (48 loc) · 2.02 KB
/
tag.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{# -*- coding: utf-8 -*- #}
{% extends 'list_post.tmpl' %}
{% block extra_head %}
{{ super() }}
{% if translations|length > 1 and generate_rss %}
{% for language in translations|sort %}
<link rel="alternate" type="application/rss+xml" title="RSS for {{ kind }} {{ tag|e }} ({{ language }})" href="{{ _link(kind + "_rss", tag, language) }}">
{% endfor %}
{% elif generate_rss %}
<link rel="alternate" type="application/rss+xml" title="RSS for {{ kind }} {{ tag|e }}" href="{{ _link(kind + "_rss", tag) }}">
{% endif %}
{% endblock %}
{% block content %}
<article class="tagpage">
<header>
<h1>{{ title|e }}</h1>
{% if description %}
<p>{{ description|e }}</p>
{% endif %}
{% if subcategories %}
{{ messages('Subcategories:') }}
<ul>
{% for name, link in subcategories %}
<li><a href="{{ link }}">{{ name|e }}</a></li>
{% endfor %}
</ul>
{% endif %}
<div class="metadata">
{% if translations|length > 1 and generate_rss %}
{% for language in translations|sort %}
<p class="feedlink">
<a href="{{ _link(kind + "_rss", tag, language) }}" hreflang="{{ language }}" type="application/rss+xml">{{ messages('RSS feed', language) }} ({{ language }})</a>
</p>
{% endfor %}
{% elif generate_rss %}
<p class="feedlink"><a href="{{ _link(kind + "_rss", tag) }}" type="application/rss+xml">{{ messages('RSS feed') }}</a></p>
{% endif %}
</div>
</header>
{% if posts %}
<ul class="postlist">
{% for post in posts %}
<li><time class="listdate" datetime="{{ post.formatted_date('webiso') }}" title="{{ post.formatted_date(date_format)|e }}">{{ post.formatted_date(date_format)|e }}</time><a href="{{ post.permalink() }}" class="listtitle">{{ post.title()|e }}<a></li>
{% endfor %}
</ul>
{% endif %}
</article>
{% endblock %}