File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -213,6 +213,7 @@ class OutPortal<C extends Component<any>> extends React.PureComponent<OutPortalP
213
213
// If we're switching portal nodes, we need to clean up the current one first.
214
214
if ( this . currentPortalNode && node !== this . currentPortalNode ) {
215
215
this . currentPortalNode . unmount ( this . placeholderNode . current ! ) ;
216
+ this . currentPortalNode . setPortalProps ( { } as ComponentProps < C > ) ;
216
217
this . currentPortalNode = node ;
217
218
}
218
219
@@ -225,6 +226,7 @@ class OutPortal<C extends Component<any>> extends React.PureComponent<OutPortalP
225
226
componentWillUnmount ( ) {
226
227
const node = this . props . node as AnyPortalNode < C > ;
227
228
node . unmount ( this . placeholderNode . current ! ) ;
229
+ node . setPortalProps ( { } as ComponentProps < C > ) ;
228
230
}
229
231
230
232
render ( ) {
You can’t perform that action at this time.
0 commit comments