/**
* Hyperframes mode helpers.
*
* The `video-hyperframes` skill (see
* `src/lib/templates/skills/video-hyperframes/SKILL.md`) emits a document with
*
*
* …
*
*
* This module extracts the per-frame body + the META JSON so an exporter can
* stamp out a Remotion project (one component per frame).
*/
export type HyperframeMetaEntry = {
i: number;
duration: number;
transition?: string;
scene?: string;
};
export type HyperFrame = {
/** 1-based index from META, or DOM order */
i: number;
/** ms */
duration: number;
transition: string;
scene: string;
/** Inner HTML of the (no wrapper) */
innerHtml: string;
/** Best-effort background colour from inline style */
bg?: string;
};
export type HyperframesParsed = {
isHyperframes: boolean;
frames: HyperFrame[];
/** Original `` contents (Tailwind CDN, fonts, inline