diff --git a/frontend/src/app/print/page.tsx b/frontend/src/app/print/page.tsx index 4248695..da38629 100644 --- a/frontend/src/app/print/page.tsx +++ b/frontend/src/app/print/page.tsx @@ -16,7 +16,8 @@ import { formatCode } from "@/utils/format"; export type PrintMode = "list" | "grid"; -function VoucherBlock({ voucher }: { voucher: Voucher }) { +// This component represents a single voucher card to be printed +function VoucherPrintCard({ voucher }: { voucher: Voucher }) { const { wifiConfig, wifiString } = useGlobal(); return ( @@ -102,6 +103,7 @@ function VoucherBlock({ voucher }: { voucher: Voucher }) { ); } +// This component handles fetching and displaying vouchers based on URL params function Vouchers() { const router = useRouter(); const searchParams = useSearchParams(); @@ -144,12 +146,13 @@ function Vouchers() { ) : (
{vouchers.map((v) => ( - + ))}
); } +// This sets up the print page itself export default function PrintPage() { const router = useRouter();