{{define "title"}} Notes about {{.User.Username}} {{end}} {{define "content"}}
{{$Root := .}}

On this page you may jot down some private notes for yourself about {{.User.Username}}, for example to remember a topic you discussed on chat or to remember what they said their favorite color was -- it's up to you!

Your notes will not normally be visible to {{.User.Username}} but will be visible to website administrators. Please be mindful of what you write in case of the unlikely event that your notes could be legally required to be disclosed to {{.User.Username}} sometime in the future.

{{InputCSRF}}
{{if not .MyNote.UpdatedAt.IsZero}}
You last updated your notes {{SincePrettyCoarse .MyNote.UpdatedAt}} ago.
{{end}}
{{if .CurrentUser.HasAdminScope "admin.user.notes"}}

Everyone Else's Notes

{{if .NotePager.Total}}

Found {{.NotePager.Total}} note{{Pluralize64 .NotePager.Total}} about this user (page {{.NotePager.Page}} of {{.NotePager.Pages}}).

{{end}}

Note: admin notes are shown first, and the rest are ordered by recently updated.

{{SimplePager .NotePager}}

{{range .OtherNotes}} {{end}}
{{SimplePager .NotePager}}
{{end}}
{{if .CurrentUser.HasAdminScope "admin.feedback"}}

Admin Feedback & Reports

{{if .FeedbackPager.Total}} Found {{.FeedbackPager.Total}} report{{Pluralize64 .FeedbackPager.Total}} about this user (page {{.FeedbackPager.Page}} of {{.FeedbackPager.Pages}}). {{end}}
{{SimplePager .FeedbackPager}}
{{range .Feedback}} {{$User := $Root.UserMap.Get .UserID}}
Intent: {{.Intent}}
Subject: {{.Subject}}
Table: {{if eq .TableName ""}} n/a {{if ne .TableID 0}} - {{.TableID}}{{end}} {{else if eq .TableName "users"}} Users: {{.TableID}} {{else if eq .TableName "photos"}} Photos: {{.TableID}} {{else if eq .TableName "messages"}} Messages: {{.TableID}} {{else}} {{.TableName}}: {{.TableID}} {{end}}
Reply To: {{if $User}} {{$User.Username}} {{else if ne .ReplyTo ""}} {{.ReplyTo}} {{else}} n/a {{end}}
Date: {{.CreatedAt.Format "2006-01-02 15:04:05 MST"}}
{{if eq .Message ""}}

No message attached.

{{else}} {{ToMarkdown .Message}} {{end}}
{{end}}
{{SimplePager .FeedbackPager}}
{{end}}
{{end}}