{% extends "base.html" %}
{% block content %}
<div class="profiles">

    {# include template "patterns/basics/headings/sp_variations/heading.html" #}
      {% trans "Let us know your birthday to get access to exclusive content." as headingtext %}
      {% with type="component" htmltag="h1" title=headingtext  %}
        <div class="heading heading__{{type}} {{extraclass}}">
          <{{htmltag}}>{{title}}</{{htmltag}}>
        </div>
      {% endwith %}
    {# end include template #}

    <form method="post" id="frmProfileEdit" action="{{EDIT_PROFILE_URL}}" class="profiles__form" novalidate>
    {% csrf_token %}
        {{ form.non_field_errors }}
        {% if settings.profiles.UserProfilesSettings.activate_display_name %}
          <fieldset>
              <div class="input-group{% if form.alias.errors %} input-error{% endif %}">
                  <label>{% trans "Display name:" %}</label>
                  {{ form.alias }}
                  {{ form.alias.errors }}
              </div>
              <p class="helptext">
                  {% trans "Please do not use your real name, phone number or email address as it's unsafe." %}
              </p>
          </fieldset>
        {% endif %}
        {% if settings.profiles.UserProfilesSettings.activate_dob %}
          <fieldset>
              <div class="input-group">
                  <label>{% trans "Date of birth:" %}</label>
                  {{ form.date_of_birth }}
              </div>
          </fieldset>
        {% endif %}

        {% if settings.profiles.UserProfilesSettings.activate_gender %}
          <fieldset>
              <div class="input-group{% if form.gender.errors %} input-error{% endif %}">
                  <label>{% trans "Gender:" %}</label>
                  {{ form.gender }}
                  {{ form.gender.errors }}
              </div>
          </fieldset>
        {% endif %}

        {% if settings.profiles.UserProfilesSettings.activate_education_level %}
            <fieldset>
            <div class="input-group{% if form.education_level.errors %} input-error{% endif %}">
                <label>{% trans "Update your Education Level:" %}</label>
                {{ form.education_level }}
                {{ form.education_level.errors}}
            </div>
            <p class="helptext">{% trans "Only you will see this." %}</p>
        </fieldset>
        {% endif %}
        <button type="submit" class="call-to-action__button call-to-action__button--primary">{% trans "Update profile" %}</button>
    </form>
    <a href="{{VIEW_PROFILE_URL}}" class="call-to-action__nav-item-text call-to-action__nav-item-text--left">Back to profile</a>
</div>
{% endblock %}
