1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-09-05 17:53:12 +02:00

fix: video

This commit is contained in:
FredrikOseberg 2025-08-14 14:20:36 +02:00
parent 33e6530b93
commit 36db02d4ab
No known key found for this signature in database
GPG Key ID: 282FD8A6D8F9BCF0
2 changed files with 5 additions and 4 deletions

View File

@ -34,12 +34,14 @@ const LazyVideo = ({ url, title = 'YouTube video player' }) => {
onKeyDown={(e) => e.key === 'Enter' && handleLoad()}
role='button'
tabIndex={0}
style={{
backgroundImage: `url(https://img.youtube.com/vi/${videoId}/maxresdefault.jpg)`,
}}
aria-label={`Load ${title}`}
style={{ width: '414px', height: '232px' }}
>
{/* Play button overlay */}
<img
src={`https://img.youtube.com/vi/${videoId}/maxresdefault.jpg`}
fetchPriority='high'
/>
<div className={styles.playButton}>
<svg
width='32'

View File

@ -133,7 +133,6 @@ export default function Root({ children }: { children: React.ReactNode }) {
});
return () => {
clearTimeout(fallbackTimer);
window.removeEventListener('scroll', handleUserInteraction);
window.removeEventListener('click', handleUserInteraction);
window.removeEventListener('touchstart', handleUserInteraction);