@@ -9,6 +9,7 @@ import { hasProp, getEvents } from '../_util/props-util';
99import BaseMixin from '../_util/BaseMixin' ;
1010import { cloneElement } from '../_util/vnode' ;
1111import { defineComponent } from 'vue' ;
12+ import isEqual from 'lodash-es/isEqual' ;
1213
1314const BUILT_IN_PLACEMENTS = {
1415 bottomLeft : {
@@ -134,7 +135,7 @@ export default defineComponent({
134135 const { options = [ ] , sActiveValue = [ ] } = this ;
135136 const result = arrayTreeFilter (
136137 options ,
137- ( o , level ) => o [ this . getFieldName ( 'value' ) ] === sActiveValue [ level ] ,
138+ ( o , level ) => isEqual ( o [ this . getFieldName ( 'value' ) ] , sActiveValue [ level ] ) ,
138139 { childrenKeyName : this . getFieldName ( 'children' ) } ,
139140 ) ;
140141 if ( result [ result . length - 2 ] ) {
@@ -145,7 +146,7 @@ export default defineComponent({
145146 getActiveOptions ( activeValue ) {
146147 return arrayTreeFilter (
147148 this . options || [ ] ,
148- ( o , level ) => o [ this . getFieldName ( 'value' ) ] === activeValue [ level ] ,
149+ ( o , level ) => isEqual ( o [ this . getFieldName ( 'value' ) ] , activeValue [ level ] ) ,
149150 { childrenKeyName : this . getFieldName ( 'children' ) } ,
150151 ) ;
151152 } ,
@@ -244,7 +245,7 @@ export default defineComponent({
244245 const currentOptions = this . getCurrentLevelOptions ( ) ;
245246 const currentIndex = currentOptions
246247 . map ( o => o [ this . getFieldName ( 'value' ) ] )
247- . indexOf ( activeValue [ currentLevel ] ) ;
248+ . findIndex ( val => isEqual ( activeValue [ currentLevel ] , val ) ) ;
248249 if (
249250 e . keyCode !== KeyCode . DOWN &&
250251 e . keyCode !== KeyCode . UP &&
0 commit comments