~huyngo/yue

ref: b50ae276f4fe44a2ffdb8bfe33dbec379b126ab2 yue/templates/base.tmpl -rw-r--r-- 1.6 KiB
b50ae276Huy Ngo Add about page to footer 11 months 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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{{define "base"}}
<!DOCTYPE html>
<html lang="{{ .Lang }}">
  <head>
    <title>{{ .Page.Title }}</title>
    <meta name="description" content="{{ .Page.Description }}">
    {{ template "head" .}}
    </head>
  <body>
    <!-- NAVIGATION BAR -->
    <div class="container large">
      <header>
        <nav class="left">
          <ul>
            <li><a href="/timeline/home">Home</a></li>
            <li><a href="/timeline/timeline">All</a></li>
            <li><a href="/timeline/timeline">Local</a></li>
            <li><a href="/communities">Communities</a></li>
            <li><a href="/settings">Settings</a></li>
          </ul>
            {{ if .LoggedIn }}
            <li>
              <a href="/user/{{ .LoggedIn.Id }}">{{ .LoggedIn.Username }}</a>
            </li>
            <li><a href="/logout">Log Out</a></li>
            {{ else }}
            <li><a href="/login">Log In</a></li>
            {{ end }}
        </nav>
      </header>
    </div>
    <div class="container">

    <!-- MAIN CONTENT -->
      <main>
      {{ template "main" .}}
      </main>
      <hr>
      <footer>
        <p>
          Yue is free software:
          Its <a id="code" href="https://git.sr.ht/~huyngo/yue">source code</a>
          is released under the
          <a href="https://www.gnu.org/licenses/agpl-3.0.html">
            GNU Affero General Public License version 3.</a>
          Current version: {{ .Yue.Version }}
        </p>
        <p>
          See:
          <ul>
            <li><a href="/about">About page</a></li>
          </ul>
        </p>
      </footer>
    </div>
  </body>
</html>
{{end}}