|
1 | 1 | import React, { FC } from 'react'; |
2 | | -import { FixedContainer, Nav, NavContainer, Brand, NavList, NavItem } from './styles'; |
3 | | -import { useTranslation } from 'react-i18next'; |
| 2 | +import { FixedContainer, Nav } from './styles'; |
4 | 3 | import useScroll from 'hooks/useScroll'; |
5 | | -import { Link, NavLink } from 'react-router-dom'; |
6 | | -import { Routes } from 'routes/Routes'; |
7 | | -import Button from 'components/Button'; |
8 | | -import Sparkles from 'components/Sparkles'; |
9 | | -import NanBrand from 'components/NanBrand'; |
| 4 | +import Desktop from './Desktop'; |
| 5 | +import Mobile from './Mobile'; |
| 6 | +import { links } from './domain/links'; |
10 | 7 |
|
11 | 8 | const Header: FC = () => { |
12 | | - const { t } = useTranslation(['config', 'translations']); |
13 | 9 | const isFixed = useScroll(50); |
14 | 10 |
|
15 | 11 | return ( |
16 | 12 | <FixedContainer> |
17 | 13 | <Nav condensed={isFixed}> |
18 | | - <NavContainer> |
19 | | - <Link to={Routes.ROOT}> |
20 | | - <Brand> |
21 | | - <NanBrand /> |
22 | | - </Brand> |
23 | | - </Link> |
24 | | - |
25 | | - <NavList> |
26 | | - <NavItem> |
27 | | - <NavLink to={Routes.LINKS_EXAMPLES}>{t('header.routerLinkExample', { ns: 'translations' })}</NavLink> |
28 | | - </NavItem> |
29 | | - <NavItem> |
30 | | - <NavLink to={Routes.API_EXAMPLES}>{t('header.integrations', { ns: 'translations' })}</NavLink> |
31 | | - </NavItem> |
32 | | - </NavList> |
33 | | - |
34 | | - <Sparkles colors={['#FFC700', '#22d0b6', '#22d0b6', '#80a6e9', '#f280b9', '#e35da0', '#0cea86']}> |
35 | | - <NavLink to={Routes.POWERED}> |
36 | | - <Button>Powered</Button> |
37 | | - </NavLink> |
38 | | - </Sparkles> |
39 | | - </NavContainer> |
| 14 | + <Desktop links={links} /> |
| 15 | + <Mobile links={links} /> |
40 | 16 | </Nav> |
41 | 17 | </FixedContainer> |
42 | 18 | ); |
|
0 commit comments