import { Play, Volume2, MoreVertical, Clock } from 'lucide-react' export default function AudioPostCard({ post, onPlay }) { const formatDate = (dateString) => { const date = new Date(dateString) const now = new Date() const diffMs = now - date const diffMins = Math.floor(diffMs / 60000) if (diffMins < 60) return `${diffMins}m ago` if (diffMins < 1440) return `${Math.floor(diffMins / 60)}h ago` return `${Math.floor(diffMins / 1440)}d ago` } return (
{/* Post Header */}

{post.title}

{post.visibility === 'private' && ( Private )}
{formatDate(post.created_at)} {post.status}
{/* Description */} {post.description && (

{post.description}

)} {/* Audio Player - Only show if ready */} {post.status === 'ready' && (
0:00 --:--
)} {/* Processing Status */} {post.status === 'processing' && (

Processing audio and generating transcript...

)} {/* Failed Status */} {post.status === 'failed' && (

Failed to process this recording. Please try uploading again.

)} {/* Language Tag */} {post.language && (
{post.language.toUpperCase()}
)}
) }