Feature/mood tracking - #39
Merged
Merged
Conversation
…d logging, analytics, and calendar integration
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
Kavinduk2
approved these changes
Mar 9, 2026
Kavinduk2
left a comment
Collaborator
There was a problem hiding this comment.
No errors were found. Can merge to the main
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a comprehensive mood tracking system to the recovery application, including backend API endpoints, frontend API integration, and a user interface for daily mood logging. The main changes add functionality for users to log their mood, view mood history, and access mood analytics, along with a modal popup for mood check-in on the dashboard.
Backend: Mood Tracking API Endpoints
progress.controller.ts:logMoodfor logging a mood entry with validation and mapping of scores to mood labels.getMoodDatafor retrieving mood history, supporting date range and "last N days" filtering, and calculating average scores.getMoodAnalyticsfor analytics such as 7- and 30-day trends, mood distribution, most frequent mood, and day-of-week patterns.Frontend: API Integration
auth-client.ts. These functions handle errors and format responses for frontend use.Frontend: Dashboard Mood Logging UI
Code Maintenance
logMoodfunction in the dashboard page.Backend: Mood Tracking Endpoints
logMood,getMoodData, andgetMoodAnalyticsendpoints with validation, mood mapping, analytics, and error handling inprogress.controller.ts.Frontend: API Integration
auth-client.ts.Frontend: Dashboard Mood Logging UI
Code Maintenance