summaryrefslogtreecommitdiff
path: root/layouts/shortcodes
diff options
context:
space:
mode:
authorMichał M. Sapka <michal@sapka.me>2023-05-17 12:37:47 +0200
committerMichał M. Sapka <michal@sapka.me>2023-05-17 12:37:47 +0200
commit4e670c556a6d8da5f935bba5948c39af9e6541be (patch)
treec68216f5c118fd69d67bba265d8a93a4dd01d442 /layouts/shortcodes
parent260cd719083d6a12958a8ee57af04aeea8a74ad0 (diff)
feat: article for 2023-05-17
Diffstat (limited to 'layouts/shortcodes')
-rw-r--r--layouts/shortcodes/svg-full-width.html20
1 files changed, 20 insertions, 0 deletions
diff --git a/layouts/shortcodes/svg-full-width.html b/layouts/shortcodes/svg-full-width.html
new file mode 100644
index 0000000..4c604ab
--- /dev/null
+++ b/layouts/shortcodes/svg-full-width.html
@@ -0,0 +1,20 @@
+{{- $file := .Get 0 }}
+{{- $path := printf "content_images/%s" $file}}
+{{- $img := resources.Get $path }}
+{{- $caption := .Get 1 }}
+{{- $source := .Get 2 }}
+<figure class="graph">
+ <img
+ class="center"
+ alt="{{ $caption }}"
+ src="{{ $img.RelPermalink }}"
+
+ >
+ <figcaption>
+ {{ $caption }}
+
+ {{- if $source }}
+ <a href="{{ $source }}" target="_blank" title="source">[source]</a>
+ {{ end }}
+ </figcaption>
+</figure>