search logic added to desktop tenders

This commit is contained in:
amirrezaghabeli
2025-09-22 09:28:09 +03:30
parent 2e2718a92e
commit f70229ab30
9 changed files with 200 additions and 51 deletions
+24
View File
@@ -0,0 +1,24 @@
import 'package:flutter/material.dart';
import 'package:tm_app/core/utils/breakpoints.dart';
/// Utility class for device and platform detection
class DeviceUtils {
/// Check if the current context represents a desktop screen
static bool isDesktop(BuildContext context) {
final size = MediaQuery.sizeOf(context);
return size.displaySize == DisplaySize.medium ||
size.displaySize == DisplaySize.large;
}
/// Check if the current context represents a mobile screen
static bool isMobile(BuildContext context) {
final size = MediaQuery.sizeOf(context);
return size.displaySize == DisplaySize.extraSmall;
}
/// Check if the current context represents a tablet screen
static bool isTablet(BuildContext context) {
final size = MediaQuery.sizeOf(context);
return size.displaySize == DisplaySize.small;
}
}