screenshot-to-component
Skill5 starsChanged 17 days agoMITView on GitHub
Converts a screenshot, mockup, or Figma export into a production-ready UI component that reuses the project's existing design system (React/Next, Vue, Svelte, React Native, Flutter, or SwiftUI with Tailwind, CSS modules, or a component library), so the result is responsive and accessible. Use when the user shares an image of a UI and asks to build, implement, or recreate it in code.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- milad-ahmd/screenshot-to-componentword for word, first seen Nov 1, 2026
Other versions1 project uses a version of this.
Word for word · 1
- milad-ahmd/screenshot-to-component★ 0100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository56 other files it gives its agents.
- docs/llms.txtllms.txt
- a11y-fixerSkill
- ad-copy-generatorSkill
- agent-guardrailsSkill
- agent-memory-keeperSkill
- ai-slop-detectorSkill
- api-to-sdkSkill
- app-store-optimizerSkill
- architecture-doctorSkill
- brand-voice-guideSkill
- bug-detectiveSkill
- changelog-from-gitSkill
- codebase-explainerSkill
- codebase-time-machineSkill
- commit-craftSkill
- competitor-spySkill
- content-repurposerSkill
- cost-cutterSkill
- demo-recorderSkill
- dependency-doctorSkill
- dockerize-anythingSkill
- durable-agent-workflowsSkill
- e2e-flow-testerSkill
- email-campaign-writerSkill
- env-secrets-guardSkill
- gh-actions-auditorSkill
- hook-generatorSkill
- incident-commanderSkill
- influencer-outreachSkill
- instagram-growth-managerSkill
- landing-page-roasterSkill
- launch-post-writerSkill
- meeting-notes-to-ticketsSkill
- merge-conflict-resolverSkill
- migration-wizardSkill
- plan-grillerSkill
- prompt-injection-scannerSkill
- pr-reviewer-proSkill
- readme-glow-upSkill
- roast-my-githubSkill
- seo-blog-writerSkill
- skill-creator-proSkill
- skill-finderSkill
- skills-doctorSkill
- social-analytics-reporterSkill
- social-media-calendarSkill
- social-media-managerSkill
- sql-optimizerSkill
- startup-idea-validatorSkill
- tdd-loopSkill
- terse-modeSkill
- test-gap-hunterSkill
- tiktok-viral-creatorSkill
- ui-tasteSkill
- youtube-script-writerSkill
- youtube-seo-optimizerSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 37
Use the project's icon library.
- Distinctive: line 38
Use realistic placeholder content, and route strings through i18n if the project uses it.
- Distinctive: line 43
If a dev server or browser tool is available, render the component and compare it with the screenshot, then fix spacing and alignment …
- Distinctive: line 48
Don't add new UI libraries or fonts without asking.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Screenshot to Component
From a picture to code that looks like your team wrote it.
1. Learn the project's UI conventions first
- Framework and styling: Tailwind (read
tailwind.config.*for theme tokens), CSS modules, styled-components, a component library (shadcn/ui, MUI, Chakra, Ant), React Native StyleSheet, FlutterThemeData. - Existing components to reuse:
Button,Card,Input,Avatar,Icon,Modal... Searchcomponents/andui/. - Design tokens: colors, spacing scale, radii, typography, dark mode, and the icon library in use (lucide, heroicons...).
- File naming, export style, prop typing and the i18n approach.
2. Analyse the image
Break it into a component tree before writing any code:
PricingCard
├── Header (plan name, badge "Popular")
├── Price (amount, period)
├── FeatureList (icon + text) ×5
└── CTA Button (primary)Note the layout (flex or grid, alignment, gaps), the states shown (hover, active, disabled, empty, loading), and which content is static and which should be props.
3. Build
- Reuse existing components and tokens. Map the colors and spacing in the image to the nearest theme token rather than hard-coding hex or pixel values.
- Turn dynamic content into typed props with sensible defaults. Repeated items become arrays.
- Responsive: mobile first, with breakpoints that follow the project's conventions.
- Accessible: semantic elements, labels and alt text, keyboard focus states and sufficient contrast.
- Use the project's icon library. Never embed raster screenshots of icons.
- Use realistic placeholder content, and route strings through i18n if the project uses it.
4. Verify
- Type-check and lint. If Storybook exists, add a story with the main states. Otherwise add a usage example.
- If a dev server or browser tool is available, render the component and compare it with the screenshot, then fix spacing and alignment differences.
- Report which existing components were reused, the assumptions you made (exact fonts, unclear interactions) and the pieces the user should confirm.
Rules
- Don't add new UI libraries or fonts without asking.
- Pixel-perfect matters less than following the design system. If they conflict, follow the system and mention the difference.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

