Fabric: Fixed error in parsing translateX/translateY prop

Summary: Quite trivial.

Reviewed By: mdvacca

Differential Revision: D8473513

fbshipit-source-id: 5d20244cbaae5ea69c79379e9894adb05cef2eb5
This commit is contained in:
Valentin Shergin 2018-06-17 21:35:55 -07:00 committed by Facebook Github Bot
parent 3b20a16703
commit dca2067b71
1 changed files with 2 additions and 2 deletions

View File

@ -262,9 +262,9 @@ inline void fromDynamic(const folly::dynamic &value, Transform &result) {
} else if (operation == "translate") {
transformMatrix = transformMatrix * Transform::Translate(parameters[0].asDouble(), parameters[1].asDouble(), 0);
} else if (operation == "translateX") {
transformMatrix = transformMatrix * Transform::Translate(parameters[0].asDouble(), 0, 0);
transformMatrix = transformMatrix * Transform::Translate(parameters.asDouble(), 0, 0);
} else if (operation == "translateY") {
transformMatrix = transformMatrix * Transform::Translate(0, parameters[0].asDouble(), 0);
transformMatrix = transformMatrix * Transform::Translate(0, parameters.asDouble(), 0);
} else if (operation == "skewX") {
transformMatrix = transformMatrix * Transform::Skew(parameters.asDouble(), 0);
} else if (operation == "skewY") {