Completes the three-panel layout
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
import type { AnyDocument } from "@/lib/types";
|
||||
import { Link } from "@tanstack/react-router";
|
||||
import type { AnyDocument, DocumentId } from "@/lib/types";
|
||||
import { DocumentLink } from "./DocumentLink";
|
||||
|
||||
export type Props = {
|
||||
doc: AnyDocument;
|
||||
title: string;
|
||||
description?: string;
|
||||
link: (id: DocumentId) => string;
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -13,13 +14,12 @@ export type Props = {
|
||||
export const BasicRow = ({ doc, title, description }: Props) => {
|
||||
return (
|
||||
<div>
|
||||
<Link
|
||||
to="/document/$documentId"
|
||||
params={{ documentId: doc.id }}
|
||||
<DocumentLink
|
||||
childDocId={doc.id}
|
||||
className="text-lg !no-underline text-slate-100 hover:underline hover:text-violet-400"
|
||||
>
|
||||
<h4>{title}</h4>
|
||||
</Link>
|
||||
</DocumentLink>
|
||||
{description && <p>{description}</p>}
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user