pass extra props to camera screen into react-native View wrapper (current usge for pass testID)

This commit is contained in:
Ran Greenberg 2017-08-02 17:30:02 +03:00
parent 4967b1331d
commit 4f72a00c0e
2 changed files with 12 additions and 12 deletions

View File

@ -4,22 +4,22 @@ import CameraScreenBase from './CameraKitCameraScreenBase';
export default class CameraScreen extends CameraScreenBase { export default class CameraScreen extends CameraScreenBase {
renderGap() { renderGap() {
return ( return (
<View style={{flex: 10, flexDirection: 'column'}}/> <View style={{flex: 10, flexDirection: 'column'}}/>
); );
} }
render() { render() {
return ( return (
<View style={{ flex: 1, backgroundColor: 'transparent' }}> <View style={{ flex: 1, backgroundColor: 'transparent' }} {...this.props}>
{this.renderCamera()} {this.renderCamera()}
{this.renderTopButtons()} {this.renderTopButtons()}
{this.renderGap()} {this.renderGap()}
{this.renderBottomButtons()} {this.renderBottomButtons()}
</View> </View>
); );
} }
} }

View File

@ -6,7 +6,7 @@ export default class CameraScreen extends CameraScreenBase {
render() { render() {
return ( return (
<View style={{ flex: 1, backgroundColor: 'black' }}> <View style={{ flex: 1, backgroundColor: 'black' }} {...this.props}>
{this.renderTopButtons()} {this.renderTopButtons()}
{this.renderCamera()} {this.renderCamera()}
{this.renderRatioStrip()} {this.renderRatioStrip()}