/
home_screen.tsx
73 lines (70 loc) · 1.73 KB
/
home_screen.tsx
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
import React from 'react';
import { Box, Text, useTheme } from '@skynexui/components';
// TODO: Create a `Scaffold` component that handles these styles
const GlobalStyle = () => {
return (
<style jsx global>{`
html {
height: 100%;
}
body {
min-height: 100%;
display: flex;
flex-direction: column;
}
#__next {
display: flex;
flex-direction: row;
}
`}</style>
);
}
export function HomeScreen() {
const theme = useTheme();
const colorsneutral = theme.colors.neutral;
const colorSelected = colorsneutral.x100;
const bg = colorSelected;
return (
<Box
styleSheet={{
width: { xs: '500px' },
flexDirection: 'row',
crossAxisAlignment: { xs: 'center' }, // alignItems
mainAxisAlignment: { xs: 'flex-start' }, // justifyContent
backgroundColor: {
xs: bg,
},
margin: { xs: 50 },
paddingVertical: { xs: 50 },
paddingHorizontal: { xs: 50 },
// TODO: Fix padding bottom implementation to match Flutter
paddingBottom: { xs: 100 },
}}
>
<Text styleSheet={{
// width: {xs: 50},
height: {xs: 50},
backgroundColor: {xs: theme.colors.primary.x400 },
}}>
Box 01
</Text>
<Text styleSheet={{
// width: {xs: 50},
flex: {xs: 2},
height: {xs: 50},
backgroundColor: {xs: theme.colors.accent.x400 },
}}>
Box 02
</Text>
<Text styleSheet={{
// width: {xs: 50},
flex: {xs: 3},
height: {xs: 50},
backgroundColor: {xs: theme.colors.positive.x400 },
}}>
Box 03
</Text>
<GlobalStyle />
</Box >
);
}