frame-flowchart-sticky
SVG curve connections + sticky note nodes + cursor interactions, reminiscent of a whiteboard brainstorming session.
1How It Works & Mechanism
This skill is not an executable program, but a prompt injected into the local coding-agent CLI: the host takes the body of SKILL.md, prepends site-wide shared design instructions, appends the user content, assembles it into a prompt sent to the authenticated agent, and captures the agent's stdout as HTML.
【输入格式】: ${opts.format} 【用户内容】: ${opts.content}
The shared instruction layer (which belongs to no single skill, but governs every template) mandates the output as a 'self-contained single-file HTML', explicitly forbidding the agent from using filesystem tools like Write/Edit/Bash, streaming HTML directly via conversational message content.
- **禁止使用 Write / Edit / MultiEdit / Bash / Create / 任何文件系统工具**。不要把 HTML 写到任何 \`.html\` 文件里。前端直接捕获你的 stdout 文本, 文件落盘由前端负责。
Beyond SKILL.md, a 'content-driven count' override rule applies: any page, frame, or card counts specified in the template are treated strictly as reference lower bounds; actual volume is dictated by user content to prevent the agent from condensing user information.
- 模板只定义"可用版面 / 风格 / 配色 / 字体 / 组件库", **不定义** slide / 帧 / 卡片 / section 的数量。
The loading convention adheres to 'one skill = one directory': SKILL.md (YAML frontmatter for the selector + prompt template in the body), optional example.md (sample input), and example.html (directly viewable preview sample); adding templates requires only a directory without modifying TS code.
* SKILL.md — frontmatter (id, scenario, tags, …) + prompt body * example.md — (optional) sample input content * example.html — (optional) pre-rendered preview, shown inline in the picker
The selection pipeline (CLI side) operates as a three-tier funnel: high-signal keywords (2 points per hit, threshold of 3) → fallback to tags/scenario scoring → if still uncertain, the first 800 characters of user content are passed to the local agent for single-sentence classification.
const CONFIDENCE_THRESHOLD = 3;
The preview pipeline is decoupled from generation: /api/templates/<id>/preview serves example.html verbatim as text/html to an iframe; the frontend iframe uses sandbox="allow-scripts allow-same-origin".
sandbox="allow-scripts allow-same-origin"
The template renders processes as a 'whiteboard + sticky notes': a 1920×1080 canvas with a beige whiteboard paper #f4ede1 or cool gray whiteboard #f0f2f4 background, layered with an ultra-subtle hex grid (rgba(0,0,0,0.04)) to create a whiteboard texture.
【画布】1920×1080。背景: 米黄白板纸 `#f4ede1` 或冷灰白板 `#f0f2f4`; 加非常浅的 hex grid `rgba(0,0,0,0.04)` 让它有白板感。
Node specifications are explicitly locked: 240×180px sticky notes, randomized across four colors (yellow #fcd34d / peach #fca5a5 / mint #a7f3d0 / sky #a5b4fc), slight rotation of ±2deg, drop-shadow, top tape linear-gradient decoration, and handwritten typography (Kalam/Caveat/Patrick Hand, Chinese LXGW WenKai).
- 每节点 = 一张 240×180px 便利贴, 4 套颜色随机分配: 黄 `#fcd34d` / 桃 `#fca5a5` / 薄荷 `#a7f3d0` / 天 `#a5b4fc`。
Connecting lines utilize SVG Bezier paths: stroke #2a2a2a, width 2.5, round caps; solid lines denote sequence, stroke-dasharray 8 6 denotes conditional branches; arrows use marker-end black triangles; explicit rendering rules are set for branching (one node splitting into two) and merging (two converging into one).
- 用 `<path>` Bezier 曲线连接节点, stroke `#2a2a2a`, width 2.5, `stroke-linecap: round`, `stroke-dasharray: 0` (实线) 或 `8 6` (虚线 = 条件分支)。 - 箭头终端用 `marker-end`, 黑色三角小箭头。
The whiteboard aesthetic relies on intentional 'imperfection': nodes do not require center alignment, though connectors must stay clear without crossing; an optional Figma-style collaboration cursor (SVG arrow + name tag) can hover beside nodes.
- 一个"光标"装饰 (`<svg>` arrow + name tag), 浮在某节点旁, 模拟 figma 协作光标。
Node counts are bounded within a range (minimum 5, maximum 12), and the content must originate from the user's authentic workflow—node text is taken directly from user input.
- 至少 5 个节点, 最多 12 个。
2Core Capabilities
3External Dependencies
| Kind | Dependency / Endpoint |
|---|---|
| network | Google Fonts(Caveat / Patrick Hand / Inter / IBM Plex Mono,示例页实际引用) |
| network | Tailwind Play CDN(共享指令强制;示例页亦引用) |
| network | hyperframes 目录页(frontmatter 出处标注,非运行时请求) |
4Recommended Governance & Evidence
- SKILL.md: Pure prompt instructions and rule text, without script execution or external side effects.
5Second-Pass Verification
- [ok] 节点/连线/交互规格 — 重读 SKILL.md【节点】【连接线】【可选交互】三段,引用逐字一致(含 240×180px、±2deg、stroke-dasharray 8 6)。
- [ok] 『不要外部图标库』结论 — SKILL.md 明写『单文件 HTML, 不要外部图标库 (用 inline SVG)』;示例页除 Tailwind/字体外无第三方资源引用。
- [ok] 节点数区间与共享指令是否冲突 — 共享指令规定模板数字是参考下限、数量由内容决定;本模板的 5-12 是可读性范围,二者不冲突(已在 traits 说明)。
- [ok] 外部端点存在性 — example.html 实测命中 fonts.googleapis.com 与 cdn.tailwindcss.com;hyperframes 链接仅在 frontmatter。
- [ok] 安全面 — 目录内 3 个文件无自写脚本、无 fetch/表单外发、无凭证读取、无写盘。
- [ok] meta 元数据 — GitHub API 实查 stars=8827、pushed_at=2026-09-15T03:36:24Z、license Apache-2.0。
- [unlocatable] 安装量 — 无公开安装量数据源,installs=null。
6Verdict & Scenarios
7a10e7dfc2816a51…