Fixed bugs: overflows on location view, made location view scrollable
This commit is contained in:
@@ -67,8 +67,12 @@ class _AddLocationBySearchFormState extends State<AddLocationBySearchForm> {
|
||||
children: [_singleResult(name: "No result")],
|
||||
);
|
||||
}
|
||||
Iterable<LocationModel> locationsToShow = _locations!;
|
||||
if (locationsToShow.length > 3) {
|
||||
locationsToShow = _locations!.getRange(0, 3);
|
||||
}
|
||||
return Column(children: [
|
||||
for (LocationModel location in _locations!.getRange(0, 3))
|
||||
for (LocationModel location in locationsToShow)
|
||||
_singleResult(name: location.name, location: location)
|
||||
]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user