import { FeedItemCard } from '@/components/feed/FeedItemCard';
import { FeedEmptyState } from '@/ui/FeedEmptyState';
import React from 'react';

interface FeedItemData {
  id: string;
  type: string;
  headline: string;
  body?: string;
  timestamp: string;
  formattedTime: string;
  ctaHref?: string;
  ctaLabel?: string;
}

interface FeedListProps {
  items: FeedItemData[];
}

export function FeedList({ items }: FeedListProps) {
  if (!items.length) {
    return <FeedEmptyState />;
  }

  return (
    <div style={{ display: 'flex', flexDirection: 'column', gap: '1rem' }}>
      {items.map(item => (
        <FeedItemCard key={item.id} item={item} />
      ))}
    </div>
  );
}
