1
0
Fork 0
mirror of https://github.com/24eme/signaturepdf synced 2024-06-03 14:32:13 +02:00

fix enregistrement

This commit is contained in:
Gabriel Poma 2023-04-20 15:11:33 +02:00
parent 784e15f252
commit 4f4d3a0583

View file

@ -127,10 +127,9 @@ const save = async function () {
const arrayBuffer = await pdffile.arrayBuffer()
const pdf = await PDFDocument.load(arrayBuffer)
console.log(pdf.getInfoDict())
pdf.getInfoDict().set(PDFName.of('fooMetadata'), PDFHexString.fromText("test de métadonéé"))
const newPDF = new Blob([pdf.save()], {type: "application/pdf"})
const newPDF = new Blob([await pdf.save()], {type: "application/pdf"})
DL = function (d,f) {
let a = document.createElement("a"),
u = URL.createObjectURL(d);