react-native-expo-cropper 1.2.41 → 1.2.42
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.
- package/dist/ImageCropper.js +9 -0
- package/package.json +1 -1
- package/src/ImageCropper.js +9 -0
package/dist/ImageCropper.js
CHANGED
|
@@ -1243,6 +1243,15 @@ var ImageCropper = function ImageCropper(_ref) {
|
|
|
1243
1243
|
});
|
|
1244
1244
|
case 4:
|
|
1245
1245
|
rotated = _context.v;
|
|
1246
|
+
// ✅ Send rotated image to backend: use rotated URI and dimensions so crop bbox matches
|
|
1247
|
+
sourceImageUri.current = rotated.uri;
|
|
1248
|
+
originalImageDimensions.current = {
|
|
1249
|
+
width: rotated.width,
|
|
1250
|
+
height: rotated.height
|
|
1251
|
+
};
|
|
1252
|
+
cameraFrameData.current = null; // rotated image is no longer "camera preview" frame
|
|
1253
|
+
imageSource.current = 'gallery'; // so layout callbacks run initializeCropBox() and show the white box
|
|
1254
|
+
|
|
1246
1255
|
setPoints([]);
|
|
1247
1256
|
hasInitializedCropBox.current = false;
|
|
1248
1257
|
setImage(rotated.uri);
|
package/package.json
CHANGED
package/src/ImageCropper.js
CHANGED
|
@@ -1048,6 +1048,15 @@ const rotatePreviewImage = async (degrees) => {
|
|
|
1048
1048
|
}
|
|
1049
1049
|
);
|
|
1050
1050
|
|
|
1051
|
+
// ✅ Send rotated image to backend: use rotated URI and dimensions so crop bbox matches
|
|
1052
|
+
sourceImageUri.current = rotated.uri;
|
|
1053
|
+
originalImageDimensions.current = {
|
|
1054
|
+
width: rotated.width,
|
|
1055
|
+
height: rotated.height,
|
|
1056
|
+
};
|
|
1057
|
+
cameraFrameData.current = null; // rotated image is no longer "camera preview" frame
|
|
1058
|
+
imageSource.current = 'gallery'; // so layout callbacks run initializeCropBox() and show the white box
|
|
1059
|
+
|
|
1051
1060
|
setPoints([]);
|
|
1052
1061
|
hasInitializedCropBox.current = false;
|
|
1053
1062
|
setImage(rotated.uri);
|