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

Function handleMaterializeKeyframes

packages/sdk/src/engine/mutate.ts:1143–1166  ·  view source on GitHub ↗
(
  parsed: ParsedDocument,
  animationId: string,
  keyframes: Array<{
    percentage: number;
    properties: Record<string, number | string>;
    ease?: string;
  }>,
  easeEach?: string,
  resolvedSelector?: string,
)

Source from the content-addressed store, hash-verified

1141}
1142
1143function handleMaterializeKeyframes(
1144 parsed: ParsedDocument,
1145 animationId: string,
1146 keyframes: Array<{
1147 percentage: number;
1148 properties: Record<string, number | string>;
1149 ease?: string;
1150 }>,
1151 easeEach?: string,
1152 resolvedSelector?: string,
1153): MutationResult {
1154 const script = getGsapScript(parsed.document);
1155 if (!script) return EMPTY;
1156 const newScript = materializeKeyframesFromScript(
1157 script,
1158 animationId,
1159 keyframes,
1160 easeEach,
1161 resolvedSelector,
1162 );
1163 if (newScript === script) return EMPTY;
1164 setGsapScript(parsed.document, newScript);
1165 return gsapScriptChange(script, newScript);
1166}
1167
1168function handleSplitIntoPropertyGroups(
1169 parsed: ParsedDocument,

Callers 1

applyGsapKeyframeOpFunction · 0.85

Calls 4

getGsapScriptFunction · 0.85
setGsapScriptFunction · 0.85
gsapScriptChangeFunction · 0.85

Tested by

no test coverage detected