forked from rDrama/rDrama
1
0
Fork 0

exempt holes from the new banner code

master
Aevann 2023-05-06 01:08:12 +03:00
parent 6890c3f2b1
commit b7f1bc50a0
2 changed files with 22 additions and 6 deletions

View File

@ -6844,12 +6844,20 @@ div.markdown {
object-fit: contain; object-fit: contain;
} }
.site-banner, .site-banner-hole { .site-banner {
width: 100%; width: 100%;
height: 100%; height: 100%;
max-height: 30vh; max-height: 30vh;
object-fit: contain; object-fit: contain;
} }
.site-banner-hole {
width: 100%;
height: 100%;
max-height: min(42vh,30vw) !important;
object-fit: cover;
}
.banner-wrapper > div { .banner-wrapper > div {
position: relative; position: relative;
} }

View File

@ -45,13 +45,21 @@
{% endif %} {% endif %}
{% endif %} {% endif %}
<div class="banner-wrapper"> {% macro img_element() %}
<div style="padding: 0 0 12.2%"> <img data-nonce="{{g.nonce}}" data-onclick="{{expand|default('expandImage()')}}" class="{{class|default('site-banner')}}" alt="{{alt|default('site banner')}}" src="{{banner_url}}">
<div> {% endmacro %}
<img data-nonce="{{g.nonce}}" data-onclick="{{expand|default('expandImage()')}}" class="{{class|default('site-banner')}}" alt="{{alt|default('site banner')}}" src="{{banner_url}}">
{% if sub and sub.has_banners %}
{{img_element()}}
{% else %}
<div class="banner-wrapper">
<div style="padding: 0 0 12.2%">
<div>
{{img_element()}}
</div>
</div> </div>
</div> </div>
</div> {% endif %}
</a> </a>
{% endif %} {% endif %}
{% endif %} {% endif %}