diff --git a/renderer/renderer.go b/renderer/renderer.go
index 4911db9..0d6776c 100644
--- a/renderer/renderer.go
+++ b/renderer/renderer.go
@@ -1,7 +1,6 @@
package renderer
import (
- "fmt"
"io"
"regexp"
"strconv"
@@ -39,32 +38,28 @@ type TemplateData struct {
Ctx *Context
}
+func emojiHTML(e mastodon.Emoji, height string) string {
+ return ``
+}
+
func emojiFilter(content string, emojis []mastodon.Emoji) string {
var replacements []string
- var r string
for _, e := range emojis {
- r = fmt.Sprintf("",
- e.URL, e.ShortCode, e.ShortCode)
- replacements = append(replacements, ":"+e.ShortCode+":", r)
+ replacements = append(replacements, ":"+e.ShortCode+":", emojiHTML(e, "24"))
}
return strings.NewReplacer(replacements...).Replace(content)
}
var quoteRE = regexp.MustCompile("(?mU)(^|> *|\n)(>.*)(
0 {
- content = spoiler + "
" + content
+ content = spoiler + "
" + content
}
- content = quoteRE.ReplaceAllString(content, "$1$2$3")
+ content = quoteRE.ReplaceAllString(content, `$1$2$3`)
+ var replacements []string
for _, e := range emojis {
- r = fmt.Sprintf("",
- e.URL, e.ShortCode, e.ShortCode)
- replacements = append(replacements, ":"+e.ShortCode+":", r)
+ replacements = append(replacements, ":"+e.ShortCode+":", emojiHTML(e, "32"))
}
for _, m := range mentions {
replacements = append(replacements, `"`+m.URL+`"`, `"/user/`+m.ID+`" title="@`+m.Acct+`"`)