diff --git a/components/Footer.tsx b/components/Footer.tsx deleted file mode 100644 index 7321a86..0000000 --- a/components/Footer.tsx +++ /dev/null @@ -1,10 +0,0 @@ -import config from '#config'; - -export default function Footer() { - const year = new Date().getFullYear(); - const {site: {startYear: year0 = year, author} = {}} = config; - - return ; -} diff --git a/components/MDXRoot.tsx b/components/MDXRoot.tsx index a131ffc..84bb003 100644 --- a/components/MDXRoot.tsx +++ b/components/MDXRoot.tsx @@ -1,38 +1,4 @@ -import Head from 'next/head'; -import type {AppProps} from 'next/app'; -import Nav from './Nav'; -import Footer from './Footer'; -import MetaInfo from './MetaInfo'; -import type {HeadingInfo} from '@sup39/rehype-mdx-export-headings'; +import MDXPageFactory from '@sup39/mdx-page'; +import config from '#config'; -export type MDXProps = { - children: JSX.Element - router: AppProps['router'], - meta: Partial<{ - title: string - description: string - h1: string - [key: string]: any - }> - headings: HeadingInfo[] -}; - -export default function MDXRoot({children, router: {pathname}, meta={}, headings}: MDXProps) { - const {title, description} = meta; - const h1 = meta.h1 ?? title; - return <> - - {title} - {description && } - -