Skip to content
This repository was archived by the owner on May 4, 2025. It is now read-only.

Commit 246e143

Browse files
committed
Changed project submission link
1 parent 003d65f commit 246e143

File tree

1 file changed

+30
-13
lines changed

1 file changed

+30
-13
lines changed

src/components/projectsPage.tsx

Lines changed: 30 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,14 @@ const ProjectsPage = () => {
1212
const [sortBy, setSortBy] = useState("stars"); // Options: none, stars, name
1313
const [showFilters, setShowFilters] = useState(false);
1414

15-
const { projects, isLoading, rateLimit, refreshStars } = useGitHubStars(data.projects as Project[]);
15+
const { projects, isLoading, rateLimit, refreshStars } = useGitHubStars(
16+
data.projects as Project[],
17+
);
1618

1719
// Get unique tags from all projects
18-
const allTags = [...new Set(data.projects.flatMap((project: Project) => project.tags))];
20+
const allTags = [
21+
...new Set(data.projects.flatMap((project: Project) => project.tags)),
22+
];
1923

2024
const filteredProjects = projects.filter((project) => {
2125
const matchesSearch =
@@ -32,7 +36,7 @@ const ProjectsPage = () => {
3236
} else if (sortBy === "name") {
3337
return a.projectName.localeCompare(b.projectName);
3438
}
35-
return 0;
39+
return 0;
3640
});
3741

3842
const handleRefreshStars = () => {
@@ -55,7 +59,7 @@ const ProjectsPage = () => {
5559
</h1>
5660
<a
5761
className="flex justify-self-center h-fit w-fit p-2 bg-black rounded-md text-white"
58-
href="https://github.com/FOSS-Cell-GECPKD/Breakpoint?tab=readme-ov-file#how-to-add-your-project"
62+
href="https://opnform.com/forms/my-form-k1tkuv"
5963
>
6064
<PlusIcon />
6165
Add My Project
@@ -76,24 +80,33 @@ const ProjectsPage = () => {
7680
value={searchTerm}
7781
onChange={(e) => setSearchTerm(e.target.value)}
7882
/>
79-
<button
83+
<button
8084
className="md:hidden px-3 bg-white border border-l-0 rounded-r-lg flex items-center"
8185
onClick={() => setShowFilters(!showFilters)}
8286
>
83-
<Filter size={18} className={showFilters ? "text-yellow-500" : "text-gray-500"} />
87+
<Filter
88+
size={18}
89+
className={
90+
showFilters ? "text-yellow-500" : "text-gray-500"
91+
}
92+
/>
8493
</button>
8594
</div>
8695
</div>
87-
88-
<div className={`${showFilters || window.innerWidth >= 768 ? 'flex' : 'hidden'} flex-wrap md:flex gap-2 items-center`}>
96+
97+
<div
98+
className={`${showFilters || window.innerWidth >= 768 ? "flex" : "hidden"} flex-wrap md:flex gap-2 items-center`}
99+
>
89100
<select
90101
className="border rounded-lg px-3 py-2 bg-white flex-grow md:flex-grow-0 mb-2 md:mb-0"
91102
value={selectedTag}
92103
onChange={(e) => setSelectedTag(e.target.value)}
93104
>
94105
<option value="">All Tags</option>
95106
{allTags.map((tag) => (
96-
<option key={tag} value={tag}>{tag}</option>
107+
<option key={tag} value={tag}>
108+
{tag}
109+
</option>
97110
))}
98111
</select>
99112

@@ -120,10 +133,14 @@ const ProjectsPage = () => {
120133
{/* Rate limit warning */}
121134
{rateLimit && rateLimit.remaining < 10 && (
122135
<div className="bg-yellow-50 border border-yellow-200 text-yellow-800 p-3 rounded-md mb-4 flex items-start gap-2">
123-
<AlertCircle className="text-yellow-600 shrink-0 mt-1" size={20} />
136+
<AlertCircle
137+
className="text-yellow-600 shrink-0 mt-1"
138+
size={20}
139+
/>
124140
<p className="text-sm">
125-
<strong>GitHub API rate limit warning:</strong> {rateLimit.remaining} requests remaining.
126-
Rate limit will reset at {rateLimit.resetTime}.
141+
<strong>GitHub API rate limit warning:</strong>{" "}
142+
{rateLimit.remaining} requests remaining. Rate limit will reset
143+
at {rateLimit.resetTime}.
127144
</p>
128145
</div>
129146
)}
@@ -147,4 +164,4 @@ const ProjectsPage = () => {
147164
);
148165
};
149166

150-
export default ProjectsPage;
167+
export default ProjectsPage;

0 commit comments

Comments
 (0)