Skip to content

Commit 0c60d39

Browse files
PanJiaChenlzq4047
authored andcommitted
Menu: fixed submenu hidden bug after adding popper-append-to-body (ElemeFE#15391)
1 parent ae1e376 commit 0c60d39

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/menu/src/submenu.vue

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,9 @@
208208
this.dispatch('ElSubmenu', 'mouse-leave-child');
209209
clearTimeout(this.timeout);
210210
this.timeout = setTimeout(() => {
211+
if (this.appendToBody) {
212+
this.rootMenu.openedMenus = [];
213+
}
211214
!this.mouseInChild && this.rootMenu.closeMenu(this.index);
212215
}, this.hideTimeout);
213216
},

0 commit comments

Comments
 (0)