From ebbfd8aba573fb6b820f7403aafcff20d174d120 Mon Sep 17 00:00:00 2001 From: wunderfisch Date: Wed, 14 Feb 2024 10:26:13 +0100 Subject: [PATCH] merging work on secondary symptom logic and buttons --- components/settings/customization/index.js | 34 ++++++++-------------- 1 file changed, 12 insertions(+), 22 deletions(-) diff --git a/components/settings/customization/index.js b/components/settings/customization/index.js index 4454667..60b7304 100644 --- a/components/settings/customization/index.js +++ b/components/settings/customization/index.js @@ -121,15 +121,17 @@ const Settings = () => { ? labels.periodPrediction.on : labels.periodPrediction.off - // old - // const onCervixToggle = (value) => { - // if (isMucusTrackingCategoryEnabled && isCervixTrackingCategoryEnabled) { - // setShouldUseCervix(value) - // saveUseCervix(value) - // } - // } + const secondarySymptomButtons = [ + { + label: 'cervical mucus', + value: 0, + }, + { + label: 'cervix', + value: 1, + }, + ] - // new const onSelectTab = (value) => { if (isMucusTrackingCategoryEnabled && isCervixTrackingCategoryEnabled) { setShouldUseCervix(value) @@ -180,18 +182,6 @@ const Settings = () => { } } - //new - const secondarySymptomButtons = [ - { - label: 'cervical mucus', - value: 0, - }, - { - label: 'cervix', - value: 1, - }, - ] - const cervixText = shouldUseCervix ? labels.useCervix.cervixModeOn : labels.useCervix.cervixModeOff @@ -285,11 +275,11 @@ const Settings = () => { - {/* hier war vorher der AppSwitch */} - {/* noch condition adden */} + {/* noch condition adden like isSecondarySymptomDisabled */} {isTemperatureTrackingCategoryEnabled && ( <> {cervixText} +