is a jQuery plugin allowing you to easily specify direction, fade-in, fade-out, and a host of other options to a grouping of elements. All you have to do is import it, specify the container to which the group of items resides, and poof, you're off and away.
diagonalFade is great for inventory or anything with a large amount of items ordered in a grid. diagonalFade has been tested in all modern browser's with jQuery 1.3.2 — if you'd like to share any of your findings please don't hesitate to contribute on GitHub!
Don't be shy—view source!
$("#container").diagonalFade({
time: 100,
fadeDirection_x: 'left-right', // "left-right" || "right-left"
fadeDirection_y: 'top-bottom', // "top-bottom" || "bottom-top"
fade: 'out', // "in" || "out"
complete: null // callback function
} });
// or $("#container").diagonalFade(); — these are all optional params.
<img>'s:
<div>'s:
代码整理:时代Java(NowJava.com)
转载请注明出处,此代码仅供学习交流,请勿用于商业用途。