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

Function buildIdentityMap

packages/parsers/src/gsapSerialize.ts:465–471  ·  view source on GitHub ↗

Build the identity-endpoint map for a flat tween's properties.

(props: Record<string, number | string>)

Source from the content-addressed store, hash-verified

463
464/** Build the identity-endpoint map for a flat tween's properties. */
465function buildIdentityMap(props: Record<string, number | string>): Record<string, number | string> {
466 const identity: Record<string, number | string> = {};
467 for (const [key, val] of Object.entries(props)) {
468 if (val != null) identity[key] = typeof val === "number" ? cssIdentityValue(key) : val;
469 }
470 return identity;
471}
472
473/**
474 * Resolve the 0% (from) and 100% (to) property maps for a tween being

Callers 1

resolveConversionPropsFunction · 0.85

Calls 2

entriesMethod · 0.80
cssIdentityValueFunction · 0.70

Tested by

no test coverage detected