summaryrefslogtreecommitdiffstats
path: root/templates_gmi/shortcodes/fig.html
diff options
context:
space:
mode:
authorJan Tuomi <jan@jantuomi.fi>2026-08-09 17:32:32 +0300
committerJan Tuomi <jan@jantuomi.fi>2026-08-09 17:32:32 +0300
commit69e01c2a6d0451f9eb7ee67e9ad464e5b1f01a67 (patch)
tree7f67e6eb0cdfc5a1ed854b8bdd6fe345e84afb26 /templates_gmi/shortcodes/fig.html
parenteee25cf1d1784e599d35ef55c4642b9cee292f9d (diff)
Fix fig paths in now pages
Diffstat (limited to 'templates_gmi/shortcodes/fig.html')
-rw-r--r--templates_gmi/shortcodes/fig.html7
1 files changed, 6 insertions, 1 deletions
diff --git a/templates_gmi/shortcodes/fig.html b/templates_gmi/shortcodes/fig.html
index 9988107..4e4b4c3 100644
--- a/templates_gmi/shortcodes/fig.html
+++ b/templates_gmi/shortcodes/fig.html
@@ -1 +1,6 @@
-=> {{ src }} {{ alt }}
+{% if src is starting_with("/") %}
+{% set img_src = src %}
+{% else %}
+{% set img_src = page.path ~ src %}
+{% endif %}
+=> {{ img_src }} {{ alt }}