mirror of
https://github.com/jquery/jquery.git
synced 2026-04-20 03:01:22 -04:00
Added in some more bug fixes - and added the slideToggle method.
This commit is contained in:
@@ -141,6 +141,13 @@ jQuery.fn.extend({
|
||||
slideUp: function(speed,callback){
|
||||
return this.animate({height: "hide"}, speed, callback);
|
||||
},
|
||||
|
||||
slideToggle: function(speed,callback){
|
||||
return this.each(function(){
|
||||
var state = $(this).is(":hidden") ? "show" : "hide";
|
||||
$(this).animate({height: state}, speed, callback);
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Fade in all matched elements by adjusting their opacity.
|
||||
|
||||
Reference in New Issue
Block a user