Skip to content
This repository was archived by the owner on Jan 13, 2022. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions src/Navigator.js
Original file line number Diff line number Diff line change
Expand Up @@ -1000,16 +1000,15 @@ var Navigator = createReactClass({

_transitionSceneStyle: function(fromIndex, toIndex, progress, index) {
var viewAtIndex = this._sceneRefs[index];
if (viewAtIndex === null || viewAtIndex === undefined) {
return;
}
if (!viewAtIndex) return;
// Use toIndex animation when we move forwards. Use fromIndex when we move back
var sceneConfigIndex = fromIndex < toIndex ? toIndex : fromIndex;
var sceneConfig = this.state.sceneConfigStack[sceneConfigIndex];
// this happens for overswiping when there is no scene at toIndex
if (!sceneConfig) {
sceneConfig = this.state.sceneConfigStack[sceneConfigIndex - 1];
}
if (!sceneConfig) return;
var styleToUse = {};
var useFn = index < fromIndex || index < toIndex ?
sceneConfig.animationInterpolators.out :
Expand Down