fromJson static method

Rect fromJson(
  1. Map json
)

Returns an instance of Rect from a given json.

Implementation

static Rect fromJson(Map<dynamic, dynamic> json) {
  return Rect.fromLTRB(
    json['left']?.toDouble() ?? 0,
    json['top']?.toDouble() ?? 0,
    json['right']?.toDouble() ?? 0,
    json['bottom']?.toDouble() ?? 0,
  );
}