I am trying to use react-native-image-crop-picker but only on Redmi Phones with Android 11. It is restarting the application when an image is selected from openCamera functionality with wide mode only (normal camera click works), the Application restarts again navigating to the splash screen.
Here is the code I am using for openCamera.
ImagePicker.openCamera({
width: 1280,
height: 720,
cropping: true,
includeBase64: true,
freeStyleCropEnabled: true,
forceJpg: true,
mediaType: 'photo',
compressImageQuality: 0.5,
})
.then(image => {
// Using image.path to upload to Server
})
.catch(error => {
// Firebase crashlytic used but no error logs
crashlytics().log(error.message);
crashlytics().recordError(this.props.error);
});
Packages:
"react-native": "0.63.4"
"react-native-image-crop-picker": "0.37.2"
Android:
com.android.tools.build:gradle:4.2.2
gradle-6.9-all