FN-5882: fix mission interview draft resume handling

Keep mission interview drafts recoverable when closing and refreshing Missions.

- make MissionInterviewModal use a single non-destructive close path for header, Escape, and backdrop actions
- refresh mission interview draft/session rows on mission and ai-session SSE updates and reconnects
- open Plan New Mission as a fresh interview instead of always resuming the last session, with regression coverage and docs updates

Files changed:
 docs/missions.md                                   |   2 +-
 .../app/components/MissionInterviewModal.tsx       |  89 +++-----
 .../dashboard/app/components/MissionManager.tsx    | 156 ++++++++++----
 .../__tests__/MissionInterviewModal.test.tsx       | 100 ++++++++-
 .../components/__tests__/MissionManager.test.tsx   | 224 +++++++++++++++++++++
 5 files changed, 455 insertions(+), 116 deletions(-)

Fusion-Task-Id: FN-5882

Fusion-Task-Lineage: 75de9e94-edef-4564-a266-91782e60c2ac
This commit is contained in:
gsxdsm
2026-06-02 10:04:28 -07:00
parent 9e00a72d7d
commit cc5e61dbc4
5 changed files with 459 additions and 120 deletions

View File

@@ -159,7 +159,7 @@ The dashboard supports mission planning workflows where you can:
- Track progress at each layer
- Persisted missions with `interviewState: "in_progress"` remain visible as interview-styled mission cards in the main mission list so planning work does not disappear after reloads
- Resume in-progress mission interview sessions directly from separate transient session rows in the main missions list (`mission_interview` sessions in `generating`, `awaiting_input`, `error`, or `complete`) before a mission record is created; `complete` means the plan summary is ready for review/approval but has not been converted into a mission yet
- Banner-driven mission interview resumes are one-shot: if you close or send the interview to background, Missions re-fetches project-scoped `mission_interview` sessions and re-surfaces the transient row (including on the mobile stacked Missions view) so resume/retry remains discoverable without losing persisted `interviewState: "in_progress"` mission cards
- Mission interview closes are non-destructive: the modal now uses a single close action for header close, backdrop click, and Escape. Closing preserves the in-progress `mission_interview` session, and Missions re-fetches project-scoped transient rows (including on the mobile stacked Missions view) so resume/retry remains discoverable without losing persisted `interviewState: "in_progress"` mission cards. Deletion remains an explicit sidebar action.
- Mission interview, milestone interview, and slice interview agents have read-only board visibility via `fn_task_list` and `fn_task_get`, so they can reference active backlog context and avoid duplicating in-flight tasks while asking planning questions
### Mission Interview Drafts