diff --git a/lib/screens/expectation_input_page.dart b/lib/screens/expectation_input_page.dart index e2df6c7..aa85efe 100644 --- a/lib/screens/expectation_input_page.dart +++ b/lib/screens/expectation_input_page.dart @@ -220,27 +220,72 @@ class ExpectationInputPageState extends State { padding: const EdgeInsets.all(16.0), child: Column( children: [ - const Card( - elevation: 2, - child: Padding( - padding: EdgeInsets.all(16.0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'Welcome to IFR Buddy!', - style: TextStyle( - fontSize: 18, fontWeight: FontWeight.bold), - textAlign: TextAlign.left, + // IntrinsicHeight Widget hinzufügen + IntrinsicHeight( + child: Row( + crossAxisAlignment: CrossAxisAlignment.stretch, // Stretch hinzufügen + children: [ + // Welcome Card - nimmt 60% der Breite + Expanded( + flex: 3, + child: Card( + elevation: 2, + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: const [ + Text( + 'Welcome to IFR Buddy!', + style: TextStyle(fontSize: 18, fontWeight: FontWeight.bold), + ), + SizedBox(height: 10), + Text( + 'Just an easy tool for writing down IFR clearances without a pen.', + style: TextStyle(fontSize: 16), + ), + ], + ), + ), ), - SizedBox(height: 10), - Text( - 'Just an easy tool for writing down IFR clearances without a pen.', - style: TextStyle(fontSize: 16), - textAlign: TextAlign.left, + ), + const SizedBox(width: 16), // Abstand zwischen den Cards + // SimBrief Card - nimmt 40% der Breite + Expanded( + flex: 2, + child: Card( + elevation: 2, + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + const Text( + 'SimBrief Import', + style: TextStyle(fontSize: 18, fontWeight: FontWeight.bold), + ), + const SizedBox(height: 10), + TextFormField( + controller: _simbriefIdController, + decoration: const InputDecoration( + labelText: 'SimBrief Pilot ID', + border: OutlineInputBorder(), + ), + ), + const SizedBox(height: 10), + SizedBox( + width: double.infinity, + child: ElevatedButton( + onPressed: _fetchSimbriefData, + child: const Text('Load SimBrief Data'), + ), + ), + ], + ), + ), ), - ], - ), + ), + ], ), ), const SizedBox(height: 16),