Determines the transform origin point based on two elements' boxes. The method is primarily used in zoom/transfer effects.


firstElementHTMLElementThe first element.
secondElementHTMLElementThe second element.

ReturnsObject An object with x and y fields that represent the transform origin point.


<div id="foo" style="position: absolute; top:10px; left: 10px; height: 200px; width: 200px; border: 1px solid red;">foo</div>
<div id="bar" style="position: absolute; top:60px; left: 60px; height: 100px; width: 100px; border: 1px solid blue;">bar</div>
    console.log(kendo.effects.transformOrigin("#bar"),"#foo"))); // x: 101, y: 101
In this article
Not finding the help you need? Improve this article