mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-11-16 06:19:21 +00:00
* feat(core): a composition with no authored length takes it from its clips A new resolver in @hyperframes/parsers returns a composition length as authored, derived from its latest clip end, or unresolved, and counts clips whose length is still pending. The runtime uses it in its two existing max-end loops with identical results, and as a last resort only when no timeline, floor or caller length exists, so a composition that has a length today keeps it. The derived source is published on window.__hf.durationSource for render telemetry. Lint reports a root that has timed clips but no data-duration as a warning that says where to author it, and still errors when there is nothing to derive from. * refactor(core): resolve the runtime duration floor in one call The declared duration and sub-composition ends were resolved separately and maxed by hand; one resolver call over both gives the same latest end. * fix(core): a derived composition length waits for every clip length and reports honestly Review follow-up. The runtime returns a content-derived length only when no clip is still pending, so a renderer that reads duration once cannot lock in a short one. window.__hf.durationSource is cleared whenever a timeline or floor supplies the length, and the diagnostic fires only for a derived length. Lint says "at least Ns", counts reference-start clips as known only at runtime, and ignores a data-end before data-start. * fix(core): a sub-composition with no known length counts as pending A host whose own timeline is not registered yet no longer lets the content-derived length show early. Tests pin the pending host and that the diagnostic fires only for a derived length. * fix(core): a loaded Lottie with no registered animation keeps the length pending Lottie registers from author scripts with no DOM marker, and nothing re-derives the length after it registers. A composition with clips and a loaded Lottie library therefore stays at zero, as before, instead of locking in the clips length and cutting the animation short. * test(core): a registered Lottie supplies the length and the clips length is not used Pins the other side of the pending Lottie rule. Once an animation reports a length it enters the duration floor, so the content-derived fallback is never consulted. * test(core): the declared and DotLottie pending branches are covered
133 lines
4.4 KiB
JSON
133 lines
4.4 KiB
JSON
{
|
|
"package": "@hyperframes/parsers",
|
|
"localNodeRuntime": true,
|
|
"subpaths": {
|
|
".": {
|
|
"source": "./src/index.ts",
|
|
"runtime": "./dist/index.js",
|
|
"types": "./dist/index.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./package.json": {
|
|
"source": "./package.json",
|
|
"runtime": "./package.json",
|
|
"types": null,
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./gsap-parser": {
|
|
"source": "./src/gsapParserExports.ts",
|
|
"runtime": "./dist/gsapParserExports.js",
|
|
"types": "./dist/gsapParserExports.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./gsap-parser-acorn": {
|
|
"source": "./src/gsapParserAcorn.ts",
|
|
"runtime": "./dist/gsapParserAcorn.js",
|
|
"types": "./dist/gsapParserAcorn.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./gsap-writer-acorn": {
|
|
"source": "./src/gsapWriterAcorn.ts",
|
|
"runtime": "./dist/gsapWriterAcorn.js",
|
|
"types": "./dist/gsapWriterAcorn.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./gsap-constants": {
|
|
"source": "./src/gsapConstants.ts",
|
|
"runtime": "./dist/gsapConstants.js",
|
|
"types": "./dist/gsapConstants.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./spring-ease": {
|
|
"source": "./src/springEase.ts",
|
|
"runtime": "./dist/springEase.js",
|
|
"types": "./dist/springEase.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./hf-ids": {
|
|
"source": "./src/hfIds.ts",
|
|
"runtime": "./dist/hfIds.js",
|
|
"types": "./dist/hfIds.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./gsap-parser-recast": {
|
|
"source": "./src/gsapParser.ts",
|
|
"runtime": "./dist/gsapParser.js",
|
|
"types": "./dist/gsapParser.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./slideshow": {
|
|
"source": "./src/slideshow/index.ts",
|
|
"runtime": "./dist/slideshow.js",
|
|
"types": "./dist/slideshow.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./asset-paths": {
|
|
"source": "./src/assets.ts",
|
|
"runtime": "./dist/assets.js",
|
|
"types": "./dist/assets.d.ts",
|
|
"environments": ["bun", "node"]
|
|
},
|
|
"./composition": {
|
|
"source": "./src/composition.ts",
|
|
"runtime": "./dist/composition.js",
|
|
"types": "./dist/composition.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./composition-contract": {
|
|
"source": "./src/compositionContract.ts",
|
|
"runtime": "./dist/compositionContract.js",
|
|
"types": "./dist/compositionContract.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./media-duration": {
|
|
"source": "./src/mediaDuration.ts",
|
|
"runtime": "./dist/mediaDuration.js",
|
|
"types": "./dist/mediaDuration.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./media-duration-fixtures": {
|
|
"source": "./src/mediaDurationFixtures.ts",
|
|
"runtime": "./dist/mediaDurationFixtures.js",
|
|
"types": "./dist/mediaDurationFixtures.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./top-level-elements": {
|
|
"source": "./src/topLevelElements.ts",
|
|
"runtime": "./dist/topLevelElements.js",
|
|
"types": "./dist/topLevelElements.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./color-grading-contract": {
|
|
"source": "./src/colorGradingContract.ts",
|
|
"runtime": "./dist/colorGradingContract.js",
|
|
"types": "./dist/colorGradingContract.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./sub-composition-validity": {
|
|
"source": "./src/subCompositionValidity.ts",
|
|
"runtime": "./dist/subCompositionValidity.js",
|
|
"types": "./dist/subCompositionValidity.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
},
|
|
"./ff-binaries": {
|
|
"source": "./src/ffBinaries.ts",
|
|
"runtime": "./dist/ffBinaries.js",
|
|
"types": "./dist/ffBinaries.d.ts",
|
|
"environments": ["bun", "node"]
|
|
},
|
|
"./asset-resolution": {
|
|
"source": "./src/assetResolution.ts",
|
|
"runtime": "./dist/assetResolution.js",
|
|
"types": "./dist/assetResolution.d.ts",
|
|
"environments": ["bun", "node"]
|
|
},
|
|
"./composition-duration": {
|
|
"source": "./src/compositionDuration.ts",
|
|
"runtime": "./dist/compositionDuration.js",
|
|
"types": "./dist/compositionDuration.d.ts",
|
|
"environments": ["browser", "bun", "node"]
|
|
}
|
|
}
|
|
}
|