AGENT SKILL

hand-drawn-diagrams

Hand-drawn / sketchy-style diagrams — Excalidraw/rough.js-style wobble, cross-hatch fills, and marker-stroke text — built as self-contained SVG with filter-based roughening, no CDN dependency required. Covers when the hand-drawn aesthetic actually fits a brief and when it undermines one, plus a small library of flowchart/whiteboard/annotation techniques.

License 许可
Apache-2.0
最近更新
2026-07-09
Stars
★ 0
Forks
0

01 前言 Front Matter

od
{ "mode": "design-system", "craft": { "requires": [ "color", "anti-ai-slop", "accessibility-baseline" ] }, "preview": { "type": "html" }, "category": "diagrams", "upstream": "https://github.com/muthuishere/hand-drawn-diagrams", "design_system": { "requires": false }, "example_prompt": "Use hand-drawn-diagrams to sketch a 4-step onboarding flowchart in a\nhand-drawn whiteboard style, with wobbly boxes, arrows, and a marker-style\nlabel font." }
name
hand-drawn-diagrams
triggers
[ "excalidraw", "hand drawn diagram", "sketch diagram", "whiteboard diagram", "rough.js", "sketchy style", "hand-drawn style" ]
description
Hand-drawn / sketchy-style diagrams — Excalidraw/rough.js-style wobble, cross-hatch fills, and marker-stroke text — built as self-contained SVG with filter-based roughening, no CDN dependency required. Covers when the hand-drawn aesthetic actually fits a brief and when it undermines one, plus a small library of flowchart/whiteboard/annotation techniques.

02 资源文件 3

03 SKILL.md 正文

Hand-Drawn Diagrams

A hand-drawn/sketchy aesthetic — wobbly strokes, cross-hatch fills, a marker-style label font — reads as informal, human, and in-progress. That's a real, distinct visual register from Open Design's usual clean-vector default, and it fits some briefs precisely because it looks unfinished. It also actively works against briefs that need to look authoritative, production-grade, or brand-precise. This skill covers both the technique and the judgment call on when to reach for it.

Resource map

hand-drawn-diagrams/
├── SKILL.md                 ← you're reading this
├── references/
│   ├── technique.md          ← SVG filter roughening + stroke/fill recipes
│   └── checklist.md          ← P0/P1/P2 self-review
└── example.html              ← 4-node hand-drawn flowchart

Step 0 — Decide if the style fits

Reach for hand-drawn when:

  • The brief is explicitly a whiteboard session, brainstorm, sketch, or early-stage concept — the point is to look like a first pass, not a finished spec.
  • The diagram is explanatory/pedagogical (a flow explainer, a system sketch in a blog post or talk) where informality reads as approachable.
  • The design system's mood is playful, editorial, or explicitly hand-crafted (check DESIGN.md's Visual Theme section before assuming).

Avoid it when:

  • The output represents a finished product surface (a real UI mockup, a pricing table, an actual dashboard) — sketchy strokes on a "real" artifact reads as unfinished or unserious, undermining exactly the credibility a polished prototype needs.
  • The active design system is precision-driven (fintech, technical/dev tools, enterprise B2B) where hand-drawn would clash with the brand's actual visual language rather than complement it.
  • The user asked for a diagram "that looks professional" without qualifying it as a sketch — default to clean vector shapes instead and only introduce the hand-drawn register if asked.

Step 1 — Build as SVG with filter-based roughening

Read references/technique.md for the core recipe: plain SVG shapes (<path>, <rect>, <line>) run through an SVG <filter> combining feTurbulence + feDisplacementMap to add organic wobble to otherwise straight lines, plus a hatch-fill pattern for "shaded" regions. This needs no external library and works inside Open Design's sandboxed preview iframe with zero network dependency — the filter is pure SVG/CSS.

For diagrams that need the fuller rough.js multi-pass-stroke look (each edge drawn 2-3 times with slight offset, closer to actual Excalidraw output), references/technique.md also covers a pinned-CDN rough.js setup as the heavier alternative — reach for the native filter approach first and only add the library when the brief specifically needs that exact multi-stroke texture.

Step 2 — Marker-style text

Pair the wobbly shapes with a rounded, slightly irregular label typeface — a handwriting-adjacent web font (e.g. a bundled/system equivalent to Excalidraw's "Virgil") rather than the design system's normal body font. Keep this substitution scoped to the diagram itself; don't let a sketchy label font leak into surrounding UI chrome that isn't part of the sketch.

Step 3 — Color restraint still applies

Hand-drawn doesn't mean colorful-marker chaos. Apply the same palette-layer discipline as any other artifact (craft/color.md): a neutral "paper" or canvas background, one or two accent colors for emphasis (a highlighted box, a "you are here" marker), not a full rainbow of marker colors per node. Cross-hatch/fill patterns should read in one or two tones, not a swatch per shape.

Step 4 — Accessibility even in a sketch

A hand-drawn diagram is still a diagram conveying information — give the <svg> a <title>/<desc> describing the flow in plain text, and make sure text labels stay legible (marker fonts can get illegible below ~14px; don't shrink labels to fit if it costs readability — resize the diagram instead), per craft/accessibility-baseline.md.

Step 5 — Self-check

Run references/checklist.md before shipping.

Source

Curated from muthuishere/hand-drawn-diagrams — this skill is an original synthesis of the native-SVG-filter roughening technique and the style-fit judgment call, not a vendor of that repo's Excalidraw-export pipeline.

04 同仓库更多 Skills