/* eslint-disable react/jsx-props-no-spreading */ import React from 'react'; import { Layout, Menu, Grid } from 'antd'; const { Header, Content, Footer } = Layout; const { useBreakpoint } = Grid import { MenuOutlined } from '@ant-design/icons'; import { useIntl, FormattedMessage } from 'gatsby-plugin-intl'; import { OutboundLink } from "gatsby-plugin-google-gtag" import { useLocation } from '@reach/router'; import { Link } from 'gatsby' import './DefaultLayout.less' import { externalLinks, linkToService, socialLinks, socialAnchorArray } from '~/utils/misc/socials'; // brand assets import { ReactComponent as AvatarAndName } from '~/icons/FullLogo_DarkBackground.svg'; import { ReactComponent as Avatar } from '~/icons/Avatar_DarkBackground.svg'; const externalLinkProps = { target: "_blank", rel: "noopener noreferrer", className: "no-external-icon" } const DefaultLayout: React.FC<{}> = ({ children, ...props }) => { const intl = useIntl() const location = useLocation() const screens = useBreakpoint(); const menuItemProps: { style: { textAlign: CanvasTextAlign, padding: number } } = { style: { textAlign: 'center', padding: 0 } } return (
} className="max-content-width" >
{/* pushes the elements away on both sides */}
{String(process.env.ENABLE_NETWORK_PAGE) === 'true' ? ( ) : null} {String(process.env.ENABLE_EXPLORER_PAGE) === 'true' ? ( ) : null} {intl.formatMessage({ id: "nav.codeLink" })} {intl.formatMessage({ id: "nav.jobsLink" })} {screens.md === false ? ( {Object.entries(externalLinks).map(([url, Icon]) =>
)}
) : null}
{socialAnchorArray(intl)}
{children}
); }; export default DefaultLayout;