feat: Updated email templates

This commit is contained in:
2026-09-10 12:06:29 +00:00
parent 059949674d
commit e1ad2467d2
34 changed files with 896 additions and 163 deletions
+18 -3
View File
@@ -1,8 +1,23 @@
{{define "category"}}Licence{{end}}
{{define "preheader"}}The licence has expired. Renew to unlock changes{{if not .DeleteOn.IsZero}} before {{date .DeleteOn}}{{end}}.{{end}}
{{define "pill"}}{{template "chip" (dict "label" "Read-only" "tone" "down")}}{{end}}
{{define "title"}}{{.InstanceName}} is now read-only{{end}}
{{define "body"}}
{{template "lead" (printf "%s's Free licence has expired." .InstanceName)}}
{{template "p" "Your servers and monitors keep running and your agents keep their keys, but changes are disabled."}}
{{template "lead" (printf "%s's Free licence has expired, so the instance is now read-only." .InstanceName)}}
{{if not .DeleteOn.IsZero}}{{template "stats" (list
(dict "big" (plural (daysUntil .DeleteOn) "day" "days") "label" "until deletion" "tone" "down")
(dict "big" (shortDate .DeleteOn) "label" "scheduled deletion" "tone" "none"))}}{{end}}
{{template "button" (dict "label" "Renew now" "url" .PortalURL)}}
{{if not .DeleteOn.IsZero}}{{template "p" (printf "If it is not renewed, the instance and everything in it will be deleted on %s." (date .DeleteOn))}}{{end}}
{{template "label" "What still works"}}
{{template "rows" (list
(dict "k" "Servers and agents" "v" "Running, keys kept")
(dict "k" "Monitors" "v" "Still checking")
(dict "k" "Changes" "v" "Disabled until renewed")
(dict "k" "Deletion" "v" (or (and (not .DeleteOn.IsZero) (date .DeleteOn)) "Not scheduled")))}}
{{template "timeline" (list
(dict "label" "Active" "date" "Ended" "state" "done")
(dict "label" "Read-only" "date" "Now" "state" "now" "tone" "down")
(dict "label" "Deleted" "date" (or (and (not .DeleteOn.IsZero) (date .DeleteOn)) "Not scheduled") "state" "next"))}}
{{if not .DeleteOn.IsZero}}{{template "callout" (dict "tone" "down" "title" "Deletion is scheduled" "text" (printf "If it is not renewed, the instance and everything in it will be deleted on %s." (date .DeleteOn)))}}{{end}}
{{end}}
{{define "why"}}the licence for {{.InstanceName}} has expired.{{end}}