updated width
This commit is contained in:
parent
8ff84963f2
commit
b7276d4714
2 changed files with 6 additions and 1 deletions
|
|
@ -4,6 +4,7 @@
|
|||
bottom: 20px;
|
||||
right: 20px;
|
||||
padding: 20px;
|
||||
min-width: 1300px;
|
||||
}
|
||||
|
||||
h1 {
|
||||
|
|
|
|||
|
|
@ -2,12 +2,16 @@ window.onload = function() {
|
|||
document.getElementById("download-pdf")
|
||||
.addEventListener("click", () => {
|
||||
const pdf_version = this.document.getElementById("body");
|
||||
const button = this.document.getElementById("download-pdf");
|
||||
button.style.display = 'block'
|
||||
|
||||
console.log(pdf_version);
|
||||
console.log(window);
|
||||
var opt = {
|
||||
margin: 0,
|
||||
filename: 'myfile.pdf',
|
||||
image: { type: 'jpeg', quality: 0.98 },
|
||||
html2canvas: { scale: 2, letterRendering: true },
|
||||
html2canvas: { scale: 2, letterRendering: true, width: 1300 },
|
||||
jsPDF: { format: 'a4', orientation: 'portrait' },
|
||||
};
|
||||
html2pdf().from(pdf_version).set(opt).save();
|
||||
|
|
|
|||
Loading…
Reference in a new issue