fix: fixing og page detail video

This commit is contained in:
Sabda Yagra 2025-10-08 11:34:15 +07:00
parent 405455ea1f
commit 3e920e9108
1 changed files with 23 additions and 1 deletions

View File

@ -35,10 +35,32 @@ export async function generateMetadata({ params }: any): Promise<Metadata> {
return { return {
title: video.title, title: video.title,
description: video.description, description: video.description,
// openGraph: {
// title: video?.title,
// description: video?.description,
// videos: [`${video?.smallThumbnailLink}`],
// },
openGraph: { openGraph: {
title: video?.title, title: video?.title,
description: video?.description, description: video?.description,
videos: [`${video?.smallThumbnailLink}`], url: `https://mediahub.polri.go.id/in/video/detail/${slug}`,
type: "video.other",
images: [
{
url: video?.thumbnailLink,
width: 1280,
height: 720,
alt: video?.title || "Thumbnail Mediahub Polri",
},
],
},
twitter: {
card: "summary_large_image",
title: video?.title,
description: video?.description,
images: [
video?.thumbnailLink,
],
}, },
}; };
} }