Finish video embed support

This commit is contained in:
2025-07-27 03:33:25 -05:00
parent f371afe529
commit 486fa65ad6

View File

@@ -6,12 +6,14 @@
<img src="{{ .Permalink }}" {{ with .Params.alt }}alt="{{ . }}"{{ end }} /> <img src="{{ .Permalink }}" {{ with .Params.alt }}alt="{{ . }}"{{ end }} />
{{ else if eq .ResourceType "video" }} {{ else if eq .ResourceType "video" }}
<video controls preload="metadata"> <video controls preload="metadata">
{{/* FIXME {{ with .Params.alt }}
<source src="{{ .Permalink }}" {{ with .Params.alt }}alt="{{ . }}"{{ end }} /> {{ warnf "video does not support alt text, '%s'" . }}
*/}} {{ end }}
<source src="{{ .Permalink }}" />
{{ i18n "browser_no_video_support" }} {{ i18n "browser_no_video_support" }}
<a href="{{ .Permalink }}" target="_blank" rel="noopener"> <a href="{{ .Permalink }}" target="_blank" rel="noopener">
{{ i18n "browser_no_video_support_link" }} {{ i18n "browser_no_video_support_link" }}
</a>
</video> </video>
{{ else }} {{ else }}
{{/* TODO: could consider implementing more types, listed at: {{/* TODO: could consider implementing more types, listed at: