-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0debf75
commit 5c4a6fd
Showing
27 changed files
with
491 additions
and
305 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Deep Directories | ||
**/dist | ||
**/smoke | ||
**/node_modules | ||
**/fixtures | ||
**/vendor | ||
**/.vercel | ||
|
||
# Files | ||
pnpm-lock.yaml | ||
|
||
# Formatted by Biome | ||
**/*.json | ||
**/*.js | ||
**/*.ts | ||
**/*.tsx | ||
**/*.jsx | ||
**/*.mjs | ||
**/*.cjs | ||
**/*.css |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,13 @@ | ||
import landing from "@/app/_images/landing.gif" | ||
import landing from "@/app/_images/landing.gif"; | ||
import Image from "next/image"; | ||
export default function HomePage() { | ||
return ( | ||
<main className="flex h-full flex-col items-center text-center gap-4 mt-15"> | ||
<div className="text-2xl font-semibold">Stardust, the container streaming platform</div> | ||
<div className="text-muted-foreground">Stardust is a container streaming platform that allows you to stream your containers to any device, anywhere.</div> | ||
<Image src={landing} alt="Stardust" className="justify-self-center w-[80rem] h-[50rem] rounded-lg p-4" /> | ||
|
||
</main> | ||
); | ||
return ( | ||
<main className="flex h-full flex-col items-center text-center gap-4 mt-15"> | ||
<div className="text-2xl font-semibold">Stardust, the container streaming platform</div> | ||
<div className="text-muted-foreground"> | ||
Stardust is a container streaming platform that allows you to stream your containers to any device, anywhere. | ||
</div> | ||
<Image src={landing} alt="Stardust" className="justify-self-center w-[80rem] h-[50rem] rounded-lg p-4" /> | ||
</main> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
import { getPages } from '@/app/source'; | ||
import { createSearchAPI } from 'fumadocs-core/search/server'; | ||
import { getPages } from "@/app/source"; | ||
import { createSearchAPI } from "fumadocs-core/search/server"; | ||
|
||
export const { GET } = createSearchAPI('advanced', { | ||
indexes: getPages().map((page) => ({ | ||
title: page.data.title, | ||
structuredData: page.data.exports.structuredData, | ||
id: page.url, | ||
url: page.url, | ||
})), | ||
export const { GET } = createSearchAPI("advanced", { | ||
indexes: getPages().map((page) => ({ | ||
title: page.data.title, | ||
structuredData: page.data.exports.structuredData, | ||
id: page.url, | ||
url: page.url, | ||
})), | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,84 +1,84 @@ | ||
import { getPage, getPages } from "@/app/source"; | ||
import type { Metadata } from "next"; | ||
import { DocsPage, DocsBody } from "fumadocs-ui/page"; | ||
import { Card, Cards } from "fumadocs-ui/components/card"; | ||
import { notFound } from "next/navigation"; | ||
import { ImageZoom } from "fumadocs-ui/components/image-zoom"; | ||
import { DocsBody, DocsPage } from "fumadocs-ui/page"; | ||
import { ExternalLinkIcon } from "lucide-react"; | ||
import {ImageZoom} from "fumadocs-ui/components/image-zoom"; | ||
import type { Metadata } from "next"; | ||
import { notFound } from "next/navigation"; | ||
import React from "react"; | ||
export default async function Page({ | ||
params, | ||
params, | ||
}: { | ||
params: { slug?: string[] }; | ||
params: { slug?: string[] }; | ||
}) { | ||
const page = getPage(params.slug); | ||
const page = getPage(params.slug); | ||
|
||
if (page == null) { | ||
notFound(); | ||
} | ||
if (page == null) { | ||
notFound(); | ||
} | ||
|
||
const MDX = page.data.exports.default; | ||
const path = `content/docs/${page.file.path}`; | ||
const MDX = page.data.exports.default; | ||
const path = `content/docs/${page.file.path}`; | ||
|
||
return ( | ||
<DocsPage | ||
toc={page.data.exports.toc} | ||
lastUpdate={page.data.exports.lastModified} | ||
tableOfContent={{ | ||
footer: ( | ||
<a | ||
href={`https://github.com/spaceness/stardust-docs/tree/main/${path}`} | ||
target="_blank" | ||
rel="noreferrer noopener" | ||
className="inline-flex items-center text-xs text-muted-foreground hover:text-foreground" | ||
> | ||
Edit on GitHub <ExternalLinkIcon className="ml-1 size-3" /> | ||
</a> | ||
), | ||
}} | ||
> | ||
<DocsBody> | ||
<h1>{page.data.title}</h1> | ||
<MDX | ||
components={{ | ||
Card: (props) => <Card {...props} />, | ||
Cards: (props) => <Cards {...props} />, | ||
// @ts-expect-error | ||
img: (props) => <ImageZoom {...props} />, | ||
}} | ||
/> | ||
</DocsBody> | ||
</DocsPage> | ||
); | ||
return ( | ||
<DocsPage | ||
toc={page.data.exports.toc} | ||
lastUpdate={page.data.exports.lastModified} | ||
tableOfContent={{ | ||
footer: ( | ||
<a | ||
href={`https://github.com/spaceness/stardust-docs/tree/main/${path}`} | ||
target="_blank" | ||
rel="noreferrer noopener" | ||
className="inline-flex items-center text-xs text-muted-foreground hover:text-foreground" | ||
> | ||
Edit on GitHub <ExternalLinkIcon className="ml-1 size-3" /> | ||
</a> | ||
), | ||
}} | ||
> | ||
<DocsBody> | ||
<h1>{page.data.title}</h1> | ||
<MDX | ||
components={{ | ||
Card: (props) => <Card {...props} />, | ||
Cards: (props) => <Cards {...props} />, | ||
// @ts-expect-error | ||
img: (props) => <ImageZoom {...props} />, | ||
}} | ||
/> | ||
</DocsBody> | ||
</DocsPage> | ||
); | ||
} | ||
|
||
export async function generateStaticParams() { | ||
return getPages().map((page) => ({ | ||
slug: page.slugs, | ||
})); | ||
return getPages().map((page) => ({ | ||
slug: page.slugs, | ||
})); | ||
} | ||
|
||
export function generateMetadata({ params }: { params: { slug?: string[] } }) { | ||
const page = getPage(params.slug); | ||
const page = getPage(params.slug); | ||
|
||
if (page == null) notFound(); | ||
const imageParams = new URLSearchParams(); | ||
const description = page.data.description ?? ""; | ||
imageParams.set("title", page.data.title); | ||
imageParams.set("description", description); | ||
if (page == null) notFound(); | ||
const imageParams = new URLSearchParams(); | ||
const description = page.data.description ?? ""; | ||
imageParams.set("title", page.data.title); | ||
imageParams.set("description", description); | ||
|
||
const image = { | ||
alt: "Banner", | ||
url: `/api/og?${imageParams.toString()}`, | ||
width: 1200, | ||
height: 630, | ||
}; | ||
return { | ||
title: page.data.title, | ||
description: page.data.description, | ||
openGraph: { | ||
url: `/docs/${page.slugs.join("/")}`, | ||
images: image, | ||
}, | ||
} satisfies Metadata; | ||
const image = { | ||
alt: "Banner", | ||
url: `/api/og?${imageParams.toString()}`, | ||
width: 1200, | ||
height: 630, | ||
}; | ||
return { | ||
title: page.data.title, | ||
description: page.data.description, | ||
openGraph: { | ||
url: `/docs/${page.slugs.join("/")}`, | ||
images: image, | ||
}, | ||
} satisfies Metadata; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
import { DocsLayout } from "fumadocs-ui/layout"; | ||
import { layoutOptions } from "../layout-options"; | ||
import type { ReactNode } from "react"; | ||
import { layoutOptions } from "../layout-options"; | ||
|
||
export default function RootDocsLayout({ children }: { children: ReactNode }) { | ||
return <DocsLayout {...layoutOptions}>{children}</DocsLayout>; | ||
return <DocsLayout {...layoutOptions}>{children}</DocsLayout>; | ||
} |
Oops, something went wrong.