[Minor] Added Mastodon link

This commit is contained in:
Robert von Burg 2022-11-11 08:35:30 +01:00
parent 7121520fcb
commit cc1e4860a5
Signed by: eitch
GPG Key ID: 75DB9C85C74331F7
2 changed files with 10 additions and 2 deletions

View File

@ -108,3 +108,9 @@ name = "<i class='fab fa-github'></i> GitHub project"
identifier = "github"
url = "https://github.com/strolch-li"
weight = 10
[[menu.shortcuts]]
name = "<i class='fab fa-mastodon'></i> Mastodon"
identifier = "mastodon"
url = "https://mstdn.gsi.li/@eitch"
weight = 10

View File

@ -41,8 +41,10 @@
<ul>
{{ range sort . "Weight"}}
<li>
{{ if gt (strings.Count "http" .URL) 0}}
{{.Pre}}<a class="padding" href="{{.URL | absLangURL }}" target="_blank">{{safeHTML .Name}}</a>{{.Post}}
{{ if gt (strings.Count "mastodon" .Identifier) 0}}
{{.Pre}}<a rel="me" class="padding" href="{{.URL | absLangURL }}" target="_blank">{{safeHTML .Name}}</a>{{.Post}}
{{ else if gt (strings.Count "http" .URL) 0 }}
{{.Pre}}<a class="padding" href="{{.URL | absLangURL }}">{{safeHTML .Name}}</a>{{.Post}}
{{ else }}
{{.Pre}}<a class="padding" href="{{.URL | absLangURL }}">{{safeHTML .Name}}</a>{{.Post}}
{{ end }}