Skip to content

Commit

Permalink
fix: tabView title internationalization switchover problem (#4652)
Browse files Browse the repository at this point in the history
当tabView被固定或取消固定后,切换国际化,该tabView的title国际化切换失败
  • Loading branch information
yuguaa authored Oct 16, 2024
1 parent 850a6af commit 7c45aeb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/stores/src/modules/tabbar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,9 @@ export const useTabbarStore = defineStore('core-tabbar', {
(item) => getTabPath(item) === getTabPath(tab),
);
if (index !== -1) {
const oldTab = this.tabs[index];
tab.meta.affixTab = true;
tab.meta.title = oldTab?.meta?.title as string;
// this.addTab(tab);
this.tabs.splice(index, 1, tab);
}
Expand Down Expand Up @@ -411,7 +413,9 @@ export const useTabbarStore = defineStore('core-tabbar', {
);

if (index !== -1) {
const oldTab = this.tabs[index];
tab.meta.affixTab = false;
tab.meta.title = oldTab?.meta?.title as string;
// this.addTab(tab);
this.tabs.splice(index, 1, tab);
}
Expand Down

0 comments on commit 7c45aeb

Please sign in to comment.