From 76d404d1f457d39e782377335ae3ae50138fc887 Mon Sep 17 00:00:00 2001 From: jainiksha Date: Mon, 8 Jun 2026 14:29:34 +0530 Subject: [PATCH 1/3] feat: add repository health score dashboard card --- src/components/Dashboard.tsx | 73 +++++++++++++++++++++++++++++++++++- 1 file changed, 71 insertions(+), 2 deletions(-) diff --git a/src/components/Dashboard.tsx b/src/components/Dashboard.tsx index e28358f0..b77b1c17 100644 --- a/src/components/Dashboard.tsx +++ b/src/components/Dashboard.tsx @@ -11,8 +11,16 @@ import { Tooltip, Legend, ResponsiveContainer -} from 'recharts'; -import { Paper, Typography, Box, Grid, Theme } from '@mui/material'; +}from 'recharts'; + +import { + Paper, + Typography, + Box, + Grid, + Theme, + LinearProgress +} from '@mui/material'; interface GitHubItem { id: number; @@ -63,6 +71,21 @@ const Dashboard: React.FC = ({ totalIssues, totalPrs, data, them .slice(0, 5); const hasData = totalIssues > 0 || totalPrs > 0; + const totalContributions = totalIssues + totalPrs; + +const healthScore = Math.min( + 100, + Math.round((totalContributions / 50) * 100) +); + +const healthStatus = + healthScore >= 80 + ? "Excellent" + : healthScore >= 60 + ? "Good" + : healthScore >= 40 + ? "Moderate" + : "Poor"; if (!hasData) { return ( @@ -76,6 +99,52 @@ const Dashboard: React.FC = ({ totalIssues, totalPrs, data, them return ( + + + Repository Health Score + + + + {healthScore}/100 + + + = 80 + ? "success.main" + : healthScore >= 60 + ? "info.main" + : healthScore >= 40 + ? "warning.main" + : "error.main" + } +> + Status: {healthStatus} + + + + + {/* Pie Chart: Issues vs PRs */} From 90d3d8a6f287095d4541fb902138f44d71bb1ce0 Mon Sep 17 00:00:00 2001 From: jainiksha Date: Mon, 8 Jun 2026 14:48:07 +0530 Subject: [PATCH 2/3] feat: add contributor growth analytics chart --- src/components/Dashboard.tsx | 41 +++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) diff --git a/src/components/Dashboard.tsx b/src/components/Dashboard.tsx index b77b1c17..166f2bb1 100644 --- a/src/components/Dashboard.tsx +++ b/src/components/Dashboard.tsx @@ -87,6 +87,12 @@ const healthStatus = ? "Moderate" : "Poor"; + const contributorGrowthData = [ + { month: "Issues", contributions: totalIssues }, + { month: "PRs", contributions: totalPrs }, + { month: "Total", contributions: totalContributions }, +]; + if (!hasData) { return ( @@ -134,7 +140,7 @@ const healthStatus = > Status: {healthStatus} - + + + + + Contributor Growth Analytics + + + + + + + + + + + + + + + Top Repositories (Current View) From d0b1c6e0052663b410c8d241eb5454a791143714 Mon Sep 17 00:00:00 2001 From: jainiksha Date: Mon, 8 Jun 2026 14:57:45 +0530 Subject: [PATCH 3/3] feat: add github user comparison interface --- src/pages/Tracker/Tracker.tsx | 37 +++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/src/pages/Tracker/Tracker.tsx b/src/pages/Tracker/Tracker.tsx index 576f39bf..23c288f2 100644 --- a/src/pages/Tracker/Tracker.tsx +++ b/src/pages/Tracker/Tracker.tsx @@ -17,6 +17,7 @@ import { TableCell, TableContainer, TableHead, + Typography, TableRow, TablePagination, Link, @@ -78,6 +79,7 @@ const Home: React.FC = () => { const [selectedRepo, setSelectedRepo] = useState(""); const [startDate, setStartDate] = useState(""); const [endDate, setEndDate] = useState(""); + const [compareUsername, setCompareUsername] = useState(""); // Fetch data when username, tab, or page changes useEffect(() => { @@ -176,6 +178,15 @@ const Home: React.FC = () => { required sx={{ flex: 1, minWidth: 150 }} /> + + + setCompareUsername(e.target.value)} + sx={{ flex: 1, minWidth: 150 }} +/> + { Fetch Data - - + + {/* Filters */} + + + + Activity Comparison + + + + Primary User: {username || "N/A"} + + + + Compare User: {compareUsername || "N/A"} + + + + Issues: {totalIssues} + + + + Pull Requests: {totalPrs} + +