agentleFS
renfei-designrenfei-design/Figma-AI-Bridge/.github/skills/figma-doc/SKILL.md

figma-doc

Skill16 starsChanged 9 months agoMITView on GitHub

Create structured documentation pages in Figma. Use when asked to create a doc, documentation page, spec, brief, write-up, or analysis page in Figma. Builds a complete documentation frame with title, sections, body text, and separators in a single plugin command.

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Read the user's topic, spec, or description.

    line 24
  2. Very specific:

    IMPORTANT — Never clone table widgets: If the source design contains Figma table widgets (WIDGET type), extract the data and use the table …

    line 70
  3. Distinctive:

    Use individual MCP tools to tweak:

    line 92
  4. Very specific:

    Use \n for line breaks within body text

    line 107
  5. Distinctive:

    Keep section bodies focused — one concept per section

    line 110
  6. Distinctive:

    Start with summary/overview, end with implications/next steps

    line 114

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Figma Documentation Page

Build a structured documentation page in Figma using a standard layout format. One command — generate content, call create_doc_page, done.

Prerequisites

  • figma-ai-bridge plugin running in Figma and connected
  • The create_doc_page command registered in code.js
  • Helper: scripts/figma_cmd.mjs <channel> create_doc_page '<paramsJSON>'

Workflow

1. Generate Content

Read the user's topic, spec, or description. Organize content into sections:

{
  "title": "Document Title",
  "width": 1600,
  "x": 0,
  "y": 0,
  "sections": [
    { "heading": "Section Title", "body": "Paragraph text..." },
    { "heading": "Comparison", "columns": [{"text": "Left col"}, {"text": "Right col"}] },
    { "heading": "Feature Matrix", "table": {
        "headers": ["Requirement", "Option A", "Option B"],
        "rows": [
          ["Goal-oriented workflows", "✅ Native", "❌ Not core"],
          ["Multi-step execution", "✅ First-class", "⚠️ Limited"]
        ]
      }
    }
  ]
}

Each section has ONE of these content types:

  • body — paragraph text with \n for line breaks
  • columns — array of {text} objects (for side-by-side comparison)
  • table — {headers: [...], rows: [[...], ...]} (for structured data, feature matrices)

Information Design Guidelines

Content typeBest formatExample
Narrative explanationbodyExecutive summary, background, recommendations
Pros/cons, either/orcolumns"Follow this" vs "Don't follow that"
Feature comparison matrixtableRequirements × options with ✅/❌
Structured criteria listtableDimensions with ratings or status
Side-by-side analysiscolumnsTwo approaches described in prose
Action items / bullet listsbodyNumbered steps, bullet points
Visual reference with descriptioncolumns + imageNodeIdComponent screenshot + explanation text

Cloning Visuals from Source

Columns and body sections support imageNodeId to clone an existing Figma node into the new doc:

  • columns[].imageNodeId — clone into that column (image above text)
  • section.imageNodeId — clone into the body section (image above text)

IMPORTANT — Never clone table widgets. If the source design contains Figma table widgets (WIDGET type), extract the data and use the table format instead.

2. Build in Figma (ONE call)

node scripts/figma_cmd.mjs <ch> create_doc_page '{
  "title": "...",
  "width": 1600,
  "sections": [
    {"heading": "Executive Summary", "body": "..."},
    {"heading": "Background", "body": "..."},
    {"heading": "Comparison", "columns": [{"text": "Left"}, {"text": "Right"}]}
  ]
}'

This single command builds the entire page: root frame, title, documentation container, all sections with headers/body, separators between sections.

Returns: { id, name, width, height, sectionCount, sections: [{id, heading, type}] }

3. Post-Creation Adjustments (optional)

Use individual MCP tools to tweak:

  • set_text_content to edit a specific text node
  • create_frame / create_text to add more content
  • move_node / resize_node for repositioning

Content Guidelines

Typical Section Patterns

  • Executive Summary — one paragraph framing the problem and approach
  • Overview / Background — context and setup
  • Analysis / Case Study — detailed breakdown
  • Design Implications — actionable takeaways with bold lead-in keywords
  • Comparison — side-by-side using columns

Text Formatting

  • Use \n for line breaks within body text
  • For bullet lists, use \n with bullet characters (•) or numbered prefixes
  • For bold sub-headings within body, put them on their own line
  • Keep section bodies focused — one concept per section

Section Count

  • Aim for 3–7 sections per document
  • Start with summary/overview, end with implications/next steps

What Gets Built

<title> (FRAME, white, cornerRadius:20, width:1600, VERTICAL auto-layout)
├── Title (TEXT, Inter Bold 40px, #424242)
└── Documentation (FRAME, cornerRadius:20, VERTICAL, spacing:64)
    ├── Section (FRAME, VERTICAL)
    │   ├── Header (TEXT, Inter Semibold 28px)
    │   └── Body (TEXT, Inter Regular 20px)
    ├── Separator (1px, #e0e0e0)
    ├── Section ...
    └── ...

Typography

ElementFontWeightSizeColor
TitleInterBold 70040#424242
Section headingInterSemibold 60028#424242
Body textInterRegular 40020#424242

Width Options

  • 1600 — standard documentation (default)
  • 2087 — wide format (specs with diagrams)

Notes

  • Avoid overlapping existing content — query get_canvas_bounds to find existing frames, then set x/y accordingly
  • Separators are auto-inserted between sections
  • The entire page builds in a single WebSocket roundtrip (~2-5 seconds)
  • Never clone Figma table widgets — always extract data and use the table format

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.