Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug Report], NavMenu, horizontal mode, collapse, true, the mouse moves quickly, causing the menu to be retracted #6520

Closed
zxjava opened this issue Aug 16, 2017 · 5 comments

Comments

@zxjava
Copy link

zxjava commented Aug 16, 2017

Element UI version

1.4.2

OS/Browsers version

chrome 60.0.3112.101 (64 位)

Vue version

2.1.0

Reproduction Link

https://jsfiddle.net/m2s8ejyz/

Steps to reproduce

当菜单为horizontal模式并且collapse为true的时候 ,比如有三级菜单{A1,children:[ {B1},{B2,children:[C1]} ]},当鼠标在弹出的二级菜单上从B2和B1之间快速移动时,如果B2的子菜单C1还未弹出来(子菜单弹出有第一定的延时),且鼠标已经移至B1,则整个菜单就会收起。

What is Expected?

无论鼠标如何移动,只要还在菜单上,菜单都不应该收起。而且子菜单的弹出有略微的延时,最好可以设置延时时间。

What is actually happening?

无论鼠标如何移动,只要还在菜单上,菜单都不应该收起。

@element-bot element-bot changed the title [Bug Report] NavMenu horizontal模式collapse为true 鼠标快速移动导致菜单收起 [Bug Report], NavMenu, horizontal mode, collapse, true, the mouse moves quickly, causing the menu to be retracted Aug 16, 2017
@element-bot
Copy link
Member

Translation of this issue:

Element UI version

1.4.2

OS/Browsers version

Chrome 60.0.3112.101 (64 bits)

Vue version

2.1.0

Reproduction Link

https://jsfiddle.net/api/post/library/pure/

Steps to reproduce

When the menu for the horizontal mode and collapse for true, such as three level menu {A1, children:[{B1}, {B2, children:[C1]}]}, when the mouse in the pop-up menu from the two level between B2 and B1 when moving quickly, if the sub menu B2 C1 not play out the submenu (some time delay, and the mouse has moved to B1), the entire menu will stop.

What is Expected?

No matter how moving the mouse is, the menu should not be put away as long as it is still on the menu. Moreover, the popup of the submenu has a slight delay, and it is better to set the delay time.

What is actually happening?

No matter how moving the mouse is, the menu should not be put away as long as it is still on the menu.

@element-bot
Copy link
Member

Hi, your JSFiddle page is blank because it seems you forgot to click the Save button. Please save your fiddle and then edit this issue with the new link.

@blackcorgi
Copy link

After reading the source code, it is found that there are settimeout(300ms) behavior in handleMouseenter () and handleMouseleave ()

And the problem will recur When the menu for the isCollapse mode , closed

@hanyuhh
Copy link

hanyuhh commented Oct 16, 2017

有什么好的解决方案么,改动源码?

@Leopoldthecoder
Copy link
Contributor

Fixed in #7579

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants