From a388cd4bcf23b22d226e476ec06a3e204f5ad976 Mon Sep 17 00:00:00 2001 From: Helmut Merz Date: Sat, 2 Apr 2022 11:59:05 +0200 Subject: [PATCH] add render-link hook --- layouts/_default/_markup/render-link.html | 5 +++++ layouts/shortcodes/iimg.html | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 layouts/_default/_markup/render-link.html diff --git a/layouts/_default/_markup/render-link.html b/layouts/_default/_markup/render-link.html new file mode 100644 index 0000000..ffcfddf --- /dev/null +++ b/layouts/_default/_markup/render-link.html @@ -0,0 +1,5 @@ +{{- if hasPrefix .Destination "https://" -}} + {{ .Text }} +{{- else -}} + {{ .Text }} +{{- end -}} diff --git a/layouts/shortcodes/iimg.html b/layouts/shortcodes/iimg.html index 63b1139..df5a9a6 100644 --- a/layouts/shortcodes/iimg.html +++ b/layouts/shortcodes/iimg.html @@ -25,4 +25,4 @@ {{- else -}} {{ $alt }} {{- end -}} -

\ No newline at end of file +