Skip to content
Snippets Groups Projects
Commit d2b581b0 authored by Tarje.Lavik's avatar Tarje.Lavik
Browse files

Style links

parent 2c4a9a62
No related branches found
No related tags found
No related merge requests found
......@@ -7,8 +7,8 @@ export default function Link({ href, children }) {
}
return (
<ChakraLink as={NextLink} href={href}>
{children}
</ChakraLink>
<NextLink href={href} passHref>
<ChakraLink color="teal.600">{children}</ChakraLink>
</NextLink>
)
}
import React from 'react'
import NextLink from 'next/link'
import { kebabCase } from 'lodash'
import { Heading, Link, Text } from '@chakra-ui/react'
import Link from '../Link'
import { Heading, Text } from '@chakra-ui/react'
import {
BigText,
Hero,
......@@ -103,11 +103,7 @@ export default function PortableTextBlock(props) {
const { reference } = mark
const href = `/id/${reference._ref}`
const text = children.length ? children[0] : children
return (
<Link as={NextLink} href={href}>
{text}
</Link>
)
return <Link href={href}>{text}</Link>
},
link: ({ mark, children }) => {
// console.log(children)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment