From e395730d981e7ce9ebdc3c2aaddccbfd284620e9 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Wed, 14 Feb 2024 17:48:50 +0100 Subject: [PATCH 01/15] First step for fertilityTracking Toggle --- components/settings/customization/index.js | 25 ++++++++++++++++------ i18n/en/settings.js | 5 +++++ local-storage.js | 8 +++++++ 3 files changed, 31 insertions(+), 7 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index 4f202de..bd20433 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -10,6 +10,7 @@ import SelectTabGroup from '../../cycle-day/select-tab-group' import { desireTrackingCategoryObservable, + fertilityTrackingObservable, moodTrackingCategoryObservable, noteTrackingCategoryObservable, painTrackingCategoryObservable, @@ -18,6 +19,7 @@ import { mucusTrackingCategoryObservable, cervixTrackingCategoryObservable, saveDesireTrackingCategory, + saveFertilityTrackingEnabled, saveMoodTrackingCategory, saveNoteTrackingCategory, savePainTrackingCategory, @@ -75,8 +77,13 @@ const Settings = () => { const [isSecondarySymptomDisabled, setIsSecondarySymptomDisabled] = useState(false) - const [isEnabled, setIsEnabled] = useState(false) - const toggleSwitch = () => setIsEnabled((previousState) => !previousState) + const [isFertilityTrackingEnabled, setFertilityTrackingEnabled] = useState( + fertilityTrackingObservable.value + ) + const fertilityTrackingToggle = (value) => { + setFertilityTrackingEnabled(value) + saveFertilityTrackingEnabled(value) + } const temperatureTrackingCategoryToggle = (value) => { setTemperatureTrackingCategory(value) @@ -112,6 +119,11 @@ const Settings = () => { setPeriodPrediction(value) savePeriodPrediction(value) } + + const fertilityTrackingText = isFertilityTrackingEnabled + ? labels.fertilityTracking.on + : labels.fertilityTracking.off + const periodPredictionText = isPeriodPredictionEnabled ? labels.periodPrediction.on : labels.periodPrediction.off @@ -234,12 +246,11 @@ const Settings = () => { value={isNoteTrackingCategoryEnabled} /> - - + diff --git a/i18n/en/settings.js b/i18n/en/settings.js index bf26203..eec5ea8 100644 --- a/i18n/en/settings.js +++ b/i18n/en/settings.js @@ -66,6 +66,11 @@ export default { 'To use the period reminder please first enable period predictions in the customization settings.', }, }, + fertilityTracking: { + title: 'Fertility phases calculation', + on: 'The quick brown fox jumps over the lazy dog', + off: 'No no', + }, secondarySymptom: { title: 'Secondary symptom', cervixModeOn: diff --git a/local-storage.js b/local-storage.js index 84b680d..7f2de93 100644 --- a/local-storage.js +++ b/local-storage.js @@ -170,6 +170,14 @@ export async function saveNoteTrackingCategory(bool) { noteTrackingCategoryObservable.set(bool) } +export const fertilityTrackingObservable = Observable() +setObvWithInitValue('fertilityTracking', fertilityTrackingObservable, true) + +export async function saveFertilityTrackingEnabled(bool) { + await AsyncStorage.setItem('fertilityTracking', JSON.stringify(bool)) + fertilityTrackingObservable.set(bool) +} + async function setObvWithInitValue(key, obv, defaultValue) { const result = await AsyncStorage.getItem(key) let value From faad51f4f191ae627cbdbc8b15f9adbaf4a8ace3 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Wed, 14 Feb 2024 17:49:16 +0100 Subject: [PATCH 02/15] Check for FertilityTrackingEnabled on home --- components/Home.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/components/Home.js b/components/Home.js index 783d8c4..af02576 100644 --- a/components/Home.js +++ b/components/Home.js @@ -14,7 +14,10 @@ import { determinePredictionText, formatWithOrdinalSuffix, } from './helpers/home' -import { periodPredictionObservable } from '../local-storage' +import { + fertilityTrackingObservable, + periodPredictionObservable, +} from '../local-storage' import { Colors, Fonts, Sizes, Spacing } from '../styles' import { LocalDate } from '@js-joda/core' @@ -28,11 +31,12 @@ const Home = ({ navigate, setDate }) => { navigate('CycleDay') } + const isFertilityTrackingEnabled = fertilityTrackingObservable.value const todayDateString = LocalDate.now().toString() const { getCycleDayNumber, getPredictedMenses } = cycleModule() const cycleDayNumber = getCycleDayNumber(todayDateString) const { status, phase, statusText } = - getFertilityStatusForDay(todayDateString) + isFertilityTrackingEnabled && getFertilityStatusForDay(todayDateString) const isPeriodPredictionEnabled = periodPredictionObservable.value const prediction = determinePredictionText(getPredictedMenses(), t) @@ -55,7 +59,7 @@ const Home = ({ navigate, setDate }) => { )} - {phase && ( + {isFertilityTrackingEnabled && phase && ( {formatWithOrdinalSuffix(phase)} From 31888c3331518a1ad54dd7b7f568eaa2104bd6e3 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Wed, 14 Feb 2024 17:49:34 +0100 Subject: [PATCH 03/15] Check for FertilityTrackingEnabled on chart --- components/helpers/chart.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/components/helpers/chart.js b/components/helpers/chart.js index ba25223..245123f 100644 --- a/components/helpers/chart.js +++ b/components/helpers/chart.js @@ -1,6 +1,10 @@ import { LocalDate } from '@js-joda/core' -import { scaleObservable, unitObservable } from '../../local-storage' +import { + fertilityTrackingObservable, + scaleObservable, + unitObservable, +} from '../../local-storage' import { getCycleStatusForDay } from '../../lib/sympto-adapter' import { getCycleDay, getAmountOfCycleDays } from '../../db' @@ -270,7 +274,8 @@ export function nfpLines() { if (dateString < cycle.startDate) updateCurrentCycle(dateString) if (cycle.noMoreCycles) return ret - const tempShift = cycle.status.temperatureShift + const tempShift = + fertilityTrackingObservable.value && cycle.status.temperatureShift if (tempShift) { if (tempShift.firstHighMeasurementDay.date === dateString) { From c037c630d392f6b8541917f3b7457ce0e284a5c6 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Thu, 22 Feb 2024 16:40:28 +0100 Subject: [PATCH 04/15] Check for FertilityTrackingEnabled in sympto-adapter --- lib/sympto-adapter.js | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/lib/sympto-adapter.js b/lib/sympto-adapter.js index ef3b8fb..44e3d18 100644 --- a/lib/sympto-adapter.js +++ b/lib/sympto-adapter.js @@ -1,9 +1,15 @@ import getFertilityStatus from 'sympto' import cycleModule from './cycle' -import { useCervixAsSecondarySymptomObservable } from '../local-storage' +import { fertilityTrackingObservable, useCervixAsSecondarySymptomObservable } from '../local-storage' import { fertilityStatus as labels } from '../i18n/en/labels' +const isFertilityTrackingEnabled = fertilityTrackingObservable.value + export function getFertilityStatusForDay(dateString) { + if (!isFertilityTrackingEnabled) { + return + } + const status = getCycleStatusForDay(dateString) if (!status) return { status: labels.fertile, @@ -34,6 +40,10 @@ export function getFertilityStatusForDay(dateString) { } export function getCycleStatusForDay(dateString, opts = {}) { + if (!isFertilityTrackingEnabled) { + return + } + const { getCycleForDay, getCyclesBefore, From 29c3b9b10885cea154d4771b0ec74130e367a9b7 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 13:12:27 +0100 Subject: [PATCH 05/15] Disable fertility tracking switch depending on temp, mucus or cervix --- components/settings/customization/index.js | 27 ++++++++++++++++------ 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index bd20433..6fd93df 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -246,13 +246,26 @@ const Settings = () => { value={isNoteTrackingCategoryEnabled} /> - - - + + + + {isTemperatureTrackingCategoryEnabled && + isMucusTrackingCategoryEnabled || + isCervixTrackingCategoryEnabled ? + ( + <> + + + ) : + ( + {labels.disabled.message} + )} + + From d0d691c6afa0f1f774342e61ea991fa77e508781 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 13:13:12 +0100 Subject: [PATCH 06/15] Turn fertility tracking off when temperature tracking is off --- local-storage.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/local-storage.js b/local-storage.js index 7f2de93..3647683 100644 --- a/local-storage.js +++ b/local-storage.js @@ -107,8 +107,15 @@ export async function saveTemperatureTrackingCategory(bool) { temperatureTrackingCategoryObservable.set(bool) if (!temperatureTrackingCategoryObservable.value) { - const result = await AsyncStorage.getItem('tempReminder') - if (JSON.parse(result).enabled) { + // if temperature tracking is turned off, the fertility tracking gets disabled + const fertilityTrackingResult = await AsyncStorage.getItem('fertilityTracking') + if (fertilityTrackingResult) { + saveFertilityTrackingEnabled(false) + } + + // if temperature tracking is turned off, the temperature reminder gets disabled + const tempReminderResult = await AsyncStorage.getItem('tempReminder') + if (JSON.parse(tempReminderResult).enabled) { tempReminderObservable.set(false) } } From 3c0ea9b208a5b6b4532fae2b990fd87ee802bb8c Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 13:13:46 +0100 Subject: [PATCH 07/15] Turn fertility tracking off when mucus and cervix tracking are off --- local-storage.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/local-storage.js b/local-storage.js index 3647683..1c1759e 100644 --- a/local-storage.js +++ b/local-storage.js @@ -127,6 +127,14 @@ setObvWithInitValue('mucus', mucusTrackingCategoryObservable, true) export async function saveMucusTrackingCategory(bool) { await AsyncStorage.setItem('mucus', JSON.stringify(bool)) mucusTrackingCategoryObservable.set(bool) + + // if mucus and cervix tracking is turned off, the fertility tracking gets disabled + if (!mucusTrackingCategoryObservable.value && !cervixTrackingCategoryObservable.value) { + const fertilityTrackingResult = await AsyncStorage.getItem('fertilityTracking') + if (fertilityTrackingResult) { + saveFertilityTrackingEnabled(false) + } + } } export const cervixTrackingCategoryObservable = Observable() @@ -135,6 +143,14 @@ setObvWithInitValue('cervix', cervixTrackingCategoryObservable, true) export async function saveCervixTrackingCategory(bool) { await AsyncStorage.setItem('cervix', JSON.stringify(bool)) cervixTrackingCategoryObservable.set(bool) + + // if cervix and mucus tracking is turned off, the fertility tracking gets disabled + if (!cervixTrackingCategoryObservable.value && !mucusTrackingCategoryObservable.value) { + const fertilityTrackingResult = await AsyncStorage.getItem('fertilityTracking') + if (fertilityTrackingResult) { + saveFertilityTrackingEnabled(false) + } + } } export const sexTrackingCategoryObservable = Observable() From 8150b791edc8fae0cca18da552d552730e0aba3b Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 13:14:21 +0100 Subject: [PATCH 08/15] Only check if fertility tracking enabled for display of secondary Symptom --- components/settings/customization/index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index 6fd93df..1782104 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -284,8 +284,7 @@ const Settings = () => { {/* used to be switch for onCervixToggle */} - {!isTemperatureTrackingCategoryEnabled || - isSecondarySymptomDisabled ? ( + {!isFertilityTrackingEnabled ? ( {labels.secondarySymptom.disabled.message} ) : ( <> From 27bb25e6da4082cb49c6ecbae960488b83474149 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 13:22:56 +0100 Subject: [PATCH 09/15] Add check for if tempReminder is null --- local-storage.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/local-storage.js b/local-storage.js index 1c1759e..2081547 100644 --- a/local-storage.js +++ b/local-storage.js @@ -115,7 +115,7 @@ export async function saveTemperatureTrackingCategory(bool) { // if temperature tracking is turned off, the temperature reminder gets disabled const tempReminderResult = await AsyncStorage.getItem('tempReminder') - if (JSON.parse(tempReminderResult).enabled) { + if (tempReminderResult && JSON.parse(tempReminderResult).enabled) { tempReminderObservable.set(false) } } From 5855ea0a348df47338066ce3c03c1a1806f63f30 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 16:38:11 +0100 Subject: [PATCH 10/15] Move temp off turns fertility off logic out of local storage --- components/settings/customization/index.js | 4 ++++ local-storage.js | 6 ------ 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index 1782104..a941e64 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -88,6 +88,10 @@ const Settings = () => { const temperatureTrackingCategoryToggle = (value) => { setTemperatureTrackingCategory(value) saveTemperatureTrackingCategory(value) + if (!value) { + setFertilityTrackingEnabled(false) + saveFertilityTrackingEnabled(false) + } } const mucusTrackingCategoryToggle = (value) => { manageSecondarySymptom(cervixTrackingCategoryObservable.value, value) diff --git a/local-storage.js b/local-storage.js index 2081547..b7ad678 100644 --- a/local-storage.js +++ b/local-storage.js @@ -107,12 +107,6 @@ export async function saveTemperatureTrackingCategory(bool) { temperatureTrackingCategoryObservable.set(bool) if (!temperatureTrackingCategoryObservable.value) { - // if temperature tracking is turned off, the fertility tracking gets disabled - const fertilityTrackingResult = await AsyncStorage.getItem('fertilityTracking') - if (fertilityTrackingResult) { - saveFertilityTrackingEnabled(false) - } - // if temperature tracking is turned off, the temperature reminder gets disabled const tempReminderResult = await AsyncStorage.getItem('tempReminder') if (tempReminderResult && JSON.parse(tempReminderResult).enabled) { From 1c7350947361f76b00fd2e87d633fedd7d36d893 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 16:38:44 +0100 Subject: [PATCH 11/15] Move cervix & mucus off turn fertility off logic out of local storage --- components/settings/customization/index.js | 2 ++ local-storage.js | 16 ---------------- 2 files changed, 2 insertions(+), 16 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index a941e64..5a0caf8 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -173,6 +173,8 @@ const Settings = () => { setIsSecondarySymptomDisabled(false) } else if (!cervix && !mucus) { setIsSecondarySymptomDisabled(true) + setFertilityTrackingEnabled(false) + saveFertilityTrackingEnabled(false) } setMucusTrackingCategory(mucus) saveMucusTrackingCategory(mucus) diff --git a/local-storage.js b/local-storage.js index b7ad678..66ce305 100644 --- a/local-storage.js +++ b/local-storage.js @@ -121,14 +121,6 @@ setObvWithInitValue('mucus', mucusTrackingCategoryObservable, true) export async function saveMucusTrackingCategory(bool) { await AsyncStorage.setItem('mucus', JSON.stringify(bool)) mucusTrackingCategoryObservable.set(bool) - - // if mucus and cervix tracking is turned off, the fertility tracking gets disabled - if (!mucusTrackingCategoryObservable.value && !cervixTrackingCategoryObservable.value) { - const fertilityTrackingResult = await AsyncStorage.getItem('fertilityTracking') - if (fertilityTrackingResult) { - saveFertilityTrackingEnabled(false) - } - } } export const cervixTrackingCategoryObservable = Observable() @@ -137,14 +129,6 @@ setObvWithInitValue('cervix', cervixTrackingCategoryObservable, true) export async function saveCervixTrackingCategory(bool) { await AsyncStorage.setItem('cervix', JSON.stringify(bool)) cervixTrackingCategoryObservable.set(bool) - - // if cervix and mucus tracking is turned off, the fertility tracking gets disabled - if (!cervixTrackingCategoryObservable.value && !mucusTrackingCategoryObservable.value) { - const fertilityTrackingResult = await AsyncStorage.getItem('fertilityTracking') - if (fertilityTrackingResult) { - saveFertilityTrackingEnabled(false) - } - } } export const sexTrackingCategoryObservable = Observable() From 405e27bdbe136639fd19bc6ade21fa614e11e3c9 Mon Sep 17 00:00:00 2001 From: bl00dymarie Date: Fri, 23 Feb 2024 16:50:30 +0100 Subject: [PATCH 12/15] Remove isSecondarySymptomDisabled; because maybe we don't need it anymore with fertilityTracking taking its job --- components/settings/customization/index.js | 7 ------- 1 file changed, 7 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index 5a0caf8..e292e16 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -74,9 +74,6 @@ const Settings = () => { noteTrackingCategoryObservable.value ) - const [isSecondarySymptomDisabled, setIsSecondarySymptomDisabled] = - useState(false) - const [isFertilityTrackingEnabled, setFertilityTrackingEnabled] = useState( fertilityTrackingObservable.value ) @@ -164,15 +161,11 @@ const Settings = () => { if (!cervix && mucus) { setUseCervixAsSecondarySymptom(0) saveUseCervixAsSecondarySymptom(0) - setIsSecondarySymptomDisabled(false) } else if (cervix && mucus) { - setIsSecondarySymptomDisabled(false) } else if (cervix && !mucus) { setUseCervixAsSecondarySymptom(1) saveUseCervixAsSecondarySymptom(1) - setIsSecondarySymptomDisabled(false) } else if (!cervix && !mucus) { - setIsSecondarySymptomDisabled(true) setFertilityTrackingEnabled(false) saveFertilityTrackingEnabled(false) } From 37152b3fec4d20948ed91042460d9d4ed9fadcfe Mon Sep 17 00:00:00 2001 From: wunderfisch Date: Fri, 23 Feb 2024 15:34:09 +0100 Subject: [PATCH 13/15] small changes in styling. more space beween switch lines, smaller switches in iOS (testing please), less bottom margin for segments --- components/common/app-switch.js | 7 ++++++- styles/containers.js | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/components/common/app-switch.js b/components/common/app-switch.js index d45758f..5e74bb5 100644 --- a/components/common/app-switch.js +++ b/components/common/app-switch.js @@ -4,7 +4,7 @@ import PropTypes from 'prop-types' import AppText from './app-text' -import { Colors, Containers } from '../../styles' +import { Colors, Containers, Spacing } from '../../styles' const AppSwitch = ({ onToggle, text, value, disabled }) => { const trackColor = { true: Colors.turquoiseDark } @@ -37,6 +37,11 @@ const styles = StyleSheet.create({ }, switch: { flex: 1, + marginBottom: Spacing.tiny, + transform: + Platform.OS === 'ios' + ? [{ scaleX: 0.8 }, { scaleY: 0.8 }] + : [{ scaleX: 1 }, { scaleY: 1 }], }, textContainer: { flex: 4, diff --git a/styles/containers.js b/styles/containers.js index 8560d10..c169fec 100644 --- a/styles/containers.js +++ b/styles/containers.js @@ -36,6 +36,6 @@ export default { }, segmentContainer: { marginHorizontal: Spacing.base, - marginBottom: Spacing.base, + marginBottom: Spacing.tiny, }, } From 4fc11d2f7e25ab18f6338c0ab5e83c3d7b5e3754 Mon Sep 17 00:00:00 2001 From: wunderfisch Date: Mon, 26 Feb 2024 13:28:43 +0100 Subject: [PATCH 14/15] changes in customization texts and small changes to styling --- components/common/app-switch.js | 2 +- components/settings/customization/index.js | 26 ++++++++++------------ i18n/en/settings.js | 14 +++++++----- styles/containers.js | 2 +- 4 files changed, 22 insertions(+), 22 deletions(-) diff --git a/components/common/app-switch.js b/components/common/app-switch.js index 5e74bb5..78ab610 100644 --- a/components/common/app-switch.js +++ b/components/common/app-switch.js @@ -34,10 +34,10 @@ AppSwitch.propTypes = { const styles = StyleSheet.create({ container: { ...Containers.rowContainer, + marginTop: Spacing.tiny, }, switch: { flex: 1, - marginBottom: Spacing.tiny, transform: Platform.OS === 'ios' ? [{ scaleX: 0.8 }, { scaleY: 0.8 }] diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index e292e16..fffcd7d 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -246,23 +246,21 @@ const Settings = () => { /> - {isTemperatureTrackingCategoryEnabled && - isMucusTrackingCategoryEnabled || - isCervixTrackingCategoryEnabled ? - ( - <> - - - ) : - ( + (isMucusTrackingCategoryEnabled || + isCervixTrackingCategoryEnabled) ? ( + <> + {labels.fertilityTracking.message} + + + ) : ( {labels.disabled.message} - )} + )} diff --git a/i18n/en/settings.js b/i18n/en/settings.js index eec5ea8..5a7a2e0 100644 --- a/i18n/en/settings.js +++ b/i18n/en/settings.js @@ -41,7 +41,7 @@ export default { disabled: { title: 'This feature is turned off', message: - 'Please first enable the temperature tracking category in the customization settings.', + 'To use the temperature scale please first enable the temperature tracking category above.', }, tempReminder: { title: 'Temperature reminder', @@ -68,8 +68,10 @@ export default { }, fertilityTracking: { title: 'Fertility phases calculation', - on: 'The quick brown fox jumps over the lazy dog', - off: 'No no', + message: + 'If you enter menstrual bleeding, temperature and cervical mucus or cervix data according to the sympto-thermal rules, drip will calculate cycle phases with the provided data.', + on: 'If you switch this off, drip will not show fertility related information.', + off: 'If you switch this on, drip will show fertility related information.', }, secondarySymptom: { title: 'Secondary symptom', @@ -80,16 +82,16 @@ export default { disabled: { title: 'Disabled', message: - 'To set a secondary symptom please first enable the temperature, cervical mucus or cervix tracking category as well as the fertility feature in the customization settings.', + 'To set a secondary symptom please first enable the temperature, cervical mucus or cervix tracking category as well as the fertility feature above.', noSecondaryEnabled: - 'To switch the secondary symptom both cervical mucus an cervix need to be enabled in the customization settings.', + 'To switch the secondary symptom both cervical mucus and cervix need to be enabled above.', }, mucus: 'cervical mucus', cervix: 'cervix', }, periodPrediction: { title: 'Period predictions', - on: 'drip predicts your 3 next menstrual bleedings based on the statistics of your previously tracked cycles, min 3 complete cycles.', + on: 'drip predicts your 3 next menstrual bleedings based on statistics if you previously tracked at least 3 complete cycles.', off: 'There are no predictions for menstrual cycles displayed. If turned on the calendar and the home screen will display period predictions.', }, passwordSettings: { diff --git a/styles/containers.js b/styles/containers.js index c169fec..8560d10 100644 --- a/styles/containers.js +++ b/styles/containers.js @@ -36,6 +36,6 @@ export default { }, segmentContainer: { marginHorizontal: Spacing.base, - marginBottom: Spacing.tiny, + marginBottom: Spacing.base, }, } From ef4095d61c96672b5237f70893328f8e6cc2aeac Mon Sep 17 00:00:00 2001 From: wunderfisch Date: Mon, 26 Feb 2024 15:28:11 +0100 Subject: [PATCH 15/15] fixing issue import and empty statement --- components/common/app-switch.js | 2 +- components/settings/customization/index.js | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/components/common/app-switch.js b/components/common/app-switch.js index 78ab610..dfa8dfe 100644 --- a/components/common/app-switch.js +++ b/components/common/app-switch.js @@ -1,5 +1,5 @@ import React from 'react' -import { StyleSheet, Switch, View } from 'react-native' +import { Platform, StyleSheet, Switch, View } from 'react-native' import PropTypes from 'prop-types' import AppText from './app-text' diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index fffcd7d..607a4e6 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -161,7 +161,6 @@ const Settings = () => { if (!cervix && mucus) { setUseCervixAsSecondarySymptom(0) saveUseCervixAsSecondarySymptom(0) - } else if (cervix && mucus) { } else if (cervix && !mucus) { setUseCervixAsSecondarySymptom(1) saveUseCervixAsSecondarySymptom(1) @@ -202,7 +201,6 @@ const Settings = () => { text={SYMPTOMS[1]} value={isTemperatureTrackingCategoryEnabled} /> - { mucusTrackingCategoryToggle(enabled) @@ -210,7 +208,6 @@ const Settings = () => { text={SYMPTOMS[2]} value={isMucusTrackingCategoryEnabled} /> - { cervixTrackingCategoryToggle(enabled) @@ -218,7 +215,6 @@ const Settings = () => { text={SYMPTOMS[3]} value={isCervixTrackingCategoryEnabled} /> - { - {/* used to be switch for onCervixToggle */} {!isFertilityTrackingEnabled ? (