aboutsummaryrefslogtreecommitdiff
path: root/themes
diff options
context:
space:
mode:
authortdro <tdro@noreply.example.com>2022-05-09 01:24:18 -0400
committertdro <tdro@noreply.example.com>2022-05-09 01:24:18 -0400
commite74a422d6550a106af265828d34036686585bdf5 (patch)
tree618af443801ece9b72e6542d6276b15723864aae /themes
parent79c7ee98c184220132680fef344c0afba121cec0 (diff)
downloadcanory-e74a422d6550a106af265828d34036686585bdf5.tar.gz
canory-e74a422d6550a106af265828d34036686585bdf5.tar.bz2
canory-e74a422d6550a106af265828d34036686585bdf5.zip
themes/default/layouts/shortcodes/abbr.rss: Show full abbreviations in RSS
Diffstat (limited to 'themes')
-rw-r--r--themes/default/layouts/shortcodes/abbr.rss.xml5
1 files changed, 5 insertions, 0 deletions
diff --git a/themes/default/layouts/shortcodes/abbr.rss.xml b/themes/default/layouts/shortcodes/abbr.rss.xml
new file mode 100644
index 0000000..7e8079b
--- /dev/null
+++ b/themes/default/layouts/shortcodes/abbr.rss.xml
@@ -0,0 +1,5 @@
+{{- $abbr := default "TL;DR:" (.Get "abbr" | default (.Get 0)) -}}
+{{- $title := default "Too long, didn't read" (.Get "title" | default (.Get 1)) -}}
+
+<abbr title="{{ $title }}">{{ $abbr | markdownify }} ({{ $title }})</abbr>
+{{- /* This comment removes trailing newlines and white spaces. */ -}}