From 05af1a3aff71e93c0d8f331fd0aba59ccb70f1f9 Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Sat, 18 Apr 2026 18:11:21 +0000 Subject: [PATCH] Changes Co-authored-by: renee-png <262607627+renee-png@users.noreply.github.com> --- src/routes/invoices.$invoiceId.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/routes/invoices.$invoiceId.tsx b/src/routes/invoices.$invoiceId.tsx index 9e4c6ef..d12784c 100644 --- a/src/routes/invoices.$invoiceId.tsx +++ b/src/routes/invoices.$invoiceId.tsx @@ -245,6 +245,11 @@ function InvoiceDetail() { total: Number(invoice.total), paid: Number(invoice.amount_paid), balance, + taxRatePct: + Number(invoice.subtotal) > 0 + ? Math.round((Number(invoice.tax) / Number(invoice.subtotal)) * 10000) / 100 + : 0, + feesAndExpenses: Number(invoice.subtotal), }, }; await downloadInvoicePdf(input, `${invoice.invoice_number}.pdf`);