Hide Tag Bar If There Are No Tags

This commit is contained in:
seiichiro 2022-02-08 20:46:31 +01:00
parent 220d338996
commit e6459b8d70
2 changed files with 10 additions and 2 deletions

View file

@ -139,6 +139,10 @@ body {
grid-template-rows: repeat(2, 1fr); grid-template-rows: repeat(2, 1fr);
} }
.content-single.notags {
bottom: 0 !important;
}
.content-single .single-image { .content-single .single-image {
grid-column: 1 / 4; grid-column: 1 / 4;
grid-row: 1 / 3; grid-row: 1 / 3;

View file

@ -5,7 +5,11 @@
{% block content %} {% block content %}
<div class="container"> <div class="container">
{% if(!empty($tags)): %}
<div class="content-single"> <div class="content-single">
{% else: %}
<div class="content-single notags">
{% endif %}
<div class="single-image"> <div class="single-image">
<img src="{{ $imageurl }}" title="{{ $page }}/{{ $last_page }}" /> <img src="{{ $imageurl }}" title="{{ $page }}/{{ $last_page }}" />
</div> </div>
@ -23,12 +27,12 @@
</a> </a>
{% endif %} {% endif %}
</div> </div>
<div class="page-footer">
{% if(!empty($tags)): %} {% if(!empty($tags)): %}
<div class="page-footer">
{% foreach($tags as $tag): %} {% foreach($tags as $tag): %}
<a href="/index.php?d={{ $dir }}&so={{ $sort }}&s={{ $gallery_slice }}&f={{{ $tag }}}"><span class="tag">{{ $tag }}</span></a> <a href="/index.php?d={{ $dir }}&so={{ $sort }}&s={{ $gallery_slice }}&f={{{ $tag }}}"><span class="tag">{{ $tag }}</span></a>
{% endforeach %} {% endforeach %}
</div>
{% endif %} {% endif %}
</div> </div>
</div>
{% endblock %} {% endblock %}