nextDESIGN/layouts/index.html

53 lines
1.3 KiB
HTML

{{ define "main" }}
<header>
<h1>{{ .Site.Title }}</h1>
<h3>{{ .Site.Params.about }}</h3>
</header>
{{ .Content }}
<h4>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 }}
<h4>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.forgejo }}
<a class="btn" href="{{ . }}">Repos on Forgejo</a>
{{- end -}}
{{ with .Site.Params.social.gitlab }}
<a class="btn" href="{{ . }}">Repos on GitLab</a>
{{- end -}}
<h2>Latest Posts</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 class="btn" href="{{ .Permalink }}">Read more posts</a>
{{ end }}
{{ end }}