perf: motion

This commit is contained in:
tangjinzhou 2022-03-04 11:50:11 +08:00
parent 207c944e21
commit 4c786dd7a7
2 changed files with 3 additions and 3 deletions

View File

@ -29,7 +29,7 @@ export const getTransitionProps = (transitionName: string, opt: TransitionProps
enterActiveClass: `${transitionName}-enter ${transitionName}-enter-prepare`,
enterToClass: `${transitionName}-enter ${transitionName}-enter-active`,
leaveFromClass: ` ${transitionName}-leave`,
leaveActiveClass: `${transitionName}-leave ${transitionName}-leave-active`,
leaveActiveClass: `${transitionName}-leave`,
leaveToClass: `${transitionName}-leave ${transitionName}-leave-active`,
...opt,
}

View File

@ -115,9 +115,9 @@ export default defineComponent({
};
watch(
[toRef(motion.value, 'name'), status],
[motion, status],
() => {
if (!motion.value.name && status.value === 'motion') {
if (!motion.value && status.value === 'motion') {
goNextStatus();
}
},