aboutsummaryrefslogtreecommitdiff
path: root/themes/default/layouts
diff options
context:
space:
mode:
authortdro <tdro@noreply.example.com>2023-12-05 14:05:22 -0500
committertdro <tdro@noreply.example.com>2023-12-05 14:05:22 -0500
commite469338b416a4c129fd42fd448e902ddd1f66921 (patch)
tree407c9556ac463d12a920d0efcebf671b13ce828a /themes/default/layouts
parentedb511eda1a1e04a73d4e5cbbd32d4c15c87e5dd (diff)
downloadcanory-e469338b416a4c129fd42fd448e902ddd1f66921.tar.gz
canory-e469338b416a4c129fd42fd448e902ddd1f66921.tar.bz2
canory-e469338b416a4c129fd42fd448e902ddd1f66921.zip
themes/default/layouts/shortcodes/abbr: Increase uniqueness
Diffstat (limited to 'themes/default/layouts')
-rw-r--r--themes/default/layouts/shortcodes/abbr.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/themes/default/layouts/shortcodes/abbr.html b/themes/default/layouts/shortcodes/abbr.html
index 2a87233..61a2e32 100644
--- a/themes/default/layouts/shortcodes/abbr.html
+++ b/themes/default/layouts/shortcodes/abbr.html
@@ -1,6 +1,6 @@
{{- $abbr := default "TL;DR:" (.Get "abbr" | default (.Get 0)) -}}
{{- $title := default "Too long, didn't read" (.Get "title" | default (.Get 1)) -}}
-{{- $hash := print (truncate 8 "" (sha256 $abbr)) .Ordinal -}}
+{{- $hash := print (truncate 4 "" (sha256 .Page.RelPermalink)) (truncate 4 "" (sha256 $abbr)) .Ordinal -}}
<input hidden="" type="checkbox" id="abbr-{{ $hash }}" />
{{- /* This comment removes trailing newlines and white spaces. */ -}}