-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmodule_numbers.html
More file actions
555 lines (531 loc) · 22.8 KB
/
module_numbers.html
File metadata and controls
555 lines (531 loc) · 22.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>SignConnect | Number Learning</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
<link href="https://unpkg.com/aos@2.3.1/dist/aos.css" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
:root {
--primary-color: #ff6e40;
--secondary-color: #26c6da;
--accent-color: #d81b60;
--bg-gradient: linear-gradient(135deg, #ffede7 0%, #e0f7fa 100%);
--card-bg: rgba(255, 255, 255, 0.95);
--shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}
body {
background: var(--bg-gradient);
font-family: 'Poppins', sans-serif;
min-height: 100vh;
display: flex;
flex-direction: column;
overflow-x: hidden;
position: relative;
margin: 0;
}
/* Abstract Background Shapes */
.abstract-shape {
position: absolute;
opacity: 0.1;
z-index: -1;
}
.shape-1 {
top: 10%;
left: 5%;
width: 200px;
height: 200px;
background: radial-gradient(circle, var(--secondary-color), transparent);
border-radius: 50%;
}
.shape-2 {
bottom: 20%;
right: 10%;
width: 150px;
height: 150px;
background: radial-gradient(circle, var(--accent-color), transparent);
clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}
/* Navbar */
.navbar {
background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
box-shadow: var(--shadow);
padding: 1rem 0;
position: sticky;
top: 0;
z-index: 1000;
}
.navbar-brand {
font-weight: 700;
font-size: 1.8rem;
color: #fff !important;
display: flex;
align-items: center;
}
.navbar-brand img {
height: 45px;
margin-right: 15px;
transition: transform 0.3s ease;
}
.navbar-brand:hover img {
transform: rotate(15deg);
}
.nav-link {
color: #fff !important;
font-weight: 500;
position: relative;
transition: all 0.3s ease;
}
.nav-link:hover {
color: #e0f7fa !important;
transform: translateY(-2px);
}
.nav-link::after {
content: '';
position: absolute;
width: 0;
height: 2px;
bottom: -2px;
left: 0;
background-color: #e0f7fa;
transition: width 0.3s ease;
}
.nav-link:hover::after {
width: 100%;
}
/* Main Content */
.main-content {
flex: 1;
padding-bottom: 50px;
}
.header-section {
padding: 60px 0;
background: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"%3E%3Cpath fill="%23ff6e40" fill-opacity="0.1" d="M0,128L48,138.7C96,149,192,171,288,186.7C384,203,480,213,576,192C672,171,768,117,864,96C960,75,1056,85,1152,106.7C1248,128,1344,160,1392,176L1440,192L1440,0L1392,0C1344,0,1248,0,1152,0C1056,0,960,0,864,0C768,0,672,0,576,0C480,0,384,0,288,0C192,0,96,0,48,0L0,0Z"%3E%3C/path%3E%3C/svg%3E') no-repeat center bottom;
background-size: cover;
text-align: center;
}
.header-section h1 {
font-size: 3rem;
font-weight: 700;
color: #3e2723;
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
margin-bottom: 0.5rem;
}
.header-section p {
font-size: 1.2rem;
color: #5d4037;
max-width: 600px;
margin: 0 auto;
}
.badge {
background: var(--accent-color);
color: #fff;
padding: 0.5rem 1rem;
border-radius: 20px;
font-size: 0.9rem;
margin-top: 0.5rem;
display: inline-block;
}
/* Number Cards */
.card {
background: #ffffff;
border: 2px solid transparent;
border-image: linear-gradient(to right, var(--primary-color), var(--secondary-color)) 1;
border-radius: 15px;
overflow: hidden;
transition: all 0.3s ease;
box-shadow: var(--shadow);
cursor: pointer;
position: relative;
height: 100%;
display: flex;
flex-direction: column;
animation: cardEntry 0.5s ease-out;
}
@keyframes cardEntry {
0% { transform: translateY(20px) scale(0.95); opacity: 0; }
100% { transform: translateY(0) scale(1); opacity: 1; }
}
.card:hover {
transform: translateY(-10px) rotate(2deg);
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2), 0 0 15px rgba(255, 110, 64, 0.3);
}
.card.clicked {
animation: pop 0.2s ease;
}
@keyframes pop {
0% { transform: scale(1); }
50% { transform: scale(1.1); }
100% { transform: scale(1); }
}
.card.completed .badge-completed {
display: block;
}
.card-body {
text-align: center;
padding: 20px;
flex: 1;
display: flex;
flex-direction: column;
justify-content: center;
background: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 200"%3E%3Ccircle fill="%23ff6e40" fill-opacity="0.05" cx="100" cy="100" r="90"/%3E%3C/svg%3E');
}
.card-title {
font-size: 2.5rem;
font-weight: 700;
color: var(--primary-color);
margin-bottom: 15px;
text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}
.card img {
max-height: 180px;
object-fit: contain;
margin: 10px auto;
transition: transform 0.3s ease;
}
.card:hover img {
transform: scale(1.1);
}
.badge-completed {
position: absolute;
top: 10px;
right: 10px;
background: var(--accent-color);
color: #fff;
font-size: 0.9rem;
padding: 5px 10px;
border-radius: 20px;
display: none;
}
.progress-bar {
height: 6px;
border-radius: 3px;
background-color: var(--secondary-color);
}
/* Buttons */
.btn {
padding: 12px 30px;
border-radius: 50px;
font-weight: 600;
transition: all 0.3s ease;
display: inline-flex;
align-items: center;
gap: 0.5rem;
}
.btn-primary {
background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
border: none;
color: #fff;
}
.btn-primary:hover {
background: linear-gradient(to right, var(--secondary-color), var(--primary-color));
transform: translateY(-2px);
box-shadow: var(--shadow);
}
.btn i {
font-size: 1rem;
}
/* Footer */
footer {
background: #f8f9fa;
padding: 1rem 0;
text-align: center;
color: #5d4037;
font-size: 0.9rem;
box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.1);
}
/* Responsive Design */
@media (max-width: 767px) {
.header-section h1 {
font-size: 2.2rem;
}
.header-section p {
font-size: 1rem;
}
.card-title {
font-size: 2rem;
}
.card-body {
padding: 15px;
}
.card img {
max-height: 150px;
}
.btn {
padding: 10px 20px;
font-size: 0.9rem;
}
.navbar-nav {
text-align: center;
}
}
/* Animations */
@keyframes fadeIn {
from { opacity: 0; transform: translateY(20px); }
to { opacity: 1; transform: translateY(0); }
}
</style>
</head>
<body>
<!-- Abstract Shapes -->
<div class="abstract-shape shape-1"></div>
<div class="abstract-shape shape-2"></div>
<!-- Navbar -->
<nav class="navbar navbar-expand-lg navbar-dark shadow">
<div class="container">
<a class="navbar-brand" href="index.html">
<img src="assets/logo.png" alt="Logo" class="logo-img">
<span>SignConnect</span>
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav ms-auto">
<li class="nav-item"><a class="nav-link" href="index.html">Home</a></li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="modulesDropdown" role="button" data-bs-toggle="dropdown" aria-expanded="false">Modules</a>
<ul class="dropdown-menu" aria-labelledby="modulesDropdown">
<li><a class="dropdown-item" href="beginner_modules.html">Beginner</a></li>
<li><a class="dropdown-item" href="intermediate_modules.html">Intermediate</a></li>
<li><a class="dropdown-item" href="advanced_modules.html">Advanced</a></li>
</ul>
</li>
<li class="nav-item"><a class="nav-link" href="dashboard.html">Dashboard</a></li>
</ul>
</div>
</div>
</nav>
<!-- Main Content -->
<div class="container main-content">
<!-- Header -->
<div class="header-section" data-aos="fade-down">
<h1>🔢 Number Learning</h1>
<p>Click a number card to learn and practice its sign language representation!</p>
<div class="row mt-4">
<div class="col-md-4"><p><strong>Numbers Learned:</strong> <span id="numbers">0/11</span></p></div>
<div class="col-md-4"><p><strong>Test Score:</strong> <span id="score">0%</span></p></div>
</div>
</div>
<!-- Number Cards -->
<section class="row justify-content-center" aria-label="Number learning cards">
<!-- Card for 0 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="50">
<div class="card card-hover" onclick="redirectToVideo('0')">
<div class="card-body">
<h3 class="card-title">0</h3>
<img src="card_images/0.png" alt="Sign for 0">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 1 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="100">
<div class="card card-hover" onclick="redirectToVideo('1')">
<div class="card-body">
<h3 class="card-title">1</h3>
<img src="card_images/1.png" alt="Sign for 1">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 2 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="150">
<div class="card card-hover" onclick="redirectToVideo('2')">
<div class="card-body">
<h3 class="card-title">2</h3>
<img src="card_images/2.png" alt="Sign for 2">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 3 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="200">
<div class="card card-hover" onclick="redirectToVideo('3')">
<div class="card-body">
<h3 class="card-title">3</h3>
<img src="card_images/3.png" alt="Sign for 3">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 4 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="250">
<div class="card card-hover" onclick="redirectToVideo('4')">
<div class="card-body">
<h3 class="card-title">4</h3>
<img src="card_images/4.png" alt="Sign for 4">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 5 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="300">
<div class="card card-hover" onclick="redirectToVideo('5')">
<div class="card-body">
<h3 class="card-title">5</h3>
<img src="card_images/5.png" alt="Sign for 5">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 6 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="350">
<div class="card card-hover" onclick="redirectToVideo('6')">
<div class="card-body">
<h3 class="card-title">6</h3>
<img src="card_images/6.png" alt="Sign for 6">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 7 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="400">
<div class="card card-hover" onclick="redirectToVideo('7')">
<div class="card-body">
<h3 class="card-title">7</h3>
<img src="card_images/7.png" alt="Sign for 7">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 8 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="450">
<div class="card card-hover" onclick="redirectToVideo('8')">
<div class="card-body">
<h3 class="card-title">8</h3>
<img src="card_images/8.png" alt="Sign for 8">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 9 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="500">
<div class="card card-hover" onclick="redirectToVideo('9')">
<div class="card-body">
<h3 class="card-title">9</h3>
<img src="card_images/9.png" alt="Sign for 9">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
<!-- Card for 10 -->
<div class="col-md-3 col-6 mb-4" data-aos="zoom-in" data-aos-delay="550">
<div class="card card-hover" onclick="redirectToVideo('10')">
<div class="card-body">
<h3 class="card-title">10</h3>
<img src="card_images/10.png" alt="Sign for 10">
<span class="badge-completed">✓ Completed</span>
<div class="progress mt-2">
<div class="progress-bar" role="progressbar" style="width: 0%;" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div>
</div>
</div>
</div>
</div>
</section>
<!-- Test Button -->
<div class="my-5" data-aos="fade-up">
<a href="number_test.html" class="btn btn-primary btn-lg" data-bs-toggle="tooltip" title="Test your number sign skills">
<i class="fas fa-check-circle"></i> Test Your Number Sign Language Skills
</a>
</div>
</div>
<!-- Footer -->
<footer>
© 2025 SignConnect | Empowering Communication
</footer>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
<script src="https://unpkg.com/aos@2.3.1/dist/aos.js"></script>
<script>
AOS.init({ duration: 800, once: true });
// Initialize tooltips
const tooltipTriggerList = document.querySelectorAll('[data-bs-toggle="tooltip"]');
const tooltipList = [...tooltipTriggerList].map(tooltipTriggerEl => new bootstrap.Tooltip(tooltipTriggerEl));
// Initialize progress from localStorage
function initializeProgress() {
const progress = JSON.parse(localStorage.getItem('numberProgress')) || {};
const numbers = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10'];
// Ensure all numbers are in progress object
numbers.forEach(number => {
if (!(number in progress)) {
progress[number] = { completed: false };
}
});
// Update UI for each card
numbers.forEach(number => {
const card = document.querySelector(`[onclick="redirectToVideo('${number}')"]`);
const progressBar = card.querySelector('.progress-bar');
if (progress[number].completed) {
card.classList.add('completed');
progressBar.style.width = '100%';
progressBar.setAttribute('aria-valuenow', '100');
} else {
card.classList.remove('completed');
progressBar.style.width = '0%';
progressBar.setAttribute('aria-valuenow', '0');
}
});
updateStats();
localStorage.setItem('numberProgress', JSON.stringify(progress));
}
// Save progress to localStorage
function saveProgress(number, completed = true) {
const progress = JSON.parse(localStorage.getItem('numberProgress')) || {};
progress[number] = { completed };
localStorage.setItem('numberProgress', JSON.stringify(progress));
}
// Update stats display
function updateStats() {
const progress = JSON.parse(localStorage.getItem('numberProgress')) || {};
const completedCount = Object.values(progress).filter(p => p.completed).length;
document.getElementById('numbers').textContent = `${completedCount}/11`;
document.getElementById('score').textContent = `${Math.round((completedCount / 11) * 100)}%`;
}
// Redirect to video page with the number as a query parameter
function redirectToVideo(number) {
const card = document.querySelector(`[onclick="redirectToVideo('${number}')"]`);
card.classList.add('clicked');
saveProgress(number, true); // Mark as completed on click
updateStats();
setTimeout(() => {
window.location.href = `number_video.html?number=${number}`;
}, 200);
}
// Initialize on page load
document.addEventListener('DOMContentLoaded', initializeProgress);
</script>
</body>
</html>