Skip to content

Commit dc960cc

Browse files
authored
Merge pull request #256 from Dilpreet0501/nav
navbar added on top
2 parents 0b21a9d + b55aece commit dc960cc

File tree

6 files changed

+392
-75
lines changed

6 files changed

+392
-75
lines changed

package-lock.json

Lines changed: 134 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@
55
"dependencies": {
66
"@emotion/react": "^11.11.4",
77
"@emotion/styled": "^11.11.5",
8+
"@fortawesome/fontawesome": "^1.1.8",
9+
"@fortawesome/fontawesome-free-regular": "^5.0.13",
10+
"@fortawesome/fontawesome-free-solid": "^5.0.13",
11+
"@fortawesome/fontawesome-svg-core": "^6.5.2",
12+
"@fortawesome/react-fontawesome": "^0.2.2",
813
"@mui/icons-material": "^5.15.19",
914
"@testing-library/jest-dom": "^5.11.4",
1015
"@testing-library/react": "^11.1.0",

src/Components/Container.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
width: 350px;
2727
height: 45px;
2828
position: relative;
29+
padding-right: 20px;
2930
}
3031
.searchbtn{
3132
position: absolute;

src/Components/TopContainer.css

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
.navbar {
2+
width: 100%;
3+
height: 100px;
4+
background: #19162c;
5+
display: flex;
6+
flex-direction: row;
7+
justify-content: space-between;
8+
align-items: center;
9+
box-shadow: 0px 0px 20px rgba(0, 0, 0, 0.4);
10+
position: sticky;
11+
top: 0;
12+
z-index: 99999;
13+
}
14+
15+
#list {
16+
display: inline;
17+
padding: 20px;
18+
}
19+
20+
.mobview {
21+
display: none;
22+
}
23+
24+
@media screen and (max-width: 1500px) {
25+
.mobview {
26+
display: flex;
27+
flex-direction: column;
28+
position: relative;
29+
}
30+
31+
.bars {
32+
padding: 20px;
33+
cursor: pointer;
34+
}
35+
36+
.largeview {
37+
display: none;
38+
}
39+
40+
.mobview #shortview {
41+
position: absolute;
42+
right: 15px;
43+
top: 60px;
44+
background: rgba(0, 0, 0, 0.8);
45+
border-radius: 10px;
46+
width: 200px;
47+
box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
48+
z-index: 100000;
49+
display: none;
50+
transition: transform 0.3s cubic-bezier(0.17, 0.81, 0.38, 1.39);
51+
}
52+
53+
.mobview #shortview:after {
54+
position: absolute;
55+
content: "";
56+
width: 10px;
57+
height: 10px;
58+
background: hsl(190, 85%, 40%);
59+
top: -5px;
60+
right: 20px;
61+
transform: rotate(45deg);
62+
}
63+
64+
#shortview.show {
65+
display: flex;
66+
flex-direction: column;
67+
align-items: center;
68+
}
69+
70+
.mobview #shortview ul {
71+
width: 100%;
72+
height: 100%;
73+
margin: 0;
74+
padding: 0;
75+
}
76+
77+
.mobview #shortview ul li {
78+
list-style: none;
79+
margin: 0;
80+
width: 100%;
81+
padding: 10px 15px;
82+
cursor: pointer;
83+
color: #757380;
84+
text-align: center;
85+
font-size: 14px;
86+
87+
}
88+
89+
90+
91+
.mobview #shortview ul li:hover {
92+
background: #19162c; /* Light background on hover */
93+
color: #757380;
94+
transition: 0.3s;
95+
}
96+
}
97+
98+
99+

0 commit comments

Comments
 (0)