From e6973d07fafb1468091afa4fa56d96c7715924a1 Mon Sep 17 00:00:00 2001 From: Aditya948351 Date: Mon, 18 May 2026 15:23:02 +0530 Subject: [PATCH 1/4] docs: add JSDoc annotations and documentation to QuizComponent --- src/components/resources/QuizComponent.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/components/resources/QuizComponent.tsx b/src/components/resources/QuizComponent.tsx index 8fef9fe5..8b7130df 100644 --- a/src/components/resources/QuizComponent.tsx +++ b/src/components/resources/QuizComponent.tsx @@ -2,6 +2,10 @@ import { useState } from "react"; import styles from "./QuizComponent.module.css"; import { useGamification } from "../../context/GamificationContext"; +/** + * Static list of quiz questions used for developer resource testing. + * Each question contains a prompt, list of choice options, and the correct answer. + */ const questions = [ { question: "What is React?", @@ -15,6 +19,11 @@ const questions = [ }, ]; +/** + * QuizComponent renders an interactive quiz interface. + * On completion, it calculates the user's score and awards gamification XP + * through the global GamificationContext depending on performance. + */ export default function QuizComponent() { const { addXp } = useGamification(); From c7e13ced2fb81a3fc8e9ad01fdd259646b876bf1 Mon Sep 17 00:00:00 2001 From: Aditya948351 Date: Mon, 18 May 2026 15:23:25 +0530 Subject: [PATCH 2/4] docs: add JSDoc annotations and description to UserProfile --- src/components/profile/UserProfile.tsx | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/components/profile/UserProfile.tsx b/src/components/profile/UserProfile.tsx index 9a6845dd..408f2ce7 100644 --- a/src/components/profile/UserProfile.tsx +++ b/src/components/profile/UserProfile.tsx @@ -21,6 +21,14 @@ import { db } from '@/lib/firebase'; import { calculateLevel } from '@/lib/points'; import { getEmbedUrl } from '@/lib/utils'; +/** + * UserProfile component renders the main dashboard profile page for authenticated developers. + * It manages: + * - Local layout state for editing avatars and bios. + * - Loading and sorting uploaded developer projects from Firestore. + * - Real-time calculations of gamification Dev Points, progress levels, and achievements. + * - Rendering animated progress rings and privacy toggle modals. + */ export default function UserProfile() { const { user, logout, updateUserProfile } = useAuth(); const router = useRouter(); @@ -37,6 +45,10 @@ export default function UserProfile() { const levelInfo = calculateLevel(user?.points || 0); const targetProgress = levelInfo.progress; + /** + * Triggers animated loading effect for the custom circular progress ring + * once the component is mounted. + */ useEffect(() => { if (user) { const timer = setTimeout(() => { From f36f464f399c1f6e6961b998a89ec25f97d936ff Mon Sep 17 00:00:00 2001 From: Aditya948351 Date: Mon, 18 May 2026 15:23:50 +0530 Subject: [PATCH 3/4] docs: add Firebase Hosting deployment guide to README --- README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/README.md b/README.md index 69b2ab02..4e8ae12e 100644 --- a/README.md +++ b/README.md @@ -136,6 +136,22 @@ To run this project locally, you'll need your own Firebase project: 5. **Open your browser:** Navigate to [http://localhost:3000](http://localhost:3000) to see the application running. +### 🚀 Firebase Hosting Deployment + +To deploy the production-ready site directly to Firebase Hosting: + +1. **Build the production static export**: + This compiles the Next.js App Router files into highly optimized static assets inside the `out/` directory: + ```bash + npm run build + ``` + +2. **Deploy to Firebase**: + Deploy the build files along with custom Firestore indexes and rules to the live platform: + ```bash + npx firebase deploy + ``` + ## 📜 Scripts - `npm run dev`: Starts the development server. From 8d7e223318b7cc9c4dbe3a64f06c5e3f802da703 Mon Sep 17 00:00:00 2001 From: Aditya948351 Date: Mon, 18 May 2026 15:38:48 +0530 Subject: [PATCH 4/4] feat: display lines and commits contributed in GitHub stats with organizational consolidation --- src/app/layout.tsx | 7 ++ src/app/opensource/page.tsx | 12 +++- src/app/u/client.tsx | 27 +++++-- src/components/profile/UserProfile.tsx | 23 ++++-- src/context/AuthContext.tsx | 3 + src/lib/github.ts | 97 ++++++++++++++++++++++++++ 6 files changed, 155 insertions(+), 14 deletions(-) diff --git a/src/app/layout.tsx b/src/app/layout.tsx index d7d504ae..d24e3fd6 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -93,6 +93,13 @@ export default function RootLayout({ }>) { return ( + +