{% extends "wiki/article.html" %}
{% load wiki_tags i18n humanize wiki_thumbnails %}
{% load url from future %}

{% block wiki_pagetitle %}{% trans "Replace image" %}: {{ image }}{% endblock %}

{% block wiki_contents_tab %}
  {% thumbnail image.current_revision.imagerevision.image "250x250" as thumb %}
    <p class="thumbnail pull-right">
      <img src="{{ thumb.url }}" alt="{{ revision.get_filename }}" />
    </p>
  {% endthumbnail %}
  <p class="lead">
    {% trans "Choose an image file to replace current image." %}
  </p>
  <form method="POST" class="form-horizontal" enctype="multipart/form-data">
    {% wiki_form form %}
    <div class="form-group form-actions">
      <div class="col-lg-2"></div>
      <div class="col-lg-10">
        <a href="{% url 'wiki:images_index' path=urlpath.path article_id=article.id %}" class="btn btn-default">
          <span class="fa fa-arrow-left"></span>
          {% trans "Go back" %}
        </a>
        <button class="btn btn-primary">
          <span class="fa fa-upload"></span>
          {% trans "Upload replacement" %}
        </button>
      </div>
    </div>
  </form>
  
{% endblock %}

