mirror of
https://github.com/foss42/apidash.git
synced 2025-05-31 14:23:45 +08:00
Migrate constraint check to utils
This commit is contained in:
12
lib/utils/window_utils.dart
Normal file
12
lib/utils/window_utils.dart
Normal file
@ -0,0 +1,12 @@
|
||||
bool showButtonLabelsInBodySuccess(int options, double maxWidth) {
|
||||
switch (options) {
|
||||
case 1:
|
||||
return (maxWidth < 300) ? false : true;
|
||||
case 2:
|
||||
return (maxWidth < 400) ? false : true;
|
||||
case 3:
|
||||
return (maxWidth < 500) ? false : true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user