You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the crop prop is set to true, the uploaded image is cropped to fit the canvas size for the preview. However, the original, uncropped file is emitted with the Change event. Is this intended behaviour? Is there any good way to crop the actual file to the size of the canvas?
The text was updated successfully, but these errors were encountered:
Hi! Yes, that's the intended behaviour: the cropping is only for presentational purposes. If you want to get the cropped image, you need to access the underlying canvas element and use the toBlob or toDataURL methods.
If you wanna add that feature as a contribution, a PR would be welcome! :) I'd just add a cropFile boolean prop and emit a file based on canvas.toBlob instead of the original file if the prop is set to true.
If the crop prop is set to true, the uploaded image is cropped to fit the canvas size for the preview. However, the original, uncropped file is emitted with the Change event. Is this intended behaviour? Is there any good way to crop the actual file to the size of the canvas?
The text was updated successfully, but these errors were encountered: