File tree 1 file changed +2
-3
lines changed
packages/motion/src/state
1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -106,7 +106,7 @@ function resolveStateAnimation(
106
106
// If current node is a variant node, merge the control node's variant
107
107
if ( this . visualElement . isVariantNode ) {
108
108
const controlVariant = resolveVariant ( this . context [ name ] , this . options . variants , this . options . custom )
109
- resolvedVariant = controlVariant ? Object . assign ( controlVariant || { } , variant ) : variant
109
+ resolvedVariant = controlVariant ? Object . assign ( controlVariant || { } , resolvedVariant ) : variant
110
110
}
111
111
if ( ! resolvedVariant )
112
112
return
@@ -186,7 +186,7 @@ function setupChildAnimations(
186
186
187
187
return {
188
188
getChildAnimations : ( ) => Promise . all ( childAnimations . map ( ( animation ) => {
189
- return typeof animation === 'function' ? animation ( ) : animation
189
+ return animation ?. ( )
190
190
} ) ) ,
191
191
childAnimations,
192
192
}
@@ -228,7 +228,6 @@ function executeAnimations(
228
228
} )
229
229
. catch ( noop )
230
230
}
231
-
232
231
// 获取动画Promise
233
232
const getAnimationPromise = ( ) => {
234
233
const animationPromise = transition ?. when
You can’t perform that action at this time.
0 commit comments