import React from 'react'; import { Link } from 'gatsby'; import { css } from '@emotion/core'; import { Box, Flex } from '@rebass/emotion'; import Color from 'color'; import { URLService } from 'lib'; import { ColourOptions } from 'types/theme'; import { FluidContainer } from 'utils/styles/mixins'; import { HeaderProps } from '../header.types'; import BasketIcon from '../compnents/basket-icon'; import * as Styles from './header-top.styles'; import { colors } from 'utils/theme'; interface HeaderTopProps extends HeaderProps { toggleBasket: () => void; themeConfig: { [key: string]: ColourOptions; }; } const HeaderTop = React.forwardRef(({ themeConfig, logo, navigation, backButtonUrl, backButtonCopy, toggleBasket, children, totalItems, fontFamily }: HeaderTopProps, ref): JSX.Element => ( <>
    { navigation.map(item => { const slug = !item.page ? '/shop' : item.page.fields.slug; return (
  • {item.title}
  • ); }) }
{ backButtonUrl && {backButtonCopy} } )); HeaderTop.defaultProps = { backButtonCopy: 'Go Back' }; export default HeaderTop;