fromJson static method

ResponsiveRect fromJson(
  1. Map<String, dynamic> json
)

Implementation

static ResponsiveRect fromJson(Map<String, dynamic> json) => ResponsiveRect(
      rectPhone: rectSingleFromJson(json[DeviceType.phone.name]) ??
          const Rect.fromLTWH(0, 0, 150, 150),
      rectTablet: rectSingleFromJson(json[DeviceType.tablet.name]),
      rectLaptop: rectSingleFromJson(
          json[DeviceType.laptop.name] ?? json[DeviceType.desktop.name]),
      rectDesktop: rectSingleFromJson(json[DeviceType.desktop.name]),
    );