"use client"; import { useTranslations } from "next-intl"; import { StatusBadge } from "./StatusBadge"; import type { Redemption } from "@/lib/afc"; interface RedemptionHistoryTableProps { redemptions: Redemption[]; } export function RedemptionHistoryTable({ redemptions }: RedemptionHistoryTableProps) { const t = useTranslations("afc"); if (redemptions.length === 0) { return (

{t("no_redemptions")}

); } return (
{redemptions.map((r) => ( ))}
{t("date")} {t("prize")} AFC {t("status")}
{new Date(r.created_at).toLocaleDateString()} {r.prize_detail} -{r.amount_afc}
); }