Create prompts for Figma Make projects (research → synthesis → save)
Generates optimized prompts for Figma Make through an interactive research workflow.
/plugin marketplace add arevlo/claude-code-workflows/plugin install arevlo-design@claude-code-workflowsCreate optimized prompts for Figma Make through an interactive research workflow.
This is a research/analysis workflow - you are NOT writing code. You are generating prompts that will be used by Figma Make (which uses Claude) to implement features.
This workflow is interactive. Use AskUserQuestion throughout:
Example follow-ups:
_make (for prompts)_clawd (for specs/references)make_projects_path in frontmatter (customize for your setup)If a prompt was recently created for this project (within current session), use AskUserQuestion with these options:
Question: "I see you recently created a prompt. What would you like to do?"
Options:
1. Modify the existing prompt - Edit or add to the prompt I just created
2. Create a new prompt - Start fresh with a different feature
3. Exit - I'm done for now
You MUST present this as an interactive picker, not just text.
THIS MUST BE THE FIRST QUESTION. Do NOT ask about entry type first.
Auto-detect from context:
feat-dashboard-ui → "Dashboard")Use AskUserQuestion immediately:
Question: "Which Make project is this for?"
Options:
1. [Project A] - (detected from branch or directory)
2. [Project B] - (detected from context)
3. Choose a different project - Let me pick from the list
Do NOT proceed until project is confirmed. Only after user selects, continue to Step 2.
Ask the user with a free-form prompt:
"Describe what you want to build. Include the problem you're solving, any constraints, files involved, and desired outcome."
Always ask: "Do you want to add Figma context? You can paste a component link for styling/layout reference."
Options:
If Figma link:
https://figma.com/design/.../node-id=123:456)mcp__figma-desktop__get_design_context with that nodeIdmcp__figma-desktop__get_variable_defs for design tokensIf screenshot:
Read tool to view the imageInclude in prompt:
Use the Task tool with subagent_type: Explore for deep codebase research:
Analyze the codebase for context on: {user's description}
Search for:
- Related components/patterns
- File structure and naming conventions
- Existing implementations to reference
- Files that will need modification
Return:
- File paths with line numbers for relevant code
- Current implementation details
- Design patterns used in the codebase
Benefits of Explore subagent:
IMPORTANT: The codebase may not reflect the latest state. Same-day prompts may have already been implemented in Figma Make but not yet downloaded/pushed to the repo.
Search _make with date filter for today's date and the selected project:
mcp__notion__notion-search with filters.created_date_range.start_date = todayIf same-day prompts exist that touch the same files you're modifying:
mcp__notion__notion-fetchExample "Current State" when sourced from recent prompt:
**Current State** (from today's prompt: [Prompt: Add Tab Pinning](notion-url)):
```tsx
// Code from that prompt's "Desired State" section
#### 5b. Search for specs and older prompts
1. **Search `_clawd`** for specs/context related to the project
2. **Search `_make`** for older prompts on the same project (for patterns/context)
**Present references with today's prompts recommended:**
Which related pages should I reference?
Today's prompts (recommended):
Older prompts: 3. [ ] Prompt: Prior Feature - (Dec 10) 4. [ ] Context: Spec Doc
- **Today's prompts go first** and should be pre-selected
- **Mark them "(Today - Recommended)"** so user knows they're current
- **Older prompts below** are available but not pre-selected
#### 5c. State resolution priority
When determining "Current State" for a file:
1. **Same-day prompts** (highest priority) - use their "Desired State"
2. **Codebase analysis** (fallback) - use actual code from repo
If using prompt-sourced state, always note this in the generated prompt so Figma Make knows the context source.
### Step 6: Choose Destination
Ask user where to save the prompt:
Where should I save this prompt?
Only show "Docs folder" option if `docs/` directory exists in current repo.
### Step 7: Generate Prompt
Use this template structure (proven to work with Figma Make):
```markdown
## Problem Statement
**{Bold one-liner describing what to build}** - {brief context}
**Reference Component**: `{path/to/main/Component.tsx}`
---
## Changes Overview
{Numbered list of ALL changes upfront}
1. {Change 1}
2. {Change 2}
3. {Change 3}
---
## 1. {First Change Title}
**Location**: `{file path}` (lines {X-Y})
**Current State**:
```tsx
{Actual code showing what exists now}
Desired State: {Description + ASCII diagram if UI-related}
┌────────────────────┐
│ Visual mockup │
│ using box drawing │
└────────────────────┘
Implementation:
{Ready-to-use code snippet}
Files to Modify:
path/to/File1.tsxpath/to/File2.tsx/* Include relevant tokens from Figma analysis or codebase */
--bg-primary: #value
--text-primary: #value
--spacing-lg: value
| Component | File Path | Line References |
|---|---|---|
| {Name} | {path} | {relevant lines} |
✅ {Specific check 1} ✅ {Specific check 2} ✅ All styling uses design system tokens ✅ Changes work responsively
### Pattern Library (use as needed):
**ASCII UI Mockups:**
┌──────────────────────┐ │ Header │ ├──────────────────────┤ │ Content area │ │ ⌘F to search │ ← Annotations └──────────────────────┘
**Before/After Comparisons:**
Before: ┌─────────────────────┐ │ Tab × │ Tab × │ │ └─────────────────────┘
After: ┌─────────────────────┐ │ 📌 Tab │ Tab × │ │ └─────────────────────┘
**Context Menu Mockups:**
┌──────────────────────┐ │ Action 1 │ │ Action 2 │ ├──────────────────────┤ │ Grouped Action │ └──────────────────────┘
**Theme Variants Block:**
Light Theme:
Dark Theme:
**Summary Table:**
| Feature | Behavior |
|---------|----------|
| Click | Opens in preview tab |
### Step 8: Save to Destination
**If Local /tmp:**
- Create directory `/tmp/make-prompts/` if it doesn't exist
- Save as: `prompt-{YYYY-MM-DD}-{HH-mm}-{slug}.md`
- Slugify the title (lowercase, hyphens, no special chars)
- Use Write tool
- Report full path to user
**If Notion:**
- Use `mcp__notion__notion-create-pages` to create page in `_make` database
- Set properties:
- Name: `Prompt: {title}`
- Project: {selected project}
- Tags: `["Prompt", "{project-type}"]`
- Add generated prompt as page content
- Report Notion URL to user
**If Docs folder:**
- Create `docs/prompts/` subdirectory if it doesn't exist
- Save as: `{YYYY-MM-DD}-{slug}.md`
- Use Write tool
- Report relative path to user
---
## Why This Structure Works
Figma Make uses Claude under the hood. This template:
1. **Problem Statement first** - Claude knows the goal immediately
2. **Changes Overview** - Full scope upfront prevents partial implementations
3. **Per-change sections** - Current → Desired → Implementation structure
4. **ASCII diagrams** - UI layout is unambiguous
5. **Line numbers** - Claude knows exactly where to look
6. **Current state code** - No guessing what exists
7. **Implementation snippets** - Ready-to-use code reduces errors
8. **Notion links** - Claude can fetch full specs via MCP
9. **Design tokens block** - No hardcoded values
10. **Success criteria** - Clear definition of "done"
11. **State resolution from prompts** - Same-day prompts take precedence over stale codebase since Figma Make implements changes before they're pushed to the repo