|
1 | 1 | import React from 'react';
|
2 | 2 |
|
3 |
| -import { Flex } from '@coderscamp/ui/components/Flex'; |
4 |
| -import { IconButton } from '@coderscamp/ui/components/IconButton'; |
5 |
| -import { HStack, Stack, VStack } from '@coderscamp/ui/components/Stack'; |
6 |
| -import { Typography } from '@coderscamp/ui/components/Typography'; |
7 |
| -import { useBreakpointValue } from '@coderscamp/ui/hooks/useBreakpointValue'; |
8 |
| -import { CodersCrewLogo } from '@coderscamp/ui/svg/logos/CodersCrewLogo'; |
9 |
| -import { VercelLogo } from '@coderscamp/ui/svg/logos/VercelLogo'; |
10 |
| - |
11 |
| -import { ExternalLink } from '../ExternalLink'; |
12 |
| -import { InternalLink } from '../InternalLink'; |
13 | 3 | import { Section } from '../Section';
|
14 |
| -import { footerNav, socialMediaIcons } from './Footer.data'; |
15 |
| - |
16 |
| -const FooterNav = () => ( |
17 |
| - <Stack |
18 |
| - direction={{ base: 'column', sm: 'row' }} |
19 |
| - spacing={{ base: '40px', md: '80px', lg: '40px', xl: '80px' }} |
20 |
| - align={{ base: 'center', sm: 'flex-start' }} |
21 |
| - > |
22 |
| - {footerNav.map(({ title, items }) => ( |
23 |
| - <VStack |
24 |
| - align={{ base: 'center', sm: 'flex-start' }} |
25 |
| - key={title} |
26 |
| - spacing="16px" |
27 |
| - textAlign={{ base: 'center', sm: 'left' }} |
28 |
| - > |
29 |
| - <Typography size="sm" color="gray.400" weight="bold" textTransform="uppercase"> |
30 |
| - {title} |
31 |
| - </Typography> |
32 |
| - {items.map(({ isExternal, ...linkProps }) => { |
33 |
| - const LinkComponent = isExternal ? ExternalLink : InternalLink; |
34 |
| - |
35 |
| - return ( |
36 |
| - <Typography size="md" color="gray.500" key={linkProps.href}> |
37 |
| - <LinkComponent withUnderline={false} {...linkProps} /> |
38 |
| - </Typography> |
39 |
| - ); |
40 |
| - })} |
41 |
| - </VStack> |
42 |
| - ))} |
43 |
| - </Stack> |
44 |
| -); |
45 |
| - |
46 |
| -const TopFooter = () => { |
47 |
| - return ( |
48 |
| - <Flex |
49 |
| - w="100%" |
50 |
| - direction={{ base: 'column', lg: 'row' }} |
51 |
| - align={{ base: 'center', lg: 'flex-start' }} |
52 |
| - justify="space-between" |
53 |
| - > |
54 |
| - <Flex maxW="384px" direction="column" align={{ base: 'center', lg: 'flex-start' }} mb={{ base: '64px', lg: 0 }}> |
55 |
| - <ExternalLink href="https://coderscrew.pl"> |
56 |
| - <CodersCrewLogo h="32px" /> |
57 |
| - </ExternalLink> |
58 |
| - <Typography pt="20px" size="md" textAlign={{ base: 'center', lg: 'left' }}> |
59 |
| - Organizatorem CodersCamp jest Stowarzyszenie CodersCrew - organizacja non-profit zrzeszająca pasjonatów |
60 |
| - dziedzin związanych z IT. |
61 |
| - </Typography> |
62 |
| - <HStack pt="24px" spacing="16px"> |
63 |
| - {socialMediaIcons.map(({ label, icon, href }) => ( |
64 |
| - <IconButton icon={icon} size="md" variant="ghost" aria-label={label} href={href} as="a" key={label} /> |
65 |
| - ))} |
66 |
| - </HStack> |
67 |
| - </Flex> |
68 |
| - <FooterNav /> |
69 |
| - </Flex> |
70 |
| - ); |
71 |
| -}; |
72 |
| - |
73 |
| -const BottomFooter = () => { |
74 |
| - const direction = useBreakpointValue({ base: 'column-reverse', md: 'row' } as const); |
75 |
| - |
76 |
| - return ( |
77 |
| - <Flex borderTop="1px" borderColor="gray.200" minH="70px" align="flex-end" width="100%"> |
78 |
| - <Stack |
79 |
| - justify="space-between" |
80 |
| - align="center" |
81 |
| - direction={direction} |
82 |
| - width="100%" |
83 |
| - mt={{ base: '32px', md: '24px' }} |
84 |
| - spacing={{ base: '16px', md: '24px' }} |
85 |
| - > |
86 |
| - <Typography color="gray.400" textAlign={{ base: 'center', md: 'left' }}> |
87 |
| - © CodersCamp 2021, wszelkie prawa zastrzeżone. |
88 |
| - </Typography> |
89 |
| - <ExternalLink href="https://vercel.com/?utm_source=coderscamp&utm_campaign=oss"> |
90 |
| - <VercelLogo w="212px" h="44px" /> |
91 |
| - </ExternalLink> |
92 |
| - </Stack> |
93 |
| - </Flex> |
94 |
| - ); |
95 |
| -}; |
| 4 | +import { BottomFooter } from './BottomFooter'; |
| 5 | +import { TopFooter } from './TopFooter'; |
96 | 6 |
|
97 | 7 | export const Footer = () => {
|
98 | 8 | return (
|
|
0 commit comments