diff --git a/app/components/projects/list/project-card.tsx b/app/components/projects/list/project-card.tsx new file mode 100644 index 0000000..390a573 --- /dev/null +++ b/app/components/projects/list/project-card.tsx @@ -0,0 +1,47 @@ +import { memo } from 'react'; +import { Link } from 'react-router'; +import { Pencil } from 'lucide-react'; +import { Badge } from '~/components/ui/badge'; +import { Button } from '~/components/ui/button'; +import { Card } from '~/components/ui/card'; +import { LogoTile } from '~/components/ui/logo-tile'; +import { Text } from '~/components/ui/text'; +import { ROUTES } from '~/data/routes'; +import { formatDate } from '~/lib/format'; +import { toBrand } from '~/services/asset-media'; +import type { Project, ProjectSummary } from '~/types/project'; + +interface ProjectCardProps { + project: ProjectSummary; + onEdit: (project: Project) => void; +} + +export const ProjectCard = memo(function ProjectCard({ project, onEdit }: ProjectCardProps) { + return ( + + + {!project.logo && ( + + No logo · text fallback + + )} + +
+
+
+ + {project.name} + + {project.status === 'archived' && Archived} +
+ + {project.assetCount} {project.assetCount === 1 ? 'asset' : 'assets'} · {formatDate(project.created)} + +
+ +
+
+ ); +});