A webmail client. Forked from https://git.sr.ht/~migadu/alps
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

40 lines
945 B

  1. <header>
  2. <nav>
  3. {{$page := (index .GlobalData.Path 0)}}
  4. <a href="/"
  5. {{ if or (eq $page "mailbox") (eq $page "message") (eq $page "compose") }}
  6. class="active"
  7. {{ end }}
  8. >Email</a>
  9. {{ if call .GlobalData.HavePlugin "caldav" }}
  10. <a
  11. href="/calendar"
  12. {{ if eq $page "calendar" }}
  13. class="active"
  14. {{ end }}
  15. >Calendar</a>
  16. {{ end }}
  17. {{ if call .GlobalData.HavePlugin "carddav" }}
  18. <a
  19. href="/contacts"
  20. {{ if eq $page "contacts" }}
  21. class="active"
  22. {{ end }}
  23. >Contacts</a>
  24. {{ end }}
  25. {{ if .GlobalData.LoggedIn }}
  26. <div>
  27. <span>{{ .GlobalData.Username }}</span>
  28. <a href="/settings">Settings</a>
  29. <a href="/logout">Sign Out</a>
  30. </div>
  31. {{ end }}
  32. </nav>
  33. {{ if .GlobalData.Notice }}
  34. <div class="notice">
  35. {{ .GlobalData.Notice }}
  36. <a href="{{.GlobalData.URL.String}}">Dismiss</a>
  37. </div>
  38. {{ end }}
  39. </header>