scaleFromJSON function
Implementation
ScaleDetails? scaleFromJSON(dynamic json, [ScaleDetails? defaultValue]) {
if (json == null) {
return defaultValue;
}
if (json is int || json is double) {
return ScaleDetails(
scale: parseDouble(json),
scaleX: null,
scaleY: null,
alignment: Alignment.center);
}
return ScaleDetails.fromJson(json);
}