react-scroll
Advanced tools
Comparing version 1.0.8 to 1.0.9
@@ -0,0 +0,0 @@ var events = ['mousedown', 'mousewheel', 'touchmove', 'keydown'] |
@@ -24,14 +24,3 @@ "use strict"; | ||
}, | ||
scrollTo : function(to) { | ||
if (this.props.delay) { | ||
var _self = this; | ||
clearTimeout(this.timeout); | ||
this.timeout = setTimeout(function() { | ||
scroller.scrollTo(to, _self.props.smooth, _self.props.duration, _self.props.offset); | ||
}, _self.props.delay) | ||
} else { | ||
scroller.scrollTo(to, this.props.smooth, this.props.duration, this.props.offset); | ||
} | ||
}, | ||
getDefaultProps: function() { | ||
@@ -44,4 +33,4 @@ return {offset: 0}; | ||
var props = this.props | ||
clearTimeout(this.timeout); | ||
this.timeout = setTimeout(function() { | ||
window.clearTimeout(this.timeout); | ||
this.timeout = window.setTimeout(function() { | ||
scroller.scrollTo(to, props.smooth, props.duration, props.offset); | ||
@@ -48,0 +37,0 @@ }, props.delay); |
@@ -0,0 +0,0 @@ module.exports = { |
{ | ||
"name": "react-scroll", | ||
"version": "1.0.8", | ||
"version": "1.0.9", | ||
"description": "A scroll component for React.js", | ||
@@ -5,0 +5,0 @@ "main": "lib", |
32767
777