parseRectangleFromList function
Parses list
as a Rectangle.
Implementation
Rectangle<num>? parseRectangleFromList(List list) {
if (list.length < 4) return null;
list = list.map((e) => parseNum(e)).whereType<num>().toList();
if (list.length < 4) return null;
return Rectangle(list[0], list[1], list[2], list[3]);
}