{% extends "base.html" %}

{% block title %}{{ tag }} — {{ repo }}{% endblock %}

{% block breadcrumbs %}
<ul>
  <li><a href="/">{{ crate::hostname() }}</a></li>
  <li><a href="/{{ repo }}">{{ repo }}</a></li>
  <li><a href="/{{ repo }}/tags">tags</a></li>
  <li>{{ tag }}</li>
</ul>
{% endblock %}

{% block content %}
<h1>{{ tag }}</h1>

{% if tagger.is_some() || tag_date.is_some() %}
<dl class="tag-info">
  {% if let Some(tagger) = tagger %}
  <dt>tagger</dt><dd>{{ tagger }}</dd>
  {% endif %}
  {% if let Some(date) = tag_date %}
  <dt>tagged</dt><dd>{{ date }}</dd>
  {% endif %}
</dl>
{% endif %}

<dl class="tag-info">
  <dt>commit</dt><dd><a href="/{{ repo }}/commits/{{ commit_sha }}">{{ commit_sha }}</a></dd>
  <dt>author</dt><dd>{{ commit_author }}</dd>
  <dt>date</dt><dd>{{ commit_date }}</dd>
</dl>

<p class="tag-downloads">
  [<a href="/{{ repo }}/archive/tar.gz/{{ commit_sha }}">tar.gz</a>]
  [<a href="/{{ repo }}/archive/tar.xz/{{ commit_sha }}">tar.xz</a>]
  [<a href="/{{ repo }}/archive/zip/{{ commit_sha }}">zip</a>]
</p>

{% if let Some(message) = message %}
<pre class="tag-message">{{ message }}</pre>
{% endif %}
{% endblock %}
