diff options
author | Ulrich-Matthias Schäfer <ulima.ums@googlemail.com> | 2018-05-26 21:17:52 +0200 |
---|---|---|
committer | Ulrich-Matthias Schäfer <ulima.ums@googlemail.com> | 2018-05-26 21:17:52 +0200 |
commit | 91785e4c1921c3f8a0aa2c799b214245bb8755f4 (patch) | |
tree | 655a825c6afc3490b098d613bdeedf87d82df66b /src | |
parent | 7990dc47fda4f3b850c18318775ab108c2aff8f5 (diff) | |
download | svg.js-91785e4c1921c3f8a0aa2c799b214245bb8755f4.tar.gz svg.js-91785e4c1921c3f8a0aa2c799b214245bb8755f4.zip |
fixed `SVG.Text.y()` which didnt work correctly with `SVG.Number` (#778)
Diffstat (limited to 'src')
-rw-r--r-- | src/text.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/text.js b/src/text.js index 20c2c1e..9895a35 100644 --- a/src/text.js +++ b/src/text.js @@ -33,7 +33,7 @@ SVG.Text = SVG.invent({ if (y == null) return typeof oy === 'number' ? oy - o : oy - return this.attr('y', typeof y === 'number' ? y + o : y) + return this.attr('y', typeof y.valueOf() === 'number' ? y + o : y) } // Move center over x-axis , cx: function(x) { |