Skip to content

Commit 91a853b

Browse files
fix: fixed responsive behaviour
Closes #12
1 parent 13b9f95 commit 91a853b

File tree

1 file changed

+77
-8
lines changed

1 file changed

+77
-8
lines changed

frontend/src/pages/Home/Home.css

Lines changed: 77 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,16 @@
1515
}
1616

1717
html {
18-
width: 100%;
18+
width: 100vw;
1919
height: 100vh;
2020
background-color: var(--tertiary-accent);
2121
}
2222

2323
body {
24-
width: 100%;
24+
width: 100vw;
2525
height: 100vh;
2626
background-color: var(--tertiary-accent);
27+
flex: 0 0 auto;
2728
}
2829

2930
ul,
@@ -35,19 +36,18 @@ li {
3536

3637
main,
3738
.main-content {
38-
flex: 1;
39+
flex: 0 0 auto;
3940
}
4041

4142
#root {
4243
min-height: 100vh;
43-
width: 100%;
44+
width: 100vw;
4445
}
4546

4647
.main {
4748
display: flex;
48-
flex-flow: column nowrap;
49+
flex-flow: column wrap;
4950
width: calc(100vw - 2.1rem);
50-
margin: 0 auto;
5151
background-color: var(--secondary-accent);
5252
background-image: url("../../assets/home/texture.png");
5353
background-repeat: no-repeat;
@@ -278,9 +278,30 @@ h1 {
278278
}
279279
}
280280

281-
@media (max-width: 495px) {
281+
@media (min-width: 495px) and (max-width: 769px) {
282+
.controls {
283+
margin-top: 2rem;
284+
}
285+
.button-purple {
286+
margin-top: 2rem;
287+
}
288+
}
289+
290+
@media (min-width: 300px) and (max-width: 495px) {
291+
body {
292+
width: 100vw;
293+
}
294+
282295
.main {
283-
margin-top: -1.2rem;
296+
margin-top: 4rem;
297+
}
298+
299+
h1 {
300+
font-size: 80px;
301+
}
302+
303+
.sub-heading {
304+
font-size: 40px;
284305
}
285306

286307
.header {
@@ -294,4 +315,52 @@ h1 {
294315
margin-top: 1rem;
295316
border-radius: 10px;
296317
}
318+
319+
.controls {
320+
margin-top: 3rem;
321+
}
322+
323+
.button {
324+
width: 200px;
325+
}
326+
327+
.dropdown--semester {
328+
width: 100px;
329+
}
330+
331+
.sem-list__container {
332+
position: absolute;
333+
width: 120px;
334+
left: 45%;
335+
margin-top: 6px;
336+
}
337+
338+
.sem-list {
339+
grid-template-columns: repeat(2, 30px);
340+
padding: 10px;
341+
}
342+
343+
.sem-list__item {
344+
width: 30px;
345+
height: 30px;
346+
}
347+
348+
.arrowhead {
349+
left: 124%;
350+
margin-top: -15px;
351+
z-index: 2;
352+
}
353+
354+
.dropdown--branches {
355+
left: 30%;
356+
}
357+
358+
.branches__container {
359+
width: 120px;
360+
height: 250px;
361+
}
362+
363+
.arrowhead-branch {
364+
left: 65%;
365+
}
297366
}

0 commit comments

Comments
 (0)