{% extends "accounts/base_site.html" %}
{% load i18n admin_urls static admin_modify %}

{% block extrahead %}{{ block.super }}
  <script src="{% url 'accounts:jsi18n' %}"></script>
  <script src="{% static 'admin/js/core.js' %}"></script>
  <script src="{% static 'admin/js/calendar.js' %}"></script>
  <script src="{% static 'admin/js/admin/DateTimeShortcuts.js' %}"></script>
  {{ media }}
{% endblock %}

{% block coltype %}colM{% endblock %}

{% block bodyclass %}{{ block.super }} app-{{ opts.app_label }} model-{{ opts.model_name }} change-form{% endblock %}

{% block nav-breadcrumbs %}
  <nav aria-label="{% translate 'Breadcrumbs' %}">
    <div class="breadcrumbs">
      <a href="{% url 'accounts:home' %}">{% translate 'Home' %}</a>
      &rsaquo; {% translate 'Profile' %} &rsaquo; {{ user }}
    </div>
  </nav>
{% endblock %}

{% block content %}
  <div id="content-main">
    <form
        {% if has_file_field %}enctype="multipart/form-data" {% endif %}{% if form_url %}action="{{ form_url }}" {% endif %}method="post"
        id="{{ opts.model_name }}_form" novalidate>
      {% csrf_token %}
      <div>
        {% if errors %}
          <p class="errornote">
            {% blocktranslate count counter=errors|length %}Please correct the error below.{% plural %}Please correct
              the errors below.{% endblocktranslate %}
          </p>
          {{ form.non_field_errors }}
        {% endif %}
        {% block field_sets %}
          {% for fieldset in fieldsets %}
            {% include "accounts/includes/fieldset.html" with heading_level=2 id_suffix=forloop.counter0 %}
          {% endfor %}
        {% endblock %}
        <div class="submit-row">
          <input type="submit" value="{% translate 'Save' %}" class="default" name="_save">
          <input type="submit" value="{% translate 'Save and continue editing' %}" name="_continue">
        </div>
      </div>
    </form>
  </div>
{% endblock %}