$(function() { //PC绔紶鏍囨诞鍔ㄥ睍绀哄瓙瀵艰埅 $(".nav ul li").hover( function() { $(this).children('').next().stop(true, true).delay(0).slideDown(0); }, function() { $(this).children('').next().stop(true, true).delay(0).slideUp(0); } ); //鐐瑰嚮閫愭笎灞曞紑绉诲姩绔鑸 $(".a_js").click( function() { $(".a_txt").stop(true, false).delay(0).animate({ width: "100%", height: "100%" }, 0); $(".a_txt").find(".div1").stop(true, false).delay(0).animate({ opacity: "0.9" }, 500); $(".a_txt").find(".div2").stop(true, false).delay(0).animate({ opacity: "1" }, 500); $(".a_txt").find(".div3").stop(true, false).delay(0).animate({ right: "0" }, 500); } ) //鐐瑰嚮鍏抽棴锛岄€愭笎闅愯棌 $(".a_closed").click( function() { $(".a_txt").stop(true, false).delay(500).animate({ width: "0", height: "0" }, 0); $(".a_txt").find(".div1").stop(true, false).delay(0).animate({ opacity: "0" }, 500); $(".a_txt").find(".div2").stop(true, false).delay(0).animate({ opacity: "0" }, 500); $(".a_txt").find(".div3").stop(true, false).delay(0).animate({ right: "-80%" }, 500); } ) //鐐瑰嚮椤剁骇鑿滃崟灞曞紑鍏抽棴瀛愬鑸 $('.div3 ul li').click(function() { $('.a_txt2:visible').slideUp().prev().removeClass('a_js2_on'); var subnav = $(this).find('.a_txt2'); console.log(subnav.is(':hidden')) if(subnav.is(':hidden')) { subnav.slideDown().prev().addClass('a_js2_on'); } else { subnav.slideUp().prev().removeClass('a_js2_on'); }; }) });