import Link from 'next/link'; import type { DocumentationPage } from 'contentlayer/generated'; import { If } from '@kit/ui/if'; import { cn } from '@kit/ui/utils'; export function DocumentationPageLink({ page, before, after, }: React.PropsWithChildren<{ page: DocumentationPage; before?: React.ReactNode; after?: React.ReactNode; }>) { return ( {(node) => <>{node}} {before ? `Previous` : ``} {after ? `Next` : ``} {page.title} {(node) => <>{node}} ); }