feat(projects): PR-PT-4 Approach stage SuspectedCause hierarchy#175
Merged
Conversation
Pure projectCauses() function maps each ImprovementProjectFactorControl to a CauseRow with resolved hypothesis, selected idea, linked actions (via ActionItem.ideaId), and derived causeStatus (pending-idea / in-progress / resolved / ruled-out). 9 tests covering all status branches. Co-Authored-By: ruflo <ruv@ruv.net>
Co-Authored-By: ruflo <ruv@ruv.net>
ApproachOverview (progress banner + goal/survey/milestone KPIs + cause cards + ruled-out collapse + Continue-in jump-outs) and ApproachSections (workbench layout) wired into IPDetailPage. Barrel re-exports CauseRow/CauseStatus/CauseProjectionInputs/projectCauses for app-level consumers. Co-Authored-By: ruflo <ruv@ruv.net>
…uffix) Co-Authored-By: ruflo <ruv@ruv.net>
…ngs stores Sources hypotheses from useInvestigationStore, ideas from questions[].ideas[], and actions from findings[].actions[] in both PWA and Azure. Passes approachInputs + onOpenCauseWorkbench through ProjectsTabView → IPDetailPage. V1 workbench handler jumps to Improve tab; IP-context scoping deferred to Plan 2. Co-Authored-By: ruflo <ruv@ruv.net>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Plan 1 PR-PT-4 of 5 — Approach stage of the IP detail page per spec D9 + §3.2.
Built in
@variscout/ui:projectCauses()pure function — per-SuspectedCause hierarchy projection (factorControl → Hypothesis → Idea → Action) with 9 testsApproachCauseCardprimitive — per-cause card with status pill (PENDING / IN PROGRESS / RESOLVED / RULED OUT), selected idea, action progress, "Open in Improve workbench" CTAApproachOverview— KPI strip (Goal/Survey/Milestone) + per-cause cards + ruled-out collapse + jump-outs (Wall / Analyze / Process)ApproachSections— same per-cause cards in workbench layout with "+ Add another suspected cause"IPDetailPageextended: Approach stage now conditionally renders Overview/Sections; barrel re-exportsCauseRow/CauseStatus/CauseProjectionInputs/projectCausesWired in apps:
ProjectsTabViewacceptsapproachInputs+onOpenCauseWorkbenchprops, forwards to IPDetailPageApp.tsx: sources hypotheses fromuseInvestigationStore; flattens ideas fromQuestion.ideas[]and actions fromFinding.actions[].onOpenCauseWorkbench→panels.showImprovement()(legacy PDCA workbench; Plan 2 adds IP-context scoping)Editor.tsxmirror viausePanelsStore.getState()Type discoveries (informed the implementation):
ImprovementIdea.text(notname);ActionItem.ideaId(notlinkedIdeaId);ActionItemStatus = 'open' | 'in-progress' | 'done'(notpending)ImprovementIdea.linkedHypothesisIddoes not exist on the type — projection iterates a flat ideas slice and picks theselected: trueone. Tight per-cause linking would need a schema follow-up (logged for Plan 2).@variscout/core/findings/types→@variscout/core/findings(correct sub-path)Test plan
pnpm --filter @variscout/ui test— IPDetail 31/31 across 8 filespnpm --filter @variscout/pwa test— 344 passedpnpm --filter @variscout/azure-app test— 1307 passed (pre-existing IndexedDB rejections unrelated)pnpm --filter @variscout/pwa tsc --noEmit— cleanpnpm --filter @variscout/azure-app tsc --noEmit— cleanSpec coverage (Plan 1 / PR-PT-4)
ImprovementIdeatype (V1 acceptable; logged for Plan 2)