diff options
author | Drew DeVault <sir@cmpwn.com> | 2020-10-22 13:03:50 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2020-10-22 13:03:50 -0400 |
commit | 6ba418c9b2fd02b2f784c20f83bd040585689c5f (patch) | |
tree | 454569141bed36edf968d952f9fe04c5d08037bc /themes/alps/message.html | |
parent | 9e2c420461cef709811ac84f958fae20b93b800b (diff) | |
download | alps-6ba418c9b2fd02b2f784c20f83bd040585689c5f.tar.gz alps-6ba418c9b2fd02b2f784c20f83bd040585689c5f.zip |
Generalize sidebar categorization logic
Diffstat (limited to 'themes/alps/message.html')
-rw-r--r-- | themes/alps/message.html | 28 |
1 files changed, 3 insertions, 25 deletions
diff --git a/themes/alps/message.html b/themes/alps/message.html index 2926641..713d3bc 100644 --- a/themes/alps/message.html +++ b/themes/alps/message.html @@ -1,5 +1,6 @@ {{template "head.html" .}} {{template "nav.html" .}} +{{template "util.html" .}} {{define "message-part-tree"}} {{/* nested templates can't access the parent's context */}} @@ -28,31 +29,8 @@ {{end}} <div class="page-wrap"> - {{$current := .Mailbox}} - <aside> - <!-- the logo image, dimensions 200x32 may be present or not --> - <a href="/compose" class="new">Compose Mail</a> - {{range .Mailboxes}} - <a href="{{.URL}}" - {{ if eq $current.Name .Name }}class="active"{{ end }}> - {{ if eq .Name "INBOX" }} - Inbox - {{else}} - {{.Name}} - {{end}} - - {{ $unseen := 0 }} - {{ if eq .Name "INBOX" }} - {{ $unseen = $.Inbox.Unseen }} - {{ end }} - {{ if eq .Name $.Mailbox.Name }} - {{ $unseen = $.Mailbox.Unseen }} - {{ end }} - {{ if $unseen }}({{ $unseen }}){{ end }} - </a> - {{end}} - </aside> - + {{ $current := .Mailbox }} + {{ template "aside" . }} <div class="container"> <main class="message"> <section class="actions"> |