{# -*- coding: utf-8 -*-

  This file is part of Invenio.
  Copyright (C) 2015-2020 CERN.

  Invenio is free software; you can redistribute it and/or modify it
  under the terms of the MIT License; see LICENSE file for more details.
#}

{%- extends config.OAUTHCLIENT_SETTINGS_TEMPLATE %}

{% from "invenio_oauthclient/_macros.html" import form_errors, render_field %}

{% block page_body %}
<div class="ui centered grid">
  <div class="row">
  {%- block signup_panel %}
  <div>
    {%- block signup_header %}
      <div class="ui center aligned header">
        <div class="content">
          <div class="ui hidden divider"></div>
          {%- block signup_app_icon %}
            {% if app_icon -%}
            <i class="{{app_icon}}"></i>
            {% endif %}
          {%- endblock %}
          <h3 class="ui header">
            {{ _('Sign-up with %(title)s!', title=app_title) }}
          </h3>
          <h5 class="ui grey header">
            {{ _('Fill in your details to complete your registration. You only have to do this once.') }}
          </h5>
          <div class="ui hidden divider"></div>
        </div>
    </div>
    {% endblock %}
    {%- block signup_form %}
    <form class="ui form" name="edit" method="post" role="form">
      {%- for field in form %}
        {{ render_field(field) }}
      {%- endfor %}
      <div class="ui hidden divider"></div>
      <button type="submit" class="ui fluid large signup submit button">
        <i class="ui edit outline icon"></i>{{ _('Complete registration') }}
      </button>
    </form>
    {%- endblock %}
  </div>
  {%- endblock %}
</div>
</div>
{% endblock %}
