From d8b0adfe978180e51f8ab7fe1281754b44b218bd Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Sat, 2 Mar 2024 18:53:35 +0800 Subject: [PATCH] Prevent embeds from playing inline --- src/components/status.css | 5 +++++ src/components/status.jsx | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/components/status.css b/src/components/status.css index 96b0d5b4..706c25ab 100644 --- a/src/components/status.css +++ b/src/components/status.css @@ -1609,6 +1609,11 @@ a.card:is(:hover, :focus):visited { .card.video { max-width: 320px; max-height: 320px; + cursor: pointer; + + lite\-youtube { + pointer-events: none; + } } .card.video iframe { width: 100%; diff --git a/src/components/status.jsx b/src/components/status.jsx index 6dc70de7..d69a0883 100644 --- a/src/components/status.jsx +++ b/src/components/status.jsx @@ -2181,7 +2181,11 @@ function Card({ card, selfReferential, instance }) { // Get ID from e.g. https://www.youtube.com/watch?v=[VIDEO_ID] const videoID = url.match(/watch\?v=([^&]+)/)?.[1]; if (videoID) { - return ; + return ( + + + + ); } } // return (