---
import AdminLayout from '../../../layouts/AdminLayout.astro';
import CollectionTable from '../../../components/admin/CollectionTable';
---

<AdminLayout title="Generation Queue">
  <div class="space-y-6">
    <div class="flex justify-between items-center">
      <div>
        <h1 class="text-3xl font-bold text-gold-500">⚙️ Generation Jobs</h1>
        <p class="text-gray-400 mt-1">Content generation queue monitoring</p>
      </div>
      <div class="flex gap-3">
        <button class="px-4 py-2 bg-graphite border border-edge-normal rounded-lg text-sm hover:bg-jet" onclick="location.reload()">
          🔄 Refresh
        </button>
      </div>
    </div>

    <CollectionTable
      endpoint="/api/collections/generation_jobs"
      columns={['job_type', 'status', 'created_at']}
      title="Jobs Queue"
      client:load
    />
  </div>
</AdminLayout>
