{% extends "deliver_grant_funding/grant_base.html" %}
{% from "govuk_frontend_jinja/components/back-link/macro.html" import govukBackLink %}

{% set page_title = "Add section" %}
{% set type_constants = collection.type.constants %}
{% set active_item_identifier = type_constants.active_nav %}

{% block beforeContent %}
  {{
    govukBackLink({
      "text": "Back",
      "href": back_link
    })
  }}
{% endblock %}

{% block content %}
  <div class="govuk-grid-row">
    <div class="govuk-grid-column-two-thirds">
      <span class="govuk-caption-l">{{ grant.name }}</span>
      <h1 class="govuk-heading-l">What is the name of the section?</h1>
      <p class="govuk-body">Use sections to group related questions together. This helps the person completing the form to focus on one topic or ‘section’ at a time.</p>

      {# TODO/NOTE FOR CONTENT: SHOULD WE LIST THE EXISTING SECTION NAMES HERE? #}

      <form method="post" novalidate>
        {{ form.csrf_token }}
        {{ form.title(params={"label": {"classes": "govuk-visually-hidden"} }) }}

        <div class="govuk-button-group">
          {{ form.submit }}
          <a class="govuk-link govuk-link--no-visited-state" href="{{ back_link }}">Cancel</a>
        </div>
      </form>
    </div>
  </div>
{% endblock content %}
