Created
September 3, 2012 05:05
-
-
Save minhd/3606831 to your computer and use it in GitHub Desktop.
jquery extend slide show/hide
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery.fn.extend({ | |
slideRightShow: function(duration) { | |
return this.each(function() { | |
$(this).show('slide', {direction: 'right'}, duration); | |
}); | |
}, | |
slideLeftHide: function(duration) { | |
return this.each(function() { | |
$(this).hide('slide', {direction: 'left'}, duration); | |
}); | |
}, | |
slideRightHide: function(duration) { | |
return this.each(function() { | |
$(this).hide('slide', {direction: 'right'}, duration); | |
}); | |
}, | |
slideLeftShow: function(duration) { | |
return this.each(function() { | |
$(this).show('slide', {direction: 'left'}, duration); | |
}); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment