Skip to content

Commit

Permalink
fix: bug of export PDF of correct size (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
JinIgarashi authored Jul 14, 2023
1 parent 21304d6 commit fc5adb2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/slow-donuts-speak.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@watergis/maplibre-gl-export": patch
---

fix: fixed the bug of export PDF of A3 size spondered by @PivnoyBaronDmitry through the PR of https://github.com/watergis/mapbox-gl-export/pull/48
3 changes: 2 additions & 1 deletion packages/maplibre-gl-export/src/lib/map-generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,8 @@ export default class MapGenerator {
const pdf = new jsPDF({
orientation: this.width > this.height ? 'l' : 'p',
unit: this.unit,
compress: true
compress: true,
format: [this.width, this.height]
});

pdf.addImage(
Expand Down

0 comments on commit fc5adb2

Please sign in to comment.