feat(dashboard): data-driven workflow template rendering - #1
Open
Ericcccccc777 wants to merge 1 commit into
Open
feat(dashboard): data-driven workflow template rendering#1Ericcccccc777 wants to merge 1 commit into
Ericcccccc777 wants to merge 1 commit into
Conversation
The Workflow page no longer hardcodes the 9 full-stack stages. It now reads the project's active workflow template (written by CCC-MAGI) and renders its stages, title, and customizations. - shared/harness.ts: WorkflowSlot / WorkflowStage / WorkflowTemplateSelection / WorkflowTemplateFile / ActiveWorkflowTemplate types; HarnessSummary gains `workflow: ActiveWorkflowTemplate | null`. - main/HarnessReader.ts: resolveWorkflowTemplate() with a never-throwing fallback chain — customized selection → templates/<id>.json → full-stack → empty; path-guarded; surfaced on harnessSummary. - dashboard/WorkflowPage.tsx: renders the active template's stages (dynamic length), the template title + "customized" badge, and abstract-slot tags; falls back to the legacy 9 names when no template is present. - strings.ts: tplCustomized (en/zh; ko→en). Backward compatible: a project with no workflow-template.json / no .harness/workflows renders exactly as before (full-stack 9 stages). Verified: tsc clean, 445 tests pass, electron-vite build succeeds. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Makes the dashboard Workflow page render whatever workflow template the harness project is on, instead of the hardcoded 9 full-stack stages. Pairs with CCC-MAGI's new template system (CCC-MAGI PR #1).
shared/harness.ts—WorkflowSlot/WorkflowStage/WorkflowTemplateSelection/WorkflowTemplateFile/ActiveWorkflowTemplatetypes;HarnessSummarygainsworkflow: ActiveWorkflowTemplate | null.main/HarnessReader.ts—resolveWorkflowTemplate()with a never-throwing fallback chain: customized selection →templates/<id>.json→full-stack→ empty. Path-guarded; surfaced onharnessSummary.dashboard/WorkflowPage.tsx— renders the active template's stages (dynamic length), title + "customized" badge, and abstract-slot tags (VERIFY-GATE / HUMAN-REVIEW / WATCH). Falls back to the legacy 9 names when no template is present.strings.ts—tplCustomized(en/zh; ko→en).Backward compatible
A project with no
.harness/state/workflow-template.jsonand no.harness/workflows/renders exactly as before (full-stack, 9 stages).Verified
tsc --noEmitclean · 445 tests pass (29 files) ·electron-vite buildsucceeds.🤖 Generated with Claude Code