portfolio-detail — Chinese Atelier / Lishu Portfolio (with Detail Pages)
One-Line Description
Horizontal text rows + hover-reveal large image on the right + Alimama DaoLiTi artistic Lishu large characters + black/white pure color + light/dark + hash-routed detail pages + list/gallery dual views.
Differences from Other Portfolio Skills
| skill | core pattern | best for |
|---|---|---|
portfolio-gen | infinite drag canvas + tile tiling | Photographers / graphic designers showcasing samples |
portfolio-museum-gen | hero carousel + large cards + waterfall + detail pages (curatorial vibe) | Video/film/installation artists |
industrial-archive-gen | black-frame flip cover + sidebar archive + Nordic industrial | Physical products / artifacts / hardware |
lishu-portfolio-gen | horizontal text rows + hover-reveal right thumbnail + Lishu large characters + Chinese restraint | Bookbinding / typography / craft / Chinese atelier |
If the user's project is about "books / fonts / exhibitions / still life / Chinese herbs / tea / pottery / wood / paper / incense" — projects needing restrained, elegant aesthetics — use this one.
When to Trigger
The user says:
- "Create a Chinese / Eastern / classical style portfolio"
- "Create a Lishu-style website / studio homepage"
- "Create a White House style portfolio" / "Create a horizontal list website like Gurgel D'Alfonso"
- "lishu-portfolio-gen ..."
And provides:
- Studio Description (required): Name, director, city, discipline, titles and stories of a few works
- Work Images (optional): URL / upload / path. Works without them (uses picsum placeholders)
If the user did not give any work titles at all → Must ask once at least which works to display. If the user only gave titles but no details → Write them: generate 1 lead sentence + 3 prose paragraphs + 6-8 spec rows + 3-6 picsum images per work + a few credits. The tone should match the work type (book → binding / font → typeface / object → still life / exhibition → exhibition visuals).
Two Modes
Mode A · Claude Code / Local (with file system)
- Use
Bashto list folders,sipsto probe each image's width/height - Output location:
~/Desktop/{slug}-portfolio.html(single file, all images via URL) - If user gave local images: copy to
~/Desktop/{slug}-portfolio-images/and change src to relative paths
Mode B · GLM / Online Chat (no file system)
- User will see 4 files after unzipping
- Only output one complete HTML string, wrapped in a
```htmlcode block - User uploaded images but no URL → use
https://picsum.photos/id/{id}/{w}/{h}placeholders (use known existing IDs) - Do not attempt to access local files, do not suggest command-line operations
Judgment: If you cannot Read to see local images → Default to Mode B.
File Division
| File | Role | How to Use |
|---|---|---|
reference.html | Complete finished reference — BAIWU 6 works | Look at: list item wording, prose tone, spec vocabulary, JSON field density |
template.html | Empty skeleton — Same CSS/JS/routing system, 2 samples + 20 SWAP markers | Modify its base, output final HTML |
README.md | User-facing instructions | Model does not need to read |
SKILL.md | Workflow for the model (this file) | Required reading |
Core rule: All changes based on template.html; learn how to write (tone, word count, tag usage) from reference.html, but do not copy specific content.
Work Steps
1. Read Two HTML Files
- First read
reference.htmlto understand "what it looks like when complete" (especiallyworks-dataJSON field density and prose tone) - Then read
template.htmlto find the 20 SWAP locations
Do not change JS / do not change CSS / do not change detail page routing system / do not change font import. SWAPs are all in HTML text and JSON data.
2. Parse User Input to Extract Information
Extract:
- ATELIER_NAME_ZH — Chinese studio name (2-4 characters best, e.g., 「白屋」「素园」「墨记」「青庐」「拙轩」)
- PINYIN — Pinyin (5-6 English letters, all caps: BAIWU / SUYUAN / MOJI)
- CHAR — Single character for logo (usually the first character of the studio name: 白 / 素 / 墨 / 青 / 拙)
- CITY — City
- DIRECTOR_ZH / DIRECTOR_EN — Director's name + pinyin
- DISCIPLINE — 3 disciplinary words ("装帧 · 字体 · 静物")
- TAGLINE — One-line positioning (20—40 characters, cursive style)
- YEAR_FOUNDED — Founding year (can use stem-branch: 乙未冬 / 甲辰春)
For each work extract:
- slug — URL ID, lowercase English hyphenated (
kong-shan-ji/wu-ming-shu) - title_zh — Chinese title (2-5 characters best, the more concise the more refined)
- title_en — English subtitle (book-title style:
An Anthology of Empty Mountains) - year — Year or stem-branch year (
甲辰 / 2024/2025/乙巳 / 2025) - tag — Top category, wrapped in square brackets, e.g.,
[ 诗集 · 装帧设计 ]/[ 字体设计 · 中草药图谱 ] - cover — Detail page large image URL
- list row location —
City, Year · Craft/Spec(appears on hover) - meta — 4 key-value pairs (detail page 4-column summary)
- lead — 30-70 character opening large text, can use
<em>keyword` to emphasize one point - prose — 3-4 prose paragraphs, each 80-150 characters
- specs — 6-10 row spec table (format/paper/binding/font/print run/printing/craft/price, etc.)
- gallery — 3-6 images, choose layout from three:
g-wide/g-half/g-third - credits — 4-7 role/name pairs
If the user gives only one sentence / no story → Write it yourself: based on the work's title and type, write lead and prose that match the work's character. Reference tone from reference.html — no marketing language, have a "museum wall-text + studio notebook" feel (restrained, specific, slow, with handmade traces).
3. List Works + Probe Dimensions (Mode A Only)
ls -la "{works_path}"
sips -g pixelWidth -g pixelHeight "{works_path}/{file}" 2>/dev/null
Get (filename, w, h, aspect) for each image. Prefer portrait images for list thumbnails (4:3 container, portrait works better).
4. Replace 20 SWAPs
| SWAP | Location | Content |
|---|---|---|
| 1 | <title> | {ATELIER_NAME} {PINYIN} — {DIRECTOR} Portfolio / Studio |
| 2 | meta description | One-line site description |
| 3 | curtain single character | Studio name's first character (e.g., 「白」) |
| 4 | logo SVG inner single character | Same as SWAP-3 |
| 5 | logo SVG inner pinyin | {PINYIN} uppercase |
| 6 | main navigation li | Usually 3 items: Works / About / Contact |
| 7 | brand-block Chinese name | {ATELIER_NAME} split with spaces (e.g., 白 屋) |
| 8 | brand-block English | {PINYIN} Studio · {CITY} |
| 9 | tagline | One-line cursive positioning, 20—40 characters, can use <br> for line break |
| 10 | list items N works | Each <a class="item" href="#work/{slug}"> containing num/project-name/en-name/location/photo-thumb |
| 11 | gallery items N works | Same N works, more compact grid — slug must match list |
| 12 | About title | 关 于 {name}<span class="en">About</span> |
| 13 | About paragraphs | 1-3 cursive paragraphs (founding background / director / design philosophy), each 60-120 characters |
| 14 | About facts table | 4-6 li (Founded/Location/Discipline/Director/Hours) |
| 15 | Contact title | 来 信<span class="en">Get in Touch</span> |
| 16 | Contact paragraph | 1-2 paragraphs inviting correspondence + response time promise |
| 17 | Contact facts table | 4-6 items (E-mail/Phone/Address/Instagram/WeChat Official Account) |
| 18 | rotating credit | Site by {WHO} (usually the studio name) |
| 19 | footer three blocks | © / ICP / social links |
| 20 | works-data JSON | Complete detail data for N works (critical!) |
5. Write works-data JSON (Most Critical Step)
Each work must have one entry in the JSON array, slug must match the #work/SLUG href in list/gallery cards exactly.
JSON fields:
{
"slug": "kong-shan-ji",
"title_zh": "空山集",
"title_en": "An Anthology of Empty Mountains",
"year": "甲辰 / 2024",
"tag": "[ 诗集 · 装帧设计 ]",
"cover": "https://picsum.photos/id/143/1800/1100",
"meta": [
{"label": "Type / 类型", "value": "诗集装帧"},
{"label": "Year / 年份", "value": "2024"},
{"label": "Edition / 印量", "value": "首印 320 本"},
{"label": "Format / 开本", "value": "130 × 195 毫米"}
],
"lead": "三十六首关于山的诗。我们想做一本——读者翻开后,先听见<em>风声</em>,再读见字的书。",
"prose": [
"段落一:诗稿来源 / 设计语境。80—150 字。",
"段落二:制作中的关键决定 — 字体、纸张、装订选择。",
"段落三:最后呈现 / 留给读者的感受。"
],
"specs": [
["开本 / Format", "130 × 195 毫米"],
["页数 / Pages", "144 页"],
["纸张 / Paper", "本色棉纸 90gsm"],
["装订 / Binding", "线装四目"],
["字体 / Typeface", "老宋(标题)· 楷体(正文)"],
["印刷 / Printing", "单色凸印"],
["印量 / Edition", "首印 320 本"],
["定价 / Price", "¥ 388"]
],
"gallery": [
{"src": "...", "layout": "g-wide", "caption": "封面"},
{"src": "...", "layout": "g-half"},
{"src": "...", "layout": "g-half"},
{"src": "...", "layout": "g-third"},
{"src": "...", "layout": "g-third"},
{"src": "...", "layout": "g-third"}
],
"credits": [
["设计 / Design", "周墨白"],
["手工装订 / Binding", "陈漱石(杭州·订书坊)"]
]
}
JSON Common Mistakes ⚠️:
- Use quotation marks within Chinese prose → must use full-width
「...」or"..."(U+201C / U+201D), not ASCII"(will break JSON) - Do not use actual newlines inside JSON strings; for paragraph breaks, add another item in the prose array
<em>word</em>in lead write the HTML tag directly — it is rendered as innerHTML- gallery
layoutmust be one of three:g-wide(full width) /g-half(half width) /g-third(one-third width)
6. Image Source Selection
- picsum placeholders: Use
id/Xform instead ofseed/X(more stable). Known good IDs: 0, 20, 40, 51, 64, 76, 88, 91, 96, 119, 121, 130, 143, 145, 158, 164, 165, 175, 177, 180, 187, 195, 200 - For the same work's cover / gallery, use adjacent IDs to create a consistent color tone
- Do not use
?grayscaleparameter (user wants images in color)
7. Chinese Studio Name Inspiration (If User Didn't Provide)
If the user says "come up with one for me" → Choose 2 characters + ancient feel:
- Object-type: 白屋 / 素园 / 墨记 / 青庐 / 拙轩 / 听雨 / 一勺 / 半亩
- Calligraphy-type: 素白 / 子衿 / 砚池 / 半山 / 寻常 / 浮云
- Avoid functional words like "工作室 / Design / Studio"; let the name itself be poetry
8. Video Support
If a work's cover is .mp4 / .webm / .mov, the detail page automatically uses <video autoplay muted loop> instead of <img>. The model just needs to provide the video path in the cover URL.
9. Reporting
Mode A: One-line report.
Generated ~/Desktop/baiwu-portfolio.html — 6 works, hover rows to view thumbnails, click to enter detail pages. Light/Dark toggle at bottom-left, list/gallery switch at center-top.
Mode B: Directly provide the complete HTML code block + a one-line instruction.
Save the above as
index.htmland double-click to open. Move the mouse over any work name to see the appearing thumbnail on the right; click to jump to the detail page. To change images, replace the picsum URLs with your image addresses.
Forced to Preserve (Cannot Change)
- Font import:
@font-faceloading the Alimama DaoLiTi woff2 URL (do not change the font source) - CSS variable system: light/dark dual themes
- All JS: theme toggle, view mode toggle, hover-row interaction, rotating credit, detail page hash routing
applyRoute(),renderDetail() <script id="works-data">node must be kept<main id="detail-root">must be kept (detail page mount point)body[data-view="home/detail"]andbody[data-mode="list/gallery"]state system- #logo / #main-menu / .theme-toggle / #project-view / #svp-credit five fixed-position elements
Common Mistake Quick Check
- Slug mismatch: list item
#work/kong-shan-ji↔ gallery item#work/kong-shan-ji↔ JSON"slug": "kong-shan-ji"— must be identical across all three - JSON quotation marks: quotes within Chinese content must use full-width 「」 or
"...", not ASCII" - Too many gallery images: maximum 6 images per work, more breaks layout
- Prose too long: each paragraph 80-150 characters, over 200 characters reading experience degrades
- List / gallery out of sync: must contain the same set of works (one-to-one mapping)
- picsum seed: use
id/Xnotseed/X, avoid random IDs hitting deleted images - Works < 3: ok, minimum 2 works works
- Works > 8: suggest splitting into two batches, too many list rows makes the page long
- First character drop cap: detail page's
.detail__prose p:first-of-type::first-letteruses DaoLiTi — first paragraph must start with a Chinese character (do not start with<em>or an English character) - Removed picsum color: images should remain color, do not add
filter: grayscale()in CSS