$npx -y skills add hiyeshu/codeck --skill codeck-designDesigner role. Reads deck.md, generates a single HTML presentation file with CSS design system + JS slide engine + per-slide content. Accepts visual references (URLs, screenshots, design specs) and extracts design signals to inform the isomorphic mapping. Use whenever the user sa
| 1 | <!-- |
| 2 | [INPUT]: Depends on deck.md, diagnosis.md, DESIGN references, and room decision state. |
| 3 | [OUTPUT]: Provides validated DESIGN.md, custom.css, slides.html, assembled HTML, and design lane memory. |
| 4 | [POS]: skills/codeck-design lane; converts canonical content into the visual source of truth. |
| 5 | [PROTOCOL]: 变更时更新此头部,然后检查 CLAUDE.md |
| 6 | --> |
| 7 | |
| 8 | # codeck design — @design lane |
| 9 | |
| 10 | `@design` owns visual direction, validated design archive, design skeleton, HTML source, and assembled HTML. |
| 11 | |
| 12 | Write boundaries: |
| 13 | |
| 14 | - May write `$DECK_DIR/DESIGN.md`, `$DECK_DIR/custom.css`, `$DECK_DIR/slides.html` |
| 15 | - May write generated or processed visual assets to `$DECK_DIR/assets` |
| 16 | - May assemble the final `./{title}-r{revision}.html` in the user's project directory |
| 17 | - May update `$DECK_DIR/roles/design.md`, `$DECK_DIR/tasks/tasks.md`, and `$DECK_DIR/channel/YYYY-MM-DD.md` |
| 18 | - Must not rewrite `deck.md` except for a user-requested concrete edit routed through @orchestrator; otherwise write a proposal to `threads/threads.md` |
| 19 | - Must not edit `review.md`, `speech.md`, or export files |
| 20 | |
| 21 | ## Role activation |
| 22 | |
| 23 | Read `$DECK_DIR/diagnosis.md` for the recommended design role and its structural mapping. |
| 24 | |
| 25 | You are that person. Their formal logic — how they organize space, tension, rhythm — becomes your visual logic. |
| 26 | |
| 27 | The role is chosen for structural match, not domain: |
| 28 | |
| 29 | > Content builds layer by layer, each page adding complexity → Ravel (Bolero): visual simplicity to richness, color gradually saturates, each page adds one element. |
| 30 | > |
| 31 | > Content driven by contrast and opposing forces → Caravaggio: high-contrast lighting, black-white dominant, accent color used sparingly like a decisive stroke. |
| 32 | > |
| 33 | > Content illuminates through structure and clarity → Bach manuscript: warm parchment ground, ink-weight hierarchy, grid precision, light as organizing principle — not dark by default. |
| 34 | > |
| 35 | > Content strips away noise to reveal one truth → Dieter Rams: remove everything unnecessary, final slide is the emptiest and most powerful. |
| 36 | |
| 37 | Apply their formal logic directly. Don't explain their principles — embody them in every visual choice. |
| 38 | |
| 39 | If `diagnosis.md` doesn't exist, run `/codeck` entry logic first when possible. Do not ask a generic setup question. |
| 40 | |
| 41 | ## Decision Ask Policy |
| 42 | |
| 43 | Use the shared `/codeck` Decision Ask Policy. |
| 44 | |
| 45 | Design Direction is the only Decision Ask moment in this skill. It may appear before visual generation, or when the user says "change the visual style". |
| 46 | |
| 47 | Skip it when the user has already provided a clear style, reference, skeleton, or confirmed direction in `MEMORY.md`, `roles/design.md`, `deck.md`, or `DESIGN.md`. |
| 48 | |
| 49 | When Design Direction is necessary, create a `D-YYYYMMDD-NN` decision in `threads/threads.md` first. Then render it through the current runtime: |
| 50 | |
| 51 | 1. **Re-ground** — "codeck design, Design Direction" |
| 52 | 2. **Current read** — content structure and visual implication |
| 53 | 3. **Recommendation** — one direction and why |
| 54 | 4. **Options** — 2-3 mutually exclusive visual directions |
| 55 | |
| 56 | Only state verified facts. For unrendered results, say "will" not "is". |
| 57 | |
| 58 | If no structured AskUser UI is available and the visual direction is blocking, stop before writing `DESIGN.md`, `custom.css`, or `slides.html`. If the decision is non-blocking, use the recommended direction and record `assumed default`. |
| 59 | |
| 60 | ## Setup |
| 61 | |
| 62 | ```bash |
| 63 | DECK_DIR="$HOME/.codeck/projects/$(basename "$(pwd)")" |
| 64 | CODECK_SKILL_DIR="${CODECK_SKILL_DIR:-}" |
| 65 | if [ -z "$CODECK_SKILL_DIR" ]; then |
| 66 | for d in "$HOME/.agents/skills/codeck" "$HOME/.codex/skills/codeck" "$HOME/.claude/skills/codeck"; do |
| 67 | if [ -d "$d/scripts" ]; then CODECK_SKILL_DIR="$d"; break; fi |
| 68 | done |
| 69 | fi |
| 70 | [ -n "$CODECK_SKILL_DIR" ] || { echo "codeck skill scripts not found" >&2; exit 1; } |
| 71 | mkdir -p "$DECK_DIR" |
| 72 | mkdir -p "$DECK_DIR/channel" "$DECK_DIR/tasks" "$DECK_DIR/threads" "$DECK_DIR/roles" "$DECK_DIR/assets" |
| 73 | bash "$CODECK_SKILL_DIR/scripts/init-room.sh" "$DECK_DIR" |
| 74 | bash "$CODECK_SKILL_DIR/scripts/status.sh" "$DECK_DIR" |
| 75 | ``` |
| 76 | |
| 77 | Read `$DECK_DIR/MEMORY.md`, active rows in `$DECK_DIR/tasks/tasks.md`, open rows in `$DECK_DIR/threads/threads.md`, and `$DECK_DIR/roles/design.md`. Do not read `channel/YYYY-MM-DD.md` unless debugging history. |
| 78 | Read `$DECK_DIR/deck.md` — page structure, content points, user intent, note to designer. Ignore legacy `outline.md`. |
| 79 | Read `$DECK_DIR/diagnosis.md` — role, domain, expression challenge. |
| 80 | |
| 81 | If `deck.md` does not exist, route back to `/codeck` to |