refactor(core): unify composition contract (#2157)

* refactor(core): unify composition contract

* fix(parsers): parse start expressions linearly
This commit is contained in:
James Russo
2026-07-16 02:44:22 -04:00
committed by GitHub
parent 9ed255c0ef
commit 21cb722ebd
36 changed files with 1148 additions and 441 deletions
@@ -237,7 +237,7 @@ window.__timelines = { t: tl };</script>
expect(liveDocEl.getAttribute("data-composition-variables") ?? "").not.toContain("accent");
});
it("mirrors setTiming onto the live element's data-start/data-end attributes", async () => {
it("mirrors canonical setTiming attributes onto the live element", async () => {
const iframe = mountIframe(BASE_HTML);
const comp = await openComposition(BASE_HTML);
const adapter = createIframePreviewAdapter(iframe);
@@ -249,7 +249,8 @@ window.__timelines = { t: tl };</script>
'[data-hf-id="hf-title"]',
) as HTMLElement;
expect(liveTitle.getAttribute("data-start")).toBe("1");
expect(liveTitle.getAttribute("data-end")).toBe("3");
expect(liveTitle.getAttribute("data-duration")).toBe("2");
expect(liveTitle.getAttribute("data-end")).toBeNull();
});
});