mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Cascader): incorrect tabs
This commit is contained in:
parent
a05da0644b
commit
04d6561315
@ -27,7 +27,7 @@ export default createComponent({
|
|||||||
|
|
||||||
watch: {
|
watch: {
|
||||||
options() {
|
options() {
|
||||||
// reset options and tab
|
this.updateTabs();
|
||||||
},
|
},
|
||||||
|
|
||||||
value(value) {
|
value(value) {
|
||||||
@ -92,7 +92,14 @@ export default createComponent({
|
|||||||
return tab;
|
return tab;
|
||||||
});
|
});
|
||||||
|
|
||||||
this.activeTab = selectedOptions.length - 1;
|
if (optionsCursor) {
|
||||||
|
this.tabs.push({
|
||||||
|
options: optionsCursor,
|
||||||
|
selectedOption: null,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
this.activeTab = this.tabs.length - 1;
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user