Files
hyperframes/packages/cli
ukimsanovandClaude Opus 4.7 86ac4e25f8 feat(capture): identify hashed fonts via OpenType name table
Modern frameworks (Next.js, Webpack) rename downloaded fonts with content
hashes for cache-busting. The captured filenames look like
'19cfc7226ec3afaa-s.woff2' and the CSS @font-face mapping that originally
tied each hash to a family name is lost during capture. The previous
DESIGN.md guidance — "hashed = Google Fonts subset, use Inter as substitute"
— was wrong half the time. The Raycast capture, for example, ships Inter,
JetBrains Mono, and Geist Mono all hashed identically.

Every OpenType / WOFF / WOFF2 file embeds a 'name' table (part of the spec
since 1996) with the family name, subfamily, weight class, and variation
axes. Subsetting and hashing don't strip it. This change uses fontkit to
read the name table from each downloaded font and writes a per-project
manifest the rest of the pipeline can consult instead of guessing.

Output: capture/extracted/fonts-manifest.json with per-file metadata and
per-family aggregation (weights captured, variable-font axes detected).
Cross-tested against 9 existing captures (Huly, Raycast, Framer, WorkOS,
Mercury, Loom, Arc, HeyGen, Railway): 132/132 files identified, 0 failures.
The 'ES Build Neutral' font in Huly captures — the one DESIGN.md was
calling '__esbuild_b38aaf' and substituting Inter for — now resolves to
its real family name with all 3 weights aggregated.

Includes canonicalization that collapses static-weight family-name
packaging ('Inter Medium' → family 'Inter' with weight 500) so the
families[] aggregate reads cleanly. Handles compound weight names
('Semi Bold' → 'SemiBold' before stripping). rawFamily preserved for
transparency.

- packages/cli/src/capture/fontMetadataExtractor.ts (new, ~210 lines)
- packages/cli/src/capture/index.ts (wired in after downloadAndRewriteFonts)
- packages/cli/package.json + bun.lock (added fontkit@2.0.4, @types/fontkit@2.0.9)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 10:53:36 -07:00
..

hyperframes

CLI for creating, previewing, and rendering HTML video compositions.

Install

npm install -g hyperframes

Or use directly with npx:

npx hyperframes <command>

Requirements: Node.js >= 22, FFmpeg

Commands

init

Scaffold a new Hyperframes project from a template:

npx hyperframes init my-video
cd my-video

preview

Start the live preview studio in your browser:

npx hyperframes preview
# Studio running at http://localhost:3002

npx hyperframes preview --port 4567

render

Render a composition to MP4:

npx hyperframes render ./my-composition.html -o output.mp4

lint

Validate your Hyperframes HTML:

npx hyperframes lint ./my-composition
npx hyperframes lint ./my-composition --json      # JSON output for CI/tooling
npx hyperframes lint ./my-composition --verbose   # Include info-level findings

By default only errors and warnings are shown. Use --verbose to also display informational findings (e.g., external script dependency notices). Use --json for machine-readable output with errorCount, warningCount, infoCount, and a findings array.

compositions

List compositions found in the current project:

npx hyperframes compositions

benchmark

Run rendering benchmarks:

npx hyperframes benchmark ./my-composition.html

doctor

Check your environment for required dependencies (Chrome, FFmpeg, Node.js):

npx hyperframes doctor

browser

Manage the bundled Chrome/Chromium installation:

npx hyperframes browser

info

Print version and environment info:

npx hyperframes info

docs

Open the documentation in your browser:

npx hyperframes docs

upgrade

Check for updates and show upgrade instructions:

npx hyperframes upgrade
npx hyperframes upgrade --check --json  # machine-readable for agents

Documentation

Full documentation: hyperframes.heygen.com/packages/cli