Skip to content

Commit ae0ef87

Browse files
Merge pull request #156 from nidble/135
Fixed: #135 Search Button should be at top
2 parents 24c835d + 4fea02f commit ae0ef87

File tree

1 file changed

+22
-26
lines changed

1 file changed

+22
-26
lines changed

components/Hero.tsx

Lines changed: 22 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,30 @@ function Hero() {
2323
<div className="text-center hero-content">
2424
<div className="max-w-md">
2525
<h1 className="mb-5 text-2023-manga-3 text-5xl font-bold uppercase">
26-
Select your language
26+
Search your language
2727
</h1>
28+
<form
29+
className="form-control w-full max-w-xs mx-auto items-center mt-10 mb-12"
30+
onSubmit={handleSubmit}
31+
>
32+
<div className="flex w-full">
33+
<input
34+
type="text"
35+
placeholder="Search for your language"
36+
className="input input-bordered w-full text-neutral-100 border-2023-bavarian-gold-2 focus:outline-2023-bavarian-gold-2 max-w-xs rounded-tr-none rounded-br-none bg-transparent"
37+
name="search"
38+
/>
39+
<button
40+
type="submit"
41+
className="btn btn-square rounded-tl-none rounded-bl-none bg-transparent border-2023-manga-3 hover:bg-2023-manga-2 hover:text-2023-void-2 hover:border-2023-manga-2"
42+
>
43+
<SearchIcon />
44+
</button>
45+
</div>
46+
</form>
2847
<p className="mb-5 text-2023-manga-3 font-semibold uppercase">
29-
Select the programming language you would like to find repositories
30-
for.
48+
Or select the programming language you would like to find
49+
repositories for.
3150
</p>
3251

3352
{mainLanguages.map(language => (
@@ -52,29 +71,6 @@ function Hero() {
5271
))}
5372
</ul>
5473
</div>
55-
<form
56-
className="form-control w-full max-w-xs mx-auto items-center"
57-
onSubmit={handleSubmit}
58-
>
59-
<label className="label">
60-
<span className="label-text text-2023-manga-3">Can&apos;t find your language?</span>
61-
</label>
62-
<div className="flex">
63-
<input
64-
type="text"
65-
placeholder="Search for your language"
66-
className="input input-bordered w-full text-neutral-100 border-2023-bavarian-gold-2 focus:outline-2023-bavarian-gold-2 max-w-xs rounded-tr-none rounded-br-none bg-transparent"
67-
name="search"
68-
autoComplete="off"
69-
/>
70-
<button
71-
type="submit"
72-
className="btn btn-square rounded-tl-none rounded-bl-none bg-transparent border-2023-manga-3 hover:bg-2023-manga-2 hover:text-2023-void-2 hover:border-2023-manga-2"
73-
>
74-
<SearchIcon />
75-
</button>
76-
</div>
77-
</form>
7874
{/* <a href="https://github.com/max-programming/hacktoberfest-projects/">
7975
<button className="m-2 border-0 hover:bg-primary-2 hover:text-black btn btn-lg">
8076
Add another language

0 commit comments

Comments
 (0)