mirror of
https://github.com/zoriya/react-native-svg.git
synced 2026-06-05 16:04:38 +00:00
[android] Fix percentage handling in SVGLength
This commit is contained in:
@@ -35,7 +35,7 @@ class SVGLength {
|
||||
value = 0;
|
||||
} else if (length.codePointAt(percentIndex) == '%') {
|
||||
unit = SVGLengthUnitType.SVG_LENGTHTYPE_PERCENTAGE;
|
||||
value = Double.valueOf(length.substring(0, percentIndex)) / 100;
|
||||
value = Double.valueOf(length.substring(0, percentIndex));
|
||||
} else {
|
||||
int twoLetterUnitIndex = stringLength - 2;
|
||||
if (twoLetterUnitIndex > 0) {
|
||||
|
||||
Reference in New Issue
Block a user