{% extends "content_template.html" %}
{% from "components/table.html" import mapping_table, row, text_field, edit_field, field with context %}
{% from "components/sub-navigation.html" import sub_navigation %}
{% from "components/service-link.html" import service_link %}

{% block per_page_title %}
  Guidance
{% endblock %}

{% block content_column_content %}

  <h1 class="font-body-2xl margin-bottom-3">Guidance</h1>

  <p>This guidance is for teams using Notify.gov to send text messages.</p>

  <p>It explains how to:</p>

  <ul class="list list-bullet">
    <li><a class="usa-link" href="#editandformat">edit and format messages</a></li>
    <li><a class="usa-link" href="#customization">add customization</a></li>
   <!-- <li><a class="usa-link" href="{{ url_for('.send_files_by_email') }}">send files by email</a></li> -->
  </ul>

  <h2 class="font-body-lg" id="#formatting">Edit and format messages</h2>

  <p>This section explains how to:</p>
  <ul class="list list-bullet">
    <li><a class="usa-link" href="#formatting">format your content</a></li>
    <li><a class="usa-link" href="#links">add links</a></li>
    <li><a class="usa-link" href="#personalised-content">personalize your content</a></li>
    <li><a class="usa-link" href="#optional-content">add optional content</a></li>
  </ul>

  <h3 class="font-body-lg" id="formatting">Format your content</h3>

  <p>You can see a list of formatting instructions on the edit template page:</p>

  <ol class="list list-number">
    <li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page.</li>
    <li>Add a new template or choose an existing template and select <b class="bold">Edit</b>.</li>
  </ol>

  <h3 class="font-body-lg" id="links">Add links</h3>

  <p>When composing a text message, write URLs in full and Notify will convert them into links for you.
  </p>

  <p>You cannot convert text into a link.
    <!-- Research shows that people like to check a URL looks genuine before clicking the link in an email. This is hard to do if the URL is hidden behind clickable link text.-->
  </p>

  <p>We do not recommend using a third-party link shortening service because:</p>

  <ul class="list list-bullet">
    <li>your users cannot see where the link will take them</li>
    <li>your link might stop working if there’s a service outage</li>
    <li>you can no longer control where the redirect goes</li>
  </ul>

  <h3 class="font-body-lg" id="personalised-content">Personalize your content</h3>

  <p>To personalize the content of your messages, add a placeholder to the template.</p>

  <p>Placeholders are filled in with details, like a name or reference number, each time you send a
    message.</p>

  <p>To add a placeholder to the template:</p>

  <ol class="list list-number">
    <li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page.</li>
    <li>Add a new template or choose an existing template and select <b class="bold">Edit</b>.</li>
    <li>Add a placeholder using double brackets. For example: Hello ((first&nbsp;name)), your reference is
      ((ref&nbsp;number)).</li>
    <li>Select <b class="bold">Save</b>.</li>
  </ol>

  <p>When you send a message you can either:</p>

  <ul class="list list-bullet">
    <li>manually fill in the placeholders yourself</li>
    <li>upload a list of personal details and let Notify do it for you</li>
  </ul>

  <p>If you upload a list, the column names need to match the placeholders in your template.</p>

  <h3 class="font-body-lg" id="optional-content">Add optional content</h3>

  <p>To add optional content to your messages:</p>

  <ol class="list list-number">
    <li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page.</li>
    <li>Add a new template or choose an existing template and select <b class="bold">Edit</b>.</li>
    <li>Use double brackets and ?? to define optional content. For example, if you only want to show something to people
      who are under 18: ((under18??Please get your application signed by a parent or guardian.))</li>
    <li>Select <b class="bold">Save</b>.</li>
  </ol>

  <p>For each person you send this message to, specify ‘yes’ or ‘no’ to show or hide this content. You
    can either:</p>

  <ul class="list list-bullet">
    <li>do this yourself</li>
    <li>upload a list of personal details and let Notify do it for you</li>
  </ul>

  <p>If you upload a list, the column names need to match the optional content in your template.</p>

  <h2 class="font-body-lg" id="customization">Message customization</h2>

  <h3 class="font-body-lg">Change the text message sender</h3>

  <p>The text message sender tells your users who the message is from.</p>

  <p>To change the text message sender from the default of ‘Notify.gov’:</p>

  <ol class="list list-number">
    <li>Go to the <b class="bold">Text message settings</b> section of the {{
      service_link(current_service, 'main.service_settings', 'settings') }} page.</li>
    <li>Select <b class="bold">Manage</b> on the <b class="bold">Text message
        senders</b> row.</li>
    <li>Select <b class="bold">Change</b> or <b class="bold">Add text message
        sender</b>.</li>
  </ol>

{% endblock %}
