Alternative content (RSS, (offline) JSON), social media partial

This commit is contained in:
Franz Klotsche
2025-11-19 11:16:40 +01:00
parent 1c9e04e308
commit dc0b5d8cfc
15 changed files with 501 additions and 17 deletions

View File

@@ -1,3 +1,5 @@
<footer>
<small>Copyright {{now.Format "2006"}} Me.</small>
<small>Copyright {{now.Format "2006"}} {{ .Site.Params.author }} -
Find me on: {{- partial "social-media.html" . -}}
</small>
</footer>

View File

@@ -1,7 +1,9 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta lang="de"> <!-- HowTo correct?-->
<meta name="author" content="{{ .Site.Params.author }}">
<meta name="keywords" content="{{ delimit .Keywords `, ` `, und ` }}">
<meta name="description" content="
{{- with .Page.Description -}}
{{ . }}
@@ -10,6 +12,17 @@
{{- end -}}">
<link rel="stylesheet" href="{{ "css/style.css"
| relURL }}">
<!-- RSS -->
{{ range .AlternativeOutputFormats -}}
{{- $link := `<link rel="%s" type="%s" href="%s" title="%s">` -}}
{{- $title := printf "%s - %s" $.Page.Title $.Site.Title -}}
{{- if $.Page.IsHome -}}
{{ $title = $.Site.Title }}
{{- end -}}
{{ printf $link .Rel .MediaType.Type .Permalink $title | safeHTML }}
{{- end }}
<title>
{{- if .Page.IsHome -}}
{{ .Site.Title }}

View File

@@ -0,0 +1,5 @@
<ul>
{{ range .Site.Data.socialmedia.accounts }}
<li><a href="{{ .url }}">{{ .name }}</a></li>
{{ end }}
</ul>