react-native-qrcode-scanner icon indicating copy to clipboard operation
react-native-qrcode-scanner copied to clipboard

trouble on camera after scanning code

Open hanaechahid opened this issue 5 years ago • 3 comments

What's happening?

After the qrcode is scanning and the app go to the next screen, the camera do something like zig zag only on the android, on ios works well.

How can it be reproduced?

` constructor(props) { super(props); this.state = { acitivateCam: false, dialogVisible: false, reactivate: false }; }

// On sucess onSuccess(e) { this.props.searchUserGlobal({ data: { qrcode: e.data }, success: data => { if (data.length > 0) { let userID = data[0].id; this.props.detialUser({ userID: userID, success: userDetailData => { if (userDetailData.roles === undefined) { userDetailData.roles = []; } this.props.navigation.navigate("ProfileStatus", { user: userDetailData, config: this.props.config.payload }); }, error: error => { alert(error); } }); } else { setTimeout(() => { alert(translate("not_found")); }, 600); } }, error: () => { setTimeout(() => { this.scanner.reactivate(); alert(translate("not_found")); }, 600); } }); } <QRCodeScanner onRead={this.onSuccess.bind(this)} ref={node => { this.scanner = node; }} showMarker={true} reactivateTimeout={400} reactivate={true} fadeIn={false} vibrate={true} cameraProps={{ captureAudio: false }} />

Build details?

device: android react-native-camera: "^2.1.1" react-native-qrcode-scanner: "^1.0.1"

hanaechahid avatar Jan 29 '20 12:01 hanaechahid

@moaazsidat could you please take a look at this?

hanaechahid avatar Jan 30 '20 17:01 hanaechahid

I'm still getting this issue. ReactiveTimeout doesn't work.

acerbastimur avatar Feb 03 '20 22:02 acerbastimur

@acerbastimur I have fixed the issue by deleting NavigationWithFocus in my component

hanaechahid avatar Feb 04 '20 08:02 hanaechahid