Skip to content

Commit

Permalink
Duration cannot be less then 10ms (#21858)
Browse files Browse the repository at this point in the history
Summary:
Related to: #21853

Fixes #21853
Pull Request resolved: #21858

Differential Revision: D13322060

Pulled By: hramos

fbshipit-source-id: 00a8de018fce6507aa131a11ba3e95d57044e683
  • Loading branch information
Baldy Lukasz authored and kelset committed Dec 12, 2018
1 parent 26775d5 commit 472e978
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Libraries/Components/Keyboard/KeyboardAvoidingView.js
Expand Up @@ -99,9 +99,10 @@ class KeyboardAvoidingView extends React.Component<Props, State> {

if (duration && easing) {
LayoutAnimation.configureNext({
duration: duration,
// We have to pass the duration equal to minimal accepted duration defined here: RCTLayoutAnimation.m
duration: duration > 10 ? duration : 10,
update: {
duration: duration,
duration: duration > 10 ? duration : 10,
type: LayoutAnimation.Types[easing] || 'keyboard',
},
});
Expand Down

0 comments on commit 472e978

Please sign in to comment.