后端:Product Module(CRUD)、Requirement Module(CRUD + 状态机流转)、PrismaService 前端:产品列表页、产品详情页(含需求池 Tab)、Zustand Store、API 封装 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
17 lines
465 B
TypeScript
17 lines
465 B
TypeScript
'use client';
|
|
|
|
import { RequirementStatus } from '@ftb/shared';
|
|
import { REQUIREMENT_STATUS_LABEL, REQUIREMENT_STATUS_COLOR } from '@/lib/constants';
|
|
|
|
interface Props {
|
|
status: RequirementStatus;
|
|
}
|
|
|
|
export function RequirementStatusBadge({ status }: Props) {
|
|
return (
|
|
<span className={`inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium ${REQUIREMENT_STATUS_COLOR[status]}`}>
|
|
{REQUIREMENT_STATUS_LABEL[status]}
|
|
</span>
|
|
);
|
|
}
|