Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/uPagge/uBlogger.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDillon <dillonzq@outlook.com>2020-02-03 13:38:10 +0300
committerDillon <dillonzq@outlook.com>2020-02-03 13:38:10 +0300
commit52c7ad29a60cc4ee6c51217d11bb4877ef0cf88a (patch)
tree4bf578ddcdbf78b8543bf33d948feceac2b7f5e8 /layouts/_default/_markup
parent8aba2262906628f38f114a9947783bc6c7fd7495 (diff)
chore(style): update code style and add an i18n word
Diffstat (limited to 'layouts/_default/_markup')
-rw-r--r--layouts/_default/_markup/render-image.html14
1 files changed, 7 insertions, 7 deletions
diff --git a/layouts/_default/_markup/render-image.html b/layouts/_default/_markup/render-image.html
index c143d1d..402f4fe 100644
--- a/layouts/_default/_markup/render-image.html
+++ b/layouts/_default/_markup/render-image.html
@@ -1,11 +1,11 @@
<figure>
+ {{- /* Lazyload */ -}}
{{- $loading := resources.Get "svg/loading.svg" | minify -}}
<img src="{{ $loading.RelPermalink }}" data-sizes="auto" data-src="{{ .Destination | safeURL }}" alt="{{ .Text }}"{{ with .Title }} title="{{ . }}"{{ end }} class="lazyload">
- <figcaption class="image-caption">
- {{- if .Title -}}
- {{- .Title -}}
- {{- else -}}
- {{- .Text -}}
- {{- end -}}
- </figcaption>
+ {{- $caption := .Title | default .Text -}}
+ {{- with $caption -}}
+ <figcaption class="image-caption">
+ {{- . -}}
+ </figcaption>
+ {{- end -}}
</figure> \ No newline at end of file