Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/spech66/materialize-bp-hugo-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Pech <windows@spech.de>2020-04-12 14:57:47 +0300
committerSebastian Pech <windows@spech.de>2020-04-12 14:57:47 +0300
commit8ddab5e8e29f8bebe62c88cec7757561f83de6e5 (patch)
treea54da123cb634f8e85dce41a03df05d5489bfdb0
parent8203c097260907b54a90e883b6621591d939a224 (diff)
external link in new window
-rw-r--r--layouts/_default/_markup/render-link.html1
1 files changed, 1 insertions, 0 deletions
diff --git a/layouts/_default/_markup/render-link.html b/layouts/_default/_markup/render-link.html
new file mode 100644
index 0000000..d1eef46
--- /dev/null
+++ b/layouts/_default/_markup/render-link.html
@@ -0,0 +1 @@
+<a href="{{ .Destination | safeURL }}"{{ with .Title}} title="{{ . }}"{{ end }}{{ if strings.HasPrefix .Destination "http" }} target="_blank" rel="noopener noreferrer"{{ end }}>{{ .Text | safeHTML }}{{ if strings.HasPrefix .Destination "https://amzn.to" }}&nbsp;<i class="fab fa-amazon"></i>{{ end }}{{ if strings.HasPrefix .Destination "https://github" }}&nbsp;<i class="fab fa-github"></i>{{ end }}</a> \ No newline at end of file