import { Metadata } from "next"; import { Header } from "@/components/header"; import { Card, CardContent } from "@/components/ui/card"; import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar"; import Link from "next/link"; import { getPosts } from "@/lib/blog-query"; import Image from "next/image"; export const metadata: Metadata = { title: "Blog - OpenCut", description: "Read the latest news and updates about OpenCut, the free and open-source video editor.", openGraph: { title: "Blog - OpenCut", description: "Read the latest news and updates about OpenCut, the free and open-source video editor.", type: "website", }, }; export default async function BlogPage() { const data = await getPosts(); if (!data || !data.posts) return
No posts yet
; return (

Blog

Read the latest news and updates about OpenCut, the free and open-source video editor.

{data.posts.map((post) => ( {post.coverImage && (
{post.title}
)} {post.authors && post.authors.length > 0 && (
{post.authors.map((author, index) => (
{author.name.charAt(0).toUpperCase()} {author.name} {index < post.authors.length - 1 && ( )}
))}
)}

{post.title}

{post.description}

))}
); }