diff options
author | wout <wout@impinc.co.uk> | 2013-01-10 13:18:21 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2013-01-10 13:18:21 +0100 |
commit | 312084aeb01d2b6cdef6b9743aee65973c6f9526 (patch) | |
tree | 8049c60dd93423740fa72fd73486b96602d94180 /dist/svg.js | |
parent | fac8f88f9f88499abe7a8197fec8c48a3457fdf0 (diff) | |
download | svg.js-312084aeb01d2b6cdef6b9743aee65973c6f9526.tar.gz svg.js-312084aeb01d2b6cdef6b9743aee65973c6f9526.zip |
Bug fix in clone() method
Diffstat (limited to 'dist/svg.js')
-rw-r--r-- | dist/svg.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/dist/svg.js b/dist/svg.js index 87d25d6..dff2603 100644 --- a/dist/svg.js +++ b/dist/svg.js @@ -1,4 +1,4 @@ -/* svg.js v0.1-80-g6d40c80 - svg container element fx event group arrange defs mask pattern gradient doc shape wrap rect ellipse poly path image text nested sugar - svgjs.com/license */ +/* svg.js v0.1-82-gfac8f88 - svg container element fx event group arrange defs mask pattern gradient doc shape wrap rect ellipse poly path image text nested sugar - svgjs.com/license */ (function() { this.svg = function(element) { @@ -219,6 +219,7 @@ if (this instanceof SVG.Wrap) { /* build new wrapped shape */ clone = this.parent[this.child.node.nodeName](); + clone.attrs = this.attrs; /* copy child attributes and transformations */ clone.child.trans = this.child.trans; @@ -239,13 +240,15 @@ name == 'g' ? this.parent.group() : this.parent[name](); + + clone.attr(this.attrs); } /* copy transformations */ clone.trans = this.trans; /* apply attributes and translations */ - return clone.attr(this.attrs).transform({}); + return clone.transform({}); }, // Remove element remove: function() { |