feat(figma): thread Figma through CLI and orchestrator (Phase D — T2F.8, T2F.9) - #1
Open
canonical-muhammadbassiony wants to merge 1 commit into
Open
Conversation
…uidance in prompts T2F.8: cmd/bauer --figma-url flag wired through CLIFlags and Config T2F.8: orchestrator.Execute forks on cfg.FigmaURL for figma-aware prompt generation T2F.8: generateChunksWithFigma fetches design, runs mapping.Resolver, writes artifacts T2F.9: figmaChunkContext.FigmaURL field enables MCP guidance block in template T2F.9: figma-context.md optional MCP section renders when FigmaURL is set T2F.9: Engine.RenderChunksFromResolved writes figma-aware prompt files to disk
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
Threads Figma integration through the CLI and orchestrator, completing Phase D of spec 002.
Tasks Implemented
--figma-urlflag tocmd/bauer/main.go, wired intoCLIFlags.FigmaURL. The orchestrator forks oncfg.FigmaURL != "": the figma-aware path callsgenerateChunksWithFigma()which fetches design data viasources.FetchFigma, runsmapping.Resolver.Build, persists figma artifacts (extraction, comments, mappings), and generates prompts viaengine.RenderChunksFromResolved.FigmaURLfield added tofigmaChunkContext(withjson:"-"),RenderChunkpasses it through, andfigma-context.mdhas a{{if .FigmaURL}}conditional section with instructions for AI agents that have MCP access.Files Changed
cmd/bauer/main.go—--figma-urlflag, wired throughFlagsSourceinternal/orchestrator/orchestrator.go—generateChunksWithFigma()method;Executeforks on FigmaURLinternal/prompt/engine.go—FigmaURLin context;RenderChunksFromResolved()methodinternal/prompt/templates/figma-context.md— MCP guidance block ({{if .FigmaURL}})How to Review
git diff feat/figma-phase-c-mapping..feat/figma-phase-d-cli -- .Part of the Bauer v2 stacked PR series (Branch 7 of 12).