forked from codesandbox/codesandbox-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_elements.js
More file actions
162 lines (138 loc) · 3.09 KB
/
_elements.js
File metadata and controls
162 lines (138 loc) · 3.09 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
import styled, { css } from 'styled-components';
import { Link } from 'gatsby';
import RightArrow from 'react-icons/lib/md/keyboard-arrow-right';
import LeftArrow from 'react-icons/lib/md/keyboard-arrow-left';
export const Dots = styled.div`
display: flex !important;
position: relative;
list-style: none;
align-items: center;
justify-content: center;
font-size: 0.5rem;
`;
export const DotContainer = styled.div`
height: 16px;
width: 60px;
display: flex;
justify-content: center;
align-items: center;
`;
export const Dot = styled.button`
transition: 0.3s ease all;
border-radius: 100%;
width: 8px;
height: 8px;
border: 0;
outline: 0;
padding: 0;
background-color: ${props => props.color};
cursor: pointer;
${props =>
props.active
? css`
width: 12px;
height: 12px;
`
: css`
&:hover {
width: 12px;
height: 12px;
}
`};
`;
export const Container = styled.div`
color: ${props => props.theme.new.title};
padding-top: 4rem;
margin-bottom: 4rem;
`;
export const Sandboxes = styled.div`
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-column-gap: 2rem;
/* accomodate for the margin of the sandboxes */
margin: 0 -0.5rem;
@media screen and (max-width: 1100px) {
grid-template-columns: repeat(2, 1fr);
}
@media screen and (max-width: 700px) {
grid-template-columns: 1fr;
}
`;
export const ShowMore = styled.button`
transition: 0.3s ease all;
width: 100%;
background-color: rgba(255, 255, 255, 0.1);
border-radius: 4px;
margin-bottom: 1rem;
font-size: 1.5rem;
color: ${props => props.theme.new.title};
border: 0;
outline: 0;
display: flex;
align-items: center;
justify-content: center;
padding: 1.5rem 0;
cursor: pointer;
${props =>
props.disable
? css`
cursor: auto;
background-color: rgba(0, 0, 0, 0.1);
`
: css`
&:hover {
background-color: rgba(255, 255, 255, 0.15);
}
`};
`;
export const Navigation = styled.div`
position: relative;
margin: 0 auto;
margin-top: 30px;
display: flex;
position: relative;
list-style: none;
align-items: center;
justify-content: center;
`;
const ArrowStyles = css`
transition: 0.3s ease color;
font-size: 3em;
height: 40px;
color: rgba(255, 255, 255, 0.8);
cursor: pointer;
position: absolute;
&:hover {
color: ${props => props.theme.homepage.white};
}
`;
export const StyledRightArrow = styled(RightArrow)`
${ArrowStyles};
right: -40px;
${props =>
props.disable &&
css`
opacity: 0.5;
pointer-events: none;
cursor: auto;
`};
`;
export const StyledLeftArrow = styled(LeftArrow)`
${ArrowStyles};
left: -40px;
${props =>
props.disable &&
css`
opacity: 0.5;
pointer-events: none;
cursor: auto;
`};
`;
export const PickedQuestion = styled(Link)`
transition: 0.3s ease color;
color: ${props => props.theme.new.description};
text-decoration: none;
&:hover {
color: ${props => props.theme.new.title};
}
`;