React-native-image-crop-picker: Unable to use openCropper on iOS

Created on 17 Jan 2020  路  3Comments  路  Source: ivpusic/react-native-image-crop-picker

Version

  • react-native-image-crop-picker v0.26.2
  • react-native v0.61.5

Platform

iOS

Expected behaviour

Calling ImagePikcer.openCropper displays the image specified in the path property to allow the user to specify the area to be cropped to.

Actual behaviour

Image flashes on the screen and then disappears.

Steps to reproduce

  1. Call ImagePicker.openPicker({ mediaType: 'phot', writeTempfile: true, includeExif: true })

  2. Within step #1's then statement, call ImagePicker.openCropper({ path: (image as PickerImage).path, width: 400, height: 400, writeTempFile: true, includeExif: true })

Attachments

No errors are presented, the image just pops up and then disappears

Most helpful comment

@dragma for me, the issue was that I was closing the modal too soon. I was calling open Picker and in the then block I closed the modal and called open Cropper. Moving the close modal command down to the then block of the open Cropper allowed it to stay open.

All 3 comments

Same here, with openCamera and openPicker, in iOS only.
The call is made in a plain page with nothing tricky or fancy.
@leelandclay Did you find any solution or cause to this ?

@dragma for me, the issue was that I was closing the modal too soon. I was calling open Picker and in the then block I closed the modal and called open Cropper. Moving the close modal command down to the then block of the open Cropper allowed it to stay open.

@leelandclay genius ! That was it for me too. Thanks a lot !

Was this page helpful?
0 / 5 - 0 ratings

Related issues

xuchao321 picture xuchao321  路  3Comments

althurzard picture althurzard  路  3Comments

habovh picture habovh  路  3Comments

zhangjunhou picture zhangjunhou  路  3Comments

sergiulucaci picture sergiulucaci  路  3Comments