File tree Expand file tree Collapse file tree 3 files changed +23
-10
lines changed
components/General/NavigationBar Expand file tree Collapse file tree 3 files changed +23
-10
lines changed Original file line number Diff line number Diff line change 1
- .LINKS {
1
+ /* Desktop and Mobile Navigation links */
2
+ .DESKTOP-LINKS {
2
3
@apply font-semibold rounded-2xl bg-white/20 shadow-lg ring-2 ring-black/10 px-3 py-4;
3
4
}
4
- .LINKS-ACTIVE {
5
+ .DESKTOP- LINKS-ACTIVE {
5
6
@apply text-black rounded-xl shadow-lg border-1 p-3;
6
7
}
8
+ .MOBILE-LINKS {
9
+ @apply font-semibold rounded-xl bg-white/20 shadow-lg ring-2 ring-black/10 p-3;
10
+ }
7
11
12
+ /* Button */
8
13
.BUTTON {
9
14
@apply font-semibold rounded-2xl bg-white shadow-lg ring-2 px-4 py-4;
10
15
}
Original file line number Diff line number Diff line change 1
1
import React from 'react' ;
2
2
import { NavLink , Link } from 'react-router-dom' ;
3
3
4
+ // ICONS
5
+ import { HiMenuAlt3 } from 'react-icons/hi' ;
4
6
// UTILS
5
7
import Logo from '../../../utils/Logo/Logo' ;
6
8
// DATA
@@ -10,15 +12,16 @@ const NavigationBar: React.FC = () => {
10
12
return (
11
13
< div className = "w-full h-[9vh] BG-BLACK-PRIMARY FLEX-BETWEEN PADDING" >
12
14
< Logo className = "font-style-logo text-4xl TEXT-WHITE-PRIMARY" />
13
- < div className = "RESPONSIVE-CENTER-BLOCK gap-4" >
14
- < div className = "LINKS" >
15
+ { /* Desktop Navigation Bar */ }
16
+ < div className = "hidden FLEX-CENTER-LG gap-4" >
17
+ < div className = "DESKTOP-LINKS" >
15
18
< ul className = "TEXT-COLOR-PRIMARY FLEX-CENTER gap-6" >
16
19
{ NAVIGATION_LINKS . map ( ( { name, path } , id ) => (
17
20
< li key = { id } className = "GRAY-300 TEXT-WHITE-PRIMARY-HOVER" >
18
21
< NavLink
19
22
to = { path }
20
23
className = { ( { isActive } ) =>
21
- isActive ? 'LINKS-ACTIVE BG-WHITE-PRIMARY' : ''
24
+ isActive ? 'DESKTOP- LINKS-ACTIVE BG-WHITE-PRIMARY' : ''
22
25
}
23
26
>
24
27
{ name }
@@ -31,6 +34,10 @@ const NavigationBar: React.FC = () => {
31
34
Contract
32
35
</ Link >
33
36
</ div >
37
+ { /* Mobile Navigation Bar */ }
38
+ < div className = "lg:hidden MOBILE-LINKS POINTER" >
39
+ < HiMenuAlt3 size = { 20 } className = "TEXT-WHITE-PRIMARY" />
40
+ </ div >
34
41
</ div >
35
42
) ;
36
43
} ;
Original file line number Diff line number Diff line change 27
27
.FLEX-CENTER {
28
28
@apply flex items-center justify-center;
29
29
}
30
+ .FLEX-CENTER-LG {
31
+ @apply lg:flex items-center justify-center;
32
+ }
30
33
.FLEX-BETWEEN {
31
34
@apply flex items-center justify-between;
32
35
}
36
+ .FLEX-END {
37
+ @apply flex items-center justify-end;
38
+ }
33
39
34
40
.PADDING {
35
41
@apply px-5;
38
44
.POINTER {
39
45
@apply hover:cursor-pointer;
40
46
}
41
-
42
- /* RESPONSIVE */
43
- .RESPONSIVE-CENTER-BLOCK {
44
- @apply hidden lg:flex items-center justify-center;
45
- }
You can’t perform that action at this time.
0 commit comments