transformOrigin
Determines the transform origin point based on two elements' boxes. The method is primarily used in zoom/transfer effects.
Parameters
firstElementHTMLElement
The first element.
secondElementHTMLElement
The second element.
ReturnsObject
An object with x and y fields that represent the transform origin point.
Example
<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>
<script>
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(kendo.effects.transformOrigin(kendo.effects.box("#bar"), kendo.effects.box("#foo"))); // x: 101, y: 101
</script>