hyperframes 0.6.97 → 0.6.98

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/dist/beat-analyzer.global.js +326 -0
  2. package/dist/cli.js +2479 -1961
  3. package/dist/commands/layout-audit.browser.js +86 -0
  4. package/dist/hyperframe-runtime.js +22 -22
  5. package/dist/hyperframe.manifest.json +1 -1
  6. package/dist/hyperframe.runtime.iife.js +22 -22
  7. package/dist/skills/hyperframes-cli/SKILL.md +67 -103
  8. package/dist/skills/hyperframes-cli/references/doctor-browser.md +45 -0
  9. package/dist/skills/hyperframes-cli/references/init-and-scaffold.md +51 -0
  10. package/dist/skills/hyperframes-cli/references/lambda.md +132 -0
  11. package/dist/skills/hyperframes-cli/references/lint-validate-inspect.md +93 -0
  12. package/dist/skills/hyperframes-cli/references/preview-render.md +107 -0
  13. package/dist/skills/hyperframes-cli/references/upgrade-info-misc.md +75 -0
  14. package/dist/studio/assets/hyperframes-player-DgsMQSvV.js +418 -0
  15. package/dist/studio/assets/index-B62bDCQv.css +1 -0
  16. package/dist/studio/assets/index-Ce3pBm_I.js +252 -0
  17. package/dist/studio/assets/{index-HveJ0MuV.js → index-D-ET9M0b.js} +1 -1
  18. package/dist/studio/assets/index-D-bS9Dxx.js +1 -0
  19. package/dist/studio/index.html +2 -2
  20. package/dist/templates/_shared/AGENTS.md +46 -21
  21. package/dist/templates/_shared/CLAUDE.md +16 -14
  22. package/package.json +3 -2
  23. package/dist/pngDecodeBlitWorker.js +0 -239
  24. package/dist/skills/gsap/SKILL.md +0 -240
  25. package/dist/skills/gsap/references/effects.md +0 -297
  26. package/dist/skills/gsap/scripts/extract-audio-data.py +0 -188
  27. package/dist/skills/hyperframes/SKILL.md +0 -491
  28. package/dist/skills/hyperframes/data-in-motion.md +0 -19
  29. package/dist/skills/hyperframes/house-style.md +0 -73
  30. package/dist/skills/hyperframes/palettes/bold-energetic.md +0 -14
  31. package/dist/skills/hyperframes/palettes/clean-corporate.md +0 -14
  32. package/dist/skills/hyperframes/palettes/dark-premium.md +0 -14
  33. package/dist/skills/hyperframes/palettes/jewel-rich.md +0 -14
  34. package/dist/skills/hyperframes/palettes/monochrome.md +0 -14
  35. package/dist/skills/hyperframes/palettes/nature-earth.md +0 -14
  36. package/dist/skills/hyperframes/palettes/neon-electric.md +0 -14
  37. package/dist/skills/hyperframes/palettes/pastel-soft.md +0 -14
  38. package/dist/skills/hyperframes/palettes/warm-editorial.md +0 -14
  39. package/dist/skills/hyperframes/patterns.md +0 -191
  40. package/dist/skills/hyperframes/references/audio-reactive.md +0 -76
  41. package/dist/skills/hyperframes/references/beat-direction.md +0 -171
  42. package/dist/skills/hyperframes/references/captions.md +0 -163
  43. package/dist/skills/hyperframes/references/css-patterns.md +0 -373
  44. package/dist/skills/hyperframes/references/design-picker.md +0 -117
  45. package/dist/skills/hyperframes/references/dynamic-techniques.md +0 -102
  46. package/dist/skills/hyperframes/references/html-in-canvas-patterns.md +0 -507
  47. package/dist/skills/hyperframes/references/motion-principles.md +0 -150
  48. package/dist/skills/hyperframes/references/narration.md +0 -92
  49. package/dist/skills/hyperframes/references/prompt-expansion.md +0 -68
  50. package/dist/skills/hyperframes/references/techniques.md +0 -525
  51. package/dist/skills/hyperframes/references/text-effects.md +0 -64
  52. package/dist/skills/hyperframes/references/transcript-guide.md +0 -107
  53. package/dist/skills/hyperframes/references/transitions/catalog.md +0 -117
  54. package/dist/skills/hyperframes/references/transitions/css-3d.md +0 -12
  55. package/dist/skills/hyperframes/references/transitions/css-blur.md +0 -51
  56. package/dist/skills/hyperframes/references/transitions/css-cover.md +0 -43
  57. package/dist/skills/hyperframes/references/transitions/css-destruction.md +0 -95
  58. package/dist/skills/hyperframes/references/transitions/css-dissolve.md +0 -66
  59. package/dist/skills/hyperframes/references/transitions/css-distortion.md +0 -45
  60. package/dist/skills/hyperframes/references/transitions/css-grid.md +0 -10
  61. package/dist/skills/hyperframes/references/transitions/css-light.md +0 -49
  62. package/dist/skills/hyperframes/references/transitions/css-mechanical.md +0 -30
  63. package/dist/skills/hyperframes/references/transitions/css-other.md +0 -25
  64. package/dist/skills/hyperframes/references/transitions/css-push.md +0 -41
  65. package/dist/skills/hyperframes/references/transitions/css-radial.md +0 -37
  66. package/dist/skills/hyperframes/references/transitions/css-scale.md +0 -24
  67. package/dist/skills/hyperframes/references/transitions.md +0 -138
  68. package/dist/skills/hyperframes/references/typography.md +0 -175
  69. package/dist/skills/hyperframes/references/video-composition.md +0 -62
  70. package/dist/skills/hyperframes/scripts/animation-map.mjs +0 -601
  71. package/dist/skills/hyperframes/scripts/contrast-report.mjs +0 -348
  72. package/dist/skills/hyperframes/scripts/package-loader.mjs +0 -269
  73. package/dist/skills/hyperframes/templates/design-picker.html +0 -1432
  74. package/dist/skills/hyperframes/visual-styles.md +0 -443
  75. package/dist/studio/assets/hyperframes-player-Daj5djxa.js +0 -418
  76. package/dist/studio/assets/index-B0twsRu0.css +0 -1
  77. package/dist/studio/assets/index-Cfye9xzo.js +0 -251
@@ -0,0 +1,107 @@
1
+ # preview, play, render, publish
2
+
3
+ Serve, render, and share commands.
4
+
5
+ ## preview
6
+
7
+ ```bash
8
+ npx hyperframes preview # serve current directory
9
+ npx hyperframes preview --port 4567 # custom port (default 3002)
10
+ ```
11
+
12
+ Hot-reloads on file changes. Opens the studio in your browser automatically.
13
+
14
+ When handing a project back to the user, use the Studio project URL, not the source `index.html` path:
15
+
16
+ ```text
17
+ http://localhost:<port>/#project/<project-name>
18
+ ```
19
+
20
+ Use the actual port and project directory name; treat `index.html` as source-code context, not the preview surface. For example, after `npx hyperframes preview --port 3017` in `codex-openai-video`, report `http://localhost:3017/#project/codex-openai-video`.
21
+
22
+ ## play (lightweight player)
23
+
24
+ ```bash
25
+ npx hyperframes play # current project, port 3003
26
+ npx hyperframes play ./my-video # specific project
27
+ npx hyperframes play --port 8080 # custom port
28
+ ```
29
+
30
+ `play` serves the composition through the embeddable `<hyperframes-player>` web component instead of the full Studio UI. Use it when sharing a preview link or when Studio is heavier than needed (no editor, no panels). `play` reports the plain `http://localhost:<port>` URL — no `#project/<name>` fragment (that's a Studio routing convention only `preview` uses).
31
+
32
+ The player's `playback-rate` attribute (preview speed control, drives the timeline's `timeScale`) is clamped to `[0.1, 5]`; values `≤ 0` or non-finite fall back to `1`. This is a preview/playback knob, not a composition `data-*` attribute — authored motion still renders at `1×`.
33
+
34
+ ### Launching with an external browser (preview + play)
35
+
36
+ Both `preview` and `play` can open inside an explicit Chromium-compatible browser instead of the OS default. Two use cases: isolated Chromium profile, or external CDP attach (DevTools / Playwright / Puppeteer / browser-MCP). **HyperFrames itself does not own CDP automation** — this only exposes the endpoint; whatever connects to it is your problem. Not to be confused with `--browser-gpu` (a `render` flag controlling Chrome GPU access during capture).
37
+
38
+ | Flag | Type | Notes |
39
+ | ------------------------- | --------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
40
+ | `--browser-path` | path | Absolute path to a Chromium-compatible executable (`/usr/bin/chromium`, `/Applications/Brave Browser.app/...`). |
41
+ | `--user-data-dir` | path | Chromium-compatible profile directory. Requires `--browser-path`. Use a throwaway directory to keep state out of your main profile. |
42
+ | `--remote-debugging-port` | integer 1-65535 | Open a Chromium CDP endpoint on the given port. **Requires both** `--browser-path` and `--user-data-dir` — refused otherwise, so a CDP endpoint cannot leak into your main profile by accident. |
43
+
44
+ ```bash
45
+ # Open preview in an isolated Chromium profile
46
+ npx hyperframes preview --browser-path /usr/bin/chromium --user-data-dir /tmp/hf-profile
47
+
48
+ # Same plus a CDP endpoint on :9222 (attach DevTools / Playwright / etc.)
49
+ npx hyperframes play --browser-path /usr/bin/chromium --user-data-dir /tmp/hf-profile --remote-debugging-port 9222
50
+ ```
51
+
52
+ Validation runs before any server boots, so an invalid value exits cleanly without leaving a listening socket behind.
53
+
54
+ ## render
55
+
56
+ ```bash
57
+ npx hyperframes render # standard MP4 from cwd
58
+ npx hyperframes render ./my-video --output ./out.mp4 # render from outside the project dir
59
+ npx hyperframes render --output final.mp4 # named output (no timestamp)
60
+ npx hyperframes render -c compositions/intro.html -o intro.mp4 # render a specific sub-composition file
61
+ npx hyperframes render --quality draft # fast iteration
62
+ npx hyperframes render --fps 60 --quality high # final delivery
63
+ npx hyperframes render --format webm # transparent WebM
64
+ npx hyperframes render --docker # byte-identical
65
+ ```
66
+
67
+ > Default `--output` is `renders/<project-name>_<YYYY-MM-DD>_<HH-MM-SS>.<ext>` — timestamped per render so successive runs don't clobber each other. Pass `--output` to get a stable name.
68
+
69
+ | Flag | Options | Default | Notes |
70
+ | ------------------------------------ | -------------------------------------------------------------------------------------------------- | ------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
71
+ | `dir` (positional) | path | cwd | Project directory. Omit to use current working directory. |
72
+ | `--composition`, `-c` | path to composition file | `index.html` | Render a specific composition file (e.g. `compositions/intro.html`) instead of the project's `index.html`. |
73
+ | `--output`, `-o` | path | `renders/<project>_<ts>.<ext>` | Output path. Default is timestamped (`<project-name>_YYYY-MM-DD_HH-MM-SS.<ext>`). |
74
+ | `--fps` | 24, 30, 60 | 30 | 60fps doubles render time |
75
+ | `--quality` | draft, standard, high | standard | draft for iterating |
76
+ | `--format` | mp4, webm, mov, gif, png-sequence | mp4 | WebM/MOV render with transparency; gif for inline autoplay in GitHub PRs/READMEs/docs (two-pass palette encode, fps capped at 30 — prefer `--fps 15` — no audio, 1-bit transparency only, HDR falls back to SDR); png-sequence writes RGBA frames to a directory (AE/Nuke/Fusion ingest) |
77
+ | `--gif-loop` | 0-65535 | 0 | GIF loop count; `0` loops forever. Only with `--format gif`. |
78
+ | `--resolution` | landscape, portrait, landscape-4k, portrait-4k, square, square-4k (+ aliases `1080p`, `4k`, `uhd`) | — | Supersample via Chrome `deviceScaleFactor`. Aspect ratio must match composition; scale must be an integer. Not with `--hdr`. |
79
+ | `--crf` | 0-51 | — | Encoder CRF (lower = higher quality). Mutually exclusive with `--video-bitrate`. |
80
+ | `--video-bitrate` | e.g. `10M`, `5000k` | — | Target bitrate. Mutually exclusive with `--crf`. |
81
+ | `--hdr` | flag | off | Force HDR output even with SDR sources. MP4 only. |
82
+ | `--sdr` | flag | off | Force SDR even with HDR sources. |
83
+ | `--workers` | number or `auto` | auto | Each worker spawns Chrome (~256 MB) |
84
+ | `--docker` | flag | off | Reproducible output across hosts |
85
+ | `--gpu` | flag | off | GPU-accelerated FFmpeg encoding (NVENC / VideoToolbox / VAAPI / QSV) |
86
+ | `--browser-gpu` / `--no-browser-gpu` | flag | auto (local), off (docker) | Host GPU for Chrome/WebGL capture |
87
+ | `--browser-timeout` | seconds (0.001–86400) | 60 | Puppeteer page-navigation timeout for the entry HTML. Raise when heavy compositions (many videos / fonts / remote assets) can't reach `domcontentloaded` within the 60s default. |
88
+ | `--quiet` | flag | off | Suppress verbose output |
89
+ | `--strict` | flag | off | Fail on lint errors |
90
+ | `--strict-all` | flag | off | Fail on lint errors AND warnings |
91
+ | `--variables` | JSON object | — | Override values declared in `data-composition-variables` |
92
+ | `--variables-file` | path | — | JSON file with variable values (alternative to `--variables`) |
93
+ | `--strict-variables` | flag | off | Fail render on undeclared keys or type mismatches in `--variables` |
94
+
95
+ **Quality guidance:** `draft` while iterating, `standard` for review, `high` for final delivery.
96
+
97
+ **Parametrized renders:** the composition declares its variables on the `<html>` root with **`data-composition-variables`** — a JSON **array of declarations** (`{id, type, label, default}` per entry) that defines the schema. Scripts inside read the resolved values via `window.__hyperframes.getVariables()`. The CLI `--variables '{"title":"Q4 Report"}'` is a JSON **object keyed by id** that overrides those declared defaults for one render; missing keys fall through, so the same composition runs unchanged in dev preview and in production. Sub-comp hosts can also override per-instance with `data-variable-values`. See the `hyperframes-core` skill for the full pattern.
98
+
99
+ ## publish
100
+
101
+ ```bash
102
+ npx hyperframes publish # upload current project, return public URL
103
+ npx hyperframes publish ./my-video # specific project
104
+ npx hyperframes publish --yes # skip the confirmation prompt (scripts/CI)
105
+ ```
106
+
107
+ Uploads the project's source (HTML + assets) and returns a stable public URL that renders in the browser. Use this for sharing a draft for review before rendering MP4, or for embedding the composition elsewhere. Lint findings are surfaced before upload but do not block.
@@ -0,0 +1,75 @@
1
+ # info, upgrade, compositions, docs, benchmark, telemetry, asset preprocessing
2
+
3
+ Catch-all reference for commands that don't fit the main dev loop.
4
+
5
+ ## info
6
+
7
+ ```bash
8
+ npx hyperframes info # project metadata
9
+ npx hyperframes info ./my-video # specific project
10
+ npx hyperframes info --json
11
+ ```
12
+
13
+ Prints **project** metadata: name, resolution, duration, element counts by type, track count, and total project size. Project-level — not environment. For environment health use `doctor`.
14
+
15
+ ## upgrade
16
+
17
+ ```bash
18
+ npx hyperframes upgrade # check + interactive prompt
19
+ npx hyperframes upgrade --check # check and exit, no prompt (agent-friendly)
20
+ npx hyperframes upgrade --check --json # machine-readable: current / latest / updateAvailable
21
+ npx hyperframes upgrade --yes # print upgrade commands without prompting
22
+ ```
23
+
24
+ Compares the installed CLI version against npm latest.
25
+
26
+ ## compositions, docs
27
+
28
+ ```bash
29
+ npx hyperframes compositions # list compositions in project
30
+ npx hyperframes compositions --json
31
+ npx hyperframes docs # list available topics
32
+ npx hyperframes docs rendering # print one topic inline in the terminal
33
+ ```
34
+
35
+ `compositions` lists every `data-composition-id` in the project (including sub-comps) with duration, resolution, and element count.
36
+
37
+ `docs` prints inline documentation **in the terminal** — it does not open a browser. Topics: `data-attributes`, `examples`, `rendering`, `gsap`, `troubleshooting`, `compositions`. Run without a topic to see the list.
38
+
39
+ ## benchmark
40
+
41
+ ```bash
42
+ npx hyperframes benchmark # run the preset matrix in current project
43
+ npx hyperframes benchmark ./my-video # specific project
44
+ npx hyperframes benchmark --runs 5 # repeat each config N times (default 3)
45
+ npx hyperframes benchmark --json
46
+ ```
47
+
48
+ Renders the project with 5 preset configurations — `30fps draft 2w`, `30fps standard 2w`, `30fps high 2w`, `30fps standard 4w`, `60fps standard 4w` — and prints a comparison of render speed and output file size. Use it to find the fastest acceptable preset for your machine. Not a single-render-with-stage-breakdown.
49
+
50
+ ## telemetry
51
+
52
+ ```bash
53
+ npx hyperframes telemetry status # show telemetry state
54
+ npx hyperframes telemetry disable # disable anonymous usage telemetry
55
+ npx hyperframes telemetry enable # re-enable telemetry
56
+ ```
57
+
58
+ Telemetry is anonymous usage counters only. Disable globally with `HYPERFRAMES_NO_TELEMETRY=1` if env-var control is preferred over the subcommand.
59
+
60
+ Events include two fingerprint properties used to distinguish managed-sandbox runs from real laptops — no PII, no env-var **values**, only existence checks:
61
+
62
+ - **`sandbox_runtime`**: `gvisor` / `firecracker` / `docker` / `kvm` / `wsl` / `null`. gVisor via kernel string + `/proc/version`. Firecracker via `/dev/vsock` + DMI sys_vendor. Docker via `/.dockerenv` + cgroup.
63
+ - **`agent_runtime`**: `claude_code` / `codex` / `cursor` / `copilot_agent` / `jules` / `replit` / `devin` / `aider` / `gemini_cli` / `hermes` / `openclaw` / `null`. Detected by the existence of well-known vendor env vars; the values themselves are never read.
64
+
65
+ ## Asset Preprocessing
66
+
67
+ ```bash
68
+ npx hyperframes tts
69
+ npx hyperframes transcribe
70
+ npx hyperframes remove-background
71
+ ```
72
+
73
+ These produce assets (narration audio, word-level transcripts, transparent video) that get dropped into a composition. Each may download its own model on first run.
74
+
75
+ For voice selection, Whisper model rules, output format choice, and the TTS → transcript → captions chain, invoke the `hyperframes-media` skill. This skill stays focused on the dev loop.