async function saveZipFile() {
const theZip = zip();
theZip.file("document.pdf", await pdfDocument.getData());
theZip.file("rects.json", JSON.stringify( rects.sort(function(a, b){return a.y - b.y})));
var audios = DictaphoneObj.getAudios();
for (let i in audios){
console.log("audio", fetch(audios[i].src).then(res => res.blob()));
theZip.file(`${i}.ogg`, fetch(audios[i].src).then(res => res.blob()));
}
const blob = await theZip.generateAsync({ type: "blob" });
const link = document.createElement("a");
link.href = window.URL.createObjectURL(blob);
link.download = `annotatedPdf.zip`;
link.click();
}