MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / buildSetGsapTweenSection

Function buildSetGsapTweenSection

packages/sdk-playground/src/main.ts:817–836  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

815}
816
817function buildSetGsapTweenSection(): HTMLDivElement {
818 const newDur = mkNumInput("new dur", "1.5");
819 const update = mkBtn("Update dur", "", () => {
820 if (!needTween()) return;
821 comp!.setGsapTween(lastTweenId, { duration: numOr(newDur.value, 1) });
822 logEntry("op", { setGsapTween: { id: lastTweenId, duration: newDur.value } });
823 });
824 const remove = mkBtn("Remove", "danger", () => {
825 if (!needTween()) return;
826 comp!.removeGsapTween(lastTweenId);
827 logEntry("op", { removeGsapTween: lastTweenId });
828 lastTweenId = "";
829 tweenIdDisplay.textContent = "no tween added yet";
830 });
831 return opSection(
832 "setGsapTween / removeGsapTween",
833 opRow(mkNote("operates on last added tween")),
834 opRow(newDur, update, remove),
835 );
836}
837
838function buildLabelSection(): HTMLDivElement {
839 const name = mkInput("label", "midpoint");

Callers

nothing calls this directly

Calls 10

mkNumInputFunction · 0.85
mkBtnFunction · 0.85
needTweenFunction · 0.85
numOrFunction · 0.85
logEntryFunction · 0.85
opSectionFunction · 0.85
opRowFunction · 0.85
mkNoteFunction · 0.85
setGsapTweenMethod · 0.65
removeGsapTweenMethod · 0.65

Tested by

no test coverage detected