Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add mythkiven/figma-ios-codegen --skill figma-ios-standard-componentsgit clone --depth 1 https://github.com/mythkiven/figma-ios-codegenWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/mythkiven/figma-ios-codegen/figma-ios-standard-components)<a href="https://agentmods.dev/skills/mythkiven/figma-ios-codegen/figma-ios-standard-components"><img src="https://agentmods.dev/badge/skills/mythkiven/figma-ios-codegen/figma-ios-standard-components/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/mythkiven/figma-ios-codegen/figma-ios-standard-components"><img src="https://agentmods.dev/badge/skills/mythkiven/figma-ios-codegen/figma-ios-standard-components.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00088 | $0.01462 |
| Opus 5 | $0.00044 | $0.00731 |
| Sonnet 5 | $0.00018 | $0.00292 |
| Haiku 4.5 | $0.00009 | $0.00146 |
Grade A, and why
figma-ios-standard-components scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 153 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Figma 标准组件类型识别
职责边界
- ✅ 识别组件是什么类型(Selector / Stepper / Toggle / Tag Group)
- ✅ 提取布局模式(水平/垂直/Flow)和结构特征(三段式、并列节点等)
- ❌ 不提取各状态的视觉特征 → 见 figma-ios-component-state-recognition
- ❌ 不生成 updateAppearance() 代码 → 同上
- ❌ 不处理业务逻辑
⚡ QUICK_REF
数据来源:design.json[node](VECTOR/INSTANCE/SYMBOL 已展开,fills/strokes/corner_radius/opacity 已规范化)
多个并列节点 + 样式不同 + 等宽 → Selector
多个并列节点 + 样式不同 + 不等宽 → Tag Group
三段式:[减] [值] [加] → Stepper
两种状态(开/关) → Toggle
生成代码前的对比流程(VECTOR 子节点)
1. 从 design.json 取出所有子节点(已含 `fills` / `strokes` / `corner_radius` / `opacity` / `vector_geometry`)
2. 对比同类节点的 `fills[].color`(`rgba` 已含 alpha)、`strokes[].color`(**无** `strokes[].visible`:不可见 stroke 阶段 1 已丢弃)、`corner_radius`
3. 验证对称性(Stepper 的减号/加号 fills 应一致)
4. 再生成代码
阶段 2 不再调 Figma REST API;所有字段都在数据包里。旧名
vector_paths/fills[].opacity/strokes[].visible不要再读。
组件类型识别
决策树
有多个并列同类节点?
└─ 是 → 节点宽度是否相等?
├─ 是 → 样式有差异? → Selector(单选 or 多选)
└─ 否 → 是否可换行? → Tag Group
有三个子节点,水平排列,左右对称?
└─ 是 → Stepper
只有两种状态(开/关),有滑块?
└─ 是 → Toggle / Switch
各类型特征
Selector(选择器)
Figma 特征:
- 多个并列节点,结构相同,样式不同(主题色 vs 灰色)
- 通常水平排列,节点等宽
分析步骤:
- 检测是否有多个并列节点 → 是
- 节点结构是否相同 → 是
- 节点样式是否有差异 → 是(颜色/边框/字体不同)
- → 识别为 Selector
变种:
- 单选 vs 多选:由业务逻辑控制,视觉识别方式一致
- 图标 + 文字 vs 纯文字:检测节点是否含 IMAGE / VECTOR 子节点
- 水平 vs 垂直:通过节点 y 坐标关系判断
Stepper(步进器)
Figma 特征:
- 三段式水平布局:[减少] [值显示] [增加]
- 左右两侧按钮结构对称(图标或文字)
- 中间是数字或文字显示区域
分析步骤:
- 是否有三个子节点 → 是
- 是否水平排列 → 是
- 左右两侧是否对称(尺寸/结构相似)→ 是
- 中间是否包含文本 → 是
- → 识别为 Stepper
变种:
- 按钮样式:纯色背景 / 图片背景 / 无背景
- 图标类型:+/-、</>、▲▼、iconfont 自定义
- 中间内容:纯数字 / 数字+单位 / 图标+数字
关键原则:不要假设固定尺寸,从 design.json[node].frame.absolute 取实际值。
Tag Group(标签组)
Figma 特征:
- 多个不等宽小按钮
- 可能换行排列(Flow Layout)
- 通常可多选
分析步骤:
- 是否有多个按钮 → 是
- 按钮宽度是否不等 → 是
- 是否可能换行 → 是
- → 识别为 Tag Group,使用
UICollectionView + LeftAlignedFlowLayout
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 153 lines · 88 tokens per session scan A 329ee8787484
figma-ios-standard-components is a skill published in the GitHub repository mythkiven/figma-ios-codegen (9 stars, last pushed 2mo ago), licensed MIT. It adds 88 tokens to every session and 1,462 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
figma-codegen
Generate framework-aware code from a Figma design. Reads the project's stack profile and emits code matching the existing framework (React/Vue/Svelte/Next/etc.) and styling (Tailwind/CSS/CSS-in-JS), reusing existing components and design tokens instead of regenerating from scratch. Triggers whenever the user wants a…
figma-build
Build a Figma design from code or a description — the reverse of figma-codegen. Reuses the connected file's existing design system (components, variables, styles) instead of drawing primitives with hardcoded values. Triggers whenever the user wants something created or updated IN Figma from code or a spec — e.g.…
unship
Compare agent-made alternatives in a local browser preview with Unship. Use for comparison setup, iteration, Canvas, selection, cleanup, and Unship installation or update troubleshooting.
flato-design-mcp-guide
Use when creating, editing, inspecting, exporting, or troubleshooting Flato designs through Flato Design MCP tools such as flatowhoami, flatogetdesigncontext, flatocreatepages, flatoupdatepages, flatoupdatecanvas, and flatoexport.
create-workflow-diagram
Create FigJam/Miro-style workflow diagrams as high-quality PNG images from plain-text workflow descriptions. Renders beautiful HTML diagrams with connected nodes, arrows, and labels, then screenshots them for sharing.
create-chatgpt-mockup
Render pixel-accurate ChatGPT mobile (iOS) screen mockups in light mode from a thread JSON. Supports user text bubbles, user image attachments, assistant markdown prose, citation chips, the OpenAI spiral logo, the Apps-SDK GPT chip in the composer, and three header styles (model-tag, plain title, "Get Plus"). Fixed…