feat: use YT thumbnail for trailer thumbnail #428

This commit is contained in:
ThaUnknown 2024-03-19 22:05:09 +01:00
parent 4ea889951b
commit 01e3bb7810

View file

@ -55,7 +55,7 @@
<div class='position-absolute w-350 h-400 absolute-container top-0 bottom-0 m-auto bg-dark-light z-30 rounded overflow-hidden pointer'>
<div class='banner position-relative bg-black'>
<img src={media.bannerImage || ' '} alt='banner' class='img-cover w-full h-full' />
<img src={media.bannerImage || `https://i.ytimg.com/vi/${media.trailer?.id}/hqdefault.jpg` || ' '} alt='banner' class='img-cover w-full h-full' />
{#if media.trailer?.id}
<div class='material-symbols-outlined filled position-absolute z-10 top-0 right-0 p-15 font-size-22' class:d-none={hide} use:click={toggleMute}>{muted ? 'volume_off' : 'volume_up'}</div>
<!-- for now we use some invidious instance, would be nice to somehow get these links outselves, this redirects straight to some google endpoint -->