Skip to content

Commit 590e04a

Browse files
committed
Fixing Some Front-End Pages, Building The Mental Health Tracker, and added more styles to the App.
1 parent 1c80390 commit 590e04a

File tree

10 files changed

+318
-121
lines changed

10 files changed

+318
-121
lines changed

build/features.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ <h1 class="text-3xl font-bold text-gray-900 mb-8 text-center">Main Features</h1>
4444
<div class="features space-y-12">
4545
<section class="feature bg-white rounded-lg shadow-md p-6 grid md:grid-cols-2 gap-6">
4646
<div>
47-
<h2 class="text-2xl font-semibold text-blue-600 mb-4">1/ AI Study Helper + Chatbot</h2>
47+
<h2 class="text-2xl font-semibold text-blue-600 mb-4">1/ AI Study Assistant </h2>
4848
<ul class="list-disc list-inside text-gray-700 space-y-2">
4949
<li>An intelligent companion that helps you study more effectively.</li>
5050
<li>Get personalized recommendations and instant answers to your questions.</li>
@@ -61,7 +61,7 @@ <h3 class="text-xl font-semibold text-gray-800 mb-2">AI Chatbot Companion</h3>
6161

6262
<section class="feature bg-white rounded-lg shadow-md p-6 grid md:grid-cols-2 gap-6">
6363
<div>
64-
<h2 class="text-2xl font-semibold text-blue-600 mb-4">2/ Personalize Mental Health Guidance</h2>
64+
<h2 class="text-2xl font-semibold text-blue-600 mb-4">2/ Personalize Mental Health Tracker</h2>
6565
<ul class="list-disc list-inside text-gray-700 space-y-2">
6666
<li>Empower students to maintain mental health, study more effective.</li>
6767
<li>Regular health check-ins & provide feedbacks</li>
@@ -75,9 +75,9 @@ <h2 class="text-2xl font-semibold text-blue-600 mb-4">2/ Personalize Mental Heal
7575

7676
<section class="feature bg-white rounded-lg shadow-md p-6 grid md:grid-cols-2 gap-6">
7777
<div>
78-
<h2 class="text-2xl font-semibold text-blue-600 mb-4">3/ Support and Connections From Mentors</h2>
78+
<h2 class="text-2xl font-semibold text-blue-600 mb-4">3/ Companion Hub </h2>
7979
<ul class="list-disc list-inside text-gray-700 space-y-2">
80-
<li>Connect students with peer mentors for academic support.</li>
80+
<li>Connect students with peer mentors, advisors for academic support.</li>
8181
<li>Facilitate group study sessions and discussions.</li>
8282
</ul>
8383
</div>

build/styles/styles.css

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -634,6 +634,9 @@ select {
634634
.mb-4 {
635635
margin-bottom: 1rem;
636636
}
637+
.mb-6 {
638+
margin-bottom: 1.5rem;
639+
}
637640
.mb-8 {
638641
margin-bottom: 2rem;
639642
}
@@ -643,6 +646,9 @@ select {
643646
.mr-2 {
644647
margin-right: 0.5rem;
645648
}
649+
.mt-12 {
650+
margin-top: 3rem;
651+
}
646652
.mt-4 {
647653
margin-top: 1rem;
648654
}
@@ -676,6 +682,9 @@ select {
676682
.h-64 {
677683
height: 16rem;
678684
}
685+
.h-\[400px\] {
686+
height: 400px;
687+
}
679688
.h-auto {
680689
height: auto;
681690
}
@@ -719,6 +728,9 @@ select {
719728
.list-disc {
720729
list-style-type: disc;
721730
}
731+
.grid-cols-3 {
732+
grid-template-columns: repeat(3, minmax(0, 1fr));
733+
}
722734
.flex-col {
723735
flex-direction: column;
724736
}
@@ -731,6 +743,12 @@ select {
731743
.justify-between {
732744
justify-content: space-between;
733745
}
746+
.gap-12 {
747+
gap: 3rem;
748+
}
749+
.gap-4 {
750+
gap: 1rem;
751+
}
734752
.gap-6 {
735753
gap: 1.5rem;
736754
}
@@ -852,6 +870,10 @@ select {
852870
padding-left: 1rem;
853871
padding-right: 1rem;
854872
}
873+
.px-6 {
874+
padding-left: 1.5rem;
875+
padding-right: 1.5rem;
876+
}
855877
.py-16 {
856878
padding-top: 4rem;
857879
padding-bottom: 4rem;
@@ -860,6 +882,10 @@ select {
860882
padding-top: 0.5rem;
861883
padding-bottom: 0.5rem;
862884
}
885+
.py-3 {
886+
padding-top: 0.75rem;
887+
padding-bottom: 0.75rem;
888+
}
863889
.py-4 {
864890
padding-top: 1rem;
865891
padding-bottom: 1rem;
@@ -886,6 +912,10 @@ select {
886912
font-size: 2.25rem;
887913
line-height: 2.5rem;
888914
}
915+
.text-lg {
916+
font-size: 1.125rem;
917+
line-height: 1.75rem;
918+
}
889919
.text-xl {
890920
font-size: 1.25rem;
891921
line-height: 1.75rem;
@@ -978,6 +1008,10 @@ select {
9781008
.hover\:bg-blue-600:hover {
9791009
--tw-bg-opacity: 1;
9801010
background-color: rgb(37 99 235 / var(--tw-bg-opacity, 1));
1011+
}
1012+
.hover\:bg-blue-700:hover {
1013+
--tw-bg-opacity: 1;
1014+
background-color: rgb(29 78 216 / var(--tw-bg-opacity, 1));
9811015
}
9821016
.hover\:bg-gray-50:hover {
9831017
--tw-bg-opacity: 1;

build/welcomePage.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ <h2 class="text-2xl font-semibold mb-4">Get Started With Our Features:</h2>
5252
<ul class="space-y-2">
5353
<li><a href="ai-assistant.html" class="text-blue-600 hover:underline">AI Assistant Bot</a></li>
5454
<li><a href="mental-health.html" class="text-blue-600 hover:underline">Mental Health Tracker</a></li>
55-
<li><a href="management.html" class="text-blue-600 hover:underline">Smart Management Panel</a></li>
5655
<li><a href="companion-hub.html" class="text-blue-600 hover:underline">Companion Hub</a></li>
56+
<li><a href="management.html" class="text-blue-600 hover:underline">Smart Management Panel</a></li>
5757
</ul>
5858
</div>
5959

public/features.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ <h1 class="text-3xl font-bold text-gray-900 mb-8 text-center">Main Features</h1>
4444
<div class="features space-y-12">
4545
<section class="feature bg-white rounded-lg shadow-md p-6 grid md:grid-cols-2 gap-6">
4646
<div>
47-
<h2 class="text-2xl font-semibold text-blue-600 mb-4">1/ AI Study Helper + Chatbot</h2>
47+
<h2 class="text-2xl font-semibold text-blue-600 mb-4">1/ AI Study Assistant </h2>
4848
<ul class="list-disc list-inside text-gray-700 space-y-2">
4949
<li>An intelligent companion that helps you study more effectively.</li>
5050
<li>Get personalized recommendations and instant answers to your questions.</li>
@@ -61,7 +61,7 @@ <h3 class="text-xl font-semibold text-gray-800 mb-2">AI Chatbot Companion</h3>
6161

6262
<section class="feature bg-white rounded-lg shadow-md p-6 grid md:grid-cols-2 gap-6">
6363
<div>
64-
<h2 class="text-2xl font-semibold text-blue-600 mb-4">2/ Personalize Mental Health Guidance</h2>
64+
<h2 class="text-2xl font-semibold text-blue-600 mb-4">2/ Personalize Mental Health Tracker</h2>
6565
<ul class="list-disc list-inside text-gray-700 space-y-2">
6666
<li>Empower students to maintain mental health, study more effective.</li>
6767
<li>Regular health check-ins & provide feedbacks</li>
@@ -75,9 +75,9 @@ <h2 class="text-2xl font-semibold text-blue-600 mb-4">2/ Personalize Mental Heal
7575

7676
<section class="feature bg-white rounded-lg shadow-md p-6 grid md:grid-cols-2 gap-6">
7777
<div>
78-
<h2 class="text-2xl font-semibold text-blue-600 mb-4">3/ Support and Connections From Mentors</h2>
78+
<h2 class="text-2xl font-semibold text-blue-600 mb-4">3/ Companion Hub </h2>
7979
<ul class="list-disc list-inside text-gray-700 space-y-2">
80-
<li>Connect students with peer mentors for academic support.</li>
80+
<li>Connect students with peer mentors, advisors for academic support.</li>
8181
<li>Facilitate group study sessions and discussions.</li>
8282
</ul>
8383
</div>

public/mental-health.html

Lines changed: 104 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -5,56 +5,60 @@
55
<meta name="viewport" content="width=device-width, initial-scale=1.0">
66
<title>Mental Health Tracker</title>
77
<link rel="stylesheet" href="styles/styles.css">
8-
<script type="module" src="scripts/mental-health.js"></script>
8+
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
9+
<script src="scripts/mental-health.js"></script>
910
<style>
1011
/* Basic styling for layout and components */
1112
body {
12-
font-family: Arial, sans-serif;
13-
margin: 0;
14-
padding: 0;
15-
background-color: #f4f4f4;
16-
color: #333;
17-
}
18-
.container {
19-
max-width: 800px;
20-
margin: 2rem auto;
21-
padding: 1rem;
22-
background: #fff;
23-
border-radius: 8px;
24-
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
25-
}
26-
h1 {
27-
text-align: center;
28-
color: #2c3e50;
29-
}
30-
.card {
31-
margin: 1rem 0;
32-
padding: 1rem;
33-
border: 1px solid #fff9f9;
34-
border-radius: 8px;
35-
}
36-
.button {
37-
background-color: #3498db;
38-
color: white;
39-
padding: 10px 20px;
40-
border: none;
41-
border-radius: 4px;
42-
cursor: pointer;
43-
text-align: center;
44-
text-decoration: none;
45-
display: inline-block;
46-
}
47-
.button:hover {
48-
background-color: #2980b9;
49-
}
50-
.slider-container {
51-
margin: 1rem 0;
52-
}
53-
.tip {
54-
margin: 1rem 0;
55-
font-weight: bold;
56-
text-align: center;
57-
}
13+
font-family: Arial, sans-serif;
14+
margin: 0;
15+
padding: 0;
16+
background-color: #f4f4f4;
17+
color: #333;
18+
}
19+
.container {
20+
max-width: 800px;
21+
margin: 2rem auto;
22+
padding: 1rem;
23+
background: #fff;
24+
border-radius: 8px;
25+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
26+
}
27+
h1 {
28+
text-align: center;
29+
color: #2c3e50;
30+
}
31+
.card {
32+
margin: 1rem 0;
33+
padding: 1rem;
34+
border: 1px solid #fff9f9;
35+
border-radius: 8px;
36+
}
37+
.button {
38+
background-color: #3498db;
39+
color: white;
40+
padding: 10px 20px;
41+
border: none;
42+
border-radius: 4px;
43+
cursor: pointer;
44+
text-align: center;
45+
}
46+
.button:hover {
47+
background-color: #2980b9;
48+
}
49+
.slider-container {
50+
margin: 1rem 0;
51+
}
52+
.tip {
53+
margin: 1rem 0;
54+
font-weight: bold;
55+
text-align: center;
56+
}
57+
#moodChart {
58+
max-width: 600px;
59+
max-height: 300px;
60+
margin: auto;
61+
}
5862
</style>
5963
<body class="bg-custom-green">
6064
<header class="bg-white shadow-md">
@@ -88,37 +92,71 @@ <h2 class="text-xl font-bold mb-4">Account</h2>
8892
</header>
8993

9094
<!-- Back Button -->
91-
<a href="/welcomePage.html" class="button">Back to Welcome</a>
95+
<div class="container mx-auto px-4 py-8">
96+
<h1 class="text-3xl font-bold text-gray-900 mb-8 text-center">Mental Health Tracker</h1>
97+
<div class="mb-4">
98+
<a href="welcomePage.html" class="bg-blue-500 text-white px-4 py-2 rounded hover:bg-blue-600">Back to Welcome</a>
99+
</div>
100+
101+
<!-- Main Container -->
102+
<div class="container mx-auto p-8">
103+
104+
<!-- Grid Layout for Daily Mood and Stress Level -->
105+
<div class="grid md:grid-cols-2 gap-12 mt-12">
106+
107+
<!-- Daily Mood Check Card -->
108+
<div class="bg-white rounded-lg shadow-lg p-8">
109+
<h2 class="text-2xl font-semibold text-gray-700 mb-6">Daily Mood Check</h2>
110+
<div id="mood-options" class="grid grid-cols-3 gap-4">
111+
<!-- Mood buttons will be generated in JS -->
112+
</div>
113+
</div>
92114

93-
<!-- Mood Tracker -->
94-
<div class="card">
95-
<h2>Daily Mood Check</h2>
96-
<div id="mood-options">
97-
<!-- Radio buttons will be added dynamically -->
115+
<!-- Stress Levels Bar -->
116+
<div class="bg-white rounded-lg shadow-lg p-8">
117+
<h2 class="text-2xl font-semibold text-gray-700 mb-6">Stress Level</h2>
118+
<input type="range" id="stress-slider" min="0" max="10" step="1" value="5" class="w-full">
119+
<p class="mt-4 text-lg">Your stress level: <span id="stress-value" class="font-bold text-blue-600">5</span> / 10</p>
120+
</div>
98121
</div>
99-
</div>
100122

101-
<!-- Stress Level -->
102-
<div class="card">
103-
<h2>Stress Level</h2>
104-
<div class="slider-container">
105-
<input type="range" id="stress-slider" min="0" max="10" step="1" value="5">
106-
<p>Your stress level: <span id="stress-value">5</span> / 10</p>
123+
<!-- Grid Layout for Chart and Wellness Tip -->
124+
<div class="grid md:grid-cols-2 gap-12 mt-12">
125+
126+
<!-- Mood & Stress Trends Chart -->
127+
<div class="bg-white rounded-lg shadow-lg p-8 h-[400px]">
128+
<h2 class="text-2xl font-semibold text-gray-700 mb-6">Mood & Stress Trends</h2>
129+
<canvas id="moodChart" class="w-full h-full"></canvas>
130+
</div>
131+
132+
<!-- Wellness Tip Generator -->
133+
<div class="bg-white rounded-lg shadow-lg p-8">
134+
<h2 class="text-2xl font-semibold text-gray-700 mb-6">Wellness Suggestions</h2>
135+
<p id="wellness-tip" class="text-lg mb-6">Click the button below for a wellness tip!</p>
136+
<!--button class="bg-blue-500 text-white px-6 py-3 rounded-lg hover:bg-blue-700 transition duration-300 ease-in-out"
137+
id="generate-tip">
138+
Generate Tip
139+
</button-->
140+
</div>
107141
</div>
108-
</div>
109142

110-
<!-- Wellness Tip -->
111-
<div class="card">
112-
<h2>Wellness Tip</h2>
113-
<p id="wellness-tip">Click the button below to get a wellness tip!</p>
114143
</div>
115144

145+
</div>
116146
<!-- Save Entry -->
117147
<div style="text-align: center;">
118148
<button class="button" id="save-entry">Save Today's Entry</button>
119149
</div>
120-
</div>
121150

122151

152+
<!-- Script to Initialize Chart After Page Load -->
153+
<script>
154+
window.addEventListener('DOMContentLoaded', function () {
155+
import('./scripts/mental-health.js').then(module => {
156+
module.initializeChart();
157+
});
158+
});
159+
</script>
160+
123161
</body>
124162
</html>

public/scripts/app.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ function initializeApp() {
2323
Powered by Azure software with AI integration.
2424
</p>
2525
<p class="text-xl text-gray-700 mb-8">
26-
This app is currently opperate in the demo version of the app.
26+
This app is currently operate in the demo version.
2727
</p>
2828
<a href="login.html" class="btn bg-blue-500 text-white px-6 py-3 rounded-lg hover:bg-blue-600 transition duration-300">Try out now</a>
2929
<p class="text-gray-700 mt-4" style="margin-top: 0.75rem; margin-bottom: 0.75rem;">Or<br></p>

0 commit comments

Comments
 (0)