@@ -112,7 +112,7 @@ const DOMWrap = {
112
112
// with a title of overflow indicator ('...')
113
113
const copy = this . $slots . default [ 0 ] ;
114
114
const { title, ...rest } = getPropsData ( copy ) ; // eslint-disable-line no-unused-vars
115
-
115
+ const events = getEvents ( copy ) ;
116
116
let style = { } ;
117
117
let key = `${ keyPrefix } -overflowed-indicator` ;
118
118
let eventKey = `${ keyPrefix } -overflowed-indicator` ;
@@ -133,11 +133,17 @@ const DOMWrap = {
133
133
134
134
const popupClassName = theme ? `${ prefixCls } -${ theme } ` : '' ;
135
135
const props = { } ;
136
+ const on = { } ;
136
137
menuAllProps . props . forEach ( k => {
137
138
if ( rest [ k ] !== undefined ) {
138
139
props [ k ] = rest [ k ] ;
139
140
}
140
141
} ) ;
142
+ menuAllProps . on . forEach ( k => {
143
+ if ( events [ k ] !== undefined ) {
144
+ on [ k ] = events [ k ] ;
145
+ }
146
+ } ) ;
141
147
const subMenuProps = {
142
148
props : {
143
149
title : overflowedIndicator ,
@@ -149,7 +155,7 @@ const DOMWrap = {
149
155
class : `${ prefixCls } -overflowed-submenu` ,
150
156
key,
151
157
style,
152
- on : getEvents ( copy ) ,
158
+ on,
153
159
} ;
154
160
155
161
return < SubMenu { ...subMenuProps } > { overflowedItems } </ SubMenu > ;
@@ -263,7 +269,10 @@ const DOMWrap = {
263
269
c ,
264
270
// children[index].key will become '.$key' in clone by default,
265
271
// we have to overwrite with the correct key explicitly
266
- { key : getPropsData ( c ) . eventKey , props : { mode : 'vertical-left' } } ,
272
+ {
273
+ key : getPropsData ( c ) . eventKey ,
274
+ props : { mode : 'vertical-left' } ,
275
+ } ,
267
276
) ;
268
277
} ) ;
269
278
0 commit comments