diff --git a/apps/site/next.config.mjs b/apps/site/next.config.mjs index 221c619..0e02f99 100644 --- a/apps/site/next.config.mjs +++ b/apps/site/next.config.mjs @@ -1,8 +1,13 @@ import { createMDX } from 'fumadocs-mdx/next'; +import { fileURLToPath } from 'node:url'; +import path from 'node:path'; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); /** @type {import('next').NextConfig} */ const config = { reactStrictMode: true, + outputFileTracingRoot: path.resolve(__dirname, '../../'), }; const withMDX = createMDX(); diff --git a/apps/site/src/app/[lang]/(marketing)/community/page.tsx b/apps/site/src/app/[lang]/(marketing)/community/page.tsx deleted file mode 100644 index 3917465..0000000 --- a/apps/site/src/app/[lang]/(marketing)/community/page.tsx +++ /dev/null @@ -1,33 +0,0 @@ -import { siteConfig } from '@/lib/site.config'; -import { buttonVariants } from '@/components/ui/button-variants'; - -export default async function CommunityPage({ - params, -}: { - params: Promise<{ lang: string }>; -}) { - const { lang } = await params; - - return ( -
-

- {lang === 'zh' ? '社区' : 'Community'} -

-

- {lang === 'zh' - ? '加入社区,获取帮助和分享经验' - : 'Join the community, get help, and share your experience'} -

-
- - GitHub - -
-
- ); -} diff --git a/apps/site/src/app/[lang]/(marketing)/download/page.tsx b/apps/site/src/app/[lang]/(marketing)/download/page.tsx deleted file mode 100644 index 269cae2..0000000 --- a/apps/site/src/app/[lang]/(marketing)/download/page.tsx +++ /dev/null @@ -1,31 +0,0 @@ -import { siteConfig } from '@/lib/site.config'; -import { buttonVariants } from '@/components/ui/button-variants'; - -export default async function DownloadPage({ - params, -}: { - params: Promise<{ lang: string }>; -}) { - const { lang } = await params; - - return ( -
-

- {lang === 'zh' ? '下载 CodePilot' : 'Download CodePilot'} -

-

- {lang === 'zh' - ? '从 GitHub Releases 下载最新版本' - : 'Download the latest version from GitHub Releases'} -

- - {lang === 'zh' ? '前往 GitHub Releases' : 'Go to GitHub Releases'} - -
- ); -} diff --git a/apps/site/src/app/[lang]/layout.tsx b/apps/site/src/app/[lang]/layout.tsx index ae4a308..534a823 100644 --- a/apps/site/src/app/[lang]/layout.tsx +++ b/apps/site/src/app/[lang]/layout.tsx @@ -1,13 +1,7 @@ import { RootProvider } from 'fumadocs-ui/provider/next'; -import { Inter } from 'next/font/google'; import type { ReactNode } from 'react'; import { i18n } from '@/lib/i18n'; - -const inter = Inter({ - subsets: ['latin'], - variable: '--font-inter', - display: 'swap', -}); +import { inter, geist } from '@/lib/fonts'; export default async function LangLayout({ params, @@ -19,7 +13,7 @@ export default async function LangLayout({ const { lang } = await params; return ( - +