diff --git a/src/pages/ComparePage.jsx b/src/pages/ComparePage.jsx
index 1a1f7ec..fb67067 100644
--- a/src/pages/ComparePage.jsx
+++ b/src/pages/ComparePage.jsx
@@ -1,7 +1,22 @@
-import { useState, useEffect } from 'react';
+import { useState, useEffect, useMemo } from 'react';
import { useApp } from '@/context/AppContext';
import { getRepo, getContributors, getCommunityProfile, searchRepos } from '@/api/github';
-import { FiPlus, FiX, FiSearch, FiStar, FiGitBranch, FiAlertCircle, FiShield, FiUsers, FiClock, FiTrash2, FiBookmark, FiCheck } from 'react-icons/fi';
+import {
+ FiPlus,
+ FiX,
+ FiSearch,
+ FiStar,
+ FiGitBranch,
+ FiAlertCircle,
+ FiShield,
+ FiUsers,
+ FiClock,
+ FiTrash2,
+ FiCopy,
+ FiShare2,
+ FiBookmark,
+ FiCheck,
+} from "react-icons/fi";
import { formatNumber } from '@/utils/format';
function formatDate(d) {
@@ -47,6 +62,23 @@ export default function ComparePage() {
loadAll();
}, [compareList]);
+ useEffect(() => {
+ const params = new URLSearchParams(window.location.search);
+
+ const repos = params.get("repos");
+
+ if (!repos) return;
+
+ repos.split(",").forEach(async(fullName) => {
+ const [owner, repo] = fullName.split("/");
+
+ try{
+ const repository = await getRepo(owner, repo);
+ addToCompare(repository);
+ } catch (_) {}
+ });
+ }, [addToCompare]);
+
const handleSearch = async (e) => {
e.preventDefault();
if (!searchQuery.trim()) return;
@@ -79,6 +111,47 @@ export default function ComparePage() {
{ key: 'created', label: 'Created', icon: