analytics/lib/plausible_web/templates/stats/countries.html.eex
2019-09-02 12:29:19 +01:00

18 lines
674 B
Elixir

<header class="modal__header">
<h1>Top Countries</h1>
<button class="modal__close" aria-label="Close modal" data-micromodal-close></button>
</header>
<div class="text-grey-darker text-lg ml-1 mt-1">by visitors</div>
<div class="my-4 border-b border-grey-light"></div>
<main class="modal__content">
<div class="mt-8">
<%= for {country, count} <- @countries do %>
<div class="flex items-center justify-between my-2">
<span><%= Plausible.Stats.CountryName.from_iso3166(country) %></span>
<span title="<%= count %>"><%= large_number_format(count) %></span>
</div>
<%= bar(count, @countries, :indigo) %>
<% end %>
</div>
</main>