add high res thumbnail
This commit is contained in:
parent
d418b429aa
commit
dc164fd377
@ -381,6 +381,8 @@ class MainHandler(tornado.web.RequestHandler):
|
||||
meta = await handler.meta()
|
||||
image = meta.get("og:image")
|
||||
if isinstance(image, str):
|
||||
if handler.provider == "youtube":
|
||||
image = image.removesuffix("hqdefault.jpg") + "maxresdefault.jpg"
|
||||
url = await handler.proxy.proxy_url(image, None)
|
||||
if isinstance(url, str):
|
||||
self.redirect(url, status=303)
|
||||
|
@ -18,6 +18,11 @@
|
||||
return url.href;
|
||||
}
|
||||
|
||||
const getProvider = () => {
|
||||
const search = new URLSearchParams(location.search);
|
||||
return search.get("provider");
|
||||
}
|
||||
|
||||
const upstream = findUpstreamVideo();
|
||||
const xhr = new XMLHttpRequest();
|
||||
xhr.open("HEAD", upstream, true);
|
||||
@ -47,7 +52,9 @@
|
||||
options.plugins.chromecast = {};
|
||||
options.plugins.chromecast.addButtonToControlBar = false;
|
||||
const player = videojs(video, options);
|
||||
if(getProvider() !== "nextcloud") {
|
||||
player.poster(findUpstreamPoster());
|
||||
}
|
||||
const source = {};
|
||||
source.type = ctype;
|
||||
source.src = upstream;
|
||||
|
Loading…
Reference in New Issue
Block a user