aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRémi Tétreault <tetreault.remi@gmail.com>2017-05-26 18:51:36 -0400
committerGitHub <noreply@github.com>2017-05-26 18:51:36 -0400
commitdbbcc1669883f284125b4a1facf3120fa534ba8e (patch)
tree733772832a6d7534835d62909401d418775dab00 /src
parentd80d692271345f73c45be0b67d44e3e3c1ecf35c (diff)
parent830e4c70b161fce24524455ef0bbd46a53b04fc8 (diff)
downloadsvg.js-dbbcc1669883f284125b4a1facf3120fa534ba8e.tar.gz
svg.js-dbbcc1669883f284125b4a1facf3120fa534ba8e.zip
Merge pull request #676 from jcorentin/fix-height-width-animation
Make width() and height() setters animatable
Diffstat (limited to 'src')
-rw-r--r--src/fx.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/fx.js b/src/fx.js
index 3d8d6fe..36535b1 100644
--- a/src/fx.js
+++ b/src/fx.js
@@ -862,6 +862,14 @@ SVG.extend(SVG.FX, {
return this
}
+ // Add animatable width
+, width: function(width) {
+ return this.add('width', new SVG.Number(width))
+ }
+ // Add animatable height
+, height: function(height) {
+ return this.add('height', new SVG.Number(height))
+ }
// Add animatable plot
, plot: function(a, b, c, d) {
// Lines can be plotted with 4 arguments