Phase2: Invoicecomputation/AdminpricingUI/Ainvoicemgnt
Some checks failed
Build and Push / build (push) Failing after 53s
Some checks failed
Build and Push / build (push) Failing after 53s
This commit is contained in:
@@ -611,21 +611,25 @@ const InvoicePdf: React.FC<InvoicePdfProps> = ({ invoice, lines }) => {
|
|||||||
</Text>
|
</Text>
|
||||||
</View>
|
</View>
|
||||||
|
|
||||||
{/* Footer with page numbers — react-pdf supplies render fn args */}
|
{/* Footer with page numbers.
|
||||||
<View
|
react-pdf API quirks (verified against build errors):
|
||||||
style={styles.footer}
|
- The `render` callback on <View> only exposes
|
||||||
render={({ pageNumber, totalPages }) => (
|
`{ pageNumber, subPageNumber }` — no totalPages.
|
||||||
<>
|
Only <Text> gets `{ pageNumber, totalPages,
|
||||||
<Text>
|
subPageNumber, subPageTotalPages }`.
|
||||||
{BRAND.issuer.legalName} · {BRAND.issuer.web} · {BRAND.issuer.email}
|
- <Text>'s render callback must return a STRING
|
||||||
</Text>
|
(or array of strings), not JSX. */}
|
||||||
<Text>
|
<View style={styles.footer} fixed>
|
||||||
{s.page} {pageNumber} {s.of} {totalPages}
|
<Text>
|
||||||
</Text>
|
{BRAND.issuer.legalName} · {BRAND.issuer.web} · {BRAND.issuer.email}
|
||||||
</>
|
</Text>
|
||||||
)}
|
<Text
|
||||||
fixed
|
render={({ pageNumber, totalPages }) =>
|
||||||
/>
|
`${s.page} ${pageNumber} ${s.of} ${totalPages}`
|
||||||
|
}
|
||||||
|
fixed
|
||||||
|
/>
|
||||||
|
</View>
|
||||||
</Page>
|
</Page>
|
||||||
</Document>
|
</Document>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user