Wellness Habit Tracker Generator

Wellness Habit Tracker Generator

Define your wellness goals, log daily progress, and track your compliance and streak metrics.

WEEKLY WELLNESS REPORT

Goal: 7 days/week | Period: ...

Overall Compliance

0

Habits Defined

0%

Average Compliance (Last 7 Days)

0

Highest Active Streak (Days)

Individual Habit Tracking

Recent Activity Log

Date Habit Value/Notes Action
No activities logged yet.

Record Daily Progress

Define Your Habits

Format: **Habit Name | Frequency (Daily/X times per week) | Goal Value (e.g., 30 minutes, 8 glasses)**
Example: *Journaling | Daily | 500 words*

Manage Logs & Reset

Go to Habit Setup to define your goals.

'; } habits.forEach(h => { const data = metrics.habitData[h.id]; const complianceText = data.compliance.toFixed(0) + '%'; const card = document.createElement('div'); card.className = 'whtg-habit-card'; card.innerHTML = `

${h.name}

Goal: ${h.goal} | Target: ${h.frequency}

${data.streak} Day Streak ${complianceText}
`; cardsContainer.appendChild(card); }); // --- 3. Render Log Table --- const tbody = document.getElementById('whtg-log-table-body'); tbody.innerHTML = ''; if (metrics.recentLogs.length === 0) { tbody.innerHTML = 'No activities logged yet.'; } metrics.recentLogs.forEach(log => { const row = tbody.insertRow(); row.innerHTML = ` ${new Date(log.date).toLocaleDateString('en-US', { month: 'short', day: 'numeric' })} ${log.habit} ${log.value || 'Completed'} `; }); } function whtgDownloadPDF() { const element = document.getElementById('whtg-print-area'); // Show PDF header and hide controls const headers = element.querySelectorAll('.pdf-header'); headers.forEach(h => h.style.display = 'block'); const controls = element.querySelectorAll('.pdf-hide'); controls.forEach(c => c.style.display = 'none'); // Reset sheet background for print const sheet = element.querySelector('.whtg-tab-content'); sheet.style.backgroundColor = '#fff'; const opt = { margin: 0.5, filename: 'Wellness_Habit_Tracker_Report.pdf', image: { type: 'jpeg', quality: 0.98 }, html2canvas: { scale: 2 }, jsPDF: { unit: 'in', format: 'letter', orientation: 'portrait' } }; html2pdf().set(opt).from(element).save().then(function() { // Revert changes after download headers.forEach(h => h.style.display = 'none'); controls.forEach(c => c.style.display = 'flex'); sheet.style.backgroundColor = '#fff'; // Re-show button container that was hidden by pdf-hide class document.querySelector('.whtg-btn-container').style.display = 'flex'; }); }
Scroll to Top