Time for action – animating an element's skew
Next we'll add the function that will skew elements to the left. The function will need to be applied to two elements, the flat, or non-skewed element, as well as the one before it (to the right in this case). The function to animate the skew from right to left is as follows:
function skewRTL() { var flat = flow.find(".flat").css("zIndex", order + 1), preFlat = flat.next(), flatMatrix = matrix.slice(0), preMatrix = matrix.slice(0), flatDims = 200, preDims = 170, skew = function() { if (preFlat.length) { if (flatMatrix[3] <= 30 * oneRad && flatMatrix[5] <= 10 * oneRad) { var flatTranslateX = parseInt(flatMatrix[9].split("p")[0], 10), flatTranslateY = parseInt(flatMatrix[10].split("p")[0], 10), preTranslateX ...
Get jQuery 1.4 Animation Techniques Beginner's Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.