avoid breaks

This commit is contained in:
Andreas Knuth 2026-02-27 10:44:00 -06:00
parent b90a2a6340
commit 8ce739d713
3 changed files with 10 additions and 2 deletions

View File

@ -1374,7 +1374,7 @@ app.get('/api/invoices/:id/pdf', async (req, res) => {
if (amountPaid > 0) { if (amountPaid > 0) {
itemsHTML += ` itemsHTML += `
<tr class="footer-row"> <tr class="footer-row">
<td colspan="3" class="total-label" style="font-size: 12px; color: #059669;">Less: Payment received:</td> <td colspan="3" class="total-label" style="font-size: 12px; color: #059669;">Downpayment:</td>
<td class="total-amount" style="font-size: 12px; color: #059669;">-$${amountPaid.toFixed(2)}</td> <td class="total-amount" style="font-size: 12px; color: #059669;">-$${amountPaid.toFixed(2)}</td>
</tr> </tr>
<tr class="footer-row"> <tr class="footer-row">
@ -1617,7 +1617,7 @@ app.get('/api/invoices/:id/html', async (req, res) => {
if (amountPaid > 0) { if (amountPaid > 0) {
itemsHTML += ` itemsHTML += `
<tr class="footer-row"> <tr class="footer-row">
<td colspan="3" class="total-label" style="font-size: 12px; color: #059669;">Less: Payment received:</td> <td colspan="3" class="total-label" style="font-size: 12px; color: #059669;">Downpayment:</td>
<td class="total-amount" style="font-size: 12px; color: #059669;">-$${amountPaid.toFixed(2)}</td> <td class="total-amount" style="font-size: 12px; color: #059669;">-$${amountPaid.toFixed(2)}</td>
</tr> </tr>
<tr class="footer-row"> <tr class="footer-row">

View File

@ -206,6 +206,10 @@
position: absolute; position: absolute;
bottom: 0; bottom: 0;
} }
tr {
page-break-inside: avoid;
break-inside: avoid;
}
</style> </style>
</head> </head>
<body> <body>

View File

@ -202,6 +202,10 @@
position: absolute; position: absolute;
bottom: 0; bottom: 0;
} }
tr {
page-break-inside: avoid;
break-inside: avoid;
}
</style> </style>
</head> </head>
<body> <body>