ivpusic / react-native-image-crop-picker

iOS/Android image picker with support for camera, video, configurable compression, multiple images and cropping
MIT License
6.14k stars 1.56k forks source link

ios bug(Call the selection picture on the iOS platform, it will pop up the first time, but not the second time) #1334

Open zengqinghua1 opened 4 years ago

zengqinghua1 commented 4 years ago

ImagePicker.openPicker({ // cropperActiveWidgetColor: '#36B7AB', cropperStatusBarColor: '#36B7AB', cropperToolbarColor: '#36B7AB',
// cropperCircleOverlay: true, width: 400, height: 400, cropping: true }).then(image => {

            console.log(image)
        });
mrminhhuy commented 4 years ago

hi, Maybe your ImagePicker inside to Modal parent

michaelmika commented 4 years ago

This issue is described poorly. Please make more effort to explain what's happening, when, etc. Also, check if your code is formatted correctly.

If you are also experiencing that the Picker is opening and closing immediately, check the parent component and it's lifecycle. If it is for example React Native's Modal component (as @codebetterme suggests), check that the modal is not closed before the callback function is triggered. In your case, the modal should be closed after your console.log(image) printing.

wanderlust252 commented 3 years ago

i have this issue too