{% extends "admin/base_site.html" %}

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


{% block breadcrumb_items %}
  <li class="breadcrumb-item active" aria-current="page">
    {{ _("Password reset confirmation") }}
  </li>
{% endblock breadcrumb_items %}


{% block content_title %}
  <h1>
    {{ title }}
  </h1>
{% endblock %}


{% block content %}
  {% if validlink %}
    <form class="paper-form paper-form--hook" method="post" novalidate>
      {% csrf_token %}

      {% block form_top %}{% endblock %}

      <fieldset class="paper-card paper-card--info card mb-3">
        <p class="card-header">
          {{ _("Please enter your new password twice so we can verify you typed it in correctly.") }}
        </p>
        <div class="card-body p-0">
          {% include 'paper_admin/includes/admin_field.html' with field=form.new_password1 %}
          {% include 'paper_admin/includes/admin_field.html' with field=form.new_password2 %}
        </div>
      </fieldset>

      <button type="submit" class="btn btn-success">
        {{ _("Change my password") }}
      </button>
    </form>
  {% else %}
    <p class="paper-message paper-message--error">
      {{ _("The password reset link was invalid, possibly because it has already been used.  Please request a new password reset.") }}
    </p>
  {% endif %}
{% endblock %}
