Skip to content

Commit 3358dd4

Browse files
committed
Fix contact form and improve About page styling
- Remove anime.js dependency from contact form - Replace all anime() calls with CSS transitions - Add CSS animations for form effects (shake, glow, focus states) - Fix double initialization issue - Fix vite build error - Remove deleted codepen.html from build config - Add sitemap.html to build entries - Improve About page "Why I Love Programming" section - Reduce font sizes for better readability - Adjust padding and max-width for better layout - Add responsive styles for mobile devices - Fix typo: "Progamming" -> "Programming" - Fix contact form module initialization - Properly export ContactForm class - Move video banner init to separate function - Update contact.html with correct imports
1 parent b3c6fc5 commit 3358dd4

7 files changed

Lines changed: 218 additions & 146 deletions

File tree

about.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ <h2 class="section-title">Why I Love Programming</h2>
137137
</p>
138138
</div>
139139
<div class="programming-journey">
140-
<h2 class="section-title">My Progamming Journey</h2>
140+
<h2 class="section-title">My Programming Journey</h2>
141141
<div class="journey-grid">
142142
<div class="journey-item">
143143
<i class="fas fa-lightbulb"></i>

contact.html

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,15 @@ <h3>Thanks for your message!</h3>
142142
<!-- Scripts loaded via main-page.js module -->
143143
<script type="module">
144144
import { ContactForm } from '/src/js/contact-form.js';
145+
146+
// Initialize contact form when DOM is ready
147+
if (document.readyState === 'loading') {
148+
document.addEventListener('DOMContentLoaded', () => {
149+
new ContactForm();
150+
});
151+
} else {
152+
new ContactForm();
153+
}
145154
</script>
146155
</body>
147156
</html>

src/css/contact.css

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,46 @@ textarea.error {
290290
}
291291
}
292292

293+
@keyframes shake {
294+
0%, 100% { transform: translateX(0); }
295+
10%, 30%, 50%, 70%, 90% { transform: translateX(-10px); }
296+
20%, 40%, 60%, 80% { transform: translateX(10px); }
297+
}
298+
299+
@keyframes glow {
300+
0%, 100% { box-shadow: 0 0 0 rgba(0, 255, 0, 0); }
301+
50% { box-shadow: 0 0 30px rgba(0, 255, 0, 0.5); }
302+
}
303+
304+
/* Form shake animation */
305+
.form-shake {
306+
animation: shake 0.5s ease-in-out;
307+
}
308+
309+
/* Form glow effect */
310+
.form-glow {
311+
animation: glow 1.5s ease-in-out;
312+
}
313+
314+
/* Field focus states */
315+
#contact-form input.field-focused,
316+
#contact-form textarea.field-focused {
317+
border-color: var(--matrix-green);
318+
box-shadow: 0 0 15px rgba(0, 255, 0, 0.4);
319+
transform: scale(1.01);
320+
}
321+
322+
/* Label focus states */
323+
#contact-form label.label-focused {
324+
color: var(--matrix-green);
325+
}
326+
327+
/* Field typing animation */
328+
#contact-form input.field-typing,
329+
#contact-form textarea.field-typing {
330+
box-shadow: 0 0 12px rgba(0, 255, 0, 0.35);
331+
}
332+
293333
#contact-form input:focus,
294334
#contact-form textarea:focus {
295335
animation: pulse-glow 2s ease-in-out infinite;

src/css/global.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -416,14 +416,17 @@
416416
}
417417

418418
#address p:nth-of-type(1)::before {
419+
padding: 10px;
419420
content: '\f3c5'; /* map-marker-alt */
420421
}
421422

422423
#address p:nth-of-type(2)::before {
424+
padding: 10px;
423425
content: '\f095'; /* phone */
424426
}
425427

426428
#address p:nth-of-type(3)::before {
429+
padding: 10px;
427430
content: '\f0e0'; /* envelope */
428431
}
429432

src/css/styles.css

Lines changed: 39 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2287,13 +2287,15 @@ nav ul li.version-timetravel:hover {
22872287

22882288
.story-content {
22892289
background: var(--card-bg);
2290-
padding: 3rem;
2290+
padding: 1.75rem 2rem;
22912291
border-radius: 15px;
22922292
border: var(--border-glow);
22932293
position: relative;
22942294
overflow: hidden;
22952295
box-shadow: 0 0 30px rgba(0, 255, 0, 0.1);
22962296
transition: var(--transition-smooth);
2297+
max-width: 800px;
2298+
margin: 0 auto;
22972299
}
22982300

22992301
.story-content::before {
@@ -2314,7 +2316,7 @@ nav ul li.version-timetravel:hover {
23142316
}
23152317

23162318
.story-content:hover {
2317-
transform: translateY(-5px);
2319+
transform: translateY(-2px);
23182320
box-shadow: 0 10px 30px rgba(0, 255, 0, 0.2);
23192321
}
23202322

@@ -2324,16 +2326,28 @@ nav ul li.version-timetravel:hover {
23242326
}
23252327

23262328
.highlight-text {
2327-
font-size: 1.6rem;
2329+
font-size: 1.2rem;
23282330
color: var(--neon-green);
2329-
margin-bottom: 2rem;
2330-
line-height: 1.6;
2331+
margin-bottom: 1.5rem;
2332+
line-height: 1.7;
23312333
font-weight: 500;
23322334
text-shadow: 0 0 5px rgba(0, 255, 0, 0.3);
23332335
position: relative;
23342336
padding-left: 2rem;
23352337
}
23362338

2339+
.story-content p {
2340+
color: #FF00FF;
2341+
margin-bottom: 1.25rem;
2342+
line-height: 1.7;
2343+
font-family: 'Courier New', Courier, monospace;
2344+
font-size: 1rem;
2345+
}
2346+
2347+
.story-content p:last-child {
2348+
margin-bottom: 0;
2349+
}
2350+
23372351
.highlight-text::before {
23382352
content: '';
23392353
position: absolute;
@@ -2465,12 +2479,17 @@ nav ul li.version-timetravel:hover {
24652479
grid-template-columns: 1fr;
24662480
}
24672481

2482+
.story-content {
2483+
padding: 1.5rem 1.25rem;
2484+
}
2485+
24682486
.highlight-text {
2469-
font-size: 1.2rem;
2487+
font-size: 1.1rem;
2488+
padding-left: 1.5rem;
24702489
}
2471-
2472-
.story-content {
2473-
padding: 1.5rem;
2490+
2491+
.story-content p {
2492+
font-size: 0.95rem;
24742493
}
24752494

24762495
.achievement-list li {
@@ -2818,7 +2837,17 @@ html {
28182837
}
28192838

28202839
.story-content {
2821-
padding: 2rem;
2840+
padding: 1.25rem 1rem;
2841+
}
2842+
2843+
.story-content p {
2844+
font-size: 0.9rem;
2845+
margin-bottom: 1rem;
2846+
}
2847+
2848+
.highlight-text {
2849+
font-size: 1rem;
2850+
padding-left: 1rem;
28222851
}
28232852
}
28242853

0 commit comments

Comments
 (0)