Commit Graph
1308 Commits
Author SHA1 Message Date
JamesandClaude Opus 4.7 6d1236a0cc feat(cli): add --output-resolution to lambda render
Allows authored-at-1080p compositions to render at 4K/2K via Chrome
deviceScaleFactor supersampling without re-laying-out the composition.
Plain --width 3840 silently lays out at 1920×1080 because data-width/
data-height attrs override Config.width — this flag is the supported
way to ask the renderer to supersample.

Accepts canonical CanvasResolution names (landscape, landscape-4k,
portrait, portrait-4k, square, square-4k) and aliases (1080p, 4k, uhd,
hd, 1080p-portrait, 4k-portrait, 1080p-square, 4k-square). Wired
through render + render-batch.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 15:08:30 -04:00
Miguel Ángel 154359d95d chore: bump version to 0.6.36 v0.6.36 2026-05-22 13:37:28 -04:00
Miguel Ángel c11f715029 Merge pull request #1034 from heygen-com/fix/retrocompat-fps-input
fix(producer): accept plain integer fps in createRenderJob
2026-05-22 19:36:25 +02:00
Miguel Ángel 215811334f fix(producer): accept plain integer fps in createRenderJob
The rational `Fps = { num, den }` refactor in 5dcc89c broke callers
passing `fps: 30` (the form documented in every code example and used
by external consumers). FFmpeg received `undefined/undefined` as the
framerate, causing a cryptic exit-code error.

Add `FpsInput = number | Fps` and `toFps()` normalizer in
@hyperframes/core. `createRenderJob` now accepts both forms —
plain integers are promoted to `{ num, den: 1 }` at the boundary;
`RenderConfig.fps` stays strict `Fps` internally so no downstream
code changes.

Also fixes the producer and engine docs, which showed phantom
`input`/`output` fields on `createRenderJob` and a wrong
`executeRenderJob(job)` signature (missing `projectDir`/`outputPath`
args).

Closes #1031
2026-05-22 13:35:16 -04:00
Miguel Ángel 6c191e2292 chore: bump version to 0.6.35 v0.6.35 2026-05-22 13:31:45 -04:00
Miguel Ángel 658e528371 Merge pull request #1033 from heygen-com/fix/studio-rejection-flood
fix(studio): stop 3M/day rejection flood from composition 404s
2026-05-22 19:30:39 +02:00
Miguel Ángel 69cf942036 revert: drop playground from fallow ignorePatterns 2026-05-22 13:23:07 -04:00
Miguel Ángel 36de02c4bf fix(studio): stop composition fetch-404 flood and cap error telemetry
Two fixes for the 3M+ unhandled_promise_rejection events/day spike:

1. Filter: suppress "Error fetching ... 404" rejections from composition
   code — these are asset-not-found content errors, not Studio bugs.

2. Rate-limit: cap both error and rejection telemetry at 50 per session.
   After the cap, emit a single *_cap_reached event so we know capping
   occurred without generating unlimited events.

3. Root cause: webAudioTransport now checks response.ok before decode
   and caches failed URLs in _failedSrcs so repeat ticks don't re-fetch
   the same 404 on every playback frame.

Also add playground/ to fallow ignorePatterns — local experiment
directory was tripping the audit gate.
2026-05-22 13:22:00 -04:00
Miguel Ángel aebb7b2660 chore: bump version to 0.6.34 v0.6.34 2026-05-22 11:44:06 -04:00
Miguel Ángel 0aae600c0f Merge pull request #1030 from heygen-com/feat/enable-blocks-panel-default
feat(studio): enable blocks panel by default
2026-05-22 17:42:22 +02:00
Miguel Ángel 4ba735c8ff feat(studio): enable blocks panel by default
Flip the fallback from false to true so the blocks panel is on for
everyone out of the box. Users can still disable it via
VITE_STUDIO_ENABLE_BLOCKS_PANEL=false if needed.
2026-05-22 11:41:50 -04:00
Miguel Ángel b1ea5d6652 Merge pull request #1027 from lirian-su-opus/fix/bundler-runtime-replace-special-patterns 2026-05-22 16:48:33 +02:00
Lirian SuandClaude Opus 4.7 69b7965446 fix(core): preserve replace-pattern characters in bundled runtime IIFE
`injectInterceptor` used `String.prototype.replace(target, replacement)`
to inject the runtime `<script>` before `</head>`. The replacement
string is a substitution template — `$&` expands to the matched
substring, and the minified runtime IIFE contains legitimate `$&`
sequences (e.g. `if(te&&$&!y.hasAttribute(...))`), so every `$&` in
the body was silently rewritten to `</head>`, producing
`Unexpected token '<'` SyntaxErrors and breaking every timeline in
the bundle.

Switch to the function-replacer form so the runtime body is passed
through verbatim. Add a regression test that diffs the bundled
runtime body against `getHyperframeRuntimeScript()` and asserts only
one `</head>` survives in the document — the test exercises the
`<head>`-present injection path (the only branch that uses the
substitution template; the no-`<head>` fallback uses slice+concat
and was unaffected).

Only the bundler is affected — `producer/fileServer.ts` already uses
the function form via `injectScriptsIntoHtml` in
`htmlDocument.ts`, so render output was correct. Snapshot, preview,
studio, layout, and validate all consume `bundleToSingleHtml` and
were broken before this fix.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-22 15:06:11 +08:00
Miguel Ángel ee4e088434 chore: bump version to 0.6.33 v0.6.33 2026-05-21 22:03:20 -04:00
Miguel Ángel 772d6c70ff Merge pull request #1025 from heygen-com/feat/studio-catalog-panel
feat(studio): catalog panel with Ask agent, block preview, and composition context
2026-05-22 04:01:33 +02:00
Miguel Ángel 0cc012cc06 fix: update tests for double-pause seek and formatted insertion 2026-05-21 22:00:14 -04:00
Miguel Ángel 2483ab5446 feat(studio): add Tooltip to player and timeline controls 2026-05-21 21:55:13 -04:00
Miguel Ángel 8ffa2eb8c1 fix(studio): use first child element for tooltip positioning 2026-05-21 21:47:29 -04:00
Miguel Ángel 738523b721 feat(studio): add styled Tooltip component to tabs and panels
Create a Tooltip component with styled popover (dark bg, border,
shadow) that appears on hover with a 400ms delay. Applied to:
- Left sidebar tabs: Code, Comps, Assets, Catalog
- Right panel tabs: Design, Layers, Motion, Renders

Replaces native title attributes with proper styled tooltips.
2026-05-21 21:41:30 -04:00
Miguel Ángel 850ff9301f feat(studio): add tooltips to studio controls and tabs
Add title attributes to interactive elements that were missing them:
- PlayerControls: Play/Pause, playback speed, shortcuts panel, clear
  in/out-point buttons, and jump-to-frame Go button
- StudioRightPanel: Design, Layers, Motion, and Renders tab buttons
2026-05-21 21:34:35 -04:00
Miguel Ángel 3e7b464b3b fix(studio): ensure GSAP timeline stays paused after seek
Call tl.pause() both before AND after tl.seek() in the adapter.
GSAP's seek() can reactivate a timeline depending on internal state;
the second pause() guarantees it stays frozen at the seeked position.
2026-05-21 21:26:32 -04:00
Miguel Ángel 7b1aa23039 fix(studio): pause all media elements in iframe on seek
When seeking via the slider or timeline scrub, explicitly pause all
<video> and <audio> elements inside the preview iframe. The GSAP
timeline pauses but iframe media elements can continue playing
independently, causing audio to keep going after a seek.
2026-05-21 21:17:11 -04:00
Miguel Ángel cf940326e9 feat(studio): make prompt modal editable with textarea 2026-05-21 20:31:00 -04:00
Miguel Ángel 300ef395ea fix(studio): destructure onShowPrompt prop in BlockCard 2026-05-21 20:29:04 -04:00
Miguel Ángel d2da3bf6db feat(studio): show prompt preview modal before copying
Clicking "Ask agent" now opens a modal that shows the full generated
prompt so the user can read it before copying. The modal has a "Copy
prompt" button that turns green on success. This replaces the silent
clipboard copy that gave no visibility into what was copied.
2026-05-21 20:12:02 -04:00
Miguel Ángel 0b0021a310 feat(studio): improve Ask agent UX, add tooltips to tabs and buttons
- Ask agent button turns green with checkmark on copy
- Add button shows tooltip "Add to composition at current time"
- Ask agent shows tooltip "Copy a prompt to paste into your AI agent"
- Tab tooltips: Code, Comps, Assets, Catalog each explain their purpose
- Search placeholder updated to "Search by name, category, or tag…"
2026-05-21 19:57:22 -04:00
Miguel Ángel 76d2c6af5d fix(studio): fix catalog Add button per category, search by tags
Add button rules: VFX, Social, Scenes get Add + Ask agent. Captions,
Transitions, Effects, Data get Ask agent only.

Search now matches category names and tags, so searching "captions"
shows all caption blocks.
2026-05-21 19:54:35 -04:00
Miguel Ángel d5518b26f1 fix(studio): destructure onAdd prop in BlockCard 2026-05-21 19:50:36 -04:00
Miguel Ángel 8c698d7f2c feat(studio): show Add button for components, Ask agent for all
Components (hyperframes:component) get both "Add" and "Ask agent"
buttons since they work as drop-in overlays. Blocks (scenes, data,
VFX, transitions) show only "Ask agent" since they need agent-guided
customization.
2026-05-21 19:31:14 -04:00
Miguel Ángel fb48b8d9b4 feat(studio): include composition context in catalog agent prompts
The "Ask agent" button now copies the current composition state along
with the category-specific prompt: playback time, active composition
path, dimensions, and all elements visible at the current time with
their track, timing, and source paths. Gives the agent full context
to place and customize the block correctly.
2026-05-21 19:23:08 -04:00
Miguel Ángel 2614071618 feat(studio): show main composition behind component sub-composition previews
When previewing a component (compositions/components/*), render the
main composition player as a backdrop behind the transparent component
overlay. This lets users see captions, vignettes, and other overlays
in context instead of against a black void.
2026-05-21 19:01:20 -04:00
Miguel Ángel 5c79cd0a8e fix(studio): rewrite block dimensions to match host project on install
Registry blocks are authored at 1920x1080 but projects may use
different dimensions (e.g. 1280x720). After installing a block, the
server now reads the host project's data-width/data-height from
index.html and rewrites the block's viewport meta and CSS dimensions
to match, preventing overflow.
2026-05-21 18:54:36 -04:00
Miguel Ángel e316aa4409 feat(studio): replace Add with Ask agent in catalog cards
Remove the Add button and drag-and-drop from catalog cards — blocks
and components need agent-guided customization, not blind insertion.

Each card now shows a single "Ask agent" button that copies a rich,
category-specific prompt to clipboard with context about what the
block does and how to customize it (captions: transcribe + style,
transitions: place at cut point, data: replace values, etc.).
2026-05-21 18:52:11 -04:00
Miguel Ángel 3e9794a23a feat(studio): add dual-action buttons to catalog cards
Each catalog card now shows two hover buttons:
- "Add" — inserts the block/component into the composition at the
  current playhead position (existing behavior, now with + icon)
- "Agent prompt" — copies a contextual prompt to clipboard tailored
  to the block's category (captions, transitions, VFX, etc.) so the
  user can paste it into their AI agent for guided customization
2026-05-21 18:46:59 -04:00
Miguel Ángel 13be10afb7 chore: bump version to 0.6.32 v0.6.32 2026-05-21 18:29:54 -04:00
Miguel Ángel d50c48ae1e Merge pull request #1010 from heygen-com/worktree-feat+studio-blocks-drop-position
feat(studio): preserve drop position when dropping blocks onto preview
2026-05-22 00:28:42 +02:00
Miguel Ángel 67701df4e9 fix(studio): add blocks at current playhead, extend root duration
Blocks and components now start at the current playhead position
instead of being appended after all existing content. If the new
element extends beyond the root composition's data-duration, the
root is automatically extended to fit.
2026-05-21 18:28:17 -04:00
Miguel Ángel 6f9b655fff fix(studio): format inserted block HTML with proper indentation
insertTimelineAssetIntoSource now detects the parent indent level and
adds the new element with matching child indentation. Block attributes
are written one-per-line for readability.
2026-05-21 18:28:17 -04:00
Miguel Ángel 997e3948e4 fix(studio): use host composition dimensions for all added blocks
Blocks were using their own native dimensions (e.g. 1920x1080) instead
of the host composition dimensions (e.g. 1280x720), causing them to
overflow the viewport and break the layout. The block's iframe scales
its content to fit the container, so using host dimensions is correct.
2026-05-21 18:28:17 -04:00
Miguel Ángel 34a4ad2ed3 fix(studio): read z-index from live iframe DOM, rename Layer to Z-index
Replace fragile regex z-index parsing with getComputedStyle on the
preview iframe elements — the same source of truth the inspector uses.

Rename "Layer" to "Z-index" in the design panel for clarity.
2026-05-21 18:28:17 -04:00
Miguel Ángel 0999ed56e6 fix(studio): lift block drop handling above DomEditOverlay
The DomEditOverlay sits at z-10 with pointer-events:auto over the
preview, intercepting all drag events before they reach NLEPreview's
viewport. Move block drop handling from NLEPreview up to the wrapper
div in NLELayout that contains both the preview and the overlay, so
drag-and-drop from the Catalog panel onto the preview area works
regardless of inspector state.
2026-05-21 18:28:17 -04:00
Miguel Ángel 289aa03499 fix(studio): inject runtime env overrides for pre-built SPA mode
VITE_STUDIO_* env vars set in the user's shell had no effect when
running `hyperframes preview` because the pre-built studio bundle had
them baked at Vite build time.

The embedded Hono server now collects VITE_STUDIO_* vars from
process.env and injects them as a `window.__HF_STUDIO_ENV__` script
tag into index.html. The client merges this runtime object on top of
the baked `import.meta.env`, so flags like
VITE_STUDIO_ENABLE_BLOCKS_PANEL=1 work as expected at runtime.
2026-05-21 18:27:29 -04:00
Miguel Ángel f51d324ff5 fix(studio): show block preview directly in the player area
Render the catalog hover preview as a full-bleed video inside the
preview overlay slot instead of a dimmed card overlay on top.
2026-05-21 18:27:29 -04:00
Miguel Ángel 9f9b9f4c06 feat(studio): improve blocks panel UX
- Rename "Blocks" tab to "Catalog"
- Replace fullscreen hover popup with inline preview in main area
- Fix z-index: newly added blocks/components use max existing z-index + 1
  instead of element count, ensuring they appear on top
2026-05-21 18:27:29 -04:00
Miguel Ángel 1d6ea53db9 feat(studio): preserve drop position when dropping blocks onto preview
Blocks dragged from the Blocks panel and dropped onto the composition
preview now land at the position where they were dropped, instead of
always being placed at (0, 0).

The preview viewport converts screen coordinates to composition space
using the stage element's bounding rect, accounting for zoom and pan.
A visual drop indicator (dashed border overlay) appears while dragging
over the preview.
2026-05-21 18:27:29 -04:00
Miguel Ángel 053a47a363 Merge pull request #1013 from heygen-com/feat/studio-suppress-resize-observer
fix(studio): suppress ResizeObserver loop noise from error telemetry
2026-05-21 23:21:14 +02:00
Miguel Ángel c61ccdb7a6 fix(studio): suppress ResizeObserver loop noise from error telemetry 2026-05-21 17:13:47 -04:00
Ular Kimsanov 74b86f6cfa Merge pull request #1006 from heygen-com/feat/skill-hyperframes-core-v2
feat(skill): hyperframes core — remove prescriptive tables, reference text-effects (not vendor)
2026-05-21 13:09:13 -07:00
Ular Kimsanov b9e4ca169e Merge pull request #1005 from heygen-com/feat/skill-website-to-hyperframes-v2
feat(skill): website-to-hyperframes — concept-first authoring + per-beat read protocol
2026-05-21 12:43:40 -07:00
Miguel Ángel 4c358e6dcc Merge pull request #1001 from heygen-com/fix/sub-comp-t0-baseline-regen
test(producer): regenerate sub-comp-t0 baseline + add gsap_from_opacity_noop lint rule
2026-05-21 21:42:37 +02:00