{% extends "sveedocuments/board/subbase_pages.html" %}
{% load i18n autobreadcrumb %}

{% block board_content %}
    <h2>{% current_title_from_breadcrumbs %}</h2>
    
    {% include "sveedocuments/board/includes/page_form_subnav.html" with active_tab="history" %}
    
    <ul class="feed">
        <li class="revision-current">
            <p class="ago">{% blocktrans with since=page_instance.modified|timesince %}{{ since }} ago{% endblocktrans %}</p>
            <p class="details">{% blocktrans with author=page_instance.author.get_full_name %}<strong>Current version:</strong> by {{ author }}{% endblocktrans %}</p>
            <p class="comment"><em>{% if page_instance.comment %}{{ page_instance.comment }}{% else %}{% trans "Empty comment" %}{% endif %}</em></p>
        </li>

        {% for revision in last_revisions %}
        <li>
            <p class="ago">{% blocktrans with since=page_instance.created|timesince %}{{ since }} ago{% endblocktrans %}</p>
            <p class="details">{% blocktrans with version=revision.revision author=revision.author.get_full_name %}<strong>Version n°{{ version }}:</strong> by {{ author }}{% endblocktrans %}</p>
            <p class="comment{% if not revision.comment %} empty{% endif %}"><em>{% if revision.comment %}{{ revision.comment }}{% else %}{% trans "Empty comment" %}{% endif %}</em></p>
        </li>
        {% endfor %}
    </ul>

{% endblock %}
