From e8124f85fc73da9e6a3f047bb5ea4eedc9a67730 Mon Sep 17 00:00:00 2001 From: efkan Date: Thu, 10 Mar 2016 15:56:12 +0200 Subject: [PATCH 1/2] Improving the ripple animation Works more short and more fast. So close to the native.. --- lib/polyfill/Ripple.js | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/lib/polyfill/Ripple.js b/lib/polyfill/Ripple.js index 9645b63..5f9685d 100644 --- a/lib/polyfill/Ripple.js +++ b/lib/polyfill/Ripple.js @@ -39,7 +39,8 @@ export default class Ripple extends Component { = 1500 ? 500 : duration + duration: duration < 300 || duration >= 600 ? 300 : duration }).start(); Animated.timing(this.state.fadeValue, { - toValue: .2, - duration: 200 + toValue: .8, + duration: 100 }).start(); }); }; @@ -121,13 +122,13 @@ export default class Ripple extends Component { }); Animated.timing(this.state.scaleValue, { - toValue: 0.001, - duration: 100 + toValue: 0, + duration: 1 }).start(); Animated.timing(this.state.fadeValue, { - toValue: 0.001, - duration: 100, + toValue: 0, + duration: 1, }).start(); }; @@ -157,4 +158,4 @@ const styles = { ripple: { position: 'absolute' } -}; \ No newline at end of file +}; From 7356d20c0dc648c3bb5c0b7169782011b464405e Mon Sep 17 00:00:00 2001 From: efkan Date: Fri, 18 Mar 2016 11:01:47 +0200 Subject: [PATCH 2/2] Update Ripple.js Correcting the indentations. --- lib/polyfill/Ripple.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/polyfill/Ripple.js b/lib/polyfill/Ripple.js index 5f9685d..585847b 100644 --- a/lib/polyfill/Ripple.js +++ b/lib/polyfill/Ripple.js @@ -39,8 +39,8 @@ export default class Ripple extends Component {