templates/themes/ansi/notification.tmpl
author Mikael Berthe <mikael@lilotux.net>
Mon, 08 May 2017 00:46:02 +0200
changeset 99 a179dc99a044
parent 88 028f7b02bd3e
child 117 e742059aa3e1
permissions -rw-r--r--
Update templates
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
76
f155f9d86832 Fix in_reply_to ID format in templates
Mikael Berthe <mikael@lilotux.net>
parents: 61
diff changeset
     1
- Notification ID: {{color "red"}}{{printf "%.0f" .id}}{{color "reset"}}
60
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
     2
  Type: {{color ",,bold"}}{{.type}}{{color "reset"}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
     3
  Timestamp: {{.created_at}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
     4
{{- with .url}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
     5
      URL: {{.url}}{{end}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
     6
{{- with .account}}
76
f155f9d86832 Fix in_reply_to ID format in templates
Mikael Berthe <mikael@lilotux.net>
parents: 61
diff changeset
     7
  - Account: ({{printf "%.0f" .id}}) {{color "magenta"}}@{{.acct}}{{color "reset"}}{{if .display_name}} - {{color "white,,bold"}}{{.display_name}}{{color "reset"}}{{end}}{{end}}
60
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
     8
{{- with .status}}
76
f155f9d86832 Fix in_reply_to ID format in templates
Mikael Berthe <mikael@lilotux.net>
parents: 61
diff changeset
     9
  - Status ID: {{color "red"}}{{printf "%.0f" .id}}{{color "reset"}}  {{color "magenta"}}@{{.account.acct}}{{color "reset"}}
60
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    10
    Name: {{color ",,bold"}}{{.account.display_name}}{{color "reset"}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    11
    Date: {{.created_at}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    12
    URL: {{.url}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    13
{{- if .reblog }}{{with .reblog}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    14
    {{color ",,bold"}}Reblogged from: {{color "magenta"}}@{{.account.acct}}{{color "reset"}}
76
f155f9d86832 Fix in_reply_to ID format in templates
Mikael Berthe <mikael@lilotux.net>
parents: 61
diff changeset
    15
      ID: {{printf "%.0f" .id}}
60
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    16
      Name: {{color ",,bold"}}{{.account.display_name}}{{color "reset"}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    17
      Date: {{.created_at}}
78
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    18
{{- if gt .in_reply_to_id 0.0}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    19
      Replying to: {{.in_reply_to_id}}{{end}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    20
{{- if .sensitive}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    21
      Sensitive: true{{end}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    22
{{- with .spoiler_text}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    23
      Spoiler: {{.}}{{end}}
99
a179dc99a044 Update templates
Mikael Berthe <mikael@lilotux.net>
parents: 88
diff changeset
    24
      Message: {{color "blue"}}{{.content | fromhtml | wrap "     " 80 | trim}}{{color "reset"}}{{end}}{{else}}
78
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    25
{{- if gt .in_reply_to_id 0.0}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    26
    Replying to: {{.in_reply_to_id}}{{end}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    27
{{- if .sensitive}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    28
  Sensitive: true{{end}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    29
{{- with .spoiler_text}}
b40bc3a8b572 Update ANSI templates
Mikael Berthe <mikael@lilotux.net>
parents: 76
diff changeset
    30
    Spoiler: {{.}}{{end}}
99
a179dc99a044 Update templates
Mikael Berthe <mikael@lilotux.net>
parents: 88
diff changeset
    31
    Message: {{color "blue"}}{{.content | fromhtml | wrap "     " 80 | trim}}{{color "reset"}}
60
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    32
{{- range .media_attachments}}
76
f155f9d86832 Fix in_reply_to ID format in templates
Mikael Berthe <mikael@lilotux.net>
parents: 61
diff changeset
    33
    - Attachment ID: {{printf "%.0f" .id}}
60
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    34
{{- if .text_url}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    35
      Text URL: {{.text_url}}{{else if .url}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    36
      URL: {{.url}}{{else if .remote_url}}
1ca78111de77 Add template for notifications
Mikael Berthe <mikael@lilotux.net>
parents:
diff changeset
    37
      Remote URL: {{.remote_url}}{{end}}{{end}}{{end}}{{end}}