jQuery: FadeOut then SlideUp
If an item is being deleted then I would like to fade it out and slide the other elements up to fill the empty space. Now, when I use fadeOut() the item doesn't have a height at the end which results in the other items jumping up (instead of sliding up nicely). How can I slideUp() and element right after fadeOut() ? jQuery.fn.fadeThenSlideToggle = function(speed, easing, callback) { if (this.is(":hidden")) { return this.slideDown(speed, easing).fadeTo(speed, 1, easing, callback); } else { return this.fadeTo(speed, 0, easing).slideUp(speed, easing, callback); } }; I tested it on JQuery 1.3.2,