mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2025-12-18 22:44:21 +01:00
Fix UI Overlap Issue in TaskQueueView
This commit addresses a UI issue where the ListView items were overlapping with the Positioned widget in the TaskQueueView. The Positioned widget has been replaced with a more flexible layout using a Column widget to ensure proper spacing and positioning of elements on the screen. The ListView now takes up all available space above the buttons, preventing any overlap and enhancing the user experience.
This commit is contained in:
@@ -8,7 +8,6 @@ import 'package:flutter/material.dart';
|
||||
import 'package:auto_gpt_flutter_client/viewmodels/skill_tree_viewmodel.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
// TODO: Add view model for task queue instead of skill tree view model
|
||||
class TaskQueueView extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
@@ -19,10 +18,11 @@ class TaskQueueView extends StatelessWidget {
|
||||
|
||||
return Material(
|
||||
color: Colors.white,
|
||||
child: Stack(
|
||||
child: Column(
|
||||
children: [
|
||||
// The list of tasks (tiles)
|
||||
ListView.builder(
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
itemCount: nodeHierarchy.length,
|
||||
itemBuilder: (context, index) {
|
||||
final node = nodeHierarchy[index];
|
||||
@@ -88,11 +88,11 @@ class TaskQueueView extends StatelessWidget {
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
|
||||
Positioned(
|
||||
bottom: 20,
|
||||
left: 20,
|
||||
right: 20,
|
||||
// Buttons at the bottom
|
||||
Padding(
|
||||
padding: EdgeInsets.all(20),
|
||||
child: Column(
|
||||
children: [
|
||||
// TestSuiteButton
|
||||
@@ -109,7 +109,6 @@ class TaskQueueView extends StatelessWidget {
|
||||
chatViewModel.clearCurrentTaskAndChats();
|
||||
viewModel.runBenchmark(chatViewModel, taskViewModel);
|
||||
},
|
||||
isDisabled: viewModel.isBenchmarkRunning,
|
||||
),
|
||||
SizedBox(height: 8), // Gap of 8 points between buttons
|
||||
// LeaderboardSubmissionButton
|
||||
|
||||
Reference in New Issue
Block a user