UI cleanup and changes

This commit is contained in:
video-prize-ranch
2022-10-13 17:29:05 -04:00
parent 7cad41e11d
commit 50d71ad321
9 changed files with 57 additions and 35 deletions

View File

@@ -92,6 +92,8 @@ func ParseComment(data gjson.Result) Comment {
comment := data.Get("comment").String()
comment = strings.ReplaceAll(comment, "\n", "<br>")
for _, match := range imgRe.FindAllString(comment, -1) {
img := iImgurRe.ReplaceAllString(match, "")
img = `<img src="` + img + `" class="comment__media" loading="lazy"/>`