Fix link previews in posts opening /i/ instead of externally

LinkEmbed now defaults externalLink to true so link previews embedded
in post content open the URL externally as expected. Only standalone
uses of LinkPreview (like the CommentContext hover card) navigate to
the /i/ comment page.
This commit is contained in:
Alex Gleason
2026-03-22 13:58:02 -05:00
parent eb7f2d1d0d
commit e9e8104b1f
+1 -1
View File
@@ -43,7 +43,7 @@ interface LinkEmbedProps {
* - Mastodon post URLs → `MastodonEmbed` (native card via Mastodon API)
* - Everything else → `LinkPreview` (OEmbed link preview card)
*/
export function LinkEmbed({ url, className, showDiscuss = true, hideImage, externalLink }: LinkEmbedProps) {
export function LinkEmbed({ url, className, showDiscuss = true, hideImage, externalLink = true }: LinkEmbedProps) {
const youtubeId = useMemo(() => extractYouTubeId(url), [url]);
const tweetId = useMemo(() => extractTweetId(url), [url]);
const blueskyPost = useMemo(() => extractBlueskyPost(url), [url]);