Skip to content

Commit f9b3c7c

Browse files
committed
doc tweaks
1 parent 9c26e45 commit f9b3c7c

2 files changed

Lines changed: 27 additions & 2 deletions

File tree

website/src/app/docs/layout.tsx

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,29 @@
11
import { source } from '@/lib/source';
22
import { DocsLayout } from 'fumadocs-ui/layouts/docs';
33
import { baseOptions } from '@/lib/layout.shared';
4+
import { Zap } from 'lucide-react';
45

56
export default function Layout({ children }: LayoutProps<'/docs'>) {
7+
const { links, ...options } = baseOptions();
68
return (
79
<DocsLayout
810
tree={source.getPageTree()}
9-
{...baseOptions()}
11+
{...options}
12+
links={links?.filter((link) => 'url' in link && link.url !== '/docs' && link.url !== 'https://rbby.dev')}
1013
sidebar={{
1114
defaultOpenLevel: 1,
15+
footer: (
16+
<div className="-mx-2 mb-2 mt-2 rounded-lg bg-fd-accent/50 px-2 py-1.5">
17+
<a
18+
href="https://rbby.dev"
19+
target="_blank"
20+
rel="noopener noreferrer"
21+
className="flex items-center justify-center gap-1.5 text-sm text-fd-muted-foreground hover:text-fd-foreground transition-colors"
22+
>
23+
by <Zap className="size-3.5" /> rbby.dev
24+
</a>
25+
</div>
26+
),
1227
}}
1328
>
1429
{children}

website/src/lib/layout.shared.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { BaseLayoutProps } from 'fumadocs-ui/layouts/shared';
2-
import { BookOpen, SquareTerminal } from 'lucide-react';
2+
import { BookOpen, SquareTerminal, Zap } from 'lucide-react';
33
import { gitConfig } from './shared';
44

55
export function baseOptions(): BaseLayoutProps {
@@ -32,6 +32,16 @@ export function baseOptions(): BaseLayoutProps {
3232
url: 'https://rbby.dev/gnata-sqlite/playground',
3333
external: true,
3434
},
35+
{
36+
text: (
37+
<span className="inline-flex items-center gap-1.5">
38+
<Zap className="size-4" />
39+
rbby.dev
40+
</span>
41+
),
42+
url: 'https://rbby.dev',
43+
external: true,
44+
},
3545
],
3646
};
3747
}

0 commit comments

Comments
 (0)