Merge pull request #1132 from alphagov/fix-single-template-usage

Don’t right align template stats for one template
This commit is contained in:
Chris Hill-Scott
2017-02-15 14:10:52 +00:00
committed by GitHub

View File

@@ -24,8 +24,8 @@
</span> </span>
</span> </span>
{% endcall %} {% endcall %}
{% call field(align='right') %} {% if template_statistics|length > 1 %}
{% if template_statistics|length > 1 %} {% call field(align='right') %}
<span id='{{item.template_id}}' class="spark-bar"> <span id='{{item.template_id}}' class="spark-bar">
<span style="width: {{ item.count / most_used_template_count * 100 }}%"> <span style="width: {{ item.count / most_used_template_count * 100 }}%">
{{ big_number( {{ big_number(
@@ -34,14 +34,16 @@
) }} ) }}
</span> </span>
</span> </span>
{% else %} {% endcall %}
{% else %}
{% call field() %}
<span id='{{item.template_id}}' class="heading-small"> <span id='{{item.template_id}}' class="heading-small">
{{ big_number( {{ big_number(
item.count, item.count,
smallest=True smallest=True
) }} ) }}
</span> </span>
{% endif %} {% endcall %}
{% endcall %} {% endif %}
{% endcall %} {% endcall %}
</div> </div>