change release section put video and more
This commit is contained in:
@@ -411,6 +411,9 @@
|
||||
</div>
|
||||
</section>
|
||||
|
||||
{% elif section.section_type == "video" %}
|
||||
{% include "partials/_video_section.html" with section=section %}
|
||||
|
||||
{% endif %}
|
||||
{% empty %}
|
||||
<section class="section">
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
{% if videos %}
|
||||
<section class="section product-videos-section" aria-label="Product videos">
|
||||
<div class="container">
|
||||
<div class="product-videos-list">
|
||||
{% for video in videos %}
|
||||
{% if video.has_video %}
|
||||
<div class="product-video-item">
|
||||
{% include "partials/_video_block.html" with video=video compact_header=True %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
||||
@@ -0,0 +1,55 @@
|
||||
{% if video.has_video %}
|
||||
{% if video.video_styled_background %}
|
||||
<div class="video-panel video-panel--styled fade-in">
|
||||
<div class="video-panel-ambient" aria-hidden="true">
|
||||
<div class="video-panel-blob video-panel-blob--1"></div>
|
||||
<div class="video-panel-blob video-panel-blob--2"></div>
|
||||
<div class="video-panel-blob video-panel-blob--3"></div>
|
||||
</div>
|
||||
<div class="video-panel-inner">
|
||||
{% if video.badge or video.title %}
|
||||
<div class="video-panel-header">
|
||||
<div class="video-panel-heading">
|
||||
{% if video.badge %}<div class="section-badge">{{ video.badge }}</div>{% endif %}
|
||||
{% if video.title %}
|
||||
<h2 class="video-panel-title" id="video-heading-{{ video.pk }}">
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" aria-hidden="true">
|
||||
<polygon points="5 3 19 12 5 21 5 3"/>
|
||||
</svg>
|
||||
{{ video.title }}
|
||||
</h2>
|
||||
{% else %}
|
||||
<h2 class="sr-only" id="video-heading-{{ video.pk }}">Video</h2>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
<h2 class="sr-only" id="video-heading-{{ video.pk }}">Video</h2>
|
||||
{% endif %}
|
||||
{% if video.description %}
|
||||
<div class="rich-content section-desc video-panel-desc">{{ video.rendered_description }}</div>
|
||||
{% elif video.content %}
|
||||
<div class="rich-content section-desc video-panel-desc">{{ video.rendered_content }}</div>
|
||||
{% endif %}
|
||||
{% include "partials/_video_player.html" with video=video %}
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
{% if video.badge or video.title %}
|
||||
<div class="section-header{% if compact_header %} product-video-header{% endif %}">
|
||||
{% if video.badge %}<div class="section-badge">{{ video.badge }}</div>{% endif %}
|
||||
{% if video.title %}
|
||||
<h2 class="section-title" id="video-heading-{{ video.pk }}">{{ video.title }}</h2>
|
||||
{% else %}
|
||||
<h2 class="sr-only" id="video-heading-{{ video.pk }}">Video</h2>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if video.description %}
|
||||
<div class="rich-content section-desc">{{ video.rendered_description }}</div>
|
||||
{% elif video.content %}
|
||||
<div class="rich-content section-desc">{{ video.rendered_content }}</div>
|
||||
{% endif %}
|
||||
{% include "partials/_video_player.html" with video=video %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
@@ -0,0 +1,26 @@
|
||||
{% if video.has_video %}
|
||||
<div class="video-block {{ video.video_size_class }} {{ video.video_aspect_class }} fade-in">
|
||||
<div class="video-block-inner glass-card">
|
||||
{% if video.video_source == "upload" and video.video_file %}
|
||||
<video
|
||||
controls
|
||||
playsinline
|
||||
preload="metadata"
|
||||
{% if video.video_poster %}poster="{{ video.video_poster.url }}"{% endif %}
|
||||
title="{{ video.title|default:'Video' }}"
|
||||
>
|
||||
<source src="{{ video.video_file.url }}" />
|
||||
</video>
|
||||
{% elif video.youtube_embed_url %}
|
||||
<iframe
|
||||
src="{{ video.youtube_embed_url }}"
|
||||
title="{{ video.title|default:'Video' }}"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
||||
allowfullscreen
|
||||
loading="lazy"
|
||||
referrerpolicy="strict-origin-when-cross-origin"
|
||||
></iframe>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
@@ -0,0 +1,7 @@
|
||||
{% if section.has_video %}
|
||||
<section class="section video-section" aria-labelledby="video-heading-{{ section.pk }}">
|
||||
<div class="container">
|
||||
{% include "partials/_video_block.html" with video=section %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
||||
Reference in New Issue
Block a user