{{define "archived.html"}}
{{template "shell-start" .}}
<header class="page-head"><div><p class="eyebrow">TEAM BOARD</p><h1>Archived cards</h1><p>Review work archived in this workspace.</p></div><a class="button secondary" href="/board">← Back to board</a></header>
{{template "notice" .}}
<section class="card archived-page-card"><header class="section-head"><div><p class="eyebrow">ARCHIVE</p><h2>{{len .ArchivedTasks}} cards</h2></div></header>
{{if .ArchivedTasks}}<div class="archived-card-list">{{range .ArchivedTasks}}<article class="archived-card"><div>{{if .Tags}}<div class="card-tags">{{range .Tags}}<span class="board-tag {{.Color}}">{{.Name}}</span>{{end}}</div>{{end}}<span class="archived-status">{{.Status}}</span><h3>{{.Title}}</h3></div>{{if or (eq .CreatorID $.User.ID) (eq $.User.Role "admin")}}<div class="archived-card-actions"><form method="post" action="/board/tasks/{{.ID}}/restore"><input type="hidden" name="csrf" value="{{$.CSRF}}"><button class="button secondary" type="submit">Restore</button></form><form method="post" action="/board/tasks/{{.ID}}/delete"><input type="hidden" name="csrf" value="{{$.CSRF}}"><button class="text-button" type="submit">Delete permanently</button></form></div>{{end}}</article>{{end}}</div>{{else}}<div class="empty roomy"><span>✓</span><h3>No archived cards</h3><p>Cards you archive will appear here.</p></div>{{end}}
</section>
{{template "shell-end" .}}
{{end}}
