oficina / calendar Public

Clone
git clone https://amadan.net/oficina/calendar

Plain git — no account needed to clone.

Download

Download this file

1{{define "title"}}{{.Title}}{{end}}
2{{define "content"}}
3<header rst-page-header>
4 <div rst-page-header-titles>
5 <h1>Reminders</h1>
6 </div>
7</header>{{if .Partial}}{{template "team-partial" .}}{{end}}
8
9{{/* In-app reminders (spec §7): the ones that have come due, newest
10 first, until they are dismissed. Unread means undismissed, because
11 nothing is written on a GET. Every action is a plain link or form. */}}
12{{if .Data.Notices}}
13<p cal-sentence cal-sentence-muted>Reminders that have come due stay here until you dismiss them.</p>
14<div rst-list cal-notices>
15 {{range .Data.Notices}}
16 <div rst-row>
17 <span rst-row-main>
18 <a href="{{.Href}}">{{.Title}}</a>
19 <small rst-row-sub>{{.When}}</small>
20 </span>
21 <form cal-notice-dismiss method="post" action="/reminders/{{.ID}}/dismiss">
22 <button rst-row-action type="submit">Dismiss<span class="rst-sr-only"> {{.Title}}</span></button>
23 </form>
24 </div>
25 {{end}}
26</div>
27<div rst-actions cal-bar>
28 <form method="post" action="/reminders/dismiss">
29 <button rst-btn type="submit">Dismiss all</button>
30 </form>
31</div>
32{{else if not .Partial}}
33{{/* Withheld under Unknown, so an empty partial list never reads as
34 "nothing due". */}}
35{{if .Data.InApp}}
36{{template "empty-state" dict
37 "Title" "No reminders waiting"
38 "Body" "When a reminder you set comes due, it appears here and stays until you dismiss it."}}
39{{else}}
40{{template "empty-state" dict
41 "Title" "No reminders waiting"
42 "Body" "Your reminders come by email. To have them appear here instead, or as well, choose how to be reminded in Settings."
43 "ActionHref" "/settings"
44 "ActionLabel" "Open Settings"}}
45{{end}}
46{{end}}
47{{end}}
48