shortcodes: Fix mp4 size

This commit is contained in:
FearlessTobi 2023-07-06 19:29:41 +02:00
parent f57272cf42
commit f9833cfc1f
2 changed files with 13 additions and 24 deletions

View File

@ -1,13 +1,15 @@
<figure>
<video preload="auto" controls>
<source src="{{ .Get "src" }}" type="video/mp4">
Your browser doesn't support mp4 video. :(
</video>
{{ with .Get "title" }}
<figcaption>
<h4>
<div style="position: relative; padding-bottom: 56.25%; padding-top: 30px; height: 0; overflow: hidden;">
<video preload="auto" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%;" controls>
<source src="{{ .Get "src" }}" type="video/mp4">
Your browser doesn't support mp4 video. :(
</video>
{{ with .Get "title" }}
<figcaption>
<h4>
{{ . }}
</h4>
</figcaption>
{{ end }}
</figure>
</h4>
</figcaption>
{{ end }}
</div>
</figure>

View File

@ -1,13 +0,0 @@
<figure>
<video preload="auto" controls>
<source src="{{ .Get "src" }}" type="video/webm">
Your browser doesn't support webm video. :(
</video>
{{ with .Get "title" }}
<figcaption>
<h4>
{{ . }}
</h4>
</figcaption>
{{ end }}
</figure>