nextDESIGN/layouts/index.html

53 lines
1.3 KiB
HTML

{{ define "main" }}
<header>
<h1>{{ .Site.Title }}</h1>
<h3>I compose music and write stuff</h3>
</header>
{{ .Content }}
<h3>Read more from me</h3>
{{ with .Site.GetPage "/about" }}
<a class="btn" href="{{ .Permalink }}">More about me</a>
{{ end }}
{{ with .Site.GetPage "/blog" }}
<a class="btn" href="{{ .Permalink }}">My blog</a>
{{ end }}
{{ with .Site.GetPage "/projects" }}
<a class="btn" href="{{ .Permalink }}">My projects</a>
{{ end }}
<h3>Find me on other places</h3>
{{ with .OutputFormats.Get "rss" }}
<a class="btn" href="{{ .Permalink }}">RSS Feed</a>
{{- end -}}
{{ with .Site.Params.social.mastodon }}
<a class="btn" href="{{ . }}">Mastodon</a>
{{- end -}}
{{ with .Site.Params.social.gitea }}
<a class="btn" href="{{ . }}">Repos on Gitea</a>
{{- end -}}
{{ with .Site.Params.social.gitlab }}
<a class="btn" href="{{ . }}">Repos on GitLab</a>
{{- end -}}
<h2>Latest Post</h2>
{{ range first 3 .Site.RegularPages }}
<article>
<h3><a href="{{ .Permalink }}">{{ .Title }}</a></h3>
{{ partial "list-post.html" . }}
</article>
{{ end }}
{{ with .Site.GetPage "/blog" }}
<a href="{{ .Permalink }}">Read more posts</a>
{{ end }}
{{ end }}