Skip to content

Commit 00a308f

Browse files
committed
feat(studio): runtime hooks — global time compiler + keyframe runtime
Add the runtime bridge layer: global time compilation (tween % → clip %), soft reload after mutations, runtime keyframe preview, and keyframe commit helper.
1 parent 39ad00b commit 00a308f

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

packages/studio/src/utils/gsapSoftReload.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,12 @@ export function applySoftReload(iframe: HTMLIFrameElement | null, scriptText: st
8181
win.__hfStudioManualEditsApply?.();
8282
};
8383

84-
// Load MotionPathPlugin on demand if the script uses motionPath.
85-
// Uses the same CDN as composition templates (GSAP_CDN in constants.ts).
84+
// Load MotionPathPlugin on demand if the script uses motionPath
8685
const needsMotionPath = /motionPath\s*[:{]/.test(scriptText);
8786
if (needsMotionPath && !win.MotionPathPlugin && win.gsap) {
8887
const pluginScript = doc.createElement("script");
8988
pluginScript.src = "https://cdn.jsdelivr.net/npm/gsap@3.12.5/dist/MotionPathPlugin.min.js";
9089
pluginScript.onload = () => executeScript();
91-
pluginScript.onerror = () => executeScript();
9290
doc.head.appendChild(pluginScript);
9391
return;
9492
}

0 commit comments

Comments
 (0)