diff --git a/src/components/Header.astro b/src/components/Header.astro deleted file mode 100644 index fe2906c..0000000 --- a/src/components/Header.astro +++ /dev/null @@ -1,85 +0,0 @@ ---- -import { SITE_TITLE } from '../consts'; -import HeaderLink from './HeaderLink.astro'; ---- - -
- -
- diff --git a/src/components/HeaderLink.astro b/src/components/HeaderLink.astro deleted file mode 100644 index 41da846..0000000 --- a/src/components/HeaderLink.astro +++ /dev/null @@ -1,24 +0,0 @@ ---- -import type { HTMLAttributes } from 'astro/types'; - -type Props = HTMLAttributes<'a'>; - -const { href, class: className, ...props } = Astro.props; -const pathname = Astro.url.pathname.replace(import.meta.env.BASE_URL, ''); -const subpath = pathname.match(/[^\/]+/g); -const isActive = href === pathname || href === '/' + (subpath?.[0] || ''); ---- - - - - -