MCPcopy Index your code
hub / github.com/react/react / finishedViewTransition

Function finishedViewTransition

packages/react-reconciler/src/ReactFiberWorkLoop.js:3778–3821  ·  view source on GitHub ↗
(lanes: Lanes)

Source from the content-addressed store, hash-verified

3776}
3777
3778function finishedViewTransition(lanes: Lanes): void {
3779 if (enableProfilerTimer && enableComponentPerformanceTrack) {
3780 if ((animatingLanes & lanes) === NoLanes) {
3781 // Was already stopped by some other action or maybe other root.
3782 return;
3783 }
3784 const task = animatingTask;
3785 stopAnimating(lanes);
3786 // If an affected track isn't in the middle of rendering or committing, log from the previous
3787 // finished render until the end of the animation.
3788 if (
3789 isGestureRender(lanes) &&
3790 !isGestureRender(workInProgressRootRenderLanes) &&
3791 !isGestureRender(pendingEffectsLanes)
3792 ) {
3793 setCurrentTrackFromLanes(GestureLane);
3794 logAnimatingPhase(gestureClampTime, now(), task);
3795 }
3796 if (
3797 includesTransitionLane(lanes) &&
3798 !includesTransitionLane(workInProgressRootRenderLanes) &&
3799 !includesTransitionLane(pendingEffectsLanes)
3800 ) {
3801 setCurrentTrackFromLanes(SomeTransitionLane);
3802 logAnimatingPhase(transitionClampTime, now(), task);
3803 }
3804 if (
3805 includesRetryLane(lanes) &&
3806 !includesRetryLane(workInProgressRootRenderLanes) &&
3807 !includesRetryLane(pendingEffectsLanes)
3808 ) {
3809 setCurrentTrackFromLanes(SomeRetryLane);
3810 logAnimatingPhase(retryClampTime, now(), task);
3811 }
3812 if (
3813 includesIdleGroupLanes(lanes) &&
3814 !includesIdleGroupLanes(workInProgressRootRenderLanes) &&
3815 !includesIdleGroupLanes(pendingEffectsLanes)
3816 ) {
3817 setCurrentTrackFromLanes(IdleLane);
3818 logAnimatingPhase(idleClampTime, now(), task);
3819 }
3820 }
3821}
3822
3823function flushAfterMutationEffects(): void {
3824 if (pendingEffectsStatus !== PENDING_AFTER_MUTATION_PHASE) {

Callers

nothing calls this directly

Calls 8

stopAnimatingFunction · 0.90
isGestureRenderFunction · 0.90
setCurrentTrackFromLanesFunction · 0.90
logAnimatingPhaseFunction · 0.90
nowFunction · 0.90
includesTransitionLaneFunction · 0.90
includesRetryLaneFunction · 0.90
includesIdleGroupLanesFunction · 0.90

Tested by

no test coverage detected