Home / All Skills / Design & Motion / vfx-text-cursor
Design & Motion · nexu-io/html-anything

vfx-text-cursor

Cursor light trail + chromatic aberration rays + directional light flares, ideal for word-by-word quote reveals in video title sequences.

L1 Basic · Source registration onlyV1 Commit-PinnedDual-pass Audit
Author nexu-ioGitHub nexu-io/html-anything ↗Stars 8827License Apache-2.0(仓库根 LICENSE 文件;GitHub API license.spdx_id = Apache-2.0)Commit 553ed98c28
Control levels describe skill capabilities and suggested control measures; they do not represent quality or safety certifications, nor do they dictate usability. Usage decisions rest entirely with users and administrators. Different agent hosts apply varying constraints; do not assume hosts provide automatic protection. Third-party skill copyrights belong to their original authors. Use at your own risk.

1How It Works & Mechanism

This skill is not an executable program, but rather an html-anything "template": a directory (SKILL.md + example.html[/example.md]) scanned and read from disk at runtime by loader.ts—adding a new template simply means adding a new directory without modifying TypeScript.

next/src/lib/templates/loader.ts
Adding a template = adding a folder. No TS code change required; the API
SKILLS_DIR is fixed at src/lib/templates/skills relative to the app cwd; listSkills() traverses top-level subdirectories and filters them using isValidBundledId, reading SKILL.md and parsing frontmatter per directory, so "picker metadata" and "generation prompt body" originate from the same file.

The frontmatter contains metadata for the picker/API (zh_name/en_name/emoji/description/category/scenario/aspect_hint/featured/recommended/tags) mapped to SkillMeta via fmToMeta(); only the body text following the frontmatter serves as specifications for the model.

next/src/lib/templates/loader.ts
zhName: fm.zh_name ?? fm.name ?? id,
id is derived from the directory name; example metadata (example_id/name/format/tagline/desc/source_url) is produced as SkillExampleMeta only when the directory contains example.md/html, and body is deliberately excluded from the list API (comment: "Body is excluded so we can return the entire registry in one cheap fetch").

During generation, this template body is treated as the prompt body: /api/convert uses assemblePrompt() to concatenate "global design directives + this template's body + user content" into a single prompt, passed to the host's local agent CLI, with HTML captured via stdout streaming.

next/src/app/api/convert/route.ts
prompt = assemblePrompt({ body: skill.body, content, format });
The same route also contains editFromHtml/editFromContent "minimal diff editing" branches; the template body acts purely as a string along this pipeline, without evaluation or execution.

A block of global shared directives (SHARED_DESIGN_DIRECTIVES) precedes the template body, enforcing unified technical and content discipline across every template—external CDN/font links commonly found in example HTML originate here (injected by the host shell, not requested by the template itself).

next/src/lib/templates/shared.ts
通过 CDN 引入 Tailwind v3 Play (https://cdn.tailwindcss.com) 与所需的 Google Fonts。
The template body only dictates style, layout, and components without repeating these hard constraints; the classification evaluation considers only the template's own directory, and this endpoint is host shell behavior documented in security.reason for self-attestation.

Artifacts are returned as stdout text: global directives explicitly forbid the agent from touching the file system, leaving persistence to the front end—thus the template directory has neither scripts nor disk-writing capabilities.

next/src/lib/templates/shared.ts
**禁止使用 Write / Edit / MultiEdit / Bash / Create / 任何文件系统工具**。
The source text continues: "Do not write HTML to any .html files... the front end directly captures your stdout text, and the front end is responsible for saving files to disk"; artifacts are ultimately written to task records and exported by the front end.

example.html is a pre-rendered example shipped with the bundle: /api/templates/<id>/preview returns it verbatim as text/html to an iframe (for inline preview in the picker), while /api/templates/<id>/example returns both example.md and example.html together.

next/src/app/api/templates/[id]/preview/route.ts
return new Response(skill.exampleHtml, {
Examples serve solely for preview and documentation and do not participate in prompt generation (generation uses only the SKILL.md body), so their external links do not affect the skill's capability boundaries.

The body details motion effects as verifiable timing specifications: word-by-word reveal at 80ms/word, cursor block following the active character, and chromatic ghost appearing at the moment of reveal and converging within 200ms.

next/src/lib/templates/skills/vfx-text-cursor/SKILL.md
- 逐字揭示, 每个字符 80ms 间隔; 当前字符后面跟着一个 cursor `▍` (或细 vertical bar)。
This is the core mechanism of "video title sequence" templates: using character-level timing to transform a quote into an editable opening frame; the same section provides concrete chromatic aberration values: text-shadow: 2px 0 #ff3b6f, -2px 0 #00d4ff.

Flares and rays are synthesized using CSS rather than bitmaps: elongated rectangles with linear-gradient + mix-blend-mode: screen, 3–5 randomized rays at irregular angles.

next/src/lib/templates/skills/vfx-text-cursor/SKILL.md
- 在打字位置附近随机生成 3-5 道**定向光斑** (light leak)
The body elaborates: "using elongated rectangles of `linear-gradient(45deg, transparent, accent20, transparent)` + `mix-blend-mode: screen`"; the example implementation uses three static approximate .ray elements (.ray-1/2/3).

Explicit negative constraints specify "what not to do": use only a single binary aberration of hot pink + cyan, prohibit full-color R/G/B rainbows, and strictly forbid serif fonts.

next/src/lib/templates/skills/vfx-text-cursor/SKILL.md
- **绝不**: 多色彩虹 chromatic (只用 1 个 hot pink + cyan 这种二元像散, 不要 R/G/B 全色)。
This constraint limits chromatic aberration to two distinct, recognizable colors to prevent cheap-looking rainbow outlines—representing template quality discipline rather than mere aesthetic description.

Accessibility and content authenticity are baked into the body: animations must be toggleable via prefers-reduced-motion (displaying all text immediately), and user-provided quotes must be used without fabrication.

next/src/lib/templates/skills/vfx-text-cursor/SKILL.md
- 必须用用户提供的金句; 不要捏造。
The preceding clause in the same section requires: "animations use `@keyframes` + JS timers (`setTimeout` word-by-word), and must be suppressible by `prefers-reduced-motion`".

The example HTML delivers only a "single static frame": the cursor block blinks via CSS blink animation, chromatic aberration is a static text-shadow across the full text, and the three .ray elements have fixed angles—there is no word-by-word JS timer, no shimmer, and no prefers-reduced-motion fallback.

next/src/lib/templates/skills/vfx-text-cursor/example.html
animation: blink 1s steps(1) infinite;
Grep across the example reveals no setTimeout, no prefers-reduced-motion, and no shimmer; thus, the "word-by-word reveal / 0.5s shimmer sweep" declared in the body is not implemented in the bundled example (the example is positioned as a static freeze-frame preview of the opening frame).

The CLI side features a direct keyword matching channel: skills-matcher.ts directly maps keywords in user content to this template id; a hit assigns confidence = hit count * 2 + 3, and reaching the threshold of 3 triggers local rules without asking the model to select a template.

cli/src/skills-matcher.ts
[["VFX", "特效", "光标", "cursor", "chromatic", "reveal"], "vfx-text-cursor"],
Terms such as VFX, cursor, and chromatic directly match vfx-text-cursor; video scenario signals maintain a separate keyword table (video, frame, hyperframes, remotion, VFX, title sequence).

Threshold constants used in CLI fallback matching: content length must exceed 60 characters to enable AI summary matching; the strong signal threshold is 3.

cli/src/skills-matcher.ts
const MIN_CONTENT_LENGTH_FOR_AI = 60;
Additionally, SCENARIO_SIGNALS weights keywords according to template scenario, and fallbackMatch scores using tags/zhName/description; only when both layers fail is the agent called for summary matching.

The host shell renders examples/artifacts using an iframe with sandbox="allow-scripts allow-same-origin" (allowing scripts and same-origin access)—this is a host product trade-off, noted as a risk, and does not affect this skill's grading.

next/src/components/template-picker.tsx
sandbox="allow-scripts allow-same-origin"
preview-pane.tsx / deck-viewer.tsx follow the same pattern; inline JS in the example HTML executes only during browser preview, and the skill itself executes no scripts.

2Core Capabilities

011920×1080 video opening frame (dark background #06070a + vignette + noise)
02Word-by-word reveal timing (80ms/word + cursor tracking)
03Chromatic aberration ghosting (reveal moment → converges within 200ms)
04Directional light leaks/flares (screen blending, 3–5 rays)
05Completion shimmer sweep (0.5s sweeping light band)
06Metadata overlay: top caption + source sub-caption + bottom-right timecode
07reduced-motion fallback (immediately displays full text)

3External Dependencies

KindDependency / Endpoint
networkTailwind CDN(示例 HTML 引用)
networkGoogle Fonts(Inter Tight / Noto Sans SC / JetBrains Mono)
network示例来源标注(frontmatter 元数据,非运行依赖)

4Recommended Governance & Evidence

Suggested Controls for Safe Operation
For Agent Runtime
Can be auto-loaded
For Administrators
Register source and version
Evidence & Triggers (File Paths & Excerpts)
  • SKILL.md: Pure prompt directives and rule text, without script execution or external side effects
Audit Notes: Evaluation target: this skill directory (next/src/lib/templates/skills/vfx-text-cursor/). Verified file-by-file: zero scripts, zero credential access, zero disk writes; endpoints appearing in the directory are limited to Tailwind CDN (referenced in example HTML), Google Fonts (Inter Tight / Noto Sans SC / JetBrains Mono), and example source attribution (frontmatter metadata, not runtime dependencies)—all located within the example.html artifact sample. The SKILL.md body specifies only layout, style, and font families, mentioning no runtime external APIs, qualifying it as a pure directive template = green. Host-side note (not factored into grading): the html-anything product shell concatenates the body into the prompt via assemblePrompt(), spawns the local agent CLI, and injects cdn.tailwindcss.com + Google Fonts requirements (next/src/lib/templates/shared.ts); the preview iframe uses sandbox="allow-scripts allow-same-origin" (next/src/components/template-picker.tsx).

5Second-Pass Verification

  • [ok] skill 目录文件清单 — find 得 SKILL.md + example.html + example.md,无 scripts/references。
  • [ok] 外部端点只出现在示例/元数据 — SKILL.md 正文无 URL;两个 URL 分别位于 frontmatter example_source_url(元数据)与 example.html 的 Tailwind CDN / Google Fonts link。
  • [discrepancy] 逐字揭示/计时器是否在示例中实现 — SKILL.md 写明「@keyframes + JS 计时器 (setTimeout 逐字)」与 0.5s shimmer、reduced-motion 降级;example.html 只有 CSS blink 光标 + 静态 text-shadow,grep 无 setTimeout / prefers-reduced-motion / shimmer,属示例未实现正文声明的动效(示例是静帧预览)。
  • [discrepancy] 「不要外链字体以外的资源」是否被示例遵守 — 正文禁非字体外链,但 example.html 引入 https://cdn.tailwindcss.com 脚本;该 Tailwind 要求实为宿主全局指令(shared.ts)强制,说明模板正文与宿主壳在此点冲突。
  • [discrepancy] chromatic 只在 reveal 瞬间 vs 示例静态 — 正文要求像散在 reveal 瞬间出现并 200ms 内收敛;示例 .chroma 是整段 h1 的静态 text-shadow。
  • [ok] CLI 匹配器路由 — cli/src/skills-matcher.ts 存在 [["VFX", "特效", "光标", "cursor", "chromatic", "reveal"], "vfx-text-cursor"] 行。
  • [ok] 判级 green 自证 — 目录零脚本文件、零凭证、零写盘;正文未点名运行时接口,端点仅见示例与 frontmatter 元数据 → green。
  • [ok] official_desc 逐字 — meta.official_desc 取自 frontmatter description 原文。

6Verdict & Scenarios

  • Turns chromatic aberration into an actionable formula: provides 80ms character intervals, 200ms convergence, and explicit text-shadow color values so the model does not have to guess
  • Negative constraints prevent degradation: single accent binary aberration + serif font ban, directly eliminating common failures like cheap rainbow strokes
  • Built-in accessibility: reduced-motion gracefully degrades to displaying all text immediately, and requires using verbatim user text without fabrication
  • Traceable origins: frontmatter attributes inspired-by links and labels, with color palette strategies explicitly documented in the example footer
  • Best for: Ideal for video title sequences, chapter title frames, keynote opening quotes, and hero frames requiring a punchy, impactful single line; also suitable as visual drafts prior to Remotion/hyperframes composition.
    Not for: Not suitable for pages carrying heavy informational density or structured data; not suitable for long-form editorial layouts (a single sentence + metadata overlay already constitutes a complete layout); not suitable for pipelines expecting directly renderable MP4 outputs—it only produces HTML frames.
    Install Agent-Ready
    ① Verified Mirror 2026-09-15
    Option A · Direct DownloadDownload vfx-text-cursor.tar.gz
    sha256: 315c18b1b92b614f…
    Option B · Copy Guide for Agent
    install.json
    Agents automatically download and verify mirrors from this JSON guide.
    ② Upstream GitHub
    GitHub Repo ↗
    Pinned to commit 553ed98c28.