Skip to content

Commit 13b9f95

Browse files
fix: resolved alignment issues
1 parent 3e7b5ee commit 13b9f95

File tree

2 files changed

+34
-14
lines changed

2 files changed

+34
-14
lines changed

frontend/src/pages/Home/Home.css

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ main,
4444
}
4545

4646
.main {
47+
display: flex;
48+
flex-flow: column nowrap;
4749
width: calc(100vw - 2.1rem);
4850
margin: 0 auto;
4951
background-color: var(--secondary-accent);
@@ -53,6 +55,9 @@ main,
5355
min-height: 100vh;
5456
border-radius: 20px;
5557
margin-top: 7.1rem;
58+
justify-content: center;
59+
align-items: center;
60+
gap: 2rem;
5661
}
5762

5863
.header {
@@ -73,14 +78,14 @@ main,
7378
.heading {
7479
width: 100%;
7580
padding: 1rem;
76-
padding-top: 10rem;
7781
}
7882

7983
h1 {
8084
font-family: "Urbanist", sans-serif;
8185
color: var(--tertiary-accent);
8286
font-weight: 700;
8387
text-align: center;
88+
font-size: 6rem;
8489
}
8590

8691
.sub-heading {
@@ -92,11 +97,17 @@ h1 {
9297
}
9398

9499
.controls {
95-
width: 100%;
100+
position: relative;
101+
width: 60%;
96102
display: flex;
97-
gap: 3rem;
103+
flex-wrap: wrap;
104+
gap: 2rem;
98105
justify-content: space-evenly;
99-
margin-top: 10rem;
106+
margin-top: 8rem;
107+
}
108+
109+
.controls__semester {
110+
position: relative;
100111
}
101112

102113
.button {
@@ -121,10 +132,11 @@ h1 {
121132
}
122133

123134
.dropdown--semester {
124-
position: relative;
135+
position: absolute;
125136
width: 250px;
126-
top: -5%;
137+
top: 80%;
127138
left: 12%;
139+
z-index: 2;
128140
}
129141

130142
.arrowhead {
@@ -177,11 +189,15 @@ h1 {
177189
transition: transform 0.8s ease;
178190
}
179191

180-
.dropdown--branches {
192+
.controls__branch {
181193
position: relative;
194+
}
195+
196+
.dropdown--branches {
197+
position: absolute;
182198
left: 9%;
183-
top: -3%;
184-
z-index: 1;
199+
top: 90%;
200+
z-index: 2;
185201
}
186202

187203
.branches__container {
@@ -194,7 +210,7 @@ h1 {
194210

195211
.arrowhead-branch {
196212
position: absolute;
197-
left: 60%;
213+
left: 71.2%;
198214
top: -7%;
199215
}
200216

@@ -222,7 +238,6 @@ h1 {
222238
}
223239

224240
.button-purple {
225-
position: absolute;
226241
width: 200px;
227242
background-color: var(--primary-accent);
228243
height: 60px;
@@ -232,10 +247,9 @@ h1 {
232247
align-items: center;
233248
font-size: 25px;
234249
border-radius: 30px;
235-
margin: 6rem auto;
236250
cursor: pointer;
237251
transition: all 0.5s ease;
238-
bottom: 5%;
252+
margin-top: 5rem;
239253
z-index: 0;
240254
}
241255

frontend/src/pages/Home/Home.jsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,13 @@ export default function Home() {
175175
</div>
176176
</div>
177177
</div>
178-
<div className="button-purple">
178+
<div
179+
className="button-purple"
180+
onClick={() => {
181+
setBranchDropdown(false);
182+
setSemDropdown(false);
183+
}}
184+
>
179185
<p>Done</p>
180186
</div>
181187
</div>

0 commit comments

Comments
 (0)