Files
www/src/app/components/note-entry.tsx
T
2025-09-16 17:42:55 -04:00

17 lines
426 B
TypeScript

'use client'
import Link from 'next/link';
import { toRelativeDate } from '../lib/date';
export function NoteEntry({ note }: { note: { title: string, mtime: string, slug: string } }) {
return (
<tr>
<td style={{ flex: '1 0 50%' }}>
<Link href={`/notes/${note.slug}`}>
{note.title}
</Link>
</td>
<td style={{ fontStyle: 'italic' }}>
{note.mtime && toRelativeDate(note.mtime)}
</td>
</tr>
);
}