mirror of
https://github.com/ElemeFE/element.git
synced 2025-12-16 11:44:01 +08:00
Tabs: add activeName and oldActiveName parameters to before-leave hook (#11713)
* Tabs: add activeName and oldActiveName parameters to before-leave hook * Tabs: fix docs
This commit is contained in:
@@ -74,7 +74,7 @@
|
||||
this.$emit('input', value);
|
||||
};
|
||||
if (this.currentName !== value && this.beforeLeave) {
|
||||
const before = this.beforeLeave();
|
||||
const before = this.beforeLeave(value, this.currentName);
|
||||
if (before && before.then) {
|
||||
before.then(() => {
|
||||
changeCurrentName();
|
||||
|
||||
Reference in New Issue
Block a user