feat: polish web master-agent controls and dispatch recovery
This commit is contained in:
@@ -867,10 +867,12 @@ export function ChatComposer({
|
||||
projectId,
|
||||
initialPendingDispatchPlan,
|
||||
initialRejectedDispatchPlan,
|
||||
dispatchPlanRecoveryHint,
|
||||
}: {
|
||||
projectId: string;
|
||||
initialPendingDispatchPlan?: PendingDispatchPlanState | null;
|
||||
initialRejectedDispatchPlan?: PendingDispatchPlanState | null;
|
||||
dispatchPlanRecoveryHint?: string | null;
|
||||
}) {
|
||||
const router = useRouter();
|
||||
const [value, setValue] = useState("");
|
||||
@@ -1128,6 +1130,11 @@ export function ChatComposer({
|
||||
{message}
|
||||
</div>
|
||||
) : null}
|
||||
{dispatchPlanRecoveryHint ? (
|
||||
<div className="mt-3 rounded-2xl border border-[#E5E5EA] bg-[#F7F8FA] px-4 py-3 text-[12px] leading-6 text-[#57606A]">
|
||||
{dispatchPlanRecoveryHint}
|
||||
</div>
|
||||
) : null}
|
||||
{pendingDispatchPlan ? (
|
||||
<div className="mt-3 rounded-2xl border border-[#E5E5EA] bg-[#F7F8FA] px-4 py-4 text-[12px] leading-6 text-[#57606A]">
|
||||
<div className="text-[14px] font-semibold text-[#111111]">等待你确认主 Agent 推荐</div>
|
||||
@@ -1167,7 +1174,10 @@ export function ChatComposer({
|
||||
<div className="mt-3 rounded-2xl border border-[#F3D19C] bg-[#FFF7E6] px-4 py-4 text-[12px] leading-6 text-[#8D5D00]">
|
||||
<div className="text-[14px] font-semibold text-[#111111]">上次推荐已拒绝</div>
|
||||
<div className="mt-2 whitespace-pre-line">{summarizeDispatchPlan(rejectedDispatchPlan)}</div>
|
||||
<div className="mt-2">如果还想继续当前协作,可以直接重新生成推荐,不用把整条需求重新打一遍。</div>
|
||||
<div className="mt-2">
|
||||
{dispatchPlanRecoveryHint ??
|
||||
"如果还想继续当前协作,可以直接重新生成新的推荐,不用把整条需求重新打一遍。"}
|
||||
</div>
|
||||
<div className="mt-3 flex flex-wrap gap-2">
|
||||
<button
|
||||
type="button"
|
||||
@@ -1175,7 +1185,7 @@ export function ChatComposer({
|
||||
onClick={() => void retryDispatchPlan()}
|
||||
className="rounded-full bg-[#07C160] px-4 py-2 text-[13px] font-semibold text-white disabled:bg-[#B7E6C9]"
|
||||
>
|
||||
重新生成推荐
|
||||
重新生成新的推荐
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user