File tree Expand file tree Collapse file tree 1 file changed +10
-9
lines changed
app/design/adminhtml/Magento/backend/web/js Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -267,17 +267,18 @@ define('globalNavigation', [
267
267
if ( subMenu . length ) {
268
268
e . preventDefault ( ) ;
269
269
}
270
-
271
- menuItem . addClass ( '_show' )
272
- . siblings ( menuItemSelector )
273
- . removeClass ( '_show' ) ;
274
-
275
- subMenu . attr ( 'aria-expanded' , 'true' ) ;
276
-
277
270
closeBtn . on ( 'click' , close ) ;
278
271
279
- this . overlay . show ( 0 ) . on ( 'click' , close ) ;
280
- this . menuLinks . last ( ) . off ( 'blur' ) ;
272
+ if ( $ ( menuItem ) . hasClass ( '_show' ) ) {
273
+ closeBtn . trigger ( 'click' ) ;
274
+ } else {
275
+ menuItem . addClass ( '_show' )
276
+ . siblings ( menuItemSelector )
277
+ . removeClass ( '_show' ) ;
278
+ subMenu . attr ( 'aria-expanded' , 'true' ) ;
279
+ this . overlay . show ( 0 ) . on ( 'click' , close ) ;
280
+ this . menuLinks . last ( ) . off ( 'blur' ) ;
281
+ }
281
282
} ,
282
283
283
284
/**
You can’t perform that action at this time.
0 commit comments