Proxy media instead of using file cache
This commit is contained in:
@@ -36,7 +36,7 @@
|
||||
<img src="https://${hostname}${getPicUrl(get(tweet.video).thumb)}" style="max-width:250px;" />
|
||||
#elif tweet.gif.isSome:
|
||||
#let thumb = &"https://{hostname}{getPicUrl(get(tweet.gif).thumb)}"
|
||||
#let url = &"https://{hostname}{getGifUrl(get(tweet.gif).url)}"
|
||||
#let url = &"https://{hostname}{getPicUrl(get(tweet.gif).url)}"
|
||||
<video poster="${thumb}" autoplay muted loop style="max-width:250px;">
|
||||
<source src="${url}" type="video/mp4"</source></video>
|
||||
#end if
|
||||
|
||||
@@ -107,7 +107,7 @@ proc renderGif(gif: Gif; prefs: Prefs): VNode =
|
||||
tdiv(class="gallery-gif", style={maxHeight: "unset"}):
|
||||
tdiv(class="attachment"):
|
||||
let thumb = getPicUrl(gif.thumb)
|
||||
let url = getGifUrl(gif.url)
|
||||
let url = getPicUrl(gif.url)
|
||||
if prefs.autoplayGifs:
|
||||
video(class="gif", poster=thumb, controls="", autoplay="", muted="", loop=""):
|
||||
source(src=url, `type`="video/mp4")
|
||||
|
||||
Reference in New Issue
Block a user