## -*- coding: utf-8 -*-
<%inherit file="list_post.tmpl"/>

<%block name="extra_head">
    ${parent.extra_head()}
    %if len(translations) > 1 and generate_rss:
        %for language in translations:
            <link rel="alternate" type="application/rss+xml" type="application/rss+xml" title="RSS for ${kind} ${tag} (${language})" href="${_link(kind + "_rss", tag, language)}">
        %endfor
    %elif generate_rss:
        <link rel="alternate" type="application/rss+xml" type="application/rss+xml" title="RSS for ${kind} ${tag}" href="${_link(kind + "_rss", tag)}">
    %endif
</%block>


<%block name="content">
<article class="tagpage">
    <header>
        <h1>${title}</h1>
        %if description:
        <p>${description}</p>
        %endif
        <div class="metadata">
            %if len(translations) > 1 and generate_rss:
                %for language in translations:
                <p class="feedlink">
                    <a href="${_link(kind + "_rss", tag, language)}" hreflang="${language}" type="application/rss+xml">${messages('RSS feed', language)} (${language})</a>&nbsp;
                </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><a href="${post.permalink()}" class="listtitle">${post.title()}</a> <time class="listdate" datetime="${post.date.isoformat()}" title="${post.formatted_date(date_format)}">${post.formatted_date(date_format)}</time></li>
    % endfor
    </ul>
    %endif
</article>
</%block>
