@seniorsistemas/angular-components 17.3.6 → 17.3.7

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.
@@ -12725,6 +12725,13 @@ var ImageCropperComponent = /** @class */ (function () {
12725
12725
  this.croppedCanvas.emit();
12726
12726
  }
12727
12727
  else {
12728
+ //hack to fix images if canvas doesnt match image (for mobile, tablets, etc)
12729
+ if (this.cropper.getCanvasData().height !== this.cropper.getImageData().height) {
12730
+ this.cropper.getImageData().scaleY = this.cropper.getImageData().height / this.cropper.getCanvasData().height;
12731
+ }
12732
+ if (this.cropper.getCanvasData().width !== this.cropper.getImageData().width) {
12733
+ this.cropper.getImageData().scaleX = this.cropper.getImageData().width / this.cropper.getCanvasData().width;
12734
+ }
12728
12735
  var _croppedCanvas = this.rounded
12729
12736
  ? this.getRoundedCanvas(this.cropper.getCroppedCanvas())
12730
12737
  : this.cropper.getCroppedCanvas();