<div class="details">
    <div class="heading">
      <span>Lanthipeptide predictions</span>
      {{help_tooltip(tooltip, "lanthi-body")}}
    </div>
  {% if not results %}
    <div class="details-text">
      Lanthipeptides - No core peptides found.
    </div>
  {% else %}
    {% for locus in results | sort %}
      <h4>Lanthipeptide(s) for {{locus}} - Putative {{results[locus][0].peptide_subclass}}</h4>
      <hr>
      <dl class="details-text">
        {% for motif in results[locus] %}
          <dt>
            <span class="serif">{{motif.get_name()}}</span> leader / core peptide
          </dt>
          <dd>
            {{ motif.leader }}
            -
            {% for aa in motif.core -%}
              {%- if aa == 'S' -%}
                <span class="dha">Dha</span>
              {%- elif aa == 'T' -%}
                <span class="dhb">Dhb</span>
              {%- elif aa == 'C' -%}
                <span class="cys">C</span>
              {%- else -%}
                {{ aa }}
              {%- endif -%}
          {% endfor -%}
        {% endfor %}
        </dd>
      </dl>
    {% endfor %}
    <div class="legend">
      <h4> Legend: </h4>
      <div>
        <span class="dha">Dha</span>: Didehydroalanine<br>
        <span class="dhb">Dhb</span>: Didehydrobutyrine<br>
      </div>
    </div>
  {% endif %}
</div>
