framer-motion
Version:
An open source and production-ready motion library for React on the web
18 lines (16 loc) • 483 B
text/typescript
import { MotionProps } from "../.."
import { valueScaleCorrection } from "../../render/dom/projection/scale-correction"
import {
isTransformOriginProp,
isTransformProp,
} from "../../render/dom/utils/transform"
export function isForcedMotionValue(
key: string,
{ layout, layoutId }: MotionProps
) {
return (
isTransformProp(key) ||
isTransformOriginProp(key) ||
((layout || layoutId !== undefined) && !!valueScaleCorrection[key])
)
}