fix(examples): host the kinetic-type A-roll so the video actually renders#1799
Draft
miguel-heygen wants to merge 1 commit into
Draft
fix(examples): host the kinetic-type A-roll so the video actually renders#1799miguel-heygen wants to merge 1 commit into
miguel-heygen wants to merge 1 commit into
Conversation
…ders The A-roll <video> was authored inside the main-graphics sub-composition template. The runtime only seeks and decodes media that is a direct child of the host root, so the footage was never driven by the live runtime and renders blank in Studio preview and the player (the producer's compile step happened to hoist it, masking the contract violation in server renders). The example also failed lint with eight errors. Root cause and fixes: - Move the <video> out of compositions/main-graphics.html and into index.html as a direct child of #root, with data-start/data-duration/data-track-index and class="clip". Its per-scene opacity reveal now runs on the main timeline at global time, since a sub-composition timeline cannot reach host elements. - Make the sub-composition a transparent overlay shell (background: transparent) and stack it above the host video so the type renders over the footage. - Drop the crossorigin attribute (plain displayed media never needs it) and mark the audible footage with data-has-audio="true". - Replace the three CSS translateY values that GSAP would overwrite with fromTo tweens (carson-line-1, wes-text-top, wes-text-bottom). - Swap the unbundled Libre Baskerville for the bundled Playfair Display serif so the renderer can supply the Wes Anderson typography, and drop the redundant -apple-system token from the body font stack. lint reports 0 errors, validate passes, and frame extraction confirms the A-roll composites correctly under every type scene.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The
kinetic-typeflagship example failshyperframes lintwith 8 errors, and its A-roll footage is not driven by the live runtime. The centerpiece error ismedia_in_subcomposition: the A-roll<video>was authored inside themain-graphicssub-composition<template>.Root cause
The runtime only seeks and decodes media that is a direct child of the host root (
index.html). Media nested in a sub-composition template is never seeked, so it renders blank in Studio preview and the<hyperframes-player>web component. The composition's server render only worked because the producer's compile step hoists nested media and auto-stamps timing, which masked the contract violation. The example also carriedcrossorigin(breaks preview), an untimed video (media_missing_data_start), threegsap_css_transform_conflictcases where a CSStranslateYwould be discarded by a GSAPytween, and an unbundledLibre Baskervillefamily with no@font-face.Fix (root cause, no suppressions)
<video>out ofcompositions/main-graphics.htmland intoindex.htmlas a direct child of#root(archetype B from composition-patterns), withdata-start/data-duration/data-track-indexandclass="clip". Its per-scene opacity reveal now runs on the main timeline at global time, since a sub-composition timeline cannot reach host elements.background: transparent) stacked above the host video, so the type renders over the footage.crossorigin; mark the audible footage withdata-has-audio="true".translateYvalues withfromTotweens (carson-line-1,wes-text-top,wes-text-bottom) so GSAP no longer overwrites them.Libre Baskervillefor the bundledPlayfair Displayserif (an auto-resolved family) so the renderer supplies the Wes Anderson typography, and drop the redundant-apple-systemtoken from the body font stack.Verification
hyperframes lint registry/examples/kinetic-type: was 8 errors, now 0 errors (2 pre-existing warnings remain:google_fonts_import,composition_self_attribute_selector).hyperframes validate registry/examples/kinetic-type: passes (exit 0, no console errors).ffmpegframe extraction: the A-roll composites correctly under the Swiss panel (3.0s), the David Carson "No timeline" headline (10.0s, correctly positioned after thefromTochange), and the Vignelli outro (14.0s). The Wes Anderson scene (12.5s) shows the elegant Playfair Display italic serif with the footage hidden as intended.ffprobeconfirms both h264 video and aac audio streams in the output. Before and after renders match visually, with the after version now contract-correct and lint-clean.