-
-
{props.children}
+
+
+
+
+
-
- {hasTableOfContents && !props.meta?.hide_table_of_contents && (
-
- )}
-
-
+ {hasTableOfContents && !props.meta?.hide_table_of_contents && (
+
+ )}
+
+
+
>
)
}
diff --git a/apps/docs/layouts/MainSkeleton.tsx b/apps/docs/layouts/MainSkeleton.tsx
new file mode 100644
index 00000000000..bf2b77aef4d
--- /dev/null
+++ b/apps/docs/layouts/MainSkeleton.tsx
@@ -0,0 +1,376 @@
+import { useTheme } from 'next-themes'
+import Image from 'next/legacy/image'
+import Link from 'next/link'
+import NavigationMenu, { type MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
+import TopNavBar from '~/components/Navigation/NavigationMenu/TopNavBar'
+
+import { PropsWithChildren, memo, useEffect } from 'react'
+import Footer from '~/components/Navigation/Footer'
+import { menuState, useMenuMobileOpen } from '~/hooks/useMenuState'
+
+const levelsData = {
+ home: {
+ icon: '/docs/img/icons/menu/home',
+ name: 'Home',
+ },
+ gettingstarted: {
+ icon: '/docs/img/icons/menu/getting-started',
+ name: 'Getting Started',
+ },
+ database: {
+ icon: '/docs/img/icons/menu/database',
+ name: 'Database',
+ },
+ api: {
+ icon: '/docs/img/icons/menu/rest',
+ name: 'REST API',
+ },
+ graphql: {
+ icon: '/docs/img/icons/menu/graphql',
+ name: 'GraphQL',
+ },
+ auth: {
+ icon: '/docs/img/icons/menu/auth',
+ name: 'Auth',
+ },
+ functions: {
+ icon: '/docs/img/icons/menu/functions',
+ name: 'Edge Functions',
+ },
+ realtime: {
+ icon: '/docs/img/icons/menu/realtime',
+ name: 'Realtime',
+ },
+ analytics: {
+ icon: '/docs/img/icons/menu/analytics',
+ name: 'Analytics',
+ },
+ storage: {
+ icon: '/docs/img/icons/menu/storage',
+ name: 'Storage',
+ },
+ ai: {
+ icon: '/docs/img/icons/menu/ai',
+ name: 'AI & Vectors',
+ },
+ supabase_cli: {
+ icon: '/docs/img/icons/menu/reference-cli',
+ name: 'Supabase CLI',
+ },
+ platform: {
+ icon: '/docs/img/icons/menu/platform',
+ name: 'Platform',
+ },
+ resources: {
+ icon: '/docs/img/icons/menu/resources',
+ name: 'Resources',
+ },
+ self_hosting: {
+ icon: '/docs/img/icons/menu/self-hosting',
+ name: 'Self-Hosting',
+ },
+ integrations: {
+ icon: '/docs/img/icons/menu/integrations',
+ name: 'Integrations',
+ },
+ reference_javascript_v1: {
+ icon: '/docs/img/icons/menu/reference-javascript',
+ name: 'Javascript Reference v1.0',
+ },
+ reference_javascript_v2: {
+ icon: '/docs/img/icons/menu/reference-javascript',
+ name: 'Javascript Reference v2.0',
+ },
+ reference_dart_v1: {
+ icon: '/docs/img/icons/menu/reference-dart',
+ name: 'Dart Reference v1.0',
+ },
+ reference_dart_v2: {
+ icon: '/docs/img/icons/menu/reference-dart',
+ name: 'Dart Reference v2.0',
+ },
+ reference_csharp_v0: {
+ icon: '/docs/img/icons/menu/reference-csharp',
+ name: 'C# Reference v0.0',
+ },
+ reference_python_v2: {
+ icon: '/docs/img/icons/menu/reference-python',
+ name: 'Python Reference v2.0',
+ },
+ reference_swift_v1: {
+ icon: '/docs/img/icons/menu/reference-swift',
+ name: 'Swift Reference v1.0',
+ },
+ reference_swift_v2: {
+ icon: '/docs/img/icons/menu/reference-swift',
+ name: 'Swift Reference v2.0',
+ },
+ reference_kotlin_v1: {
+ icon: '/docs/img/icons/menu/reference-kotlin',
+ name: 'Kotlin Reference v1.0',
+ },
+ reference_kotlin_v2: {
+ icon: '/docs/img/icons/menu/reference-kotlin',
+ name: 'Kotlin Reference v2.0',
+ },
+ reference_cli: {
+ icon: '/docs/img/icons/menu/reference-cli',
+ name: 'CLI Reference',
+ },
+ reference_api: {
+ icon: '/docs/img/icons/menu/reference-api',
+ name: 'Management API Reference',
+ },
+ reference_self_hosting_auth: {
+ icon: '/docs/img/icons/menu/reference-auth',
+ name: 'Auth Server Reference',
+ },
+ reference_self_hosting_storage: {
+ icon: '/docs/img/icons/menu/reference-storage',
+ name: 'Storage Server Reference',
+ },
+ reference_self_hosting_realtime: {
+ icon: '/docs/img/icons/menu/reference-realtime',
+ name: 'Realtime Server Reference',
+ },
+ reference_self_hosting_analytics: {
+ icon: '/docs/img/icons/menu/reference-analytics',
+ name: 'Analytics Server Reference',
+ },
+ reference_self_hosting_functions: {
+ icon: '/docs/img/icons/menu/reference-functions',
+ name: 'Functions Server Reference',
+ },
+}
+
+const MobileHeader = memo(function MobileHeader({ menuId }: { menuId: MenuId }) {
+ const mobileMenuOpen = useMenuMobileOpen()
+ const menuLevel = menuId
+
+ return (
+
+
+
+

+
+
+ {mobileMenuOpen
+ ? 'Close'
+ : menuLevel
+ ? levelsData[menuLevel].name
+ : levelsData['home'].name}
+
+
+ )
+})
+
+const MobileMenuBackdrop = memo(function MobileMenuBackdrop() {
+ const mobileMenuOpen = useMenuMobileOpen()
+
+ useEffect(() => {
+ window.addEventListener('resize', (e: UIEvent) => {
+ const w = e.target as Window
+ if (mobileMenuOpen && w.innerWidth >= 1024) {
+ menuState.setMenuMobileOpen(!mobileMenuOpen)
+ }
+ })
+ return () => {
+ window.removeEventListener('resize', () => {})
+ }
+ }, [mobileMenuOpen])
+
+ return (
+
menuState.setMenuMobileOpen(!mobileMenuOpen)}
+ >
+ )
+})
+
+const HeaderLogo = memo(function HeaderLogo() {
+ const { resolvedTheme } = useTheme()
+ return (
+
+
+
DOCS
+
+ )
+})
+
+const Container = memo(function Container(props: PropsWithChildren) {
+ const mobileMenuOpen = useMenuMobileOpen()
+
+ return (
+
+ )
+})
+
+const NavContainer = memo(function NavContainer({ menuId }: { menuId: MenuId }) {
+ const mobileMenuOpen = useMenuMobileOpen()
+
+ return (
+
+ )
+})
+
+function MainSkeleton({ children, menuId }: PropsWithChildren<{ menuId: MenuId }>) {
+ return (
+
+
+
+
+
+
+
+
+ {children}
+
+
+
+
+
+ )
+}
+
+export { MainSkeleton }
diff --git a/apps/docs/layouts/SiteLayout.tsx b/apps/docs/layouts/SiteLayout.tsx
index ed1447aa80c..5754ddff924 100644
--- a/apps/docs/layouts/SiteLayout.tsx
+++ b/apps/docs/layouts/SiteLayout.tsx
@@ -1,349 +1,5 @@
-import { useTheme } from 'next-themes'
-import Image from 'next/legacy/image'
-import Link from 'next/link'
-import NavigationMenu from '~/components/Navigation/NavigationMenu/NavigationMenu'
-import TopNavBar from '~/components/Navigation/NavigationMenu/TopNavBar'
-
import Head from 'next/head'
-import { PropsWithChildren, memo, useEffect } from 'react'
-import Footer from '~/components/Navigation/Footer'
-import { menuState, useMenuLevelId, useMenuMobileOpen } from '~/hooks/useMenuState'
-
-const levelsData = {
- home: {
- icon: '/docs/img/icons/menu/home',
- name: 'Home',
- },
- gettingstarted: {
- icon: '/docs/img/icons/menu/getting-started',
- name: 'Getting Started',
- },
- database: {
- icon: '/docs/img/icons/menu/database',
- name: 'Database',
- },
- api: {
- icon: '/docs/img/icons/menu/rest',
- name: 'REST API',
- },
- graphql: {
- icon: '/docs/img/icons/menu/graphql',
- name: 'GraphQL',
- },
- auth: {
- icon: '/docs/img/icons/menu/auth',
- name: 'Auth',
- },
- functions: {
- icon: '/docs/img/icons/menu/functions',
- name: 'Edge Functions',
- },
- realtime: {
- icon: '/docs/img/icons/menu/realtime',
- name: 'Realtime',
- },
- analytics: {
- icon: '/docs/img/icons/menu/analytics',
- name: 'Analytics',
- },
- storage: {
- icon: '/docs/img/icons/menu/storage',
- name: 'Storage',
- },
- ai: {
- icon: '/docs/img/icons/menu/ai',
- name: 'AI & Vectors',
- },
- supabase_cli: {
- icon: '/docs/img/icons/menu/reference-cli',
- name: 'Supabase CLI',
- },
- platform: {
- icon: '/docs/img/icons/menu/platform',
- name: 'Platform',
- },
- resources: {
- icon: '/docs/img/icons/menu/resources',
- name: 'Resources',
- },
- self_hosting: {
- icon: '/docs/img/icons/menu/self-hosting',
- name: 'Self-Hosting',
- },
- integrations: {
- icon: '/docs/img/icons/menu/integrations',
- name: 'Integrations',
- },
- reference_javascript_v1: {
- icon: '/docs/img/icons/menu/reference-javascript',
- name: 'Javascript Reference v1.0',
- },
- reference_javascript_v2: {
- icon: '/docs/img/icons/menu/reference-javascript',
- name: 'Javascript Reference v2.0',
- },
- reference_dart_v1: {
- icon: '/docs/img/icons/menu/reference-dart',
- name: 'Dart Reference v1.0',
- },
- reference_dart_v2: {
- icon: '/docs/img/icons/menu/reference-dart',
- name: 'Dart Reference v2.0',
- },
- reference_csharp_v0: {
- icon: '/docs/img/icons/menu/reference-csharp',
- name: 'C# Reference v0.0',
- },
- reference_python_v2: {
- icon: '/docs/img/icons/menu/reference-python',
- name: 'Python Reference v2.0',
- },
- reference_swift_v1: {
- icon: '/docs/img/icons/menu/reference-swift',
- name: 'Swift Reference v1.0',
- },
- reference_swift_v2: {
- icon: '/docs/img/icons/menu/reference-swift',
- name: 'Swift Reference v2.0',
- },
- reference_kotlin_v1: {
- icon: '/docs/img/icons/menu/reference-kotlin',
- name: 'Kotlin Reference v1.0',
- },
- reference_kotlin_v2: {
- icon: '/docs/img/icons/menu/reference-kotlin',
- name: 'Kotlin Reference v2.0',
- },
- reference_cli: {
- icon: '/docs/img/icons/menu/reference-cli',
- name: 'CLI Reference',
- },
- reference_api: {
- icon: '/docs/img/icons/menu/reference-api',
- name: 'Management API Reference',
- },
- reference_self_hosting_auth: {
- icon: '/docs/img/icons/menu/reference-auth',
- name: 'Auth Server Reference',
- },
- reference_self_hosting_storage: {
- icon: '/docs/img/icons/menu/reference-storage',
- name: 'Storage Server Reference',
- },
- reference_self_hosting_realtime: {
- icon: '/docs/img/icons/menu/reference-realtime',
- name: 'Realtime Server Reference',
- },
- reference_self_hosting_analytics: {
- icon: '/docs/img/icons/menu/reference-analytics',
- name: 'Analytics Server Reference',
- },
- reference_self_hosting_functions: {
- icon: '/docs/img/icons/menu/reference-functions',
- name: 'Functions Server Reference',
- },
-}
-
-const MobileHeader = memo(function MobileHeader() {
- const mobileMenuOpen = useMenuMobileOpen()
- const menuLevel = useMenuLevelId()
-
- return (
-
-
-
-

-
-
- {mobileMenuOpen
- ? 'Close'
- : menuLevel
- ? levelsData[menuLevel].name
- : levelsData['home'].name}
-
-
- )
-})
-
-const MobileMenuBackdrop = memo(function MobileMenuBackdrop() {
- const mobileMenuOpen = useMenuMobileOpen()
-
- useEffect(() => {
- window.addEventListener('resize', (e: UIEvent) => {
- const w = e.target as Window
- if (mobileMenuOpen && w.innerWidth >= 1024) {
- menuState.setMenuMobileOpen(!mobileMenuOpen)
- }
- })
- return () => {
- window.removeEventListener('resize', () => {})
- }
- }, [mobileMenuOpen])
-
- return (
-
menuState.setMenuMobileOpen(!mobileMenuOpen)}
- >
- )
-})
-
-const HeaderLogo = memo(function HeaderLogo() {
- const { resolvedTheme } = useTheme()
- return (
-
-
-
DOCS
-
- )
-})
-
-const Container = memo(function Container(props: PropsWithChildren) {
- const mobileMenuOpen = useMenuMobileOpen()
-
- return (
-
- )
-})
-
-const NavContainer = memo(function NavContainer() {
- const mobileMenuOpen = useMenuMobileOpen()
-
- return (
-
- )
-})
+import { PropsWithChildren } from 'react'
const SiteLayout = ({ children }: PropsWithChildren<{}>) => {
return (
@@ -351,32 +7,7 @@ const SiteLayout = ({ children }: PropsWithChildren<{}>) => {
Supabase Docs
-
-
-
-
-
-
-
-
-
- {children}
-
-
-
-
-
-
+
{children}
>
)
}
diff --git a/apps/docs/layouts/guides/index.tsx b/apps/docs/layouts/guides/index.tsx
index 105e250dd5b..34768852a2e 100644
--- a/apps/docs/layouts/guides/index.tsx
+++ b/apps/docs/layouts/guides/index.tsx
@@ -10,8 +10,10 @@ import components from '~/components'
import { highlightSelectedTocItem } from '~/components/CustomHTMLElements/CustomHTMLElements.utils'
import { FooterHelpCalloutType } from '~/components/FooterHelpCallout'
import GuidesTableOfContents from '~/components/GuidesTableOfContents'
+import { type MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import useHash from '~/hooks/useHash'
import { LayoutMainContent } from '../DefaultLayout'
+import { MainSkeleton } from '../MainSkeleton'
interface Props {
meta: {
@@ -30,6 +32,7 @@ interface Props {
toc?: any
currentPage?: string
hideToc?: boolean
+ menuId: MenuId
}
const Layout: FC
= (props) => {
@@ -42,6 +45,8 @@ const Layout: FC = (props) => {
const { asPath } = useRouter()
const router = useRouter()
+ const menuId = props.menuId
+
const EDIT_BUTTON_EXCLUDE_LIST = ['/404']
useEffect(() => {
@@ -108,77 +113,79 @@ const Layout: FC = (props) => {
},
}}
/>
-
-
-
- {props.meta?.breadcrumb && (
-
{props.meta.breadcrumb}
- )}
-
- {props.meta.title}
- {props.meta?.subtitle && (
- {props.meta.subtitle}
- )}
-
- {props.children}
-
- {EDIT_BUTTON_EXCLUDE_LIST.includes(router.route) ? (
- <>>
- ) : (
-
- )}
-
-
- {!props.hideToc && hasTableOfContents && !props.meta?.hide_table_of_contents && (
+
+
+
-
- {props.meta?.tocVideo && !!tocVideoPreview && (
-
-
+ {props.meta?.breadcrumb && (
+
{props.meta.breadcrumb}
+ )}
+
+ {props.meta.title}
+ {props.meta?.subtitle && (
+ {props.meta.subtitle}
+ )}
+
+ {props.children}
+
+ {EDIT_BUTTON_EXCLUDE_LIST.includes(router.route) ? (
+ <>>
+ ) : (
+
)}
-
- On this page
-
-
-
+
- )}
-
-
+ {!props.hideToc && hasTableOfContents && !props.meta?.hide_table_of_contents && (
+
+
+ {props.meta?.tocVideo && !!tocVideoPreview && (
+
+
+
+ )}
+
+ On this page
+
+
+
+
+ )}
+
+
+
>
)
}
diff --git a/apps/docs/pages/guides/ai/[[...slug]].tsx b/apps/docs/pages/guides/ai/[[...slug]].tsx
index af8cc713906..a19f8a02e54 100644
--- a/apps/docs/pages/guides/ai/[[...slug]].tsx
+++ b/apps/docs/pages/guides/ai/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function AiGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/ai/python/[slug].tsx b/apps/docs/pages/guides/ai/python/[slug].tsx
index fcbd53160c0..952e4bfa099 100644
--- a/apps/docs/pages/guides/ai/python/[slug].tsx
+++ b/apps/docs/pages/guides/ai/python/[slug].tsx
@@ -11,6 +11,7 @@ import Layout from '~/layouts/DefaultGuideLayout'
import { UrlTransformFunction, linkTransform } from '~/lib/mdx/plugins/rehypeLinkTransform'
import remarkMkDocsAdmonition from '~/lib/mdx/plugins/remarkAdmonition'
import { removeTitle } from '~/lib/mdx/plugins/remarkRemoveTitle'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
// We fetch these docs at build time from an external repo
const org = 'supabase'
@@ -61,7 +62,7 @@ interface PythonClientDocsProps {
export default function PythonClientDocs({ source, meta }: PythonClientDocsProps) {
return (
-
+
)
diff --git a/apps/docs/pages/guides/api/[[...slug]].tsx b/apps/docs/pages/guides/api/[[...slug]].tsx
index 94951837d6d..d46e03fd7cc 100644
--- a/apps/docs/pages/guides/api/[[...slug]].tsx
+++ b/apps/docs/pages/guides/api/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function ApiGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/auth/[[...slug]].tsx b/apps/docs/pages/guides/auth/[[...slug]].tsx
index 777f65e6ddd..9e645a917ea 100644
--- a/apps/docs/pages/guides/auth/[[...slug]].tsx
+++ b/apps/docs/pages/guides/auth/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function AuthGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/cli/[[...slug]].tsx b/apps/docs/pages/guides/cli/[[...slug]].tsx
index 3e690745906..2dd168f672d 100644
--- a/apps/docs/pages/guides/cli/[[...slug]].tsx
+++ b/apps/docs/pages/guides/cli/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function CliGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/cli/config.tsx b/apps/docs/pages/guides/cli/config.tsx
index 3830af444f1..193f25fca66 100644
--- a/apps/docs/pages/guides/cli/config.tsx
+++ b/apps/docs/pages/guides/cli/config.tsx
@@ -5,6 +5,8 @@ import GuidesTableOfContents from '~/components/GuidesTableOfContents'
import { Heading } from '~/components/CustomHTMLElements'
import Head from 'next/head'
import { CodeBlock } from 'ui'
+import { MainSkeleton } from '~/layouts/MainSkeleton'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
// Parameters are grouped on the page by tag
const tocList = []
@@ -29,24 +31,26 @@ export default function Config() {
Supabase CLI config
-
-
-
-
CLI configuration
-
-
{specFile.info.description}
-
{content}
+
+
+
+
+
CLI configuration
+
+
{specFile.info.description}
+
{content}
+
+
+
-
-
-
- On this page
-
-
-
-
-
+
>
)
}
diff --git a/apps/docs/pages/guides/cli/github-action/[slug].tsx b/apps/docs/pages/guides/cli/github-action/[slug].tsx
index 049e3f1072d..d06701295e5 100644
--- a/apps/docs/pages/guides/cli/github-action/[slug].tsx
+++ b/apps/docs/pages/guides/cli/github-action/[slug].tsx
@@ -12,6 +12,7 @@ import { UrlTransformFunction, linkTransform } from '~/lib/mdx/plugins/rehypeLin
import remarkMkDocsAdmonition from '~/lib/mdx/plugins/remarkAdmonition'
import { removeTitle } from '~/lib/mdx/plugins/remarkRemoveTitle'
import remarkPyMdownTabs from '~/lib/mdx/plugins/remarkTabs'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
// We fetch these docs at build time from an external repo
const org = 'supabase'
@@ -62,7 +63,7 @@ interface ActionDocsProps {
export default function ActionDocs({ source, meta }: ActionDocsProps) {
return (
-
+
)
diff --git a/apps/docs/pages/guides/database/[[...slug]].tsx b/apps/docs/pages/guides/database/[[...slug]].tsx
index fc7519ad2ba..0ee6416477b 100644
--- a/apps/docs/pages/guides/database/[[...slug]].tsx
+++ b/apps/docs/pages/guides/database/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -31,7 +32,7 @@ export default function DatabaseGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/database/extensions/wrappers/[[...slug]].tsx b/apps/docs/pages/guides/database/extensions/wrappers/[[...slug]].tsx
index 564d96d51d2..0d34ede0dcb 100644
--- a/apps/docs/pages/guides/database/extensions/wrappers/[[...slug]].tsx
+++ b/apps/docs/pages/guides/database/extensions/wrappers/[[...slug]].tsx
@@ -10,6 +10,7 @@ import remarkGfm from 'remark-gfm'
import codeHikeTheme from 'config/code-hike.theme.json' assert { type: 'json' }
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
import { UrlTransformFunction, linkTransform } from '~/lib/mdx/plugins/rehypeLinkTransform'
@@ -83,7 +84,7 @@ export default function WrappersDocs({
editLink,
}: InferGetStaticPropsType) {
return (
-
+
)
diff --git a/apps/docs/pages/guides/functions/[[...slug]].tsx b/apps/docs/pages/guides/functions/[[...slug]].tsx
index 8e41b131d3e..8a8ed0defd2 100644
--- a/apps/docs/pages/guides/functions/[[...slug]].tsx
+++ b/apps/docs/pages/guides/functions/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function FunctionsGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/getting-started/[[...slug]].tsx b/apps/docs/pages/guides/getting-started/[[...slug]].tsx
index 8791fae3a10..e16c15ac68f 100644
--- a/apps/docs/pages/guides/getting-started/[[...slug]].tsx
+++ b/apps/docs/pages/guides/getting-started/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function GettingStartedGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/graphql/[[...slug]].tsx b/apps/docs/pages/guides/graphql/[[...slug]].tsx
index 559e10f592b..00eaecfe221 100644
--- a/apps/docs/pages/guides/graphql/[[...slug]].tsx
+++ b/apps/docs/pages/guides/graphql/[[...slug]].tsx
@@ -5,14 +5,17 @@ import { serialize } from 'next-mdx-remote/serialize'
import { isAbsolute, relative } from 'path'
import rehypeSlug from 'rehype-slug'
import remarkGfm from 'remark-gfm'
-import codeHikeTheme from 'config/code-hike.theme.json' assert { type: 'json' }
+
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { UrlTransformFunction, linkTransform } from '~/lib/mdx/plugins/rehypeLinkTransform'
import remarkMkDocsAdmonition from '~/lib/mdx/plugins/remarkAdmonition'
import { removeTitle } from '~/lib/mdx/plugins/remarkRemoveTitle'
import remarkPyMdownTabs from '~/lib/mdx/plugins/remarkTabs'
+import codeHikeTheme from 'config/code-hike.theme.json' assert { type: 'json' }
+
// We fetch these docs at build time from an external repo
const org = 'supabase'
const repo = 'pg_graphql'
@@ -114,7 +117,7 @@ interface PGGraphQLDocsProps {
export default function PGGraphQLDocs({ source, meta }: PGGraphQLDocsProps) {
return (
-
+
)
diff --git a/apps/docs/pages/guides/platform/[[...slug]].tsx b/apps/docs/pages/guides/platform/[[...slug]].tsx
index 06340742556..f20307d7974 100644
--- a/apps/docs/pages/guides/platform/[[...slug]].tsx
+++ b/apps/docs/pages/guides/platform/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function PlatformGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/realtime/[[...slug]].tsx b/apps/docs/pages/guides/realtime/[[...slug]].tsx
index dddabae2a82..3a90134f5ad 100644
--- a/apps/docs/pages/guides/realtime/[[...slug]].tsx
+++ b/apps/docs/pages/guides/realtime/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function RealtimeGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/resources/[[...slug]].tsx b/apps/docs/pages/guides/resources/[[...slug]].tsx
index 1fb37bfe708..d73ad930fe5 100644
--- a/apps/docs/pages/guides/resources/[[...slug]].tsx
+++ b/apps/docs/pages/guides/resources/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function ResourcesGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/self-hosting/[[...slug]].tsx b/apps/docs/pages/guides/self-hosting/[[...slug]].tsx
index fee43e2be5b..c63d1c13b75 100644
--- a/apps/docs/pages/guides/self-hosting/[[...slug]].tsx
+++ b/apps/docs/pages/guides/self-hosting/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function SelfHostingGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/guides/self-hosting/analytics/config.tsx b/apps/docs/pages/guides/self-hosting/analytics/config.tsx
index 073411ca703..3946fc2c55c 100644
--- a/apps/docs/pages/guides/self-hosting/analytics/config.tsx
+++ b/apps/docs/pages/guides/self-hosting/analytics/config.tsx
@@ -3,6 +3,7 @@ import { MDXRemote } from 'next-mdx-remote'
import { serialize } from 'next-mdx-remote/serialize'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Param from '~/components/Params'
import Layout from '~/layouts/DefaultGuideLayout'
import { getAnalyticsConfigV0 } from '~/lib/mdx/getConfig'
@@ -27,6 +28,7 @@ export const Page = (props: InferGetStaticPropsType) => (
diff --git a/apps/docs/pages/guides/self-hosting/auth/config.tsx b/apps/docs/pages/guides/self-hosting/auth/config.tsx
index 50734320dfe..5702f8a5379 100644
--- a/apps/docs/pages/guides/self-hosting/auth/config.tsx
+++ b/apps/docs/pages/guides/self-hosting/auth/config.tsx
@@ -3,6 +3,7 @@ import { MDXRemote } from 'next-mdx-remote'
import { serialize } from 'next-mdx-remote/serialize'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Param from '~/components/Params'
import Layout from '~/layouts/DefaultGuideLayout'
import { getAuthConfigV1 } from '~/lib/mdx/getConfig'
@@ -27,6 +28,7 @@ export const Page = (props: InferGetStaticPropsType) => (
diff --git a/apps/docs/pages/guides/self-hosting/realtime/config.tsx b/apps/docs/pages/guides/self-hosting/realtime/config.tsx
index 1dd5086b214..09df809537c 100644
--- a/apps/docs/pages/guides/self-hosting/realtime/config.tsx
+++ b/apps/docs/pages/guides/self-hosting/realtime/config.tsx
@@ -3,6 +3,7 @@ import { MDXRemote } from 'next-mdx-remote'
import { serialize } from 'next-mdx-remote/serialize'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Param from '~/components/Params'
import Layout from '~/layouts/DefaultGuideLayout'
import { getRealtimeConfigV0 } from '~/lib/mdx/getConfig'
@@ -27,6 +28,7 @@ export const Page = (props: InferGetStaticPropsType) => (
diff --git a/apps/docs/pages/guides/self-hosting/storage/config.tsx b/apps/docs/pages/guides/self-hosting/storage/config.tsx
index 57a32f7cb96..8a131f674ac 100644
--- a/apps/docs/pages/guides/self-hosting/storage/config.tsx
+++ b/apps/docs/pages/guides/self-hosting/storage/config.tsx
@@ -3,6 +3,7 @@ import { MDXRemote } from 'next-mdx-remote'
import { serialize } from 'next-mdx-remote/serialize'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Param from '~/components/Params'
import Layout from '~/layouts/DefaultGuideLayout'
import { getStorageConfigV0 } from '~/lib/mdx/getConfig'
@@ -27,6 +28,7 @@ export const Page = (props: InferGetStaticPropsType) => (
diff --git a/apps/docs/pages/guides/storage/[[...slug]].tsx b/apps/docs/pages/guides/storage/[[...slug]].tsx
index c3ae4c4b3c3..90c4b978d88 100644
--- a/apps/docs/pages/guides/storage/[[...slug]].tsx
+++ b/apps/docs/pages/guides/storage/[[...slug]].tsx
@@ -2,6 +2,7 @@ import { type GetStaticPaths, type GetStaticProps, type InferGetStaticPropsType
import { MDXRemote } from 'next-mdx-remote'
import components from '~/components'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import Layout from '~/layouts/DefaultGuideLayout'
import { getGuidesStaticPaths, getGuidesStaticProps } from '~/lib/docs'
@@ -21,7 +22,7 @@ export default function StorageGuide({
const { hideToc, ...meta } = frontmatter
return (
-
+
)
diff --git a/apps/docs/pages/handbook/contributing.mdx b/apps/docs/pages/handbook/contributing.mdx
deleted file mode 100644
index 5365b2fb9f9..00000000000
--- a/apps/docs/pages/handbook/contributing.mdx
+++ /dev/null
@@ -1,32 +0,0 @@
-import Layout from '~/layouts/DefaultGuideLayout'
-
-export const meta = {
- id: 'contributing',
- title: 'Contributing',
- description: 'Want to help?',
-}
-
-## How to contribute
-
-Supabase has many [open source repos](https://github.com/orgs/supabase/repositories). Some of the more popular ones are:
-
-- [Supabase](https://github.com/supabase/supabase) - Our Dashboard, Websites, and example apps
-- [Supabase-js](https://github.com/supabase/supabase-js) - A client-side library written in TypeScript
-- [Gotrue](https://github.com/supabase/gotrue) - Our auth server, written in Go
-- [Realtime](https://github.com/supabase/realtime) - A server for streaming changes from Postgres, written in Elixir
-- [browse all](https://github.com/orgs/supabase/repositories)
-
-Want to contribute? Why not jump into our GitHub repo and:
-
-- [Sponsor Supabase](https://github.com/sponsors/supabase).
-- [Answer Discussions](https://github.com/supabase/supabase/discussions).
-- Submit an issue to one of our [repos](https://github.com/orgs/supabase/repositories)
-- Report a performance issue or a part of the documentation that you find confusing.
-- Create a pull request in one of our [repos](https://github.com/orgs/supabase/repositories)
-- [Translate our Readme](https://github.com/supabase/supabase/issues/1341).
-- Try our products and give feedback.
-- Spread the word if you like what we are doing.
-
-export const Page = ({ children }) =>
-
-export default Page
diff --git a/apps/docs/pages/handbook/introduction.mdx b/apps/docs/pages/handbook/introduction.mdx
deleted file mode 100644
index f6f2fc2c162..00000000000
--- a/apps/docs/pages/handbook/introduction.mdx
+++ /dev/null
@@ -1,21 +0,0 @@
-import Layout from '~/layouts/DefaultGuideLayout'
-
-export const meta = {
- id: 'introduction',
- title: 'Supabase Handbook',
- description: 'The Supabase public handbook and manifesto',
-}
-
-Supabase is thinking in public. Everything is online, no matter how raw the current state of things.
-
-This is our public handbook and manifesto. We are completely opensource and this means that you, our users, are also our team members.
-
----
-
-## Opensource
-
-Wherever we can we will support existing opensource tools and libraries.
-
-export const Page = ({ children }) =>
-
-export default Page
diff --git a/apps/docs/pages/reference/analytics/[...slug].tsx b/apps/docs/pages/reference/analytics/[...slug].tsx
deleted file mode 100644
index 6ba5e15111c..00000000000
--- a/apps/docs/pages/reference/analytics/[...slug].tsx
+++ /dev/null
@@ -1,168 +0,0 @@
-import specFile from '~/spec/transforms/analytics_v0_openapi_deparsed.json' assert { type: 'json' }
-import { gen_v3, enrichedOperation } from '~/lib/refGenerator/helpers'
-import { Tabs, CodeBlock } from 'ui'
-
-import RefSubLayout from '~/layouts/ref/RefSubLayout'
-
-export type AcceptedValue = {
- id: string
- name: string
- type: 'string' | 'boolean' | 'object'
- description?: string
-}
-
-export type Flag = {
- id: string
- name: string
- description: string
- default_value: string
- accepted_values: AcceptedValue[]
-}
-
-export type ApiParameter = {
- example: string
- in: string
- name: string
- required: boolean
- schema: {
- type: string
- example: string
- }
-}
-// @ts-ignore
-const generatedSpec = gen_v3(specFile, 'wat', { apiUrl: 'apiv0' })
-
-export default function Config() {
- return (
-
-
-
-
-
{generatedSpec.info.title}
-
{generatedSpec.info.description}
-
-
-
- {generatedSpec.operations.map((operation: any) => (
-
-
-
-
-
- {operation.operation}
- {operation.fullPath}
-
-
- {/* Path Parameters */}
- {operation.parameters &&
- operation.parameters.filter((parameter) => parameter.in === 'path').length >
- 0 && (
-
- )}
-
- {/* Header Parameters */}
- {operation.parameters &&
- operation.parameters.filter((parameter) => parameter.in === 'header').length >
- 0 && (
-
- )}
-
-
- {operation.responseList.length > 0 && (
- <>
- Responses
-
- {operation.responseList.map((response: any) => (
-
- {response.description}
- {response?.content && response?.content['application/json'] && (
-
-
- {JSON.stringify(response.content['application/json'], null, 2)}
-
-
- )}
-
- ))}
-
- >
- )}
-
-
-
- ))}
-
-
-
-
- )
-}
diff --git a/apps/docs/pages/reference/analytics/config.tsx b/apps/docs/pages/reference/analytics/config.tsx
deleted file mode 100644
index 4db5c72958f..00000000000
--- a/apps/docs/pages/reference/analytics/config.tsx
+++ /dev/null
@@ -1,114 +0,0 @@
-import fs from 'fs'
-import matter from 'gray-matter'
-import components from '~/components/index'
-import { MDXRemote } from 'next-mdx-remote'
-import { serialize } from 'next-mdx-remote/serialize'
-
-import specFile from '~/spec/analytics_v0_config.yaml' assert { type: 'yml' }
-import { Parameter } from '~/lib/refGenerator/refTypes'
-
-import ReactMarkdown from 'react-markdown'
-
-// Parameters are grouped on the page by tag
-const TAGS = ['general', 'database']
-
-export default function Config(props) {
- return (
-
-
-
-
{specFile.info.title} Configuration
-
{specFile.info.description}
-
-
- {props.docs
- .filter((doc) => doc.introPage)
- .map((item) => (
-
- ))}
-
- {TAGS.map((tag) =>
- specFile.parameters
- .filter((param: Parameter) => param.tags[0] === tag)
- .map((parameter: Parameter, index) => (
-
- {index === 0 &&
{tag} Settings
}
-
-
-
- $
- {parameter.title}
-
-
-
-
-
- {parameter.description}
-
-
-
- Required: {parameter.required.toString()}
-
-
- Default:
-
- {parameter.default ? parameter.default.toString() : 'None'}
-
-
-
-
- {parameter.links &&
- parameter.links.map((link) => (
-
- ))}
-
-
-
-
-
- ))
- )}
-
-
-
-
- )
-}
-export async function getServerSideProps() {
- // an array of ids of the intro sections for this library
- const introPages = ['analytics']
-
- const pages = [...introPages]
-
- // Grab custom markdown intro page files
- const allMarkdownDocs = await Promise.all(
- pages.map(async (x: any, i) => {
- const pathName = `docs/ref/analytics/${x}.mdx`
-
- const markdownExists = fs.existsSync(pathName)
-
- const fileContents = markdownExists ? fs.readFileSync(pathName, 'utf8') : ''
- const { data, content } = matter(fileContents)
-
- return {
- id: x,
- title: x,
- // ...content,
- meta: data,
- introPage: introPages.includes(x),
- content: content ? await serialize(content || '') : null,
- }
- })
- )
-
- return {
- props: {
- docs: allMarkdownDocs,
- },
- }
-}
diff --git a/apps/docs/pages/reference/api/[...slug].tsx b/apps/docs/pages/reference/api/[...slug].tsx
index 27760ce04d8..d9c72242668 100644
--- a/apps/docs/pages/reference/api/[...slug].tsx
+++ b/apps/docs/pages/reference/api/[...slug].tsx
@@ -1,18 +1,28 @@
-import apiCommonSections from '~/spec/common-api-sections.json' assert { type: 'json' }
-import specFile from '~/spec/transforms/api_v0_openapi_deparsed.json' assert { type: 'json' }
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { gen_v3 } from '~/lib/refGenerator/helpers'
+import apiCommonSections from '~/spec/common-api-sections.json' assert { type: 'json' }
+import specFile from '~/spec/transforms/api_v0_openapi_deparsed.json' assert { type: 'json' }
+
// @ts-ignore
const generatedSpec = gen_v3(specFile, 'wat', { apiUrl: 'apiv0' })
const sections = flattenSections(apiCommonSections)
const libraryPath = '/api'
export default function Config(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/auth/[...slug].tsx b/apps/docs/pages/reference/auth/[...slug].tsx
deleted file mode 100644
index 8664fe97acb..00000000000
--- a/apps/docs/pages/reference/auth/[...slug].tsx
+++ /dev/null
@@ -1,168 +0,0 @@
-import { CodeBlock, Tabs } from 'ui'
-import specFile from '~/spec/transforms/auth_v1_openapi_deparsed.json' assert { type: 'json' }
-import { gen_v3 } from '~/lib/refGenerator/helpers'
-
-import RefSubLayout from '~/layouts/ref/RefSubLayout'
-
-export type AcceptedValue = {
- id: string
- name: string
- type: 'string' | 'boolean' | 'object'
- description?: string
-}
-
-export type Flag = {
- id: string
- name: string
- description: string
- default_value: string
- accepted_values: AcceptedValue[]
-}
-
-export type ApiParameter = {
- example: string
- in: string
- name: string
- required: boolean
- schema: {
- type: string
- example: string
- }
-}
-// @ts-ignore
-const generatedSpec = gen_v3(specFile, 'wat', { apiUrl: 'apiv0' })
-
-export default function Config() {
- return (
-
-
-
-
-
{generatedSpec.info.title}
-
{generatedSpec.info.description}
-
-
-
- {generatedSpec.operations.map((operation: any) => (
-
-
-
-
-
- {operation.operation}
- {operation.fullPath}
-
-
- {/* Path Parameters */}
- {operation.parameters &&
- operation.parameters.filter((parameter) => parameter.in === 'path').length >
- 0 && (
-
- )}
-
- {/* Header Parameters */}
- {operation.parameters &&
- operation.parameters.filter((parameter) => parameter.in === 'header').length >
- 0 && (
-
- )}
-
-
- {operation.responseList.length > 0 && (
- <>
- Responses
-
- {operation.responseList.map((response: any) => (
-
- {response.description}
- {response?.content && response?.content['application/json'] && (
-
-
- {JSON.stringify(response.content['application/json'], null, 2)}
-
-
- )}
-
- ))}
-
- >
- )}
-
-
-
- ))}
-
-
-
-
- )
-}
diff --git a/apps/docs/pages/reference/auth/config.tsx b/apps/docs/pages/reference/auth/config.tsx
deleted file mode 100644
index d9c1e5eacbf..00000000000
--- a/apps/docs/pages/reference/auth/config.tsx
+++ /dev/null
@@ -1,73 +0,0 @@
-import specFile from '~/spec/gotrue_v1_config.yaml' assert { type: 'yml' }
-import { Parameter } from '~/lib/refGenerator/refTypes'
-import ReactMarkdown from 'react-markdown'
-import Head from 'next/head'
-
-// Parameters are grouped on the page by tag
-const TAGS = ['general']
-
-export default function Config() {
- return (
- <>
-
- Auth config
-
-
-
-
-
{specFile.info.title} Configuration
-
{specFile.info.description}
-
- {TAGS.map((tag) =>
- specFile.parameters
- .filter((param: Parameter) => param.tags[0] === tag)
- .map((parameter: Parameter, index) => (
-
- {index === 0 &&
{tag}
}
-
-
-
- $
- {parameter.title}
-
-
-
-
-
- {parameter.description}
-
-
-
- Required: {parameter.required.toString()}
-
-
- Default:
-
- {parameter.default ? parameter.default.toString() : 'None'}
-
-
-
-
- {parameter.links &&
- parameter.links.map((link) => (
-
- ))}
-
-
-
-
-
- ))
- )}
-
-
-
-
- >
- )
-}
diff --git a/apps/docs/pages/reference/cli/[...slug].tsx b/apps/docs/pages/reference/cli/[...slug].tsx
index 75b9088f7fa..779e04540b6 100644
--- a/apps/docs/pages/reference/cli/[...slug].tsx
+++ b/apps/docs/pages/reference/cli/[...slug].tsx
@@ -1,17 +1,25 @@
-import spec from '~/spec/cli_v1_commands.yaml' assert { type: 'yml' }
-
-import { flattenSections } from '~/lib/helpers'
-
-import cliCommonSections from '~/spec/common-cli-sections.json' assert { type: 'json' }
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import RefSectionHandler from '~/components/reference/RefSectionHandler'
+import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
+import spec from '~/spec/cli_v1_commands.yaml' assert { type: 'yml' }
+import cliCommonSections from '~/spec/common-cli-sections.json' assert { type: 'json' }
+
const sections = flattenSections(cliCommonSections)
const libraryPath = '/cli'
export default function CliRef(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/csharp/[...slug].tsx b/apps/docs/pages/reference/csharp/[...slug].tsx
index 8145e38f7c9..77dba701704 100644
--- a/apps/docs/pages/reference/csharp/[...slug].tsx
+++ b/apps/docs/pages/reference/csharp/[...slug].tsx
@@ -4,12 +4,21 @@ import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/csharp'
export default function CSharpReference(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/csharp/crawlers/[...slug].tsx b/apps/docs/pages/reference/csharp/crawlers/[...slug].tsx
index 0d515778deb..aa454e5d162 100644
--- a/apps/docs/pages/reference/csharp/crawlers/[...slug].tsx
+++ b/apps/docs/pages/reference/csharp/crawlers/[...slug].tsx
@@ -7,6 +7,7 @@ import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { useRouter } from 'next/router'
import RefSEO from '~/components/reference/RefSEO'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/csharp'
@@ -25,6 +26,7 @@ export default function CSharpReference(props) {
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/csharp/v0/crawlers/[...slug].tsx b/apps/docs/pages/reference/csharp/v0/crawlers/[...slug].tsx
index 5e20575d173..101c289bddb 100644
--- a/apps/docs/pages/reference/csharp/v0/crawlers/[...slug].tsx
+++ b/apps/docs/pages/reference/csharp/v0/crawlers/[...slug].tsx
@@ -7,6 +7,7 @@ import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { useRouter } from 'next/router'
import RefSEO from '~/components/reference/RefSEO'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/csharp/v0'
@@ -24,6 +25,7 @@ export default function JSReference(props) {
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/dart/crawlers/[...slug].tsx b/apps/docs/pages/reference/dart/crawlers/[...slug].tsx
index faace96a0ba..b18c2eeff9b 100644
--- a/apps/docs/pages/reference/dart/crawlers/[...slug].tsx
+++ b/apps/docs/pages/reference/dart/crawlers/[...slug].tsx
@@ -7,6 +7,7 @@ import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { useRouter } from 'next/router'
import RefSEO from '~/components/reference/RefSEO'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/dart'
@@ -25,6 +26,7 @@ export default function DartReference(props) {
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/kotlin/crawlers/[...slug].tsx b/apps/docs/pages/reference/kotlin/crawlers/[...slug].tsx
index 2a0d1cadc29..2f3885d524b 100644
--- a/apps/docs/pages/reference/kotlin/crawlers/[...slug].tsx
+++ b/apps/docs/pages/reference/kotlin/crawlers/[...slug].tsx
@@ -7,6 +7,7 @@ import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { useRouter } from 'next/router'
import RefSEO from '~/components/reference/RefSEO'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/kotlin'
@@ -25,6 +26,7 @@ export default function KotlinReference(props) {
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/self-hosting-auth/[...slug].tsx b/apps/docs/pages/reference/self-hosting-auth/[...slug].tsx
index 723d11e079b..fbd09b75644 100644
--- a/apps/docs/pages/reference/self-hosting-auth/[...slug].tsx
+++ b/apps/docs/pages/reference/self-hosting-auth/[...slug].tsx
@@ -1,11 +1,13 @@
-import authSpec from '~/spec/auth_v1_openapi.json' assert { type: 'json' }
-import selfHostingAuthCommonSections from '~/spec/common-self-hosting-auth-sections.json'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { gen_v3 } from '~/lib/refGenerator/helpers'
+import authSpec from '~/spec/auth_v1_openapi.json' assert { type: 'json' }
+import selfHostingAuthCommonSections from '~/spec/common-self-hosting-auth-sections.json'
+
const sections = flattenSections(selfHostingAuthCommonSections)
const libraryPath = '/self-hosting-auth'
@@ -13,7 +15,15 @@ const libraryPath = '/self-hosting-auth'
const spec = gen_v3(authSpec, 'wat', { apiUrl: 'apiv0' })
export default function SelfHostAuthReference(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/self-hosting-functions/[...slug].tsx b/apps/docs/pages/reference/self-hosting-functions/[...slug].tsx
index bbd3f335313..432e1a6cec0 100644
--- a/apps/docs/pages/reference/self-hosting-functions/[...slug].tsx
+++ b/apps/docs/pages/reference/self-hosting-functions/[...slug].tsx
@@ -1,16 +1,23 @@
-import selfHostingFunctionsCommonSections from '~/spec/common-self-hosting-functions-sections.json'
-
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
-import { gen_v3 } from '~/lib/refGenerator/helpers'
+
+import selfHostingFunctionsCommonSections from '~/spec/common-self-hosting-functions-sections.json' assert { type: 'json' }
const sections = flattenSections(selfHostingFunctionsCommonSections)
const libraryPath = '/self-hosting-functions'
export default function SelfHostFunctionsReference(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/self-hosting-realtime/[...slug].tsx b/apps/docs/pages/reference/self-hosting-realtime/[...slug].tsx
index 59c9276e5b7..3b894c15f8b 100644
--- a/apps/docs/pages/reference/self-hosting-realtime/[...slug].tsx
+++ b/apps/docs/pages/reference/self-hosting-realtime/[...slug].tsx
@@ -1,15 +1,23 @@
-import selfHostingRealtimeCommonSections from '~/spec/common-self-hosting-realtime-sections.json'
-
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
+import selfHostingRealtimeCommonSections from '~/spec/common-self-hosting-realtime-sections.json' assert { type: 'json' }
+
const sections = flattenSections(selfHostingRealtimeCommonSections)
const libraryPath = '/self-hosting-realtime'
export default function SelfHostRealtimeReference(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/self-hosting-storage/[...slug].tsx b/apps/docs/pages/reference/self-hosting-storage/[...slug].tsx
index 1468b40f3a9..13559bdc7dc 100644
--- a/apps/docs/pages/reference/self-hosting-storage/[...slug].tsx
+++ b/apps/docs/pages/reference/self-hosting-storage/[...slug].tsx
@@ -1,11 +1,13 @@
-import storageSpec from '~/spec/storage_v0_openapi.json' assert { type: 'json' }
-import selfHostingStorageCommonSections from '~/spec/common-self-hosting-storage-sections.json'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { gen_v3 } from '~/lib/refGenerator/helpers'
+import storageSpec from '~/spec/storage_v0_openapi.json' assert { type: 'json' }
+import selfHostingStorageCommonSections from '~/spec/common-self-hosting-storage-sections.json' assert { type: 'json' }
+
const sections = flattenSections(selfHostingStorageCommonSections)
const libraryPath = '/self-hosting-storage'
@@ -13,7 +15,15 @@ const libraryPath = '/self-hosting-storage'
const spec = gen_v3(storageSpec, 'wat', { apiUrl: 'apiv0' })
export default function SelfHostStorageReference(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/swift/[...slug].tsx b/apps/docs/pages/reference/swift/[...slug].tsx
index 6c84806c676..c459f833e11 100644
--- a/apps/docs/pages/reference/swift/[...slug].tsx
+++ b/apps/docs/pages/reference/swift/[...slug].tsx
@@ -4,12 +4,21 @@ import RefSectionHandler from '~/components/reference/RefSectionHandler'
import { flattenSections } from '~/lib/helpers'
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/swift'
export default function SwiftReference(props) {
- return
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/swift/crawlers/[...slug].tsx b/apps/docs/pages/reference/swift/crawlers/[...slug].tsx
index d8e3be4f79c..69000ea9674 100644
--- a/apps/docs/pages/reference/swift/crawlers/[...slug].tsx
+++ b/apps/docs/pages/reference/swift/crawlers/[...slug].tsx
@@ -7,6 +7,7 @@ import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { useRouter } from 'next/router'
import RefSEO from '~/components/reference/RefSEO'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/swift'
@@ -25,6 +26,7 @@ export default function SwiftReference(props) {
+ return (
+
+ )
}
export async function getStaticProps() {
diff --git a/apps/docs/pages/reference/swift/v0/crawlers/[...slug].tsx b/apps/docs/pages/reference/swift/v1/crawlers/[...slug].tsx
similarity index 92%
rename from apps/docs/pages/reference/swift/v0/crawlers/[...slug].tsx
rename to apps/docs/pages/reference/swift/v1/crawlers/[...slug].tsx
index 6c19debf234..1ef50177ac2 100644
--- a/apps/docs/pages/reference/swift/v0/crawlers/[...slug].tsx
+++ b/apps/docs/pages/reference/swift/v1/crawlers/[...slug].tsx
@@ -7,6 +7,7 @@ import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
import { useRouter } from 'next/router'
import RefSEO from '~/components/reference/RefSEO'
+import { MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
const sections = flattenSections(clientLibsCommonSections)
const libraryPath = '/swift/v2'
@@ -24,6 +25,7 @@ export default function SwiftReference(props) {