2013-03-01 51 views

回答

0

刪除此行:

$('.text').fadeOut(100); 

工作對我來說你的榜樣。

+0

然後,當您將鼠標從包含div移開時,文本永遠不會消失。 – GordonsBeard 2013-03-01 00:10:51

+0

不幸的是,我需要保持fadeOut – 2013-03-01 00:12:27

3
$("#menu, #arrow").mouseenter(function() { 
    $('#arrow').stop(true, false).fadeOut("fast"); 
    $("body").children(':not(#menu)').children(':not(#arrow)').css("-webkit-filter", "blur(2px)"); 
    $("#menu").stop().animate({ 
     width: "300px" 
    }, 300, function() { 
     $('.text').fadeIn(200); 
    }); 
}) 
$("#menu").mouseleave(function() { 
    $("#menu").stop().animate({ 
     width: "5px" 
    }, 300, function() { 
     $('#arrow').stop(true, false).fadeIn("slow"); 
    }); 
    $("body").children(':not(#menu)').css("-webkit-filter", "none"); 
    $('.text').fadeOut(100); 
}); 

您的選擇器很奇怪。所以懸停在射擊菜單和箭頭。試試這個:http://jsfiddle.net/ZcbUW/2/