File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -398,15 +398,15 @@ module.exports = React.createClass({
398398
399399 // Snap to grid if prop has been provided
400400 if ( Array . isArray ( this . props . grid ) ) {
401- var directionX = clientX < parseInt ( this . state . clientX ) ? - 1 : 1 ;
402- var directionY = clientY < parseInt ( this . state . clientY ) ? - 1 : 1 ;
401+ var directionX = clientX < parseInt ( this . state . clientX , 10 ) ? - 1 : 1 ;
402+ var directionY = clientY < parseInt ( this . state . clientY , 10 ) ? - 1 : 1 ;
403403
404- clientX = Math . abs ( clientX - parseInt ( this . state . clientX ) ) >= this . props . grid [ 0 ]
405- ? ( parseInt ( this . state . clientX ) + ( this . props . grid [ 0 ] * directionX ) )
404+ clientX = Math . abs ( clientX - parseInt ( this . state . clientX , 10 ) ) >= this . props . grid [ 0 ]
405+ ? ( parseInt ( this . state . clientX , 10 ) + ( this . props . grid [ 0 ] * directionX ) )
406406 : this . state . clientX ;
407407
408- clientY = Math . abs ( clientY - parseInt ( this . state . clientY ) ) >= this . props . grid [ 1 ]
409- ? ( parseInt ( this . state . clientY ) + ( this . props . grid [ 1 ] * directionY ) )
408+ clientY = Math . abs ( clientY - parseInt ( this . state . clientY , 10 ) ) >= this . props . grid [ 1 ]
409+ ? ( parseInt ( this . state . clientY , 10 ) + ( this . props . grid [ 1 ] * directionY ) )
410410 : this . state . clientY ;
411411 }
412412
You can’t perform that action at this time.
0 commit comments