"use client"; import { useState } from "react"; import type { ImageAsset } from "@/lib/types"; import { getImageUrl } from "@/lib/api"; /** * 候选评估面板(Phase 1 占位) * * 对应 INFOLAYER.md 3.3.3 节:同轮生成的一组候选图的并排比较、 * 快速评分、标注差异、挑选定稿。 */ interface CandidatePanelProps { candidates: ImageAsset[]; onPick?: (id: string) => void; onClose?: () => void; } export function CandidatePanel({ candidates, onPick, onClose }: CandidatePanelProps) { const [ratings, setRatings] = useState>({}); const [notes, setNotes] = useState>({}); if (candidates.length === 0) return null; return (

候选评估

Phase 1 共 {candidates.length} 张
{candidates.map((c, i) => (
{c.url ? ( {`候选 ) : (
占位候选 {i + 1}
)}
#{i + 1}
{[1, 2, 3, 4, 5].map((n) => ( ))}
setNotes((prev) => ({ ...prev, [c.id]: e.target.value }))} placeholder="点评(占位)" className="w-full px-2 py-1 text-[11px] rounded-md bg-[var(--bg-primary)] border border-[var(--border)] focus:border-[var(--accent)]/40 outline-none" />
))}
自动差异对比(占位)
构图 / 配色 / 细节的自动化差分尚未接入(Phase 2)。用户可在此给出评分与点评, Agent 将根据选中项做后续迭代。
); }