From 13211f7b8531870fe5eeb787c4c30dd06018f004 Mon Sep 17 00:00:00 2001 From: Shreya Singh Date: Sun, 24 May 2026 12:27:30 +0530 Subject: [PATCH] fix: improve hero section alignment and responsiveness --- src/components/Hero.tsx | 160 ++++++++++++++++++++++------------------ 1 file changed, 90 insertions(+), 70 deletions(-) diff --git a/src/components/Hero.tsx b/src/components/Hero.tsx index a606d777..163fb037 100644 --- a/src/components/Hero.tsx +++ b/src/components/Hero.tsx @@ -1,91 +1,118 @@ import { Search, GitBranch, GitCommit, GitPullRequest, Layout } from 'lucide-react'; import { Link } from 'react-router-dom'; -// Fixed array declaration for data structure rendering stability const MATRIX_CELLS = Array.from({ length: 21 }, (_, i) => i); const Hero = () => { return ( -
+
- {/* 1. Cyber Grid Overlay */} -
- - {/* Ambient Radial Glow Elements */} -
-
+ {/* Background Grid */} +
+ + {/* Glow Effects */} +
+
-
-
+
+ +
- {/* LEFT COLUMN: Typography & CTA */} -
-

+ {/* LEFT SIDE */} +
+ +

Track GitHub Activity - + Like Never Before

- -

- Monitor and analyze GitHub user activity with powerful insights. Perfect for developers, - project managers, and teams who want to understand contribution patterns and repository engagement. + +

+ Monitor and analyze GitHub user activity with powerful insights. + Perfect for developers, project managers, and teams who want to + understand contribution patterns and repository engagement.

-
- {/* Interactive Primary Link Button */} - - - - Start Tracking +
+ + + + + Start Tracking +
- {/* RIGHT COLUMN: Dashboard & Floating Git Elements */} -
+ {/* RIGHT SIDE */} +
- {/* The Main Dashboard Mockup Card */} -
-
-
+ {/* Dashboard Card */} +
+ + {/* Header */} +
+
- Dashboard Insights + + Dashboard Insights +
-
- - - + +
+ + +
- {/* Mockup Data widgets */} -
-
-
Weekly Commits
-
176 +12%
+ {/* Stats */} +
+ +
+
+ Weekly Commits +
+ +
+ 176 + + +12% + +
+
-
+
- {/* Simulated GitHub Contribution Grid */} -
-
Contribution Matrix
+ {/* Contribution Grid */} +
+
+ Contribution Matrix +
+
{MATRIX_CELLS.map((cellIndex) => { - // Fully qualified class names to ensure they aren't removed by Tailwind's compilation process - const intensitiesLight = ['bg-slate-200', 'bg-emerald-200', 'bg-emerald-300', 'bg-emerald-500', 'bg-emerald-600']; - const intensitiesDark = ['dark:bg-slate-800', 'dark:bg-emerald-900/60', 'dark:bg-emerald-700', 'dark:bg-emerald-500', 'dark:bg-emerald-400']; - - const lightClass = intensitiesLight[cellIndex % intensitiesLight.length]; - const darkClass = intensitiesDark[cellIndex % intensitiesDark.length]; - + const intensities = [ + 'bg-slate-200 dark:bg-slate-800', + 'bg-emerald-200 dark:bg-emerald-900/60', + 'bg-emerald-300 dark:bg-emerald-700', + 'bg-emerald-500', + 'bg-emerald-600', + ]; + return ( -
); })} @@ -94,32 +121,25 @@ const Hero = () => {
- {/* Floating Git Icon Nodes using native inline styles for correct staggered delays */} -
- + {/* Floating Icons */} +
+
-
- +
-
- +
- - {/* Subtle Neon Center Glow */} -
-