mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-03 04:38:33 +00:00
* fix(producer): render -c <scene> uses the scene's own duration, not the project's When rendering a single sub-composition standalone (`hyperframes render -c compositions/scene.html`), the producer extracts the scene's mount from index.html and wraps it in a shallow clone of the master root. That clone kept the master's `data-duration`, so the standalone composition advertised the whole project's length instead of the scene's own: a 2s scene rendered for the full 12s project, and a master that derives its length from sibling mounts (now removed) produced "Composition has zero duration". Re-point the extracted wrapper's `data-duration` at the scene's own, read from the scene file's `<template>` root (the source of truth for that scene), with a fallback to the mount's `data-duration`. Full-project renders are unaffected — they never take the extraction branch. Verified end-to-end via the pre-capture duration gate: a 2s scene now resolves to 2s and a 10s scene to 10s (both were 12s), while the full index render stays at 12s. Adds unit coverage for both the scene-file and mount-fallback paths. * test(producer): distinguish scene and mount durations