diff options
author | Ulrich-Matthias Schäfer <ulima.ums@googlemail.com> | 2019-11-01 13:37:24 +0100 |
---|---|---|
committer | Ulrich-Matthias Schäfer <ulima.ums@googlemail.com> | 2019-11-01 13:37:24 +0100 |
commit | 2827a27531c661726d204d6da9d17c6f72d8e404 (patch) | |
tree | a4180b1f462685cce0c314be16511a630d222b05 /src/utils/utils.js | |
parent | 0748382e9859c31253d93b0c258487da362bcade (diff) | |
download | svg.js-2827a27531c661726d204d6da9d17c6f72d8e404.tar.gz svg.js-2827a27531c661726d204d6da9d17c6f72d8e404.zip |
Updated dependencies to newest version, new linter fixed stuff
Diffstat (limited to 'src/utils/utils.js')
-rw-r--r-- | src/utils/utils.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/utils/utils.js b/src/utils/utils.js index c2046a9..5d8706e 100644 --- a/src/utils/utils.js +++ b/src/utils/utils.js @@ -75,7 +75,7 @@ export function proportionalSize (element, width, height, box) { export function getOrigin (o, element) { // Allow origin or around as the names - let origin = o.origin // o.around == null ? o.origin : o.around + const origin = o.origin // o.around == null ? o.origin : o.around let ox, oy // Allow the user to pass a string to rotate around a given point @@ -85,10 +85,10 @@ export function getOrigin (o, element) { const { height, width, x, y } = element.bbox() // Calculate the transformed x and y coordinates - let bx = string.includes('left') ? x + const bx = string.includes('left') ? x : string.includes('right') ? x + width : x + width / 2 - let by = string.includes('top') ? y + const by = string.includes('top') ? y : string.includes('bottom') ? y + height : y + height / 2 |