File size: 1,610 Bytes
6111b2b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
import { RootProvider } from "fumadocs-ui/provider/next";
import { DocsLayout } from "fumadocs-ui/layouts/docs";
import { source } from "@/lib/source";
import type { ReactNode } from "react";
import type { BaseLayoutProps } from "fumadocs-ui/layouts/shared";
import { Suspense } from "react";
import LanguageSelector from "@/shared/components/LanguageSelector";

export const metadata = {
  title: {
    template: "%s — OmniRoute Docs",
    default: "OmniRoute Documentation",
  },
  description:
    "Comprehensive documentation for OmniRoute AI gateway — setup, API, compression, deployment, and more.",
  robots: {
    index: true,
    follow: true,
  },
};

const docsLayoutOptions: BaseLayoutProps = {
  nav: {
    title: "OmniRoute Docs",
    url: "/docs",
    children: (
      <Suspense fallback={<div className="w-24 h-8" />}>

        <LanguageSelector />

      </Suspense>
    ),
  },
  links: [
    {
      text: "Docs Home",
      url: "/docs",
    },
    {
      text: "\u2190 Back to Dashboard",
      url: "/dashboard",
      secondary: true,
    },
  ],
  githubUrl: "https://github.com/diegosouzapw/OmniRoute",
};

export default function Layout({ children }: { children: ReactNode }) {
  return (
    <RootProvider

      theme={{

        defaultTheme: "dark",

        attribute: "class",

      }}

      search={{

        options: {

          api: "/docs/api/search",

        },

      }}

    >

      <DocsLayout tree={source.pageTree} {...docsLayoutOptions}>

        {children}

      </DocsLayout>

    </RootProvider>
  );
}