gpt4 book ai didi

jquery - jQuery 下拉菜单上的快速鼠标移动

转载 作者:行者123 更新时间:2023-12-01 07:26:40 25 4
gpt4 key购买 nike

我有一个简单的下拉项目

$('.item').mouseover(function(){
$(this).children().slideDown('slow');
});
$('.item').mouseleave(function(){
$(this).children().slideUp("slow");
});

我的问题是,如果我们将鼠标快速移入/移出该项目多次,它将通过继续打开和关闭 <div> 来执行所有进程。 .

最佳答案

尝试hoverIntent ,它专门解决了这个问题。

关于jquery - jQuery 下拉菜单上的快速鼠标移动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9113096/

25 4 0