diff --git a/index.html b/index.html index 8b4409e..18c8092 100644 --- a/index.html +++ b/index.html @@ -1715,13 +1715,14 @@ ${numPeople > 0 ? ` `; document.getElementById('summaryCards').innerHTML = summaryHtml; - // Toggle referral columns when no people in downline + // Toggle referral columns when no people in downline, but respect checkbox + const shouldShow = (numPeople > 0) && showRef; for (const id of ['headerYourCut','headerCumulative','headerTimelineComm','headerTimelineCum']) { const el = document.getElementById(id); - if (el) el.style.display = numPeople > 0 ? '' : 'none'; + if (el) el.style.display = shouldShow ? '' : 'none'; } for (const el of document.querySelectorAll('.referral-col')) { - el.style.display = numPeople > 0 ? '' : 'none'; + el.style.display = shouldShow ? '' : 'none'; } let cumRunning = 0;