Skip to content
Merged
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
NoTransition scene config causes blank scenes
The NoTransition scene config produces an interpolator function with a
divide by zero, which can cause scenes to have opacity=NaN when
directionAdjustedProgress is set to 1.

This bad value is interpreted on Simulator as opacity=1 (bug does not
appear) but on my device it shows up as opacity=0 (scene shows briefly and
then disappears).

The 'constant' type seems more appropriate here.
  • Loading branch information
keeth committed Mar 3, 2016
commit a3ccd7b698090d074e9132dbe246562e84b60279
11 changes: 3 additions & 8 deletions Animations.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,8 @@ import buildStyleInterpolator from 'react-native/Libraries/Utilities/buildStyleI

var NoTransition = {
opacity: {
from: 1,
to: 1,
min: 1,
max: 1,
type: 'linear',
extrapolate: false,
round: 100,
value: 1.0,
type: 'constant',
},
};

Expand Down Expand Up @@ -145,4 +140,4 @@ const Animations = {
}
}

export default Animations;
export default Animations;