File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ <h4>Example Details</h4>
3535
3636 var AnimateDemo = React . createClass ( {
3737 getInitialState : function ( ) {
38- return { start : 0 } ;
38+ return { current : 0 } ;
3939 } ,
4040
4141 componentDidMount : function ( ) {
@@ -47,14 +47,14 @@ <h4>Example Details</h4>
4747 } ,
4848
4949 tick : function ( ) {
50- this . setState ( { start : this . state . start + 1 } ) ;
50+ this . setState ( { current : this . state . current + 1 } ) ;
5151 } ,
5252
5353 render : function ( ) {
5454 var children = [ ] ;
5555 var pos = 0 ;
5656 var colors = [ 'red' , 'gray' , 'blue' ] ;
57- for ( var i = this . state . start ; i < this . state . start + 3 ; i ++ ) {
57+ for ( var i = this . state . current ; i < this . state . current + 3 ; i ++ ) {
5858 var style = {
5959 left : pos * 128 ,
6060 background : colors [ i % 3 ]
You can’t perform that action at this time.
0 commit comments