
layout-library-importer
Add a supplied layout image and bilingual layout prompt to the local handdraw-style layout library and gallery. Use for new SC- social-card or IG- infographic layouts; do not use for style-number imports.
- Installs
- 0
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/yang0/handraw-style --skill layout-library-importer- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads layout-library-importer automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Layout Library Importer
Use this Skill when the user wants to add a new visual layout/type to the local hand-drawn layout gallery. This is a repository-local workflow: do not commit, push, publish, or install anything externally unless the user separately asks.
Source of truth
Work from the repository root and read the live implementation before editing:
skills/handdraw-style-prompter/references/layouts.jsonis the layout index.skills/handdraw-style-prompter/references/layouts/*.mdis the authoritative bilingual prompt content.images/layouts/social-cards/,images/layouts/infographics/,images/layouts/comic-storyboards/, andimages/layouts/ip-characters/hold the layout images; canonical assets use WebP.skills/handdraw-style-prompter/scripts/build_layout_gallery.pyrebuilds the derived gallery.skills/handdraw-style-prompter/scripts/validate_library.pyis the full validation command.
Preserve unrelated dirty work. Inspect git status --short before editing and do not reset, clean, or overwrite files outside the requested layout import.
Import workflow
Batch input mode
Unless the user explicitly asks to rebuild, treat consecutive layout imports as batch input. For each supplied image, convert it to WebP when needed, add its index entry, and create its bilingual prompt file, but do not rebuild gallery/layouts.html or run the full validator after each item.
When the user says 重建索引, rebuild the layout gallery once from the accumulated canonical index and run the full validation and whitespace check. The canonical index is references/layouts.json; this request means regenerate and validate its derived gallery, not recreate the index entries already recorded.
-
Determine the next ID from the live index. Use the next number within the requested category:
SC-###forsocial-card,IG-###forinfographic,SB-###forcomic-storyboard,IP-###forip-character. Never reuse an existing ID or infer a number from a filename alone. -
Treat the user-supplied image as the canonical visual source. The repository asset must always use the
.webpextension. If the supplied image is already WebP, copy it to the category directory with the new ID. If it is another format, convert it to WebP losslessly using Python:python -c "from PIL import Image; img = Image.open(r'<input>'); img.save(r'<target>.webp', format='WEBP', lossless=True)"Do not delete the source attachment. Do not generate, crop, recolor, or otherwise alter the image content. If the attachment is unavailable as a readable local file, stop before changing the index and ask the user to reattach it.
-
Add one index object to
references/layouts.jsonwith the ID, exact category, concise Chinese display name, repository-relative WebP image path (../../../images/layouts/...webp), prompt path (layouts/{ID}.md), and concrete internal keywords. Keep the JSON array ordered by category and numeric ID. -
Create
references/layouts/{ID}.mdwith exactly two non-empty marker blocks:<!-- zh --> Chinese layout prompt <!-- en --> English layout promptThe prompt must describe composition, text hierarchy, placement, whitespace, and other layout constraints supplied by the user. Do not invent subject matter or illustration style. The Chinese and English blocks must express the same constraints. The layout prompt is the single source of truth used by prompt combination.
-
When the user requests a rebuild, rebuild the derived gallery and sync documentation counts:
python skills/handdraw-style-prompter/scripts/build_layout_gallery.pyThe build script automatically regenerates
gallery/layouts.html, updatesLAYOUTS.md/LAYOUTS_en.md, and synchronizes layout totals and category counts acrossREADME.md,README_en.md, and allSKILL.mdfiles. Do not manually edit the generatedgallery/layouts.html. The gallery must remain browse-only: thumbnail, ID/name information, enlarged preview, and copy-prompt behavior; no input form. -
Synchronize client caches & mirrors: Always ensure local desktop caches and mirror environments reflect the new layout entry:
- Copy
references/layouts.jsontoclient/cache/layouts.json. - If
.agents/mirror exists, ensure itsreferences/andgallery/layouts.htmlare synchronized. - When deploying to static site, verify that
https://handraw-style.com/gallery/layouts.htmlreturns HTTP 200 and includes the newly added layout ID.
- Copy
Validation
Run this section after an explicit rebuild request. During batch input mode, only confirm that the current image, index entry, and prompt file exist and agree. For every newly added layout, also confirm that the indexed image path ends in .webp and that the WebP file exists. Existing legacy PNG assets are outside this migration step.
Run the full validator and whitespace check:
python skills/handdraw-style-prompter/scripts/validate_library.py
git diff --check
Also verify directly that the new image, index entry, prompt file, generated card, and category count agree. For a social-card import with no infographic entries, the generated page must not show an infographic filter. When an IG-* entry is added later, the existing generator should expose that category automatically.
If browser automation is available, reload the existing local layouts.html preview and check the new card, full-image display, category filter, enlarged preview, and copy action. If the local file:// page is blocked by browser policy, report that visual QA was not completed; do not present string or file checks as a substitute for visual confirmation.
Response contract
Report the assigned ID, display name, canonical image path, prompt path, validation result, and whether visual browser QA completed. Mention any browser restriction explicitly. Do not claim that a layout was generated when the user supplied the image.
FAQ
What does the layout-library-importer skill do?
Add a supplied layout image and bilingual layout prompt to the local handdraw-style layout library and gallery. Use for new SC- social-card or IG- infographic layouts; do not use for style-number imports.
How do I install layout-library-importer?
Run npx skills add https://github.com/yang0/handraw-style --skill layout-library-importer in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/layout-library-importer/ (personal) or .claude/skills/layout-library-importer/ (project).
Which AI agents can use layout-library-importer?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is layout-library-importer safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains layout-library-importer?
It is published by yang0 in yang0/handraw-style. It has 0 recorded installs.
More from yang0/handraw-style
handdraw-style-prompter
yang0/handraw-style
Turn a 001–312 hand-drawn style number and image theme into bilingual prompts, using model capability data to decide when core traits and a numbered reference image are required.
editorial-hairstylist
yang0/handraw-style
Early professional hairstylist node that designs and locks formal shoot hair for each candidate direction before downstream Look expansion.
couple-photo-wardrobe-board
yang0/handraw-style
Design numbered six-look wardrobe boards for one or any number of participants inside a confirmed portrait theme, preserving full per-person outfit detail.
editorial-makeup-artist
yang0/handraw-style
Mandatory formal-shoot makeup and skin optimization node for portrait photography.
reference-beauty-prep
yang0/handraw-style
Turns a real-person reference into a reusable polished identity reference through a visual three-panel beauty exploration.
couple-photo-orchestrator
yang0/handraw-style
Orchestrates professional portrait, couple, wedding, family, cosplay, and themed photography planning from direction selection through Look, scene micro-zones, Shot List, and on-demand image generation.
Popular frontend & design skills
setup-matt-pocock-skills
mattpocock/skills
Configure this repo for the engineering skills: set up its issue tracker, triage label vocabulary, and domain doc layout. Run once before first use of the other engineering skills.
frontend-design
anthropics/skills
Guidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults.
prototype
mattpocock/skills
Build a throwaway prototype to answer a design question. Use when the user wants to sanity-check whether a state model or logic feels right, or explore what a UI should look like.
ui-taste
uizze.sh
Give your coding agent better UI taste. Build and polish web and iOS interfaces with Uizze's anti-ui-slop playbooks and optional real-product references. Use for UI design, implementation, redesign, critique, or a final visual review in Claude Code, Codex, Cursor, or Copilot.
hyperframes-animation
heygen-com/hyperframes
All animation knowledge for HyperFrames — atomic motion rules, multi-phase scene blueprints, scene transitions, broader motion-design techniques, AND the seven runtime adapters (GSAP default, plus Lottie, Three.js, Anime.js, CSS keyframes, Web Animations API, TypeGPU). Use for any motion or animation task: pick 2-4 rules and compose, or load a blueprint, or look up runtime-specific API (e.g. GSAP eases / Lottie player / Three.js mixer). Also covers auditing an existing composition's choreography (animation map) and 24 named text-animation effects. HyperFrames-native: single paused timeline, seek-safe, deterministic.
hyperframes-core
heygen-com/hyperframes
The HyperFrames composition contract — build one renderable project. Use for composition structure, the data- timing attributes, class="clip", tracks, sub-compositions, variables, framework-owned media playback, deterministic-render rules, and validation. Read before writing composition HTML.