screenSizeType property

DeviceScreenSizeType get screenSizeType

Implementation

DeviceScreenSizeType get screenSizeType {
  double width = MediaQuery.of(this).size.width;

  if (width >= ScreenSizeBreakpoints.desktopMinWidth) {
    return DeviceScreenSizeType.desktop;
  }
  if (width >= ScreenSizeBreakpoints.mobileMaxWidth) {
    return DeviceScreenSizeType.tablet;
  }
  return DeviceScreenSizeType.mobile;
}