getBreakPoint method
Implementation
String? getBreakPoint(Size size) {
var sm = BreakPoint("sm", 550);
var md = BreakPoint("md", 800);
var lg = BreakPoint("lg", 1024);
if(size.width > lg.points){
return "lg";
}
if(size.width > md.points){
return "md";
}
if(size.width > sm.points){
return "sm";
}
return null;
// var deviceType = getDeviceType(size);
// switch (deviceType) {
// case DeviceScreenType.watch:
// return null;
// case DeviceScreenType.tablet:
// return "md";
// case DeviceScreenType.mobile:
// return "sm";
// case DeviceScreenType.desktop:
// return "lg";
// default:
// return null;
// }
}