~gitpocket/gitpocket

gitpocket/templates/layout.html -rw-r--r--1.2 KiB ViewLogBlameView rawPermalink d622d6a952 — feat(basin): minimal git host with ssh and smart https 4 days ago
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{.Title}}</title>
<link rel="stylesheet" href="/static/style.css">
</head>
<body>
<header>
<nav>
<a class="site" href="/">{{.Host}}</a>
{{if .User}}<a href="/~{{.User.Name}}">~{{.User.Name}}</a><a href="/create">new repo</a><a href="/settings">settings</a><form method="post" action="/logout"><button>log out</button></form>{{else}}<a href="/login">log in</a><a href="/register">register</a>{{end}}
</nav>
{{with .Data}}{{with index . "Page"}}
<nav class="repo">
<span class="path"><a href="/~{{.Repo.Owner.Name}}">~{{.Repo.Owner.Name}}</a>/<a href="/{{.Repo.Path}}">{{.Repo.Name}}</a>{{if .Repo.Private}} <span class="tag">private</span>{{end}}</span>
<a href="/{{.Repo.Path}}">summary</a>
{{if not .Empty}}<a href="/{{.Repo.Path}}/tree/{{.Ref}}/">tree</a><a href="/{{.Repo.Path}}/log/{{.Ref}}">log</a><a href="/{{.Repo.Path}}/refs">refs</a>{{end}}
{{if .Owner}}<a href="/{{.Repo.Path}}/settings">settings</a>{{end}}
</nav>
{{end}}{{end}}
</header>
<main>
{{if .Error}}<p class="error">{{.Error}}</p>{{end}}
{{template "content" .}}
</main>
</body>
</html>