Replaced object by svg

This commit is contained in:
Kevin Veen-Birkenbach 2025-07-07 12:46:56 +02:00
parent 9ada9acb3a
commit cc0fc9b77f
No known key found for this signature in database
GPG Key ID: 44D8F11FD62F878E

View File

@ -4,11 +4,11 @@
<div class="card-img-top">
{% if card.icon.cache %}
{% if card.icon.cache.endswith('.svg') %}
<object type="image/svg+xml" data="{{ card.icon.cache }}" style="width:100px; height:auto;">
<svg type="image/svg+xml" data="{{ card.icon.cache }}" style="width:100px; height:auto;">
{% if card.icon.class %}
<i class="{{ card.icon.class }}"></i>
{% endif %}
</object>
</svg>
{% else %}
<img src="{{ card.icon.cache }}" alt="{{ card.title }}" style="width:100px; height:auto;"
onerror="this.style.display='none'; var icon=this.nextElementSibling; if(icon) icon.style.display='inline-block';">