mirror of
https://github.com/minetest/contentdb.git
synced 2025-01-09 14:37:36 +01:00
Stats: Make date range dropdown blue when active
This commit is contained in:
parent
2596253535
commit
cb352fad47
@ -30,9 +30,9 @@
|
||||
{% endmacro %}
|
||||
|
||||
|
||||
{% macro render_daterange_selector(options) %}
|
||||
<nav class="dropdown d-inline-block">
|
||||
<button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownDateRange" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
{% macro render_daterange_selector(options, is_active) %}
|
||||
<nav class="dropdown d-inline-block mr-2">
|
||||
<button class="btn {% if is_active %}btn-primary{% else %}btn-secondary{% endif %} dropdown-toggle" type="button" id="dropdownDateRange" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
{{ _("Date range...") }}
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="dropdownDateRange">
|
||||
|
@ -17,7 +17,7 @@
|
||||
<i class="fas fa-download mr-1"></i>
|
||||
{{ _("Download (.csv)") }}
|
||||
</a>
|
||||
{{ render_daterange_selector(options) }}
|
||||
{{ render_daterange_selector(options, start or end) }}
|
||||
{{ render_package_selector(package.author, package=package) }}
|
||||
</div>
|
||||
<h2 class="mt-0">{{ _("Statistics") }}</h2>
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
{% block content %}
|
||||
<div class="float-right">
|
||||
{{ render_daterange_selector(options) }}
|
||||
{{ render_daterange_selector(options, start or end) }}
|
||||
{{ render_package_selector(user, package=None) }}
|
||||
</div>
|
||||
<h2 class="mt-0">{{ self.title() }}</h2>
|
||||
|
Loading…
Reference in New Issue
Block a user