-
Notifications
You must be signed in to change notification settings - Fork 171
/
winter.js
118 lines (116 loc) · 2.92 KB
/
winter.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
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
import CardModel from './card-model'
import { Box, Card, Flex, Grid, Heading, Text } from 'theme-ui'
import Buttons from './button'
import Icon from '@hackclub/icons'
import Dot from '../../dot'
/** @jsxImportSource theme-ui */
function BreakdownBox({
subtitle,
icon,
text,
description,
delay,
href,
color,
bg
}) {
return (
<Card
sx={{
color: 'white',
background: 'rgba(54,98,166,0.4)',
height: '100%',
cursor: `${href ? 'pointer' : 'default'}`,
display: 'flex',
flexDirection: 'column',
zIndex: 2,
p: [2, 3, '24px']
// justifyContent: 'flex-end'
}}
>
<Flex sx={{ alignItems: 'center', gap: '10px' }}>
<Icon glyph={icon} size={32} color={'white'} />
<Heading
sx={{
fontSize: ['16px', '16px', '24px', '26px']
}}
as="h4"
>
{text}
</Heading>
</Flex>
<Text
as="p"
sx={{
fontSize: [1, '16px !important', '18px !important'],
lineHeight: 1.25,
display: ['none', 'none', 'block', 'block'],
mt: [1, 2, 2]
}}
>
{description}
</Text>
</Card>
)
}
export default function Winter() {
return (
<CardModel
color="white"
sx={{
backgroundSize: 'cover',
backgroundColor: '#3561A4'
}}
position={[null, 'bottom', 'bottom']}
image="/home/winter-bg.webp"
badge
>
<Text variant="title" as="h3" sx={{ fontSize: ['36px', 4, 5] }}>
Winter Hardware Wonderland
</Text>
<Text as="p" variant="subtitle" sx={{ maxWidth: '45ch' }}>
Get $250 to build your own electronics projects alongside hundreds of
other teenagers in the Hack Club community!
</Text>
<Box>
<Grid gap={[2, 2, 3]} columns={3} py={3}>
<BreakdownBox
icon="settings"
color="#5bc0de"
text="Free hardware"
description="We'll pay for up to $250 of your hardware to build your project."
delay="200"
/>
<BreakdownBox
icon="event-code"
color="#5bc0de"
text="Daily progress"
description={
<>
From <strong>Feb 14-23</strong>, work on your project, sharing
daily updates.
</>
}
delay="100"
/>
<BreakdownBox
icon="friend"
color="#5bc0de"
text="Friends"
description="Find support from our community of 20k+ teenagers in the Slack."
delay="300"
/>
</Grid>
<Buttons
id="13"
link="https://github.com/hackclub/winter"
icon="freeze"
primary="white"
sx={{ color: 'blue' }}
>
View The Projects
</Buttons>
</Box>
</CardModel>
)
}