Skip to content

Commit 91abc74

Browse files
committed
Merge branch 'main' of github.com:Keith-Web3/hacktoberfest-projects into OpenIssues
2 parents 9443a84 + 003df5a commit 91abc74

14 files changed

+57
-12
lines changed

.all-contributorsrc

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"login": "max-programming",
1010
"name": "Max Programming",
1111
"avatar_url": "https://avatars.githubusercontent.com/u/51731966?v=4",
12-
"profile": "https://usman-s.me",
12+
"profile": "https://usmans.me",
1313
"contributions": [
1414
"code"
1515
]
@@ -362,6 +362,36 @@
362362
"code",
363363
"design"
364364
]
365+
},
366+
{
367+
"login": "Mohit030802",
368+
"name": "Mohit",
369+
"avatar_url": "https://avatars.githubusercontent.com/u/80634689?v=4",
370+
"profile": "https://bright-ganache-eb99ae.netlify.app/",
371+
"contributions": [
372+
"code",
373+
"ideas"
374+
]
375+
},
376+
{
377+
"login": "tmsagarofficial",
378+
"name": "S A G A R",
379+
"avatar_url": "https://avatars.githubusercontent.com/u/110724849?v=4",
380+
"profile": "https://github.com/tmsagarofficial",
381+
"contributions": [
382+
"ideas",
383+
"code"
384+
]
385+
},
386+
{
387+
"login": "prithvi2k2",
388+
"name": "Prithvi Reddy",
389+
"avatar_url": "https://avatars.githubusercontent.com/u/72189314?v=4",
390+
"profile": "https://prithvi2k2.github.io/",
391+
"contributions": [
392+
"code",
393+
"design"
394+
]
365395
}
366396
],
367397
"contributorsPerLine": 7,

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
# Hacktoberfest Projects 🎉
22

3-
A Web app that lets you find eligible repositories for Hacktoberfest 2022!
3+
4+
A Web app that lets you find eligible repositories for Hacktoberfest!
45

56
Use it here - https://finder.usmans.me
67

78
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
8-
[![All Contributors](https://img.shields.io/badge/all_contributors-37-orange.svg?style=flat-square)](#contributors-)
9+
[![All Contributors](https://img.shields.io/badge/all_contributors-40-orange.svg?style=flat-square)](#contributors-)
910
<!-- ALL-CONTRIBUTORS-BADGE:END -->
1011
<a href="https://gitmoji.dev">
1112
<img src="https://img.shields.io/badge/gitmoji-%20😜%20😍-FFDD67.svg?style=flat-square" alt="Gitmoji">
@@ -75,7 +76,7 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
7576
<table>
7677
<tbody>
7778
<tr>
78-
<td align="center" valign="top" width="14.28%"><a href="https://usman-s.me"><img src="https://avatars.githubusercontent.com/u/51731966?v=4?s=100" width="100px;" alt="Max Programming"/><br /><sub><b>Max Programming</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=max-programming" title="Code">💻</a></td>
79+
<td align="center" valign="top" width="14.28%"><a href="https://usmans.me"><img src="https://avatars.githubusercontent.com/u/51731966?v=4?s=100" width="100px;" alt="Max Programming"/><br /><sub><b>Max Programming</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=max-programming" title="Code">💻</a></td>
7980
<td align="center" valign="top" width="14.28%"><a href="https://sunritjana.now.sh"><img src="https://avatars.githubusercontent.com/u/56873669?v=4?s=100" width="100px;" alt="Sunrit Jana"/><br /><sub><b>Sunrit Jana</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=janaSunrise" title="Code">💻</a></td>
8081
<td align="center" valign="top" width="14.28%"><a href="https://medium.com/@geeknees"><img src="https://avatars.githubusercontent.com/u/701242?v=4?s=100" width="100px;" alt="Masumi Kawasaki"/><br /><sub><b>Masumi Kawasaki</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=geeknees" title="Code">💻</a> <a href="#content-geeknees" title="Content">🖋</a></td>
8182
<td align="center" valign="top" width="14.28%"><a href="http://rishit-khandelwal.github.io"><img src="https://avatars.githubusercontent.com/u/65018379?v=4?s=100" width="100px;" alt="Rishit Khandelwal"/><br /><sub><b>Rishit Khandelwal</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=rishit-khandelwal" title="Code">💻</a> <a href="#content-rishit-khandelwal" title="Content">🖋</a></td>
@@ -122,6 +123,9 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
122123
<tr>
123124
<td align="center" valign="top" width="14.28%"><a href="https://maitri-vv.github.io/Maitri-sPortfolio/"><img src="https://avatars.githubusercontent.com/u/87691594?v=4?s=100" width="100px;" alt="maitri-vv"/><br /><sub><b>maitri-vv</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=maitri-vv" title="Code">💻</a></td>
124125
<td align="center" valign="top" width="14.28%"><a href="https://dev.to/nidble/"><img src="https://avatars.githubusercontent.com/u/1447119?v=4?s=100" width="100px;" alt="Antonino Bertulla"/><br /><sub><b>Antonino Bertulla</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=nidble" title="Code">💻</a> <a href="#design-nidble" title="Design">🎨</a></td>
126+
<td align="center" valign="top" width="14.28%"><a href="https://bright-ganache-eb99ae.netlify.app/"><img src="https://avatars.githubusercontent.com/u/80634689?v=4?s=100" width="100px;" alt="Mohit"/><br /><sub><b>Mohit</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=Mohit030802" title="Code">💻</a> <a href="#ideas-Mohit030802" title="Ideas, Planning, & Feedback">🤔</a></td>
127+
<td align="center" valign="top" width="14.28%"><a href="https://github.com/tmsagarofficial"><img src="https://avatars.githubusercontent.com/u/110724849?v=4?s=100" width="100px;" alt="S A G A R"/><br /><sub><b>S A G A R</b></sub></a><br /><a href="#ideas-tmsagarofficial" title="Ideas, Planning, & Feedback">🤔</a> <a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=tmsagarofficial" title="Code">💻</a></td>
128+
<td align="center" valign="top" width="14.28%"><a href="https://prithvi2k2.github.io/"><img src="https://avatars.githubusercontent.com/u/72189314?v=4?s=100" width="100px;" alt="Prithvi Reddy"/><br /><sub><b>Prithvi Reddy</b></sub></a><br /><a href="https://github.com/max-programming/hacktoberfest-projects/commits?author=prithvi2k2" title="Code">💻</a> <a href="#design-prithvi2k2" title="Design">🎨</a></td>
125129
</tr>
126130
</tbody>
127131
</table>

components/Hero.tsx

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { FormEventHandler } from 'react';
1+
import { FormEventHandler, useState } from 'react';
22
import Link from 'next/link';
33

44
import languages from 'assets/languages.json';
@@ -10,11 +10,19 @@ import Button from './Button';
1010
const { main: mainLanguages, others: otherLanguages } = languages;
1111

1212
function Hero() {
13+
const [errorMessage, setErrorMessage] = useState<string | null>(null);
1314
const router = useRouter();
1415
const handleSubmit: FormEventHandler = e => {
1516
e.preventDefault();
1617
const formData = new FormData(e.target as HTMLFormElement);
17-
const search = formData.get('search');
18+
const search = (formData.get('search') as string).trim();
19+
// Check if the input is empty or contains only spaces
20+
if (search === '') {
21+
setErrorMessage('Empty search terms invalid!');
22+
return;
23+
}
24+
// Clear any previous error message & proceed to search
25+
setErrorMessage(null);
1826
router.push(`/repos/${search}`);
1927
};
2028
return (

components/Search.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ interface FormValues {
66
searchQuery: string;
77
}
88
export interface SearchProps {
9-
searchBarWrapperStyles?: string
9+
searchBarWrapperStyles?: string;
1010
}
1111

1212
export default function Search({ searchBarWrapperStyles }: SearchProps) {
@@ -19,7 +19,11 @@ export default function Search({ searchBarWrapperStyles }: SearchProps) {
1919
});
2020

2121
const onSubmit: SubmitHandler<FormValues> = ({ searchQuery }) => {
22-
router.push({ query: { ...router.query, q: searchQuery } });
22+
let trimmedQuery = searchQuery.trim();
23+
//Performs search only with non-empty strings
24+
if (trimmedQuery !== '') {
25+
router.push({ query: { ...router.query, q: trimmedQuery } });
26+
}
2327
};
2428

2529
return (
@@ -40,7 +44,7 @@ export default function Search({ searchBarWrapperStyles }: SearchProps) {
4044
type="button"
4145
onClick={() => reset()}
4246
>
43-
<GoX />
47+
<GoX color="white" />
4448
</button>
4549
</div>
4650
</form>

pages/_app.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import '@fontsource/poppins';
99
import '../styles/globals.css';
1010

1111
import type { AppProps } from 'next/app';
12+
import Footer from 'components/Footer';
1213

1314
function MyApp({ Component, pageProps, router }: AppProps) {
1415
return (
@@ -37,6 +38,7 @@ function MyApp({ Component, pageProps, router }: AppProps) {
3738
<DefaultSeo {...SEO} />
3839
<NextNProgress color="#ffd74d" options={{ showSpinner: false }} />
3940
<Component {...pageProps} />
41+
<Footer />
4042
</motion.div>
4143
);
4244
}

pages/contributors.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ export default function Contrubutors({ contributors }: Props) {
4444
))}
4545
</div>
4646
</div>
47-
<Footer />
4847
</div>
4948
);
5049
}

pages/index.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,7 @@ const Home: NextPage = () => {
2727

2828
<Header />
2929
<Hero />
30-
<Footer />
3130
</div>
3231
);
3332
};
34-
3533
export default Home;

public/android-chrome-192x192.png

-25.3 KB
Loading

public/android-chrome-256x256.png

-44.1 KB
Loading

public/apple-touch-icon.ico

8.48 KB
Binary file not shown.

0 commit comments

Comments
 (0)