aboutsummaryrefslogtreecommitdiff
path: root/renderer
diff options
context:
space:
mode:
authorr <r@freesoftwareextremist.com>2020-05-24 05:46:54 +0000
committerr <r@freesoftwareextremist.com>2020-05-24 05:57:01 +0000
commitf3367d920d151727bf5703a364c7d39ae24071d7 (patch)
tree943941882af4b47131eaa4fb510df2abc6256d3c /renderer
parentfd2a353770a5f3cea773a5c4465bf0fc2a2818d3 (diff)
downloadbloat-f3367d920d151727bf5703a364c7d39ae24071d7.tar.gz
bloat-f3367d920d151727bf5703a364c7d39ae24071d7.zip
Imporve emoji style
- Increase emoji size - Add colons to emoji alt text and title
Diffstat (limited to 'renderer')
-rw-r--r--renderer/renderer.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/renderer/renderer.go b/renderer/renderer.go
index 41b3ea4..4d35ba7 100644
--- a/renderer/renderer.go
+++ b/renderer/renderer.go
@@ -40,7 +40,7 @@ func emojiFilter(content string, emojis []mastodon.Emoji) string {
var replacements []string
var r string
for _, e := range emojis {
- r = fmt.Sprintf("<img class=\"status-emoji\" src=\"%s\" alt=\"%s\" title=\"%s\" />",
+ r = fmt.Sprintf("<img class=\"emoji\" src=\"%s\" alt=\":%s:\" title=\":%s:\" />",
e.URL, e.ShortCode, e.ShortCode)
replacements = append(replacements, ":"+e.ShortCode+":", r)
}
@@ -56,7 +56,7 @@ func statusContentFilter(spoiler string, content string,
content = spoiler + "<br />" + content
}
for _, e := range emojis {
- r = fmt.Sprintf("<img class=\"status-emoji\" src=\"%s\" alt=\"%s\" title=\"%s\" />",
+ r = fmt.Sprintf("<img class=\"emoji\" src=\"%s\" alt=\":%s:\" title=\":%s:\" />",
e.URL, e.ShortCode, e.ShortCode)
replacements = append(replacements, ":"+e.ShortCode+":", r)
}