JodusNodus / react-qr-reader

React component for reading QR codes from webcam.
https://jodusnodus.github.io/react-qr-reader
MIT License
1.13k stars 406 forks source link

Style of camera #209

Open samaneh-kamalian opened 2 years ago

samaneh-kamalian commented 2 years ago

Hi. I use react-native-qrcode-scanner in my android version of my app. the page that has camera is like this: androidCamera

but in PWA version that i use react-qr-reader, i can not style the camera to cover my page like in android version: Screen Shot 2021-10-19 at 8 46 16 AM

As you can see, there is a gray area that is between camera and my bottom content. I try lots of thing, like this code:

      <View style={{height: wp("200%")}}>
                    <QRCodeScanner
                      delay={1000}
                      onScan={this.props.barcodeRecognized.bind(this)}
                      style={{ height: '100%', overflow: 'auto' }}
                    />
       </View>

But there is no change in the height of the camera section! Could you please help me and suggest me a solution?

samaneh-kamalian commented 2 years ago

Hi. I use react-native-qrcode-scanner in my android version of my app. the page that has camera is like this: androidCamera

but in PWA version that i use react-qr-reader, i can not style the camera to cover my page like in android version: Screen Shot 2021-10-19 at 8 46 16 AM

As you can see, there is a gray area that is between camera and my bottom content. I try lots of thing, like this code:

      <View style={{height: wp("200%")}}>
                    <QRCodeScanner
                      delay={1000}
                      onScan={this.props.barcodeRecognized.bind(this)}
                      style={{ height: '100%', overflow: 'auto' }}
                    />
       </View>

But there is no change in the height of the camera section! Could you please help me and suggest me a solution?

Any solution? :(

samaneh-kamalian commented 2 years ago

There is not any solution?

NamNP06 commented 2 years ago

in PWA , i not display camera, please help me

filipenadai commented 2 years ago

PWA not display camera, don't have any solution ?

marcel-rf commented 2 years ago

There is not any solution?

To solve it you need to set container.overflow to 'visible' or set the overflow to something other than hidden to the containerStyle or chnage In the file https://github.com/react-qr-reader/react-qr-reader/blob/c7e15006060c2c8aebee372491d65db7c1312383/src/QrReader/styles.ts#L5