← ClaudeAtlas

encapsulated-mockup-builderlisted

Build front-end prototypes, mockups, landing pages, dashboards, component demos, and interactive UI concepts as ONE self-contained HTML file — a single <style> block in <head>, a single <script> block before </body>, tokens in :root, and every icon/graphic/image embedded inline (SVG or data URI) so the file opens and works with zero external dependencies, bundlers, or missing assets. Use this whenever the user asks for a prototype, mockup, demo, "quick page", "something I can open in the browser", "show me what it'd look like", an artifact/preview, a design handoff, or any front-end that isn't being wired into an existing build system — even if they don't say "single file". Also use when converting a React/Vue/Tailwind snippet into something runnable without npm.
fernandokylas/editorial-web-craft · ★ 2 · Web & Frontend · score 73
Install: claude install-skill fernandokylas/editorial-web-craft
# Encapsulated Mockup Builder A prototype earns its keep by being *looked at*. A folder of `index.html` + `styles.css` + `app.js` + an `images/hero.png` that needs a dev server, or a JSX snippet that needs a bundler, delays that moment and usually breaks on the way. One HTML file that opens from a double-click, works offline, and renders exactly the same on the reviewer's laptop as it did in yours is the most reliable way to get a design in front of someone — and it's trivially shareable, diffable, and versionable. So: everything in one file. Not as a constraint to work around, but as the unit of delivery. ## The structure Start every artifact from `assets/boilerplate.html` and keep its four zones in order: ``` <head> <meta charset> <meta viewport> <title> <style> 1. :root tokens — colours, type scale, spacing, radius, motion. The only place raw values live. (+ .theme-inverted or [data-theme] blocks that re-map the same tokens) 2. Reset, base, layout, components — everything references var(--token) </style> </head> <body> (inline SVG sprite, if icons repeat) 3. Semantic markup — <main>, <section>, <nav>, <button>, real headings; #app-root if JS renders <script> 4. One IIFE: state object, event delegation on the root, init on DOMContentLoaded </script> </body> ``` Why tokens first: a reviewer's most common request is "can we see it in the brand green / with more breathing room". If every colour and spacing value is a `:root` variable, th