31 lines
1.0 KiB
HTML
Raw Normal View History

{% if settings.settings.light_mode %}
{% set pathstatic = ".." %}
{% else %}
{% set pathstatic = "." %}
{% endif %}
2016-05-26 17:04:57 +02:00
<section class="pictures-group">
{% for line in section.images %}
{% for image in line %}
{% if image.type == "video" %}
{% set video = Video(image) %}
2017-05-03 19:04:16 +02:00
{% set format = settings.ffmpeg.extension %}
2016-05-26 17:04:57 +02:00
{{ video.copy() }}
{% else %}
{% set image = Image(image) %}
{{ image.copy() }}
{% endif %}
2017-05-03 19:04:16 +02:00
{% set caption = image.text %}
2016-05-26 17:04:57 +02:00
<div class="image">
{% if video %}
2017-05-03 19:04:16 +02:00
<video class="responsive-video" id="video" poster="{{ pathstatic }}/{{ video.generate_thumbnail("800") }}" alt="" autoplay="autoplay" loop="loop" preload="auto" muted>
<source src="{{ pathstatic }}/{{ video }}.{{ format }}" type="video/{{ format }}">
2016-05-26 17:04:57 +02:00
</video>
{% set video = "" %}
{% else %}
<img src="{{ pathstatic }}/{{ image.generate_thumbnail("x800") }}" alt="{% if caption %}{{ caption }}{% endif %}">
2016-05-26 17:04:57 +02:00
{% endif %}
</div>
{% endfor %}
{% endfor %}
</section>