🎉 init: 小龙的工作空间

This commit is contained in:
大海
2026-06-06 10:40:48 +08:00
commit a188ee1426
3201 changed files with 231817 additions and 0 deletions
@@ -0,0 +1,20 @@
import type { Note } from "@/types";
import { Card } from "@/components/ui/Card";
interface NoteCardProps {
note: Note;
onClick?: () => void;
}
export function NoteCard({ note, onClick }: NoteCardProps) {
return (
<Card onClick={onClick}>
<h3 className="font-medium text-gray-800 truncate">{note.title || "无标题"}</h3>
<p className="text-sm text-gray-500 mt-1 line-clamp-2">{note.content?.slice(0, 120) || "空笔记"}</p>
<div className="flex items-center gap-2 mt-2">
{note.isMarkdown && <span className="text-xs px-1.5 py-0.5 bg-purple-100 text-purple-600 rounded">MD</span>}
<span className="text-xs text-gray-400">{new Date(note.updatedAt).toLocaleDateString("zh-CN")}</span>
</div>
</Card>
);
}