Files
alexohneander-zola/templates/shortcodes/dimmable_image.html
2023-04-16 18:06:20 +02:00

3 lines
281 B
HTML

{% set meta = get_image_metadata(path=src, allow_missing=true) %}
<img class="dimmable-image" src="{{ get_url(path=src) }}" {% if alt %}alt="{{ alt }}" {% endif %} {% if meta.width %}width="{{ meta.width }}" {% endif %} {% if meta.height %}height="{{ meta.height }}" {% endif %}/>