Merge branch '345-move-info-button-out-of-header-to-body' into marie-move-info-button-out-of-header-to-body

This commit is contained in:
Julia Friesel
2019-05-19 17:53:14 +02:00
26 changed files with 481 additions and 397 deletions
+1 -22
View File
@@ -1,17 +1,13 @@
import React from 'react'
import {
Alert,
ScrollView,
TextInput,
TouchableOpacity,
View
} from 'react-native'
import FeatherIcon from 'react-native-vector-icons/Feather'
import infoLabels from '../../../i18n/en/symptom-info'
import { sex as sexLabels, contraceptives as contraceptivesLabels } from '../../../i18n/en/cycle-day'
import { shared as sharedLabels } from '../../../i18n/en/labels'
import styles, { iconStyles } from '../../../styles'
import styles from '../../../styles'
import SelectBoxGroup from '../select-box-group'
@@ -34,14 +30,6 @@ export default class Sex extends SymptomView {
symptomName = 'sex'
showInfoBox(){
const symptomName = 'sex'
Alert.alert(
infoLabels[symptomName].title,
infoLabels[symptomName].text
)
}
onBackButtonPress() {
const nothingEntered = Object.values(this.state).every(val => !val)
if (nothingEntered) {
@@ -79,15 +67,6 @@ export default class Sex extends SymptomView {
/>
</SymptomSection>
<View style={{ flex: 1 }}></View>
<TouchableOpacity
onPress={this.showInfoBox}
style={styles.infoButton}
>
<FeatherIcon
name="info"
style={iconStyles.symptomInfo}
/>
</TouchableOpacity>
</View>
<SymptomSection
header={contraceptivesLabels.header}