html2canvas-pro 2.3.8 → 2.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * html2canvas-pro 2.3.8 <https://yorickshan.github.io/html2canvas-pro/>
2
+ * html2canvas-pro 2.3.9 <https://yorickshan.github.io/html2canvas-pro/>
3
3
  * Copyright (c) 2024-present yorickshan and html2canvas-pro contributors
4
4
  * Released under MIT License
5
5
  */
@@ -10598,11 +10598,13 @@ var CanvasRenderer = class CanvasRenderer {
10598
10598
  }
10599
10599
  mask(paths) {
10600
10600
  this.ctx.beginPath();
10601
- this.ctx.moveTo(0, 0);
10602
- this.ctx.lineTo(this.options.width, 0);
10603
- this.ctx.lineTo(this.options.width, this.options.height);
10604
- this.ctx.lineTo(0, this.options.height);
10605
- this.ctx.lineTo(0, 0);
10601
+ const x = this.options.x;
10602
+ const y = this.options.y;
10603
+ this.ctx.moveTo(x, y);
10604
+ this.ctx.lineTo(x + this.options.width, y);
10605
+ this.ctx.lineTo(x + this.options.width, y + this.options.height);
10606
+ this.ctx.lineTo(x, y + this.options.height);
10607
+ this.ctx.lineTo(x, y);
10606
10608
  this.formatPath(paths.slice(0).reverse());
10607
10609
  this.ctx.closePath();
10608
10610
  }