feat(FN-2994): merge fusion/fn-2994
Commits merged: - fix(FN-2994): gate unavailable research workflow and humanize provider labels - fix(FN-2994): polish research view form and history interactions - feat(FN-2994): complete Step 5 — document research view architecture - fix(FN-2994): align status-dot variant and hook/test conventions - fix(FN-2994): address lint and typecheck issues - test(FN-2994): cover research lifecycle actions and pending status - fix(FN-2994): polish research actions and cited reader behavior - feat(FN-2994): complete Step 3 — add lifecycle actions and task flows - fix(FN-2994): ensure research enables header overflow gate - feat(FN-2994): complete Step 2 — implement research view shell layout - feat(FN-2994): complete Step 2 — gate research navigation and view - feat(FN-2994): complete Step 1 — add research api surface and hook Files changed: docs/architecture.md | 7 +- docs/dashboard-guide.md | 21 ++ packages/dashboard/app/App.tsx | 11 +- packages/dashboard/app/api/legacy.ts | 143 ++++----- packages/dashboard/app/components/Header.tsx | 29 +- packages/dashboard/app/components/MobileNavBar.tsx | 22 +- packages/dashboard/app/components/ResearchView.css | 247 +++++++++------ packages/dashboard/app/components/ResearchView.tsx | 347 ++++++++++++++------- .../app/components/__tests__/ResearchView.test.tsx | 183 ++++++----- .../app/hooks/__tests__/useResearch.test.ts | 66 ++++ packages/dashboard/app/hooks/useResearch.ts | 162 ++++++++++ packages/dashboard/app/research-types.ts | 43 +++ packages/dashboard/app/styles.css | 4 + .../src/__tests__/research-routes.test.ts | 65 ++++ packages/dashboard/src/research-routes.ts | 195 ++++++++++-- 15 files changed, 1111 insertions(+), 434 deletions(-) Fusion-Task-Id: FN-2994
This commit is contained in:
@@ -421,6 +421,7 @@ Key server capabilities:
|
||||
- Note: this **hyphenated `dev-server-*` family is the canonical runtime owner** today; see `docs/dev-server-module-boundary-audit.md` for the FN-2212 boundary/consolidation audit covering parallel `devserver-*` modules.
|
||||
- Plugin management routes (`plugin-routes.ts`)
|
||||
- Insights routes (`insights-routes.ts`)
|
||||
- Research routes (`research-routes.ts`) — `/api/research` surface for runs, details, cancel/retry, exports, create-task, and attach-task actions; supports graceful degradation envelopes via availability payloads when capabilities are unavailable
|
||||
- Roadmap routes (`roadmap-routes.ts`)
|
||||
- Project-scoped store reuse via `project-store-resolver.ts`
|
||||
- Rate limiting (`rate-limit.ts`)
|
||||
@@ -437,7 +438,7 @@ Key server capabilities:
|
||||
|
||||
### Real-time channels
|
||||
- **SSE**: `/api/events` (`sse.ts`)
|
||||
- Emits `task:*`, mission events, AI session updates, and automation schedule events (`schedule:created`, `schedule:updated`, `schedule:deleted`, `schedule:run`)
|
||||
- Emits `task:*`, mission events, AI session updates, automation schedule events (`schedule:created`, `schedule:updated`, `schedule:deleted`, `schedule:run`), and research run lifecycle events (`research:run:created`, `research:run:updated`, `research:run:completed`, `research:run:failed`, `research:run:cancelled`) when available
|
||||
- Project-scoped: resolves project context from query param or engine manager
|
||||
- **Chat streaming**: `/api/chat/sessions/:id/messages` (`routes.ts` + `chat.ts`)
|
||||
- Streams assistant responses as SSE events for chat sessions
|
||||
@@ -479,8 +480,8 @@ The dashboard's CSS is split between a consolidated global stylesheet and modula
|
||||
- Component-specific CSS rules live in the component's `.css` file, not in the root stylesheet
|
||||
|
||||
**Lazy-loaded views** (bundle size optimization):
|
||||
The following 14 views are lazy-loaded via `React.lazy()` with `<Suspense fallback={null}>`:
|
||||
- `AgentsView`, `RoadmapsView`, `TodoView`, `NodesView`, `ChatView`, `MemoryView`
|
||||
The following 15 views are lazy-loaded via `React.lazy()` with `<Suspense fallback={null}>`:
|
||||
- `AgentsView`, `RoadmapsView`, `TodoView`, `NodesView`, `ChatView`, `MemoryView`, `ResearchView`
|
||||
- `DevServerView`, `InsightsView`, `DocumentsView`, `SkillsView`
|
||||
- `SetupWizardModal`, `PluginManager`, `PiExtensionsManager`, `AgentDetailView
|
||||
|
||||
|
||||
@@ -105,6 +105,27 @@ Documents view supports toggling between raw text and formatted markdown when vi
|
||||
|
||||
The toggle button is accessible with `aria-pressed` for screen readers. Toggle state is scoped per-document, so switching between documents resets the view to raw mode.
|
||||
|
||||
## Research View
|
||||
|
||||
Research view is a standalone dashboard surface for creating and managing research runs.
|
||||
|
||||
> Available when `experimentalFeatures.researchView` is enabled.
|
||||
|
||||
Features:
|
||||
|
||||
- Create-run form with required query text and selectable provider options
|
||||
- Searchable run history list with project-scoped state
|
||||
- Selected-run reader with summary, citations, findings, and run event history
|
||||
- Run lifecycle controls: cancel, retry, and refresh
|
||||
- Export actions for supported formats (`markdown`, `json`, `html` as advertised by backend availability)
|
||||
- Task-facing actions to create a new task from findings or attach findings to an existing task
|
||||
- Graceful unavailable/setup messaging when research backend capability is disabled or not configured
|
||||
|
||||
Navigation:
|
||||
- Desktop: **Header → More views** overflow menu
|
||||
- Mobile: **More** sheet in `MobileNavBar`
|
||||
- Research is intentionally not shown in the primary board/list/agents/missions/chat toggle row
|
||||
|
||||
## Memory View
|
||||
|
||||
Memory view provides a multi-file editor for project and daily memory files.
|
||||
|
||||
Reference in New Issue
Block a user