Skip to content

Commit b560933

Browse files
authored
Bugfix: onboarding android (#820)
* fix skip * snaps * rm * min height
1 parent d50a575 commit b560933

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

app/components/UI/OnboardingWizard/__snapshots__/index.test.js.snap

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ exports[`OnboardingWizard should render correctly 1`] = `
4747
style={
4848
Array [
4949
Object {
50+
"backgroundColor": "transparent",
5051
"bottom": 0,
5152
"flex": 1,
5253
"left": 0,
@@ -55,9 +56,7 @@ exports[`OnboardingWizard should render correctly 1`] = `
5556
"right": 0,
5657
"top": 0,
5758
},
58-
Object {
59-
"backgroundColor": "transparent",
60-
},
59+
Object {},
6160
]
6261
}
6362
supportedOrientations={

app/components/UI/OnboardingWizard/index.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React, { Component } from 'react';
22
import PropTypes from 'prop-types';
3-
import { Platform, TouchableOpacity, View, StyleSheet, Text } from 'react-native';
3+
import { Platform, TouchableOpacity, View, StyleSheet, Text, Dimensions } from 'react-native';
44
import { colors, fontStyles } from '../../../styles/common';
55
import { connect } from 'react-redux';
66
import Step1 from './Step1';
@@ -18,6 +18,7 @@ import ElevatedView from 'react-native-elevated-view';
1818
import Modal from 'react-native-modal';
1919
import DeviceSize from '../../../util/DeviceSize';
2020

21+
const MIN_HEIGHT = Dimensions.get('window').height;
2122
const styles = StyleSheet.create({
2223
root: {
2324
top: 0,
@@ -26,7 +27,8 @@ const styles = StyleSheet.create({
2627
right: 0,
2728
flex: 1,
2829
margin: 0,
29-
position: 'absolute'
30+
position: 'absolute',
31+
backgroundColor: colors.transparent
3032
},
3133
main: {
3234
flex: 1,
@@ -118,7 +120,7 @@ class OnboardingWizard extends Component {
118120
backdropOpacity={0}
119121
disableAnimation
120122
transparent
121-
style={[styles.root, { backgroundColor: colors.transparent }]}
123+
style={[styles.root, Platform.OS === 'android' ? { minHeight: MIN_HEIGHT } : {}]}
122124
>
123125
<View style={styles.main}>{this.onboardingWizardNavigator(step)}</View>
124126
{step !== 1 && (

0 commit comments

Comments
 (0)