fix: 修复图表添加动画时被缩放到异常状态的问题

This commit is contained in:
pipipi-pikachu 2023-10-28 17:04:47 +08:00
parent fc5a3024a6
commit 6a95f8280c

View File

@ -283,7 +283,9 @@ const updateElementAnimation = (type: AnimationType, effect: string) => {
const animationItem = currentSlideAnimations.value.find(item => item.elId === handleElementId.value)
const duration = animationItem?.duration || ANIMATION_DEFAULT_DURATION
runAnimation(handleElementId.value, effect, duration)
setTimeout(() => {
runAnimation(handleElementId.value, effect, duration)
}, 0)
}
const handleAnimationId = ref('')
@ -307,7 +309,9 @@ const addAnimation = (type: AnimationType, effect: string) => {
animationPoolVisible.value = false
addHistorySnapshot()
runAnimation(handleElementId.value, effect, ANIMATION_DEFAULT_DURATION)
setTimeout(() => {
runAnimation(handleElementId.value, effect, ANIMATION_DEFAULT_DURATION)
}, 0)
}
// 600ms