diff --git a/.changeset/add_support_for_audio_and_video_previews_in_url_previews_and_reuse_attachment_components.md b/.changeset/add_support_for_audio_and_video_previews_in_url_previews_and_reuse_attachment_components.md new file mode 100644 index 00000000..f176d8de --- /dev/null +++ b/.changeset/add_support_for_audio_and_video_previews_in_url_previews_and_reuse_attachment_components.md @@ -0,0 +1,5 @@ +--- +sable: minor +--- + +Add support for audio and video in URL previews if homeserver provides it. diff --git a/src/app/components/url-preview/UrlPreview.tsx b/src/app/components/url-preview/UrlPreview.tsx index ae970b0e..d27aa33d 100644 --- a/src/app/components/url-preview/UrlPreview.tsx +++ b/src/app/components/url-preview/UrlPreview.tsx @@ -6,13 +6,10 @@ export const UrlPreview = as<'div'>(({ className, ...props }, ref) => ( )); -export const UrlPreviewImg = as<'img'>(({ className, alt, ...props }, ref) => ( - {alt} -)); - export const UrlPreviewContent = as<'div'>(({ className, ...props }, ref) => ( - {imgUrl && ( - + {(prev['og:video'] && ( + ); };