Watch
1
0
Fork
You've already forked nitter
0
mirror of https://github.com/zedeus/nitter synced 2026-11-22 12:57:19 +00:00

Improve gif html

This commit is contained in:
Zed 2022-06-11 23:27:11 +02:00
commit 6e490c2dd9

View file

@ -135,11 +135,9 @@ proc renderGif(gif: Gif; prefs: Prefs): VNode =
let thumb = getSmallPic(gif.thumb)
let url = getPicUrl(gif.url)
if prefs.autoplayGifs:
video(class="gif", poster=thumb, controls="", autoplay="", muted="", loop=""):
source(src=url, `type`="video/mp4")
video(src=url, class="gif", poster=thumb, controls="", muted="", loop="", playsinline="", autoplay="")
else:
video(class="gif", poster=thumb, controls="", muted="", loop=""):
source(src=url, `type`="video/mp4")
video(src=url, class="gif", poster=thumb, controls="", muted="", loop="", playsinline="")
proc renderPoll(poll: Poll): VNode =
buildHtml(tdiv(class="poll")):