Communitygithub.com

Biznomad/claude-skills

使用 HyperFrames HTML 建立影片作品、動畫、標題卡、疊加層、字幕、旁白、音訊反應式視覺效果與場景轉場。

claude-skills 是什麼?

此技能提供給開發者或 AI 代理一個全面的影片製作工作流程,完全以 HTML 為核心。它將影片作品定義為帶有 `data-*` 屬性控制時序、GSAP 時間軸驅動動畫,以及 CSS 定義外觀的 HTML 檔案。技能引導使用者遵循嚴格的逐步流程:首先從設計檔案(design.md)建立視覺識別或從內建風格庫中選擇;接著執行提示擴展以完善意圖;然後規劃場景節奏與佈局;最後才撰寫 HTML 與動畫。它強調「先佈局再動畫」的方法:先將每個元素定位在最終靜止狀態,再用 GSAP 的 `from()` 與 `to()` 加入進場和退場動畫,以避免內容意外重疊。技能支援子作品(透過 `data-composition-src` 載入外部 HTML)、參數化變數(`data-composition-variables` 與 `getVariables()`),並提供詳細的資料屬性參考,用於控制剪輯時序、軌道索引與媒體修剪。此技能特別適合 Cursor、Claude Code 等平台,可處理從簡單標題卡到多場景影片的所有工作,並可與 `hyperframes-cli`(開發指令)與 `hyperframes-media`(素材預處理)等配套技能協作。

相容平台✓Claude Code✓Codex CLI~Cursor
npx skills add https://github.com/Biznomad/claude-skills/tree/HEAD/hyperframes

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

HyperFrames

HTML 是影片的真實來源。一個作品是一個帶有 data-* 屬性控制時序、GSAP 時間軸驅動動畫,以及 CSS 定義外觀的 HTML 檔案。框架處理剪輯的可見性、媒體播放和時間軸同步。

方法

探索階段(僅限探索性請求)

對於開放式請求(「製作一個產品發布影片」、「為我們的品牌創作一些東西」),在使用者尚未確定方向時,先了解意圖再做顏色選擇:

  • 觀眾 — 誰觀看這部影片?開發者?高階主管?一般消費者?
  • 平台 — 影片在哪裡播放?社群媒體(15 秒)、網站主視覺、產品示範、內部使用?
  • 優先級 — 什麼最重要?動畫品質?內容準確度?品牌忠實度?速度?
  • 變化方案 — 使用者想要多個選項,還是單一最佳方案?

對於具體請求(「加上一個標題卡」、「修正場景 3 的時間」),請跳過探索階段。

對於探索性請求,可考慮提供 2-3 個有意義的變化方案——不只是顏色交換,而是不同的節奏、能量層級或結構方法。一個安全/預期,一個有野心。這不是強制性的——這是在適當情況下可用的工具。

步驟 1:設計系統

如果專案中存在 design.md 或 DESIGN.md,請先閱讀(檢查兩種大小寫——它們在 Linux 上是不同的檔案)。這是品牌顏色、字體和限制的真實來源。使用其確切的值——不要發明顏色或替換字體。任何格式皆可(YAML 前置資料、散文、表格——只需提取值)。

如果它指定了本地找不到的字體(沒有 fonts/ 目錄包含 .woff2 檔案,也不是內建字體),請在撰寫 HTML 之前警告使用者:「design.md 指定了 [字體名稱] 但未找到字體檔案。請將 .woff2 檔案加入 fonts/,否則我將回退到 [最接近的內建替代字體]。」

如果沒有 design.md,提供使用者一個選擇:

  1. 使用者指定了風格或氛圍? → 閱讀 visual-styles.md 以了解 8 個命名預設。選擇最接近的。
  2. 想要視覺化瀏覽選項? → 執行設計選擇器:閱讀 references/design-picker.md 了解完整工作流程。這會提供一個視覺選擇器頁面。使用者在瀏覽器中配置氛圍、調色盤、排版和動畫,然後複製產生的 design.md 並貼回對話。
  3. 想要跳過並快速進行? → 詢問:氛圍、淺色或深色、任何品牌顏色/字體?然後從 house-style.md 中選擇一個調色盤。

design.md 定義品牌。它不定義影片作品規則。 那些來自 references/video-composition.md 和 house-style.md。以適合影片的規模使用品牌顏色——而不是以 Web UI 的不透明度。

步驟 2:提示擴展

每個作品都必須執行此步驟(單一場景片段和瑣碎編輯除外)。此步驟將使用者的意圖針對 design.md 和 house-style.md 進行錨定,並產生一個所有下游代理都能以相同方式讀取的一致中間產物。

閱讀 references/prompt-expansion.md 了解完整流程和輸出格式。

步驟 3:規劃

在撰寫 HTML 之前,從高層次思考:

  1. 什麼 — 觀看者應該體驗什麼?識別敘事弧線、關鍵時刻和情感節拍。
  2. 結構 — 有多少個作品,哪些是子作品 vs 內聯,哪些軌道承載什麼(影片、音訊、疊加層、字幕)。
  3. 節奏 — 在實作之前宣告你的場景節奏。哪些場景是快速擊打,哪些是停留,著色器落在哪裡,能量峰值在哪裡。命名模式:快速-快速-慢-快速-著色器-停留。閱讀 references/beat-direction.md 了解節奏模板。
  4. 時間 — 哪些剪輯驅動持續時間,轉場落在哪裡,節奏如何。
  5. 佈局 — 先建立結束狀態。請見下方的「先佈局再動畫」。
  6. 動畫 — 然後使用下列規則加入動作。

只建立被要求的內容。 「一個標題卡」的請求不是「一個標題卡 + 3 個支援場景 + 背景音樂 + 字幕」的請求。每個場景、每個元素、每個補間動畫都應該有其存在的理由。如果額外的場景或元素能真正提升作品,請提出建議——不要直接加入。

對於小編輯(修正顏色、調整時間、加入一個元素),直接跳到規則。

先佈局再動畫

將每個元素定位在其最顯眼的時刻——即它完全進入、正確定位、且尚未退出的影格。首先將其寫為靜態 HTML+CSS。先不要加入 GSAP。

為什麼這很重要: 如果你將元素定位在其動畫起始狀態(畫面外、縮放到 0、不透明度 0)並補間到你認為它們應該到達的位置,你是在猜測最終佈局。重疊在影片渲染之前是不可見的。透過先建立結束狀態,你可以在加入任何動畫之前看見並修正佈局問題。

流程

  1. 為每個場景識別主影格 — 最多元素同時可見的時刻。這就是你要建立的佈局。
  2. 為該影格撰寫靜態 CSS。.scene-content 容器必須使用 width: 100%; height: 100%; padding: Npx; 搭配 display: flex; flex-direction: column; gap: Npx; box-sizing: border-box 來填滿整個場景。使用內邊距將內容向內推——絕對不要在內容容器上使用 position: absolute; top: Npx。當內容高於剩餘空間時,絕對定位的內容容器會溢出。保留 position: absolute 僅供裝飾性元素使用。
  3. 使用 gsap.from() 加入進場動畫 — 從畫面外/不可見動畫到 CSS 位置。CSS 位置是真實來源;補間描述了到達那裡的旅程。(在透過 data-composition-src 載入的子作品中,偏好使用 gsap.fromTo()——請參閱 references/motion-principles.md 中的承載 GSAP 規則。)
  4. 使用 gsap.to() 加入退場動畫 — 從 CSS 位置動畫到畫面外/不可見。

範例

/* scene-content 填滿場景,內邊距定位內容 */
.scene-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 120px 160px;
  gap: 24px;
  box-sizing: border-box;
}
.title {
  font-size: 120px;
}
.subtitle {
  font-size: 42px;
}
/* 容器填滿任何場景尺寸 (1920x1080, 1080x1920 等)。
   內邊距定位內容。Flex + gap 處理間距。*/

錯誤——硬編碼尺寸和絕對定位:

.scene-content {
  position: absolute;
  top: 200px;
  left: 160px;
  width: 1920px;
  height: 1080px;
  display: flex; /* ... */
}
// 步驟 3:動畫進入這些位置
tl.from(".title", { y: 60, opacity: 0, duration: 0.6, ease: "power3.out" }, 0);
tl.from(".subtitle", { y: 40, opacity: 0, duration: 0.5, ease: "power3.out" }, 0.2);
tl.from(".logo", { scale: 0.8, opacity: 0, duration: 0.4, ease: "power2.out" }, 0.3);

// 步驟 4:從這些位置動畫退出
tl.to(".title", { y: -40, opacity: 0, duration: 0.4, ease: "power2.in" }, 3);
tl.to(".subtitle", { y: -30, opacity: 0, duration: 0.3, ease: "power2.in" }, 3.1);
tl.to(".logo", { scale: 0.9, opacity: 0, duration: 0.3, ease: "power2.in" }, 3.2);

當元素在不同時間共享空間時

如果元素 A 在元素 B 進入同一區域之前退出,兩者都應該有其各自主影格的正確 CSS 位置。時間軸順序保證它們永遠不會視覺上共存——但如果你跳過佈局步驟,你將不會捕捉到它們因時間錯誤而意外重疊的情況。

什麼算作有意重疊

分層效果(文字後的發光、陰影元素、背景圖案)和 z 軸堆疊設計(卡片堆疊、深度層)是故意的。佈局步驟的目的是捕捉無意重疊——兩個標題落在彼此上方、統計數字覆蓋標籤、內容溢出畫面。

資料屬性

所有剪輯

屬性必要值
id是唯一識別碼
data-start是秒數或剪輯 ID 參考 ("el-1", "intro + 2")
data-durationimg/div/作品需要秒數。影片/音訊預設為媒體長度。
data-track-index是整數。同一軌道的剪輯不能重疊。
data-media-start否來源的修剪偏移(秒)
data-volume否0-1(預設 1)

data-track-index 不影響視覺層級——請使用 CSS z-index。

作品剪輯

屬性必要值
data-composition-id是唯一作品 ID
data-start是開始時間(根作品:使用 "0")
data-duration是優先於 GSAP 時間軸持續時間
data-width / data-height是像素尺寸(1920x1080 或 1080x1920)
data-composition-src否外部 HTML 檔案路徑
data-variable-values否子作品主機上每個實例變數覆蓋的 JSON 物件

在根 <html> 元素上:

屬性必要值
data-composition-variables否宣告變數的 JSON 陣列 (id/type/label/default)——驅動 Studio 編輯 UI 並為 getVariables() 提供預設值

作品結構

透過 data-composition-src 載入的子作品使用 <template> 包裝。獨立作品(主要的 index.html)不使用 <template>——它們將 data-composition-id div 直接放在 <body> 中。在獨立檔案上使用 <template> 會對瀏覽器隱藏所有內容並破壞渲染。

子作品結構:

<template id="my-comp-template">
  <div data-composition-id="my-comp" data-width="1920" data-height="1080">
    <!-- 內容 -->
    <style>
      [data-composition-id="my-comp"] {
        /* 範圍樣式 */
      }
    </style>
    <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/gsap.min.js"></script>
    <script>
      window.__timelines = window.__timelines || {};
      const tl = gsap.timeline({ paused: true });
      // 補間...
      window.__timelines["my-comp"] = tl;
    </script>
  </div>
</template>

在根中載入:<div id="el-1" data-composition-id="my-comp" data-composition-src="compositions/my-comp.html" data-start="0" data-duration="10" data-track-index="1"></div>

變數(參數化作品)

使用不同的內容渲染同一個作品——標題、主題顏色、價格、字幕——而無需編輯原始 HTML。

三步驟模式:

  1. 宣告作品 <html> 根上的變數,使用 data-composition-variables。每個條目需要 id、type(其中之一為 string、number、color、boolean、enum)、label 和 default。列舉條目還需要 options: [{value, label}, ...]。
  2. 讀取作品內部腳本中解析後的值,使用 window.__hyperframes.getVariables()。返回宣告的預設值 + 每個實例覆蓋 + CLI 覆蓋的合併結果。
  3. 覆蓋在渲染時使用 npx hyperframes render --variables '{...}'(頂層)或使用主機元素上的 data-variable-values='{...}'(子作品的每個實例)。
<!doctype html>
<html
  data-composition-variables='[
  {"id":"title","type":"string","label":"Title","default":"Hello"},
  {"id":"theme","type":"enum","label":"Theme","default":"light","options":[
    {"value":"light","label":"Light"},
    {"value":"dark","label":"Dark"}
  ]}
]'
>
  <body>
    <div data-composition-id="root" data-width="1920" data-height="1080">
      <h1 id="hero" class="clip" data-start="0" data-duration="3"></h1>
      <script>
        const { title, theme } = window.__hyperframes.getVariables();
        document.getElementById("hero").textContent = title;
        document.body.dataset.theme = theme;
      </script>
    </div>
  </body>
</html>
# 開發預覽使用宣告的預設值
npx hyperframes preview

# 使用覆蓋值渲染
npx hyperframes render --variables '{"title":"Q4 Report","theme":"dark"}' --output q4.mp4

# 或從 JSON 檔案
npx hyperframes render --variables-file ./vars.json

子作品每個實例的值: 相同的 getVariables() 在透過 data-composition-src 載入的子作品中運作。每個主機元素傳遞自己的值:

<div
  data-composition-id="card-pro"
  data-composition-src="compositions/card.html"
  data-variable-values='{"title":"Pro","price":"$29"}'
></div>
<div
  data-composition-id="card-enterprise"
  data-composition-src="compositions/card.html"

…

[因翻譯而截斷]

Individual skills in this repo

This repo contains 17 individual skills — each has its own dedicated page.

Biznomad/claude-skills

TikTok Ads deep analysis covering creative quality, tracking, bidding, campaign structure, and TikTok Shop. Evaluates 25 checks with emphasis on creative-first strategy, safe zone compliance, and Smart+ campaigns. Use when user says "TikTok Ads", "TikTok marketing", "TikTok Shop", "Spark Ads", "Smart+", or "TikTok campaign".

Biznomad/claude-skills

YouTube Ads specific analysis covering campaign types, creative quality, audience targeting, and measurement. Evaluates video ad performance across skippable, non-skippable, bumper, Shorts, and Demand Gen formats. Use when user says "YouTube Ads", "video ads", "pre-roll", "bumper ads", "YouTube campaign", or "Shorts ads".

Biznomad/claude-skills

Help users get promoted at work. Use when someone is preparing for a promotion conversation, building their case for advancement, trying to understand what's blocking their promotion, or figuring out how to get to the next level in their career.

Biznomad/claude-skills

CSS animation adapter patterns for HyperFrames. Use when authoring CSS keyframes, animation-delay based timing, animation-fill-mode, animation-play-state, or CSS-only motion that HyperFrames must seek deterministically during preview and rendering.

Biznomad/claude-skills

HyperFrames CLI dev loop — `npx hyperframes` for scaffolding (init), validation (lint, inspect), preview, render, and environment troubleshooting (doctor, browser, info, upgrade). Use when running any of these commands or troubleshooting the HyperFrames build/render environment. For asset preprocessing commands (`tts`, `transcribe`, `remove-background`), invoke the `hyperframes-media` skill instead.

Biznomad/claude-skills

Asset preprocessing for HyperFrames compositions — text-to-speech narration (Kokoro), audio/video transcription (Whisper), and background removal for transparent overlays (u2net). Use when generating voiceover from text, transcribing speech for captions, removing the background from a video or image to use as a transparent overlay, choosing a TTS voice or whisper model, or chaining these (TTS → transcribe → captions). Each command downloads its own model on first run.

Biznomad/claude-skills

Install and wire registry blocks and components into HyperFrames compositions. Use when running hyperframes add, installing a block or component, wiring an installed item into index.html, or working with hyperframes.json. Covers the add command, install locations, block sub-composition wiring, component snippet merging, and registry discovery.

Biznomad/claude-skills

Optimize landing pages for higher conversion rates using proven frameworks and design patterns. Use when designing, reviewing, or improving landing pages, hero sections, pricing pages, CTAs, or when the user asks about conversion optimization.

Biznomad/claude-skills

Building promotion cases, brag documents, tracking wins, and self-advocacy for career advancement. Use when preparing for promotions, documenting accomplishments, or building your case for advancement.

Biznomad/claude-skills

Translate an existing Remotion (React-based) video composition into a HyperFrames HTML composition. Use ONLY when the user explicitly asks to port, convert, migrate, translate, or rewrite a Remotion composition as HyperFrames (e.g. "port my Remotion project to HyperFrames"). Do NOT use when (a) authoring a NEW HyperFrames composition (even if A/B-testing a Remotion video); (b) Remotion is mentioned in passing; (c) Remotion code is shared as reference, not for translation; (d) the user wants "the same video as my Remotion one" without explicitly asking to migrate the source — treat as a fresh HyperFrames build. When in doubt, default to the `hyperframes` skill. Detects unsupported patterns (useState, useEffect side effects, async calculateMetadata, third-party React component libraries, `@remotion/lambda`) and recommends the runtime interop escape hatch instead of a lossy translation.

Biznomad/claude-skills

Produce programmable videos with Remotion using scene planning, asset orchestration, and validation gates for automated, brand-consistent video content.

Biznomad/claude-skills

Generate cinematic film-style video prompts for Seedance 2.0 on Higgsfield. Use whenever the user wants cinematic, film-like, movie-quality, Hollywood-style, dramatic, or professional film-quality AI video. Triggers on: cinematic, film look, movie scene, dramatic lighting, depth of field, lens flare, anamorphic, letterbox, noir, epic, Steadicam, dolly, crane shot, or any cinematic video generation request. Always use this skill even if the user doesn't explicitly say "cinematic" but describes a film-like aesthetic.

Biznomad/claude-skills

为 Seedance 2.0(Higgsfield)生成电影级胶片风格视频提示词。在用户想要电影级、胶片感、电影质量、好莱坞风格、戏剧性或专业胶片质量的AI视频时使用。触发词:电影级、胶片感、电影场景、戏剧性打光、景深、镜头光晕、变形、信箱式、黑色电影、史诗、稳定摄像机、推车镜头、吊臂镜头或任何电影级视频生成请求。即使用户没有明确说"电影级"但描述了胶片美学,也要使用此技能。

Biznomad/claude-skills

Convert comic book panels, manga pages, webtoons, and illustrated storyboards into animated video using Seedance 2.0 on Higgsfield. Use whenever the user wants to animate comics, bring illustrations to life, convert manga to video, animate storyboards, or create motion from static sequential art. Triggers on: comic to video, manga animation, panel animation, storyboard to video, webtoon animation, comic book motion, sequential art, graphic novel animation, or any illustrate-to-animate request. Use even when user says "make this drawing move" or "animate this page.

Biznomad/claude-skills

Generate music video and beat-synced visual content prompts for Seedance 2.0 on Higgsfield. Use whenever the user wants to create a music video, lyric video, beat-synced visuals, performance video, concert visual, album art animation, or music-driven visual content. Triggers on: music video, lyric video, beat sync, music visualization, performance video, concert visual, album visual, song video, music clip, beat drop visual, rhythm sync, or any music-driven video request. Use even for "make visuals for my song" or "video for this track.

Biznomad/claude-skills

Build, redesign, and deploy websites across any stack — static HTML, Next.js, Astro, or Shopify Liquid themes. Handles design systems, brand-aware layouts, component architecture, and deployment pipelines (Netlify, Vercel, Shopify API). Use when asked to build a website, redesign a site, create a landing page, build a web app, create Shopify sections/templates, or deploy web projects. Triggers on requests like "build me a website", "redesign this page", "create a landing page", "build a Shopify theme", "deploy to Netlify".

Biznomad/claude-skills

Capture a website and create a HyperFrames video from it. Use when: (1) a user provides a URL and wants a video, (2) someone says "capture this site", "turn this into a video", "make a promo from my site", (3) the user wants a social ad, product tour, or any video based on an existing website, (4) the user shares a link and asks for any kind of video content. Even if the user just pastes a URL — this is the skill to use.

相關技能