File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -170,9 +170,9 @@ export default class ReactCSSTransitionReplace extends React.Component {
170
170
performLeave = ( key ) => {
171
171
this . transitioningKeys [ key ] = true
172
172
this . childRefs [ key ] . componentWillLeave ( this . handleDoneLeaving . bind ( this , key ) )
173
- if ( ! this . state . currentChild ) {
174
- // The enter transition dominates, but if there is no
175
- // entering component the height is set to zero.
173
+ if ( ! this . state . currentChild || ! findDOMNode ( this . childRefs [ this . state . currentKey ] ) ) {
174
+ // The enter transition dominates, but if there is no entering
175
+ // component or it renders null the height is set to zero.
176
176
this . enqueueHeightTransition ( )
177
177
}
178
178
}
@@ -184,7 +184,7 @@ export default class ReactCSSTransitionReplace extends React.Component {
184
184
delete nextState . prevChildren [ key ]
185
185
delete this . childRefs [ key ]
186
186
187
- if ( ! this . state . currentChild ) {
187
+ if ( ! this . state . currentChild || ! findDOMNode ( this . childRefs [ this . state . currentKey ] ) ) {
188
188
nextState . height = null
189
189
}
190
190
You can’t perform that action at this time.
0 commit comments