Added disk as option and moved toggle

This commit is contained in:
Liv
2024-01-12 21:27:20 +01:00
committed by bl00dymarie
parent d86f3ec9eb
commit 3b34ce7134
4 changed files with 20 additions and 0 deletions
+16
View File
@@ -116,6 +116,15 @@ const SymptomEditView = ({ date, onClose, symptom, symptomData }) => {
style: styles.input,
textAlignVertical: 'top',
}
const excludeToggle = shouldShow(symptomConfig.excludeText) && (
<Segment style={styles.segmentBorder}>
<AppSwitch
onToggle={onExcludeToggle}
text={symptomPage[symptom].excludeText}
value={data.exclude}
/>
</Segment>
)
return (
<AppModal onClose={onSave}>
@@ -143,6 +152,10 @@ const SymptomEditView = ({ date, onClose, symptom, symptomData }) => {
</Segment>
)
})}
{/*for bleeding, we want to move the "exclude" toggle up between the tab and box groups, all other symptoms should still have it at the bottom*/}
{symptom === 'bleeding' && excludeToggle}
{shouldShow(symptomConfig.selectBoxGroups) &&
symptomPage[symptom].selectBoxGroups.map((group) => {
const isOtherSelected =
@@ -181,6 +194,9 @@ const SymptomEditView = ({ date, onClose, symptom, symptomData }) => {
/>
</Segment>
)}
{symptom !== 'bleeding' && excludeToggle}
{shouldShow(symptomConfig.note) && (
<Segment style={styles.segmentBorder}>
<AppText>{symptomPage[symptom].note}</AppText>