import React from 'react'; interface LineItem { label: string; qty: number; priceCents: number; } interface OrderSummaryProps { lineItems: LineItem[]; subtotalCents: number; taxCents: number; totalCents: number; } const formatCurrency = (cents: number) => { return new Intl.NumberFormat('de-DE', { style: 'currency', currency: 'EUR', }).format(cents / 100); }; export default function OrderSummary({ lineItems, subtotalCents, taxCents, totalCents, }: OrderSummaryProps) { return (
| Artikel | Preis |
|---|---|
| {item.qty}× {item.label} | {formatCurrency(item.qty * item.priceCents)} |