mirror of
https://github.com/zoriya/react-native-svg.git
synced 2025-12-20 05:55:10 +00:00
fix ellipse draw bug and fix shape props context
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
export default function({viewbox, width, height, preserveAspectRatio, x: dx, y: dy, dScale, dScaleX, dScaleY, shouldTransform}) {
|
||||
export default function({viewbox, width, height, preserveAspectRatio, x: dx, y: dy, dScale, dScaleX, dScaleY}) {
|
||||
if (!viewbox || !width || !height) {
|
||||
return false;
|
||||
}
|
||||
@@ -47,18 +47,18 @@ export default function({viewbox, width, height, preserveAspectRatio, x: dx, y:
|
||||
y = -vy * sy;
|
||||
}
|
||||
|
||||
if (shouldTransform) {
|
||||
x += (+dx || 0);
|
||||
y += (+dy || 0);
|
||||
//if (shouldTransform) {
|
||||
x += (+dx || 0);
|
||||
y += (+dy || 0);
|
||||
|
||||
if (dScale) {
|
||||
scaleX *= (+dScale || 1);
|
||||
scaleY *= (+dScale || 1);
|
||||
} else {
|
||||
scaleX *= (+dScaleX || 1);
|
||||
scaleY *= (+dScaleY || 1);
|
||||
}
|
||||
if (dScale) {
|
||||
scaleX *= (+dScale || 1);
|
||||
scaleY *= (+dScale || 1);
|
||||
} else {
|
||||
scaleX *= (+dScaleX || 1);
|
||||
scaleY *= (+dScaleY || 1);
|
||||
}
|
||||
//}
|
||||
|
||||
return {
|
||||
x,
|
||||
|
||||
Reference in New Issue
Block a user