feat(turbo): restructured repo to be a standard turborepo monorepo (#341)

* added turborepo

* finished turbo migration

* updated gitignore

* use dotenv & run format

* fixed error in docs

* remove standalone deployment in prod

* fix ts error, remove ignore ts errors during build

* added formatter to the end of the docs generator
This commit is contained in:
Waleed Latif
2025-05-09 21:45:49 -07:00
committed by GitHub
parent 1438028982
commit a92ee8bf46
1072 changed files with 39956 additions and 22581 deletions
@@ -0,0 +1,46 @@
import type { ReactNode } from 'react'
import Link from 'next/link'
import { DocsLayout } from 'fumadocs-ui/layouts/docs'
import { ExternalLink, GithubIcon } from 'lucide-react'
import { source } from '@/lib/source'
const GitHubLink = () => (
<div className="fixed bottom-4 right-4 z-50">
<Link
href="https://github.com/simstudioai/sim"
target="_blank"
rel="noopener noreferrer"
className="flex items-center justify-center w-8 h-8 rounded-full bg-background border border-border hover:bg-muted transition-colors"
>
<GithubIcon className="h-4 w-4" />
</Link>
</div>
)
export default function Layout({ children }: { children: ReactNode }) {
return (
<>
<DocsLayout
tree={source.pageTree}
nav={{
title: <div className="flex items-center font-medium">Sim Studio</div>,
}}
links={[
{
text: 'Visit Sim Studio',
url: 'https://simstudio.ai',
icon: <ExternalLink className="h-4 w-4" />,
},
]}
sidebar={{
defaultOpenLevel: 1,
collapsible: true,
footer: null,
}}
>
{children}
</DocsLayout>
<GitHubLink />
</>
)
}
+58
View File
@@ -0,0 +1,58 @@
import { notFound } from 'next/navigation'
import { DocsBody, DocsDescription, DocsPage, DocsTitle } from 'fumadocs-ui/page'
import mdxComponents from '@/components/mdx-components'
import { source } from '@/lib/source'
export const dynamic = 'force-static'
export default async function Page(props: { params: Promise<{ slug?: string[] }> }) {
const params = await props.params
const page = source.getPage(params.slug)
if (!page) notFound()
const MDX = page.data.body
return (
<DocsPage
toc={page.data.toc}
full={page.data.full}
tableOfContent={{
style: 'clerk',
enabled: true,
header: <div className="mb-2 text-sm font-medium">On this page</div>,
single: false,
}}
article={{
className: 'scroll-smooth max-sm:pb-16',
}}
tableOfContentPopover={{
style: 'clerk',
enabled: true,
}}
footer={{
enabled: false,
}}
>
<DocsTitle>{page.data.title}</DocsTitle>
<DocsDescription>{page.data.description}</DocsDescription>
<DocsBody>
<MDX components={mdxComponents} />
</DocsBody>
</DocsPage>
)
}
export async function generateStaticParams() {
return source.generateParams()
}
export async function generateMetadata(props: { params: Promise<{ slug?: string[] }> }) {
const params = await props.params
const page = source.getPage(params.slug)
if (!page) notFound()
return {
title: page.data.title,
description: page.data.description,
}
}
+4
View File
@@ -0,0 +1,4 @@
import { createFromSource } from 'fumadocs-core/search/server'
import { source } from '@/lib/source'
export const { GET } = createFromSource(source)
+18
View File
@@ -0,0 +1,18 @@
@import 'tailwindcss';
@import 'fumadocs-ui/css/neutral.css';
@import 'fumadocs-ui/css/preset.css';
:root {
--color-fd-primary: #802fff; /* Purple from control-bar component */
}
/* Custom text highlighting styles */
.text-highlight {
color: var(--color-fd-primary);
}
/* Override marker color for highlighted lists */
.highlight-markers li::marker {
color: var(--color-fd-primary);
}
@source '../node_modules/fumadocs-ui/dist/**/*.js';
+21
View File
@@ -0,0 +1,21 @@
import type { BaseLayoutProps } from 'fumadocs-ui/layouts/shared'
/**
* Shared layout configurations
*
* you can customise layouts individually from:
* Home Layout: app/(home)/layout.tsx
* Docs Layout: app/docs/layout.tsx
*/
export const baseOptions: BaseLayoutProps = {
nav: {
title: (
<>
<svg width="24" height="24" xmlns="http://www.w3.org/2000/svg" aria-label="Logo">
<circle cx={12} cy={12} r={12} fill="currentColor" />
</svg>
My App
</>
),
},
}
+38
View File
@@ -0,0 +1,38 @@
import type { ReactNode } from 'react'
import { Inter } from 'next/font/google'
import { RootProvider } from 'fumadocs-ui/provider'
import './global.css'
const inter = Inter({
subsets: ['latin'],
})
export default function Layout({ children }: { children: ReactNode }) {
return (
<html lang="en" className={inter.className} suppressHydrationWarning>
<body className="flex flex-col min-h-screen">
<RootProvider>{children}</RootProvider>
</body>
</html>
)
}
export const metadata = {
title: 'Sim Studio',
description:
'Build agents in seconds with a drag and drop workflow builder. Access comprehensive documentation to help you create efficient workflows and maximize your automation capabilities.',
manifest: '/favicon/site.webmanifest',
icons: {
icon: [
{ url: '/favicon/favicon-16x16.png', sizes: '16x16', type: 'image/png' },
{ url: '/favicon/favicon-32x32.png', sizes: '32x32', type: 'image/png' },
],
apple: '/favicon/apple-touch-icon.png',
shortcut: '/favicon/favicon.ico',
},
appleWebApp: {
capable: true,
statusBarStyle: 'default',
title: 'Sim Studio Docs',
},
}