mirror of
https://github.com/yuzu-emu/shared-bulma-theme.git
synced 2024-12-22 18:15:45 +00:00
commit
f250a15a42
19
layouts/shortcodes/gifv.html
Normal file
19
layouts/shortcodes/gifv.html
Normal file
|
@ -0,0 +1,19 @@
|
|||
<!-- Usage: {{< gifv "url|title" "url2|title" >}} -->
|
||||
<div class="columns">
|
||||
{{ range $param := .Params }}
|
||||
<!-- gifv -->
|
||||
{{ $items := split $param "|" }}
|
||||
{{ $src := (index $items 0) }}
|
||||
{{ $title := (index $items 1) }}
|
||||
<div class="column">
|
||||
<video preload="auto" autoplay="autoplay" muted="muted" loop="loop" webkit-playsinline="">
|
||||
<source src="{{ $src }}" type="video/mp4">
|
||||
Your browser doesn't support mp4 video. :(
|
||||
</video>
|
||||
|
||||
{{ if $title }}
|
||||
<p class="has-text-centered is-italic has-text-grey-light">{{ $title }}</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
Loading…
Reference in a new issue