Skip to content

Commit

Permalink
fix: 修复!removeOnLeave 因为没有 leavedCLassName 而走到最后的 motionChildren = nu…
Browse files Browse the repository at this point in the history
…ll 分支
  • Loading branch information
heiyu4585 committed Jan 9, 2023
1 parent 4143c57 commit 82d9538
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/CSSMotion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ export function genCSSMotion(
{ ...mergedProps, className: leavedClassName },
setNodeRef,
);
} else if (forceRender) {
} else if ( forceRender || (!removeOnLeave && !leavedClassName)) {
motionChildren = children(
{ ...mergedProps, style: { display: 'none' } },
setNodeRef,
Expand Down

0 comments on commit 82d9538

Please sign in to comment.