mirror of
https://github.com/Tencent/tdesign-vue-next-starter.git
synced 2024-11-10 13:18:40 +08:00
fix: 修复侧边栏开合时图表没有刷新 (#253)
This commit is contained in:
parent
11f0a1259d
commit
75d3e00d7e
|
@ -130,6 +130,7 @@ onUnmounted(() => {
|
|||
onDeactivated(() => {
|
||||
storeModeWatch();
|
||||
storeBrandThemeWatch();
|
||||
storeSidebarCompactWatch();
|
||||
});
|
||||
|
||||
const currentMonth = ref(getThisMonth());
|
||||
|
@ -141,6 +142,21 @@ const storeBrandThemeWatch = watch(
|
|||
},
|
||||
);
|
||||
|
||||
const storeSidebarCompactWatch = watch(
|
||||
() => store.isSidebarCompact,
|
||||
() => {
|
||||
if (store.isSidebarCompact) {
|
||||
nextTick(() => {
|
||||
updateContainer();
|
||||
});
|
||||
} else {
|
||||
setTimeout(() => {
|
||||
updateContainer();
|
||||
}, 180);
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
const storeModeWatch = watch(
|
||||
() => store.mode,
|
||||
() => {
|
||||
|
|
Loading…
Reference in New Issue
Block a user