{% load comments i18n %}
{% load url from future %}
<article id="entry-{{ object.pk }}" class="hentry{% if object.featured %} featured{% endif %}">
  {% block entry-header %}
  <header class="entry-header">
    {% block entry-title %}
    <h2 class="entry-title">
      <a href="{{ object.get_absolute_url }}" title="{{ object.title }}" rel="bookmark">
        {{ object.title }}
      </a>
    </h2>
    {% endblock %}
    {% block entry-info %}
    <p class="entry-info">
      {% with authors=object.authors.all %}
      {% if authors|length %}
      {% trans "Written by" %}
      {% for author in authors %}
      <span class="vcard author">
        <a href="{{ author.get_absolute_url }}" class="fn url{% if not author.get_full_name %} nickname{% endif %}" rel="author"
           title="{% blocktrans %}Show all {{ author }}'s entries{% endblocktrans %}">{{ author }}</a></span>{% if not forloop.last %}, {% endif %}
      {% endfor %}
      {% trans "on" %}
      {% else %}
      {% trans "Written on" %}
      {% endif %}
      {% endwith %}
      <time datetime="{{ object.creation_date|date:"c" }}" pubdate="pubdate">{{ object.creation_date|date:"DATE_FORMAT" }}</time>
      {% with categories=object.categories.all %}
      {% if categories|length %}
      {% trans "in" %}
      {% for category in categories %}
      <a href="{{ category.get_absolute_url }}"
         title="{% blocktrans %}Show all entries in {{ category }}{% endblocktrans %}"
         rel="tag category">{{ category }}</a>{% if not forloop.last %}, {% endif %}{% endfor %}{% endif %}.{% endwith %}
    </p>
    {% endblock %}
  </header>
  {% endblock %}

  {% block entry-body %}
  <div class="entry-body">
    {% block entry-image %}
    {% if object.image %}
    <div class="entry-image">
      <p>
        {% if continue_reading %}
        <a href="{{ object.get_absolute_url }}" title="{{ object.title }}" rel="bookmark">
          {% endif %}
          <img src="{{ object.image.url }}" alt="{{ object.title }}" class="thumbnail pull-left" style="margin-right: 15px;" />
          {% if continue_reading %}
        </a>
        {% endif %}
      </p>
    </div>
    {% endif %}
    {% endblock %}
    {% block entry-content %}
    <div class="entry-content">
      {{ object_content }}
    </div>
    {% endblock %}
    {% block continue-reading %}
    {% if continue_reading %}
    <p class="continue-reading">
      <a href="{{ object.get_absolute_url }}"
         title="{% blocktrans with object=object.title %}Continue reading {{ object }}{% endblocktrans %}"
         rel="bookmark" class="btn btn-primary">
        {% trans "Continue reading" %}
      </a>
    </p>
    {% endif %}
    {% endblock %}
  </div>
  {% endblock %}

  {% block entry-footer %}
  <footer class="entry-footer well">
    {% block entry-tags %}
    <p class="entry-tags">
      <i class="icon-tags"></i> <strong>{% trans "Tags" %}</strong> :
      {% for tag in object.tags_list %}
      <a href="{% url 'zinnia_tag_detail' tag %}"
         title="{% blocktrans %}Show all entries tagged by {{ tag }}{% endblocktrans %}"
         rel="tag">{{ tag }}</a>
      {% empty %}
      <span>{% trans "No tags" %}</span>
      {% endfor %}
    </p>
    {% endblock %}
    {% block entry-shorturl %}
    <p class="entry-shorturl">
      <i class="icon-bookmark"></i> <strong>{% trans "Short url" %}</strong> :
      <a href="{{ object.short_url }}"
         title="{% blocktrans with object=object.title %}Short URL to {{ object }}{% endblocktrans %}"
         rel="shortlink">
        {{ object.short_url }}
      </a>
    </p>
    {% endblock %}
    {% block entry-comments %}
    <p class="entry-comments">
      <i class="icon-comment"></i> <strong>{% trans "Discussions" %}</strong> :
      {% with comment_count=object.comment_count %}
      {% if comment_count %}
      <a href="{{ object.get_absolute_url }}#comments"
         title="{% blocktrans with object=object.title %}Comments on {{ object }}{% endblocktrans %}">
        {% blocktrans count comment_count=comment_count %}{{ comment_count }} comment{% plural %}{{ comment_count }} comments{% endblocktrans %}
      </a>
      {% else %}
      {% if object.comments_are_open %}
      {% trans "No comments yet." %}
      <a href="{{ object.get_absolute_url }}#comment-form"
         title="{% blocktrans with object=object.title %}Leave a comment on {{ object }}{% endblocktrans %}">
        {% trans "Be first to comment!" %}
      </a>
      {% else %}
      {% trans "Comments are closed." %}
      {% endif %}
      {% endif %}
      {% endwith %}
      {% with pingback_count=object.pingback_count %}
      {% if pingback_count %}
      , <a href="{{ object.get_absolute_url }}#pingbacks" title="{% blocktrans with object=object.title %}Pingbacks on {{ object }}{% endblocktrans %}">
        {% blocktrans count pingback_count=pingback_count %}{{ pingback_count }} pingback{% plural %}{{ pingback_count }} pingbacks{% endblocktrans %}
      </a>
      {% endif %}
      {% endwith %}
      {% with trackback_count=object.trackback_count %}
      {% if trackback_count %}
      , <a href="{{ object.get_absolute_url }}#trackbacks" title="{% blocktrans with object=object.title %}Trackbacks on {{ object }}{% endblocktrans %}">
        {% blocktrans count trackback_count=trackback_count %}{{ trackback_count }} trackback{% plural %}{{ trackback_count }} trackbacks{% endblocktrans %}
      </a>
      {% endif %}
      {% endwith %}
    </p>
    {% endblock %}
  </footer>
  {% endblock %}
</article>
