mirror of
https://github.com/documenso/documenso.git
synced 2026-07-10 21:15:15 +10:00
fix: checkbox states not showing in signed PDF for legacy uploads
Flatten the pdf-lib form before saving to bake checkbox/radio appearances into the PDF content. This ensures checked states are preserved when the PDF is subsequently processed by libpdf for final signing.
This commit is contained in:
@@ -388,6 +388,11 @@ const decorateAndSignPdf = async ({
|
||||
}
|
||||
}
|
||||
|
||||
// Flatten the form to bake checkbox/radio appearances into the PDF content
|
||||
// This ensures proper rendering when the PDF is processed by libpdf
|
||||
const form = legacy_pdfLibDoc.getForm();
|
||||
form.flatten();
|
||||
|
||||
await pdfDoc.reload(await legacy_pdfLibDoc.save());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user