Permalink
Browse files

fix: attrs should be deep clone. Closed #288.

  • Loading branch information...
simaQ committed Sep 3, 2018
1 parent fa10b9f commit 2e4a90b9d16224d217a8f1b6c935c4847e9c5599
Showing with 2 additions and 6 deletions.
  1. +1 −1 src/animation/detail.js
  2. +1 −1 src/animation/group.js
  3. +0 −4 test/bug/issue-302-spec.js
@@ -13,7 +13,7 @@ const Chart = require('../chart/chart');

let timeline;
Element.prototype.animate = function() {
const attrs = this.get('attrs');
const attrs = Util.mix({}, this.get('attrs'));
return new Animator(this, attrs, timeline);
};

@@ -10,7 +10,7 @@ const Animator = require('../graphic/animate/animator');

let timeline;
Shape.prototype.animate = function() {
const attrs = this.get('attrs');
const attrs = Util.mix({}, this.get('attrs'));
return new Animator(this, attrs, timeline);
};

@@ -9,10 +9,6 @@ canvas.height = 260;
canvas.id = 'issue302';
document.body.appendChild(canvas);

// function snapEqual(a, b) {
// return Math.abs(a - b) < 0.01;
// }

describe('issue 302', () => {
it('Issue 302', () => {
const data = [

0 comments on commit 2e4a90b

Please sign in to comment.