2021-12-13 17:12:51 -03:00
|
|
|
import { useData } from '../../hooks/useData'
|
2021-12-12 23:45:41 -03:00
|
|
|
import { Avatar } from '../Avatar'
|
|
|
|
|
import { Button } from '../Button'
|
|
|
|
|
import { SocialLinks } from '../SocialLinks'
|
|
|
|
|
import { Content, Description, Name, Wrapper } from './styles'
|
|
|
|
|
|
|
|
|
|
export const Home = () => {
|
|
|
|
|
const { data } = useData()
|
2021-12-18 00:50:54 -03:00
|
|
|
const { colors, buttonsSchema, font, name, description } = data.settings
|
2021-12-12 23:45:41 -03:00
|
|
|
|
|
|
|
|
return (
|
2021-12-18 00:50:54 -03:00
|
|
|
<Wrapper color={colors.texts} font={font}>
|
2021-12-12 23:45:41 -03:00
|
|
|
<Content>
|
|
|
|
|
<Avatar />
|
|
|
|
|
<Name>{name}</Name>
|
|
|
|
|
<SocialLinks />
|
|
|
|
|
<Description>{description}</Description>
|
2021-12-18 00:50:54 -03:00
|
|
|
{data.buttonLinks?.map((link, i) => (
|
2021-12-13 17:12:51 -03:00
|
|
|
<Button
|
2021-12-18 00:50:54 -03:00
|
|
|
as="a"
|
|
|
|
|
href={link.href}
|
|
|
|
|
rel="noopener noreferrer"
|
|
|
|
|
target="_blank"
|
|
|
|
|
// key={link.id}
|
|
|
|
|
key={i}
|
|
|
|
|
variant={buttonsSchema}
|
2021-12-13 17:12:51 -03:00
|
|
|
>
|
|
|
|
|
{link.label}
|
|
|
|
|
</Button>
|
|
|
|
|
))}
|
2021-12-12 23:45:41 -03:00
|
|
|
</Content>
|
|
|
|
|
</Wrapper>
|
|
|
|
|
)
|
|
|
|
|
}
|