1
1
import React , { useState } from 'react' ;
2
2
import { Link } from 'react-router-dom' ;
3
3
import Avatar from '@mui/material/Avatar' ;
4
+ import Button from '@mui/material/Button' ;
5
+ import MoreVertIcon from '@mui/icons-material/MoreVert' ;
6
+ import NavBarButtons from './NavBarButtons' ;
4
7
import NavbarDropDown from './NavBarButtons' ;
8
+ import NewExportButton from './NewExportButton' ;
5
9
import { RootState } from '../../redux/store' ;
6
10
import logo from '../../public/icons/win/logo.png' ;
7
- import NewExportButton from './NewExportButton' ;
8
11
import { useSelector } from 'react-redux' ;
9
- import Button from '@mui/material/Button' ;
10
- import MoreVertIcon from '@mui/icons-material/MoreVert' ;
11
- import NavBarButtons from './NavBarButtons' ;
12
12
13
13
const NavBar = ( ) => {
14
14
const [ dropMenu , setDropMenu ] = useState ( false ) ;
15
- const isDarkMode = useSelector ( ( state : RootState ) => state . darkMode . isDarkMode ) ;
15
+ const isDarkMode = useSelector (
16
+ ( state : RootState ) => state . darkMode . isDarkMode
17
+ ) ;
16
18
17
19
const buttonContainerStyle = {
18
20
display : 'flex' ,
19
21
alignItems : 'center' ,
20
- justifyContent : 'flex-start' ,
22
+ justifyContent : 'flex-start'
21
23
} ;
22
24
23
25
const buttonStyle = {
@@ -28,31 +30,40 @@ const NavBar = () => {
28
30
padding : '8px 12px' ,
29
31
cursor : 'pointer' ,
30
32
marginRight : '10px' ,
31
- marginLeft : '5px' ,
32
- borderRadius : '4px' ,
33
+ marginLeft : '5px' ,
34
+ borderRadius : '4px'
33
35
} ;
34
36
35
37
const moreVertButtonStyle = {
36
38
backgroundColor : '#333' ,
37
39
border : '1px solid #333' ,
38
40
padding : '0' ,
39
41
cursor : 'pointer' ,
40
- display : 'flex' ,
41
- alignItems : 'center' ,
42
- justifyContent : 'flex-start' ,
42
+ display : 'flex' ,
43
+ alignItems : 'center' ,
44
+ justifyContent : 'flex-start' ,
43
45
borderRadius : '4px' ,
44
- width : '30px' ,
46
+ width : '30px' ,
45
47
minWidth : '20px' ,
46
- marginLeft : '0px' ,
47
- marginRight : '10px' ,
48
+ marginLeft : '0px' ,
49
+ marginRight : '10px'
48
50
} ;
49
51
50
52
return (
51
- < nav className = "main-navbar" style = { isDarkMode ? { backgroundColor : '#013365' } : { backgroundColor : 'white' } } >
52
- < Link to = "/" style = { { textDecoration : 'none' } } >
53
+ < nav
54
+ className = "main-navbar"
55
+ style = {
56
+ isDarkMode
57
+ ? { backgroundColor : '#013365' }
58
+ : { backgroundColor : '#151515' }
59
+ }
60
+ >
61
+ < Link to = "/" style = { { textDecoration : 'none' } } >
53
62
< div className = "main-logo" >
54
63
< Avatar src = { logo } > </ Avatar >
55
- < h1 style = { isDarkMode ? { color : 'white' } : { color : '#013365' } } > ReacType</ h1 >
64
+ < h1 style = { isDarkMode ? { color : 'white' } : { color : 'white' } } >
65
+ ReacType
66
+ </ h1 >
56
67
</ div >
57
68
</ Link >
58
69
< div style = { buttonContainerStyle } >
@@ -66,7 +77,11 @@ const NavBar = () => {
66
77
>
67
78
< MoreVertIcon style = { { color : 'white' } } />
68
79
</ Button >
69
- < NavBarButtons dropMenu = { dropMenu } setDropMenu = { setDropMenu } style = { { color : 'white' } } />
80
+ < NavBarButtons
81
+ dropMenu = { dropMenu }
82
+ setDropMenu = { setDropMenu }
83
+ style = { { color : 'white' } }
84
+ />
70
85
</ div >
71
86
</ nav >
72
87
) ;
0 commit comments