import { eq } from 'drizzle-orm'; import { notFound } from 'next/navigation'; import Link from 'next/link'; import { ArrowLeft } from 'lucide-react'; import { db, getDeck, schema } from '@linkder/db'; import { DeckClient } from './deck-client'; export const dynamic = 'force-dynamic'; export default async function DeckPage({ params }: { params: Promise<{ jobId: string }> }) { const { jobId } = await params; const job = await db.query.jobs.findFirst({ where: eq(schema.jobs.id, jobId), with: { category: true }, }); if (!job) notFound(); const cards = await getDeck(db, { jobId }); return (
Back

{job.category.name} ยท {job.addressText}

{job.title}

Swipe right to send this job to a pro, left to pass. Drag the card or use the buttons.

); }