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-01-31 13:46:28 +0300
committerDillon <dillonzq@outlook.com>2020-01-31 13:46:28 +0300
commit344f0a9f411a9b28d6e5732e591f26953d9c1263 (patch)
tree52ed7ce26bdcf9e40e2bd782da377e5c0c4653ca /layouts/_default/_markup
parent7e6236361f790ec76a1d282021e6507a8378f40f (diff)
fix(css): fix some css bugs
Diffstat (limited to 'layouts/_default/_markup')
-rw-r--r--layouts/_default/_markup/render-image.html20
-rw-r--r--layouts/_default/_markup/render-link.html10
2 files changed, 30 insertions, 0 deletions
diff --git a/layouts/_default/_markup/render-image.html b/layouts/_default/_markup/render-image.html
new file mode 100644
index 0000000..8ab4804
--- /dev/null
+++ b/layouts/_default/_markup/render-image.html
@@ -0,0 +1,20 @@
+<figure>
+ <img
+ {{ $res := resources.Get "svg/loading.svg" | minify }}
+ src="{{ $res.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>
+</figure> \ No newline at end of file
diff --git a/layouts/_default/_markup/render-link.html b/layouts/_default/_markup/render-link.html
new file mode 100644
index 0000000..ccac741
--- /dev/null
+++ b/layouts/_default/_markup/render-link.html
@@ -0,0 +1,10 @@
+<a href="{{ .Destination | safeURL }}"
+ {{- with .Title -}}
+ title="{{ . }}"
+ {{- end -}}
+ {{- if strings.HasPrefix .Destination "http" -}}
+ target="_blank"
+ {{- end -}}
+ >
+ {{- .Text -}}
+</a> \ No newline at end of file