templates/log.html
1{{ define "log" }}
2<html>
3{{ template "head" . }}
4
5 {{ template "repoheader" . }}
6 <body>
7 {{ template "nav" . }}
8 <main>
9 {{ $repo := .name }}
10 <table class="log-table">
11 <thead>
12 <tr><th>commit</th><th>age</th><th>files</th><th>lines</th></tr>
13 </thead>
14 <tbody>
15 {{ range .commits }}
16 <tr>
17 <td class="log-msg"><a href="/{{ $repo }}/commit/{{ .Hash }}">{{ .Message }}</a>
18 {{- range .Decor }}
19 <span class="deco deco-{{ .Type }}">{{ .Name }}</span>
20 {{- end -}}
21 </td>
22 <td class="log-age">{{ .Age }}</td>
23 <td class="log-files">{{ .Files }}</td>
24 <td class="log-lines"><span class="diff-add">+{{ .Add }}</span> <span class="diff-del">−{{ .Del }}</span></td>
25 </tr>
26 {{ end }}
27 </tbody>
28 </table>
29 </main>
30 </body>
31</html>
32{{ end }}