image-to-code
БесплатноБез исполняемых скриптовНе проверенImplement a selected image, screenshot, mockup, or Image Gen reference as a faithful, responsive frontend.
от openai★ 8 494 звезды на GitHubОб этом скилле
Image to Code
You're tasked with translating the visual target image into a high-quality, interactive website or web app.
Critical Overrides
- Refer to the Plugin router $index before proceeding.
- Follow $critical-overrides.
User Context
Before starting, load $user-context and run its preflight script when local shell access is available.
Use saved product URLs, Figma files, screenshots, reference images, codebase paths, Storybook, tokens, design systems, brand assets, component refs, browser preferences, and share targets as grounding material when relevant.
Do not inspect every saved reference. Inspect only what the current task needs.
[IMPORTANT] Previewing prototypes in ChatGPT Work Mode
Starting sites-preview is not verification. Verification requires opening http://terminal.local:4173/ in the cloud browser, inspecting the rendered page, testing primary interactions, checking browser console errors, and passing design QA.
Do not substitute HTTP health, build success, preview-service status, or deployment success for browser verification. If the cloud browser cannot be used, report verification as blocked.
For local prototype verification and design QA in ChatGPT Work Mode:
- Install dependencies if needed. The project must have an npm
devscript. sites-previewrunsnpm run dev -- --host 0.0.0.0 --port 4173 --strictPort. Thedevscript must accept those flags.- For Product Design Vite starters, use
"dev": "vite". Configure Vite withserver.host: "0.0.0.0"andserver.allowedHosts: ["terminal.local"]. Preserve an existing Sites project's supported dev script; do not replace its runtime. - From the site root, run
sites-preview start "$PWD". - Open
http://terminal.local:4173/in the cloud browser. Do not uselocalhost,127.0.0.1,0.0.0.0, HTTPS, or another port. - Verify the rendered site and its primary interactions before reporting completion.
- Keep the local preview open for the user. Do not deploy to Sites unless the user explicitly asks to share, publish, or deploy.
Workflow
CRITICAL: THIS IS NOT GUIDANCE. THIS IS A CHECKLIST TO COMPLETE.
Do not start unless you have a selected image, screenshot, mockup, or Image Gen result to recreate. A written brief is not enough.
Resolve the exact selected visual target before building.
- If the user selected a numbered
$ideateoption, use the Nth displayed generated-image result from the most recent ideation set. Do not use the original concept planning order or Image Gen prompt submission order. - Use the concept-name list from
$ideateonly when it was explicitly written in the same displayed-image order. - A generated-image result ID, selected image attachment, screenshot, mockup, or Figma frame is stronger than a bare ordinal. Prefer that exact reference when available.
- If the selected result cannot be resolved unambiguously, stop before implementation and ask the user to name the concept or reattach/select the image. Never guess and build a nearby option.
Mobile runtime exception: 1:1 fidelity applies only to app-owned content inside the device screen.
PhoneFrame,StatusBar,HomeIndicator,KeyboardDock, and the device assets are template-owned infrastructure. Preserve them even if the reference omits them, depicts different device chrome, or includes chrome in the image. Never recreate device chrome as an image asset.- If the user selected a numbered
Treat the resolved image as the design to recreate.
If the provided design is a mobile viewport, build a mobile app. When creating a fresh local app for that case, use local-prototype-preflight with
--template mobile-app. If it's unclear, default to desktop.Before planning or implementing with the
mobile-apptemplate, read itsAGENTS.mdand follow its runtime and component guidance.Review the reference design, catalog every image asset in the design, and use the Image Gen tool to create individual images for each one. Zoom in so you can catch every asset that needs to be generated.
Examples include:
- Hero images including full bleed image backgrounds
- Featured article imagery
- Thumbnails
- Decorative illustrations
- Textures and background motifs
- Logos
- Product images
- Avatars
Rules:
- CRITICAL RULE: Do not create custom div art, CSS art, inline SVGs, handcrafted SVGs, HTML element drawings, div/span shapes, CSS drawings, gradients, emoji, or text glyphs instead of real icons and image assets ever. Use the built-in Image Gen tool for images and the closest matching icon library for icons.
- If text is part of an image asset, keep it in the image asset. Examples include full bleed hero images, signs, posters, packaging, storefronts, article art, and illustrations where the type belongs to the visual itself. Do not cro
Установить image-to-code в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл image-to-code?
Implement a selected image, screenshot, mockup, or Image Gen reference as a faithful, responsive frontend.
Как установить скилл image-to-code?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл image-to-code запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic