Use indentation inside templating blocks for better readability

This commit is contained in:
2021-11-22 02:21:15 -06:00
parent e1e211a42a
commit ead88d5e16
24 changed files with 310 additions and 326 deletions

View File

@ -4,24 +4,25 @@
{{ $alt := index . "alt" }}
{{ if index . "border" }}
<figure class="border">
<figure class="border">
{{ else }}
<figure>
<figure>
{{ end }}
{{ if eq $type "image" }}
<img src="{{ $src }}" alt="{{ $alt }}" />
<img src="{{ $src }}" alt="{{ $alt }}" />
{{ else if eq $type "video" }}
<video controls>
<source src="{{ $src }}" alt="{{ $alt }}">
{{ i18n "browser_no_video_support" }}
</video>
<video controls>
<source src="{{ $src }}" alt="{{ $alt }}">
{{ i18n "browser_no_video_support" }}
</video>
{{ end }}
{{ if not $hidecaption }}
{{ with $alt }}
<figcaption>
{{ . | markdownify }}
</figcaption>
{{ end }}
{{ with $alt }}
<figcaption>
{{ . | markdownify }}
</figcaption>
{{ end }}
{{ end }}
</figure>