postfix all i18n imports with 'labels'

- issue: 127
- by: sg
This commit is contained in:
Stefanie Grewenig
2019-01-12 16:29:31 +01:00
parent a951ffe959
commit 9fe1940907
4 changed files with 15 additions and 15 deletions
+2 -2
View File
@@ -10,7 +10,7 @@ import { saveSymptom } from '../../../db'
import ActionButtonFooter from './action-button-footer' import ActionButtonFooter from './action-button-footer'
import SymptomSection from './symptom-section' import SymptomSection from './symptom-section'
import { noteExplainer } from '../../../i18n/en/cycle-day' import { noteExplainer } from '../../../i18n/en/cycle-day'
import { shared } from '../../../i18n/en/labels' import { shared as sharedLabels } from '../../../i18n/en/labels'
export default class Note extends Component { export default class Note extends Component {
constructor(props) { constructor(props) {
@@ -34,7 +34,7 @@ export default class Note extends Component {
<TextInput <TextInput
autoFocus={!this.state.currentValue} autoFocus={!this.state.currentValue}
multiline={true} multiline={true}
placeholder={shared.enter} placeholder={sharedLabels.enter}
onChangeText={(val) => { onChangeText={(val) => {
this.setState({ currentValue: val }) this.setState({ currentValue: val })
}} }}
+2 -2
View File
@@ -6,7 +6,7 @@ import {
} from 'react-native' } from 'react-native'
import { saveSymptom } from '../../../db' import { saveSymptom } from '../../../db'
import { pain as labels } from '../../../i18n/en/cycle-day' import { pain as labels } from '../../../i18n/en/cycle-day'
import { shared } from '../../../i18n/en/labels' import { shared as sharedLabels } from '../../../i18n/en/labels'
import ActionButtonFooter from './action-button-footer' import ActionButtonFooter from './action-button-footer'
import SelectBoxGroup from '../select-box-group' import SelectBoxGroup from '../select-box-group'
import SymptomSection from './symptom-section' import SymptomSection from './symptom-section'
@@ -50,7 +50,7 @@ export default class Pain extends Component {
<TextInput <TextInput
autoFocus={this.state.focusTextArea} autoFocus={this.state.focusTextArea}
multiline={true} multiline={true}
placeholder={shared.enter} placeholder={sharedLabels.enter}
value={this.state.note} value={this.state.note}
onChangeText={(val) => { onChangeText={(val) => {
this.setState({note: val}) this.setState({note: val})
+6 -6
View File
@@ -6,8 +6,8 @@ import {
} from 'react-native' } from 'react-native'
import styles from '../../../styles' import styles from '../../../styles'
import { saveSymptom } from '../../../db' import { saveSymptom } from '../../../db'
import { sex as sexLabels, contraceptives as cLabels } from '../../../i18n/en/cycle-day' import { sex as sexLabels, contraceptives as contraceptivesLabels } from '../../../i18n/en/cycle-day'
import { shared } from '../../../i18n/en/labels' import { shared as sharedLabels } from '../../../i18n/en/labels'
import ActionButtonFooter from './action-button-footer' import ActionButtonFooter from './action-button-footer'
import SelectBoxGroup from '../select-box-group' import SelectBoxGroup from '../select-box-group'
import SymptomSection from './symptom-section' import SymptomSection from './symptom-section'
@@ -49,11 +49,11 @@ export default class Sex extends Component {
/> />
</SymptomSection> </SymptomSection>
<SymptomSection <SymptomSection
header={cLabels.header} header={contraceptivesLabels.header}
explainer={cLabels.explainer} explainer={contraceptivesLabels.explainer}
> >
<SelectBoxGroup <SelectBoxGroup
labels={cLabels.categories} labels={contraceptivesLabels.categories}
onSelect={this.toggleState} onSelect={this.toggleState}
optionsState={this.state} optionsState={this.state}
/> />
@@ -63,7 +63,7 @@ export default class Sex extends Component {
<TextInput <TextInput
autoFocus={this.state.focusTextArea} autoFocus={this.state.focusTextArea}
multiline={true} multiline={true}
placeholder={shared.enter} placeholder={sharedLabels.enter}
value={this.state.note} value={this.state.note}
onChangeText={(val) => { onChangeText={(val) => {
this.setState({ note: val }) this.setState({ note: val })
+5 -5
View File
@@ -15,7 +15,7 @@ import styles from '../../../styles'
import { LocalTime, ChronoUnit } from 'js-joda' import { LocalTime, ChronoUnit } from 'js-joda'
import { temperature as labels } from '../../../i18n/en/cycle-day' import { temperature as labels } from '../../../i18n/en/cycle-day'
import { scaleObservable } from '../../../local-storage' import { scaleObservable } from '../../../local-storage'
import { shared } from '../../../i18n/en/labels' import { shared as sharedLabels } from '../../../i18n/en/labels'
import ActionButtonFooter from './action-button-footer' import ActionButtonFooter from './action-button-footer'
import config from '../../../config' import config from '../../../config'
import SymptomSection from './symptom-section' import SymptomSection from './symptom-section'
@@ -81,11 +81,11 @@ export default class Temp extends Component {
if (warningMsg) { if (warningMsg) {
Alert.alert( Alert.alert(
shared.warning, sharedLabels.warning,
warningMsg, warningMsg,
[ [
{ text: shared.cancel }, { text: sharedLabels.cancel },
{ text: shared.save, onPress: this.saveTemperature} { text: sharedLabels.save, onPress: this.saveTemperature}
] ]
) )
} else { } else {
@@ -142,7 +142,7 @@ export default class Temp extends Component {
<TextInput <TextInput
multiline={true} multiline={true}
autoFocus={this.state.focusTextArea} autoFocus={this.state.focusTextArea}
placeholder={shared.enter} placeholder={sharedLabels.enter}
value={this.state.note} value={this.state.note}
onChangeText={(val) => { onChangeText={(val) => {
this.setState({ note: val }) this.setState({ note: val })