pencil-to-code

pencil-to-code is a skill for Codex from JohnWayneeee/ai-agent-skills. It costs 73 tokens per session (726 once invoked), scanned A, original, MIT.

A workflow for turning Pencil design files or selected design nodes into frontend code that preserves layout, typography, images, and responsive behavior.

In plain words
What is it for?
Use it to build or refine responsive pages and reusable components from Pencil or Figma-like designs.
Why use it?
It reduces the guesswork involved in translating a visual design into code and helps prevent differences in spacing, type, backgrounds, and mobile layouts.

Skill for Codex

Written for Codex: agents/openai.yaml present.

Good fit Use it to build or refine responsive pages and reusable components from Pencil or Figma-like designs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/johnwayneeee/ai-agent-skills/pencil-to-code
Install

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.

Any agent
npx skills add JohnWayneeee/ai-agent-skills --skill pencil-to-code
Clone the repo
git clone --depth 1 https://github.com/JohnWayneeee/ai-agent-skills

Made for: Codex.

Wrote 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.

agentmods badge for pencil-to-code

README.md
[![agentmods](https://agentmods.dev/badge/skills/johnwayneeee/ai-agent-skills/pencil-to-code.svg)](https://agentmods.dev/skills/johnwayneeee/ai-agent-skills/pencil-to-code)
Your own site
<a href="https://agentmods.dev/skills/johnwayneeee/ai-agent-skills/pencil-to-code"><img src="https://agentmods.dev/badge/skills/johnwayneeee/ai-agent-skills/pencil-to-code.svg" alt="Measured on agentmods" height="20"></a>
Per session 73 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 726 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00073 $0.00726
Opus 5 $0.00036 $0.00363
Sonnet 5 $0.00015 $0.00145
Haiku 4.5 $0.00007 $0.00073

Measured 7d ago against content hash 9a94188aac8b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

pencil-to-code 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 7d 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.

skills/pencil-to-code/SKILL.md · 55 lines

How it starts

The opening of the file, as written. The whole thing — 55 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Pencil To Code

Use this skill to transfer a Pencil design into maintainable frontend code without losing layout, typography, background treatment, or responsive intent.

Workflow

  1. Read the design contract first

    • Use Pencil MCP to inspect all user-provided artboards and handoff/spec nodes.
    • Read variables with get_variables.
    • Capture screenshots of each target artboard before coding.
    • If a handoff node exists, treat it as source-of-truth for responsive behavior.
  2. Extract implementation facts

    • Record artboard sizes, foreground stack width, stack x/y, section gaps, spacer heights, radii, stroke colors, blur radii, shadows, and image fill modes.
    • Read repeated components deeply enough to capture exact text, font family, font size, font weight, line height, letter spacing, icon size, and touch target dimensions.
    • Distinguish fixed foreground layout from decorative absolute layers.
  3. Map design to code deliberately

    • Use semantic, reusable components for repeated rows/cards/actions.
    • Keep foreground layout in flex/grid.
    • Keep background image, veil, mist, vignette, wires, particles, and similar decorative layers absolute/fixed and non-interactive.
    • Preserve design tokens as CSS variables or framework theme tokens.
    • Copy or reference real assets from the Pencil export rather than approximating logos/photos.
  4. Handle responsive artboards literally

    • Foreground dimensions must follow the handoff, not viewport convenience.
    • If the design says a column is fixed, do not stretch cards/buttons on tablet/desktop.
    • Only expand the outer scene when the handoff says so.
    • Re-check artboard node IDs after the user says the design changed.
  5. Verify visually and numerically

    • Run the project checks required by the repo.
    • Use browser screenshots at every artboard size.
    • Use browser getComputedStyle for text that looks wrong; verify actual font-family, font-size, font-weight, line-height, and letter-spacing.
    • Compare rendered screenshots against Pencil screenshots before finalizing.

Read the full file on GitHub · 55 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

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.

  1. 7d ago First seen · 55 lines · 73 tokens per session scan A 9a94188aac8b

Subscribe to this mod's changes

pencil-to-code is a skill published in the GitHub repository JohnWayneeee/ai-agent-skills (1 stars, last pushed 3mo ago), licensed MIT. It adds 73 tokens to every session and 726 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.

Related

Other skills, from other repositories

frontend-design

Design and build production-ready frontend interfaces with design systems, responsive layouts, accessible components, and dark mode support. Use when the user requests frontend design or provides relevant inputs for this workflow.

seb1n/awesome-ai-agent-skills · 40 tokens

3d-web-experience

Expert in building 3D experiences for the web - Three.js, React Three Fiber, Spline, WebGL, and interactive 3D scenes. Covers product configurators, 3D portfolios, immersive websites, and bringing depth to web experiences.

sickn33/agentic-awesome-skills · 57 tokens

anti-ui-slop

Stop coding agents from shipping generic UI. Extend the product's design system, use UIZZE evidence only when useful, cover required states, and inspect the rendered result.

sickn33/agentic-awesome-skills · 39 tokens

antigravity-design-expert

Core UI/UX engineering skill for building highly interactive, spatial, weightless, and glassmorphism-based web interfaces using GSAP and 3D CSS.

sickn33/agentic-awesome-skills · 39 tokens

canvas-app

Creates or edits a Power Apps Canvas App through the Canvas Authoring MCP coauthoring session. Handles new app generation, direct targeted edits, complex multi-screen changes, responsive layout, per-screen self-QA, and compile-error convergence. Trigger on requests to create, build, generate, modify, update, change…

microsoft/power-platform-skills · 79 tokens

shopify-theme-optimization

Theme speed and UX optimization — Core Web Vitals, Liquid code, image loading, mobile responsiveness.

nexscope-ai/eCommerce-Skills · 25 tokens