Skip to content
Back to search

design-to-code-fidelity

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
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/penner77-rong--design-to-code-fidelity/badge.svg)](/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
  1. ---
  2. name: design-to-code-fidelity
  3. 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.
  4. ---
  5. # Design-to-code fidelity
  6. ## Core rules
  7. - Treat the selected design source as the authority. Reproduce it without creative additions.
  8. - Use the most structured evidence available. Never present an inferred rule as an explicit design definition.
  9. - Inspect only the assets relevant to the target screens and their dependencies unless the user requests a full-system audit.
  10. - 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.
  11. - State assumptions, unavailable evidence, and unverified behavior. Never claim pixel-perfect fidelity without a rendered comparison.
  12. ## 1. Establish scope and evidence
  13. 1. Identify the design source, final target screens or artboards, states, flows, viewports, source version, and code destination.
  14. 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.
  15. 3. Determine the access level:
  16. - **Structured:** tokens or variables, shared styles, components, layout constraints, and interactions are inspectable.
  17. - **Partial:** only some structured assets or properties are inspectable.
  18. - **Visual:** rendered screens or screenshots are available without reliable underlying properties.
  19. - **Documented:** specifications or design-system documentation are available without the complete source.
  20. 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.
  21. ## 2. Learn from foundations to composition
  22. Follow the strongest available evidence from the lowest reusable level upward. Keep a compact mapping of source evidence → value or behavior → code representation.
  23. ### Path A: mature design system
  24. 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.
  25. 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.
  26. 3. **Templates and screens:** Inspect hierarchy, content, section order, containers, grids, alignment, margins, gaps, padding, sizing, imagery, overlays, overflow, and responsive constraints.
  27. 4. **Flows and behavior:** Inspect navigation, scrolling, transitions, overlays, and interactive states evidenced by the source.
  28. 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.
  29. ### Path B: partial or absent design system
  30. 1. Extract observed properties from actual elements: typography, color, opacity, strokes, radii, effects, icon treatment, dimensions, padding, and spacing.
  31. 2. Identify repeated combinations across the target screens. Classify them as **inferred patterns**, not official components or tokens.
  32. 3. Connect repeated patterns across visible states and variations. Implement only states evidenced by the source or explicitly requested.
  33. 4. Inspect page and section composition, layout constraints, scrolling, and available responsive examples.
  34. 5. If nothing repeats, keep values and structures local to the screen instead of inventing a design system.
  35. 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.
  36. ## 3. Resolve conflicts and missing information
  37. Use this evidence order unless the user specifies otherwise:
  38. 1. Explicit property or override on the selected target
  39. 2. Referenced component or template definition
  40. 3. Referenced token, variable, or shared style
  41. 4. Repeated pattern across approved screens
  42. 5. Written specification
  43. 6. Visual estimate
  44. 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.
  45. ## 4. Implement without invention
  46. - Match structure, content, assets, typography, color, dimensions, spacing, alignment, borders, radii, effects, states, and interactions evidenced by the source.
  47. - Do not add or rewrite sections, controls, copy, imagery, decoration, animation, states, or behavior to make the result feel more complete.
  48. - Use supplied fonts, icons, and images. Do not silently substitute unrelated assets.
  49. - Preserve appearance while using semantic markup and appropriate accessibility behavior.
  50. - 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.
  51. ## 5. Verify and iterate
  52. 1. Render every provided viewport and relevant state after fonts and assets load.
  53. 2. Compare each rendering with the matching source through overlay, image comparison, or close side-by-side inspection when supported.
  54. 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.
  55. 4. Re-render after corrections. Test flows, variants, overflow, image cropping, and responsive examples.
  56. 5. Report:
  57. - implemented screens, states, and viewports;
  58. - comparison method used;
  59. - remaining measurable differences;
  60. - inferred rules and assumptions;
  61. - evidence that could not be accessed or verified.
  62. ## Applying the skill
  63. 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
  1. # Design-to-Code Fidelity
  2. An agent-independent workflow for turning readable design sources into code with high visual, structural, responsive, and interaction fidelity.
  3. The skill works with:
  4. - mature business design systems with tokens, components, variants, and templates;
  5. - partial design systems;
  6. - personal projects containing screens but few reusable assets;
  7. - screenshots or specifications when structured design data is unavailable.
  8. ## Core principle
  9. 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.
  10. ## Learning paths
  11. ### Mature design system
  12. 1. Survey the target screens.
  13. 2. Trace the relevant tokens, variables, modes, and shared styles.
  14. 3. Inspect the referenced components, variants, and states.
  15. 4. Learn templates, screen composition, responsive rules, and interactions.
  16. 5. Implement, render, compare, and correct.
  17. ### Partial or absent design system
  18. 1. Survey the target screens.
  19. 2. Extract observed visual properties from actual elements.
  20. 3. Identify repeated combinations as inferred patterns.
  21. 4. Connect visible states and variations.
  22. 5. Learn page composition, responsive evidence, and interactions.
  23. 6. Implement, render, compare, and correct.
  24. ## Usage
  25. Invoke the skill in an agent that supports custom skills or instruction files:
  26. > 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.
  27. Provide whatever is available:
  28. - a connected design source, exported screens, screenshots, or specifications;
  29. - the target screens, flows, and states;
  30. - an existing codebase or preferred framework;
  31. - required viewport sizes.
  32. The workflow adapts when some inputs are missing and reports assumptions and unverified details.
  33. ## Files
  34. - `SKILL.md` contains the portable workflow and fidelity rules.
  35. - `agents/openai.yaml` provides ChatGPT and Codex interface metadata.
  36. - `assets/icon.svg` provides the skill icon.
  37. Other agents may require the instructions to be copied or adapted to their own skill, rules, or system-prompt format.
  38. ## Limitations
  39. 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.
  40. ## License
  41. Released under the MIT License.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.