feat: Updated email templates
This commit is contained in:
@@ -1,18 +1,23 @@
|
||||
{{- /*
|
||||
The plain-text counterpart of layout.html.tmpl.
|
||||
|
||||
It defines the same helper names - p, lead, button, well, note, rows, chip -
|
||||
so a message's txt file reads as the same document as its html one, and a
|
||||
helper added on one side is obvious by its absence on the other.
|
||||
It defines the same helper names - p, lead, small, label, divider, button,
|
||||
well, note, rows, chip, callout, steps, stats, timeline - so a message's txt
|
||||
file reads as the same document as its html one, and a helper added on one
|
||||
side is obvious by its absence on the other.
|
||||
|
||||
"subject" is defined here rather than in the HTML file: html/template would
|
||||
escape an ampersand in an instance name, and mail clients show subject lines
|
||||
verbatim.
|
||||
"subject" and "tone" are defined here rather than in the HTML file:
|
||||
html/template would escape an ampersand in an instance name, and mail
|
||||
clients show subject lines verbatim. tone is read once per render and handed
|
||||
to both layouts through the tone func.
|
||||
*/ -}}
|
||||
{{- define "subject"}}Vantage{{end -}}
|
||||
{{- define "tone"}}accent{{end -}}
|
||||
{{- define "title"}}{{end -}}
|
||||
{{- define "pill"}}{{end -}}
|
||||
{{- define "body"}}{{end -}}
|
||||
{{- define "category"}}Account{{end -}}
|
||||
{{- define "why"}}it relates to your Vantage account.{{end -}}
|
||||
|
||||
{{- define "p"}}{{.}}
|
||||
|
||||
@@ -20,8 +25,16 @@
|
||||
{{- define "lead"}}{{.}}
|
||||
|
||||
{{end -}}
|
||||
{{- define "button"}}{{.label}}:
|
||||
{{- define "small"}}{{.}}
|
||||
|
||||
{{end -}}
|
||||
{{- define "label"}}{{upper .}}
|
||||
|
||||
{{end -}}
|
||||
{{- define "divider"}}----------------------------------------
|
||||
|
||||
{{end -}}
|
||||
{{- define "button"}}{{.label}}:
|
||||
{{.url}}
|
||||
|
||||
{{end -}}
|
||||
@@ -31,16 +44,38 @@
|
||||
{{- define "note"}}{{.}}
|
||||
|
||||
{{end -}}
|
||||
{{- define "rows"}}{{range .}}{{.k}}: {{.v}}
|
||||
{{- define "rows"}}{{range .}} {{.k}}: {{.v}}
|
||||
{{end}}
|
||||
{{end -}}
|
||||
{{- define "chip"}}[{{upper .label}}]
|
||||
{{- define "chip"}}[{{upper .label}}]{{end -}}
|
||||
{{- define "callout"}}>> {{.title}}
|
||||
{{.text}}
|
||||
|
||||
{{end -}}
|
||||
VANTAGE
|
||||
{{- define "steps"}}{{range $i, $s := .}} {{add $i 1}}. {{$s.t}}
|
||||
{{$s.d}}
|
||||
{{end}}
|
||||
{{end -}}
|
||||
{{- define "stats"}}{{range .}} {{.label}}: {{.big}}
|
||||
{{end}}
|
||||
{{end -}}
|
||||
{{- define "timeline"}}{{range .}} {{if eq .state "done"}}[x]{{else if eq .state "now"}}[>]{{else}}[ ]{{end}} {{.label}}: {{.date}}
|
||||
{{end}}
|
||||
{{end -}}
|
||||
{{- define "findings"}}{{range .}} - {{.CVEID}} [{{upper .Severity}}] {{.PackageName}} on {{.ServerName}}, {{if .FixedIn}}fixed in {{.FixedIn}}{{else}}no fix published yet{{end}}
|
||||
{{end}}
|
||||
{{end -}}
|
||||
VANTAGE · {{template "category" .}}
|
||||
|
||||
{{template "pill" .}}
|
||||
{{template "title" .}}
|
||||
========================================
|
||||
|
||||
{{template "body" .}}
|
||||
--
|
||||
Sent by Vantage · infrastructure control plane
|
||||
----------------------------------------
|
||||
Why you got this: {{template "why" .}}
|
||||
{{with hq}}
|
||||
Vantage HQ: {{.}}
|
||||
Billing: {{.}}/billing
|
||||
{{end}}
|
||||
Vantage · infrastructure control plane
|
||||
|
||||
Reference in New Issue
Block a user