mirror of
https://github.com/labring/FastGPT.git
synced 2026-05-03 01:02:15 +08:00
docs: switch to docs layout and apply black theme (#6533)
* feat: add Gemini 3.1 models - Add gemini-3.1-pro-preview (released February 19, 2026) - Add gemini-3.1-flash-lite-preview (released March 3, 2026) Both models support: - 1M context window - 64k max response - Vision - Tool choice * docs: switch to docs layout and apply black theme - Change layout from notebook to docs - Update logo to icon + text format - Apply fumadocs black theme - Simplify global.css (keep only navbar and TOC styles) - Fix icon components to properly accept className props - Add mobile text overflow handling - Update Node engine requirement to >=20.x * doc * doc * lock * fix: ts * doc * doc --------- Co-authored-by: archer <archer@archerdeMac-mini.local> Co-authored-by: archer <545436317@qq.com>
This commit is contained in:
@@ -1,18 +1,17 @@
|
||||
import { type ReactNode } from 'react';
|
||||
import { source } from '@/lib/source';
|
||||
import { DocsLayout } from 'fumadocs-ui/layouts/notebook';
|
||||
import { DocsLayout } from 'fumadocs-ui/layouts/docs';
|
||||
import { baseOptions } from '@/app/layout.config';
|
||||
import { t, getLocalizedPath, i18n } from '@/lib/i18n';
|
||||
import LogoLight from '@/components/docs/logo';
|
||||
import LogoDark from '@/components/docs/logoDark';
|
||||
import '@/app/global.css';
|
||||
import { CustomSidebarComponents } from '@/components/sideBar';
|
||||
import { SidebarKeepOpen } from '@/components/sidebarKeepOpen';
|
||||
import { SidebarScrollFix } from '@/components/sidebarScrollFix';
|
||||
import FeishuLogoLight from '@/components/docs/feishuLogoLIght';
|
||||
import FeishuLogoDark from '@/components/docs/feishuLogoDark';
|
||||
import GithubLogoLight from '@/components/docs/githubLogoLight';
|
||||
import GithubLogoDark from '@/components/docs/githubLogoDark';
|
||||
import { BookOpen, Code, Lightbulb, CircleHelp, Scale, History, Server } from 'lucide-react';
|
||||
import { BookOpen, Code, Lightbulb, CircleHelp, Server } from 'lucide-react';
|
||||
|
||||
export default async function Layout({
|
||||
params,
|
||||
@@ -57,51 +56,6 @@ export default async function Layout({
|
||||
return (
|
||||
<DocsLayout
|
||||
{...baseOptions(lang)}
|
||||
nav={{
|
||||
title: (
|
||||
<div className="flex flex-row items-center gap-2 h-14 ml-1">
|
||||
<div className="block dark:hidden">
|
||||
<LogoLight className="w-48 h-auto" />
|
||||
</div>
|
||||
<div className="hidden dark:block">
|
||||
<LogoDark className="w-48 h-auto" />
|
||||
</div>
|
||||
</div>
|
||||
),
|
||||
mode: 'top'
|
||||
}}
|
||||
links={[
|
||||
{
|
||||
type: 'icon',
|
||||
icon: (
|
||||
<div className="flex flex-row items-center gap-2">
|
||||
<div className="block dark:hidden">
|
||||
<FeishuLogoLight />
|
||||
</div>
|
||||
<div className="hidden dark:block">
|
||||
<FeishuLogoDark />
|
||||
</div>
|
||||
</div>
|
||||
),
|
||||
url: 'https://oss.laf.run/otnvvf-imgs/fastgpt-feishu1.png',
|
||||
text: '飞书群'
|
||||
},
|
||||
{
|
||||
type: 'icon',
|
||||
icon: (
|
||||
<div className="flex flex-row items-center gap-2">
|
||||
<div className="block dark:hidden">
|
||||
<GithubLogoLight />
|
||||
</div>
|
||||
<div className="hidden dark:block">
|
||||
<GithubLogoDark />
|
||||
</div>
|
||||
</div>
|
||||
),
|
||||
url: 'https://github.com/labring/FastGPT',
|
||||
text: 'github'
|
||||
}
|
||||
]}
|
||||
tree={source.pageTree[lang] || source.pageTree[i18n.defaultLanguage]}
|
||||
searchToggle={{
|
||||
enabled: true
|
||||
@@ -111,9 +65,23 @@ export default async function Layout({
|
||||
collapsible: false,
|
||||
components: CustomSidebarComponents
|
||||
}}
|
||||
tabMode="sidebar"
|
||||
links={[
|
||||
{
|
||||
type: 'icon',
|
||||
icon: <FeishuLogoLight className="block dark:hidden size-5" />,
|
||||
url: 'https://oss.laf.run/otnvvf-imgs/fastgpt-feishu1.png',
|
||||
text: '飞书群'
|
||||
},
|
||||
{
|
||||
type: 'icon',
|
||||
icon: <GithubLogoLight className="block dark:hidden size-5" />,
|
||||
url: 'https://github.com/labring/FastGPT',
|
||||
text: 'github'
|
||||
}
|
||||
]}
|
||||
>
|
||||
<SidebarKeepOpen tabUrls={tabUrls} />
|
||||
<SidebarScrollFix />
|
||||
{children}
|
||||
</DocsLayout>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user