import type { TguPlanDecision } from "../../model/tguTypes"; import type { TguPlanUi } from "../../model/timelineTypes"; import { platformLabel } from "./tguTimelineMapper"; import { statusStyle } from "./tguStatus"; type TguPlanDetailsProps = { plan?: TguPlanUi; decisionInFlight: boolean; notice?: string; error?: string; onDecision: (planId: string, decision: TguPlanDecision, reason?: string) => void; onClose: () => void; }; export function TguPlanDetails({ plan, decisionInFlight, notice, error, onDecision, onClose }: TguPlanDetailsProps) { if (!plan) { return ( ); } const style = statusStyle(plan.status); const duration = formatDuration(plan.endMs - plan.startMs); const reject = () => { const reason = window.prompt("Reason для REJECTED", "UI_TEST_REJECTED"); if (reason === null) return; onDecision(plan.planId, "REJECTED", reason); }; return ( ); } function Detail({ label, value, mono }: { label: string; value?: string; mono?: boolean }) { return (