mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-08-26 16:46:19 +08:00
fix: newTabTitle does not work as expected (#4160)
* fix: cloneDeep tab close #4158
* Revert "fix: cloneDeep tab close #4158"
This reverts commit 8e2f4b39ad
.
* fix: deep clone meta.newTabTitle
This commit is contained in:
@@ -478,7 +478,7 @@ function cloneTab(route: TabDefinition): TabDefinition {
|
||||
if (!route) {
|
||||
return route;
|
||||
}
|
||||
const { matched, ...opt } = route;
|
||||
const { matched, meta, ...opt } = route;
|
||||
return {
|
||||
...opt,
|
||||
matched: (matched
|
||||
@@ -488,6 +488,10 @@ function cloneTab(route: TabDefinition): TabDefinition {
|
||||
path: item.path,
|
||||
}))
|
||||
: undefined) as RouteRecordNormalized[],
|
||||
meta: {
|
||||
...meta,
|
||||
newTabTitle: meta.newTabTitle,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user