forked from cerebral/overmind
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathelements.tsx
More file actions
52 lines (48 loc) · 1.41 KB
/
elements.tsx
File metadata and controls
52 lines (48 loc) · 1.41 KB
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
43
44
45
46
47
48
49
50
51
52
import styled from '../../styled-components'
export const Wrapper = styled.div`
position: fixed;
z-index: 2;
background-color: ${({ theme }) =>
theme.color.lighten(theme.color.dark, -0.25)};
height: 50px;
top: -50px;
color: ${({ theme }) => theme.color.white};
transition: top 0.5s ease-out;
width: 100%;
display: flex;
align-items: center;
justify-content: space-between;
box-sizing: border-box;
padding: ${({ theme }) => `0 ${theme.padding.small}`};
`
export const MenuWrapper = styled.div`
position: fixed;
left: 0;
top: 0;
transform: translate3d(-110vw, 0, 0);
transition: transform 0.2s ease-in-out;
width: 100vw;
height: 100vh;
`
export const Menu = styled.div`
background-color: ${({ theme }) => theme.color.white};
box-shadow: 10px 0px 41px 6px rgba(0, 0, 0, 0.35);
width: 250px;
height: 100vh;
display: flex;
flex-direction: column;
overflow-y: scroll;
-webkit-overflow-scrolling: touch;
border-right: 2px solid ${({ theme }) => theme.color.primary};
padding: ${({ theme }) => theme.padding.small};
padding-bottom: ${({ theme }) => theme.padding.large};
box-sizing: border-box;
`
export const Link = styled<{ selected?: boolean }, 'a'>('a')`
text-decoration: none;
color: ${({ selected, theme }) =>
selected ? theme.color.primary : theme.color.black};
margin: ${({ theme }) => theme.padding.small};
cursor: pointer;
text-transform: uppercase;
`