import 'package:flutter/material.dart'; import 'package:wetter/components/main_menu.dart'; import 'package:wetter/screens/main_weather_view.dart'; void main() => runApp(const MyApp()); class MyApp extends StatefulWidget { const MyApp({super.key}); @override State createState() => _MyAppState(); } class _MyAppState extends State { @override Widget build(BuildContext context) { return MaterialApp( title: 'Wetter', theme: ThemeData( primarySwatch: Colors.blue, textTheme: const TextTheme( headline1: TextStyle(fontSize: 72.0, fontWeight: FontWeight.bold), headline6: TextStyle(fontSize: 36.0, fontStyle: FontStyle.italic), bodyText2: TextStyle(fontSize: 14.0, fontFamily: 'Hind'), ), ), home: DefaultTabController( length: 3, child: Scaffold( appBar: AppBar( title: const Text('Wetter'), bottom: const TabBar( tabs: [ Tab(icon: Text("Hamburg")), Tab(icon: Text("Frankfurt")), Tab(icon: Text("Freiburg")), ], ), ), drawer: const NavBar(), body: const TabBarView( children: [ MainWeatherView(53.46, 9.98), MainWeatherView(50.15, 8.70), MainWeatherView(47.99, 7.85) ], ), ), ), ); } }