[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-figma-figma-use":3,"mdc--6t1but-key":31,"related-org-figma-figma-use":7499,"related-repo-figma-figma-use":7662},{"slug":4,"name":4,"fn":5,"description":6,"org":7,"tags":11,"stars":20,"repoUrl":21,"updatedAt":22,"license":23,"forks":24,"topics":25,"repo":26,"sourceUrl":29,"mdContent":30},"figma-use","initialize Figma tool usage","**MANDATORY prerequisite** — you MUST invoke this skill BEFORE every `use_figma` tool call. NEVER call `use_figma` directly without loading this skill first. Skipping it causes common, hard-to-debug failures. Trigger whenever the user wants to perform a write action or a unique read action that requires JavaScript execution in the Figma file context — e.g. create\u002Fedit\u002Fdelete nodes, set up variables or tokens, build components and variants, modify auto-layout or fills, bind variables to properties, or inspect file structure programmatically.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},"figma","Figma","https:\u002F\u002Fpexgzepcugksgbtrxkhf.supabase.co\u002Fstorage\u002Fv1\u002Fobject\u002Fpublic\u002Forg-logos\u002Ffigma.png",[12,16,17],{"name":13,"slug":14,"type":15},"MCP","mcp","tag",{"name":9,"slug":8,"type":15},{"name":18,"slug":19,"type":15},"Design","design",1805,"https:\u002F\u002Fgithub.com\u002Ffigma\u002Fmcp-server-guide","2026-07-31T05:52:29.57808",null,164,[],{"repoUrl":21,"stars":20,"forks":24,"topics":27,"description":28},[],"A guide on how to use the Figma MCP server","https:\u002F\u002Fgithub.com\u002Ffigma\u002Fmcp-server-guide\u002Ftree\u002FHEAD\u002Fskills\u002Ffigma-use","---\nname: figma-use\ndescription: \"**MANDATORY prerequisite** — you MUST invoke this skill BEFORE every `use_figma` tool call. NEVER call `use_figma` directly without loading this skill first. Skipping it causes common, hard-to-debug failures. Trigger whenever the user wants to perform a write action or a unique read action that requires JavaScript execution in the Figma file context — e.g. create\u002Fedit\u002Fdelete nodes, set up variables or tokens, build components and variants, modify auto-layout or fills, bind variables to properties, or inspect file structure programmatically.\"\ndisable-model-invocation: false\n---\n\n# use_figma — Figma Plugin API Skill\n\nUse the `use_figma` tool to execute JavaScript in Figma files via the Plugin API. All detailed reference docs live in `references\u002F`.\n\n**Always include `figma-use` in the comma-separated `skillNames` parameter when calling `use_figma`. If this skill was loaded via an MCP resource, you MUST prefix the name with `resource:` (e.g. `resource:figma-use`).** This is a logging parameter used to track skill usage — it does not affect execution.\n\n**If Figma MCP tools appear as deferred tools, batch-load all their schemas in a single `ToolSearch` call** using the `select:` syntax — e.g. `ToolSearch query=\"select:use_figma,get_screenshot,get_metadata,create_new_file\"`. One round trip beats six.\n\n**If the task involves building or updating a full page, screen, or multi-section layout in Figma from code**, also load [figma-generate-design](..\u002Ffigma-generate-design\u002FSKILL.md). It provides the workflow for discovering design system components via `search_design_system`, importing them, and assembling screens incrementally. Both skills work together: this one for the API rules, that one for the screen-building workflow.\n\n**If the task involves creating or building a component in Figma** (even a single component), also load [figma-generate-library](..\u002Ffigma-generate-library\u002FSKILL.md). It provides the component creation workflow — variable foundations, variant sets, design token bindings — that `figma-use` alone doesn't cover.\n\nBefore anything, load [plugin-api-standalone.index.md](references\u002Fplugin-api-standalone.index.md) to understand what is possible. When you are asked to write plugin API code, use this context to grep [plugin-api-standalone.d.ts](references\u002Fplugin-api-standalone.d.ts) for relevant types, methods, and properties. This is the definitive source of truth for the API surface. It is a large typings file, so do not load it all at once, grep for relevant sections as needed.\n\nIMPORTANT: Whenever you work with design systems, start with [working-with-design-systems\u002Fwwds.md](references\u002Fworking-with-design-systems\u002Fwwds.md) to understand the key concepts, processes, and guidelines for working with design systems in Figma. Then load the more specific references for components, variables, text styles, and effect styles as needed.\n\n## 1. Critical Rules\n\n1.  **Use `return` to send data back.** The return value is JSON-serialized automatically (objects, arrays, strings, numbers). Do NOT call `figma.closePlugin()` or wrap code in an async IIFE — this is handled for you.\n2.  **Write plain JavaScript with top-level `await` and `return`.** Code is automatically wrapped in an async context. Do NOT wrap in `(async () => { ... })()`.\n3.  `figma.notify()` **throws \"not implemented\"** — never use it\n3a. **Prefer returned IDs and external state for workflow persistence.** Put human-readable component purpose and usage in the component's `description`. `getSharedPluginData(namespace, key)` and `setSharedPluginData(namespace, key, value)` should almost never be needed; if needed, you must use a stable namespace (at least 3 alphanumeric, `_`, or `.` characters).\n4.  `console.log()` is NOT returned — use `return` for output\n5.  **Work incrementally in small steps.** Break large operations into multiple `use_figma` calls. Validate after each step. This is the single most important practice for avoiding bugs.\n6.  Colors are **0–1 range** (not 0–255): `{r: 1, g: 0, b: 0}` = red\n7.  Fills\u002Fstrokes are **read-only arrays** — clone, modify, reassign\n8.  **Every text edit follows the canonical recipe: load font → `await` → mutate → return affected node IDs.** Skipping the load throws `Cannot write to node with unloaded font \"\u003Cfamily> \u003Cstyle>\"`. The rule covers more than `characters` — it applies to any operation on nodes with unloaded fonts (`appendChild`, `insertChild`, `setBoundVariable`, `setExplicitVariableModeForCollection`, `setValueForMode`, `findAll` callbacks touching text). When mutating existing text, load the node's *current* fonts via `getStyledTextSegments(['fontName'])`, not a hardcoded default. Inter is preloaded in most environments so other families surface this bug more often — the recipe is the same for every font. Use `await figma.listAvailableFontsAsync()` first if the style string is unverified. See [Canonical text-edit recipe](references\u002Fgotchas.md#canonical-text-edit-recipe-font-load--await--mutate--return-ids).\n9.  **Pages load incrementally** — use `await figma.setCurrentPageAsync(page)` to switch pages and load their content. The sync setter `figma.currentPage = page` does **NOT** work and will throw (see Page Rules below)\n10. `setBoundVariableForPaint` returns a **NEW** paint — must capture and reassign\n11. `createVariable` accepts collection **object or ID string** (object preferred)\n12. **`layoutSizingHorizontal\u002FVertical` is value-restricted by structural context — `FIXED` always works, `HUG` and `FILL` do not.** `'HUG'` is valid only on an auto-layout frame itself OR on a **TEXT** child of one. `'FILL'` is valid only on a child of an auto-layout frame that is also not absolute-positioned, not inside an immutable frame, and not a canvas-grid child. Practical consequence: append to an auto-layout parent FIRST, then set `HUG`\u002F`FILL` — a newly-created or unparented node can't satisfy the rule yet. The property itself exists on every `SceneNode`; the error is value-rejection, not \"no such property\". See [Gotchas](references\u002Fgotchas.md#layoutsizinghorizontallayoutsizingvertical-value-rules-fixed-hug-fill).\n12a. **Use auto-layout for containers that hold related children.** When children have a structural relationship — stacked, side-by-side, aligned, gapped, hugged — wrap them in `figma.createAutoLayout()`, not `figma.createFrame()` with absolute `x`\u002F`y`. Absolute coordinates govern where a container sits on the canvas; auto-layout governs how its children relate inside it. Skipping the container leaves no protection against text reflow, content changes, or overlap.\n12b. **`layoutSizing*` and `*AxisSizingMode` are different enums — don't cross them.** `layoutSizingHorizontal`\u002F`layoutSizingVertical` (set on a **child**) take `'FIXED'|'HUG'|'FILL'`; `primaryAxisSizingMode`\u002F`counterAxisSizingMode` (set on the **frame** itself) take `'FIXED'|'AUTO'`. So `layoutSizingVertical = 'AUTO'` is invalid (use `'HUG'`), and `counterAxisSizingMode = 'FILL'` throws `Expected 'FIXED' | 'AUTO', received 'FILL'` (use `'FIXED'`\u002F`'AUTO'`). Two more errors from the same setter — `Error: in set_layoutSizingHorizontal: node must be an auto-layout frame or a child of an auto-layout frame` and `Error: in set_layoutSizingHorizontal: FILL can only be set on children of auto-layout frames` — mean the node isn't in an auto-layout context yet; **recommendation: make the parent auto-layout (`figma.createAutoLayout()`) and `appendChild` the node before setting** (see Rule 12). See [Gotchas](references\u002Fgotchas.md#layoutsizing-vs-axissizingmode-two-different-sizing-enums).\n13. **Position new top-level nodes away from (0,0).** Nodes appended directly to the page default to (0,0). Scan `figma.currentPage.children` to find a clear position (e.g., to the right of the rightmost node). This only applies to page-level nodes — nodes nested inside other frames or auto-layout containers are positioned by their parent. See [Gotchas](references\u002Fgotchas.md).\n14. **On `use_figma` error, STOP. Do NOT immediately retry.** Failed scripts are **atomic** — if a script errors, it is not executed at all and no changes are made to the file. Read the error message carefully, fix the script, then retry. See [Error Recovery](#6-error-recovery--self-correction).\n15. **MUST `return` ALL created\u002Fmutated node IDs.** Whenever a script creates new nodes or mutates existing ones on the canvas, collect every affected node ID and return them in a structured object (e.g. `return { createdNodeIds: [...], mutatedNodeIds: [...] }`). This is essential for subsequent calls to reference, validate, or clean up those nodes.\n16. **Always set `variable.scopes` explicitly when creating variables.** The default `ALL_SCOPES` pollutes every property picker — almost never what you want. Use specific scopes like `[\"FRAME_FILL\", \"SHAPE_FILL\"]` for backgrounds, `[\"TEXT_FILL\"]` for text colors, `[\"GAP\"]` for spacing, etc. See [variable-patterns.md](references\u002Fvariable-patterns.md) for the full list.\n17. **`await` every Promise.** Never leave a Promise unawaited — unawaited async calls (e.g. `figma.loadFontAsync(...)` without `await`, or `figma.setCurrentPageAsync(page)` without `await`) will fire-and-forget, causing silent failures or race conditions. The script may return before the async operation completes, leading to missing data or half-applied changes.\n\n> For detailed WRONG\u002FCORRECT examples of each rule, see [Gotchas & Common Mistakes](references\u002Fgotchas.md).\n\n## 2. Page Rules (Critical)\n\n**Page context resets between `use_figma` calls** — `figma.currentPage` starts on the first page each time.\n\n### Switching pages\n\nUse `await figma.setCurrentPageAsync(page)` to switch pages and load their content. The sync setter `figma.currentPage = page` does **NOT work** — it throws `\"Setting figma.currentPage is not supported\"` in `use_figma`. Always use the async method.\n\n```js\n\u002F\u002F Switch to a specific page (loads its content)\nconst targetPage = figma.root.children.find((p) => p.name === \"My Page\");\nawait figma.setCurrentPageAsync(targetPage);\n\u002F\u002F targetPage.children is now populated\n```\n\n### Call `setCurrentPageAsync` at most once per `use_figma` invocation — fan multi-page work out in parallel\n\n**One script must switch pages at most once.** Never loop over `figma.root.children` and switch pages inside the loop.\n\nIf the work spans multiple pages, **split it into N `use_figma` calls (one per target page) and emit them in parallel** — a single assistant message containing N `use_figma` tool-use blocks. The harness runs them concurrently; each script sets `currentPage` exactly once.\n\n> **Explicit instruction:** when fanning out, you MUST issue the N tool calls in **one message**. Do not send them across multiple turns. Do not await one before issuing the next. Sequential per-page calls are slower than the in-loop pattern this rule replaces and waste the entire benefit of splitting.\n\n```js\n\u002F\u002F AVOID — switches pages N times in one script, reloads the file each time\nfor (const page of figma.root.children) {\n  await figma.setCurrentPageAsync(page);\n  \u002F\u002F ... touch this page ...\n}\n\n\u002F\u002F PREFER — read-only discovery call to get page IDs, then in the NEXT message\n\u002F\u002F emit N parallel use_figma tool calls (one per page), each setting currentPage once.\n```\n\nDefault to parallel fan-out for any multi-page work — reads and writes alike. See [gotchas.md → Set current page once per `use_figma` call](references\u002Fgotchas.md#set-current-page-once-per-use_figma-call--split-multi-page-work-into-parallel-calls) for the full rationale.\n\n### Across script runs\n\n`figma.currentPage` resets to the **first page** at the start of each `use_figma` call. If your workflow spans multiple calls and targets a non-default page, call `await figma.setCurrentPageAsync(page)` at the start of each invocation.\n\nYou can call `use_figma` multiple times to incrementally build on the file state, or to retrieve information before writing another script. For example, write a script to get metadata about existing nodes, `return` that data, then use it in a subsequent script to modify those nodes.\n\n## 3. `return` Is Your Output Channel\n\nThe agent sees **ONLY** the value you `return`. Everything else is invisible.\n\n- **Returning IDs (CRITICAL)**: Every script that creates or mutates canvas nodes **MUST** return all affected node IDs — e.g. `return { createdNodeIds: [...], mutatedNodeIds: [...] }`. This is a hard requirement, not optional.\n- **Progress reporting**: `return { createdNodeIds: [...], count: 5, errors: [] }`\n- **Error info**: Thrown errors are automatically captured and returned — just let them propagate or `throw` explicitly.\n- `console.log()` output is **never** returned to the agent\n- Always return actionable data (IDs, counts, status) so subsequent calls can reference created objects\n\n## 4. Editor Mode\n\n`use_figma` works in **design mode** (editorType `\"figma\"`, the default). FigJam (`\"figjam\"`) and Slides (`\"slides\"`) have different sets of available node types — most design nodes are blocked in FigJam, and FigJam-only nodes are blocked in Slides.\n\n**Tell the editor from the URL:** Design = `figma.com\u002Fdesign\u002F...`, FigJam = `figma.com\u002Fboard\u002F...`, Slides = `figma.com\u002Fslides\u002F...`. Confirm before assuming an API is available.\n\nAvailable in design mode: Rectangle, Frame, Component, Text, Ellipse, Star, Line, Vector, Polygon, BooleanOperation, Slice, Page, Section, TextPath.\n\n**Blocked** in design mode: Sticky, Connector, ShapeWithText, CodeBlock, Slide, SlideRow, SlideGrid, InteractiveSlideElement, Webpage.\n\nAvailable in Slides mode: Rectangle, Frame, Component, Text, Ellipse, Star, Line, Vector, Polygon, BooleanOperation, Slice, Section, TextPath, Slide, SlideRow, SlideGrid, InteractiveSlideElement.\n\n**Blocked** in Slides mode: Sticky, Connector, ShapeWithText, CodeBlock, Webpage, Page.\n\n**Design-only APIs (not just node types):** `figma.createPage()` is available only in Design files (`figma.com\u002Fdesign\u002F...`). In both FigJam (`figma.com\u002Fboard\u002F...`) and Slides (`figma.com\u002Fslides\u002F...`) it throws `TypeError: figma.createPage no such property 'createPage' on the figma global object`. Do not emit `figma.createPage()` in FigJam or Slides workflows.\n\n> **Slides note:** There is no dedicated read tool for Slides files yet. Use `use_figma` with read-only scripts for inspection (see Section 6 \"Inspect first\" pattern), and `get_screenshot` \u002F `await node.screenshot()` for visual context. For Slides-specific API guidance, load the [figma-use-slides](..\u002Ffigma-use-slides\u002FSKILL.md) skill.\n\n## 5. Efficient APIs — Prefer These Over Verbose Alternatives\n\nThese APIs reduce boilerplate, eliminate ordering errors, and compress token output. **Always prefer them over the verbose alternatives.**\n\n### `node.query(selector)` — CSS-like node search\n\nFind nodes within a subtree using CSS-like selectors. Replaces verbose `findAll` + filter loops.\n\n```js\n\u002F\u002F BEFORE — verbose traversal\nconst texts = frame.findAll(n => n.type === 'TEXT' && n.name === 'Title')\n\n\u002F\u002F AFTER — one-liner with query\nconst texts = frame.query('TEXT[name=Title]')\n```\n\n**Selector syntax:**\n- Type: `FRAME`, `TEXT`, `RECTANGLE`, `ELLIPSE`, `COMPONENT`, `INSTANCE`, `SECTION` (case-insensitive)\n- Attribute exact: `[name=Card]`, `[visible=true]`, `[opacity=0.5]`\n- Attribute substring: `[name*=art]` (contains), `[name^=Header]` (starts-with), `[name$=Nav]` (ends-with)\n- Dot-path traversal: `[fills.0.type=SOLID]`, `[fills.*.type=SOLID]` (wildcard index)\n- Instance matching: `[mainComponent=nodeId]`, `[mainComponent.name=Button]`\n- Combinators: `FRAME > TEXT` (direct child), `FRAME TEXT` (any descendant), `A + B` (adjacent sibling), `A ~ B` (general sibling)\n- Pseudo-classes: `:first-child`, `:last-child`, `:nth-child(2)`, `:not(TYPE)`, `:is(FRAME, RECTANGLE)`, `:where(TEXT, ELLIPSE)`\n- Node ID: `#nodeId` or bare GUID\n- Comma: `TEXT, RECTANGLE` (union)\n- Wildcard: `*` (any type)\n\n**QueryResult methods:**\n| Method | Description |\n|---|---|\n| `.length` | Number of matched nodes |\n| `.first()` | First matched node (or `null`) |\n| `.last()` | Last matched node (or `null`) |\n| `.toArray()` | Convert to regular array |\n| `.each(fn)` | Iterate with callback, returns `this` for chaining |\n| `.map(fn)` | Map to new array |\n| `.filter(fn)` | Filter to new QueryResult |\n| `.values(keys)` | Extract property values: `.values(['name', 'x', 'y'])` → `[{name, x, y}, ...]` |\n| `.set(props)` | Set properties on all matched nodes (see `node.set()` below) |\n| `.query(selector)` | Sub-query within matched nodes |\n| `for...of` | Iterable — works in `for` loops |\n\n**Scope:** `node.query()` searches within that node's subtree. To search the whole page: `figma.currentPage.query('...')`. There is no global `figma.query()`.\n\n**Examples:**\n```js\n\u002F\u002F Recolor all text inside cards\nfigma.currentPage.query('FRAME[name^=Card] TEXT').set({\n  fills: [{type: 'SOLID', color: {r: 0.2, g: 0.2, b: 0.8}}]\n})\n\n\u002F\u002F Get names and positions of all frames\nreturn figma.currentPage.query('FRAME').values(['name', 'x', 'y'])\n\n\u002F\u002F Find the first component named \"Button\"\nconst btn = figma.currentPage.query('COMPONENT[name=Button]').first()\n\n\u002F\u002F Find all instances of a specific component\nfigma.currentPage.query(`INSTANCE[mainComponent=${compId}]`)\n\n\u002F\u002F Find nodes with solid fills using dot-path traversal\nfigma.currentPage.query('[fills.0.type=SOLID]')\n```\n\n### `node.set(props)` — batch property updates\n\nSet multiple properties in one call. Returns `this` for chaining.\n\n```js\n\u002F\u002F BEFORE — one line per property\nframe.opacity = 0.5\nframe.cornerRadius = 8\nframe.name = \"Card\"\n\n\u002F\u002F AFTER — single call\nframe.set({ opacity: 0.5, cornerRadius: 8, name: \"Card\" })\n```\n\n**Priority key ordering:** `layoutMode` is always applied before other properties (like `width`\u002F`height`) regardless of object key order. This prevents the common bug where `resize()` behaves differently depending on whether `layoutMode` is set.\n\n**Width\u002Fheight handling:** `width` and `height` are routed through `node.resize()` automatically — setting `{ width: 200 }` calls `resize(200, currentHeight)`.\n\n**Chaining with query:**\n```js\n\u002F\u002F Find all rectangles named \"Divider\" and update them\nfigma.currentPage.query('RECTANGLE[name=Divider]').set({\n  fills: [{type: 'SOLID', color: {r: 0.9, g: 0.9, b: 0.9}}],\n  cornerRadius: 2\n})\n```\n\n### `figma.createAutoLayout(direction?, props?)` — auto-layout frames\n\nCreates a frame with auto-layout already enabled and both axes hugging content. **This is the default container whenever children have a structural relationship to each other (see Rule 12a).**\n\n```js\n\u002F\u002F BEFORE — manual setup, easy to get ordering wrong\nconst frame = figma.createFrame()\nframe.layoutMode = 'VERTICAL'\nframe.primaryAxisSizingMode = 'AUTO'\nframe.counterAxisSizingMode = 'AUTO'\nframe.layoutSizingHorizontal = 'HUG'\nframe.layoutSizingVertical = 'HUG'\n\n\u002F\u002F AFTER — one call, layout ready\nconst frame = figma.createAutoLayout('VERTICAL')\n```\n\nChildren can immediately use `layoutSizingHorizontal\u002FVertical = 'FILL'` after being appended — no need to set sizing modes manually.\n\nAccepts an optional props object as the first or second argument:\n```js\nfigma.createAutoLayout({ name: 'Card', itemSpacing: 12 })               \u002F\u002F HORIZONTAL + props\nfigma.createAutoLayout('VERTICAL', { name: 'Column', itemSpacing: 8 })  \u002F\u002F VERTICAL + props\n```\n\n### `node.placeholder` — shimmer overlay for AI-in-progress feedback\n\nSets a visual shimmer overlay on a node indicating work is in progress. **Always remove the shimmer when done** — leftover shimmers confuse users and indicate incomplete work.\n\n```js\n\u002F\u002F Mark as in-progress\nframe.placeholder = true\n\n\u002F\u002F ... build out the content ...\n\n\u002F\u002F MUST remove when done — never leave shimmers on finished nodes\nframe.placeholder = false\n```\n\nWhen building complex layouts, set `placeholder = true` on sections before populating them, then set `placeholder = false` on each section as it's completed.\n\n### `await node.screenshot(opts?)` — inline screenshots\n\nCapture a node as a PNG and return it inline in the response. Eliminates the need for a separate `get_screenshot` call.\n\n```js\n\u002F\u002F Take a screenshot of a frame (returned inline in the tool response)\nawait frame.screenshot()\n\n\u002F\u002F Custom scale (default auto-scales: 0.5x or capped so max dimension ≤ 1024px)\nawait frame.screenshot({ scale: 2 })\n\n\u002F\u002F Include overlapping content from sibling nodes\nawait frame.screenshot({ contentsOnly: false })\n```\n\n**When to use:** After creating or modifying nodes, call `screenshot()` to visually verify the result within the same script. No need for a separate `get_screenshot` call.\n\n**Auto-naming:** The image caption includes node metadata — `\"Card (300x150 at 0,60).png\"` — giving spatial context without parsing the image.\n\n**Default scaling:** Uses 0.5x scale, but automatically caps so the largest output dimension never exceeds 1024px. Explicit `{ scale: N }` bypasses the cap.\n\n## 6. Incremental Workflow (How to Avoid Bugs)\n\nThe most common cause of bugs is trying to do too much in a single `use_figma` call. **Work in small steps and validate after each one.**\n\n### Key rules\n\n- **At most 10 logical operations per `use_figma` call.** A \"logical operation\" is creating a node, setting its properties, and parenting it. If you need to create 20 nodes, split across 2-3 calls. **Slides override:** in Slides files, slides are isolated subtrees — the relevant limit is complexity per slide, not total nodes across slides. Building 3–5 new slides in one call is safe, and so is applying the same edit (e.g. adding a footer, recoloring a heading) across every slide in the deck in a single call. See [figma-use-slides](..\u002Ffigma-use-slides\u002FSKILL.md) for the deck-building workflow.\n- **Build top-down, starting with placeholders.** Create the outer structure first with `placeholder = true` on each section, then incrementally replace placeholders with real content in subsequent calls.\n\n### The pattern\n\n1. **Inspect first.** Before creating anything, run a read-only `use_figma` to discover what already exists in the file — pages, components, variables, naming conventions. Match what's there.\n2. **Build the skeleton.** Create the top-level structure with placeholder sections. Set `placeholder = true` on each section so the user sees progress.\n3. **Fill in sections incrementally.** In each subsequent call, populate one section and set its `placeholder = false` when done. Take a `screenshot()` to verify.\n4. **Return IDs from every call.** Always `return` created node IDs, variable IDs, collection IDs as objects (e.g. `return { createdNodeIds: [...] }`). You'll need these as inputs to subsequent calls.\n5. **Validate after each step.** Use `get_metadata` to verify structure (counts, names, hierarchy, positions). Use `await node.screenshot()` inline or `get_screenshot` after major milestones to catch visual issues.\n6. **Fix before moving on.** If validation reveals a problem, fix it before proceeding to the next step. Don't build on a broken foundation.\n\n### Suggested step order for complex tasks\n\n```\nStep 1: Inspect file — discover existing pages, components, variables, conventions\nStep 2: Create tokens\u002Fvariables (if needed)\n       → validate with get_metadata\nStep 3: Create individual components\n       → validate with get_metadata + get_screenshot\nStep 4: Compose layouts from component instances\n       → validate with get_screenshot\nStep 5: Final verification\n```\n\n### What to validate at each step\n\n| After... | Check with `get_metadata` | Check with `get_screenshot` |\n|---|---|---|\n| Creating variables | Collection count, variable count, mode names | — |\n| Creating components | Child count, variant names, property definitions | Variants visible, not collapsed, grid readable |\n| Binding variables | Node properties reflect bindings | Colors\u002Ftokens resolved correctly |\n| Composing layouts | Instance nodes have mainComponent, hierarchy correct | No cropped\u002Fclipped text, no overlapping elements, correct spacing |\n\n## 7. Error Recovery & Self-Correction\n\n**`use_figma` is atomic — failed scripts do not execute.** If a script errors, no changes are made to the file. The file remains in the same state as before the call. This means there are no partial nodes, no orphaned elements from the failed script, and retrying after a fix is safe.\n\n### When `use_figma` returns an error\n\n1. **STOP.** Do not immediately fix the code and retry.\n2. **Read the error message carefully.** Understand exactly what went wrong — wrong API usage, missing font, invalid property value, etc.\n3. **If the error is unclear**, call `get_metadata` or `get_screenshot` to understand the current file state.\n4. **Fix the script** based on the error message.\n5. **Retry** the corrected script.\n\n### Common self-correction patterns\n\n| Error message | Likely cause | How to fix |\n|---|---|---|\n| `\"not implemented\"` | Used `figma.notify()` | Remove it — use `return` for output |\n| `Error: in set_layoutSizingHorizontal: node must be an auto-layout frame or a child of an auto-layout frame` \u002F `Error: in set_layoutSizingHorizontal: FILL can only be set on children of auto-layout frames` \u002F `\"HUG can only be set on auto-layout frames or text children of auto-layout frames\"` \u002F `\"FILL cannot be set on absolute positioned auto-layout children\"` \u002F `\"FILL cannot be set on canvas grid children\"` | Tried to assign `HUG`\u002F`FILL` to a node whose structural context doesn't allow it (e.g. parent isn't auto-layout, ran before `appendChild`, non-text child trying to `HUG`, absolute-positioned child trying to `FILL`) | Make the parent auto-layout via `figma.createAutoLayout()`; `appendChild` first; reserve `HUG` for the auto-layout frame itself or for TEXT children; for absolute\u002Fimmutable\u002Fgrid children use `FIXED` + `resize()`. See [gotchas.md](references\u002Fgotchas.md#layoutsizinghorizontallayoutsizingvertical-value-rules-fixed-hug-fill) |\n| `\"Setting figma.currentPage is not supported\"` | Used sync page setter (`figma.currentPage = page`) which does NOT work | Use `await figma.setCurrentPageAsync(page)` — the only way to switch pages |\n| Property value out of range | Color channel > 1 (used 0–255 instead of 0–1) | Divide by 255 |\n| `\"Cannot read properties of null\"` | Node doesn't exist (wrong ID, wrong page) | Check page context, verify ID |\n| Script hangs \u002F no response | Infinite loop or unresolved promise | Check for `while(true)` or missing `await`; ensure code terminates |\n| `\"The node with id X does not exist\"` | Parent instance was implicitly detached by a child `detachInstance()`, changing IDs | Re-discover nodes by traversal from a stable (non-instance) parent frame |\n\n### When the script succeeds but the result looks wrong\n\n1. Call `get_metadata` to check structural correctness (hierarchy, counts, positions).\n2. Call `get_screenshot` to check visual correctness. Look closely for cropped\u002Fclipped text (line heights cutting off content) and overlapping elements — these are common and easy to miss.\n3. Identify the discrepancy — is it structural (wrong hierarchy, missing nodes) or visual (wrong colors, broken layout, clipped content)?\n4. Write a targeted fix script that modifies only the broken parts — don't recreate everything.\n\n> For the full validation workflow, see [Validation & Error Recovery](references\u002Fvalidation-and-recovery.md).\n\n## 8. Pre-Flight Checklist\n\nBefore submitting ANY `use_figma` call, verify:\n\n- [ ] Code uses `return` to send data back (NOT `figma.closePlugin()`)\n- [ ] Code is NOT wrapped in an async IIFE (auto-wrapped for you)\n- [ ] `return` value includes structured data with actionable info (IDs, counts)\n- [ ] NO usage of `figma.notify()` anywhere\n- [ ] NO usage of `console.log()` as output (use `return` instead)\n- [ ] All colors use 0–1 range (not 0–255)\n- [ ] Paint `color` objects use `{r, g, b}` only — no `a` field (opacity goes at the paint level: `{ type: 'SOLID', color: {...}, opacity: 0.5 }`)\n- [ ] Fills\u002Fstrokes are reassigned as new arrays (not mutated in place)\n- [ ] Page switches use `await figma.setCurrentPageAsync(page)` (sync setter `figma.currentPage = page` does NOT work)\n- [ ] `layoutSizingVertical\u002FHorizontal = 'FILL'` is set AFTER `parent.appendChild(child)`\n- [ ] Wrapping TEXT blocks set `textAutoResize = 'HEIGHT'` and an explicit width (`'FIXED'` + `resize()`) — NOT `FILL` alone, which the default `WIDTH_AND_HEIGHT` mode ignores, collapsing the node to a near-zero-width thread. Verify `node.width > 0`\n- [ ] Every text mutation follows the [canonical recipe](references\u002Fgotchas.md#canonical-text-edit-recipe-font-load--await--mutate--return-ids): `loadFontAsync` → `await` → mutate `characters`\u002Ffont\u002Fsize\u002Fetc. → return affected node IDs. Works for ANY font family\u002Fstyle, not just Inter (which only happens to be preloaded).\n- [ ] Style names have already been verified via `listAvailableFontsAsync()` — NOT guessed from memory (`\"SemiBold\"` vs `\"Semi Bold\"` is a common footgun)\n- [ ] For `FONT_FAMILY`-scoped variables: every value across every relevant mode is loaded before `setBoundVariable(\"fontFamily\", …)`, `setValueForMode`, or `setExplicitVariableModeForCollection`\n- [ ] `lineHeight`\u002F`letterSpacing` use `{unit, value}` format (not bare numbers)\n- [ ] `resize()` is called BEFORE setting sizing modes (resize resets them to FIXED)\n- [ ] For multi-step workflows: IDs from previous calls are passed as string literals (not variables)\n- [ ] New top-level nodes are positioned away from (0,0) to avoid overlapping existing content\n- [ ] Containers with structurally-related children use `figma.createAutoLayout()`, not absolute x\u002Fy (see Rule 12a)\n- [ ] ALL created\u002Fmutated node IDs are collected and included in the `return` value\n- [ ] Every async call (`loadFontAsync`, `setCurrentPageAsync`, `importComponentByKeyAsync`, etc.) is `await`ed — no fire-and-forget Promises\n\n## 9. Discover Conventions Before Creating\n\n**Always inspect the Figma file before creating anything.** Different files use different naming conventions, variable structures, and component patterns. Your code should match what's already there, not impose new conventions.\n\nWhen in doubt about any convention (naming, scoping, structure), check the Figma file first, then the user's codebase. Only fall back to common patterns when neither exists.\n\n### Quick inspection scripts\n\n**List all pages and top-level nodes:**\n```js\nconst pages = figma.root.children.map(p => `${p.name} id=${p.id} children=${p.children.length}`);\nreturn pages.join('\\n');\n```\n\n**List existing components across all pages:**\n\n`search_design_system` is an option for published components. For on-canvas components, use the two-step fan-out — **don't loop pages inside one script.**\n\nStep 1: one read-only `use_figma` to get page IDs:\n```js\nreturn figma.root.children.map(p => ({ id: p.id, name: p.name }));\n```\n\nStep 2: in the **next assistant turn, emit one `use_figma` per page in parallel** (a single message containing N tool-use blocks). Each runs:\n```js\nconst page = await figma.getNodeByIdAsync(PAGE_ID);\nawait figma.setCurrentPageAsync(page);\n\u002F\u002F findAllWithCriteria uses an indexed type lookup — hundreds of times faster\n\u002F\u002F than the findAll(n => n.type === '…') side-effect-in-predicate antipattern.\nconst matches = page.findAllWithCriteria({ types: ['COMPONENT', 'COMPONENT_SET'] });\nreturn matches.map(n => ({ page: page.name, name: n.name, type: n.type, id: n.id }));\n```\n\n**List existing variable collections and their conventions:**\n```js\nconst collections = await figma.variables.getLocalVariableCollectionsAsync();\nconst results = collections.map(c => ({\n  name: c.name, id: c.id,\n  varCount: c.variableIds.length,\n  modes: c.modes.map(m => m.name)\n}));\nreturn results;\n```\n\n## 10. Reference Docs\n\nLoad these as needed based on what your task involves:\n\n| Doc | When to load | What it covers |\n|-----|-------------|----------------|\n| [gotchas.md](references\u002Fgotchas.md) | Before any `use_figma` | Every known pitfall with WRONG\u002FCORRECT code examples — start with the [canonical text-edit recipe](references\u002Fgotchas.md#canonical-text-edit-recipe-font-load--await--mutate--return-ids) |\n| [common-patterns.md](references\u002Fcommon-patterns.md) | Need working code examples | Script scaffolds: shapes, text, auto-layout, variables, components, multi-step workflows |\n| [plugin-api-patterns.md](references\u002Fplugin-api-patterns.md) | Creating\u002Fediting nodes | Fills, strokes, Auto Layout, effects, grouping, cloning, styles |\n| [api-reference.md](references\u002Fapi-reference.md) | Need exact API surface | Node creation, variables API, core properties, what works and what doesn't |\n| [validation-and-recovery.md](references\u002Fvalidation-and-recovery.md) | Multi-step writes or error recovery | `get_metadata` vs `get_screenshot` workflow, mandatory error recovery steps |\n| [component-patterns.md](references\u002Fcomponent-patterns.md) | Creating components\u002Fvariants | combineAsVariants, component properties, INSTANCE_SWAP, variant layout, discovering existing components, metadata traversal |\n| [variable-patterns.md](references\u002Fvariable-patterns.md) | Creating\u002Fbinding variables | Collections, modes, scopes, aliasing, binding patterns, discovering existing variables |\n| [text-style-patterns.md](references\u002Ftext-style-patterns.md) | Creating\u002Fapplying text styles | Type ramps, font discovery via `listAvailableFontsAsync`, listing styles, applying styles to nodes |\n| [effect-style-patterns.md](references\u002Feffect-style-patterns.md) | Creating\u002Fapplying effect styles | Drop shadows, listing styles, applying styles to nodes |\n| [plugin-api-standalone.index.md](references\u002Fplugin-api-standalone.index.md) | Need to understand the full API surface | Index of all types, methods, and properties in the Plugin API |\n| [plugin-api-standalone.d.ts](references\u002Fplugin-api-standalone.d.ts) | Need exact type signatures | Full typings file — grep for specific symbols, don't load all at once |\n\n## 11. Snippet examples\n\nYou will see snippets throughout documentation here. These snippets contain useful plugin API code that can be repurposed. Use them as is, or as starter code as you go. If there are key concepts that are best documented as generic snippets, call them out and write to disk so you can reuse in the future.\n",{"data":32,"body":34},{"name":4,"description":6,"disable-model-invocation":33},false,{"type":35,"children":36},"root",[37,46,69,118,152,179,204,225,238,245,1091,1106,1112,1137,1144,1182,1367,1387,1405,1439,1459,1610,1629,1635,1666,1685,1698,1717,1801,1807,1848,1882,1887,1897,1902,1911,1963,2007,2013,2023,2035,2047,2239,2247,2518,2526,2791,2823,2831,3400,3412,3424,3626,3673,3718,3726,3942,3954,3964,4238,4251,4256,4428,4440,4452,4547,4568,4580,4592,4759,4783,4801,4819,4825,4842,4848,4897,4903,5031,5037,5047,5053,5161,5167,5182,5195,5262,5268,5585,5591,5626,5641,5647,5659,6140,6146,6156,6161,6167,6175,6375,6383,6398,6410,6530,6549,6885,6893,7182,7188,7193,7482,7488,7493],{"type":38,"tag":39,"props":40,"children":42},"element","h1",{"id":41},"use_figma-figma-plugin-api-skill",[43],{"type":44,"value":45},"text","use_figma — Figma Plugin API Skill",{"type":38,"tag":47,"props":48,"children":49},"p",{},[50,52,59,61,67],{"type":44,"value":51},"Use the ",{"type":38,"tag":53,"props":54,"children":56},"code",{"className":55},[],[57],{"type":44,"value":58},"use_figma",{"type":44,"value":60}," tool to execute JavaScript in Figma files via the Plugin API. All detailed reference docs live in ",{"type":38,"tag":53,"props":62,"children":64},{"className":63},[],[65],{"type":44,"value":66},"references\u002F",{"type":44,"value":68},".",{"type":38,"tag":47,"props":70,"children":71},{},[72,116],{"type":38,"tag":73,"props":74,"children":75},"strong",{},[76,78,83,85,91,93,98,100,106,108,114],{"type":44,"value":77},"Always include ",{"type":38,"tag":53,"props":79,"children":81},{"className":80},[],[82],{"type":44,"value":4},{"type":44,"value":84}," in the comma-separated ",{"type":38,"tag":53,"props":86,"children":88},{"className":87},[],[89],{"type":44,"value":90},"skillNames",{"type":44,"value":92}," parameter when calling ",{"type":38,"tag":53,"props":94,"children":96},{"className":95},[],[97],{"type":44,"value":58},{"type":44,"value":99},". If this skill was loaded via an MCP resource, you MUST prefix the name with ",{"type":38,"tag":53,"props":101,"children":103},{"className":102},[],[104],{"type":44,"value":105},"resource:",{"type":44,"value":107}," (e.g. ",{"type":38,"tag":53,"props":109,"children":111},{"className":110},[],[112],{"type":44,"value":113},"resource:figma-use",{"type":44,"value":115},").",{"type":44,"value":117}," This is a logging parameter used to track skill usage — it does not affect execution.",{"type":38,"tag":47,"props":119,"children":120},{},[121,134,136,142,144,150],{"type":38,"tag":73,"props":122,"children":123},{},[124,126,132],{"type":44,"value":125},"If Figma MCP tools appear as deferred tools, batch-load all their schemas in a single ",{"type":38,"tag":53,"props":127,"children":129},{"className":128},[],[130],{"type":44,"value":131},"ToolSearch",{"type":44,"value":133}," call",{"type":44,"value":135}," using the ",{"type":38,"tag":53,"props":137,"children":139},{"className":138},[],[140],{"type":44,"value":141},"select:",{"type":44,"value":143}," syntax — e.g. ",{"type":38,"tag":53,"props":145,"children":147},{"className":146},[],[148],{"type":44,"value":149},"ToolSearch query=\"select:use_figma,get_screenshot,get_metadata,create_new_file\"",{"type":44,"value":151},". One round trip beats six.",{"type":38,"tag":47,"props":153,"children":154},{},[155,160,162,169,171,177],{"type":38,"tag":73,"props":156,"children":157},{},[158],{"type":44,"value":159},"If the task involves building or updating a full page, screen, or multi-section layout in Figma from code",{"type":44,"value":161},", also load ",{"type":38,"tag":163,"props":164,"children":166},"a",{"href":165},"..\u002Ffigma-generate-design\u002FSKILL.md",[167],{"type":44,"value":168},"figma-generate-design",{"type":44,"value":170},". It provides the workflow for discovering design system components via ",{"type":38,"tag":53,"props":172,"children":174},{"className":173},[],[175],{"type":44,"value":176},"search_design_system",{"type":44,"value":178},", importing them, and assembling screens incrementally. Both skills work together: this one for the API rules, that one for the screen-building workflow.",{"type":38,"tag":47,"props":180,"children":181},{},[182,187,189,195,197,202],{"type":38,"tag":73,"props":183,"children":184},{},[185],{"type":44,"value":186},"If the task involves creating or building a component in Figma",{"type":44,"value":188}," (even a single component), also load ",{"type":38,"tag":163,"props":190,"children":192},{"href":191},"..\u002Ffigma-generate-library\u002FSKILL.md",[193],{"type":44,"value":194},"figma-generate-library",{"type":44,"value":196},". It provides the component creation workflow — variable foundations, variant sets, design token bindings — that ",{"type":38,"tag":53,"props":198,"children":200},{"className":199},[],[201],{"type":44,"value":4},{"type":44,"value":203}," alone doesn't cover.",{"type":38,"tag":47,"props":205,"children":206},{},[207,209,215,217,223],{"type":44,"value":208},"Before anything, load ",{"type":38,"tag":163,"props":210,"children":212},{"href":211},"references\u002Fplugin-api-standalone.index.md",[213],{"type":44,"value":214},"plugin-api-standalone.index.md",{"type":44,"value":216}," to understand what is possible. When you are asked to write plugin API code, use this context to grep ",{"type":38,"tag":163,"props":218,"children":220},{"href":219},"references\u002Fplugin-api-standalone.d.ts",[221],{"type":44,"value":222},"plugin-api-standalone.d.ts",{"type":44,"value":224}," for relevant types, methods, and properties. This is the definitive source of truth for the API surface. It is a large typings file, so do not load it all at once, grep for relevant sections as needed.",{"type":38,"tag":47,"props":226,"children":227},{},[228,230,236],{"type":44,"value":229},"IMPORTANT: Whenever you work with design systems, start with ",{"type":38,"tag":163,"props":231,"children":233},{"href":232},"references\u002Fworking-with-design-systems\u002Fwwds.md",[234],{"type":44,"value":235},"working-with-design-systems\u002Fwwds.md",{"type":44,"value":237}," to understand the key concepts, processes, and guidelines for working with design systems in Figma. Then load the more specific references for components, variables, text styles, and effect styles as needed.",{"type":38,"tag":239,"props":240,"children":242},"h2",{"id":241},"_1-critical-rules",[243],{"type":44,"value":244},"1. Critical Rules",{"type":38,"tag":246,"props":247,"children":248},"ol",{},[249,276,307,370,388,405,425,437,545,578,596,614,910,934,965,990,1048],{"type":38,"tag":250,"props":251,"children":252},"li",{},[253,266,268,274],{"type":38,"tag":73,"props":254,"children":255},{},[256,258,264],{"type":44,"value":257},"Use ",{"type":38,"tag":53,"props":259,"children":261},{"className":260},[],[262],{"type":44,"value":263},"return",{"type":44,"value":265}," to send data back.",{"type":44,"value":267}," The return value is JSON-serialized automatically (objects, arrays, strings, numbers). Do NOT call ",{"type":38,"tag":53,"props":269,"children":271},{"className":270},[],[272],{"type":44,"value":273},"figma.closePlugin()",{"type":44,"value":275}," or wrap code in an async IIFE — this is handled for you.",{"type":38,"tag":250,"props":277,"children":278},{},[279,298,300,306],{"type":38,"tag":73,"props":280,"children":281},{},[282,284,290,292,297],{"type":44,"value":283},"Write plain JavaScript with top-level ",{"type":38,"tag":53,"props":285,"children":287},{"className":286},[],[288],{"type":44,"value":289},"await",{"type":44,"value":291}," and ",{"type":38,"tag":53,"props":293,"children":295},{"className":294},[],[296],{"type":44,"value":263},{"type":44,"value":68},{"type":44,"value":299}," Code is automatically wrapped in an async context. Do NOT wrap in ",{"type":38,"tag":53,"props":301,"children":303},{"className":302},[],[304],{"type":44,"value":305},"(async () => { ... })()",{"type":44,"value":68},{"type":38,"tag":250,"props":308,"children":309},{},[310,316,318,323,325,330,332,338,340,346,347,353,355,361,363,368],{"type":38,"tag":53,"props":311,"children":313},{"className":312},[],[314],{"type":44,"value":315},"figma.notify()",{"type":44,"value":317}," ",{"type":38,"tag":73,"props":319,"children":320},{},[321],{"type":44,"value":322},"throws \"not implemented\"",{"type":44,"value":324}," — never use it\n3a. ",{"type":38,"tag":73,"props":326,"children":327},{},[328],{"type":44,"value":329},"Prefer returned IDs and external state for workflow persistence.",{"type":44,"value":331}," Put human-readable component purpose and usage in the component's ",{"type":38,"tag":53,"props":333,"children":335},{"className":334},[],[336],{"type":44,"value":337},"description",{"type":44,"value":339},". ",{"type":38,"tag":53,"props":341,"children":343},{"className":342},[],[344],{"type":44,"value":345},"getSharedPluginData(namespace, key)",{"type":44,"value":291},{"type":38,"tag":53,"props":348,"children":350},{"className":349},[],[351],{"type":44,"value":352},"setSharedPluginData(namespace, key, value)",{"type":44,"value":354}," should almost never be needed; if needed, you must use a stable namespace (at least 3 alphanumeric, ",{"type":38,"tag":53,"props":356,"children":358},{"className":357},[],[359],{"type":44,"value":360},"_",{"type":44,"value":362},", or ",{"type":38,"tag":53,"props":364,"children":366},{"className":365},[],[367],{"type":44,"value":68},{"type":44,"value":369}," characters).",{"type":38,"tag":250,"props":371,"children":372},{},[373,379,381,386],{"type":38,"tag":53,"props":374,"children":376},{"className":375},[],[377],{"type":44,"value":378},"console.log()",{"type":44,"value":380}," is NOT returned — use ",{"type":38,"tag":53,"props":382,"children":384},{"className":383},[],[385],{"type":44,"value":263},{"type":44,"value":387}," for output",{"type":38,"tag":250,"props":389,"children":390},{},[391,396,398,403],{"type":38,"tag":73,"props":392,"children":393},{},[394],{"type":44,"value":395},"Work incrementally in small steps.",{"type":44,"value":397}," Break large operations into multiple ",{"type":38,"tag":53,"props":399,"children":401},{"className":400},[],[402],{"type":44,"value":58},{"type":44,"value":404}," calls. Validate after each step. This is the single most important practice for avoiding bugs.",{"type":38,"tag":250,"props":406,"children":407},{},[408,410,415,417,423],{"type":44,"value":409},"Colors are ",{"type":38,"tag":73,"props":411,"children":412},{},[413],{"type":44,"value":414},"0–1 range",{"type":44,"value":416}," (not 0–255): ",{"type":38,"tag":53,"props":418,"children":420},{"className":419},[],[421],{"type":44,"value":422},"{r: 1, g: 0, b: 0}",{"type":44,"value":424}," = red",{"type":38,"tag":250,"props":426,"children":427},{},[428,430,435],{"type":44,"value":429},"Fills\u002Fstrokes are ",{"type":38,"tag":73,"props":431,"children":432},{},[433],{"type":44,"value":434},"read-only arrays",{"type":44,"value":436}," — clone, modify, reassign",{"type":38,"tag":250,"props":438,"children":439},{},[440,452,454,460,462,468,470,476,478,484,485,491,492,498,499,505,506,512,514,520,522,528,530,536,538,544],{"type":38,"tag":73,"props":441,"children":442},{},[443,445,450],{"type":44,"value":444},"Every text edit follows the canonical recipe: load font → ",{"type":38,"tag":53,"props":446,"children":448},{"className":447},[],[449],{"type":44,"value":289},{"type":44,"value":451}," → mutate → return affected node IDs.",{"type":44,"value":453}," Skipping the load throws ",{"type":38,"tag":53,"props":455,"children":457},{"className":456},[],[458],{"type":44,"value":459},"Cannot write to node with unloaded font \"\u003Cfamily> \u003Cstyle>\"",{"type":44,"value":461},". The rule covers more than ",{"type":38,"tag":53,"props":463,"children":465},{"className":464},[],[466],{"type":44,"value":467},"characters",{"type":44,"value":469}," — it applies to any operation on nodes with unloaded fonts (",{"type":38,"tag":53,"props":471,"children":473},{"className":472},[],[474],{"type":44,"value":475},"appendChild",{"type":44,"value":477},", ",{"type":38,"tag":53,"props":479,"children":481},{"className":480},[],[482],{"type":44,"value":483},"insertChild",{"type":44,"value":477},{"type":38,"tag":53,"props":486,"children":488},{"className":487},[],[489],{"type":44,"value":490},"setBoundVariable",{"type":44,"value":477},{"type":38,"tag":53,"props":493,"children":495},{"className":494},[],[496],{"type":44,"value":497},"setExplicitVariableModeForCollection",{"type":44,"value":477},{"type":38,"tag":53,"props":500,"children":502},{"className":501},[],[503],{"type":44,"value":504},"setValueForMode",{"type":44,"value":477},{"type":38,"tag":53,"props":507,"children":509},{"className":508},[],[510],{"type":44,"value":511},"findAll",{"type":44,"value":513}," callbacks touching text). When mutating existing text, load the node's ",{"type":38,"tag":515,"props":516,"children":517},"em",{},[518],{"type":44,"value":519},"current",{"type":44,"value":521}," fonts via ",{"type":38,"tag":53,"props":523,"children":525},{"className":524},[],[526],{"type":44,"value":527},"getStyledTextSegments(['fontName'])",{"type":44,"value":529},", not a hardcoded default. Inter is preloaded in most environments so other families surface this bug more often — the recipe is the same for every font. Use ",{"type":38,"tag":53,"props":531,"children":533},{"className":532},[],[534],{"type":44,"value":535},"await figma.listAvailableFontsAsync()",{"type":44,"value":537}," first if the style string is unverified. See ",{"type":38,"tag":163,"props":539,"children":541},{"href":540},"references\u002Fgotchas.md#canonical-text-edit-recipe-font-load--await--mutate--return-ids",[542],{"type":44,"value":543},"Canonical text-edit recipe",{"type":44,"value":68},{"type":38,"tag":250,"props":546,"children":547},{},[548,553,555,561,563,569,571,576],{"type":38,"tag":73,"props":549,"children":550},{},[551],{"type":44,"value":552},"Pages load incrementally",{"type":44,"value":554}," — use ",{"type":38,"tag":53,"props":556,"children":558},{"className":557},[],[559],{"type":44,"value":560},"await figma.setCurrentPageAsync(page)",{"type":44,"value":562}," to switch pages and load their content. The sync setter ",{"type":38,"tag":53,"props":564,"children":566},{"className":565},[],[567],{"type":44,"value":568},"figma.currentPage = page",{"type":44,"value":570}," does ",{"type":38,"tag":73,"props":572,"children":573},{},[574],{"type":44,"value":575},"NOT",{"type":44,"value":577}," work and will throw (see Page Rules below)",{"type":38,"tag":250,"props":579,"children":580},{},[581,587,589,594],{"type":38,"tag":53,"props":582,"children":584},{"className":583},[],[585],{"type":44,"value":586},"setBoundVariableForPaint",{"type":44,"value":588}," returns a ",{"type":38,"tag":73,"props":590,"children":591},{},[592],{"type":44,"value":593},"NEW",{"type":44,"value":595}," paint — must capture and reassign",{"type":38,"tag":250,"props":597,"children":598},{},[599,605,607,612],{"type":38,"tag":53,"props":600,"children":602},{"className":601},[],[603],{"type":44,"value":604},"createVariable",{"type":44,"value":606}," accepts collection ",{"type":38,"tag":73,"props":608,"children":609},{},[610],{"type":44,"value":611},"object or ID string",{"type":44,"value":613}," (object preferred)",{"type":38,"tag":250,"props":615,"children":616},{},[617,651,652,658,660,665,667,673,675,680,682,687,689,695,697,703,705,710,712,718,720,726,728,734,735,741,743,761,762,768,769,775,777,782,784,790,792,798,799,805,807,812,814,820,822,828,830,835,837,843,845,851,853,859,860,866,868,874,875,881,883,902,904,909],{"type":38,"tag":73,"props":618,"children":619},{},[620,626,628,634,636,642,643,649],{"type":38,"tag":53,"props":621,"children":623},{"className":622},[],[624],{"type":44,"value":625},"layoutSizingHorizontal\u002FVertical",{"type":44,"value":627}," is value-restricted by structural context — ",{"type":38,"tag":53,"props":629,"children":631},{"className":630},[],[632],{"type":44,"value":633},"FIXED",{"type":44,"value":635}," always works, ",{"type":38,"tag":53,"props":637,"children":639},{"className":638},[],[640],{"type":44,"value":641},"HUG",{"type":44,"value":291},{"type":38,"tag":53,"props":644,"children":646},{"className":645},[],[647],{"type":44,"value":648},"FILL",{"type":44,"value":650}," do not.",{"type":44,"value":317},{"type":38,"tag":53,"props":653,"children":655},{"className":654},[],[656],{"type":44,"value":657},"'HUG'",{"type":44,"value":659}," is valid only on an auto-layout frame itself OR on a ",{"type":38,"tag":73,"props":661,"children":662},{},[663],{"type":44,"value":664},"TEXT",{"type":44,"value":666}," child of one. ",{"type":38,"tag":53,"props":668,"children":670},{"className":669},[],[671],{"type":44,"value":672},"'FILL'",{"type":44,"value":674}," is valid only on a child of an auto-layout frame that is also not absolute-positioned, not inside an immutable frame, and not a canvas-grid child. Practical consequence: append to an auto-layout parent FIRST, then set ",{"type":38,"tag":53,"props":676,"children":678},{"className":677},[],[679],{"type":44,"value":641},{"type":44,"value":681},"\u002F",{"type":38,"tag":53,"props":683,"children":685},{"className":684},[],[686],{"type":44,"value":648},{"type":44,"value":688}," — a newly-created or unparented node can't satisfy the rule yet. The property itself exists on every ",{"type":38,"tag":53,"props":690,"children":692},{"className":691},[],[693],{"type":44,"value":694},"SceneNode",{"type":44,"value":696},"; the error is value-rejection, not \"no such property\". See ",{"type":38,"tag":163,"props":698,"children":700},{"href":699},"references\u002Fgotchas.md#layoutsizinghorizontallayoutsizingvertical-value-rules-fixed-hug-fill",[701],{"type":44,"value":702},"Gotchas",{"type":44,"value":704},".\n12a. ",{"type":38,"tag":73,"props":706,"children":707},{},[708],{"type":44,"value":709},"Use auto-layout for containers that hold related children.",{"type":44,"value":711}," When children have a structural relationship — stacked, side-by-side, aligned, gapped, hugged — wrap them in ",{"type":38,"tag":53,"props":713,"children":715},{"className":714},[],[716],{"type":44,"value":717},"figma.createAutoLayout()",{"type":44,"value":719},", not ",{"type":38,"tag":53,"props":721,"children":723},{"className":722},[],[724],{"type":44,"value":725},"figma.createFrame()",{"type":44,"value":727}," with absolute ",{"type":38,"tag":53,"props":729,"children":731},{"className":730},[],[732],{"type":44,"value":733},"x",{"type":44,"value":681},{"type":38,"tag":53,"props":736,"children":738},{"className":737},[],[739],{"type":44,"value":740},"y",{"type":44,"value":742},". Absolute coordinates govern where a container sits on the canvas; auto-layout governs how its children relate inside it. Skipping the container leaves no protection against text reflow, content changes, or overlap.\n12b. ",{"type":38,"tag":73,"props":744,"children":745},{},[746,752,753,759],{"type":38,"tag":53,"props":747,"children":749},{"className":748},[],[750],{"type":44,"value":751},"layoutSizing*",{"type":44,"value":291},{"type":38,"tag":53,"props":754,"children":756},{"className":755},[],[757],{"type":44,"value":758},"*AxisSizingMode",{"type":44,"value":760}," are different enums — don't cross them.",{"type":44,"value":317},{"type":38,"tag":53,"props":763,"children":765},{"className":764},[],[766],{"type":44,"value":767},"layoutSizingHorizontal",{"type":44,"value":681},{"type":38,"tag":53,"props":770,"children":772},{"className":771},[],[773],{"type":44,"value":774},"layoutSizingVertical",{"type":44,"value":776}," (set on a ",{"type":38,"tag":73,"props":778,"children":779},{},[780],{"type":44,"value":781},"child",{"type":44,"value":783},") take ",{"type":38,"tag":53,"props":785,"children":787},{"className":786},[],[788],{"type":44,"value":789},"'FIXED'|'HUG'|'FILL'",{"type":44,"value":791},"; ",{"type":38,"tag":53,"props":793,"children":795},{"className":794},[],[796],{"type":44,"value":797},"primaryAxisSizingMode",{"type":44,"value":681},{"type":38,"tag":53,"props":800,"children":802},{"className":801},[],[803],{"type":44,"value":804},"counterAxisSizingMode",{"type":44,"value":806}," (set on the ",{"type":38,"tag":73,"props":808,"children":809},{},[810],{"type":44,"value":811},"frame",{"type":44,"value":813}," itself) take ",{"type":38,"tag":53,"props":815,"children":817},{"className":816},[],[818],{"type":44,"value":819},"'FIXED'|'AUTO'",{"type":44,"value":821},". So ",{"type":38,"tag":53,"props":823,"children":825},{"className":824},[],[826],{"type":44,"value":827},"layoutSizingVertical = 'AUTO'",{"type":44,"value":829}," is invalid (use ",{"type":38,"tag":53,"props":831,"children":833},{"className":832},[],[834],{"type":44,"value":657},{"type":44,"value":836},"), and ",{"type":38,"tag":53,"props":838,"children":840},{"className":839},[],[841],{"type":44,"value":842},"counterAxisSizingMode = 'FILL'",{"type":44,"value":844}," throws ",{"type":38,"tag":53,"props":846,"children":848},{"className":847},[],[849],{"type":44,"value":850},"Expected 'FIXED' | 'AUTO', received 'FILL'",{"type":44,"value":852}," (use ",{"type":38,"tag":53,"props":854,"children":856},{"className":855},[],[857],{"type":44,"value":858},"'FIXED'",{"type":44,"value":681},{"type":38,"tag":53,"props":861,"children":863},{"className":862},[],[864],{"type":44,"value":865},"'AUTO'",{"type":44,"value":867},"). Two more errors from the same setter — ",{"type":38,"tag":53,"props":869,"children":871},{"className":870},[],[872],{"type":44,"value":873},"Error: in set_layoutSizingHorizontal: node must be an auto-layout frame or a child of an auto-layout frame",{"type":44,"value":291},{"type":38,"tag":53,"props":876,"children":878},{"className":877},[],[879],{"type":44,"value":880},"Error: in set_layoutSizingHorizontal: FILL can only be set on children of auto-layout frames",{"type":44,"value":882}," — mean the node isn't in an auto-layout context yet; ",{"type":38,"tag":73,"props":884,"children":885},{},[886,888,893,895,900],{"type":44,"value":887},"recommendation: make the parent auto-layout (",{"type":38,"tag":53,"props":889,"children":891},{"className":890},[],[892],{"type":44,"value":717},{"type":44,"value":894},") and ",{"type":38,"tag":53,"props":896,"children":898},{"className":897},[],[899],{"type":44,"value":475},{"type":44,"value":901}," the node before setting",{"type":44,"value":903}," (see Rule 12). See ",{"type":38,"tag":163,"props":905,"children":907},{"href":906},"references\u002Fgotchas.md#layoutsizing-vs-axissizingmode-two-different-sizing-enums",[908],{"type":44,"value":702},{"type":44,"value":68},{"type":38,"tag":250,"props":911,"children":912},{},[913,918,920,926,928,933],{"type":38,"tag":73,"props":914,"children":915},{},[916],{"type":44,"value":917},"Position new top-level nodes away from (0,0).",{"type":44,"value":919}," Nodes appended directly to the page default to (0,0). Scan ",{"type":38,"tag":53,"props":921,"children":923},{"className":922},[],[924],{"type":44,"value":925},"figma.currentPage.children",{"type":44,"value":927}," to find a clear position (e.g., to the right of the rightmost node). This only applies to page-level nodes — nodes nested inside other frames or auto-layout containers are positioned by their parent. See ",{"type":38,"tag":163,"props":929,"children":931},{"href":930},"references\u002Fgotchas.md",[932],{"type":44,"value":702},{"type":44,"value":68},{"type":38,"tag":250,"props":935,"children":936},{},[937,949,951,956,958,964],{"type":38,"tag":73,"props":938,"children":939},{},[940,942,947],{"type":44,"value":941},"On ",{"type":38,"tag":53,"props":943,"children":945},{"className":944},[],[946],{"type":44,"value":58},{"type":44,"value":948}," error, STOP. Do NOT immediately retry.",{"type":44,"value":950}," Failed scripts are ",{"type":38,"tag":73,"props":952,"children":953},{},[954],{"type":44,"value":955},"atomic",{"type":44,"value":957}," — if a script errors, it is not executed at all and no changes are made to the file. Read the error message carefully, fix the script, then retry. See ",{"type":38,"tag":163,"props":959,"children":961},{"href":960},"#6-error-recovery--self-correction",[962],{"type":44,"value":963},"Error Recovery",{"type":44,"value":68},{"type":38,"tag":250,"props":966,"children":967},{},[968,980,982,988],{"type":38,"tag":73,"props":969,"children":970},{},[971,973,978],{"type":44,"value":972},"MUST ",{"type":38,"tag":53,"props":974,"children":976},{"className":975},[],[977],{"type":44,"value":263},{"type":44,"value":979}," ALL created\u002Fmutated node IDs.",{"type":44,"value":981}," Whenever a script creates new nodes or mutates existing ones on the canvas, collect every affected node ID and return them in a structured object (e.g. ",{"type":38,"tag":53,"props":983,"children":985},{"className":984},[],[986],{"type":44,"value":987},"return { createdNodeIds: [...], mutatedNodeIds: [...] }",{"type":44,"value":989},"). This is essential for subsequent calls to reference, validate, or clean up those nodes.",{"type":38,"tag":250,"props":991,"children":992},{},[993,1006,1008,1014,1016,1022,1024,1030,1032,1038,1040,1046],{"type":38,"tag":73,"props":994,"children":995},{},[996,998,1004],{"type":44,"value":997},"Always set ",{"type":38,"tag":53,"props":999,"children":1001},{"className":1000},[],[1002],{"type":44,"value":1003},"variable.scopes",{"type":44,"value":1005}," explicitly when creating variables.",{"type":44,"value":1007}," The default ",{"type":38,"tag":53,"props":1009,"children":1011},{"className":1010},[],[1012],{"type":44,"value":1013},"ALL_SCOPES",{"type":44,"value":1015}," pollutes every property picker — almost never what you want. Use specific scopes like ",{"type":38,"tag":53,"props":1017,"children":1019},{"className":1018},[],[1020],{"type":44,"value":1021},"[\"FRAME_FILL\", \"SHAPE_FILL\"]",{"type":44,"value":1023}," for backgrounds, ",{"type":38,"tag":53,"props":1025,"children":1027},{"className":1026},[],[1028],{"type":44,"value":1029},"[\"TEXT_FILL\"]",{"type":44,"value":1031}," for text colors, ",{"type":38,"tag":53,"props":1033,"children":1035},{"className":1034},[],[1036],{"type":44,"value":1037},"[\"GAP\"]",{"type":44,"value":1039}," for spacing, etc. See ",{"type":38,"tag":163,"props":1041,"children":1043},{"href":1042},"references\u002Fvariable-patterns.md",[1044],{"type":44,"value":1045},"variable-patterns.md",{"type":44,"value":1047}," for the full list.",{"type":38,"tag":250,"props":1049,"children":1050},{},[1051,1061,1063,1069,1071,1076,1077,1083,1084,1089],{"type":38,"tag":73,"props":1052,"children":1053},{},[1054,1059],{"type":38,"tag":53,"props":1055,"children":1057},{"className":1056},[],[1058],{"type":44,"value":289},{"type":44,"value":1060}," every Promise.",{"type":44,"value":1062}," Never leave a Promise unawaited — unawaited async calls (e.g. ",{"type":38,"tag":53,"props":1064,"children":1066},{"className":1065},[],[1067],{"type":44,"value":1068},"figma.loadFontAsync(...)",{"type":44,"value":1070}," without ",{"type":38,"tag":53,"props":1072,"children":1074},{"className":1073},[],[1075],{"type":44,"value":289},{"type":44,"value":362},{"type":38,"tag":53,"props":1078,"children":1080},{"className":1079},[],[1081],{"type":44,"value":1082},"figma.setCurrentPageAsync(page)",{"type":44,"value":1070},{"type":38,"tag":53,"props":1085,"children":1087},{"className":1086},[],[1088],{"type":44,"value":289},{"type":44,"value":1090},") will fire-and-forget, causing silent failures or race conditions. The script may return before the async operation completes, leading to missing data or half-applied changes.",{"type":38,"tag":1092,"props":1093,"children":1094},"blockquote",{},[1095],{"type":38,"tag":47,"props":1096,"children":1097},{},[1098,1100,1105],{"type":44,"value":1099},"For detailed WRONG\u002FCORRECT examples of each rule, see ",{"type":38,"tag":163,"props":1101,"children":1102},{"href":930},[1103],{"type":44,"value":1104},"Gotchas & Common Mistakes",{"type":44,"value":68},{"type":38,"tag":239,"props":1107,"children":1109},{"id":1108},"_2-page-rules-critical",[1110],{"type":44,"value":1111},"2. Page Rules (Critical)",{"type":38,"tag":47,"props":1113,"children":1114},{},[1115,1127,1129,1135],{"type":38,"tag":73,"props":1116,"children":1117},{},[1118,1120,1125],{"type":44,"value":1119},"Page context resets between ",{"type":38,"tag":53,"props":1121,"children":1123},{"className":1122},[],[1124],{"type":44,"value":58},{"type":44,"value":1126}," calls",{"type":44,"value":1128}," — ",{"type":38,"tag":53,"props":1130,"children":1132},{"className":1131},[],[1133],{"type":44,"value":1134},"figma.currentPage",{"type":44,"value":1136}," starts on the first page each time.",{"type":38,"tag":1138,"props":1139,"children":1141},"h3",{"id":1140},"switching-pages",[1142],{"type":44,"value":1143},"Switching pages",{"type":38,"tag":47,"props":1145,"children":1146},{},[1147,1148,1153,1154,1159,1160,1165,1167,1173,1175,1180],{"type":44,"value":257},{"type":38,"tag":53,"props":1149,"children":1151},{"className":1150},[],[1152],{"type":44,"value":560},{"type":44,"value":562},{"type":38,"tag":53,"props":1155,"children":1157},{"className":1156},[],[1158],{"type":44,"value":568},{"type":44,"value":570},{"type":38,"tag":73,"props":1161,"children":1162},{},[1163],{"type":44,"value":1164},"NOT work",{"type":44,"value":1166}," — it throws ",{"type":38,"tag":53,"props":1168,"children":1170},{"className":1169},[],[1171],{"type":44,"value":1172},"\"Setting figma.currentPage is not supported\"",{"type":44,"value":1174}," in ",{"type":38,"tag":53,"props":1176,"children":1178},{"className":1177},[],[1179],{"type":44,"value":58},{"type":44,"value":1181},". Always use the async method.",{"type":38,"tag":1183,"props":1184,"children":1189},"pre",{"className":1185,"code":1186,"language":1187,"meta":1188,"style":1188},"language-js shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u002F\u002F Switch to a specific page (loads its content)\nconst targetPage = figma.root.children.find((p) => p.name === \"My Page\");\nawait figma.setCurrentPageAsync(targetPage);\n\u002F\u002F targetPage.children is now populated\n","js","",[1190],{"type":38,"tag":53,"props":1191,"children":1192},{"__ignoreMap":1188},[1193,1205,1327,1358],{"type":38,"tag":1194,"props":1195,"children":1198},"span",{"class":1196,"line":1197},"line",1,[1199],{"type":38,"tag":1194,"props":1200,"children":1202},{"style":1201},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic",[1203],{"type":44,"value":1204},"\u002F\u002F Switch to a specific page (loads its content)\n",{"type":38,"tag":1194,"props":1206,"children":1208},{"class":1196,"line":1207},2,[1209,1215,1221,1227,1232,1236,1240,1244,1249,1253,1259,1264,1268,1273,1278,1283,1288,1292,1297,1302,1307,1313,1318,1322],{"type":38,"tag":1194,"props":1210,"children":1212},{"style":1211},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[1213],{"type":44,"value":1214},"const",{"type":38,"tag":1194,"props":1216,"children":1218},{"style":1217},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[1219],{"type":44,"value":1220}," targetPage ",{"type":38,"tag":1194,"props":1222,"children":1224},{"style":1223},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[1225],{"type":44,"value":1226},"=",{"type":38,"tag":1194,"props":1228,"children":1229},{"style":1217},[1230],{"type":44,"value":1231}," figma",{"type":38,"tag":1194,"props":1233,"children":1234},{"style":1223},[1235],{"type":44,"value":68},{"type":38,"tag":1194,"props":1237,"children":1238},{"style":1217},[1239],{"type":44,"value":35},{"type":38,"tag":1194,"props":1241,"children":1242},{"style":1223},[1243],{"type":44,"value":68},{"type":38,"tag":1194,"props":1245,"children":1246},{"style":1217},[1247],{"type":44,"value":1248},"children",{"type":38,"tag":1194,"props":1250,"children":1251},{"style":1223},[1252],{"type":44,"value":68},{"type":38,"tag":1194,"props":1254,"children":1256},{"style":1255},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[1257],{"type":44,"value":1258},"find",{"type":38,"tag":1194,"props":1260,"children":1261},{"style":1217},[1262],{"type":44,"value":1263},"(",{"type":38,"tag":1194,"props":1265,"children":1266},{"style":1223},[1267],{"type":44,"value":1263},{"type":38,"tag":1194,"props":1269,"children":1271},{"style":1270},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#EEFFFF;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic",[1272],{"type":44,"value":47},{"type":38,"tag":1194,"props":1274,"children":1275},{"style":1223},[1276],{"type":44,"value":1277},")",{"type":38,"tag":1194,"props":1279,"children":1280},{"style":1211},[1281],{"type":44,"value":1282}," =>",{"type":38,"tag":1194,"props":1284,"children":1285},{"style":1217},[1286],{"type":44,"value":1287}," p",{"type":38,"tag":1194,"props":1289,"children":1290},{"style":1223},[1291],{"type":44,"value":68},{"type":38,"tag":1194,"props":1293,"children":1294},{"style":1217},[1295],{"type":44,"value":1296},"name ",{"type":38,"tag":1194,"props":1298,"children":1299},{"style":1223},[1300],{"type":44,"value":1301},"===",{"type":38,"tag":1194,"props":1303,"children":1304},{"style":1223},[1305],{"type":44,"value":1306}," \"",{"type":38,"tag":1194,"props":1308,"children":1310},{"style":1309},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[1311],{"type":44,"value":1312},"My Page",{"type":38,"tag":1194,"props":1314,"children":1315},{"style":1223},[1316],{"type":44,"value":1317},"\"",{"type":38,"tag":1194,"props":1319,"children":1320},{"style":1217},[1321],{"type":44,"value":1277},{"type":38,"tag":1194,"props":1323,"children":1324},{"style":1223},[1325],{"type":44,"value":1326},";\n",{"type":38,"tag":1194,"props":1328,"children":1330},{"class":1196,"line":1329},3,[1331,1336,1340,1344,1349,1354],{"type":38,"tag":1194,"props":1332,"children":1334},{"style":1333},"--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic",[1335],{"type":44,"value":289},{"type":38,"tag":1194,"props":1337,"children":1338},{"style":1217},[1339],{"type":44,"value":1231},{"type":38,"tag":1194,"props":1341,"children":1342},{"style":1223},[1343],{"type":44,"value":68},{"type":38,"tag":1194,"props":1345,"children":1346},{"style":1255},[1347],{"type":44,"value":1348},"setCurrentPageAsync",{"type":38,"tag":1194,"props":1350,"children":1351},{"style":1217},[1352],{"type":44,"value":1353},"(targetPage)",{"type":38,"tag":1194,"props":1355,"children":1356},{"style":1223},[1357],{"type":44,"value":1326},{"type":38,"tag":1194,"props":1359,"children":1361},{"class":1196,"line":1360},4,[1362],{"type":38,"tag":1194,"props":1363,"children":1364},{"style":1201},[1365],{"type":44,"value":1366},"\u002F\u002F targetPage.children is now populated\n",{"type":38,"tag":1138,"props":1368,"children":1370},{"id":1369},"call-setcurrentpageasync-at-most-once-per-use_figma-invocation-fan-multi-page-work-out-in-parallel",[1371,1373,1378,1380,1385],{"type":44,"value":1372},"Call ",{"type":38,"tag":53,"props":1374,"children":1376},{"className":1375},[],[1377],{"type":44,"value":1348},{"type":44,"value":1379}," at most once per ",{"type":38,"tag":53,"props":1381,"children":1383},{"className":1382},[],[1384],{"type":44,"value":58},{"type":44,"value":1386}," invocation — fan multi-page work out in parallel",{"type":38,"tag":47,"props":1388,"children":1389},{},[1390,1395,1397,1403],{"type":38,"tag":73,"props":1391,"children":1392},{},[1393],{"type":44,"value":1394},"One script must switch pages at most once.",{"type":44,"value":1396}," Never loop over ",{"type":38,"tag":53,"props":1398,"children":1400},{"className":1399},[],[1401],{"type":44,"value":1402},"figma.root.children",{"type":44,"value":1404}," and switch pages inside the loop.",{"type":38,"tag":47,"props":1406,"children":1407},{},[1408,1410,1422,1424,1429,1431,1437],{"type":44,"value":1409},"If the work spans multiple pages, ",{"type":38,"tag":73,"props":1411,"children":1412},{},[1413,1415,1420],{"type":44,"value":1414},"split it into N ",{"type":38,"tag":53,"props":1416,"children":1418},{"className":1417},[],[1419],{"type":44,"value":58},{"type":44,"value":1421}," calls (one per target page) and emit them in parallel",{"type":44,"value":1423}," — a single assistant message containing N ",{"type":38,"tag":53,"props":1425,"children":1427},{"className":1426},[],[1428],{"type":44,"value":58},{"type":44,"value":1430}," tool-use blocks. The harness runs them concurrently; each script sets ",{"type":38,"tag":53,"props":1432,"children":1434},{"className":1433},[],[1435],{"type":44,"value":1436},"currentPage",{"type":44,"value":1438}," exactly once.",{"type":38,"tag":1092,"props":1440,"children":1441},{},[1442],{"type":38,"tag":47,"props":1443,"children":1444},{},[1445,1450,1452,1457],{"type":38,"tag":73,"props":1446,"children":1447},{},[1448],{"type":44,"value":1449},"Explicit instruction:",{"type":44,"value":1451}," when fanning out, you MUST issue the N tool calls in ",{"type":38,"tag":73,"props":1453,"children":1454},{},[1455],{"type":44,"value":1456},"one message",{"type":44,"value":1458},". Do not send them across multiple turns. Do not await one before issuing the next. Sequential per-page calls are slower than the in-loop pattern this rule replaces and waste the entire benefit of splitting.",{"type":38,"tag":1183,"props":1460,"children":1462},{"className":1185,"code":1461,"language":1187,"meta":1188,"style":1188},"\u002F\u002F AVOID — switches pages N times in one script, reloads the file each time\nfor (const page of figma.root.children) {\n  await figma.setCurrentPageAsync(page);\n  \u002F\u002F ... touch this page ...\n}\n\n\u002F\u002F PREFER — read-only discovery call to get page IDs, then in the NEXT message\n\u002F\u002F emit N parallel use_figma tool calls (one per page), each setting currentPage once.\n",[1463],{"type":38,"tag":53,"props":1464,"children":1465},{"__ignoreMap":1188},[1466,1474,1527,1565,1573,1582,1592,1601],{"type":38,"tag":1194,"props":1467,"children":1468},{"class":1196,"line":1197},[1469],{"type":38,"tag":1194,"props":1470,"children":1471},{"style":1201},[1472],{"type":44,"value":1473},"\u002F\u002F AVOID — switches pages N times in one script, reloads the file each time\n",{"type":38,"tag":1194,"props":1475,"children":1476},{"class":1196,"line":1207},[1477,1482,1487,1491,1496,1501,1505,1509,1513,1517,1522],{"type":38,"tag":1194,"props":1478,"children":1479},{"style":1333},[1480],{"type":44,"value":1481},"for",{"type":38,"tag":1194,"props":1483,"children":1484},{"style":1217},[1485],{"type":44,"value":1486}," (",{"type":38,"tag":1194,"props":1488,"children":1489},{"style":1211},[1490],{"type":44,"value":1214},{"type":38,"tag":1194,"props":1492,"children":1493},{"style":1217},[1494],{"type":44,"value":1495}," page ",{"type":38,"tag":1194,"props":1497,"children":1498},{"style":1223},[1499],{"type":44,"value":1500},"of",{"type":38,"tag":1194,"props":1502,"children":1503},{"style":1217},[1504],{"type":44,"value":1231},{"type":38,"tag":1194,"props":1506,"children":1507},{"style":1223},[1508],{"type":44,"value":68},{"type":38,"tag":1194,"props":1510,"children":1511},{"style":1217},[1512],{"type":44,"value":35},{"type":38,"tag":1194,"props":1514,"children":1515},{"style":1223},[1516],{"type":44,"value":68},{"type":38,"tag":1194,"props":1518,"children":1519},{"style":1217},[1520],{"type":44,"value":1521},"children) ",{"type":38,"tag":1194,"props":1523,"children":1524},{"style":1223},[1525],{"type":44,"value":1526},"{\n",{"type":38,"tag":1194,"props":1528,"children":1529},{"class":1196,"line":1329},[1530,1535,1539,1543,1547,1552,1557,1561],{"type":38,"tag":1194,"props":1531,"children":1532},{"style":1333},[1533],{"type":44,"value":1534},"  await",{"type":38,"tag":1194,"props":1536,"children":1537},{"style":1217},[1538],{"type":44,"value":1231},{"type":38,"tag":1194,"props":1540,"children":1541},{"style":1223},[1542],{"type":44,"value":68},{"type":38,"tag":1194,"props":1544,"children":1545},{"style":1255},[1546],{"type":44,"value":1348},{"type":38,"tag":1194,"props":1548,"children":1550},{"style":1549},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[1551],{"type":44,"value":1263},{"type":38,"tag":1194,"props":1553,"children":1554},{"style":1217},[1555],{"type":44,"value":1556},"page",{"type":38,"tag":1194,"props":1558,"children":1559},{"style":1549},[1560],{"type":44,"value":1277},{"type":38,"tag":1194,"props":1562,"children":1563},{"style":1223},[1564],{"type":44,"value":1326},{"type":38,"tag":1194,"props":1566,"children":1567},{"class":1196,"line":1360},[1568],{"type":38,"tag":1194,"props":1569,"children":1570},{"style":1201},[1571],{"type":44,"value":1572},"  \u002F\u002F ... touch this page ...\n",{"type":38,"tag":1194,"props":1574,"children":1576},{"class":1196,"line":1575},5,[1577],{"type":38,"tag":1194,"props":1578,"children":1579},{"style":1223},[1580],{"type":44,"value":1581},"}\n",{"type":38,"tag":1194,"props":1583,"children":1585},{"class":1196,"line":1584},6,[1586],{"type":38,"tag":1194,"props":1587,"children":1589},{"emptyLinePlaceholder":1588},true,[1590],{"type":44,"value":1591},"\n",{"type":38,"tag":1194,"props":1593,"children":1595},{"class":1196,"line":1594},7,[1596],{"type":38,"tag":1194,"props":1597,"children":1598},{"style":1201},[1599],{"type":44,"value":1600},"\u002F\u002F PREFER — read-only discovery call to get page IDs, then in the NEXT message\n",{"type":38,"tag":1194,"props":1602,"children":1604},{"class":1196,"line":1603},8,[1605],{"type":38,"tag":1194,"props":1606,"children":1607},{"style":1201},[1608],{"type":44,"value":1609},"\u002F\u002F emit N parallel use_figma tool calls (one per page), each setting currentPage once.\n",{"type":38,"tag":47,"props":1611,"children":1612},{},[1613,1615,1627],{"type":44,"value":1614},"Default to parallel fan-out for any multi-page work — reads and writes alike. See ",{"type":38,"tag":163,"props":1616,"children":1618},{"href":1617},"references\u002Fgotchas.md#set-current-page-once-per-use_figma-call--split-multi-page-work-into-parallel-calls",[1619,1621,1626],{"type":44,"value":1620},"gotchas.md → Set current page once per ",{"type":38,"tag":53,"props":1622,"children":1624},{"className":1623},[],[1625],{"type":44,"value":58},{"type":44,"value":133},{"type":44,"value":1628}," for the full rationale.",{"type":38,"tag":1138,"props":1630,"children":1632},{"id":1631},"across-script-runs",[1633],{"type":44,"value":1634},"Across script runs",{"type":38,"tag":47,"props":1636,"children":1637},{},[1638,1643,1645,1650,1652,1657,1659,1664],{"type":38,"tag":53,"props":1639,"children":1641},{"className":1640},[],[1642],{"type":44,"value":1134},{"type":44,"value":1644}," resets to the ",{"type":38,"tag":73,"props":1646,"children":1647},{},[1648],{"type":44,"value":1649},"first page",{"type":44,"value":1651}," at the start of each ",{"type":38,"tag":53,"props":1653,"children":1655},{"className":1654},[],[1656],{"type":44,"value":58},{"type":44,"value":1658}," call. If your workflow spans multiple calls and targets a non-default page, call ",{"type":38,"tag":53,"props":1660,"children":1662},{"className":1661},[],[1663],{"type":44,"value":560},{"type":44,"value":1665}," at the start of each invocation.",{"type":38,"tag":47,"props":1667,"children":1668},{},[1669,1671,1676,1678,1683],{"type":44,"value":1670},"You can call ",{"type":38,"tag":53,"props":1672,"children":1674},{"className":1673},[],[1675],{"type":44,"value":58},{"type":44,"value":1677}," multiple times to incrementally build on the file state, or to retrieve information before writing another script. For example, write a script to get metadata about existing nodes, ",{"type":38,"tag":53,"props":1679,"children":1681},{"className":1680},[],[1682],{"type":44,"value":263},{"type":44,"value":1684}," that data, then use it in a subsequent script to modify those nodes.",{"type":38,"tag":239,"props":1686,"children":1688},{"id":1687},"_3-return-is-your-output-channel",[1689,1691,1696],{"type":44,"value":1690},"3. ",{"type":38,"tag":53,"props":1692,"children":1694},{"className":1693},[],[1695],{"type":44,"value":263},{"type":44,"value":1697}," Is Your Output Channel",{"type":38,"tag":47,"props":1699,"children":1700},{},[1701,1703,1708,1710,1715],{"type":44,"value":1702},"The agent sees ",{"type":38,"tag":73,"props":1704,"children":1705},{},[1706],{"type":44,"value":1707},"ONLY",{"type":44,"value":1709}," the value you ",{"type":38,"tag":53,"props":1711,"children":1713},{"className":1712},[],[1714],{"type":44,"value":263},{"type":44,"value":1716},". Everything else is invisible.",{"type":38,"tag":1718,"props":1719,"children":1720},"ul",{},[1721,1745,1761,1779,1796],{"type":38,"tag":250,"props":1722,"children":1723},{},[1724,1729,1731,1736,1738,1743],{"type":38,"tag":73,"props":1725,"children":1726},{},[1727],{"type":44,"value":1728},"Returning IDs (CRITICAL)",{"type":44,"value":1730},": Every script that creates or mutates canvas nodes ",{"type":38,"tag":73,"props":1732,"children":1733},{},[1734],{"type":44,"value":1735},"MUST",{"type":44,"value":1737}," return all affected node IDs — e.g. ",{"type":38,"tag":53,"props":1739,"children":1741},{"className":1740},[],[1742],{"type":44,"value":987},{"type":44,"value":1744},". This is a hard requirement, not optional.",{"type":38,"tag":250,"props":1746,"children":1747},{},[1748,1753,1755],{"type":38,"tag":73,"props":1749,"children":1750},{},[1751],{"type":44,"value":1752},"Progress reporting",{"type":44,"value":1754},": ",{"type":38,"tag":53,"props":1756,"children":1758},{"className":1757},[],[1759],{"type":44,"value":1760},"return { createdNodeIds: [...], count: 5, errors: [] }",{"type":38,"tag":250,"props":1762,"children":1763},{},[1764,1769,1771,1777],{"type":38,"tag":73,"props":1765,"children":1766},{},[1767],{"type":44,"value":1768},"Error info",{"type":44,"value":1770},": Thrown errors are automatically captured and returned — just let them propagate or ",{"type":38,"tag":53,"props":1772,"children":1774},{"className":1773},[],[1775],{"type":44,"value":1776},"throw",{"type":44,"value":1778}," explicitly.",{"type":38,"tag":250,"props":1780,"children":1781},{},[1782,1787,1789,1794],{"type":38,"tag":53,"props":1783,"children":1785},{"className":1784},[],[1786],{"type":44,"value":378},{"type":44,"value":1788}," output is ",{"type":38,"tag":73,"props":1790,"children":1791},{},[1792],{"type":44,"value":1793},"never",{"type":44,"value":1795}," returned to the agent",{"type":38,"tag":250,"props":1797,"children":1798},{},[1799],{"type":44,"value":1800},"Always return actionable data (IDs, counts, status) so subsequent calls can reference created objects",{"type":38,"tag":239,"props":1802,"children":1804},{"id":1803},"_4-editor-mode",[1805],{"type":44,"value":1806},"4. Editor Mode",{"type":38,"tag":47,"props":1808,"children":1809},{},[1810,1815,1817,1822,1824,1830,1832,1838,1840,1846],{"type":38,"tag":53,"props":1811,"children":1813},{"className":1812},[],[1814],{"type":44,"value":58},{"type":44,"value":1816}," works in ",{"type":38,"tag":73,"props":1818,"children":1819},{},[1820],{"type":44,"value":1821},"design mode",{"type":44,"value":1823}," (editorType ",{"type":38,"tag":53,"props":1825,"children":1827},{"className":1826},[],[1828],{"type":44,"value":1829},"\"figma\"",{"type":44,"value":1831},", the default). FigJam (",{"type":38,"tag":53,"props":1833,"children":1835},{"className":1834},[],[1836],{"type":44,"value":1837},"\"figjam\"",{"type":44,"value":1839},") and Slides (",{"type":38,"tag":53,"props":1841,"children":1843},{"className":1842},[],[1844],{"type":44,"value":1845},"\"slides\"",{"type":44,"value":1847},") have different sets of available node types — most design nodes are blocked in FigJam, and FigJam-only nodes are blocked in Slides.",{"type":38,"tag":47,"props":1849,"children":1850},{},[1851,1856,1858,1864,1866,1872,1874,1880],{"type":38,"tag":73,"props":1852,"children":1853},{},[1854],{"type":44,"value":1855},"Tell the editor from the URL:",{"type":44,"value":1857}," Design = ",{"type":38,"tag":53,"props":1859,"children":1861},{"className":1860},[],[1862],{"type":44,"value":1863},"figma.com\u002Fdesign\u002F...",{"type":44,"value":1865},", FigJam = ",{"type":38,"tag":53,"props":1867,"children":1869},{"className":1868},[],[1870],{"type":44,"value":1871},"figma.com\u002Fboard\u002F...",{"type":44,"value":1873},", Slides = ",{"type":38,"tag":53,"props":1875,"children":1877},{"className":1876},[],[1878],{"type":44,"value":1879},"figma.com\u002Fslides\u002F...",{"type":44,"value":1881},". Confirm before assuming an API is available.",{"type":38,"tag":47,"props":1883,"children":1884},{},[1885],{"type":44,"value":1886},"Available in design mode: Rectangle, Frame, Component, Text, Ellipse, Star, Line, Vector, Polygon, BooleanOperation, Slice, Page, Section, TextPath.",{"type":38,"tag":47,"props":1888,"children":1889},{},[1890,1895],{"type":38,"tag":73,"props":1891,"children":1892},{},[1893],{"type":44,"value":1894},"Blocked",{"type":44,"value":1896}," in design mode: Sticky, Connector, ShapeWithText, CodeBlock, Slide, SlideRow, SlideGrid, InteractiveSlideElement, Webpage.",{"type":38,"tag":47,"props":1898,"children":1899},{},[1900],{"type":44,"value":1901},"Available in Slides mode: Rectangle, Frame, Component, Text, Ellipse, Star, Line, Vector, Polygon, BooleanOperation, Slice, Section, TextPath, Slide, SlideRow, SlideGrid, InteractiveSlideElement.",{"type":38,"tag":47,"props":1903,"children":1904},{},[1905,1909],{"type":38,"tag":73,"props":1906,"children":1907},{},[1908],{"type":44,"value":1894},{"type":44,"value":1910}," in Slides mode: Sticky, Connector, ShapeWithText, CodeBlock, Webpage, Page.",{"type":38,"tag":47,"props":1912,"children":1913},{},[1914,1919,1920,1926,1928,1933,1935,1940,1941,1946,1948,1954,1956,1961],{"type":38,"tag":73,"props":1915,"children":1916},{},[1917],{"type":44,"value":1918},"Design-only APIs (not just node types):",{"type":44,"value":317},{"type":38,"tag":53,"props":1921,"children":1923},{"className":1922},[],[1924],{"type":44,"value":1925},"figma.createPage()",{"type":44,"value":1927}," is available only in Design files (",{"type":38,"tag":53,"props":1929,"children":1931},{"className":1930},[],[1932],{"type":44,"value":1863},{"type":44,"value":1934},"). In both FigJam (",{"type":38,"tag":53,"props":1936,"children":1938},{"className":1937},[],[1939],{"type":44,"value":1871},{"type":44,"value":1839},{"type":38,"tag":53,"props":1942,"children":1944},{"className":1943},[],[1945],{"type":44,"value":1879},{"type":44,"value":1947},") it throws ",{"type":38,"tag":53,"props":1949,"children":1951},{"className":1950},[],[1952],{"type":44,"value":1953},"TypeError: figma.createPage no such property 'createPage' on the figma global object",{"type":44,"value":1955},". Do not emit ",{"type":38,"tag":53,"props":1957,"children":1959},{"className":1958},[],[1960],{"type":44,"value":1925},{"type":44,"value":1962}," in FigJam or Slides workflows.",{"type":38,"tag":1092,"props":1964,"children":1965},{},[1966],{"type":38,"tag":47,"props":1967,"children":1968},{},[1969,1974,1976,1981,1983,1989,1991,1997,1999,2005],{"type":38,"tag":73,"props":1970,"children":1971},{},[1972],{"type":44,"value":1973},"Slides note:",{"type":44,"value":1975}," There is no dedicated read tool for Slides files yet. Use ",{"type":38,"tag":53,"props":1977,"children":1979},{"className":1978},[],[1980],{"type":44,"value":58},{"type":44,"value":1982}," with read-only scripts for inspection (see Section 6 \"Inspect first\" pattern), and ",{"type":38,"tag":53,"props":1984,"children":1986},{"className":1985},[],[1987],{"type":44,"value":1988},"get_screenshot",{"type":44,"value":1990}," \u002F ",{"type":38,"tag":53,"props":1992,"children":1994},{"className":1993},[],[1995],{"type":44,"value":1996},"await node.screenshot()",{"type":44,"value":1998}," for visual context. For Slides-specific API guidance, load the ",{"type":38,"tag":163,"props":2000,"children":2002},{"href":2001},"..\u002Ffigma-use-slides\u002FSKILL.md",[2003],{"type":44,"value":2004},"figma-use-slides",{"type":44,"value":2006}," skill.",{"type":38,"tag":239,"props":2008,"children":2010},{"id":2009},"_5-efficient-apis-prefer-these-over-verbose-alternatives",[2011],{"type":44,"value":2012},"5. Efficient APIs — Prefer These Over Verbose Alternatives",{"type":38,"tag":47,"props":2014,"children":2015},{},[2016,2018],{"type":44,"value":2017},"These APIs reduce boilerplate, eliminate ordering errors, and compress token output. ",{"type":38,"tag":73,"props":2019,"children":2020},{},[2021],{"type":44,"value":2022},"Always prefer them over the verbose alternatives.",{"type":38,"tag":1138,"props":2024,"children":2026},{"id":2025},"nodequeryselector-css-like-node-search",[2027,2033],{"type":38,"tag":53,"props":2028,"children":2030},{"className":2029},[],[2031],{"type":44,"value":2032},"node.query(selector)",{"type":44,"value":2034}," — CSS-like node search",{"type":38,"tag":47,"props":2036,"children":2037},{},[2038,2040,2045],{"type":44,"value":2039},"Find nodes within a subtree using CSS-like selectors. Replaces verbose ",{"type":38,"tag":53,"props":2041,"children":2043},{"className":2042},[],[2044],{"type":44,"value":511},{"type":44,"value":2046}," + filter loops.",{"type":38,"tag":1183,"props":2048,"children":2050},{"className":1185,"code":2049,"language":1187,"meta":1188,"style":1188},"\u002F\u002F BEFORE — verbose traversal\nconst texts = frame.findAll(n => n.type === 'TEXT' && n.name === 'Title')\n\n\u002F\u002F AFTER — one-liner with query\nconst texts = frame.query('TEXT[name=Title]')\n",[2051],{"type":38,"tag":53,"props":2052,"children":2053},{"__ignoreMap":1188},[2054,2062,2175,2182,2190],{"type":38,"tag":1194,"props":2055,"children":2056},{"class":1196,"line":1197},[2057],{"type":38,"tag":1194,"props":2058,"children":2059},{"style":1201},[2060],{"type":44,"value":2061},"\u002F\u002F BEFORE — verbose traversal\n",{"type":38,"tag":1194,"props":2063,"children":2064},{"class":1196,"line":1207},[2065,2069,2074,2078,2083,2087,2091,2095,2100,2104,2109,2113,2118,2122,2127,2131,2136,2141,2145,2149,2153,2157,2161,2166,2170],{"type":38,"tag":1194,"props":2066,"children":2067},{"style":1211},[2068],{"type":44,"value":1214},{"type":38,"tag":1194,"props":2070,"children":2071},{"style":1217},[2072],{"type":44,"value":2073}," texts ",{"type":38,"tag":1194,"props":2075,"children":2076},{"style":1223},[2077],{"type":44,"value":1226},{"type":38,"tag":1194,"props":2079,"children":2080},{"style":1217},[2081],{"type":44,"value":2082}," frame",{"type":38,"tag":1194,"props":2084,"children":2085},{"style":1223},[2086],{"type":44,"value":68},{"type":38,"tag":1194,"props":2088,"children":2089},{"style":1255},[2090],{"type":44,"value":511},{"type":38,"tag":1194,"props":2092,"children":2093},{"style":1217},[2094],{"type":44,"value":1263},{"type":38,"tag":1194,"props":2096,"children":2097},{"style":1270},[2098],{"type":44,"value":2099},"n",{"type":38,"tag":1194,"props":2101,"children":2102},{"style":1211},[2103],{"type":44,"value":1282},{"type":38,"tag":1194,"props":2105,"children":2106},{"style":1217},[2107],{"type":44,"value":2108}," n",{"type":38,"tag":1194,"props":2110,"children":2111},{"style":1223},[2112],{"type":44,"value":68},{"type":38,"tag":1194,"props":2114,"children":2115},{"style":1217},[2116],{"type":44,"value":2117},"type ",{"type":38,"tag":1194,"props":2119,"children":2120},{"style":1223},[2121],{"type":44,"value":1301},{"type":38,"tag":1194,"props":2123,"children":2124},{"style":1223},[2125],{"type":44,"value":2126}," '",{"type":38,"tag":1194,"props":2128,"children":2129},{"style":1309},[2130],{"type":44,"value":664},{"type":38,"tag":1194,"props":2132,"children":2133},{"style":1223},[2134],{"type":44,"value":2135},"'",{"type":38,"tag":1194,"props":2137,"children":2138},{"style":1223},[2139],{"type":44,"value":2140}," &&",{"type":38,"tag":1194,"props":2142,"children":2143},{"style":1217},[2144],{"type":44,"value":2108},{"type":38,"tag":1194,"props":2146,"children":2147},{"style":1223},[2148],{"type":44,"value":68},{"type":38,"tag":1194,"props":2150,"children":2151},{"style":1217},[2152],{"type":44,"value":1296},{"type":38,"tag":1194,"props":2154,"children":2155},{"style":1223},[2156],{"type":44,"value":1301},{"type":38,"tag":1194,"props":2158,"children":2159},{"style":1223},[2160],{"type":44,"value":2126},{"type":38,"tag":1194,"props":2162,"children":2163},{"style":1309},[2164],{"type":44,"value":2165},"Title",{"type":38,"tag":1194,"props":2167,"children":2168},{"style":1223},[2169],{"type":44,"value":2135},{"type":38,"tag":1194,"props":2171,"children":2172},{"style":1217},[2173],{"type":44,"value":2174},")\n",{"type":38,"tag":1194,"props":2176,"children":2177},{"class":1196,"line":1329},[2178],{"type":38,"tag":1194,"props":2179,"children":2180},{"emptyLinePlaceholder":1588},[2181],{"type":44,"value":1591},{"type":38,"tag":1194,"props":2183,"children":2184},{"class":1196,"line":1360},[2185],{"type":38,"tag":1194,"props":2186,"children":2187},{"style":1201},[2188],{"type":44,"value":2189},"\u002F\u002F AFTER — one-liner with query\n",{"type":38,"tag":1194,"props":2191,"children":2192},{"class":1196,"line":1575},[2193,2197,2201,2205,2209,2213,2218,2222,2226,2231,2235],{"type":38,"tag":1194,"props":2194,"children":2195},{"style":1211},[2196],{"type":44,"value":1214},{"type":38,"tag":1194,"props":2198,"children":2199},{"style":1217},[2200],{"type":44,"value":2073},{"type":38,"tag":1194,"props":2202,"children":2203},{"style":1223},[2204],{"type":44,"value":1226},{"type":38,"tag":1194,"props":2206,"children":2207},{"style":1217},[2208],{"type":44,"value":2082},{"type":38,"tag":1194,"props":2210,"children":2211},{"style":1223},[2212],{"type":44,"value":68},{"type":38,"tag":1194,"props":2214,"children":2215},{"style":1255},[2216],{"type":44,"value":2217},"query",{"type":38,"tag":1194,"props":2219,"children":2220},{"style":1217},[2221],{"type":44,"value":1263},{"type":38,"tag":1194,"props":2223,"children":2224},{"style":1223},[2225],{"type":44,"value":2135},{"type":38,"tag":1194,"props":2227,"children":2228},{"style":1309},[2229],{"type":44,"value":2230},"TEXT[name=Title]",{"type":38,"tag":1194,"props":2232,"children":2233},{"style":1223},[2234],{"type":44,"value":2135},{"type":38,"tag":1194,"props":2236,"children":2237},{"style":1217},[2238],{"type":44,"value":2174},{"type":38,"tag":47,"props":2240,"children":2241},{},[2242],{"type":38,"tag":73,"props":2243,"children":2244},{},[2245],{"type":44,"value":2246},"Selector syntax:",{"type":38,"tag":1718,"props":2248,"children":2249},{},[2250,2304,2329,2358,2378,2396,2433,2479,2492,2505],{"type":38,"tag":250,"props":2251,"children":2252},{},[2253,2255,2261,2262,2267,2268,2274,2275,2281,2282,2288,2289,2295,2296,2302],{"type":44,"value":2254},"Type: ",{"type":38,"tag":53,"props":2256,"children":2258},{"className":2257},[],[2259],{"type":44,"value":2260},"FRAME",{"type":44,"value":477},{"type":38,"tag":53,"props":2263,"children":2265},{"className":2264},[],[2266],{"type":44,"value":664},{"type":44,"value":477},{"type":38,"tag":53,"props":2269,"children":2271},{"className":2270},[],[2272],{"type":44,"value":2273},"RECTANGLE",{"type":44,"value":477},{"type":38,"tag":53,"props":2276,"children":2278},{"className":2277},[],[2279],{"type":44,"value":2280},"ELLIPSE",{"type":44,"value":477},{"type":38,"tag":53,"props":2283,"children":2285},{"className":2284},[],[2286],{"type":44,"value":2287},"COMPONENT",{"type":44,"value":477},{"type":38,"tag":53,"props":2290,"children":2292},{"className":2291},[],[2293],{"type":44,"value":2294},"INSTANCE",{"type":44,"value":477},{"type":38,"tag":53,"props":2297,"children":2299},{"className":2298},[],[2300],{"type":44,"value":2301},"SECTION",{"type":44,"value":2303}," (case-insensitive)",{"type":38,"tag":250,"props":2305,"children":2306},{},[2307,2309,2315,2316,2322,2323],{"type":44,"value":2308},"Attribute exact: ",{"type":38,"tag":53,"props":2310,"children":2312},{"className":2311},[],[2313],{"type":44,"value":2314},"[name=Card]",{"type":44,"value":477},{"type":38,"tag":53,"props":2317,"children":2319},{"className":2318},[],[2320],{"type":44,"value":2321},"[visible=true]",{"type":44,"value":477},{"type":38,"tag":53,"props":2324,"children":2326},{"className":2325},[],[2327],{"type":44,"value":2328},"[opacity=0.5]",{"type":38,"tag":250,"props":2330,"children":2331},{},[2332,2334,2340,2342,2348,2350,2356],{"type":44,"value":2333},"Attribute substring: ",{"type":38,"tag":53,"props":2335,"children":2337},{"className":2336},[],[2338],{"type":44,"value":2339},"[name*=art]",{"type":44,"value":2341}," (contains), ",{"type":38,"tag":53,"props":2343,"children":2345},{"className":2344},[],[2346],{"type":44,"value":2347},"[name^=Header]",{"type":44,"value":2349}," (starts-with), ",{"type":38,"tag":53,"props":2351,"children":2353},{"className":2352},[],[2354],{"type":44,"value":2355},"[name$=Nav]",{"type":44,"value":2357}," (ends-with)",{"type":38,"tag":250,"props":2359,"children":2360},{},[2361,2363,2369,2370,2376],{"type":44,"value":2362},"Dot-path traversal: ",{"type":38,"tag":53,"props":2364,"children":2366},{"className":2365},[],[2367],{"type":44,"value":2368},"[fills.0.type=SOLID]",{"type":44,"value":477},{"type":38,"tag":53,"props":2371,"children":2373},{"className":2372},[],[2374],{"type":44,"value":2375},"[fills.*.type=SOLID]",{"type":44,"value":2377}," (wildcard index)",{"type":38,"tag":250,"props":2379,"children":2380},{},[2381,2383,2389,2390],{"type":44,"value":2382},"Instance matching: ",{"type":38,"tag":53,"props":2384,"children":2386},{"className":2385},[],[2387],{"type":44,"value":2388},"[mainComponent=nodeId]",{"type":44,"value":477},{"type":38,"tag":53,"props":2391,"children":2393},{"className":2392},[],[2394],{"type":44,"value":2395},"[mainComponent.name=Button]",{"type":38,"tag":250,"props":2397,"children":2398},{},[2399,2401,2407,2409,2415,2417,2423,2425,2431],{"type":44,"value":2400},"Combinators: ",{"type":38,"tag":53,"props":2402,"children":2404},{"className":2403},[],[2405],{"type":44,"value":2406},"FRAME > TEXT",{"type":44,"value":2408}," (direct child), ",{"type":38,"tag":53,"props":2410,"children":2412},{"className":2411},[],[2413],{"type":44,"value":2414},"FRAME TEXT",{"type":44,"value":2416}," (any descendant), ",{"type":38,"tag":53,"props":2418,"children":2420},{"className":2419},[],[2421],{"type":44,"value":2422},"A + B",{"type":44,"value":2424}," (adjacent sibling), ",{"type":38,"tag":53,"props":2426,"children":2428},{"className":2427},[],[2429],{"type":44,"value":2430},"A ~ B",{"type":44,"value":2432}," (general sibling)",{"type":38,"tag":250,"props":2434,"children":2435},{},[2436,2438,2444,2445,2451,2452,2458,2459,2465,2466,2472,2473],{"type":44,"value":2437},"Pseudo-classes: ",{"type":38,"tag":53,"props":2439,"children":2441},{"className":2440},[],[2442],{"type":44,"value":2443},":first-child",{"type":44,"value":477},{"type":38,"tag":53,"props":2446,"children":2448},{"className":2447},[],[2449],{"type":44,"value":2450},":last-child",{"type":44,"value":477},{"type":38,"tag":53,"props":2453,"children":2455},{"className":2454},[],[2456],{"type":44,"value":2457},":nth-child(2)",{"type":44,"value":477},{"type":38,"tag":53,"props":2460,"children":2462},{"className":2461},[],[2463],{"type":44,"value":2464},":not(TYPE)",{"type":44,"value":477},{"type":38,"tag":53,"props":2467,"children":2469},{"className":2468},[],[2470],{"type":44,"value":2471},":is(FRAME, RECTANGLE)",{"type":44,"value":477},{"type":38,"tag":53,"props":2474,"children":2476},{"className":2475},[],[2477],{"type":44,"value":2478},":where(TEXT, ELLIPSE)",{"type":38,"tag":250,"props":2480,"children":2481},{},[2482,2484,2490],{"type":44,"value":2483},"Node ID: ",{"type":38,"tag":53,"props":2485,"children":2487},{"className":2486},[],[2488],{"type":44,"value":2489},"#nodeId",{"type":44,"value":2491}," or bare GUID",{"type":38,"tag":250,"props":2493,"children":2494},{},[2495,2497,2503],{"type":44,"value":2496},"Comma: ",{"type":38,"tag":53,"props":2498,"children":2500},{"className":2499},[],[2501],{"type":44,"value":2502},"TEXT, RECTANGLE",{"type":44,"value":2504}," (union)",{"type":38,"tag":250,"props":2506,"children":2507},{},[2508,2510,2516],{"type":44,"value":2509},"Wildcard: ",{"type":38,"tag":53,"props":2511,"children":2513},{"className":2512},[],[2514],{"type":44,"value":2515},"*",{"type":44,"value":2517}," (any type)",{"type":38,"tag":47,"props":2519,"children":2520},{},[2521],{"type":38,"tag":73,"props":2522,"children":2523},{},[2524],{"type":44,"value":2525},"QueryResult methods:",{"type":38,"tag":2527,"props":2528,"children":2529},"table",{},[2530,2549],{"type":38,"tag":2531,"props":2532,"children":2533},"thead",{},[2534],{"type":38,"tag":2535,"props":2536,"children":2537},"tr",{},[2538,2544],{"type":38,"tag":2539,"props":2540,"children":2541},"th",{},[2542],{"type":44,"value":2543},"Method",{"type":38,"tag":2539,"props":2545,"children":2546},{},[2547],{"type":44,"value":2548},"Description",{"type":38,"tag":2550,"props":2551,"children":2552},"tbody",{},[2553,2571,2595,2618,2635,2660,2677,2694,2725,2750,2767],{"type":38,"tag":2535,"props":2554,"children":2555},{},[2556,2566],{"type":38,"tag":2557,"props":2558,"children":2559},"td",{},[2560],{"type":38,"tag":53,"props":2561,"children":2563},{"className":2562},[],[2564],{"type":44,"value":2565},".length",{"type":38,"tag":2557,"props":2567,"children":2568},{},[2569],{"type":44,"value":2570},"Number of matched nodes",{"type":38,"tag":2535,"props":2572,"children":2573},{},[2574,2583],{"type":38,"tag":2557,"props":2575,"children":2576},{},[2577],{"type":38,"tag":53,"props":2578,"children":2580},{"className":2579},[],[2581],{"type":44,"value":2582},".first()",{"type":38,"tag":2557,"props":2584,"children":2585},{},[2586,2588,2594],{"type":44,"value":2587},"First matched node (or ",{"type":38,"tag":53,"props":2589,"children":2591},{"className":2590},[],[2592],{"type":44,"value":2593},"null",{"type":44,"value":1277},{"type":38,"tag":2535,"props":2596,"children":2597},{},[2598,2607],{"type":38,"tag":2557,"props":2599,"children":2600},{},[2601],{"type":38,"tag":53,"props":2602,"children":2604},{"className":2603},[],[2605],{"type":44,"value":2606},".last()",{"type":38,"tag":2557,"props":2608,"children":2609},{},[2610,2612,2617],{"type":44,"value":2611},"Last matched node (or ",{"type":38,"tag":53,"props":2613,"children":2615},{"className":2614},[],[2616],{"type":44,"value":2593},{"type":44,"value":1277},{"type":38,"tag":2535,"props":2619,"children":2620},{},[2621,2630],{"type":38,"tag":2557,"props":2622,"children":2623},{},[2624],{"type":38,"tag":53,"props":2625,"children":2627},{"className":2626},[],[2628],{"type":44,"value":2629},".toArray()",{"type":38,"tag":2557,"props":2631,"children":2632},{},[2633],{"type":44,"value":2634},"Convert to regular array",{"type":38,"tag":2535,"props":2636,"children":2637},{},[2638,2647],{"type":38,"tag":2557,"props":2639,"children":2640},{},[2641],{"type":38,"tag":53,"props":2642,"children":2644},{"className":2643},[],[2645],{"type":44,"value":2646},".each(fn)",{"type":38,"tag":2557,"props":2648,"children":2649},{},[2650,2652,2658],{"type":44,"value":2651},"Iterate with callback, returns ",{"type":38,"tag":53,"props":2653,"children":2655},{"className":2654},[],[2656],{"type":44,"value":2657},"this",{"type":44,"value":2659}," for chaining",{"type":38,"tag":2535,"props":2661,"children":2662},{},[2663,2672],{"type":38,"tag":2557,"props":2664,"children":2665},{},[2666],{"type":38,"tag":53,"props":2667,"children":2669},{"className":2668},[],[2670],{"type":44,"value":2671},".map(fn)",{"type":38,"tag":2557,"props":2673,"children":2674},{},[2675],{"type":44,"value":2676},"Map to new array",{"type":38,"tag":2535,"props":2678,"children":2679},{},[2680,2689],{"type":38,"tag":2557,"props":2681,"children":2682},{},[2683],{"type":38,"tag":53,"props":2684,"children":2686},{"className":2685},[],[2687],{"type":44,"value":2688},".filter(fn)",{"type":38,"tag":2557,"props":2690,"children":2691},{},[2692],{"type":44,"value":2693},"Filter to new QueryResult",{"type":38,"tag":2535,"props":2695,"children":2696},{},[2697,2706],{"type":38,"tag":2557,"props":2698,"children":2699},{},[2700],{"type":38,"tag":53,"props":2701,"children":2703},{"className":2702},[],[2704],{"type":44,"value":2705},".values(keys)",{"type":38,"tag":2557,"props":2707,"children":2708},{},[2709,2711,2717,2719],{"type":44,"value":2710},"Extract property values: ",{"type":38,"tag":53,"props":2712,"children":2714},{"className":2713},[],[2715],{"type":44,"value":2716},".values(['name', 'x', 'y'])",{"type":44,"value":2718}," → ",{"type":38,"tag":53,"props":2720,"children":2722},{"className":2721},[],[2723],{"type":44,"value":2724},"[{name, x, y}, ...]",{"type":38,"tag":2535,"props":2726,"children":2727},{},[2728,2737],{"type":38,"tag":2557,"props":2729,"children":2730},{},[2731],{"type":38,"tag":53,"props":2732,"children":2734},{"className":2733},[],[2735],{"type":44,"value":2736},".set(props)",{"type":38,"tag":2557,"props":2738,"children":2739},{},[2740,2742,2748],{"type":44,"value":2741},"Set properties on all matched nodes (see ",{"type":38,"tag":53,"props":2743,"children":2745},{"className":2744},[],[2746],{"type":44,"value":2747},"node.set()",{"type":44,"value":2749}," below)",{"type":38,"tag":2535,"props":2751,"children":2752},{},[2753,2762],{"type":38,"tag":2557,"props":2754,"children":2755},{},[2756],{"type":38,"tag":53,"props":2757,"children":2759},{"className":2758},[],[2760],{"type":44,"value":2761},".query(selector)",{"type":38,"tag":2557,"props":2763,"children":2764},{},[2765],{"type":44,"value":2766},"Sub-query within matched nodes",{"type":38,"tag":2535,"props":2768,"children":2769},{},[2770,2779],{"type":38,"tag":2557,"props":2771,"children":2772},{},[2773],{"type":38,"tag":53,"props":2774,"children":2776},{"className":2775},[],[2777],{"type":44,"value":2778},"for...of",{"type":38,"tag":2557,"props":2780,"children":2781},{},[2782,2784,2789],{"type":44,"value":2783},"Iterable — works in ",{"type":38,"tag":53,"props":2785,"children":2787},{"className":2786},[],[2788],{"type":44,"value":1481},{"type":44,"value":2790}," loops",{"type":38,"tag":47,"props":2792,"children":2793},{},[2794,2799,2800,2806,2808,2814,2816,2822],{"type":38,"tag":73,"props":2795,"children":2796},{},[2797],{"type":44,"value":2798},"Scope:",{"type":44,"value":317},{"type":38,"tag":53,"props":2801,"children":2803},{"className":2802},[],[2804],{"type":44,"value":2805},"node.query()",{"type":44,"value":2807}," searches within that node's subtree. To search the whole page: ",{"type":38,"tag":53,"props":2809,"children":2811},{"className":2810},[],[2812],{"type":44,"value":2813},"figma.currentPage.query('...')",{"type":44,"value":2815},". There is no global ",{"type":38,"tag":53,"props":2817,"children":2819},{"className":2818},[],[2820],{"type":44,"value":2821},"figma.query()",{"type":44,"value":68},{"type":38,"tag":47,"props":2824,"children":2825},{},[2826],{"type":38,"tag":73,"props":2827,"children":2828},{},[2829],{"type":44,"value":2830},"Examples:",{"type":38,"tag":1183,"props":2832,"children":2834},{"className":1185,"code":2833,"language":1187,"meta":1188,"style":1188},"\u002F\u002F Recolor all text inside cards\nfigma.currentPage.query('FRAME[name^=Card] TEXT').set({\n  fills: [{type: 'SOLID', color: {r: 0.2, g: 0.2, b: 0.8}}]\n})\n\n\u002F\u002F Get names and positions of all frames\nreturn figma.currentPage.query('FRAME').values(['name', 'x', 'y'])\n\n\u002F\u002F Find the first component named \"Button\"\nconst btn = figma.currentPage.query('COMPONENT[name=Button]').first()\n\n\u002F\u002F Find all instances of a specific component\nfigma.currentPage.query(`INSTANCE[mainComponent=${compId}]`)\n\n\u002F\u002F Find nodes with solid fills using dot-path traversal\nfigma.currentPage.query('[fills.0.type=SOLID]')\n",[2835],{"type":38,"tag":53,"props":2836,"children":2837},{"__ignoreMap":1188},[2838,2846,2907,3031,3043,3050,3058,3169,3176,3185,3257,3265,3274,3339,3347,3356],{"type":38,"tag":1194,"props":2839,"children":2840},{"class":1196,"line":1197},[2841],{"type":38,"tag":1194,"props":2842,"children":2843},{"style":1201},[2844],{"type":44,"value":2845},"\u002F\u002F Recolor all text inside cards\n",{"type":38,"tag":1194,"props":2847,"children":2848},{"class":1196,"line":1207},[2849,2853,2857,2861,2865,2869,2873,2877,2882,2886,2890,2894,2899,2903],{"type":38,"tag":1194,"props":2850,"children":2851},{"style":1217},[2852],{"type":44,"value":8},{"type":38,"tag":1194,"props":2854,"children":2855},{"style":1223},[2856],{"type":44,"value":68},{"type":38,"tag":1194,"props":2858,"children":2859},{"style":1217},[2860],{"type":44,"value":1436},{"type":38,"tag":1194,"props":2862,"children":2863},{"style":1223},[2864],{"type":44,"value":68},{"type":38,"tag":1194,"props":2866,"children":2867},{"style":1255},[2868],{"type":44,"value":2217},{"type":38,"tag":1194,"props":2870,"children":2871},{"style":1217},[2872],{"type":44,"value":1263},{"type":38,"tag":1194,"props":2874,"children":2875},{"style":1223},[2876],{"type":44,"value":2135},{"type":38,"tag":1194,"props":2878,"children":2879},{"style":1309},[2880],{"type":44,"value":2881},"FRAME[name^=Card] TEXT",{"type":38,"tag":1194,"props":2883,"children":2884},{"style":1223},[2885],{"type":44,"value":2135},{"type":38,"tag":1194,"props":2887,"children":2888},{"style":1217},[2889],{"type":44,"value":1277},{"type":38,"tag":1194,"props":2891,"children":2892},{"style":1223},[2893],{"type":44,"value":68},{"type":38,"tag":1194,"props":2895,"children":2896},{"style":1255},[2897],{"type":44,"value":2898},"set",{"type":38,"tag":1194,"props":2900,"children":2901},{"style":1217},[2902],{"type":44,"value":1263},{"type":38,"tag":1194,"props":2904,"children":2905},{"style":1223},[2906],{"type":44,"value":1526},{"type":38,"tag":1194,"props":2908,"children":2909},{"class":1196,"line":1329},[2910,2915,2920,2925,2930,2935,2939,2943,2948,2952,2957,2962,2966,2971,2976,2980,2986,2990,2995,2999,3003,3007,3012,3016,3021,3026],{"type":38,"tag":1194,"props":2911,"children":2912},{"style":1549},[2913],{"type":44,"value":2914},"  fills",{"type":38,"tag":1194,"props":2916,"children":2917},{"style":1223},[2918],{"type":44,"value":2919},":",{"type":38,"tag":1194,"props":2921,"children":2922},{"style":1217},[2923],{"type":44,"value":2924}," [",{"type":38,"tag":1194,"props":2926,"children":2927},{"style":1223},[2928],{"type":44,"value":2929},"{",{"type":38,"tag":1194,"props":2931,"children":2932},{"style":1549},[2933],{"type":44,"value":2934},"type",{"type":38,"tag":1194,"props":2936,"children":2937},{"style":1223},[2938],{"type":44,"value":2919},{"type":38,"tag":1194,"props":2940,"children":2941},{"style":1223},[2942],{"type":44,"value":2126},{"type":38,"tag":1194,"props":2944,"children":2945},{"style":1309},[2946],{"type":44,"value":2947},"SOLID",{"type":38,"tag":1194,"props":2949,"children":2950},{"style":1223},[2951],{"type":44,"value":2135},{"type":38,"tag":1194,"props":2953,"children":2954},{"style":1223},[2955],{"type":44,"value":2956},",",{"type":38,"tag":1194,"props":2958,"children":2959},{"style":1549},[2960],{"type":44,"value":2961}," color",{"type":38,"tag":1194,"props":2963,"children":2964},{"style":1223},[2965],{"type":44,"value":2919},{"type":38,"tag":1194,"props":2967,"children":2968},{"style":1223},[2969],{"type":44,"value":2970}," {",{"type":38,"tag":1194,"props":2972,"children":2973},{"style":1549},[2974],{"type":44,"value":2975},"r",{"type":38,"tag":1194,"props":2977,"children":2978},{"style":1223},[2979],{"type":44,"value":2919},{"type":38,"tag":1194,"props":2981,"children":2983},{"style":2982},"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C",[2984],{"type":44,"value":2985}," 0.2",{"type":38,"tag":1194,"props":2987,"children":2988},{"style":1223},[2989],{"type":44,"value":2956},{"type":38,"tag":1194,"props":2991,"children":2992},{"style":1549},[2993],{"type":44,"value":2994}," g",{"type":38,"tag":1194,"props":2996,"children":2997},{"style":1223},[2998],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3000,"children":3001},{"style":2982},[3002],{"type":44,"value":2985},{"type":38,"tag":1194,"props":3004,"children":3005},{"style":1223},[3006],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3008,"children":3009},{"style":1549},[3010],{"type":44,"value":3011}," b",{"type":38,"tag":1194,"props":3013,"children":3014},{"style":1223},[3015],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3017,"children":3018},{"style":2982},[3019],{"type":44,"value":3020}," 0.8",{"type":38,"tag":1194,"props":3022,"children":3023},{"style":1223},[3024],{"type":44,"value":3025},"}}",{"type":38,"tag":1194,"props":3027,"children":3028},{"style":1217},[3029],{"type":44,"value":3030},"]\n",{"type":38,"tag":1194,"props":3032,"children":3033},{"class":1196,"line":1360},[3034,3039],{"type":38,"tag":1194,"props":3035,"children":3036},{"style":1223},[3037],{"type":44,"value":3038},"}",{"type":38,"tag":1194,"props":3040,"children":3041},{"style":1217},[3042],{"type":44,"value":2174},{"type":38,"tag":1194,"props":3044,"children":3045},{"class":1196,"line":1575},[3046],{"type":38,"tag":1194,"props":3047,"children":3048},{"emptyLinePlaceholder":1588},[3049],{"type":44,"value":1591},{"type":38,"tag":1194,"props":3051,"children":3052},{"class":1196,"line":1584},[3053],{"type":38,"tag":1194,"props":3054,"children":3055},{"style":1201},[3056],{"type":44,"value":3057},"\u002F\u002F Get names and positions of all frames\n",{"type":38,"tag":1194,"props":3059,"children":3060},{"class":1196,"line":1594},[3061,3065,3069,3073,3077,3081,3085,3089,3093,3097,3101,3105,3109,3114,3119,3123,3128,3132,3136,3140,3144,3148,3152,3156,3160,3164],{"type":38,"tag":1194,"props":3062,"children":3063},{"style":1333},[3064],{"type":44,"value":263},{"type":38,"tag":1194,"props":3066,"children":3067},{"style":1217},[3068],{"type":44,"value":1231},{"type":38,"tag":1194,"props":3070,"children":3071},{"style":1223},[3072],{"type":44,"value":68},{"type":38,"tag":1194,"props":3074,"children":3075},{"style":1217},[3076],{"type":44,"value":1436},{"type":38,"tag":1194,"props":3078,"children":3079},{"style":1223},[3080],{"type":44,"value":68},{"type":38,"tag":1194,"props":3082,"children":3083},{"style":1255},[3084],{"type":44,"value":2217},{"type":38,"tag":1194,"props":3086,"children":3087},{"style":1217},[3088],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3090,"children":3091},{"style":1223},[3092],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3094,"children":3095},{"style":1309},[3096],{"type":44,"value":2260},{"type":38,"tag":1194,"props":3098,"children":3099},{"style":1223},[3100],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3102,"children":3103},{"style":1217},[3104],{"type":44,"value":1277},{"type":38,"tag":1194,"props":3106,"children":3107},{"style":1223},[3108],{"type":44,"value":68},{"type":38,"tag":1194,"props":3110,"children":3111},{"style":1255},[3112],{"type":44,"value":3113},"values",{"type":38,"tag":1194,"props":3115,"children":3116},{"style":1217},[3117],{"type":44,"value":3118},"([",{"type":38,"tag":1194,"props":3120,"children":3121},{"style":1223},[3122],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3124,"children":3125},{"style":1309},[3126],{"type":44,"value":3127},"name",{"type":38,"tag":1194,"props":3129,"children":3130},{"style":1223},[3131],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3133,"children":3134},{"style":1223},[3135],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3137,"children":3138},{"style":1223},[3139],{"type":44,"value":2126},{"type":38,"tag":1194,"props":3141,"children":3142},{"style":1309},[3143],{"type":44,"value":733},{"type":38,"tag":1194,"props":3145,"children":3146},{"style":1223},[3147],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3149,"children":3150},{"style":1223},[3151],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3153,"children":3154},{"style":1223},[3155],{"type":44,"value":2126},{"type":38,"tag":1194,"props":3157,"children":3158},{"style":1309},[3159],{"type":44,"value":740},{"type":38,"tag":1194,"props":3161,"children":3162},{"style":1223},[3163],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3165,"children":3166},{"style":1217},[3167],{"type":44,"value":3168},"])\n",{"type":38,"tag":1194,"props":3170,"children":3171},{"class":1196,"line":1603},[3172],{"type":38,"tag":1194,"props":3173,"children":3174},{"emptyLinePlaceholder":1588},[3175],{"type":44,"value":1591},{"type":38,"tag":1194,"props":3177,"children":3179},{"class":1196,"line":3178},9,[3180],{"type":38,"tag":1194,"props":3181,"children":3182},{"style":1201},[3183],{"type":44,"value":3184},"\u002F\u002F Find the first component named \"Button\"\n",{"type":38,"tag":1194,"props":3186,"children":3188},{"class":1196,"line":3187},10,[3189,3193,3198,3202,3206,3210,3214,3218,3222,3226,3230,3235,3239,3243,3247,3252],{"type":38,"tag":1194,"props":3190,"children":3191},{"style":1211},[3192],{"type":44,"value":1214},{"type":38,"tag":1194,"props":3194,"children":3195},{"style":1217},[3196],{"type":44,"value":3197}," btn ",{"type":38,"tag":1194,"props":3199,"children":3200},{"style":1223},[3201],{"type":44,"value":1226},{"type":38,"tag":1194,"props":3203,"children":3204},{"style":1217},[3205],{"type":44,"value":1231},{"type":38,"tag":1194,"props":3207,"children":3208},{"style":1223},[3209],{"type":44,"value":68},{"type":38,"tag":1194,"props":3211,"children":3212},{"style":1217},[3213],{"type":44,"value":1436},{"type":38,"tag":1194,"props":3215,"children":3216},{"style":1223},[3217],{"type":44,"value":68},{"type":38,"tag":1194,"props":3219,"children":3220},{"style":1255},[3221],{"type":44,"value":2217},{"type":38,"tag":1194,"props":3223,"children":3224},{"style":1217},[3225],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3227,"children":3228},{"style":1223},[3229],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3231,"children":3232},{"style":1309},[3233],{"type":44,"value":3234},"COMPONENT[name=Button]",{"type":38,"tag":1194,"props":3236,"children":3237},{"style":1223},[3238],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3240,"children":3241},{"style":1217},[3242],{"type":44,"value":1277},{"type":38,"tag":1194,"props":3244,"children":3245},{"style":1223},[3246],{"type":44,"value":68},{"type":38,"tag":1194,"props":3248,"children":3249},{"style":1255},[3250],{"type":44,"value":3251},"first",{"type":38,"tag":1194,"props":3253,"children":3254},{"style":1217},[3255],{"type":44,"value":3256},"()\n",{"type":38,"tag":1194,"props":3258,"children":3260},{"class":1196,"line":3259},11,[3261],{"type":38,"tag":1194,"props":3262,"children":3263},{"emptyLinePlaceholder":1588},[3264],{"type":44,"value":1591},{"type":38,"tag":1194,"props":3266,"children":3268},{"class":1196,"line":3267},12,[3269],{"type":38,"tag":1194,"props":3270,"children":3271},{"style":1201},[3272],{"type":44,"value":3273},"\u002F\u002F Find all instances of a specific component\n",{"type":38,"tag":1194,"props":3275,"children":3277},{"class":1196,"line":3276},13,[3278,3282,3286,3290,3294,3298,3302,3307,3312,3317,3322,3326,3331,3335],{"type":38,"tag":1194,"props":3279,"children":3280},{"style":1217},[3281],{"type":44,"value":8},{"type":38,"tag":1194,"props":3283,"children":3284},{"style":1223},[3285],{"type":44,"value":68},{"type":38,"tag":1194,"props":3287,"children":3288},{"style":1217},[3289],{"type":44,"value":1436},{"type":38,"tag":1194,"props":3291,"children":3292},{"style":1223},[3293],{"type":44,"value":68},{"type":38,"tag":1194,"props":3295,"children":3296},{"style":1255},[3297],{"type":44,"value":2217},{"type":38,"tag":1194,"props":3299,"children":3300},{"style":1217},[3301],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3303,"children":3304},{"style":1223},[3305],{"type":44,"value":3306},"`",{"type":38,"tag":1194,"props":3308,"children":3309},{"style":1309},[3310],{"type":44,"value":3311},"INSTANCE[mainComponent=",{"type":38,"tag":1194,"props":3313,"children":3314},{"style":1223},[3315],{"type":44,"value":3316},"${",{"type":38,"tag":1194,"props":3318,"children":3319},{"style":1217},[3320],{"type":44,"value":3321},"compId",{"type":38,"tag":1194,"props":3323,"children":3324},{"style":1223},[3325],{"type":44,"value":3038},{"type":38,"tag":1194,"props":3327,"children":3328},{"style":1309},[3329],{"type":44,"value":3330},"]",{"type":38,"tag":1194,"props":3332,"children":3333},{"style":1223},[3334],{"type":44,"value":3306},{"type":38,"tag":1194,"props":3336,"children":3337},{"style":1217},[3338],{"type":44,"value":2174},{"type":38,"tag":1194,"props":3340,"children":3342},{"class":1196,"line":3341},14,[3343],{"type":38,"tag":1194,"props":3344,"children":3345},{"emptyLinePlaceholder":1588},[3346],{"type":44,"value":1591},{"type":38,"tag":1194,"props":3348,"children":3350},{"class":1196,"line":3349},15,[3351],{"type":38,"tag":1194,"props":3352,"children":3353},{"style":1201},[3354],{"type":44,"value":3355},"\u002F\u002F Find nodes with solid fills using dot-path traversal\n",{"type":38,"tag":1194,"props":3357,"children":3359},{"class":1196,"line":3358},16,[3360,3364,3368,3372,3376,3380,3384,3388,3392,3396],{"type":38,"tag":1194,"props":3361,"children":3362},{"style":1217},[3363],{"type":44,"value":8},{"type":38,"tag":1194,"props":3365,"children":3366},{"style":1223},[3367],{"type":44,"value":68},{"type":38,"tag":1194,"props":3369,"children":3370},{"style":1217},[3371],{"type":44,"value":1436},{"type":38,"tag":1194,"props":3373,"children":3374},{"style":1223},[3375],{"type":44,"value":68},{"type":38,"tag":1194,"props":3377,"children":3378},{"style":1255},[3379],{"type":44,"value":2217},{"type":38,"tag":1194,"props":3381,"children":3382},{"style":1217},[3383],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3385,"children":3386},{"style":1223},[3387],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3389,"children":3390},{"style":1309},[3391],{"type":44,"value":2368},{"type":38,"tag":1194,"props":3393,"children":3394},{"style":1223},[3395],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3397,"children":3398},{"style":1217},[3399],{"type":44,"value":2174},{"type":38,"tag":1138,"props":3401,"children":3403},{"id":3402},"nodesetprops-batch-property-updates",[3404,3410],{"type":38,"tag":53,"props":3405,"children":3407},{"className":3406},[],[3408],{"type":44,"value":3409},"node.set(props)",{"type":44,"value":3411}," — batch property updates",{"type":38,"tag":47,"props":3413,"children":3414},{},[3415,3417,3422],{"type":44,"value":3416},"Set multiple properties in one call. Returns ",{"type":38,"tag":53,"props":3418,"children":3420},{"className":3419},[],[3421],{"type":44,"value":2657},{"type":44,"value":3423}," for chaining.",{"type":38,"tag":1183,"props":3425,"children":3427},{"className":1185,"code":3426,"language":1187,"meta":1188,"style":1188},"\u002F\u002F BEFORE — one line per property\nframe.opacity = 0.5\nframe.cornerRadius = 8\nframe.name = \"Card\"\n\n\u002F\u002F AFTER — single call\nframe.set({ opacity: 0.5, cornerRadius: 8, name: \"Card\" })\n",[3428],{"type":38,"tag":53,"props":3429,"children":3430},{"__ignoreMap":1188},[3431,3439,3464,3489,3522,3529,3537],{"type":38,"tag":1194,"props":3432,"children":3433},{"class":1196,"line":1197},[3434],{"type":38,"tag":1194,"props":3435,"children":3436},{"style":1201},[3437],{"type":44,"value":3438},"\u002F\u002F BEFORE — one line per property\n",{"type":38,"tag":1194,"props":3440,"children":3441},{"class":1196,"line":1207},[3442,3446,3450,3455,3459],{"type":38,"tag":1194,"props":3443,"children":3444},{"style":1217},[3445],{"type":44,"value":811},{"type":38,"tag":1194,"props":3447,"children":3448},{"style":1223},[3449],{"type":44,"value":68},{"type":38,"tag":1194,"props":3451,"children":3452},{"style":1217},[3453],{"type":44,"value":3454},"opacity ",{"type":38,"tag":1194,"props":3456,"children":3457},{"style":1223},[3458],{"type":44,"value":1226},{"type":38,"tag":1194,"props":3460,"children":3461},{"style":2982},[3462],{"type":44,"value":3463}," 0.5\n",{"type":38,"tag":1194,"props":3465,"children":3466},{"class":1196,"line":1329},[3467,3471,3475,3480,3484],{"type":38,"tag":1194,"props":3468,"children":3469},{"style":1217},[3470],{"type":44,"value":811},{"type":38,"tag":1194,"props":3472,"children":3473},{"style":1223},[3474],{"type":44,"value":68},{"type":38,"tag":1194,"props":3476,"children":3477},{"style":1217},[3478],{"type":44,"value":3479},"cornerRadius ",{"type":38,"tag":1194,"props":3481,"children":3482},{"style":1223},[3483],{"type":44,"value":1226},{"type":38,"tag":1194,"props":3485,"children":3486},{"style":2982},[3487],{"type":44,"value":3488}," 8\n",{"type":38,"tag":1194,"props":3490,"children":3491},{"class":1196,"line":1360},[3492,3496,3500,3504,3508,3512,3517],{"type":38,"tag":1194,"props":3493,"children":3494},{"style":1217},[3495],{"type":44,"value":811},{"type":38,"tag":1194,"props":3497,"children":3498},{"style":1223},[3499],{"type":44,"value":68},{"type":38,"tag":1194,"props":3501,"children":3502},{"style":1217},[3503],{"type":44,"value":1296},{"type":38,"tag":1194,"props":3505,"children":3506},{"style":1223},[3507],{"type":44,"value":1226},{"type":38,"tag":1194,"props":3509,"children":3510},{"style":1223},[3511],{"type":44,"value":1306},{"type":38,"tag":1194,"props":3513,"children":3514},{"style":1309},[3515],{"type":44,"value":3516},"Card",{"type":38,"tag":1194,"props":3518,"children":3519},{"style":1223},[3520],{"type":44,"value":3521},"\"\n",{"type":38,"tag":1194,"props":3523,"children":3524},{"class":1196,"line":1575},[3525],{"type":38,"tag":1194,"props":3526,"children":3527},{"emptyLinePlaceholder":1588},[3528],{"type":44,"value":1591},{"type":38,"tag":1194,"props":3530,"children":3531},{"class":1196,"line":1584},[3532],{"type":38,"tag":1194,"props":3533,"children":3534},{"style":1201},[3535],{"type":44,"value":3536},"\u002F\u002F AFTER — single call\n",{"type":38,"tag":1194,"props":3538,"children":3539},{"class":1196,"line":1594},[3540,3544,3548,3552,3556,3560,3565,3569,3574,3578,3583,3587,3592,3596,3601,3605,3609,3613,3617,3622],{"type":38,"tag":1194,"props":3541,"children":3542},{"style":1217},[3543],{"type":44,"value":811},{"type":38,"tag":1194,"props":3545,"children":3546},{"style":1223},[3547],{"type":44,"value":68},{"type":38,"tag":1194,"props":3549,"children":3550},{"style":1255},[3551],{"type":44,"value":2898},{"type":38,"tag":1194,"props":3553,"children":3554},{"style":1217},[3555],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3557,"children":3558},{"style":1223},[3559],{"type":44,"value":2929},{"type":38,"tag":1194,"props":3561,"children":3562},{"style":1549},[3563],{"type":44,"value":3564}," opacity",{"type":38,"tag":1194,"props":3566,"children":3567},{"style":1223},[3568],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3570,"children":3571},{"style":2982},[3572],{"type":44,"value":3573}," 0.5",{"type":38,"tag":1194,"props":3575,"children":3576},{"style":1223},[3577],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3579,"children":3580},{"style":1549},[3581],{"type":44,"value":3582}," cornerRadius",{"type":38,"tag":1194,"props":3584,"children":3585},{"style":1223},[3586],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3588,"children":3589},{"style":2982},[3590],{"type":44,"value":3591}," 8",{"type":38,"tag":1194,"props":3593,"children":3594},{"style":1223},[3595],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3597,"children":3598},{"style":1549},[3599],{"type":44,"value":3600}," name",{"type":38,"tag":1194,"props":3602,"children":3603},{"style":1223},[3604],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3606,"children":3607},{"style":1223},[3608],{"type":44,"value":1306},{"type":38,"tag":1194,"props":3610,"children":3611},{"style":1309},[3612],{"type":44,"value":3516},{"type":38,"tag":1194,"props":3614,"children":3615},{"style":1223},[3616],{"type":44,"value":1317},{"type":38,"tag":1194,"props":3618,"children":3619},{"style":1223},[3620],{"type":44,"value":3621}," }",{"type":38,"tag":1194,"props":3623,"children":3624},{"style":1217},[3625],{"type":44,"value":2174},{"type":38,"tag":47,"props":3627,"children":3628},{},[3629,3634,3635,3641,3643,3649,3650,3656,3658,3664,3666,3671],{"type":38,"tag":73,"props":3630,"children":3631},{},[3632],{"type":44,"value":3633},"Priority key ordering:",{"type":44,"value":317},{"type":38,"tag":53,"props":3636,"children":3638},{"className":3637},[],[3639],{"type":44,"value":3640},"layoutMode",{"type":44,"value":3642}," is always applied before other properties (like ",{"type":38,"tag":53,"props":3644,"children":3646},{"className":3645},[],[3647],{"type":44,"value":3648},"width",{"type":44,"value":681},{"type":38,"tag":53,"props":3651,"children":3653},{"className":3652},[],[3654],{"type":44,"value":3655},"height",{"type":44,"value":3657},") regardless of object key order. This prevents the common bug where ",{"type":38,"tag":53,"props":3659,"children":3661},{"className":3660},[],[3662],{"type":44,"value":3663},"resize()",{"type":44,"value":3665}," behaves differently depending on whether ",{"type":38,"tag":53,"props":3667,"children":3669},{"className":3668},[],[3670],{"type":44,"value":3640},{"type":44,"value":3672}," is set.",{"type":38,"tag":47,"props":3674,"children":3675},{},[3676,3681,3682,3687,3688,3693,3695,3701,3703,3709,3711,3717],{"type":38,"tag":73,"props":3677,"children":3678},{},[3679],{"type":44,"value":3680},"Width\u002Fheight handling:",{"type":44,"value":317},{"type":38,"tag":53,"props":3683,"children":3685},{"className":3684},[],[3686],{"type":44,"value":3648},{"type":44,"value":291},{"type":38,"tag":53,"props":3689,"children":3691},{"className":3690},[],[3692],{"type":44,"value":3655},{"type":44,"value":3694}," are routed through ",{"type":38,"tag":53,"props":3696,"children":3698},{"className":3697},[],[3699],{"type":44,"value":3700},"node.resize()",{"type":44,"value":3702}," automatically — setting ",{"type":38,"tag":53,"props":3704,"children":3706},{"className":3705},[],[3707],{"type":44,"value":3708},"{ width: 200 }",{"type":44,"value":3710}," calls ",{"type":38,"tag":53,"props":3712,"children":3714},{"className":3713},[],[3715],{"type":44,"value":3716},"resize(200, currentHeight)",{"type":44,"value":68},{"type":38,"tag":47,"props":3719,"children":3720},{},[3721],{"type":38,"tag":73,"props":3722,"children":3723},{},[3724],{"type":44,"value":3725},"Chaining with query:",{"type":38,"tag":1183,"props":3727,"children":3729},{"className":1185,"code":3728,"language":1187,"meta":1188,"style":1188},"\u002F\u002F Find all rectangles named \"Divider\" and update them\nfigma.currentPage.query('RECTANGLE[name=Divider]').set({\n  fills: [{type: 'SOLID', color: {r: 0.9, g: 0.9, b: 0.9}}],\n  cornerRadius: 2\n})\n",[3730],{"type":38,"tag":53,"props":3731,"children":3732},{"__ignoreMap":1188},[3733,3741,3801,3914,3931],{"type":38,"tag":1194,"props":3734,"children":3735},{"class":1196,"line":1197},[3736],{"type":38,"tag":1194,"props":3737,"children":3738},{"style":1201},[3739],{"type":44,"value":3740},"\u002F\u002F Find all rectangles named \"Divider\" and update them\n",{"type":38,"tag":1194,"props":3742,"children":3743},{"class":1196,"line":1207},[3744,3748,3752,3756,3760,3764,3768,3772,3777,3781,3785,3789,3793,3797],{"type":38,"tag":1194,"props":3745,"children":3746},{"style":1217},[3747],{"type":44,"value":8},{"type":38,"tag":1194,"props":3749,"children":3750},{"style":1223},[3751],{"type":44,"value":68},{"type":38,"tag":1194,"props":3753,"children":3754},{"style":1217},[3755],{"type":44,"value":1436},{"type":38,"tag":1194,"props":3757,"children":3758},{"style":1223},[3759],{"type":44,"value":68},{"type":38,"tag":1194,"props":3761,"children":3762},{"style":1255},[3763],{"type":44,"value":2217},{"type":38,"tag":1194,"props":3765,"children":3766},{"style":1217},[3767],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3769,"children":3770},{"style":1223},[3771],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3773,"children":3774},{"style":1309},[3775],{"type":44,"value":3776},"RECTANGLE[name=Divider]",{"type":38,"tag":1194,"props":3778,"children":3779},{"style":1223},[3780],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3782,"children":3783},{"style":1217},[3784],{"type":44,"value":1277},{"type":38,"tag":1194,"props":3786,"children":3787},{"style":1223},[3788],{"type":44,"value":68},{"type":38,"tag":1194,"props":3790,"children":3791},{"style":1255},[3792],{"type":44,"value":2898},{"type":38,"tag":1194,"props":3794,"children":3795},{"style":1217},[3796],{"type":44,"value":1263},{"type":38,"tag":1194,"props":3798,"children":3799},{"style":1223},[3800],{"type":44,"value":1526},{"type":38,"tag":1194,"props":3802,"children":3803},{"class":1196,"line":1329},[3804,3808,3812,3816,3820,3824,3828,3832,3836,3840,3844,3848,3852,3856,3860,3864,3869,3873,3877,3881,3885,3889,3893,3897,3901,3905,3909],{"type":38,"tag":1194,"props":3805,"children":3806},{"style":1549},[3807],{"type":44,"value":2914},{"type":38,"tag":1194,"props":3809,"children":3810},{"style":1223},[3811],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3813,"children":3814},{"style":1217},[3815],{"type":44,"value":2924},{"type":38,"tag":1194,"props":3817,"children":3818},{"style":1223},[3819],{"type":44,"value":2929},{"type":38,"tag":1194,"props":3821,"children":3822},{"style":1549},[3823],{"type":44,"value":2934},{"type":38,"tag":1194,"props":3825,"children":3826},{"style":1223},[3827],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3829,"children":3830},{"style":1223},[3831],{"type":44,"value":2126},{"type":38,"tag":1194,"props":3833,"children":3834},{"style":1309},[3835],{"type":44,"value":2947},{"type":38,"tag":1194,"props":3837,"children":3838},{"style":1223},[3839],{"type":44,"value":2135},{"type":38,"tag":1194,"props":3841,"children":3842},{"style":1223},[3843],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3845,"children":3846},{"style":1549},[3847],{"type":44,"value":2961},{"type":38,"tag":1194,"props":3849,"children":3850},{"style":1223},[3851],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3853,"children":3854},{"style":1223},[3855],{"type":44,"value":2970},{"type":38,"tag":1194,"props":3857,"children":3858},{"style":1549},[3859],{"type":44,"value":2975},{"type":38,"tag":1194,"props":3861,"children":3862},{"style":1223},[3863],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3865,"children":3866},{"style":2982},[3867],{"type":44,"value":3868}," 0.9",{"type":38,"tag":1194,"props":3870,"children":3871},{"style":1223},[3872],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3874,"children":3875},{"style":1549},[3876],{"type":44,"value":2994},{"type":38,"tag":1194,"props":3878,"children":3879},{"style":1223},[3880],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3882,"children":3883},{"style":2982},[3884],{"type":44,"value":3868},{"type":38,"tag":1194,"props":3886,"children":3887},{"style":1223},[3888],{"type":44,"value":2956},{"type":38,"tag":1194,"props":3890,"children":3891},{"style":1549},[3892],{"type":44,"value":3011},{"type":38,"tag":1194,"props":3894,"children":3895},{"style":1223},[3896],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3898,"children":3899},{"style":2982},[3900],{"type":44,"value":3868},{"type":38,"tag":1194,"props":3902,"children":3903},{"style":1223},[3904],{"type":44,"value":3025},{"type":38,"tag":1194,"props":3906,"children":3907},{"style":1217},[3908],{"type":44,"value":3330},{"type":38,"tag":1194,"props":3910,"children":3911},{"style":1223},[3912],{"type":44,"value":3913},",\n",{"type":38,"tag":1194,"props":3915,"children":3916},{"class":1196,"line":1360},[3917,3922,3926],{"type":38,"tag":1194,"props":3918,"children":3919},{"style":1549},[3920],{"type":44,"value":3921},"  cornerRadius",{"type":38,"tag":1194,"props":3923,"children":3924},{"style":1223},[3925],{"type":44,"value":2919},{"type":38,"tag":1194,"props":3927,"children":3928},{"style":2982},[3929],{"type":44,"value":3930}," 2\n",{"type":38,"tag":1194,"props":3932,"children":3933},{"class":1196,"line":1575},[3934,3938],{"type":38,"tag":1194,"props":3935,"children":3936},{"style":1223},[3937],{"type":44,"value":3038},{"type":38,"tag":1194,"props":3939,"children":3940},{"style":1217},[3941],{"type":44,"value":2174},{"type":38,"tag":1138,"props":3943,"children":3945},{"id":3944},"figmacreateautolayoutdirection-props-auto-layout-frames",[3946,3952],{"type":38,"tag":53,"props":3947,"children":3949},{"className":3948},[],[3950],{"type":44,"value":3951},"figma.createAutoLayout(direction?, props?)",{"type":44,"value":3953}," — auto-layout frames",{"type":38,"tag":47,"props":3955,"children":3956},{},[3957,3959],{"type":44,"value":3958},"Creates a frame with auto-layout already enabled and both axes hugging content. ",{"type":38,"tag":73,"props":3960,"children":3961},{},[3962],{"type":44,"value":3963},"This is the default container whenever children have a structural relationship to each other (see Rule 12a).",{"type":38,"tag":1183,"props":3965,"children":3967},{"className":1185,"code":3966,"language":1187,"meta":1188,"style":1188},"\u002F\u002F BEFORE — manual setup, easy to get ordering wrong\nconst frame = figma.createFrame()\nframe.layoutMode = 'VERTICAL'\nframe.primaryAxisSizingMode = 'AUTO'\nframe.counterAxisSizingMode = 'AUTO'\nframe.layoutSizingHorizontal = 'HUG'\nframe.layoutSizingVertical = 'HUG'\n\n\u002F\u002F AFTER — one call, layout ready\nconst frame = figma.createAutoLayout('VERTICAL')\n",[3968],{"type":38,"tag":53,"props":3969,"children":3970},{"__ignoreMap":1188},[3971,3979,4012,4046,4079,4111,4143,4175,4182,4190],{"type":38,"tag":1194,"props":3972,"children":3973},{"class":1196,"line":1197},[3974],{"type":38,"tag":1194,"props":3975,"children":3976},{"style":1201},[3977],{"type":44,"value":3978},"\u002F\u002F BEFORE — manual setup, easy to get ordering wrong\n",{"type":38,"tag":1194,"props":3980,"children":3981},{"class":1196,"line":1207},[3982,3986,3991,3995,3999,4003,4008],{"type":38,"tag":1194,"props":3983,"children":3984},{"style":1211},[3985],{"type":44,"value":1214},{"type":38,"tag":1194,"props":3987,"children":3988},{"style":1217},[3989],{"type":44,"value":3990}," frame ",{"type":38,"tag":1194,"props":3992,"children":3993},{"style":1223},[3994],{"type":44,"value":1226},{"type":38,"tag":1194,"props":3996,"children":3997},{"style":1217},[3998],{"type":44,"value":1231},{"type":38,"tag":1194,"props":4000,"children":4001},{"style":1223},[4002],{"type":44,"value":68},{"type":38,"tag":1194,"props":4004,"children":4005},{"style":1255},[4006],{"type":44,"value":4007},"createFrame",{"type":38,"tag":1194,"props":4009,"children":4010},{"style":1217},[4011],{"type":44,"value":3256},{"type":38,"tag":1194,"props":4013,"children":4014},{"class":1196,"line":1329},[4015,4019,4023,4028,4032,4036,4041],{"type":38,"tag":1194,"props":4016,"children":4017},{"style":1217},[4018],{"type":44,"value":811},{"type":38,"tag":1194,"props":4020,"children":4021},{"style":1223},[4022],{"type":44,"value":68},{"type":38,"tag":1194,"props":4024,"children":4025},{"style":1217},[4026],{"type":44,"value":4027},"layoutMode ",{"type":38,"tag":1194,"props":4029,"children":4030},{"style":1223},[4031],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4033,"children":4034},{"style":1223},[4035],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4037,"children":4038},{"style":1309},[4039],{"type":44,"value":4040},"VERTICAL",{"type":38,"tag":1194,"props":4042,"children":4043},{"style":1223},[4044],{"type":44,"value":4045},"'\n",{"type":38,"tag":1194,"props":4047,"children":4048},{"class":1196,"line":1360},[4049,4053,4057,4062,4066,4070,4075],{"type":38,"tag":1194,"props":4050,"children":4051},{"style":1217},[4052],{"type":44,"value":811},{"type":38,"tag":1194,"props":4054,"children":4055},{"style":1223},[4056],{"type":44,"value":68},{"type":38,"tag":1194,"props":4058,"children":4059},{"style":1217},[4060],{"type":44,"value":4061},"primaryAxisSizingMode ",{"type":38,"tag":1194,"props":4063,"children":4064},{"style":1223},[4065],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4067,"children":4068},{"style":1223},[4069],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4071,"children":4072},{"style":1309},[4073],{"type":44,"value":4074},"AUTO",{"type":38,"tag":1194,"props":4076,"children":4077},{"style":1223},[4078],{"type":44,"value":4045},{"type":38,"tag":1194,"props":4080,"children":4081},{"class":1196,"line":1575},[4082,4086,4090,4095,4099,4103,4107],{"type":38,"tag":1194,"props":4083,"children":4084},{"style":1217},[4085],{"type":44,"value":811},{"type":38,"tag":1194,"props":4087,"children":4088},{"style":1223},[4089],{"type":44,"value":68},{"type":38,"tag":1194,"props":4091,"children":4092},{"style":1217},[4093],{"type":44,"value":4094},"counterAxisSizingMode ",{"type":38,"tag":1194,"props":4096,"children":4097},{"style":1223},[4098],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4100,"children":4101},{"style":1223},[4102],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4104,"children":4105},{"style":1309},[4106],{"type":44,"value":4074},{"type":38,"tag":1194,"props":4108,"children":4109},{"style":1223},[4110],{"type":44,"value":4045},{"type":38,"tag":1194,"props":4112,"children":4113},{"class":1196,"line":1584},[4114,4118,4122,4127,4131,4135,4139],{"type":38,"tag":1194,"props":4115,"children":4116},{"style":1217},[4117],{"type":44,"value":811},{"type":38,"tag":1194,"props":4119,"children":4120},{"style":1223},[4121],{"type":44,"value":68},{"type":38,"tag":1194,"props":4123,"children":4124},{"style":1217},[4125],{"type":44,"value":4126},"layoutSizingHorizontal ",{"type":38,"tag":1194,"props":4128,"children":4129},{"style":1223},[4130],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4132,"children":4133},{"style":1223},[4134],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4136,"children":4137},{"style":1309},[4138],{"type":44,"value":641},{"type":38,"tag":1194,"props":4140,"children":4141},{"style":1223},[4142],{"type":44,"value":4045},{"type":38,"tag":1194,"props":4144,"children":4145},{"class":1196,"line":1594},[4146,4150,4154,4159,4163,4167,4171],{"type":38,"tag":1194,"props":4147,"children":4148},{"style":1217},[4149],{"type":44,"value":811},{"type":38,"tag":1194,"props":4151,"children":4152},{"style":1223},[4153],{"type":44,"value":68},{"type":38,"tag":1194,"props":4155,"children":4156},{"style":1217},[4157],{"type":44,"value":4158},"layoutSizingVertical ",{"type":38,"tag":1194,"props":4160,"children":4161},{"style":1223},[4162],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4164,"children":4165},{"style":1223},[4166],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4168,"children":4169},{"style":1309},[4170],{"type":44,"value":641},{"type":38,"tag":1194,"props":4172,"children":4173},{"style":1223},[4174],{"type":44,"value":4045},{"type":38,"tag":1194,"props":4176,"children":4177},{"class":1196,"line":1603},[4178],{"type":38,"tag":1194,"props":4179,"children":4180},{"emptyLinePlaceholder":1588},[4181],{"type":44,"value":1591},{"type":38,"tag":1194,"props":4183,"children":4184},{"class":1196,"line":3178},[4185],{"type":38,"tag":1194,"props":4186,"children":4187},{"style":1201},[4188],{"type":44,"value":4189},"\u002F\u002F AFTER — one call, layout ready\n",{"type":38,"tag":1194,"props":4191,"children":4192},{"class":1196,"line":3187},[4193,4197,4201,4205,4209,4213,4218,4222,4226,4230,4234],{"type":38,"tag":1194,"props":4194,"children":4195},{"style":1211},[4196],{"type":44,"value":1214},{"type":38,"tag":1194,"props":4198,"children":4199},{"style":1217},[4200],{"type":44,"value":3990},{"type":38,"tag":1194,"props":4202,"children":4203},{"style":1223},[4204],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4206,"children":4207},{"style":1217},[4208],{"type":44,"value":1231},{"type":38,"tag":1194,"props":4210,"children":4211},{"style":1223},[4212],{"type":44,"value":68},{"type":38,"tag":1194,"props":4214,"children":4215},{"style":1255},[4216],{"type":44,"value":4217},"createAutoLayout",{"type":38,"tag":1194,"props":4219,"children":4220},{"style":1217},[4221],{"type":44,"value":1263},{"type":38,"tag":1194,"props":4223,"children":4224},{"style":1223},[4225],{"type":44,"value":2135},{"type":38,"tag":1194,"props":4227,"children":4228},{"style":1309},[4229],{"type":44,"value":4040},{"type":38,"tag":1194,"props":4231,"children":4232},{"style":1223},[4233],{"type":44,"value":2135},{"type":38,"tag":1194,"props":4235,"children":4236},{"style":1217},[4237],{"type":44,"value":2174},{"type":38,"tag":47,"props":4239,"children":4240},{},[4241,4243,4249],{"type":44,"value":4242},"Children can immediately use ",{"type":38,"tag":53,"props":4244,"children":4246},{"className":4245},[],[4247],{"type":44,"value":4248},"layoutSizingHorizontal\u002FVertical = 'FILL'",{"type":44,"value":4250}," after being appended — no need to set sizing modes manually.",{"type":38,"tag":47,"props":4252,"children":4253},{},[4254],{"type":44,"value":4255},"Accepts an optional props object as the first or second argument:",{"type":38,"tag":1183,"props":4257,"children":4259},{"className":1185,"code":4258,"language":1187,"meta":1188,"style":1188},"figma.createAutoLayout({ name: 'Card', itemSpacing: 12 })               \u002F\u002F HORIZONTAL + props\nfigma.createAutoLayout('VERTICAL', { name: 'Column', itemSpacing: 8 })  \u002F\u002F VERTICAL + props\n",[4260],{"type":38,"tag":53,"props":4261,"children":4262},{"__ignoreMap":1188},[4263,4338],{"type":38,"tag":1194,"props":4264,"children":4265},{"class":1196,"line":1197},[4266,4270,4274,4278,4282,4286,4290,4294,4298,4302,4306,4310,4315,4319,4324,4328,4333],{"type":38,"tag":1194,"props":4267,"children":4268},{"style":1217},[4269],{"type":44,"value":8},{"type":38,"tag":1194,"props":4271,"children":4272},{"style":1223},[4273],{"type":44,"value":68},{"type":38,"tag":1194,"props":4275,"children":4276},{"style":1255},[4277],{"type":44,"value":4217},{"type":38,"tag":1194,"props":4279,"children":4280},{"style":1217},[4281],{"type":44,"value":1263},{"type":38,"tag":1194,"props":4283,"children":4284},{"style":1223},[4285],{"type":44,"value":2929},{"type":38,"tag":1194,"props":4287,"children":4288},{"style":1549},[4289],{"type":44,"value":3600},{"type":38,"tag":1194,"props":4291,"children":4292},{"style":1223},[4293],{"type":44,"value":2919},{"type":38,"tag":1194,"props":4295,"children":4296},{"style":1223},[4297],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4299,"children":4300},{"style":1309},[4301],{"type":44,"value":3516},{"type":38,"tag":1194,"props":4303,"children":4304},{"style":1223},[4305],{"type":44,"value":2135},{"type":38,"tag":1194,"props":4307,"children":4308},{"style":1223},[4309],{"type":44,"value":2956},{"type":38,"tag":1194,"props":4311,"children":4312},{"style":1549},[4313],{"type":44,"value":4314}," itemSpacing",{"type":38,"tag":1194,"props":4316,"children":4317},{"style":1223},[4318],{"type":44,"value":2919},{"type":38,"tag":1194,"props":4320,"children":4321},{"style":2982},[4322],{"type":44,"value":4323}," 12",{"type":38,"tag":1194,"props":4325,"children":4326},{"style":1223},[4327],{"type":44,"value":3621},{"type":38,"tag":1194,"props":4329,"children":4330},{"style":1217},[4331],{"type":44,"value":4332},")               ",{"type":38,"tag":1194,"props":4334,"children":4335},{"style":1201},[4336],{"type":44,"value":4337},"\u002F\u002F HORIZONTAL + props\n",{"type":38,"tag":1194,"props":4339,"children":4340},{"class":1196,"line":1207},[4341,4345,4349,4353,4357,4361,4365,4369,4373,4377,4381,4385,4389,4394,4398,4402,4406,4410,4414,4418,4423],{"type":38,"tag":1194,"props":4342,"children":4343},{"style":1217},[4344],{"type":44,"value":8},{"type":38,"tag":1194,"props":4346,"children":4347},{"style":1223},[4348],{"type":44,"value":68},{"type":38,"tag":1194,"props":4350,"children":4351},{"style":1255},[4352],{"type":44,"value":4217},{"type":38,"tag":1194,"props":4354,"children":4355},{"style":1217},[4356],{"type":44,"value":1263},{"type":38,"tag":1194,"props":4358,"children":4359},{"style":1223},[4360],{"type":44,"value":2135},{"type":38,"tag":1194,"props":4362,"children":4363},{"style":1309},[4364],{"type":44,"value":4040},{"type":38,"tag":1194,"props":4366,"children":4367},{"style":1223},[4368],{"type":44,"value":2135},{"type":38,"tag":1194,"props":4370,"children":4371},{"style":1223},[4372],{"type":44,"value":2956},{"type":38,"tag":1194,"props":4374,"children":4375},{"style":1223},[4376],{"type":44,"value":2970},{"type":38,"tag":1194,"props":4378,"children":4379},{"style":1549},[4380],{"type":44,"value":3600},{"type":38,"tag":1194,"props":4382,"children":4383},{"style":1223},[4384],{"type":44,"value":2919},{"type":38,"tag":1194,"props":4386,"children":4387},{"style":1223},[4388],{"type":44,"value":2126},{"type":38,"tag":1194,"props":4390,"children":4391},{"style":1309},[4392],{"type":44,"value":4393},"Column",{"type":38,"tag":1194,"props":4395,"children":4396},{"style":1223},[4397],{"type":44,"value":2135},{"type":38,"tag":1194,"props":4399,"children":4400},{"style":1223},[4401],{"type":44,"value":2956},{"type":38,"tag":1194,"props":4403,"children":4404},{"style":1549},[4405],{"type":44,"value":4314},{"type":38,"tag":1194,"props":4407,"children":4408},{"style":1223},[4409],{"type":44,"value":2919},{"type":38,"tag":1194,"props":4411,"children":4412},{"style":2982},[4413],{"type":44,"value":3591},{"type":38,"tag":1194,"props":4415,"children":4416},{"style":1223},[4417],{"type":44,"value":3621},{"type":38,"tag":1194,"props":4419,"children":4420},{"style":1217},[4421],{"type":44,"value":4422},")  ",{"type":38,"tag":1194,"props":4424,"children":4425},{"style":1201},[4426],{"type":44,"value":4427},"\u002F\u002F VERTICAL + props\n",{"type":38,"tag":1138,"props":4429,"children":4431},{"id":4430},"nodeplaceholder-shimmer-overlay-for-ai-in-progress-feedback",[4432,4438],{"type":38,"tag":53,"props":4433,"children":4435},{"className":4434},[],[4436],{"type":44,"value":4437},"node.placeholder",{"type":44,"value":4439}," — shimmer overlay for AI-in-progress feedback",{"type":38,"tag":47,"props":4441,"children":4442},{},[4443,4445,4450],{"type":44,"value":4444},"Sets a visual shimmer overlay on a node indicating work is in progress. ",{"type":38,"tag":73,"props":4446,"children":4447},{},[4448],{"type":44,"value":4449},"Always remove the shimmer when done",{"type":44,"value":4451}," — leftover shimmers confuse users and indicate incomplete work.",{"type":38,"tag":1183,"props":4453,"children":4455},{"className":1185,"code":4454,"language":1187,"meta":1188,"style":1188},"\u002F\u002F Mark as in-progress\nframe.placeholder = true\n\n\u002F\u002F ... build out the content ...\n\n\u002F\u002F MUST remove when done — never leave shimmers on finished nodes\nframe.placeholder = false\n",[4456],{"type":38,"tag":53,"props":4457,"children":4458},{"__ignoreMap":1188},[4459,4467,4493,4500,4508,4515,4523],{"type":38,"tag":1194,"props":4460,"children":4461},{"class":1196,"line":1197},[4462],{"type":38,"tag":1194,"props":4463,"children":4464},{"style":1201},[4465],{"type":44,"value":4466},"\u002F\u002F Mark as in-progress\n",{"type":38,"tag":1194,"props":4468,"children":4469},{"class":1196,"line":1207},[4470,4474,4478,4483,4487],{"type":38,"tag":1194,"props":4471,"children":4472},{"style":1217},[4473],{"type":44,"value":811},{"type":38,"tag":1194,"props":4475,"children":4476},{"style":1223},[4477],{"type":44,"value":68},{"type":38,"tag":1194,"props":4479,"children":4480},{"style":1217},[4481],{"type":44,"value":4482},"placeholder ",{"type":38,"tag":1194,"props":4484,"children":4485},{"style":1223},[4486],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4488,"children":4490},{"style":4489},"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC",[4491],{"type":44,"value":4492}," true\n",{"type":38,"tag":1194,"props":4494,"children":4495},{"class":1196,"line":1329},[4496],{"type":38,"tag":1194,"props":4497,"children":4498},{"emptyLinePlaceholder":1588},[4499],{"type":44,"value":1591},{"type":38,"tag":1194,"props":4501,"children":4502},{"class":1196,"line":1360},[4503],{"type":38,"tag":1194,"props":4504,"children":4505},{"style":1201},[4506],{"type":44,"value":4507},"\u002F\u002F ... build out the content ...\n",{"type":38,"tag":1194,"props":4509,"children":4510},{"class":1196,"line":1575},[4511],{"type":38,"tag":1194,"props":4512,"children":4513},{"emptyLinePlaceholder":1588},[4514],{"type":44,"value":1591},{"type":38,"tag":1194,"props":4516,"children":4517},{"class":1196,"line":1584},[4518],{"type":38,"tag":1194,"props":4519,"children":4520},{"style":1201},[4521],{"type":44,"value":4522},"\u002F\u002F MUST remove when done — never leave shimmers on finished nodes\n",{"type":38,"tag":1194,"props":4524,"children":4525},{"class":1196,"line":1594},[4526,4530,4534,4538,4542],{"type":38,"tag":1194,"props":4527,"children":4528},{"style":1217},[4529],{"type":44,"value":811},{"type":38,"tag":1194,"props":4531,"children":4532},{"style":1223},[4533],{"type":44,"value":68},{"type":38,"tag":1194,"props":4535,"children":4536},{"style":1217},[4537],{"type":44,"value":4482},{"type":38,"tag":1194,"props":4539,"children":4540},{"style":1223},[4541],{"type":44,"value":1226},{"type":38,"tag":1194,"props":4543,"children":4544},{"style":4489},[4545],{"type":44,"value":4546}," false\n",{"type":38,"tag":47,"props":4548,"children":4549},{},[4550,4552,4558,4560,4566],{"type":44,"value":4551},"When building complex layouts, set ",{"type":38,"tag":53,"props":4553,"children":4555},{"className":4554},[],[4556],{"type":44,"value":4557},"placeholder = true",{"type":44,"value":4559}," on sections before populating them, then set ",{"type":38,"tag":53,"props":4561,"children":4563},{"className":4562},[],[4564],{"type":44,"value":4565},"placeholder = false",{"type":44,"value":4567}," on each section as it's completed.",{"type":38,"tag":1138,"props":4569,"children":4571},{"id":4570},"await-nodescreenshotopts-inline-screenshots",[4572,4578],{"type":38,"tag":53,"props":4573,"children":4575},{"className":4574},[],[4576],{"type":44,"value":4577},"await node.screenshot(opts?)",{"type":44,"value":4579}," — inline screenshots",{"type":38,"tag":47,"props":4581,"children":4582},{},[4583,4585,4590],{"type":44,"value":4584},"Capture a node as a PNG and return it inline in the response. Eliminates the need for a separate ",{"type":38,"tag":53,"props":4586,"children":4588},{"className":4587},[],[4589],{"type":44,"value":1988},{"type":44,"value":4591}," call.",{"type":38,"tag":1183,"props":4593,"children":4595},{"className":1185,"code":4594,"language":1187,"meta":1188,"style":1188},"\u002F\u002F Take a screenshot of a frame (returned inline in the tool response)\nawait frame.screenshot()\n\n\u002F\u002F Custom scale (default auto-scales: 0.5x or capped so max dimension ≤ 1024px)\nawait frame.screenshot({ scale: 2 })\n\n\u002F\u002F Include overlapping content from sibling nodes\nawait frame.screenshot({ contentsOnly: false })\n",[4596],{"type":38,"tag":53,"props":4597,"children":4598},{"__ignoreMap":1188},[4599,4607,4631,4638,4646,4695,4702,4710],{"type":38,"tag":1194,"props":4600,"children":4601},{"class":1196,"line":1197},[4602],{"type":38,"tag":1194,"props":4603,"children":4604},{"style":1201},[4605],{"type":44,"value":4606},"\u002F\u002F Take a screenshot of a frame (returned inline in the tool response)\n",{"type":38,"tag":1194,"props":4608,"children":4609},{"class":1196,"line":1207},[4610,4614,4618,4622,4627],{"type":38,"tag":1194,"props":4611,"children":4612},{"style":1333},[4613],{"type":44,"value":289},{"type":38,"tag":1194,"props":4615,"children":4616},{"style":1217},[4617],{"type":44,"value":2082},{"type":38,"tag":1194,"props":4619,"children":4620},{"style":1223},[4621],{"type":44,"value":68},{"type":38,"tag":1194,"props":4623,"children":4624},{"style":1255},[4625],{"type":44,"value":4626},"screenshot",{"type":38,"tag":1194,"props":4628,"children":4629},{"style":1217},[4630],{"type":44,"value":3256},{"type":38,"tag":1194,"props":4632,"children":4633},{"class":1196,"line":1329},[4634],{"type":38,"tag":1194,"props":4635,"children":4636},{"emptyLinePlaceholder":1588},[4637],{"type":44,"value":1591},{"type":38,"tag":1194,"props":4639,"children":4640},{"class":1196,"line":1360},[4641],{"type":38,"tag":1194,"props":4642,"children":4643},{"style":1201},[4644],{"type":44,"value":4645},"\u002F\u002F Custom scale (default auto-scales: 0.5x or capped so max dimension ≤ 1024px)\n",{"type":38,"tag":1194,"props":4647,"children":4648},{"class":1196,"line":1575},[4649,4653,4657,4661,4665,4669,4673,4678,4682,4687,4691],{"type":38,"tag":1194,"props":4650,"children":4651},{"style":1333},[4652],{"type":44,"value":289},{"type":38,"tag":1194,"props":4654,"children":4655},{"style":1217},[4656],{"type":44,"value":2082},{"type":38,"tag":1194,"props":4658,"children":4659},{"style":1223},[4660],{"type":44,"value":68},{"type":38,"tag":1194,"props":4662,"children":4663},{"style":1255},[4664],{"type":44,"value":4626},{"type":38,"tag":1194,"props":4666,"children":4667},{"style":1217},[4668],{"type":44,"value":1263},{"type":38,"tag":1194,"props":4670,"children":4671},{"style":1223},[4672],{"type":44,"value":2929},{"type":38,"tag":1194,"props":4674,"children":4675},{"style":1549},[4676],{"type":44,"value":4677}," scale",{"type":38,"tag":1194,"props":4679,"children":4680},{"style":1223},[4681],{"type":44,"value":2919},{"type":38,"tag":1194,"props":4683,"children":4684},{"style":2982},[4685],{"type":44,"value":4686}," 2",{"type":38,"tag":1194,"props":4688,"children":4689},{"style":1223},[4690],{"type":44,"value":3621},{"type":38,"tag":1194,"props":4692,"children":4693},{"style":1217},[4694],{"type":44,"value":2174},{"type":38,"tag":1194,"props":4696,"children":4697},{"class":1196,"line":1584},[4698],{"type":38,"tag":1194,"props":4699,"children":4700},{"emptyLinePlaceholder":1588},[4701],{"type":44,"value":1591},{"type":38,"tag":1194,"props":4703,"children":4704},{"class":1196,"line":1594},[4705],{"type":38,"tag":1194,"props":4706,"children":4707},{"style":1201},[4708],{"type":44,"value":4709},"\u002F\u002F Include overlapping content from sibling nodes\n",{"type":38,"tag":1194,"props":4711,"children":4712},{"class":1196,"line":1603},[4713,4717,4721,4725,4729,4733,4737,4742,4746,4751,4755],{"type":38,"tag":1194,"props":4714,"children":4715},{"style":1333},[4716],{"type":44,"value":289},{"type":38,"tag":1194,"props":4718,"children":4719},{"style":1217},[4720],{"type":44,"value":2082},{"type":38,"tag":1194,"props":4722,"children":4723},{"style":1223},[4724],{"type":44,"value":68},{"type":38,"tag":1194,"props":4726,"children":4727},{"style":1255},[4728],{"type":44,"value":4626},{"type":38,"tag":1194,"props":4730,"children":4731},{"style":1217},[4732],{"type":44,"value":1263},{"type":38,"tag":1194,"props":4734,"children":4735},{"style":1223},[4736],{"type":44,"value":2929},{"type":38,"tag":1194,"props":4738,"children":4739},{"style":1549},[4740],{"type":44,"value":4741}," contentsOnly",{"type":38,"tag":1194,"props":4743,"children":4744},{"style":1223},[4745],{"type":44,"value":2919},{"type":38,"tag":1194,"props":4747,"children":4748},{"style":4489},[4749],{"type":44,"value":4750}," false",{"type":38,"tag":1194,"props":4752,"children":4753},{"style":1223},[4754],{"type":44,"value":3621},{"type":38,"tag":1194,"props":4756,"children":4757},{"style":1217},[4758],{"type":44,"value":2174},{"type":38,"tag":47,"props":4760,"children":4761},{},[4762,4767,4769,4775,4777,4782],{"type":38,"tag":73,"props":4763,"children":4764},{},[4765],{"type":44,"value":4766},"When to use:",{"type":44,"value":4768}," After creating or modifying nodes, call ",{"type":38,"tag":53,"props":4770,"children":4772},{"className":4771},[],[4773],{"type":44,"value":4774},"screenshot()",{"type":44,"value":4776}," to visually verify the result within the same script. No need for a separate ",{"type":38,"tag":53,"props":4778,"children":4780},{"className":4779},[],[4781],{"type":44,"value":1988},{"type":44,"value":4591},{"type":38,"tag":47,"props":4784,"children":4785},{},[4786,4791,4793,4799],{"type":38,"tag":73,"props":4787,"children":4788},{},[4789],{"type":44,"value":4790},"Auto-naming:",{"type":44,"value":4792}," The image caption includes node metadata — ",{"type":38,"tag":53,"props":4794,"children":4796},{"className":4795},[],[4797],{"type":44,"value":4798},"\"Card (300x150 at 0,60).png\"",{"type":44,"value":4800}," — giving spatial context without parsing the image.",{"type":38,"tag":47,"props":4802,"children":4803},{},[4804,4809,4811,4817],{"type":38,"tag":73,"props":4805,"children":4806},{},[4807],{"type":44,"value":4808},"Default scaling:",{"type":44,"value":4810}," Uses 0.5x scale, but automatically caps so the largest output dimension never exceeds 1024px. Explicit ",{"type":38,"tag":53,"props":4812,"children":4814},{"className":4813},[],[4815],{"type":44,"value":4816},"{ scale: N }",{"type":44,"value":4818}," bypasses the cap.",{"type":38,"tag":239,"props":4820,"children":4822},{"id":4821},"_6-incremental-workflow-how-to-avoid-bugs",[4823],{"type":44,"value":4824},"6. Incremental Workflow (How to Avoid Bugs)",{"type":38,"tag":47,"props":4826,"children":4827},{},[4828,4830,4835,4837],{"type":44,"value":4829},"The most common cause of bugs is trying to do too much in a single ",{"type":38,"tag":53,"props":4831,"children":4833},{"className":4832},[],[4834],{"type":44,"value":58},{"type":44,"value":4836}," call. ",{"type":38,"tag":73,"props":4838,"children":4839},{},[4840],{"type":44,"value":4841},"Work in small steps and validate after each one.",{"type":38,"tag":1138,"props":4843,"children":4845},{"id":4844},"key-rules",[4846],{"type":44,"value":4847},"Key rules",{"type":38,"tag":1718,"props":4849,"children":4850},{},[4851,4880],{"type":38,"tag":250,"props":4852,"children":4853},{},[4854,4865,4867,4872,4874,4878],{"type":38,"tag":73,"props":4855,"children":4856},{},[4857,4859,4864],{"type":44,"value":4858},"At most 10 logical operations per ",{"type":38,"tag":53,"props":4860,"children":4862},{"className":4861},[],[4863],{"type":44,"value":58},{"type":44,"value":4591},{"type":44,"value":4866}," A \"logical operation\" is creating a node, setting its properties, and parenting it. If you need to create 20 nodes, split across 2-3 calls. ",{"type":38,"tag":73,"props":4868,"children":4869},{},[4870],{"type":44,"value":4871},"Slides override:",{"type":44,"value":4873}," in Slides files, slides are isolated subtrees — the relevant limit is complexity per slide, not total nodes across slides. Building 3–5 new slides in one call is safe, and so is applying the same edit (e.g. adding a footer, recoloring a heading) across every slide in the deck in a single call. See ",{"type":38,"tag":163,"props":4875,"children":4876},{"href":2001},[4877],{"type":44,"value":2004},{"type":44,"value":4879}," for the deck-building workflow.",{"type":38,"tag":250,"props":4881,"children":4882},{},[4883,4888,4890,4895],{"type":38,"tag":73,"props":4884,"children":4885},{},[4886],{"type":44,"value":4887},"Build top-down, starting with placeholders.",{"type":44,"value":4889}," Create the outer structure first with ",{"type":38,"tag":53,"props":4891,"children":4893},{"className":4892},[],[4894],{"type":44,"value":4557},{"type":44,"value":4896}," on each section, then incrementally replace placeholders with real content in subsequent calls.",{"type":38,"tag":1138,"props":4898,"children":4900},{"id":4899},"the-pattern",[4901],{"type":44,"value":4902},"The pattern",{"type":38,"tag":246,"props":4904,"children":4905},{},[4906,4923,4940,4964,4989,5021],{"type":38,"tag":250,"props":4907,"children":4908},{},[4909,4914,4916,4921],{"type":38,"tag":73,"props":4910,"children":4911},{},[4912],{"type":44,"value":4913},"Inspect first.",{"type":44,"value":4915}," Before creating anything, run a read-only ",{"type":38,"tag":53,"props":4917,"children":4919},{"className":4918},[],[4920],{"type":44,"value":58},{"type":44,"value":4922}," to discover what already exists in the file — pages, components, variables, naming conventions. Match what's there.",{"type":38,"tag":250,"props":4924,"children":4925},{},[4926,4931,4933,4938],{"type":38,"tag":73,"props":4927,"children":4928},{},[4929],{"type":44,"value":4930},"Build the skeleton.",{"type":44,"value":4932}," Create the top-level structure with placeholder sections. Set ",{"type":38,"tag":53,"props":4934,"children":4936},{"className":4935},[],[4937],{"type":44,"value":4557},{"type":44,"value":4939}," on each section so the user sees progress.",{"type":38,"tag":250,"props":4941,"children":4942},{},[4943,4948,4950,4955,4957,4962],{"type":38,"tag":73,"props":4944,"children":4945},{},[4946],{"type":44,"value":4947},"Fill in sections incrementally.",{"type":44,"value":4949}," In each subsequent call, populate one section and set its ",{"type":38,"tag":53,"props":4951,"children":4953},{"className":4952},[],[4954],{"type":44,"value":4565},{"type":44,"value":4956}," when done. Take a ",{"type":38,"tag":53,"props":4958,"children":4960},{"className":4959},[],[4961],{"type":44,"value":4774},{"type":44,"value":4963}," to verify.",{"type":38,"tag":250,"props":4965,"children":4966},{},[4967,4972,4974,4979,4981,4987],{"type":38,"tag":73,"props":4968,"children":4969},{},[4970],{"type":44,"value":4971},"Return IDs from every call.",{"type":44,"value":4973}," Always ",{"type":38,"tag":53,"props":4975,"children":4977},{"className":4976},[],[4978],{"type":44,"value":263},{"type":44,"value":4980}," created node IDs, variable IDs, collection IDs as objects (e.g. ",{"type":38,"tag":53,"props":4982,"children":4984},{"className":4983},[],[4985],{"type":44,"value":4986},"return { createdNodeIds: [...] }",{"type":44,"value":4988},"). You'll need these as inputs to subsequent calls.",{"type":38,"tag":250,"props":4990,"children":4991},{},[4992,4997,4999,5005,5007,5012,5014,5019],{"type":38,"tag":73,"props":4993,"children":4994},{},[4995],{"type":44,"value":4996},"Validate after each step.",{"type":44,"value":4998}," Use ",{"type":38,"tag":53,"props":5000,"children":5002},{"className":5001},[],[5003],{"type":44,"value":5004},"get_metadata",{"type":44,"value":5006}," to verify structure (counts, names, hierarchy, positions). Use ",{"type":38,"tag":53,"props":5008,"children":5010},{"className":5009},[],[5011],{"type":44,"value":1996},{"type":44,"value":5013}," inline or ",{"type":38,"tag":53,"props":5015,"children":5017},{"className":5016},[],[5018],{"type":44,"value":1988},{"type":44,"value":5020}," after major milestones to catch visual issues.",{"type":38,"tag":250,"props":5022,"children":5023},{},[5024,5029],{"type":38,"tag":73,"props":5025,"children":5026},{},[5027],{"type":44,"value":5028},"Fix before moving on.",{"type":44,"value":5030}," If validation reveals a problem, fix it before proceeding to the next step. Don't build on a broken foundation.",{"type":38,"tag":1138,"props":5032,"children":5034},{"id":5033},"suggested-step-order-for-complex-tasks",[5035],{"type":44,"value":5036},"Suggested step order for complex tasks",{"type":38,"tag":1183,"props":5038,"children":5042},{"className":5039,"code":5041,"language":44},[5040],"language-text","Step 1: Inspect file — discover existing pages, components, variables, conventions\nStep 2: Create tokens\u002Fvariables (if needed)\n       → validate with get_metadata\nStep 3: Create individual components\n       → validate with get_metadata + get_screenshot\nStep 4: Compose layouts from component instances\n       → validate with get_screenshot\nStep 5: Final verification\n",[5043],{"type":38,"tag":53,"props":5044,"children":5045},{"__ignoreMap":1188},[5046],{"type":44,"value":5041},{"type":38,"tag":1138,"props":5048,"children":5050},{"id":5049},"what-to-validate-at-each-step",[5051],{"type":44,"value":5052},"What to validate at each step",{"type":38,"tag":2527,"props":5054,"children":5055},{},[5056,5086],{"type":38,"tag":2531,"props":5057,"children":5058},{},[5059],{"type":38,"tag":2535,"props":5060,"children":5061},{},[5062,5067,5077],{"type":38,"tag":2539,"props":5063,"children":5064},{},[5065],{"type":44,"value":5066},"After...",{"type":38,"tag":2539,"props":5068,"children":5069},{},[5070,5072],{"type":44,"value":5071},"Check with ",{"type":38,"tag":53,"props":5073,"children":5075},{"className":5074},[],[5076],{"type":44,"value":5004},{"type":38,"tag":2539,"props":5078,"children":5079},{},[5080,5081],{"type":44,"value":5071},{"type":38,"tag":53,"props":5082,"children":5084},{"className":5083},[],[5085],{"type":44,"value":1988},{"type":38,"tag":2550,"props":5087,"children":5088},{},[5089,5107,5125,5143],{"type":38,"tag":2535,"props":5090,"children":5091},{},[5092,5097,5102],{"type":38,"tag":2557,"props":5093,"children":5094},{},[5095],{"type":44,"value":5096},"Creating variables",{"type":38,"tag":2557,"props":5098,"children":5099},{},[5100],{"type":44,"value":5101},"Collection count, variable count, mode names",{"type":38,"tag":2557,"props":5103,"children":5104},{},[5105],{"type":44,"value":5106},"—",{"type":38,"tag":2535,"props":5108,"children":5109},{},[5110,5115,5120],{"type":38,"tag":2557,"props":5111,"children":5112},{},[5113],{"type":44,"value":5114},"Creating components",{"type":38,"tag":2557,"props":5116,"children":5117},{},[5118],{"type":44,"value":5119},"Child count, variant names, property definitions",{"type":38,"tag":2557,"props":5121,"children":5122},{},[5123],{"type":44,"value":5124},"Variants visible, not collapsed, grid readable",{"type":38,"tag":2535,"props":5126,"children":5127},{},[5128,5133,5138],{"type":38,"tag":2557,"props":5129,"children":5130},{},[5131],{"type":44,"value":5132},"Binding variables",{"type":38,"tag":2557,"props":5134,"children":5135},{},[5136],{"type":44,"value":5137},"Node properties reflect bindings",{"type":38,"tag":2557,"props":5139,"children":5140},{},[5141],{"type":44,"value":5142},"Colors\u002Ftokens resolved correctly",{"type":38,"tag":2535,"props":5144,"children":5145},{},[5146,5151,5156],{"type":38,"tag":2557,"props":5147,"children":5148},{},[5149],{"type":44,"value":5150},"Composing layouts",{"type":38,"tag":2557,"props":5152,"children":5153},{},[5154],{"type":44,"value":5155},"Instance nodes have mainComponent, hierarchy correct",{"type":38,"tag":2557,"props":5157,"children":5158},{},[5159],{"type":44,"value":5160},"No cropped\u002Fclipped text, no overlapping elements, correct spacing",{"type":38,"tag":239,"props":5162,"children":5164},{"id":5163},"_7-error-recovery-self-correction",[5165],{"type":44,"value":5166},"7. Error Recovery & Self-Correction",{"type":38,"tag":47,"props":5168,"children":5169},{},[5170,5180],{"type":38,"tag":73,"props":5171,"children":5172},{},[5173,5178],{"type":38,"tag":53,"props":5174,"children":5176},{"className":5175},[],[5177],{"type":44,"value":58},{"type":44,"value":5179}," is atomic — failed scripts do not execute.",{"type":44,"value":5181}," If a script errors, no changes are made to the file. The file remains in the same state as before the call. This means there are no partial nodes, no orphaned elements from the failed script, and retrying after a fix is safe.",{"type":38,"tag":1138,"props":5183,"children":5185},{"id":5184},"when-use_figma-returns-an-error",[5186,5188,5193],{"type":44,"value":5187},"When ",{"type":38,"tag":53,"props":5189,"children":5191},{"className":5190},[],[5192],{"type":44,"value":58},{"type":44,"value":5194}," returns an error",{"type":38,"tag":246,"props":5196,"children":5197},{},[5198,5208,5218,5242,5252],{"type":38,"tag":250,"props":5199,"children":5200},{},[5201,5206],{"type":38,"tag":73,"props":5202,"children":5203},{},[5204],{"type":44,"value":5205},"STOP.",{"type":44,"value":5207}," Do not immediately fix the code and retry.",{"type":38,"tag":250,"props":5209,"children":5210},{},[5211,5216],{"type":38,"tag":73,"props":5212,"children":5213},{},[5214],{"type":44,"value":5215},"Read the error message carefully.",{"type":44,"value":5217}," Understand exactly what went wrong — wrong API usage, missing font, invalid property value, etc.",{"type":38,"tag":250,"props":5219,"children":5220},{},[5221,5226,5228,5233,5235,5240],{"type":38,"tag":73,"props":5222,"children":5223},{},[5224],{"type":44,"value":5225},"If the error is unclear",{"type":44,"value":5227},", call ",{"type":38,"tag":53,"props":5229,"children":5231},{"className":5230},[],[5232],{"type":44,"value":5004},{"type":44,"value":5234}," or ",{"type":38,"tag":53,"props":5236,"children":5238},{"className":5237},[],[5239],{"type":44,"value":1988},{"type":44,"value":5241}," to understand the current file state.",{"type":38,"tag":250,"props":5243,"children":5244},{},[5245,5250],{"type":38,"tag":73,"props":5246,"children":5247},{},[5248],{"type":44,"value":5249},"Fix the script",{"type":44,"value":5251}," based on the error message.",{"type":38,"tag":250,"props":5253,"children":5254},{},[5255,5260],{"type":38,"tag":73,"props":5256,"children":5257},{},[5258],{"type":44,"value":5259},"Retry",{"type":44,"value":5261}," the corrected script.",{"type":38,"tag":1138,"props":5263,"children":5265},{"id":5264},"common-self-correction-patterns",[5266],{"type":44,"value":5267},"Common self-correction patterns",{"type":38,"tag":2527,"props":5269,"children":5270},{},[5271,5292],{"type":38,"tag":2531,"props":5272,"children":5273},{},[5274],{"type":38,"tag":2535,"props":5275,"children":5276},{},[5277,5282,5287],{"type":38,"tag":2539,"props":5278,"children":5279},{},[5280],{"type":44,"value":5281},"Error message",{"type":38,"tag":2539,"props":5283,"children":5284},{},[5285],{"type":44,"value":5286},"Likely cause",{"type":38,"tag":2539,"props":5288,"children":5289},{},[5290],{"type":44,"value":5291},"How to fix",{"type":38,"tag":2550,"props":5293,"children":5294},{},[5295,5328,5448,5482,5500,5522,5555],{"type":38,"tag":2535,"props":5296,"children":5297},{},[5298,5307,5317],{"type":38,"tag":2557,"props":5299,"children":5300},{},[5301],{"type":38,"tag":53,"props":5302,"children":5304},{"className":5303},[],[5305],{"type":44,"value":5306},"\"not implemented\"",{"type":38,"tag":2557,"props":5308,"children":5309},{},[5310,5312],{"type":44,"value":5311},"Used ",{"type":38,"tag":53,"props":5313,"children":5315},{"className":5314},[],[5316],{"type":44,"value":315},{"type":38,"tag":2557,"props":5318,"children":5319},{},[5320,5322,5327],{"type":44,"value":5321},"Remove it — use ",{"type":38,"tag":53,"props":5323,"children":5325},{"className":5324},[],[5326],{"type":44,"value":263},{"type":44,"value":387},{"type":38,"tag":2535,"props":5329,"children":5330},{},[5331,5366,5404],{"type":38,"tag":2557,"props":5332,"children":5333},{},[5334,5339,5340,5345,5346,5352,5353,5359,5360],{"type":38,"tag":53,"props":5335,"children":5337},{"className":5336},[],[5338],{"type":44,"value":873},{"type":44,"value":1990},{"type":38,"tag":53,"props":5341,"children":5343},{"className":5342},[],[5344],{"type":44,"value":880},{"type":44,"value":1990},{"type":38,"tag":53,"props":5347,"children":5349},{"className":5348},[],[5350],{"type":44,"value":5351},"\"HUG can only be set on auto-layout frames or text children of auto-layout frames\"",{"type":44,"value":1990},{"type":38,"tag":53,"props":5354,"children":5356},{"className":5355},[],[5357],{"type":44,"value":5358},"\"FILL cannot be set on absolute positioned auto-layout children\"",{"type":44,"value":1990},{"type":38,"tag":53,"props":5361,"children":5363},{"className":5362},[],[5364],{"type":44,"value":5365},"\"FILL cannot be set on canvas grid children\"",{"type":38,"tag":2557,"props":5367,"children":5368},{},[5369,5371,5376,5377,5382,5384,5389,5391,5396,5398,5403],{"type":44,"value":5370},"Tried to assign ",{"type":38,"tag":53,"props":5372,"children":5374},{"className":5373},[],[5375],{"type":44,"value":641},{"type":44,"value":681},{"type":38,"tag":53,"props":5378,"children":5380},{"className":5379},[],[5381],{"type":44,"value":648},{"type":44,"value":5383}," to a node whose structural context doesn't allow it (e.g. parent isn't auto-layout, ran before ",{"type":38,"tag":53,"props":5385,"children":5387},{"className":5386},[],[5388],{"type":44,"value":475},{"type":44,"value":5390},", non-text child trying to ",{"type":38,"tag":53,"props":5392,"children":5394},{"className":5393},[],[5395],{"type":44,"value":641},{"type":44,"value":5397},", absolute-positioned child trying to ",{"type":38,"tag":53,"props":5399,"children":5401},{"className":5400},[],[5402],{"type":44,"value":648},{"type":44,"value":1277},{"type":38,"tag":2557,"props":5405,"children":5406},{},[5407,5409,5414,5415,5420,5422,5427,5429,5434,5436,5441,5443],{"type":44,"value":5408},"Make the parent auto-layout via ",{"type":38,"tag":53,"props":5410,"children":5412},{"className":5411},[],[5413],{"type":44,"value":717},{"type":44,"value":791},{"type":38,"tag":53,"props":5416,"children":5418},{"className":5417},[],[5419],{"type":44,"value":475},{"type":44,"value":5421}," first; reserve ",{"type":38,"tag":53,"props":5423,"children":5425},{"className":5424},[],[5426],{"type":44,"value":641},{"type":44,"value":5428}," for the auto-layout frame itself or for TEXT children; for absolute\u002Fimmutable\u002Fgrid children use ",{"type":38,"tag":53,"props":5430,"children":5432},{"className":5431},[],[5433],{"type":44,"value":633},{"type":44,"value":5435}," + ",{"type":38,"tag":53,"props":5437,"children":5439},{"className":5438},[],[5440],{"type":44,"value":3663},{"type":44,"value":5442},". See ",{"type":38,"tag":163,"props":5444,"children":5445},{"href":699},[5446],{"type":44,"value":5447},"gotchas.md",{"type":38,"tag":2535,"props":5449,"children":5450},{},[5451,5459,5471],{"type":38,"tag":2557,"props":5452,"children":5453},{},[5454],{"type":38,"tag":53,"props":5455,"children":5457},{"className":5456},[],[5458],{"type":44,"value":1172},{"type":38,"tag":2557,"props":5460,"children":5461},{},[5462,5464,5469],{"type":44,"value":5463},"Used sync page setter (",{"type":38,"tag":53,"props":5465,"children":5467},{"className":5466},[],[5468],{"type":44,"value":568},{"type":44,"value":5470},") which does NOT work",{"type":38,"tag":2557,"props":5472,"children":5473},{},[5474,5475,5480],{"type":44,"value":257},{"type":38,"tag":53,"props":5476,"children":5478},{"className":5477},[],[5479],{"type":44,"value":560},{"type":44,"value":5481}," — the only way to switch pages",{"type":38,"tag":2535,"props":5483,"children":5484},{},[5485,5490,5495],{"type":38,"tag":2557,"props":5486,"children":5487},{},[5488],{"type":44,"value":5489},"Property value out of range",{"type":38,"tag":2557,"props":5491,"children":5492},{},[5493],{"type":44,"value":5494},"Color channel > 1 (used 0–255 instead of 0–1)",{"type":38,"tag":2557,"props":5496,"children":5497},{},[5498],{"type":44,"value":5499},"Divide by 255",{"type":38,"tag":2535,"props":5501,"children":5502},{},[5503,5512,5517],{"type":38,"tag":2557,"props":5504,"children":5505},{},[5506],{"type":38,"tag":53,"props":5507,"children":5509},{"className":5508},[],[5510],{"type":44,"value":5511},"\"Cannot read properties of null\"",{"type":38,"tag":2557,"props":5513,"children":5514},{},[5515],{"type":44,"value":5516},"Node doesn't exist (wrong ID, wrong page)",{"type":38,"tag":2557,"props":5518,"children":5519},{},[5520],{"type":44,"value":5521},"Check page context, verify ID",{"type":38,"tag":2535,"props":5523,"children":5524},{},[5525,5530,5535],{"type":38,"tag":2557,"props":5526,"children":5527},{},[5528],{"type":44,"value":5529},"Script hangs \u002F no response",{"type":38,"tag":2557,"props":5531,"children":5532},{},[5533],{"type":44,"value":5534},"Infinite loop or unresolved promise",{"type":38,"tag":2557,"props":5536,"children":5537},{},[5538,5540,5546,5548,5553],{"type":44,"value":5539},"Check for ",{"type":38,"tag":53,"props":5541,"children":5543},{"className":5542},[],[5544],{"type":44,"value":5545},"while(true)",{"type":44,"value":5547}," or missing ",{"type":38,"tag":53,"props":5549,"children":5551},{"className":5550},[],[5552],{"type":44,"value":289},{"type":44,"value":5554},"; ensure code terminates",{"type":38,"tag":2535,"props":5556,"children":5557},{},[5558,5567,5580],{"type":38,"tag":2557,"props":5559,"children":5560},{},[5561],{"type":38,"tag":53,"props":5562,"children":5564},{"className":5563},[],[5565],{"type":44,"value":5566},"\"The node with id X does not exist\"",{"type":38,"tag":2557,"props":5568,"children":5569},{},[5570,5572,5578],{"type":44,"value":5571},"Parent instance was implicitly detached by a child ",{"type":38,"tag":53,"props":5573,"children":5575},{"className":5574},[],[5576],{"type":44,"value":5577},"detachInstance()",{"type":44,"value":5579},", changing IDs",{"type":38,"tag":2557,"props":5581,"children":5582},{},[5583],{"type":44,"value":5584},"Re-discover nodes by traversal from a stable (non-instance) parent frame",{"type":38,"tag":1138,"props":5586,"children":5588},{"id":5587},"when-the-script-succeeds-but-the-result-looks-wrong",[5589],{"type":44,"value":5590},"When the script succeeds but the result looks wrong",{"type":38,"tag":246,"props":5592,"children":5593},{},[5594,5605,5616,5621],{"type":38,"tag":250,"props":5595,"children":5596},{},[5597,5598,5603],{"type":44,"value":1372},{"type":38,"tag":53,"props":5599,"children":5601},{"className":5600},[],[5602],{"type":44,"value":5004},{"type":44,"value":5604}," to check structural correctness (hierarchy, counts, positions).",{"type":38,"tag":250,"props":5606,"children":5607},{},[5608,5609,5614],{"type":44,"value":1372},{"type":38,"tag":53,"props":5610,"children":5612},{"className":5611},[],[5613],{"type":44,"value":1988},{"type":44,"value":5615}," to check visual correctness. Look closely for cropped\u002Fclipped text (line heights cutting off content) and overlapping elements — these are common and easy to miss.",{"type":38,"tag":250,"props":5617,"children":5618},{},[5619],{"type":44,"value":5620},"Identify the discrepancy — is it structural (wrong hierarchy, missing nodes) or visual (wrong colors, broken layout, clipped content)?",{"type":38,"tag":250,"props":5622,"children":5623},{},[5624],{"type":44,"value":5625},"Write a targeted fix script that modifies only the broken parts — don't recreate everything.",{"type":38,"tag":1092,"props":5627,"children":5628},{},[5629],{"type":38,"tag":47,"props":5630,"children":5631},{},[5632,5634,5640],{"type":44,"value":5633},"For the full validation workflow, see ",{"type":38,"tag":163,"props":5635,"children":5637},{"href":5636},"references\u002Fvalidation-and-recovery.md",[5638],{"type":44,"value":5639},"Validation & Error Recovery",{"type":44,"value":68},{"type":38,"tag":239,"props":5642,"children":5644},{"id":5643},"_8-pre-flight-checklist",[5645],{"type":44,"value":5646},"8. Pre-Flight Checklist",{"type":38,"tag":47,"props":5648,"children":5649},{},[5650,5652,5657],{"type":44,"value":5651},"Before submitting ANY ",{"type":38,"tag":53,"props":5653,"children":5655},{"className":5654},[],[5656],{"type":44,"value":58},{"type":44,"value":5658}," call, verify:",{"type":38,"tag":1718,"props":5660,"children":5663},{"className":5661},[5662],"contains-task-list",[5664,5689,5698,5713,5729,5751,5760,5799,5808,5831,5853,5904,5940,5973,6008,6039,6054,6063,6072,6088,6104],{"type":38,"tag":250,"props":5665,"children":5668},{"className":5666},[5667],"task-list-item",[5669,5674,5676,5681,5683,5688],{"type":38,"tag":5670,"props":5671,"children":5673},"input",{"disabled":1588,"type":5672},"checkbox",[],{"type":44,"value":5675}," Code uses ",{"type":38,"tag":53,"props":5677,"children":5679},{"className":5678},[],[5680],{"type":44,"value":263},{"type":44,"value":5682}," to send data back (NOT ",{"type":38,"tag":53,"props":5684,"children":5686},{"className":5685},[],[5687],{"type":44,"value":273},{"type":44,"value":1277},{"type":38,"tag":250,"props":5690,"children":5692},{"className":5691},[5667],[5693,5696],{"type":38,"tag":5670,"props":5694,"children":5695},{"disabled":1588,"type":5672},[],{"type":44,"value":5697}," Code is NOT wrapped in an async IIFE (auto-wrapped for you)",{"type":38,"tag":250,"props":5699,"children":5701},{"className":5700},[5667],[5702,5705,5706,5711],{"type":38,"tag":5670,"props":5703,"children":5704},{"disabled":1588,"type":5672},[],{"type":44,"value":317},{"type":38,"tag":53,"props":5707,"children":5709},{"className":5708},[],[5710],{"type":44,"value":263},{"type":44,"value":5712}," value includes structured data with actionable info (IDs, counts)",{"type":38,"tag":250,"props":5714,"children":5716},{"className":5715},[5667],[5717,5720,5722,5727],{"type":38,"tag":5670,"props":5718,"children":5719},{"disabled":1588,"type":5672},[],{"type":44,"value":5721}," NO usage of ",{"type":38,"tag":53,"props":5723,"children":5725},{"className":5724},[],[5726],{"type":44,"value":315},{"type":44,"value":5728}," anywhere",{"type":38,"tag":250,"props":5730,"children":5732},{"className":5731},[5667],[5733,5736,5737,5742,5744,5749],{"type":38,"tag":5670,"props":5734,"children":5735},{"disabled":1588,"type":5672},[],{"type":44,"value":5721},{"type":38,"tag":53,"props":5738,"children":5740},{"className":5739},[],[5741],{"type":44,"value":378},{"type":44,"value":5743}," as output (use ",{"type":38,"tag":53,"props":5745,"children":5747},{"className":5746},[],[5748],{"type":44,"value":263},{"type":44,"value":5750}," instead)",{"type":38,"tag":250,"props":5752,"children":5754},{"className":5753},[5667],[5755,5758],{"type":38,"tag":5670,"props":5756,"children":5757},{"disabled":1588,"type":5672},[],{"type":44,"value":5759}," All colors use 0–1 range (not 0–255)",{"type":38,"tag":250,"props":5761,"children":5763},{"className":5762},[5667],[5764,5767,5769,5775,5777,5783,5785,5790,5792,5798],{"type":38,"tag":5670,"props":5765,"children":5766},{"disabled":1588,"type":5672},[],{"type":44,"value":5768}," Paint ",{"type":38,"tag":53,"props":5770,"children":5772},{"className":5771},[],[5773],{"type":44,"value":5774},"color",{"type":44,"value":5776}," objects use ",{"type":38,"tag":53,"props":5778,"children":5780},{"className":5779},[],[5781],{"type":44,"value":5782},"{r, g, b}",{"type":44,"value":5784}," only — no ",{"type":38,"tag":53,"props":5786,"children":5788},{"className":5787},[],[5789],{"type":44,"value":163},{"type":44,"value":5791}," field (opacity goes at the paint level: ",{"type":38,"tag":53,"props":5793,"children":5795},{"className":5794},[],[5796],{"type":44,"value":5797},"{ type: 'SOLID', color: {...}, opacity: 0.5 }",{"type":44,"value":1277},{"type":38,"tag":250,"props":5800,"children":5802},{"className":5801},[5667],[5803,5806],{"type":38,"tag":5670,"props":5804,"children":5805},{"disabled":1588,"type":5672},[],{"type":44,"value":5807}," Fills\u002Fstrokes are reassigned as new arrays (not mutated in place)",{"type":38,"tag":250,"props":5809,"children":5811},{"className":5810},[5667],[5812,5815,5817,5822,5824,5829],{"type":38,"tag":5670,"props":5813,"children":5814},{"disabled":1588,"type":5672},[],{"type":44,"value":5816}," Page switches use ",{"type":38,"tag":53,"props":5818,"children":5820},{"className":5819},[],[5821],{"type":44,"value":560},{"type":44,"value":5823}," (sync setter ",{"type":38,"tag":53,"props":5825,"children":5827},{"className":5826},[],[5828],{"type":44,"value":568},{"type":44,"value":5830}," does NOT work)",{"type":38,"tag":250,"props":5832,"children":5834},{"className":5833},[5667],[5835,5838,5839,5845,5847],{"type":38,"tag":5670,"props":5836,"children":5837},{"disabled":1588,"type":5672},[],{"type":44,"value":317},{"type":38,"tag":53,"props":5840,"children":5842},{"className":5841},[],[5843],{"type":44,"value":5844},"layoutSizingVertical\u002FHorizontal = 'FILL'",{"type":44,"value":5846}," is set AFTER ",{"type":38,"tag":53,"props":5848,"children":5850},{"className":5849},[],[5851],{"type":44,"value":5852},"parent.appendChild(child)",{"type":38,"tag":250,"props":5854,"children":5856},{"className":5855},[5667],[5857,5860,5862,5868,5870,5875,5876,5881,5883,5888,5890,5896,5898],{"type":38,"tag":5670,"props":5858,"children":5859},{"disabled":1588,"type":5672},[],{"type":44,"value":5861}," Wrapping TEXT blocks set ",{"type":38,"tag":53,"props":5863,"children":5865},{"className":5864},[],[5866],{"type":44,"value":5867},"textAutoResize = 'HEIGHT'",{"type":44,"value":5869}," and an explicit width (",{"type":38,"tag":53,"props":5871,"children":5873},{"className":5872},[],[5874],{"type":44,"value":858},{"type":44,"value":5435},{"type":38,"tag":53,"props":5877,"children":5879},{"className":5878},[],[5880],{"type":44,"value":3663},{"type":44,"value":5882},") — NOT ",{"type":38,"tag":53,"props":5884,"children":5886},{"className":5885},[],[5887],{"type":44,"value":648},{"type":44,"value":5889}," alone, which the default ",{"type":38,"tag":53,"props":5891,"children":5893},{"className":5892},[],[5894],{"type":44,"value":5895},"WIDTH_AND_HEIGHT",{"type":44,"value":5897}," mode ignores, collapsing the node to a near-zero-width thread. Verify ",{"type":38,"tag":53,"props":5899,"children":5901},{"className":5900},[],[5902],{"type":44,"value":5903},"node.width > 0",{"type":38,"tag":250,"props":5905,"children":5907},{"className":5906},[5667],[5908,5911,5913,5918,5919,5925,5926,5931,5933,5938],{"type":38,"tag":5670,"props":5909,"children":5910},{"disabled":1588,"type":5672},[],{"type":44,"value":5912}," Every text mutation follows the ",{"type":38,"tag":163,"props":5914,"children":5915},{"href":540},[5916],{"type":44,"value":5917},"canonical recipe",{"type":44,"value":1754},{"type":38,"tag":53,"props":5920,"children":5922},{"className":5921},[],[5923],{"type":44,"value":5924},"loadFontAsync",{"type":44,"value":2718},{"type":38,"tag":53,"props":5927,"children":5929},{"className":5928},[],[5930],{"type":44,"value":289},{"type":44,"value":5932}," → mutate ",{"type":38,"tag":53,"props":5934,"children":5936},{"className":5935},[],[5937],{"type":44,"value":467},{"type":44,"value":5939},"\u002Ffont\u002Fsize\u002Fetc. → return affected node IDs. Works for ANY font family\u002Fstyle, not just Inter (which only happens to be preloaded).",{"type":38,"tag":250,"props":5941,"children":5943},{"className":5942},[5667],[5944,5947,5949,5955,5957,5963,5965,5971],{"type":38,"tag":5670,"props":5945,"children":5946},{"disabled":1588,"type":5672},[],{"type":44,"value":5948}," Style names have already been verified via ",{"type":38,"tag":53,"props":5950,"children":5952},{"className":5951},[],[5953],{"type":44,"value":5954},"listAvailableFontsAsync()",{"type":44,"value":5956}," — NOT guessed from memory (",{"type":38,"tag":53,"props":5958,"children":5960},{"className":5959},[],[5961],{"type":44,"value":5962},"\"SemiBold\"",{"type":44,"value":5964}," vs ",{"type":38,"tag":53,"props":5966,"children":5968},{"className":5967},[],[5969],{"type":44,"value":5970},"\"Semi Bold\"",{"type":44,"value":5972}," is a common footgun)",{"type":38,"tag":250,"props":5974,"children":5976},{"className":5975},[5667],[5977,5980,5982,5988,5990,5996,5997,6002,6003],{"type":38,"tag":5670,"props":5978,"children":5979},{"disabled":1588,"type":5672},[],{"type":44,"value":5981}," For ",{"type":38,"tag":53,"props":5983,"children":5985},{"className":5984},[],[5986],{"type":44,"value":5987},"FONT_FAMILY",{"type":44,"value":5989},"-scoped variables: every value across every relevant mode is loaded before ",{"type":38,"tag":53,"props":5991,"children":5993},{"className":5992},[],[5994],{"type":44,"value":5995},"setBoundVariable(\"fontFamily\", …)",{"type":44,"value":477},{"type":38,"tag":53,"props":5998,"children":6000},{"className":5999},[],[6001],{"type":44,"value":504},{"type":44,"value":362},{"type":38,"tag":53,"props":6004,"children":6006},{"className":6005},[],[6007],{"type":44,"value":497},{"type":38,"tag":250,"props":6009,"children":6011},{"className":6010},[5667],[6012,6015,6016,6022,6023,6029,6031,6037],{"type":38,"tag":5670,"props":6013,"children":6014},{"disabled":1588,"type":5672},[],{"type":44,"value":317},{"type":38,"tag":53,"props":6017,"children":6019},{"className":6018},[],[6020],{"type":44,"value":6021},"lineHeight",{"type":44,"value":681},{"type":38,"tag":53,"props":6024,"children":6026},{"className":6025},[],[6027],{"type":44,"value":6028},"letterSpacing",{"type":44,"value":6030}," use ",{"type":38,"tag":53,"props":6032,"children":6034},{"className":6033},[],[6035],{"type":44,"value":6036},"{unit, value}",{"type":44,"value":6038}," format (not bare numbers)",{"type":38,"tag":250,"props":6040,"children":6042},{"className":6041},[5667],[6043,6046,6047,6052],{"type":38,"tag":5670,"props":6044,"children":6045},{"disabled":1588,"type":5672},[],{"type":44,"value":317},{"type":38,"tag":53,"props":6048,"children":6050},{"className":6049},[],[6051],{"type":44,"value":3663},{"type":44,"value":6053}," is called BEFORE setting sizing modes (resize resets them to FIXED)",{"type":38,"tag":250,"props":6055,"children":6057},{"className":6056},[5667],[6058,6061],{"type":38,"tag":5670,"props":6059,"children":6060},{"disabled":1588,"type":5672},[],{"type":44,"value":6062}," For multi-step workflows: IDs from previous calls are passed as string literals (not variables)",{"type":38,"tag":250,"props":6064,"children":6066},{"className":6065},[5667],[6067,6070],{"type":38,"tag":5670,"props":6068,"children":6069},{"disabled":1588,"type":5672},[],{"type":44,"value":6071}," New top-level nodes are positioned away from (0,0) to avoid overlapping existing content",{"type":38,"tag":250,"props":6073,"children":6075},{"className":6074},[5667],[6076,6079,6081,6086],{"type":38,"tag":5670,"props":6077,"children":6078},{"disabled":1588,"type":5672},[],{"type":44,"value":6080}," Containers with structurally-related children use ",{"type":38,"tag":53,"props":6082,"children":6084},{"className":6083},[],[6085],{"type":44,"value":717},{"type":44,"value":6087},", not absolute x\u002Fy (see Rule 12a)",{"type":38,"tag":250,"props":6089,"children":6091},{"className":6090},[5667],[6092,6095,6097,6102],{"type":38,"tag":5670,"props":6093,"children":6094},{"disabled":1588,"type":5672},[],{"type":44,"value":6096}," ALL created\u002Fmutated node IDs are collected and included in the ",{"type":38,"tag":53,"props":6098,"children":6100},{"className":6099},[],[6101],{"type":44,"value":263},{"type":44,"value":6103}," value",{"type":38,"tag":250,"props":6105,"children":6107},{"className":6106},[5667],[6108,6111,6113,6118,6119,6124,6125,6131,6133,6138],{"type":38,"tag":5670,"props":6109,"children":6110},{"disabled":1588,"type":5672},[],{"type":44,"value":6112}," Every async call (",{"type":38,"tag":53,"props":6114,"children":6116},{"className":6115},[],[6117],{"type":44,"value":5924},{"type":44,"value":477},{"type":38,"tag":53,"props":6120,"children":6122},{"className":6121},[],[6123],{"type":44,"value":1348},{"type":44,"value":477},{"type":38,"tag":53,"props":6126,"children":6128},{"className":6127},[],[6129],{"type":44,"value":6130},"importComponentByKeyAsync",{"type":44,"value":6132},", etc.) is ",{"type":38,"tag":53,"props":6134,"children":6136},{"className":6135},[],[6137],{"type":44,"value":289},{"type":44,"value":6139},"ed — no fire-and-forget Promises",{"type":38,"tag":239,"props":6141,"children":6143},{"id":6142},"_9-discover-conventions-before-creating",[6144],{"type":44,"value":6145},"9. Discover Conventions Before Creating",{"type":38,"tag":47,"props":6147,"children":6148},{},[6149,6154],{"type":38,"tag":73,"props":6150,"children":6151},{},[6152],{"type":44,"value":6153},"Always inspect the Figma file before creating anything.",{"type":44,"value":6155}," Different files use different naming conventions, variable structures, and component patterns. Your code should match what's already there, not impose new conventions.",{"type":38,"tag":47,"props":6157,"children":6158},{},[6159],{"type":44,"value":6160},"When in doubt about any convention (naming, scoping, structure), check the Figma file first, then the user's codebase. Only fall back to common patterns when neither exists.",{"type":38,"tag":1138,"props":6162,"children":6164},{"id":6163},"quick-inspection-scripts",[6165],{"type":44,"value":6166},"Quick inspection scripts",{"type":38,"tag":47,"props":6168,"children":6169},{},[6170],{"type":38,"tag":73,"props":6171,"children":6172},{},[6173],{"type":44,"value":6174},"List all pages and top-level nodes:",{"type":38,"tag":1183,"props":6176,"children":6178},{"className":1185,"code":6177,"language":1187,"meta":1188,"style":1188},"const pages = figma.root.children.map(p => `${p.name} id=${p.id} children=${p.children.length}`);\nreturn pages.join('\\n');\n",[6179],{"type":38,"tag":53,"props":6180,"children":6181},{"__ignoreMap":1188},[6182,6329],{"type":38,"tag":1194,"props":6183,"children":6184},{"class":1196,"line":1197},[6185,6189,6194,6198,6202,6206,6210,6214,6218,6222,6227,6231,6235,6239,6244,6248,6252,6256,6260,6265,6269,6273,6277,6282,6286,6291,6295,6299,6303,6307,6311,6316,6321,6325],{"type":38,"tag":1194,"props":6186,"children":6187},{"style":1211},[6188],{"type":44,"value":1214},{"type":38,"tag":1194,"props":6190,"children":6191},{"style":1217},[6192],{"type":44,"value":6193}," pages ",{"type":38,"tag":1194,"props":6195,"children":6196},{"style":1223},[6197],{"type":44,"value":1226},{"type":38,"tag":1194,"props":6199,"children":6200},{"style":1217},[6201],{"type":44,"value":1231},{"type":38,"tag":1194,"props":6203,"children":6204},{"style":1223},[6205],{"type":44,"value":68},{"type":38,"tag":1194,"props":6207,"children":6208},{"style":1217},[6209],{"type":44,"value":35},{"type":38,"tag":1194,"props":6211,"children":6212},{"style":1223},[6213],{"type":44,"value":68},{"type":38,"tag":1194,"props":6215,"children":6216},{"style":1217},[6217],{"type":44,"value":1248},{"type":38,"tag":1194,"props":6219,"children":6220},{"style":1223},[6221],{"type":44,"value":68},{"type":38,"tag":1194,"props":6223,"children":6224},{"style":1255},[6225],{"type":44,"value":6226},"map",{"type":38,"tag":1194,"props":6228,"children":6229},{"style":1217},[6230],{"type":44,"value":1263},{"type":38,"tag":1194,"props":6232,"children":6233},{"style":1270},[6234],{"type":44,"value":47},{"type":38,"tag":1194,"props":6236,"children":6237},{"style":1211},[6238],{"type":44,"value":1282},{"type":38,"tag":1194,"props":6240,"children":6241},{"style":1223},[6242],{"type":44,"value":6243}," `${",{"type":38,"tag":1194,"props":6245,"children":6246},{"style":1217},[6247],{"type":44,"value":47},{"type":38,"tag":1194,"props":6249,"children":6250},{"style":1223},[6251],{"type":44,"value":68},{"type":38,"tag":1194,"props":6253,"children":6254},{"style":1217},[6255],{"type":44,"value":3127},{"type":38,"tag":1194,"props":6257,"children":6258},{"style":1223},[6259],{"type":44,"value":3038},{"type":38,"tag":1194,"props":6261,"children":6262},{"style":1309},[6263],{"type":44,"value":6264}," id=",{"type":38,"tag":1194,"props":6266,"children":6267},{"style":1223},[6268],{"type":44,"value":3316},{"type":38,"tag":1194,"props":6270,"children":6271},{"style":1217},[6272],{"type":44,"value":47},{"type":38,"tag":1194,"props":6274,"children":6275},{"style":1223},[6276],{"type":44,"value":68},{"type":38,"tag":1194,"props":6278,"children":6279},{"style":1217},[6280],{"type":44,"value":6281},"id",{"type":38,"tag":1194,"props":6283,"children":6284},{"style":1223},[6285],{"type":44,"value":3038},{"type":38,"tag":1194,"props":6287,"children":6288},{"style":1309},[6289],{"type":44,"value":6290}," children=",{"type":38,"tag":1194,"props":6292,"children":6293},{"style":1223},[6294],{"type":44,"value":3316},{"type":38,"tag":1194,"props":6296,"children":6297},{"style":1217},[6298],{"type":44,"value":47},{"type":38,"tag":1194,"props":6300,"children":6301},{"style":1223},[6302],{"type":44,"value":68},{"type":38,"tag":1194,"props":6304,"children":6305},{"style":1217},[6306],{"type":44,"value":1248},{"type":38,"tag":1194,"props":6308,"children":6309},{"style":1223},[6310],{"type":44,"value":68},{"type":38,"tag":1194,"props":6312,"children":6313},{"style":1217},[6314],{"type":44,"value":6315},"length",{"type":38,"tag":1194,"props":6317,"children":6318},{"style":1223},[6319],{"type":44,"value":6320},"}`",{"type":38,"tag":1194,"props":6322,"children":6323},{"style":1217},[6324],{"type":44,"value":1277},{"type":38,"tag":1194,"props":6326,"children":6327},{"style":1223},[6328],{"type":44,"value":1326},{"type":38,"tag":1194,"props":6330,"children":6331},{"class":1196,"line":1207},[6332,6336,6341,6345,6350,6354,6358,6363,6367,6371],{"type":38,"tag":1194,"props":6333,"children":6334},{"style":1333},[6335],{"type":44,"value":263},{"type":38,"tag":1194,"props":6337,"children":6338},{"style":1217},[6339],{"type":44,"value":6340}," pages",{"type":38,"tag":1194,"props":6342,"children":6343},{"style":1223},[6344],{"type":44,"value":68},{"type":38,"tag":1194,"props":6346,"children":6347},{"style":1255},[6348],{"type":44,"value":6349},"join",{"type":38,"tag":1194,"props":6351,"children":6352},{"style":1217},[6353],{"type":44,"value":1263},{"type":38,"tag":1194,"props":6355,"children":6356},{"style":1223},[6357],{"type":44,"value":2135},{"type":38,"tag":1194,"props":6359,"children":6360},{"style":1217},[6361],{"type":44,"value":6362},"\\n",{"type":38,"tag":1194,"props":6364,"children":6365},{"style":1223},[6366],{"type":44,"value":2135},{"type":38,"tag":1194,"props":6368,"children":6369},{"style":1217},[6370],{"type":44,"value":1277},{"type":38,"tag":1194,"props":6372,"children":6373},{"style":1223},[6374],{"type":44,"value":1326},{"type":38,"tag":47,"props":6376,"children":6377},{},[6378],{"type":38,"tag":73,"props":6379,"children":6380},{},[6381],{"type":44,"value":6382},"List existing components across all pages:",{"type":38,"tag":47,"props":6384,"children":6385},{},[6386,6391,6393],{"type":38,"tag":53,"props":6387,"children":6389},{"className":6388},[],[6390],{"type":44,"value":176},{"type":44,"value":6392}," is an option for published components. For on-canvas components, use the two-step fan-out — ",{"type":38,"tag":73,"props":6394,"children":6395},{},[6396],{"type":44,"value":6397},"don't loop pages inside one script.",{"type":38,"tag":47,"props":6399,"children":6400},{},[6401,6403,6408],{"type":44,"value":6402},"Step 1: one read-only ",{"type":38,"tag":53,"props":6404,"children":6406},{"className":6405},[],[6407],{"type":44,"value":58},{"type":44,"value":6409}," to get page IDs:",{"type":38,"tag":1183,"props":6411,"children":6413},{"className":1185,"code":6412,"language":1187,"meta":1188,"style":1188},"return figma.root.children.map(p => ({ id: p.id, name: p.name }));\n",[6414],{"type":38,"tag":53,"props":6415,"children":6416},{"__ignoreMap":1188},[6417],{"type":38,"tag":1194,"props":6418,"children":6419},{"class":1196,"line":1197},[6420,6424,6428,6432,6436,6440,6444,6448,6452,6456,6460,6464,6468,6472,6477,6481,6485,6489,6493,6497,6501,6505,6509,6513,6517,6521,6526],{"type":38,"tag":1194,"props":6421,"children":6422},{"style":1333},[6423],{"type":44,"value":263},{"type":38,"tag":1194,"props":6425,"children":6426},{"style":1217},[6427],{"type":44,"value":1231},{"type":38,"tag":1194,"props":6429,"children":6430},{"style":1223},[6431],{"type":44,"value":68},{"type":38,"tag":1194,"props":6433,"children":6434},{"style":1217},[6435],{"type":44,"value":35},{"type":38,"tag":1194,"props":6437,"children":6438},{"style":1223},[6439],{"type":44,"value":68},{"type":38,"tag":1194,"props":6441,"children":6442},{"style":1217},[6443],{"type":44,"value":1248},{"type":38,"tag":1194,"props":6445,"children":6446},{"style":1223},[6447],{"type":44,"value":68},{"type":38,"tag":1194,"props":6449,"children":6450},{"style":1255},[6451],{"type":44,"value":6226},{"type":38,"tag":1194,"props":6453,"children":6454},{"style":1217},[6455],{"type":44,"value":1263},{"type":38,"tag":1194,"props":6457,"children":6458},{"style":1270},[6459],{"type":44,"value":47},{"type":38,"tag":1194,"props":6461,"children":6462},{"style":1211},[6463],{"type":44,"value":1282},{"type":38,"tag":1194,"props":6465,"children":6466},{"style":1217},[6467],{"type":44,"value":1486},{"type":38,"tag":1194,"props":6469,"children":6470},{"style":1223},[6471],{"type":44,"value":2929},{"type":38,"tag":1194,"props":6473,"children":6474},{"style":1549},[6475],{"type":44,"value":6476}," id",{"type":38,"tag":1194,"props":6478,"children":6479},{"style":1223},[6480],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6482,"children":6483},{"style":1217},[6484],{"type":44,"value":1287},{"type":38,"tag":1194,"props":6486,"children":6487},{"style":1223},[6488],{"type":44,"value":68},{"type":38,"tag":1194,"props":6490,"children":6491},{"style":1217},[6492],{"type":44,"value":6281},{"type":38,"tag":1194,"props":6494,"children":6495},{"style":1223},[6496],{"type":44,"value":2956},{"type":38,"tag":1194,"props":6498,"children":6499},{"style":1549},[6500],{"type":44,"value":3600},{"type":38,"tag":1194,"props":6502,"children":6503},{"style":1223},[6504],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6506,"children":6507},{"style":1217},[6508],{"type":44,"value":1287},{"type":38,"tag":1194,"props":6510,"children":6511},{"style":1223},[6512],{"type":44,"value":68},{"type":38,"tag":1194,"props":6514,"children":6515},{"style":1217},[6516],{"type":44,"value":1296},{"type":38,"tag":1194,"props":6518,"children":6519},{"style":1223},[6520],{"type":44,"value":3038},{"type":38,"tag":1194,"props":6522,"children":6523},{"style":1217},[6524],{"type":44,"value":6525},"))",{"type":38,"tag":1194,"props":6527,"children":6528},{"style":1223},[6529],{"type":44,"value":1326},{"type":38,"tag":47,"props":6531,"children":6532},{},[6533,6535,6547],{"type":44,"value":6534},"Step 2: in the ",{"type":38,"tag":73,"props":6536,"children":6537},{},[6538,6540,6545],{"type":44,"value":6539},"next assistant turn, emit one ",{"type":38,"tag":53,"props":6541,"children":6543},{"className":6542},[],[6544],{"type":44,"value":58},{"type":44,"value":6546}," per page in parallel",{"type":44,"value":6548}," (a single message containing N tool-use blocks). Each runs:",{"type":38,"tag":1183,"props":6550,"children":6552},{"className":1185,"code":6551,"language":1187,"meta":1188,"style":1188},"const page = await figma.getNodeByIdAsync(PAGE_ID);\nawait figma.setCurrentPageAsync(page);\n\u002F\u002F findAllWithCriteria uses an indexed type lookup — hundreds of times faster\n\u002F\u002F than the findAll(n => n.type === '…') side-effect-in-predicate antipattern.\nconst matches = page.findAllWithCriteria({ types: ['COMPONENT', 'COMPONENT_SET'] });\nreturn matches.map(n => ({ page: page.name, name: n.name, type: n.type, id: n.id }));\n",[6553],{"type":38,"tag":53,"props":6554,"children":6555},{"__ignoreMap":1188},[6556,6598,6626,6634,6642,6739],{"type":38,"tag":1194,"props":6557,"children":6558},{"class":1196,"line":1197},[6559,6563,6567,6571,6576,6580,6584,6589,6594],{"type":38,"tag":1194,"props":6560,"children":6561},{"style":1211},[6562],{"type":44,"value":1214},{"type":38,"tag":1194,"props":6564,"children":6565},{"style":1217},[6566],{"type":44,"value":1495},{"type":38,"tag":1194,"props":6568,"children":6569},{"style":1223},[6570],{"type":44,"value":1226},{"type":38,"tag":1194,"props":6572,"children":6573},{"style":1333},[6574],{"type":44,"value":6575}," await",{"type":38,"tag":1194,"props":6577,"children":6578},{"style":1217},[6579],{"type":44,"value":1231},{"type":38,"tag":1194,"props":6581,"children":6582},{"style":1223},[6583],{"type":44,"value":68},{"type":38,"tag":1194,"props":6585,"children":6586},{"style":1255},[6587],{"type":44,"value":6588},"getNodeByIdAsync",{"type":38,"tag":1194,"props":6590,"children":6591},{"style":1217},[6592],{"type":44,"value":6593},"(PAGE_ID)",{"type":38,"tag":1194,"props":6595,"children":6596},{"style":1223},[6597],{"type":44,"value":1326},{"type":38,"tag":1194,"props":6599,"children":6600},{"class":1196,"line":1207},[6601,6605,6609,6613,6617,6622],{"type":38,"tag":1194,"props":6602,"children":6603},{"style":1333},[6604],{"type":44,"value":289},{"type":38,"tag":1194,"props":6606,"children":6607},{"style":1217},[6608],{"type":44,"value":1231},{"type":38,"tag":1194,"props":6610,"children":6611},{"style":1223},[6612],{"type":44,"value":68},{"type":38,"tag":1194,"props":6614,"children":6615},{"style":1255},[6616],{"type":44,"value":1348},{"type":38,"tag":1194,"props":6618,"children":6619},{"style":1217},[6620],{"type":44,"value":6621},"(page)",{"type":38,"tag":1194,"props":6623,"children":6624},{"style":1223},[6625],{"type":44,"value":1326},{"type":38,"tag":1194,"props":6627,"children":6628},{"class":1196,"line":1329},[6629],{"type":38,"tag":1194,"props":6630,"children":6631},{"style":1201},[6632],{"type":44,"value":6633},"\u002F\u002F findAllWithCriteria uses an indexed type lookup — hundreds of times faster\n",{"type":38,"tag":1194,"props":6635,"children":6636},{"class":1196,"line":1360},[6637],{"type":38,"tag":1194,"props":6638,"children":6639},{"style":1201},[6640],{"type":44,"value":6641},"\u002F\u002F than the findAll(n => n.type === '…') side-effect-in-predicate antipattern.\n",{"type":38,"tag":1194,"props":6643,"children":6644},{"class":1196,"line":1575},[6645,6649,6654,6658,6663,6667,6672,6676,6680,6685,6689,6693,6697,6701,6705,6709,6713,6718,6722,6727,6731,6735],{"type":38,"tag":1194,"props":6646,"children":6647},{"style":1211},[6648],{"type":44,"value":1214},{"type":38,"tag":1194,"props":6650,"children":6651},{"style":1217},[6652],{"type":44,"value":6653}," matches ",{"type":38,"tag":1194,"props":6655,"children":6656},{"style":1223},[6657],{"type":44,"value":1226},{"type":38,"tag":1194,"props":6659,"children":6660},{"style":1217},[6661],{"type":44,"value":6662}," page",{"type":38,"tag":1194,"props":6664,"children":6665},{"style":1223},[6666],{"type":44,"value":68},{"type":38,"tag":1194,"props":6668,"children":6669},{"style":1255},[6670],{"type":44,"value":6671},"findAllWithCriteria",{"type":38,"tag":1194,"props":6673,"children":6674},{"style":1217},[6675],{"type":44,"value":1263},{"type":38,"tag":1194,"props":6677,"children":6678},{"style":1223},[6679],{"type":44,"value":2929},{"type":38,"tag":1194,"props":6681,"children":6682},{"style":1549},[6683],{"type":44,"value":6684}," types",{"type":38,"tag":1194,"props":6686,"children":6687},{"style":1223},[6688],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6690,"children":6691},{"style":1217},[6692],{"type":44,"value":2924},{"type":38,"tag":1194,"props":6694,"children":6695},{"style":1223},[6696],{"type":44,"value":2135},{"type":38,"tag":1194,"props":6698,"children":6699},{"style":1309},[6700],{"type":44,"value":2287},{"type":38,"tag":1194,"props":6702,"children":6703},{"style":1223},[6704],{"type":44,"value":2135},{"type":38,"tag":1194,"props":6706,"children":6707},{"style":1223},[6708],{"type":44,"value":2956},{"type":38,"tag":1194,"props":6710,"children":6711},{"style":1223},[6712],{"type":44,"value":2126},{"type":38,"tag":1194,"props":6714,"children":6715},{"style":1309},[6716],{"type":44,"value":6717},"COMPONENT_SET",{"type":38,"tag":1194,"props":6719,"children":6720},{"style":1223},[6721],{"type":44,"value":2135},{"type":38,"tag":1194,"props":6723,"children":6724},{"style":1217},[6725],{"type":44,"value":6726},"] ",{"type":38,"tag":1194,"props":6728,"children":6729},{"style":1223},[6730],{"type":44,"value":3038},{"type":38,"tag":1194,"props":6732,"children":6733},{"style":1217},[6734],{"type":44,"value":1277},{"type":38,"tag":1194,"props":6736,"children":6737},{"style":1223},[6738],{"type":44,"value":1326},{"type":38,"tag":1194,"props":6740,"children":6741},{"class":1196,"line":1584},[6742,6746,6751,6755,6759,6763,6767,6771,6775,6779,6783,6787,6791,6795,6799,6803,6807,6811,6815,6819,6823,6827,6832,6836,6840,6844,6848,6852,6856,6860,6864,6868,6873,6877,6881],{"type":38,"tag":1194,"props":6743,"children":6744},{"style":1333},[6745],{"type":44,"value":263},{"type":38,"tag":1194,"props":6747,"children":6748},{"style":1217},[6749],{"type":44,"value":6750}," matches",{"type":38,"tag":1194,"props":6752,"children":6753},{"style":1223},[6754],{"type":44,"value":68},{"type":38,"tag":1194,"props":6756,"children":6757},{"style":1255},[6758],{"type":44,"value":6226},{"type":38,"tag":1194,"props":6760,"children":6761},{"style":1217},[6762],{"type":44,"value":1263},{"type":38,"tag":1194,"props":6764,"children":6765},{"style":1270},[6766],{"type":44,"value":2099},{"type":38,"tag":1194,"props":6768,"children":6769},{"style":1211},[6770],{"type":44,"value":1282},{"type":38,"tag":1194,"props":6772,"children":6773},{"style":1217},[6774],{"type":44,"value":1486},{"type":38,"tag":1194,"props":6776,"children":6777},{"style":1223},[6778],{"type":44,"value":2929},{"type":38,"tag":1194,"props":6780,"children":6781},{"style":1549},[6782],{"type":44,"value":6662},{"type":38,"tag":1194,"props":6784,"children":6785},{"style":1223},[6786],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6788,"children":6789},{"style":1217},[6790],{"type":44,"value":6662},{"type":38,"tag":1194,"props":6792,"children":6793},{"style":1223},[6794],{"type":44,"value":68},{"type":38,"tag":1194,"props":6796,"children":6797},{"style":1217},[6798],{"type":44,"value":3127},{"type":38,"tag":1194,"props":6800,"children":6801},{"style":1223},[6802],{"type":44,"value":2956},{"type":38,"tag":1194,"props":6804,"children":6805},{"style":1549},[6806],{"type":44,"value":3600},{"type":38,"tag":1194,"props":6808,"children":6809},{"style":1223},[6810],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6812,"children":6813},{"style":1217},[6814],{"type":44,"value":2108},{"type":38,"tag":1194,"props":6816,"children":6817},{"style":1223},[6818],{"type":44,"value":68},{"type":38,"tag":1194,"props":6820,"children":6821},{"style":1217},[6822],{"type":44,"value":3127},{"type":38,"tag":1194,"props":6824,"children":6825},{"style":1223},[6826],{"type":44,"value":2956},{"type":38,"tag":1194,"props":6828,"children":6829},{"style":1549},[6830],{"type":44,"value":6831}," type",{"type":38,"tag":1194,"props":6833,"children":6834},{"style":1223},[6835],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6837,"children":6838},{"style":1217},[6839],{"type":44,"value":2108},{"type":38,"tag":1194,"props":6841,"children":6842},{"style":1223},[6843],{"type":44,"value":68},{"type":38,"tag":1194,"props":6845,"children":6846},{"style":1217},[6847],{"type":44,"value":2934},{"type":38,"tag":1194,"props":6849,"children":6850},{"style":1223},[6851],{"type":44,"value":2956},{"type":38,"tag":1194,"props":6853,"children":6854},{"style":1549},[6855],{"type":44,"value":6476},{"type":38,"tag":1194,"props":6857,"children":6858},{"style":1223},[6859],{"type":44,"value":2919},{"type":38,"tag":1194,"props":6861,"children":6862},{"style":1217},[6863],{"type":44,"value":2108},{"type":38,"tag":1194,"props":6865,"children":6866},{"style":1223},[6867],{"type":44,"value":68},{"type":38,"tag":1194,"props":6869,"children":6870},{"style":1217},[6871],{"type":44,"value":6872},"id ",{"type":38,"tag":1194,"props":6874,"children":6875},{"style":1223},[6876],{"type":44,"value":3038},{"type":38,"tag":1194,"props":6878,"children":6879},{"style":1217},[6880],{"type":44,"value":6525},{"type":38,"tag":1194,"props":6882,"children":6883},{"style":1223},[6884],{"type":44,"value":1326},{"type":38,"tag":47,"props":6886,"children":6887},{},[6888],{"type":38,"tag":73,"props":6889,"children":6890},{},[6891],{"type":44,"value":6892},"List existing variable collections and their conventions:",{"type":38,"tag":1183,"props":6894,"children":6896},{"className":1185,"code":6895,"language":1187,"meta":1188,"style":1188},"const collections = await figma.variables.getLocalVariableCollectionsAsync();\nconst results = collections.map(c => ({\n  name: c.name, id: c.id,\n  varCount: c.variableIds.length,\n  modes: c.modes.map(m => m.name)\n}));\nreturn results;\n",[6897],{"type":38,"tag":53,"props":6898,"children":6899},{"__ignoreMap":1188},[6900,6951,7001,7054,7091,7151,7166],{"type":38,"tag":1194,"props":6901,"children":6902},{"class":1196,"line":1197},[6903,6907,6912,6916,6920,6924,6928,6933,6937,6942,6947],{"type":38,"tag":1194,"props":6904,"children":6905},{"style":1211},[6906],{"type":44,"value":1214},{"type":38,"tag":1194,"props":6908,"children":6909},{"style":1217},[6910],{"type":44,"value":6911}," collections ",{"type":38,"tag":1194,"props":6913,"children":6914},{"style":1223},[6915],{"type":44,"value":1226},{"type":38,"tag":1194,"props":6917,"children":6918},{"style":1333},[6919],{"type":44,"value":6575},{"type":38,"tag":1194,"props":6921,"children":6922},{"style":1217},[6923],{"type":44,"value":1231},{"type":38,"tag":1194,"props":6925,"children":6926},{"style":1223},[6927],{"type":44,"value":68},{"type":38,"tag":1194,"props":6929,"children":6930},{"style":1217},[6931],{"type":44,"value":6932},"variables",{"type":38,"tag":1194,"props":6934,"children":6935},{"style":1223},[6936],{"type":44,"value":68},{"type":38,"tag":1194,"props":6938,"children":6939},{"style":1255},[6940],{"type":44,"value":6941},"getLocalVariableCollectionsAsync",{"type":38,"tag":1194,"props":6943,"children":6944},{"style":1217},[6945],{"type":44,"value":6946},"()",{"type":38,"tag":1194,"props":6948,"children":6949},{"style":1223},[6950],{"type":44,"value":1326},{"type":38,"tag":1194,"props":6952,"children":6953},{"class":1196,"line":1207},[6954,6958,6963,6967,6972,6976,6980,6984,6989,6993,6997],{"type":38,"tag":1194,"props":6955,"children":6956},{"style":1211},[6957],{"type":44,"value":1214},{"type":38,"tag":1194,"props":6959,"children":6960},{"style":1217},[6961],{"type":44,"value":6962}," results ",{"type":38,"tag":1194,"props":6964,"children":6965},{"style":1223},[6966],{"type":44,"value":1226},{"type":38,"tag":1194,"props":6968,"children":6969},{"style":1217},[6970],{"type":44,"value":6971}," collections",{"type":38,"tag":1194,"props":6973,"children":6974},{"style":1223},[6975],{"type":44,"value":68},{"type":38,"tag":1194,"props":6977,"children":6978},{"style":1255},[6979],{"type":44,"value":6226},{"type":38,"tag":1194,"props":6981,"children":6982},{"style":1217},[6983],{"type":44,"value":1263},{"type":38,"tag":1194,"props":6985,"children":6986},{"style":1270},[6987],{"type":44,"value":6988},"c",{"type":38,"tag":1194,"props":6990,"children":6991},{"style":1211},[6992],{"type":44,"value":1282},{"type":38,"tag":1194,"props":6994,"children":6995},{"style":1217},[6996],{"type":44,"value":1486},{"type":38,"tag":1194,"props":6998,"children":6999},{"style":1223},[7000],{"type":44,"value":1526},{"type":38,"tag":1194,"props":7002,"children":7003},{"class":1196,"line":1329},[7004,7009,7013,7018,7022,7026,7030,7034,7038,7042,7046,7050],{"type":38,"tag":1194,"props":7005,"children":7006},{"style":1549},[7007],{"type":44,"value":7008},"  name",{"type":38,"tag":1194,"props":7010,"children":7011},{"style":1223},[7012],{"type":44,"value":2919},{"type":38,"tag":1194,"props":7014,"children":7015},{"style":1217},[7016],{"type":44,"value":7017}," c",{"type":38,"tag":1194,"props":7019,"children":7020},{"style":1223},[7021],{"type":44,"value":68},{"type":38,"tag":1194,"props":7023,"children":7024},{"style":1217},[7025],{"type":44,"value":3127},{"type":38,"tag":1194,"props":7027,"children":7028},{"style":1223},[7029],{"type":44,"value":2956},{"type":38,"tag":1194,"props":7031,"children":7032},{"style":1549},[7033],{"type":44,"value":6476},{"type":38,"tag":1194,"props":7035,"children":7036},{"style":1223},[7037],{"type":44,"value":2919},{"type":38,"tag":1194,"props":7039,"children":7040},{"style":1217},[7041],{"type":44,"value":7017},{"type":38,"tag":1194,"props":7043,"children":7044},{"style":1223},[7045],{"type":44,"value":68},{"type":38,"tag":1194,"props":7047,"children":7048},{"style":1217},[7049],{"type":44,"value":6281},{"type":38,"tag":1194,"props":7051,"children":7052},{"style":1223},[7053],{"type":44,"value":3913},{"type":38,"tag":1194,"props":7055,"children":7056},{"class":1196,"line":1360},[7057,7062,7066,7070,7074,7079,7083,7087],{"type":38,"tag":1194,"props":7058,"children":7059},{"style":1549},[7060],{"type":44,"value":7061},"  varCount",{"type":38,"tag":1194,"props":7063,"children":7064},{"style":1223},[7065],{"type":44,"value":2919},{"type":38,"tag":1194,"props":7067,"children":7068},{"style":1217},[7069],{"type":44,"value":7017},{"type":38,"tag":1194,"props":7071,"children":7072},{"style":1223},[7073],{"type":44,"value":68},{"type":38,"tag":1194,"props":7075,"children":7076},{"style":1217},[7077],{"type":44,"value":7078},"variableIds",{"type":38,"tag":1194,"props":7080,"children":7081},{"style":1223},[7082],{"type":44,"value":68},{"type":38,"tag":1194,"props":7084,"children":7085},{"style":1217},[7086],{"type":44,"value":6315},{"type":38,"tag":1194,"props":7088,"children":7089},{"style":1223},[7090],{"type":44,"value":3913},{"type":38,"tag":1194,"props":7092,"children":7093},{"class":1196,"line":1575},[7094,7099,7103,7107,7111,7116,7120,7124,7128,7133,7137,7142,7146],{"type":38,"tag":1194,"props":7095,"children":7096},{"style":1549},[7097],{"type":44,"value":7098},"  modes",{"type":38,"tag":1194,"props":7100,"children":7101},{"style":1223},[7102],{"type":44,"value":2919},{"type":38,"tag":1194,"props":7104,"children":7105},{"style":1217},[7106],{"type":44,"value":7017},{"type":38,"tag":1194,"props":7108,"children":7109},{"style":1223},[7110],{"type":44,"value":68},{"type":38,"tag":1194,"props":7112,"children":7113},{"style":1217},[7114],{"type":44,"value":7115},"modes",{"type":38,"tag":1194,"props":7117,"children":7118},{"style":1223},[7119],{"type":44,"value":68},{"type":38,"tag":1194,"props":7121,"children":7122},{"style":1255},[7123],{"type":44,"value":6226},{"type":38,"tag":1194,"props":7125,"children":7126},{"style":1217},[7127],{"type":44,"value":1263},{"type":38,"tag":1194,"props":7129,"children":7130},{"style":1270},[7131],{"type":44,"value":7132},"m",{"type":38,"tag":1194,"props":7134,"children":7135},{"style":1211},[7136],{"type":44,"value":1282},{"type":38,"tag":1194,"props":7138,"children":7139},{"style":1217},[7140],{"type":44,"value":7141}," m",{"type":38,"tag":1194,"props":7143,"children":7144},{"style":1223},[7145],{"type":44,"value":68},{"type":38,"tag":1194,"props":7147,"children":7148},{"style":1217},[7149],{"type":44,"value":7150},"name)\n",{"type":38,"tag":1194,"props":7152,"children":7153},{"class":1196,"line":1584},[7154,7158,7162],{"type":38,"tag":1194,"props":7155,"children":7156},{"style":1223},[7157],{"type":44,"value":3038},{"type":38,"tag":1194,"props":7159,"children":7160},{"style":1217},[7161],{"type":44,"value":6525},{"type":38,"tag":1194,"props":7163,"children":7164},{"style":1223},[7165],{"type":44,"value":1326},{"type":38,"tag":1194,"props":7167,"children":7168},{"class":1196,"line":1594},[7169,7173,7178],{"type":38,"tag":1194,"props":7170,"children":7171},{"style":1333},[7172],{"type":44,"value":263},{"type":38,"tag":1194,"props":7174,"children":7175},{"style":1217},[7176],{"type":44,"value":7177}," results",{"type":38,"tag":1194,"props":7179,"children":7180},{"style":1223},[7181],{"type":44,"value":1326},{"type":38,"tag":239,"props":7183,"children":7185},{"id":7184},"_10-reference-docs",[7186],{"type":44,"value":7187},"10. Reference Docs",{"type":38,"tag":47,"props":7189,"children":7190},{},[7191],{"type":44,"value":7192},"Load these as needed based on what your task involves:",{"type":38,"tag":2527,"props":7194,"children":7195},{},[7196,7217],{"type":38,"tag":2531,"props":7197,"children":7198},{},[7199],{"type":38,"tag":2535,"props":7200,"children":7201},{},[7202,7207,7212],{"type":38,"tag":2539,"props":7203,"children":7204},{},[7205],{"type":44,"value":7206},"Doc",{"type":38,"tag":2539,"props":7208,"children":7209},{},[7210],{"type":44,"value":7211},"When to load",{"type":38,"tag":2539,"props":7213,"children":7214},{},[7215],{"type":44,"value":7216},"What it covers",{"type":38,"tag":2550,"props":7218,"children":7219},{},[7220,7250,7272,7294,7316,7348,7370,7390,7420,7442,7462],{"type":38,"tag":2535,"props":7221,"children":7222},{},[7223,7230,7240],{"type":38,"tag":2557,"props":7224,"children":7225},{},[7226],{"type":38,"tag":163,"props":7227,"children":7228},{"href":930},[7229],{"type":44,"value":5447},{"type":38,"tag":2557,"props":7231,"children":7232},{},[7233,7235],{"type":44,"value":7234},"Before any ",{"type":38,"tag":53,"props":7236,"children":7238},{"className":7237},[],[7239],{"type":44,"value":58},{"type":38,"tag":2557,"props":7241,"children":7242},{},[7243,7245],{"type":44,"value":7244},"Every known pitfall with WRONG\u002FCORRECT code examples — start with the ",{"type":38,"tag":163,"props":7246,"children":7247},{"href":540},[7248],{"type":44,"value":7249},"canonical text-edit recipe",{"type":38,"tag":2535,"props":7251,"children":7252},{},[7253,7262,7267],{"type":38,"tag":2557,"props":7254,"children":7255},{},[7256],{"type":38,"tag":163,"props":7257,"children":7259},{"href":7258},"references\u002Fcommon-patterns.md",[7260],{"type":44,"value":7261},"common-patterns.md",{"type":38,"tag":2557,"props":7263,"children":7264},{},[7265],{"type":44,"value":7266},"Need working code examples",{"type":38,"tag":2557,"props":7268,"children":7269},{},[7270],{"type":44,"value":7271},"Script scaffolds: shapes, text, auto-layout, variables, components, multi-step workflows",{"type":38,"tag":2535,"props":7273,"children":7274},{},[7275,7284,7289],{"type":38,"tag":2557,"props":7276,"children":7277},{},[7278],{"type":38,"tag":163,"props":7279,"children":7281},{"href":7280},"references\u002Fplugin-api-patterns.md",[7282],{"type":44,"value":7283},"plugin-api-patterns.md",{"type":38,"tag":2557,"props":7285,"children":7286},{},[7287],{"type":44,"value":7288},"Creating\u002Fediting nodes",{"type":38,"tag":2557,"props":7290,"children":7291},{},[7292],{"type":44,"value":7293},"Fills, strokes, Auto Layout, effects, grouping, cloning, styles",{"type":38,"tag":2535,"props":7295,"children":7296},{},[7297,7306,7311],{"type":38,"tag":2557,"props":7298,"children":7299},{},[7300],{"type":38,"tag":163,"props":7301,"children":7303},{"href":7302},"references\u002Fapi-reference.md",[7304],{"type":44,"value":7305},"api-reference.md",{"type":38,"tag":2557,"props":7307,"children":7308},{},[7309],{"type":44,"value":7310},"Need exact API surface",{"type":38,"tag":2557,"props":7312,"children":7313},{},[7314],{"type":44,"value":7315},"Node creation, variables API, core properties, what works and what doesn't",{"type":38,"tag":2535,"props":7317,"children":7318},{},[7319,7327,7332],{"type":38,"tag":2557,"props":7320,"children":7321},{},[7322],{"type":38,"tag":163,"props":7323,"children":7324},{"href":5636},[7325],{"type":44,"value":7326},"validation-and-recovery.md",{"type":38,"tag":2557,"props":7328,"children":7329},{},[7330],{"type":44,"value":7331},"Multi-step writes or error recovery",{"type":38,"tag":2557,"props":7333,"children":7334},{},[7335,7340,7341,7346],{"type":38,"tag":53,"props":7336,"children":7338},{"className":7337},[],[7339],{"type":44,"value":5004},{"type":44,"value":5964},{"type":38,"tag":53,"props":7342,"children":7344},{"className":7343},[],[7345],{"type":44,"value":1988},{"type":44,"value":7347}," workflow, mandatory error recovery steps",{"type":38,"tag":2535,"props":7349,"children":7350},{},[7351,7360,7365],{"type":38,"tag":2557,"props":7352,"children":7353},{},[7354],{"type":38,"tag":163,"props":7355,"children":7357},{"href":7356},"references\u002Fcomponent-patterns.md",[7358],{"type":44,"value":7359},"component-patterns.md",{"type":38,"tag":2557,"props":7361,"children":7362},{},[7363],{"type":44,"value":7364},"Creating components\u002Fvariants",{"type":38,"tag":2557,"props":7366,"children":7367},{},[7368],{"type":44,"value":7369},"combineAsVariants, component properties, INSTANCE_SWAP, variant layout, discovering existing components, metadata traversal",{"type":38,"tag":2535,"props":7371,"children":7372},{},[7373,7380,7385],{"type":38,"tag":2557,"props":7374,"children":7375},{},[7376],{"type":38,"tag":163,"props":7377,"children":7378},{"href":1042},[7379],{"type":44,"value":1045},{"type":38,"tag":2557,"props":7381,"children":7382},{},[7383],{"type":44,"value":7384},"Creating\u002Fbinding variables",{"type":38,"tag":2557,"props":7386,"children":7387},{},[7388],{"type":44,"value":7389},"Collections, modes, scopes, aliasing, binding patterns, discovering existing variables",{"type":38,"tag":2535,"props":7391,"children":7392},{},[7393,7402,7407],{"type":38,"tag":2557,"props":7394,"children":7395},{},[7396],{"type":38,"tag":163,"props":7397,"children":7399},{"href":7398},"references\u002Ftext-style-patterns.md",[7400],{"type":44,"value":7401},"text-style-patterns.md",{"type":38,"tag":2557,"props":7403,"children":7404},{},[7405],{"type":44,"value":7406},"Creating\u002Fapplying text styles",{"type":38,"tag":2557,"props":7408,"children":7409},{},[7410,7412,7418],{"type":44,"value":7411},"Type ramps, font discovery via ",{"type":38,"tag":53,"props":7413,"children":7415},{"className":7414},[],[7416],{"type":44,"value":7417},"listAvailableFontsAsync",{"type":44,"value":7419},", listing styles, applying styles to nodes",{"type":38,"tag":2535,"props":7421,"children":7422},{},[7423,7432,7437],{"type":38,"tag":2557,"props":7424,"children":7425},{},[7426],{"type":38,"tag":163,"props":7427,"children":7429},{"href":7428},"references\u002Feffect-style-patterns.md",[7430],{"type":44,"value":7431},"effect-style-patterns.md",{"type":38,"tag":2557,"props":7433,"children":7434},{},[7435],{"type":44,"value":7436},"Creating\u002Fapplying effect styles",{"type":38,"tag":2557,"props":7438,"children":7439},{},[7440],{"type":44,"value":7441},"Drop shadows, listing styles, applying styles to nodes",{"type":38,"tag":2535,"props":7443,"children":7444},{},[7445,7452,7457],{"type":38,"tag":2557,"props":7446,"children":7447},{},[7448],{"type":38,"tag":163,"props":7449,"children":7450},{"href":211},[7451],{"type":44,"value":214},{"type":38,"tag":2557,"props":7453,"children":7454},{},[7455],{"type":44,"value":7456},"Need to understand the full API surface",{"type":38,"tag":2557,"props":7458,"children":7459},{},[7460],{"type":44,"value":7461},"Index of all types, methods, and properties in the Plugin API",{"type":38,"tag":2535,"props":7463,"children":7464},{},[7465,7472,7477],{"type":38,"tag":2557,"props":7466,"children":7467},{},[7468],{"type":38,"tag":163,"props":7469,"children":7470},{"href":219},[7471],{"type":44,"value":222},{"type":38,"tag":2557,"props":7473,"children":7474},{},[7475],{"type":44,"value":7476},"Need exact type signatures",{"type":38,"tag":2557,"props":7478,"children":7479},{},[7480],{"type":44,"value":7481},"Full typings file — grep for specific symbols, don't load all at once",{"type":38,"tag":239,"props":7483,"children":7485},{"id":7484},"_11-snippet-examples",[7486],{"type":44,"value":7487},"11. Snippet examples",{"type":38,"tag":47,"props":7489,"children":7490},{},[7491],{"type":44,"value":7492},"You will see snippets throughout documentation here. These snippets contain useful plugin API code that can be repurposed. Use them as is, or as starter code as you go. If there are key concepts that are best documented as generic snippets, call them out and write to disk so you can reuse in the future.",{"type":38,"tag":7494,"props":7495,"children":7496},"style",{},[7497],{"type":44,"value":7498},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"items":7500,"total":3341},[7501,7519,7532,7543,7553,7569,7582,7595,7617,7623,7639,7650],{"slug":7502,"name":7502,"fn":7503,"description":7504,"org":7505,"tags":7506,"stars":20,"repoUrl":21,"updatedAt":7518},"figma-code-connect","map Figma components to code snippets","Creates and maintains Figma Code Connect template files that map Figma components to code snippets. Use when the user mentions Code Connect, Figma component mapping, design-to-code translation, or asks to create\u002Fupdate .figma.ts or .figma.js files.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7507,7508,7511,7512,7515],{"name":18,"slug":19,"type":15},{"name":7509,"slug":7510,"type":15},"Design System","design-system",{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},"Frontend","frontend",{"name":7516,"slug":7517,"type":15},"UI Components","ui-components","2026-07-31T05:52:30.590302",{"slug":7520,"name":7520,"fn":7521,"description":7522,"org":7523,"tags":7524,"stars":20,"repoUrl":21,"updatedAt":7531},"figma-create-new-file","create new Figma or FigJam files","**MANDATORY prerequisite** — you MUST invoke this skill BEFORE every `create_new_file` tool call. NEVER call `create_new_file` directly without loading this skill first. Trigger whenever the user wants a new blank Figma file — a new design, FigJam, or Slides file — or when you need a fresh file before calling `use_figma`. Usage — \u002Ffigma-create-new-file [editorType] [fileName] (e.g. \u002Ffigma-create-new-file figjam My Whiteboard, \u002Ffigma-create-new-file slides Q3 Review)",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7525,7526,7527,7530],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7528,"slug":7529,"type":15},"Ideation","ideation",{"name":13,"slug":14,"type":15},"2026-04-06T18:11:46.464282",{"slug":7533,"name":7533,"fn":7534,"description":7535,"org":7536,"tags":7537,"stars":20,"repoUrl":21,"updatedAt":7542},"figma-design-to-code","implement Figma designs as code","**MANDATORY prerequisite** — you MUST invoke this skill BEFORE calling the `get_design_context` Figma MCP tool. You MUST trigger this skill whenever the user wants to implement, build, port, or code up a Figma design as code. Example prompts (not exhaustive) are 'implement this Figma design', 'build this screen from Figma', 'turn this Figma into code', 'design to code'. This skill provides critical instructions and steps to the agent on how to correctly implement Figma designs in code and must NOT be skipped.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7538,7539,7540,7541],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},{"name":7516,"slug":7517,"type":15},"2026-07-10T06:43:51.122606",{"slug":168,"name":168,"fn":7544,"description":7545,"org":7546,"tags":7547,"stars":20,"repoUrl":21,"updatedAt":7552},"translate code layouts into Figma","Use this skill alongside figma-use when the task involves translating an application page, view, or multi-section layout into Figma. Triggers: 'write to Figma', 'create in Figma from code', 'push page to Figma', 'take this app\u002Fpage and build it in Figma', 'create a screen', 'build a landing page in Figma', 'update the Figma screen to match code', 'convert this modal\u002Fdialog\u002Fdrawer\u002Fpanel to Figma'. This is the preferred workflow skill whenever the user wants to build or update a full page, modal, dialog, drawer, sidebar, panel, or any composed multi-section view in Figma from code or a description. Discovers design system components, variables, and styles from Code Connect files, existing screens, and library search, then imports them and assembles views incrementally section-by-section using design system tokens instead of hardcoded values.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7548,7549,7550,7551],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},{"name":7516,"slug":7517,"type":15},"2026-04-06T18:11:48.952023",{"slug":7554,"name":7554,"fn":7555,"description":7556,"org":7557,"tags":7558,"stars":20,"repoUrl":21,"updatedAt":7568},"figma-generate-diagram","generate flowcharts and architecture diagrams in Figma","MANDATORY prerequisite — load this skill BEFORE every `generate_diagram` tool call. NEVER call `generate_diagram` directly without loading this skill first. Trigger whenever the user asks to create, generate, draw, render, sketch, or build a diagram — flowchart, architecture diagram, sequence diagram, ERD or entity-relationship diagram, state diagram or state machine, gantt chart, or timeline. Also trigger when the user mentions Mermaid syntax or wants a system architecture, decision tree, dependency graph, API call flow, auth handshake, schema, or pipeline visualized in FigJam. Routes to type-specific guidance, sets universal Mermaid constraints, and tells you when to use a different diagram type or skip the tool entirely (mindmaps, pie charts, class diagrams, etc.).",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7559,7562,7563,7566,7567],{"name":7560,"slug":7561,"type":15},"Architecture","architecture",{"name":18,"slug":19,"type":15},{"name":7564,"slug":7565,"type":15},"Diagrams","diagrams",{"name":9,"slug":8,"type":15},{"name":13,"slug":14,"type":15},"2026-04-28T05:43:52.834484",{"slug":194,"name":194,"fn":7570,"description":7571,"org":7572,"tags":7573,"stars":20,"repoUrl":21,"updatedAt":7581},"build Figma design systems from code","Build or update a professional-grade design system in Figma from a codebase. Use when the user wants to create variables\u002Ftokens, build component libraries, create individual components with proper variant sets and variable bindings, set up theming (light\u002Fdark modes), document foundations, or reconcile gaps between code and Figma. Also use when the user asks to create or generate any component in Figma — even a single one — since components require proper variable foundations, variant states, and design token bindings to be production-quality. This skill teaches WHAT to build and in WHAT ORDER — it complements the `figma-use` skill which teaches HOW to call the Plugin API. Both skills should be loaded together.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7574,7575,7576,7579,7580],{"name":18,"slug":19,"type":15},{"name":7509,"slug":7510,"type":15},{"name":7577,"slug":7578,"type":15},"Documentation","documentation",{"name":9,"slug":8,"type":15},{"name":7516,"slug":7517,"type":15},"2026-07-31T05:52:28.587088",{"slug":7583,"name":7583,"fn":7584,"description":7585,"org":7586,"tags":7587,"stars":20,"repoUrl":21,"updatedAt":7594},"figma-implement-motion","implement Figma animations in production code","Translates Figma motion and animations into production-ready application code. Use when implementing animation\u002Fmotion from a Figma design — user mentions \"implement this motion\", \"add animation from Figma\", \"animate this component\", provides a Figma URL whose node is animated, or when `get_design_context` returns motion data or instructs you to call `get_motion_context`.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7588,7591,7592,7593],{"name":7589,"slug":7590,"type":15},"Animation","animation",{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},"2026-06-25T07:13:13.645254",{"slug":7596,"name":7596,"fn":7597,"description":7598,"org":7599,"tags":7600,"stars":20,"repoUrl":21,"updatedAt":7616},"figma-swiftui","translate between Figma designs and SwiftUI code","SwiftUI ↔ Figma translation. Use whenever the user mentions Swift, SwiftUI, iOS, iPhone, or iPad — in EITHER direction — translating a Figma design into SwiftUI (design → code), or pushing SwiftUI views \u002F screens \u002F tokens back into a Figma file (code → design). Triggers on phrases like 'implement this Figma design in SwiftUI', 'build this screen in Swift', 'push this SwiftUI view to Figma', 'mirror my Swift code in a Figma file', or whenever a Figma URL appears alongside `.swift` files \u002F an `.xcodeproj`. Routes to a direction-specific reference doc; loads alongside `figma-use` for the code → design path.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7601,7602,7603,7604,7607,7610,7613],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},{"name":7605,"slug":7606,"type":15},"iOS","ios",{"name":7608,"slug":7609,"type":15},"Mobile","mobile",{"name":7611,"slug":7612,"type":15},"SwiftUI","swiftui",{"name":7614,"slug":7615,"type":15},"Visual Design","visual-design","2026-06-09T07:16:28.204756",{"slug":4,"name":4,"fn":5,"description":6,"org":7618,"tags":7619,"stars":20,"repoUrl":21,"updatedAt":22},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7620,7621,7622],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":13,"slug":14,"type":15},{"slug":7624,"name":7624,"fn":7625,"description":7626,"org":7627,"tags":7628,"stars":20,"repoUrl":21,"updatedAt":7638},"figma-use-figjam","use Figma tools in FigJam context","This skill helps agents use Figma's use_figma MCP tool in the FigJam context. Can be used alongside figma-use which has foundational context for using the use_figma tool.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7629,7632,7633,7636,7637],{"name":7630,"slug":7631,"type":15},"Collaboration","collaboration",{"name":18,"slug":19,"type":15},{"name":7634,"slug":7635,"type":15},"FigJam","figjam",{"name":9,"slug":8,"type":15},{"name":13,"slug":14,"type":15},"2026-04-28T05:43:51.600727",{"slug":7640,"name":7640,"fn":7641,"description":7642,"org":7643,"tags":7644,"stars":20,"repoUrl":21,"updatedAt":7649},"figma-use-motion","animate Figma nodes with motion tools","Motion \u002F animation context for the `use_figma` MCP tool — animating Figma nodes via manual keyframes, animation styles, easing, and timeline duration. Load alongside figma-use whenever a task involves adding, editing, or inspecting animation on a node.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7645,7646,7647,7648],{"name":7589,"slug":7590,"type":15},{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":13,"slug":14,"type":15},"2026-06-25T07:13:12.398176",{"slug":2004,"name":2004,"fn":7651,"description":7652,"org":7653,"tags":7654,"stars":20,"repoUrl":21,"updatedAt":7661},"use Figma tools in Slides context","This skill helps agents use Figma's use_figma MCP tool in the Slides context. Can be used alongside figma-use which has foundational context for using the use_figma tool.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7655,7656,7657,7658],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":13,"slug":14,"type":15},{"name":7659,"slug":7660,"type":15},"Presentations","presentations","2026-05-14T06:09:42.171824",{"items":7663,"total":3341},[7664,7672,7679,7686,7693,7701,7709],{"slug":7502,"name":7502,"fn":7503,"description":7504,"org":7665,"tags":7666,"stars":20,"repoUrl":21,"updatedAt":7518},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7667,7668,7669,7670,7671],{"name":18,"slug":19,"type":15},{"name":7509,"slug":7510,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},{"name":7516,"slug":7517,"type":15},{"slug":7520,"name":7520,"fn":7521,"description":7522,"org":7673,"tags":7674,"stars":20,"repoUrl":21,"updatedAt":7531},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7675,7676,7677,7678],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7528,"slug":7529,"type":15},{"name":13,"slug":14,"type":15},{"slug":7533,"name":7533,"fn":7534,"description":7535,"org":7680,"tags":7681,"stars":20,"repoUrl":21,"updatedAt":7542},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7682,7683,7684,7685],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},{"name":7516,"slug":7517,"type":15},{"slug":168,"name":168,"fn":7544,"description":7545,"org":7687,"tags":7688,"stars":20,"repoUrl":21,"updatedAt":7552},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7689,7690,7691,7692],{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15},{"name":7516,"slug":7517,"type":15},{"slug":7554,"name":7554,"fn":7555,"description":7556,"org":7694,"tags":7695,"stars":20,"repoUrl":21,"updatedAt":7568},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7696,7697,7698,7699,7700],{"name":7560,"slug":7561,"type":15},{"name":18,"slug":19,"type":15},{"name":7564,"slug":7565,"type":15},{"name":9,"slug":8,"type":15},{"name":13,"slug":14,"type":15},{"slug":194,"name":194,"fn":7570,"description":7571,"org":7702,"tags":7703,"stars":20,"repoUrl":21,"updatedAt":7581},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7704,7705,7706,7707,7708],{"name":18,"slug":19,"type":15},{"name":7509,"slug":7510,"type":15},{"name":7577,"slug":7578,"type":15},{"name":9,"slug":8,"type":15},{"name":7516,"slug":7517,"type":15},{"slug":7583,"name":7583,"fn":7584,"description":7585,"org":7710,"tags":7711,"stars":20,"repoUrl":21,"updatedAt":7594},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[7712,7713,7714,7715],{"name":7589,"slug":7590,"type":15},{"name":18,"slug":19,"type":15},{"name":9,"slug":8,"type":15},{"name":7513,"slug":7514,"type":15}]