mirror of https://github.com/jlelse/GoBlog
20 lines
945 B
Plaintext
20 lines
945 B
Plaintext
{{ define "header" }}
|
|
<header>
|
|
<h1><a href="{{ blogrelative .Blog "/" }}" rel="home" title="{{ .Blog.Title }}">{{ .Blog.Title }}</a></h1>
|
|
{{ with .Blog.Description }}<p><i>{{ . }}</i></p>{{ end }}
|
|
<nav>
|
|
{{ with menu .Blog "main" }}
|
|
{{ range $i, $item := .Items }}{{ if ne $i 0 }} • {{ end }}<a href="{{ $item.Link }}">{{ $item.Title }}</a>{{ end }}
|
|
{{ end }}
|
|
</nav>
|
|
{{ if .LoggedIn }}
|
|
<nav>
|
|
<a href="{{ blogrelative .Blog "/editor" }}">{{ string .Blog.Lang "editor" }}</a>
|
|
• <a href="/notifications">{{ string .Blog.Lang "notifications" }}</a>
|
|
• <a href="/webmention">{{ string .Blog.Lang "webmentions" }}</a>
|
|
• <a href="{{ blogrelative .Blog "/comment" }}">{{ string .Blog.Lang "comments" }}</a>
|
|
• <a href="/logout">{{ string .Blog.Lang "logout" }}</a>
|
|
</nav>
|
|
{{ end }}
|
|
</header>
|
|
{{ end }} |