File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import EventEmitter from 'events' ;
2- import { EASING } from './easing' ;
2+ import { EASING } from './easing' ;
33
44/**
55 * Base class for creating other animations.
@@ -138,10 +138,9 @@ export default class Animation extends EventEmitter {
138138 *
139139 * @abstract
140140 * @param {Shape } shape Shape instance that need to be animated
141- * @param {Cursor } cursor Cursor instance that you can use for rendering other stuff
142141 * @returns {Promise } Returns Promise that fulfills with shape instance when animation is done
143142 */
144- animate ( shape , cursor ) {
143+ animate ( shape ) {
145144 return Promise . reject ( new Error ( 'You must implement animate() method' ) ) ;
146145 }
147146
@@ -171,7 +170,7 @@ export default class Animation extends EventEmitter {
171170 const start = Date . now ( ) ;
172171 const end = start + duration ;
173172 const tick = resolve => {
174- let currentTime = Date . now ( ) ;
173+ const currentTime = Date . now ( ) ;
175174
176175 if ( currentTime > end ) {
177176 resolve ( shape ) ;
You can’t perform that action at this time.
0 commit comments