-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathHeader.js
42 lines (39 loc) · 848 Bytes
/
Header.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import React from "react";
import { NavLink } from "react-router-dom";
import styled from "styled-components";
import Nav from "./Nav";
const Header = () => {
return (
<MainHeader>
<NavLink to="/">
<img src="./images/logo.png" alt="my logo img" />
</NavLink>
<Nav/>
</MainHeader>
);
};
const MainHeader = styled.header`
padding: 0 4.8rem;
height: 10rem;
background-color: ${({ theme }) => theme.colors.bg};
display: flex;
justify-content: space-between;
align-items: center;
position: relative;
.logo {
height: 5rem;
}
img{
position:absolute;
top:5px;
left:0px;
}
@media (max-width: ${({ theme }) => theme.media.mobile}) {
img{
position:absolute;
top:-4px;
left:-24px;
}
}
`;
export default Header;