{% extends "admin/base_site.html" %}
{% load i18n admin_static filebrowser %}
{% loaf url from future %}

{% block extrastyle %}{{ block.super }}
  <link rel="stylesheet" type="text/css" href="{% static 'lemon/css/changeform.css' %}" />
  <link rel="stylesheet" type="text/css" href="{% static 'filebrowser/css/style.css' %}" />
{% endblock %}

{% block navigation %}
  <li class="second"><a href="{% url 'admin:index' %}">{% trans "Main Page" %}</a></li>
  <li class="last"><a href="{% url 'admin:filebrowser:browse' %}{% query_string 'p' %}">{% trans "Return To Folder" %}</a></li>
{% endblock %}

{% block content %}
  {% if form.errors %}
    <div class="errornote">
      <p>{% trans 'Please correct the following errors.' %}</p>
      <ul class="errorlist">{% for error in form.non_field_errors %}<li>{{ error }}</li>{% endfor %}</ul>
    </div>
  {% endif %}
  <h1>{{ title }}</h1>
  <form action="{% query_string 'p' %}" method="post">{% csrf_token %}
    <div id="tabs" class="tabs">
      <fieldset class="main">
        <div class="content">
          <div class="field clearfix last">
            <label class="required" for="id_dir_name">{{ form.dir_name.label }}</label>
            {{ form.dir_name }}
            {{ form.dir_name.errors }}
            <p class="help">
              {{ form.dir_name.help_text|safe }}
              <br />{% trans "The Name will be converted to lowercase. Spaces will be replaced with underscores." %}
            </p>
          </div>
        </div>
      </fieldset>
    </div>
    <div class="main-buttons">
      <input type="submit" value="{% trans 'Create' %}" class="default" />
    </div>
  </form>
{% endblock %}
