Rendering icons on cycle day overview
This commit is contained in:
@@ -13,7 +13,14 @@ import cycleModule from '../../lib/cycle'
|
|||||||
import styles from '../../styles'
|
import styles from '../../styles'
|
||||||
import * as labels from './labels/labels'
|
import * as labels from './labels/labels'
|
||||||
import { AppText } from '../app-text'
|
import { AppText } from '../app-text'
|
||||||
|
import BleedingIcon from '../../assets/bleeding'
|
||||||
|
import CervixIcon from '../../assets/cervix'
|
||||||
|
import DesireIcon from '../../assets/desire'
|
||||||
import MucusIcon from '../../assets/mucus'
|
import MucusIcon from '../../assets/mucus'
|
||||||
|
import NoteIcon from '../../assets/note'
|
||||||
|
import PainIcon from '../../assets/pain'
|
||||||
|
import SexIcon from '../../assets/sex'
|
||||||
|
import TemperatureIcon from '../../assets/temperature'
|
||||||
|
|
||||||
const bleedingLabels = labels.bleeding
|
const bleedingLabels = labels.bleeding
|
||||||
const feelingLabels = labels.mucus.feeling.categories
|
const feelingLabels = labels.mucus.feeling.categories
|
||||||
@@ -69,13 +76,17 @@ export default class CycleDayOverView extends Component {
|
|||||||
onPress={() => this.navigate('BleedingEditView')}
|
onPress={() => this.navigate('BleedingEditView')}
|
||||||
data={getLabel('bleeding', cycleDay.bleeding)}
|
data={getLabel('bleeding', cycleDay.bleeding)}
|
||||||
disabled={dateInFuture}
|
disabled={dateInFuture}
|
||||||
/>
|
>
|
||||||
|
<BleedingIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
<SymptomBox
|
<SymptomBox
|
||||||
title='Temperature'
|
title='Temperature'
|
||||||
onPress={() => this.navigate('TemperatureEditView')}
|
onPress={() => this.navigate('TemperatureEditView')}
|
||||||
data={getLabel('temperature', cycleDay.temperature)}
|
data={getLabel('temperature', cycleDay.temperature)}
|
||||||
disabled={dateInFuture}
|
disabled={dateInFuture}
|
||||||
/>
|
>
|
||||||
|
<TemperatureIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
<SymptomBox
|
<SymptomBox
|
||||||
title='Mucus'
|
title='Mucus'
|
||||||
onPress={() => this.navigate('MucusEditView')}
|
onPress={() => this.navigate('MucusEditView')}
|
||||||
@@ -89,30 +100,40 @@ export default class CycleDayOverView extends Component {
|
|||||||
onPress={() => this.navigate('CervixEditView')}
|
onPress={() => this.navigate('CervixEditView')}
|
||||||
data={getLabel('cervix', cycleDay.cervix)}
|
data={getLabel('cervix', cycleDay.cervix)}
|
||||||
disabled={dateInFuture}
|
disabled={dateInFuture}
|
||||||
/>
|
>
|
||||||
|
<CervixIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
<SymptomBox
|
<SymptomBox
|
||||||
title='Desire'
|
title='Desire'
|
||||||
onPress={() => this.navigate('DesireEditView')}
|
onPress={() => this.navigate('DesireEditView')}
|
||||||
data={getLabel('desire', cycleDay.desire)}
|
data={getLabel('desire', cycleDay.desire)}
|
||||||
disabled={dateInFuture}
|
disabled={dateInFuture}
|
||||||
/>
|
>
|
||||||
|
<DesireIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
<SymptomBox
|
<SymptomBox
|
||||||
title='Sex'
|
title='Sex'
|
||||||
onPress={() => this.navigate('SexEditView')}
|
onPress={() => this.navigate('SexEditView')}
|
||||||
data={getLabel('sex', cycleDay.sex)}
|
data={getLabel('sex', cycleDay.sex)}
|
||||||
disabled={dateInFuture}
|
disabled={dateInFuture}
|
||||||
/>
|
>
|
||||||
|
<SexIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
<SymptomBox
|
<SymptomBox
|
||||||
title='Pain'
|
title='Pain'
|
||||||
onPress={() => this.navigate('PainEditView')}
|
onPress={() => this.navigate('PainEditView')}
|
||||||
data={getLabel('pain', cycleDay.pain)}
|
data={getLabel('pain', cycleDay.pain)}
|
||||||
disabled={dateInFuture}
|
disabled={dateInFuture}
|
||||||
/>
|
>
|
||||||
|
<PainIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
<SymptomBox
|
<SymptomBox
|
||||||
title='Note'
|
title='Note'
|
||||||
onPress={() => this.navigate('NoteEditView')}
|
onPress={() => this.navigate('NoteEditView')}
|
||||||
data={getLabel('note', cycleDay.note)}
|
data={getLabel('note', cycleDay.note)}
|
||||||
/>
|
>
|
||||||
|
<NoteIcon viewBox='0 0 450 450' />
|
||||||
|
</SymptomBox>
|
||||||
{/* this is just to make the last row adhere to the grid
|
{/* this is just to make the last row adhere to the grid
|
||||||
(and) because there are no pseudo properties in RN */}
|
(and) because there are no pseudo properties in RN */}
|
||||||
<FillerBoxes />
|
<FillerBoxes />
|
||||||
|
|||||||
Reference in New Issue
Block a user