Skip to content

Commit

Permalink
Thousands separators for large numbers on Area page
Browse files Browse the repository at this point in the history
  • Loading branch information
zarino authored and struan committed Apr 22, 2024
1 parent 3b1bf45 commit eefd67f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions hub/templates/hub/area.html
Original file line number Diff line number Diff line change
Expand Up @@ -495,9 +495,9 @@ <h3 class="h5">{{ dataset.label }}</h3>
<span>{{ dataset.data.value.link_text|safe }}</span>
</a>
{% elif dataset.data_type == "integer" %}
<p class="card-text mb-0 display-6 lh-1 text-primary">{{ dataset.data.value }}</p>
<p class="card-text mb-0 display-6 lh-1 text-primary">{{ dataset.data.value|intcomma }}</p>
{% if data.data.average %}
<p class="card-text mt-2 text-muted">{{dataset.data.average|floatformat }} national average</p>
<p class="card-text mt-2 text-muted">{{dataset.data.average|intcomma }} national average</p>
{% endif %}
{% elif dataset.is_range and dataset.data|length > 0 %}
<table class="table mb-0 js-chart" data-chart-type="bar" data-chart-direction="y">
Expand Down Expand Up @@ -585,7 +585,7 @@ <h3 class="h5">{{ dataset.label }}</h3>
<p class="card-text mt-2 text-muted">{{dataset.data.average|floatformat }}% national average</p>
{% elif dataset.data_type == "integer" %}
{% if dataset.related_category %}
<p class="card-text mb-3 display-6 lh-1 text-primary">{{ dataset.data.value }}</p>
<p class="card-text mb-3 display-6 lh-1 text-primary">{{ dataset.data.value|intcomma }}</p>
<ul class="tag-cloud">
{% if dataset.related_category.subcategory == "groups" %}
{% for data in dataset.related_category.data.value %}
Expand All @@ -606,8 +606,8 @@ <h3 class="h5">{{ dataset.label }}</h3>
{% endif %}
</ul>
{% else %}
<p class="card-text mb-0 display-6 lh-1 text-primary">{{ dataset.data.value }}</p>
<p class="card-text mt-2 text-muted">{{dataset.data.average|floatformat }} national average</p>
<p class="card-text mb-0 display-6 lh-1 text-primary">{{ dataset.data.value|intcomma }}</p>
<p class="card-text mt-2 text-muted">{{dataset.data.average|intcomma }} national average</p>
{% endif %}
{% elif dataset.is_range %}
<table class="table mb-0">
Expand Down

0 comments on commit eefd67f

Please sign in to comment.