Skip to content
Snippets Groups Projects
Commit 442bcc5c authored by emelko's avatar emelko
Browse files

Adds subcategory names to the selected options

parent 2bbe7371
No related branches found
No related tags found
No related merge requests found
......@@ -70,10 +70,10 @@ export default class CycleDayOverView extends Component {
mucus: mucus => {
const filledCategories = ['feeling', 'texture'].filter(c => isNumber(mucus[c]))
let label = filledCategories.map(category => {
return labels.mucus[category].categories[mucus[category]]
return category + ': ' + labels.mucus[category].categories[mucus[category]]
}).join(', ')
if (isNumber(mucus.value)) label += `\n${labels.mucusNFP[mucus.value]}`
if (isNumber(mucus.value)) label += `\n => ${labels.mucusNFP[mucus.value]}`
if (mucus.exclude) label = `(${label})`
return label
......@@ -81,7 +81,7 @@ export default class CycleDayOverView extends Component {
cervix: cervix => {
const filledCategories = ['opening', 'firmness', 'position'].filter(c => isNumber(cervix[c]))
let label = filledCategories.map(category => {
return labels.cervix[category].categories[cervix[category]]
return category + ': ' + labels.cervix[category].categories[cervix[category]]
}).join(', ')
if (cervix.exclude) label = `(${label})`
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment