Skip to content

Commit 1707cc0

Browse files
committed
Use existing Button(ui) component in DocsNavigation.
1 parent aa733f1 commit 1707cc0

File tree

1 file changed

+19
-16
lines changed

1 file changed

+19
-16
lines changed

components/docs/content/DocsNavigation.tsx

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
import { ArrowLeft, ArrowRight } from "lucide-react";
44
import Link from "next/link";
5+
import { Button } from "@/components/ui/button";
56

67
interface NavigationLink {
78
title: string;
@@ -20,28 +21,30 @@ export function DocsNavigation({ prev, next }: DocsNavigationProps) {
2021
aria-label="Documentation navigation"
2122
>
2223
{prev ? (
23-
<Link
24-
href={prev.path}
25-
prefetch
26-
aria-label={`Previous: ${prev.title}`}
27-
className="group flex items-center gap-3 rounded-lg border border-gray-300 bg-white px-4 py-3 text-gray-700 shadow-sm transition hover:bg-gray-100 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-300 dark:hover:bg-gray-700"
28-
>
29-
<ArrowLeft className="h-5 w-5 shrink-0 text-gray-500 transition group-hover:text-gray-700 dark:text-gray-400 dark:group-hover:text-gray-200" />
30-
<span className="truncate text-sm font-medium">{prev.title}</span>
24+
<Link href={prev.path} prefetch aria-label={`Previous: ${prev.title}`}>
25+
<Button
26+
variant="secondary"
27+
size="md"
28+
leftIcon={<ArrowLeft className="h-5 w-5 text-gray-500 dark:text-gray-400" />}
29+
className="group text-gray-700 dark:text-gray-300"
30+
>
31+
<span className="truncate">{prev.title}</span>
32+
</Button>
3133
</Link>
3234
) : (
3335
<div />
3436
)}
3537

3638
{next ? (
37-
<Link
38-
href={next.path}
39-
prefetch
40-
aria-label={`Next: ${next.title}`}
41-
className="group flex items-center gap-3 rounded-lg border border-gray-300 bg-white px-4 py-3 text-gray-700 shadow-sm transition hover:bg-gray-100 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-300 dark:hover:bg-gray-700"
42-
>
43-
<span className="truncate text-sm font-medium">{next.title}</span>
44-
<ArrowRight className="h-5 w-5 shrink-0 text-gray-500 transition group-hover:text-gray-700 dark:text-gray-400 dark:group-hover:text-gray-200" />
39+
<Link href={next.path} prefetch aria-label={`Next: ${next.title}`}>
40+
<Button
41+
variant="secondary"
42+
size="md"
43+
rightIcon={<ArrowRight className="h-5 w-5 text-gray-500 dark:text-gray-400" />}
44+
className="group text-gray-700 dark:text-gray-300"
45+
>
46+
<span className="truncate">{next.title}</span>
47+
</Button>
4548
</Link>
4649
) : (
4750
<div />

0 commit comments

Comments
 (0)