import { Badge } from '@nextsparkjs/core/components/ui/badge' import Image from 'next/image' interface Category { id: string name: string color?: string } interface PostHeaderProps { post: { title: string excerpt?: string featuredImage?: string createdAt: string categories?: Category[] } } export function PostHeader({ post }: PostHeaderProps) { return (
{/* Featured Image */} {post.featuredImage && (
{post.title}
)} {/* Post Meta */}
{/* Categories */} {post.categories && post.categories.length > 0 && (
{post.categories.map((category) => ( {category.name} ))}
)} {/* Title */}

{post.title}

{/* Excerpt */} {post.excerpt && (

{post.excerpt}

)} {/* Date - using suppressHydrationWarning to prevent server/client mismatch */}
{/* Separator */}

) }