forked from p96170835/amis
combo修改tab的activeKey为有效值
This commit is contained in:
parent
0782266701
commit
af2de7be16
|
@ -153,7 +153,7 @@ export default class ComboControl extends React.Component<ComboProps> {
|
|||
});
|
||||
|
||||
if (store.activeKey >= values.length) {
|
||||
store.setActiveKey(values.length - 1);
|
||||
store.setActiveKey(Math.max(0, values.length - 1));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue