Back to search
design-to-code-fidelity
SkillWorks with Claude CodeGitHub
Read an accessible design source and implement or audit its selected screens in code with high visual, structural, responsive, and interaction fidelity. Use for design-to-code work from any connected design application, structured design file, prototype, specification, screenshot, or existing UI, whether the source has a mature design system, partial assets, or screens only.
Safety scan
A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.
Checked today
Badge for your README
Markdown
[](/listings/penner77-rong--design-to-code-fidelity)HTML
<a href="/listings/penner77-rong--design-to-code-fidelity"><img src="/api/listings/penner77-rong--design-to-code-fidelity/badge.svg" alt="findsafeskills safety rating" /></a>Install
i
What was scanned
The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.
SKILL.md · Manifest · 86 lines
- ---
- name: design-to-code-fidelity
- description: Read an accessible design source and implement or audit its selected screens in code with high visual, structural, responsive, and interaction fidelity. Use for design-to-code work from any connected design application, structured design file, prototype, specification, screenshot, or existing UI, whether the source has a mature design system, partial assets, or screens only.
- ---
- # Design-to-code fidelity
- ## Core rules
- - Treat the selected design source as the authority. Reproduce it without creative additions.
- - Use the most structured evidence available. Never present an inferred rule as an explicit design definition.
- - Inspect only the assets relevant to the target screens and their dependencies unless the user requests a full-system audit.
- - Use the existing codebase, framework, and conventions when provided. Reuse code where the design supplies evidence of a repeated pattern; do not force unrelated elements into one abstraction.
- - State assumptions, unavailable evidence, and unverified behavior. Never claim pixel-perfect fidelity without a rendered comparison.
- ## 1. Establish scope and evidence
- 1. Identify the design source, final target screens or artboards, states, flows, viewports, source version, and code destination.
- 2. Briefly survey the relevant source to distinguish final designs from explorations and discover repeated elements and dependencies. This survey guides the detailed bottom-up inspection; it does not replace it.
- 3. Determine the access level:
- - **Structured:** tokens or variables, shared styles, components, layout constraints, and interactions are inspectable.
- - **Partial:** only some structured assets or properties are inspectable.
- - **Visual:** rendered screens or screenshots are available without reliable underlying properties.
- - **Documented:** specifications or design-system documentation are available without the complete source.
- 4. Inventory what exists: foundations, shared styles, reusable components and states, templates, screens, assets, responsive definitions, and interaction definitions. Note missing evidence without requiring the user to create a design system first.
- ## 2. Learn from foundations to composition
- Follow the strongest available evidence from the lowest reusable level upward. Keep a compact mapping of source evidence → value or behavior → code representation.
- ### Path A: mature design system
- 1. **Relevant foundations:** Resolve referenced tokens or variables, aliases, themes or modes, and shared styles. Cover color, typography, spacing, dimensions, radii, strokes, effects, grids, and responsive values.
- 2. **Relevant components:** Inspect each component family used by the target, including anatomy, properties, nested elements, assets, variants, states, overrides, constraints, and behavior. Complete one family before the next.
- 3. **Templates and screens:** Inspect hierarchy, content, section order, containers, grids, alignment, margins, gaps, padding, sizing, imagery, overlays, overflow, and responsive constraints.
- 4. **Flows and behavior:** Inspect navigation, scrolling, transitions, overlays, and interactive states evidenced by the source.
- Do not read an entire large system by default. Start from the target screens, trace their referenced foundations and components, resolve those dependencies fully, and expand only when needed.
- ### Path B: partial or absent design system
- 1. Extract observed properties from actual elements: typography, color, opacity, strokes, radii, effects, icon treatment, dimensions, padding, and spacing.
- 2. Identify repeated combinations across the target screens. Classify them as **inferred patterns**, not official components or tokens.
- 3. Connect repeated patterns across visible states and variations. Implement only states evidenced by the source or explicitly requested.
- 4. Inspect page and section composition, layout constraints, scrolling, and available responsive examples.
- 5. If nothing repeats, keep values and structures local to the screen instead of inventing a design system.
- If only screenshots are available, measure visible facts where possible and label estimates. If only one viewport is available, responsive behavior is unresolved unless constraints or written requirements supply evidence.
- ## 3. Resolve conflicts and missing information
- Use this evidence order unless the user specifies otherwise:
- 1. Explicit property or override on the selected target
- 2. Referenced component or template definition
- 3. Referenced token, variable, or shared style
- 4. Repeated pattern across approved screens
- 5. Written specification
- 6. Visual estimate
- Inspect nearby states and related screens before inferring. Make the smallest reversible assumption only when implementation must continue, and report it. Ask for a decision when a missing asset, contradictory source, or ambiguous behavior would materially change the result.
- ## 4. Implement without invention
- - Match structure, content, assets, typography, color, dimensions, spacing, alignment, borders, radii, effects, states, and interactions evidenced by the source.
- - Do not add or rewrite sections, controls, copy, imagery, decoration, animation, states, or behavior to make the result feel more complete.
- - Use supplied fonts, icons, and images. Do not silently substitute unrelated assets.
- - Preserve appearance while using semantic markup and appropriate accessibility behavior.
- - Implement responsive compositions shown or defined by the source. At unspecified widths, use the smallest conservative reflow needed to keep the UI usable and mark it as an inference. Do not invent a distinct mobile design.
- ## 5. Verify and iterate
- 1. Render every provided viewport and relevant state after fonts and assets load.
- 2. Compare each rendering with the matching source through overlay, image comparison, or close side-by-side inspection when supported.
- 3. Correct in this order: content and hierarchy; major geometry; typography and wrapping; colors and assets; borders, radii, effects, and detailed spacing; interactions and transitions.
- 4. Re-render after corrections. Test flows, variants, overflow, image cropping, and responsive examples.
- 5. Report:
- - implemented screens, states, and viewports;
- - comparison method used;
- - remaining measurable differences;
- - inferred rules and assumptions;
- - evidence that could not be accessed or verified.
- ## Applying the skill
- When invoked, obtain or infer the minimum required inputs: the accessible design source, target screens or flows, codebase or desired stack, and target viewports. If some inputs are absent, continue with inspectable work and request only decisions that materially affect the result.
README.md · README · 64 lines
- # Design-to-Code Fidelity
- An agent-independent workflow for turning readable design sources into code with high visual, structural, responsive, and interaction fidelity.
- The skill works with:
- - mature business design systems with tokens, components, variants, and templates;
- - partial design systems;
- - personal projects containing screens but few reusable assets;
- - screenshots or specifications when structured design data is unavailable.
- ## Core principle
- Follow the strongest available evidence from the lowest reusable level upward. Treat explicit design definitions, inferred patterns, and visual estimates as different levels of evidence. Do not add unrequested design ideas.
- ## Learning paths
- ### Mature design system
- 1. Survey the target screens.
- 2. Trace the relevant tokens, variables, modes, and shared styles.
- 3. Inspect the referenced components, variants, and states.
- 4. Learn templates, screen composition, responsive rules, and interactions.
- 5. Implement, render, compare, and correct.
- ### Partial or absent design system
- 1. Survey the target screens.
- 2. Extract observed visual properties from actual elements.
- 3. Identify repeated combinations as inferred patterns.
- 4. Connect visible states and variations.
- 5. Learn page composition, responsive evidence, and interactions.
- 6. Implement, render, compare, and correct.
- ## Usage
- Invoke the skill in an agent that supports custom skills or instruction files:
- > Use Design-to-Code Fidelity to implement these selected screens. Follow the available design evidence, do not add or redesign anything, and verify the rendered result against the source.
- Provide whatever is available:
- - a connected design source, exported screens, screenshots, or specifications;
- - the target screens, flows, and states;
- - an existing codebase or preferred framework;
- - required viewport sizes.
- The workflow adapts when some inputs are missing and reports assumptions and unverified details.
- ## Files
- - `SKILL.md` contains the portable workflow and fidelity rules.
- - `agents/openai.yaml` provides ChatGPT and Codex interface metadata.
- - `assets/icon.svg` provides the skill icon.
- Other agents may require the instructions to be copied or adapted to their own skill, rules, or system-prompt format.
- ## Limitations
- Accuracy depends on the evidence the agent can access. Structured tokens, components, constraints, and prototypes support more exact implementation than screenshots alone. The skill requires assumptions and estimates to be disclosed and forbids unsupported claims of pixel-perfect fidelity.
- ## License
- Released under the MIT License.
Ratings and comments
Sign in to rate this skill.
Sign inFree to use. If it’s helped, pass it on.