Adds text for end of 2nd phase before infertility

This commit is contained in:
emelko
2021-02-20 12:23:23 +01:00
parent 19942d3afc
commit df732e5acc
3 changed files with 18 additions and 461 deletions
+8 -5
View File
@@ -75,16 +75,19 @@ function formatStatus(phaseNameForDay, dateString, status) {
//there might not actually be any data for the phase
const peri = status.phases.periOvulatory
const phaseEnd = peri && peri.end
let s
let periStatus
let periStatusText
if (phaseEnd && phaseEnd.date === dateString) {
s = labels.fertileUntilEvening
periStatus = labels.fertileUntilEvening
periStatusText = labels.periOvuUntilEveningText(status.temperatureShift.rule)
} else {
s = labels.fertile
periStatus = labels.fertile
periStatusText = labels.periOvuText
}
return {
status: s,
status: periStatus,
phase: 2,
statusText: labels.periOvuText
statusText: periStatusText
}
},
postOvulatory: (dateString, status) => {