From e3fb407710dbec60d4eefdd51ac7992fe5e384f1 Mon Sep 17 00:00:00 2001 From: "E. Almqvist" Date: Sun, 3 Jul 2022 02:56:58 +0200 Subject: [PATCH] Fixed all build errors --- components/activelink.tsx | 5 +++-- components/footer.tsx | 14 ++++++++------ components/header.tsx | 10 ++++++---- components/layout.tsx | 4 +++- components/nav.tsx | 12 +++++++----- pages/_app.tsx | 2 +- pages/index.tsx | 6 +++--- 7 files changed, 31 insertions(+), 22 deletions(-) diff --git a/components/activelink.tsx b/components/activelink.tsx index 30aa57a..e678488 100644 --- a/components/activelink.tsx +++ b/components/activelink.tsx @@ -3,7 +3,6 @@ import { ReactNode } from "react" import Link from "next/link" import styled, {css} from "styled-components" - const ALink = styled.a<{active?: boolean}>` border-bottom: 1px solid transparent; ${({active}) => active && css` @@ -12,7 +11,7 @@ const ALink = styled.a<{active?: boolean}>` `} ` -export default ({children, href}: {children: ReactNode, href: string}) => { +const ActiveLink = ({children, href}: {children: ReactNode, href: string}) => { const router = useRouter() return ( @@ -20,3 +19,5 @@ export default ({children, href}: {children: ReactNode, href: string}) => { ) } + +export default ActiveLink diff --git a/components/footer.tsx b/components/footer.tsx index 0a45911..e09cd0e 100644 --- a/components/footer.tsx +++ b/components/footer.tsx @@ -1,7 +1,7 @@ import styled from 'styled-components' import Link from "next/link" -const Footer = styled.footer` +const FooterCont = styled.footer` display: flex; align-items: center; justify-content: center; @@ -24,11 +24,11 @@ const Spacer = styled.div` flex: 1; ` -export default () => { +const Footer = () => { return ( <> -
+

Copyright © {new Date().getFullYear()} Elias Almqvist

  • {""}
  • @@ -36,10 +36,12 @@ export default () => {

    Source Code

    -
  • GitHub
  • -
  • WychGit
  • +
  • GitHub
  • +
  • WychGit
  • -
    + ) } + +export default Footer diff --git a/components/header.tsx b/components/header.tsx index 5dc92c5..4317d96 100644 --- a/components/header.tsx +++ b/components/header.tsx @@ -2,7 +2,7 @@ import styled from 'styled-components' import Nav from './nav' import Link from "next/link" -const Header = styled.header` +const HeaderCont = styled.header` display: flex; align-items: center; border-bottom: var(--border-size) var(--border-type) var(--border-color); @@ -23,11 +23,13 @@ const Header = styled.header` } ` -export default () => { +const Header = () => { return ( -
    +

    wych.dev

    + ) } + +export default Header diff --git a/components/layout.tsx b/components/layout.tsx index 446a2f3..ebf75fd 100644 --- a/components/layout.tsx +++ b/components/layout.tsx @@ -2,10 +2,12 @@ import Header from './header' import Footer from './footer' import {ReactNode} from 'react' -export default ({children}: {children: ReactNode}) => { +const Layout = ({children}: {children: ReactNode}) => { return <>
    {children}