How to order effects in jquery sequentially -
i have snippet of code:
$("a#list-mode").click(function() { $("#list-fix-pos").removeclass('col-lg-3', 1250, "easeinoutquart" ); $(this).hide("fade", 1250, true); $("a#map-mode").show("fade", 1250, true); });
how can order effects take place sequentially? @ moment, effects transition @ once.
thanks
jquery's .hide
, .show
functions allow specify function performed upon completion. syntax is
.hide( duration [, easing ] [, complete ] )
in case, that'd be
$("a#list-mode").click(function() { $("#list-fix-pos").hide(1250, 'easeinoutquart', function() { $(this).hide(1250, 'fade', function() { $("a#map-mode").show(1250, 'fade'); }); }); $("#list-fix-pos").removeclass('col-lg-3'); });
Comments
Post a Comment