mirror of
https://github.com/BBaoVanC/bobatheme.git
synced 2024-11-17 13:25:57 -06:00
23 lines
579 B
HTML
23 lines
579 B
HTML
|
<figure>
|
||
|
|
||
|
{{ $img := $.Page.Resources.GetMatch (.Get "src") | resources.Fingerprint "sha512" }}
|
||
|
|
||
|
{{ if .Get "href" }}<a href="{{ .Get "href" }}">{{ end }}
|
||
|
<img src="{{ $img.Permalink }}"
|
||
|
{{ with $img.Title }}
|
||
|
alt="{{ . }}"
|
||
|
{{ end }}
|
||
|
|
||
|
{{ with .Get "width" }}width="{{ . }}"{{ end }}
|
||
|
{{ with .Get "height" }}height="{{ . }}"{{ end }}
|
||
|
/>
|
||
|
{{ if .Get "href" }}</a>{{ end }}
|
||
|
|
||
|
{{ with $img.Title }}
|
||
|
<figcaption>
|
||
|
{{ . | markdownify }}
|
||
|
</figcaption>
|
||
|
{{ end }}
|
||
|
|
||
|
</figure>
|