aboutsummaryrefslogtreecommitdiff
path: root/themes/sourcehut/address-book.html
blob: 666e08a837805bb7bb91665f0d2da5144fc3611e (plain) (blame)
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
{{template "head.html"}}
{{template "nav.html" .Global}}

<div class="container-fluid">
  <div class="row">
    <div class="col-md-12 header-tabbed">
      <h2>Contacts</h2>
      <ul class="nav nav-tabs">
        <li class="nav-item">
          <a class="nav-link active" href="/contacts">Contacts</a>
        </li>
        <li class="nav-item">
          <a class="nav-link" href="/contacts/create">Create contact</a>
        </li>
      </ul>
    </div>
  </div>
</div>
<div class="container-fluid mailbox-container">
  <div class="row">
    <div class="col-md-2 mailboxes-column">
      <ul class="nav flex-column">
        <li class="nav-item">
          <a class="nav-link active" href="/contacts">{{.AddressBook.Name}}</a>
        </li>
      </ul>
    </div>
    <div class="col-md-10 messages-column">
      <div class="nav flex-column">
        <form method="get" action="">
          <input type="text" name="query" value="{{.Query}}"
            class="form-control" placeholder="Search" autofocus>
        </form>
      </div>

      {{if .AddressObjects}}
        <ul class="nav flex-column">
          {{range .AddressObjects}}
            <li class="nav-item">
              <a
                class="nav-link"
                href="/contacts/{{.Card.Value "UID" | pathescape}}"
              >{{.Card.Value "FN"}}</a>
            </li>
          {{end}}
        </ul>
      {{else}}
        <p>No contact.</p>
      {{end}}
    </div>
  </div>
</div>

{{template "foot.html"}}