Fixing Hidden-content feature for Upcoming contests (#77)

This commit is contained in:
Nguyễn Văn Thắng 2023-08-30 13:13:34 +08:00 committed by GitHub
parent 944d3a733e
commit 3cd95e9349
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 215 additions and 198 deletions

View file

@ -278,11 +278,11 @@
<br>
{% endif %}
<h3 class="toggle open contest-group-header">
<i class="fa fa-chevron-right fa-fw"></i>
{{ _('Ongoing Contests') }}
</h3>
{% if current_contests %}
<h3 class="toggle open contest-group-header">
<i class="fa fa-chevron-right fa-fw"></i>
{{ _('Ongoing Contests') }}
</h3>
<div id="ongoing-table" class="toggled">
<table class="contest-list table striped">
<thead>
@ -319,6 +319,11 @@
</table>
<br>
</div>
{% else %}
<div class="toggled">
<i> {{ _('There is no ongoing contest at this time.') }} </i>
<br>
</div>
{% endif %}
<h3 class="toggle open contest-group-header">
@ -354,15 +359,17 @@
</table>
</div>
{% else %}
<i>{{ _('There are no scheduled contests at this time.') }}</i>
<br>
<div class="toggled">
<i>{{ _('There is no scheduled contest at this time.') }}</i>
<br>
</div>
{% endif %}
<br>
<h3 class="toggle open contest-group-header">
{{ _('Past Contests') }}
</h3>
{% if past_contests %}
<h3 class="toggle open contest-group-header">
{{ _('Past Contests') }}
</h3>
{% if page_obj and page_obj.num_pages > 1 %}
<div style="margin-bottom: 4px;">
{% include "list-pages.html" %}
@ -411,6 +418,11 @@
{% include "list-pages.html" %}
</div>
{% endif %}
{% else %}
<div class="toggled">
<i> {{ _('There is no past contest.') }} </i>
<br>
</div>
{% endif %}
</div>
{% endblock %}