-
Notifications
You must be signed in to change notification settings - Fork 54
feat: add About CodeLens page with carousel and platform overview #196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
kunalverma2512
merged 4 commits into
kunalverma2512:main
from
Christina1507:about-codelens
Jun 13, 2026
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
80601d5
feat: add About CodeLens page with carousel and platform overview
Christina1507 1a71596
fix: improve carousel accessibility
Christina1507 2870180
style: refine About page design and content
Christina1507 67fe4c9
style: address final design review feedback
Christina1507 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,119 @@ | ||
| import { useEffect, useState } from "react"; | ||
|
|
||
| const slides = [ | ||
| { | ||
| title: "Competitive Programming", | ||
| description: | ||
| "Practice curated problems and strengthen problem-solving skills through structured learning.", | ||
| stat: "500+", | ||
| }, | ||
| { | ||
| title: "AlgoVerse", | ||
| description: | ||
| "Visualize algorithms and data structures with interactive learning experiences.", | ||
| stat: "DSA", | ||
| }, | ||
| { | ||
| title: "GitHub Intelligence", | ||
| description: | ||
| "Analyze repositories and gain deeper insights into development activity.", | ||
| stat: "GitHub", | ||
| }, | ||
| { | ||
| title: "APEX AI", | ||
| description: | ||
| "Leverage AI-powered tools to improve productivity and learning outcomes.", | ||
| stat: "AI", | ||
| }, | ||
| { | ||
| title: "Community Driven", | ||
| description: | ||
| "Built with community feedback and contributions to help learners grow together.", | ||
| stat: "Open", | ||
| }, | ||
| ]; | ||
|
|
||
| export default function AboutCarousel() { | ||
| const [current, setCurrent] = useState(0); | ||
| const [paused, setPaused] = useState(false); | ||
|
|
||
| useEffect(() => { | ||
| if (paused) return; | ||
|
|
||
| const timer = setInterval(() => { | ||
| setCurrent((prev) => (prev + 1) % slides.length); | ||
| }, 4500); | ||
|
|
||
| return () => clearInterval(timer); | ||
| }, [paused]); | ||
|
|
||
| return ( | ||
| <div | ||
| className="max-w-6xl mx-auto" | ||
| onMouseEnter={() => setPaused(true)} | ||
| onMouseLeave={() => setPaused(false)} | ||
| onFocus={() => setPaused(true)} | ||
| onBlur={() => setPaused(false)} | ||
| tabIndex={0} | ||
| aria-roledescription="carousel" | ||
| aria-label="Platform highlights" | ||
| onKeyDown={(e) => { | ||
| if (e.key === "ArrowRight") { | ||
| setCurrent((prev) => (prev + 1) % slides.length); | ||
| } | ||
|
|
||
| if (e.key === "ArrowLeft") { | ||
| setCurrent( | ||
| (prev) => (prev - 1 + slides.length) % slides.length | ||
| ); | ||
| } | ||
| }} | ||
| > | ||
|
Christina1507 marked this conversation as resolved.
|
||
| <div className="relative bg-black text-white p-10 md:p-14 overflow-hidden min-h-[320px]"> | ||
|
|
||
| <div | ||
| aria-hidden="true" | ||
| className="absolute top-4 right-6 text-[90px] md:text-[140px] font-black text-zinc-800 select-none" | ||
| > | ||
| {slides[current].stat} | ||
| </div> | ||
|
|
||
| <div | ||
| className="relative z-10 max-w-2xl" | ||
| aria-live="polite" | ||
| aria-atomic="true" | ||
| > | ||
| <p className="uppercase tracking-[0.25em] text-xs text-zinc-400 mb-4"> | ||
| Platform Highlight | ||
| </p> | ||
|
|
||
| <h3 className="text-4xl md:text-5xl font-black mb-6"> | ||
| {slides[current].title} | ||
| </h3> | ||
|
|
||
| <p className="text-zinc-300 text-lg leading-8"> | ||
| {slides[current].description} | ||
| </p> | ||
| </div> | ||
| </div> | ||
|
|
||
| <div className="flex justify-center gap-3 mt-8"> | ||
| {slides.map((slide, index) => ( | ||
| <button | ||
| key={index} | ||
| onClick={() => setCurrent(index)} | ||
| aria-label={`Go to slide ${index + 1}: ${slide.title}`} | ||
| aria-current={ | ||
| current === index ? "true" : undefined | ||
| } | ||
| className={`transition-all duration-300 rounded-full ${ | ||
| current === index | ||
| ? "w-10 h-3 bg-black" | ||
| : "w-3 h-3 bg-zinc-300" | ||
| }`} | ||
| /> | ||
|
Christina1507 marked this conversation as resolved.
|
||
| ))} | ||
| </div> | ||
| </div> | ||
| ); | ||
| } | ||
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.