import FeedEmptyState from '@/components/feed/FeedEmptyState';
import FeedItemCard from '@/components/feed/FeedItemCard';
import type { FeedItem } from '@gridpilot/social/domain/entities/FeedItem';

interface FeedListProps {
  items: FeedItem[];
}

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

  return (
    <div className="space-y-4">
      {items.map(item => (
        <FeedItemCard key={item.id} item={item} />
      ))}
    </div>
  );
}