diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..dd42c59 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,25 @@ +{ + // Use IntelliSense to learn about possible attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "name": "Prototype_Learn", + "request": "launch", + "type": "dart" + }, + { + "name": "Prototype_Learn (profile mode)", + "request": "launch", + "type": "dart", + "flutterMode": "profile" + }, + { + "name": "Prototype_Learn (release mode)", + "request": "launch", + "type": "dart", + "flutterMode": "release" + } + ] +} \ No newline at end of file diff --git a/lib/main.dart b/lib/main.dart index 2dd093a..c72a4af 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -24,13 +24,14 @@ Future main() async { /// Supabase client final supabase = Supabase.instance.client; +final timeSpan = ""; /// Error message to display the user when unexpected error occurs. const unexpectedErrorMessage = 'Unexpected error occurred.'; class MyApp extends StatelessWidget { const MyApp({super.key}); - + @override Widget build(BuildContext context) { return MaterialApp( @@ -47,4 +48,3 @@ class MyApp extends StatelessWidget { ); } } - diff --git a/lib/screens/detail_widget.dart b/lib/screens/detail_widget.dart index b52f616..7e6474b 100644 --- a/lib/screens/detail_widget.dart +++ b/lib/screens/detail_widget.dart @@ -4,12 +4,13 @@ import 'package:learn_project/screens/subheader_Datepicker.dart'; import 'package:intl/intl.dart'; //import 'package:supabase_flutter/supabase_flutter.dart'; -class Frame28 extends StatelessWidget { +class Frame28 extends StatelessWidget { final List> events; final Color color; - const Frame28({Key? key, required this.events, required this.color}) : super(key: key); - + const Frame28({Key? key, required this.events, required this.color}) + : super(key: key); + /* void initState() { super.initState(); _loadData(); @@ -19,44 +20,57 @@ class Frame28 extends StatelessWidget { @override Widget build(BuildContext context) { //_loadData(); - var body = CustomScrollView( - slivers: [ - SliverSafeArea( - //minimum: EdgeInsets.zero, - bottom: false, - sliver: - SliverToBoxAdapter( - child: Container( + var body = CustomScrollView(slivers: [ + SliverSafeArea( + //minimum: EdgeInsets.zero, + bottom: false, + sliver: SliverToBoxAdapter( + child: Container( alignment: Alignment.center, - child: Column( - children: [ - //Header Container - HeaderSection(), - Container( - height: 35, - padding: const EdgeInsets.all(0), - child: ButtonSection(), // Dein Button-Bereich - ), - Container(height: 10,), - //Container(child: MusikHeader(),), - Column( - children: [ - Container( - width: 380, - //height: 259, - - child: const Column( - mainAxisSize: MainAxisSize.min, - mainAxisAlignment: MainAxisAlignment.start, - crossAxisAlignment: CrossAxisAlignment.start, + child: Column(children: [ + //Header Container + HeaderSection(), + Container( + height: 35, + padding: const EdgeInsets.all(0), + child: TimeButtonSection(), // Dein Button-Bereich + ), + Container( + height: 10, + child: MusikHeader(), + ), + Container( + height: 35, + child: MusikHeader(), + ), + //Container(child: MusikHeader(),), + Column( children: [ - // TODO: muss noch angepasst werden jedes mal wenn ein neuer Tag ist wieder diesen Text anzeigen - SizedBox(height: 10), - Text( 'Heute', style: TextStyle(color: Color(0xFF171717), fontSize: 12, fontFamily: 'Inter', fontWeight: FontWeight.w600,height:0,),), - //Kurze Zwischenbereich zum trennen - SizedBox(height: 4), - //EventCard2Section(), - /* const SizedBox(height: 20), + Container( + width: 380, + //height: 259, + + child: const Column( + mainAxisSize: MainAxisSize.min, + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + // TODO: muss noch angepasst werden jedes mal wenn ein neuer Tag ist wieder diesen Text anzeigen + SizedBox(height: 10), + Text( + 'Heute', + style: TextStyle( + color: Color(0xFF171717), + fontSize: 12, + fontFamily: 'Inter', + fontWeight: FontWeight.w600, + height: 0, + ), + ), + //Kurze Zwischenbereich zum trennen + SizedBox(height: 4), + //EventCard2Section(), + /* const SizedBox(height: 20), EventCard2Section(), const SizedBox(height: 20), Text('Morgen', style: TextStyle(color: Color(0xFF171717), fontSize: 12, fontFamily: 'Inter', fontWeight: FontWeight.w600, height: 0,),), @@ -64,35 +78,38 @@ class Frame28 extends StatelessWidget { const SizedBox(height: 4), EventCard2Section(), const SizedBox(height: 20), */ - ], + ], + ), + ), + ], ), - ), - ], - ),]) - ),),), - SliverList( - - delegate: SliverChildBuilderDelegate( - - (context, index) { - return EventCard2Section( - title: events[index]['name'], - description: events[index]['description'], - location: events[index]['location']['name'], - start_time: extractTime24h(events[index]['time'][0]['start_date']), - color: color, - ); - }, - childCount: events.length, - ),), - - ]); - return Scaffold(backgroundColor: Colors.white, + ])), + ), + ), + SliverList( + delegate: SliverChildBuilderDelegate( + (context, index) { + return EventCard2Section( + title: events[index]['name'], + description: events[index]['description'], + location: events[index]['location']['name'], + start_time: + extractTime24h(events[index]['time'][0]['start_date']), + color: color, + ); + }, + childCount: events.length, + ), + ), + ]); + return Scaffold( + backgroundColor: Colors.white, body: body, ); } } -String extractTime24h(String timestamp) { + +String extractTime24h(String timestamp) { try { DateTime dateTime = DateTime.parse(timestamp); String hours = dateTime.hour.toString().padLeft(2, '0'); @@ -102,4 +119,4 @@ String extractTime24h(String timestamp) { print('Error parsing timestamp: $e'); return '--:--'; // or some other error indicator } -} \ No newline at end of file +} diff --git a/lib/screens/home copy.dart b/lib/screens/home copy.dart index 988d46f..032b2a6 100644 --- a/lib/screens/home copy.dart +++ b/lib/screens/home copy.dart @@ -16,28 +16,31 @@ class HomePage extends StatelessWidget { //Body Container Expanded( - child: NestedScrollView( - headerSliverBuilder: (BuildContext context, bool innerBoxIsScrolled) { - return [ - SliverToBoxAdapter( - child: Container( - height: 35, - padding: const EdgeInsets.all(0), - child: ButtonSection(), // Dein Button-Bereich - ), - ), - ]; - }, - body:Column( - children:[ - GridView.builder( - shrinkWrap: true, // Damit der GridView korrekt in die Column passt - //physics: NeverScrollableScrollPhysics(), // Deaktiviert das Scrolling des GridView - gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( - crossAxisCount: 2, // Anzahl der Spalten im Grid - ), - itemCount: Data.recipes.length, // Anzahl der Elemente im Grid - itemBuilder: (BuildContext context, int index) { + child: NestedScrollView( + headerSliverBuilder: + (BuildContext context, bool innerBoxIsScrolled) { + return [ + SliverToBoxAdapter( + child: Container( + height: 35, + padding: const EdgeInsets.all(0), + child: TimeButtonSection(), // Dein Button-Bereich + ), + ), + ]; + }, + body: Column( + children: [ + GridView.builder( + shrinkWrap: + true, // Damit der GridView korrekt in die Column passt + //physics: NeverScrollableScrollPhysics(), // Deaktiviert das Scrolling des GridView + gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( + crossAxisCount: 2, // Anzahl der Spalten im Grid + ), + itemCount: + Data.recipes.length, // Anzahl der Elemente im Grid + itemBuilder: (BuildContext context, int index) { return Padding( padding: const EdgeInsets.all(6.0), child: InkWell( @@ -46,7 +49,7 @@ class HomePage extends StatelessWidget { context, MaterialPageRoute( builder: (context) => DetailsPage( - //recipe: Data.recipes[index], + //recipe: Data.recipes[index], ))); }, child: Card( @@ -76,11 +79,12 @@ class HomePage extends StatelessWidget { tag: Data.recipes[index].id, child: FadeInImage( image: AssetImage( - Data.recipes[index].imageUrl, - ), + Data.recipes[index].imageUrl, + ), fit: BoxFit.cover, placeholder: AssetImage( - 'assets/images/loading.gif', ), + 'assets/images/loading.gif', + ), ), ), ), @@ -102,19 +106,18 @@ class HomePage extends StatelessWidget { ), ); }, - ), - Image.asset( - 'assets/images/FooterFooter.png', // Pfad zum Bild - height: 127, // Höhe des Bildes - width: 390, // Breite des Bildes - ), - ], - ), - ), - ), + ), + Image.asset( + 'assets/images/FooterFooter.png', // Pfad zum Bild + height: 127, // Höhe des Bildes + width: 390, // Breite des Bildes + ), + ], + ), + ), + ), - - /* Expanded( + /* Expanded( child: Column( children:[ Container( @@ -202,13 +205,11 @@ class HomePage extends StatelessWidget { ), ), */ - - //Footer Container //Here you will get unexpected behaviour when keyboard pops-up. //So its better to use `bottomNavigationBar` to avoid this. - /* Container( + /* Container( padding: const EdgeInsets.all(8.0), color: Colors.white, alignment: Alignment.center, diff --git a/lib/screens/home.dart b/lib/screens/home.dart index 6213641..8216fdf 100644 --- a/lib/screens/home.dart +++ b/lib/screens/home.dart @@ -17,62 +17,70 @@ class HomePage extends StatelessWidget { // Überprüfe, ob der Insert erfolgreich war } + Future>> fetchEvents(String category) async { try { final today = DateTime.now().toUtc().toString().split(' ')[0]; final response = await supabase .from("events") //.innerJoin('event_category', 'events.id = event_category.event_id') - .select('id,name,description,detail,subheader,location(name),time!inner(*),event_category!inner(event_id)') - .eq('event_category.category_id',category); - //.gte('time.start_date', DateTime.now().toIso8601String().split('T')[0]) // Beginn des heutigen Tages - //.lt('time.start_date', DateTime.now().add(Duration(days: 1)).toIso8601String().split('T')[0]); // Morgen; - //select('id, name, cities(id, name)') - //find all events mit Ort und zusatzinfos die die Kathegorie haben welche ausgewählt wurde am heutigen Tag dann kommender Tag usw. + .select( + 'id,name,description,detail,subheader,location(name),time!inner(*),event_category!inner(event_id)') + .eq('event_category.category_id', category); + //.gte('time.start_date', DateTime.now().toIso8601String().split('T')[0]) // Beginn des heutigen Tages + //.lt('time.start_date', DateTime.now().add(Duration(days: 1)).toIso8601String().split('T')[0]); // Morgen; + //select('id, name, cities(id, name)') + //find all events mit Ort und zusatzinfos die die Kathegorie haben welche ausgewählt wurde am heutigen Tag dann kommender Tag usw. //final test = response[0]['time'][0]['start_date']; return (response as List).cast>(); } catch (e) { throw Exception('Failed to fetch data: $e'); } } - Future>> fetchEventsToday(String category) async { + + Future>> fetchEventsToday(String category) async { try { final today = DateTime.now().toUtc().toString().split(' ')[0]; final response = await supabase .from("events") //.innerJoin('event_category', 'events.id = event_category.event_id') - .select('id,name,description,detail,subheader,location(name),time!inner(*),event_category!inner(event_id)') - .eq('event_category.category_id',category)//; + .select( + 'id,name,description,detail,subheader,location(name),time!inner(*),event_category!inner(event_id)') + .eq('event_category.category_id', category) //; .eq('time.start_date', today); - //.gte('time.start_date', DateTime.now().toIso8601String().split('T')[0]) // Beginn des heutigen Tages - //.lt('time.start_date', DateTime.now().add(Duration(days: 1)).toIso8601String().split('T')[0]); // Morgen; - //select('id, name, cities(id, name)') - //find all events mit Ort und zusatzinfos die die Kathegorie haben welche ausgewählt wurde am heutigen Tag dann kommender Tag usw. + //.gte('time.start_date', DateTime.now().toIso8601String().split('T')[0]) // Beginn des heutigen Tages + //.lt('time.start_date', DateTime.now().add(Duration(days: 1)).toIso8601String().split('T')[0]); // Morgen; + //select('id, name, cities(id, name)') + //find all events mit Ort und zusatzinfos die die Kathegorie haben welche ausgewählt wurde am heutigen Tag dann kommender Tag usw. //final test = response[0]['time'][0]['start_date']; return (response as List).cast>(); } catch (e) { throw Exception('Failed to fetch data: $e'); } } - Future>> fetchEventsTomorrow(String category) async { + + Future>> fetchEventsTomorrow( + String category) async { try { final today = DateTime.now().toUtc().toString().split(' ')[0]; final response = await supabase .from("events") //.innerJoin('event_category', 'events.id = event_category.event_id') - .select('id,name,description,detail,subheader,location(name),time!inner(*),event_category!inner(event_id)') - .eq('event_category.category_id',category)//; + .select( + 'id,name,description,detail,subheader,location(name),time!inner(*),event_category!inner(event_id)') + .eq('event_category.category_id', category) //; .eq('time.start_date', today); - //.gte('time.start_date', DateTime.now().toIso8601String().split('T')[0]) // Beginn des heutigen Tages - //.lt('time.start_date', DateTime.now().add(Duration(days: 1)).toIso8601String().split('T')[0]); // Morgen; - //select('id, name, cities(id, name)') - //find all events mit Ort und zusatzinfos die die Kathegorie haben welche ausgewählt wurde am heutigen Tag dann kommender Tag usw. + //.gte('time.start_date', DateTime.now().toIso8601String().split('T')[0]) // Beginn des heutigen Tages + //.lt('time.start_date', DateTime.now().add(Duration(days: 1)).toIso8601String().split('T')[0]); // Morgen; + //select('id, name, cities(id, name)') + //find all events mit Ort und zusatzinfos die die Kathegorie haben welche ausgewählt wurde am heutigen Tag dann kommender Tag usw. //final test = response[0]['time'][0]['start_date']; return (response as List).cast>(); } catch (e) { throw Exception('Failed to fetch data: $e'); } } + @override Widget build(BuildContext context) { var size = MediaQuery.of(context).size; @@ -81,77 +89,77 @@ class HomePage extends StatelessWidget { final double itemHeight = (size.height - kToolbarHeight - 24) / 5; final double itemWidth = size.width / 2.3; var appBar = AppBar( - leading:SizedBox( - height: 60, - width: 63, - child: IconButton( + leading: SizedBox( + height: 60, + width: 63, + child: IconButton( icon: Image.asset('assets/images/logo.png'), onPressed: () { // Open drawer or perform action }, - ),), - title: Row( - children: [ -SizedBox( - height: 10, //height of button - width: 20, //width of button - child: Icon(Icons.keyboard_arrow_down), - ), - const SizedBox( - //width of button - width: 10, - ), - SizedBox( - width: 100.0, - child: TextField( - controller: TextEditingController(text: "Ingolstadt"), - decoration: InputDecoration( - border: UnderlineInputBorder(), - ), - ), - ), - ], ), - actions: [ - IconButton( - icon: Icon(Icons.search), - onPressed: () { - // Perform search action - }, - ), - SizedBox( - height: 40, - child: VerticalDivider( - thickness: 1, - width: 20, - color: Colors.black, - ),), + ), + title: Row( + children: [ SizedBox( - height: 50, //height of button - //width of button - child: IconButton( - icon: Image.asset('assets/images/Login.png'), - onPressed: () {}, - ), - ), + height: 10, //height of button + width: 20, //width of button + child: Icon(Icons.keyboard_arrow_down), + ), + const SizedBox( + //width of button + width: 10, + ), + SizedBox( + width: 100.0, + child: TextField( + controller: TextEditingController(text: "Ingolstadt"), + decoration: InputDecoration( + border: UnderlineInputBorder(), + ), + ), + ), ], - bottom: PreferredSize( - preferredSize: Size.fromHeight(1.0), - child: Container( + ), + actions: [ + IconButton( + icon: Icon(Icons.search), + onPressed: () { + // Perform search action + }, + ), + SizedBox( + height: 40, + child: VerticalDivider( + thickness: 1, + width: 20, color: Colors.black, - height: 1.0, ), ), - flexibleSpace: Container( - + SizedBox( + height: 50, //height of button + //width of button + child: IconButton( + icon: Image.asset('assets/images/Login.png'), + onPressed: () {}, + ), ), - ); + ], + bottom: PreferredSize( + preferredSize: Size.fromHeight(1.0), + child: Container( + color: Colors.black, + height: 1.0, + ), + ), + flexibleSpace: Container(), + ); var body = SafeArea( child: Column( children: [ //Header Container //HeaderSection(), - Container(height:10), + Container(height: 10), //Body Container Expanded( child: NestedScrollView( @@ -162,7 +170,7 @@ SizedBox( child: Container( height: 35, padding: const EdgeInsets.all(0), - child: ButtonSection(), // Dein Button-Bereich + child: TimeButtonSection(), // Dein Button-Bereich ), ), ]; @@ -185,9 +193,9 @@ SizedBox( padding: const EdgeInsets.all(6.0), child: InkWell( onTap: () async { - /* List> events = + /* List> events = await _loadData(); */ - List> events2 = + List> events2 = await fetchEvents(Data.recipes[index].category); Navigator.push( context, @@ -203,8 +211,8 @@ SizedBox( borderRadius: BorderRadius.circular(6.0), ), child: Container( - width: MediaQuery.of(context).size.width / 2.5, - height: 20, + //width: (MediaQuery.of(context).size.width / 2), + //height: 20, child: Column( children: [ Expanded( diff --git a/lib/screens/subheader_Datepicker.dart b/lib/screens/subheader_Datepicker.dart index 72c6169..208744d 100644 --- a/lib/screens/subheader_Datepicker.dart +++ b/lib/screens/subheader_Datepicker.dart @@ -1,19 +1,39 @@ import 'package:flutter/material.dart'; import 'package:learn_project/utils/helper_functions.dart'; -class ButtonSection extends StatelessWidget { +class TimeButtonSection extends StatefulWidget { + const TimeButtonSection(); + + @override + _TimeButtonSection createState() => _TimeButtonSection(); +} + +class _TimeButtonSection extends State { + bool _isToDayActive = false; + bool _isToMorrowActive = false; + bool _isWEActive = false; + @override Widget build(BuildContext context) { return Row( mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ // Button "Heute" (filled style) - ElevatedButton( - onPressed: () {}, + OutlinedButton( + onPressed: () { + setState(() { + _isToDayActive = !_isToDayActive; + _isToMorrowActive = false; + _isWEActive = false; + }); + }, child: Text('Heute'), - style: ElevatedButton.styleFrom( - backgroundColor: Colors.black, // Button color - foregroundColor: Colors.white, // Text color + style: OutlinedButton.styleFrom( + backgroundColor: _isToDayActive ? Colors.black : Colors.white, + foregroundColor: _isToDayActive ? Colors.white : Colors.black, + side: _isToDayActive + ? BorderSide(color: Colors.white) + : BorderSide(color: Colors.black), minimumSize: Size(85, 39), // Breite und Höhe shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(10.0), @@ -22,11 +42,20 @@ class ButtonSection extends StatelessWidget { ), // Button "Morgen" (outlined style) OutlinedButton( - onPressed: () {}, + onPressed: () { + setState(() { + _isToDayActive = false; + _isToMorrowActive = !_isToMorrowActive; + _isWEActive = false; + }); + }, child: Text('Morgen'), style: OutlinedButton.styleFrom( - foregroundColor: Colors.black, // Text color - side: BorderSide(color: Colors.black), // Border color + backgroundColor: _isToMorrowActive ? Colors.black : Colors.white, + foregroundColor: _isToMorrowActive ? Colors.white : Colors.black, + side: _isToMorrowActive + ? BorderSide(color: Colors.white) + : BorderSide(color: Colors.black), // Border color minimumSize: Size(90, 39), // Breite und Höhe shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(10.0), @@ -35,11 +64,20 @@ class ButtonSection extends StatelessWidget { ), // Button "Wochenende" (outlined style) OutlinedButton( - onPressed: () {}, + onPressed: () { + setState(() { + _isToDayActive = false; + _isToMorrowActive = false; + _isWEActive = !_isWEActive; + }); + }, child: Text('Wochenende'), style: OutlinedButton.styleFrom( - foregroundColor: Colors.black, // Text color - side: BorderSide(color: Colors.black), // Border color + backgroundColor: _isWEActive ? Colors.black : Colors.white, + foregroundColor: _isWEActive ? Colors.white : Colors.black, + side: _isWEActive + ? BorderSide(color: Colors.white) + : BorderSide(color: Colors.black), // Border color minimumSize: Size(100, 39), // Breite und Höhe shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(10.0), @@ -167,7 +205,6 @@ class EventCard2Section extends StatelessWidget { height: 120, margin: new EdgeInsets.fromLTRB(20.0, 0, 0.0, 8.0), child: Stack( - children: [ Positioned( left: 0, @@ -186,7 +223,7 @@ class EventCard2Section extends StatelessWidget { ), boxShadow: [ BoxShadow( - color: color,//Color(0xFFF8AB14), + color: color, //Color(0xFFF8AB14), blurRadius: 0, offset: Offset(0, 10), spreadRadius: 0, @@ -204,30 +241,31 @@ class EventCard2Section extends StatelessWidget { width: 130, // Breite des Bildes ), ), - Positioned( // Bookmark Button - left: 320, - top: 12, - child: Container( - width: 32, - height: 32, - decoration: BoxDecoration( - color: Color.fromARGB(196, 171, 170, 170), // Hintergrundfarbe des Buttons - shape: BoxShape.circle, // Runde Form - ), - child: IconButton( - padding: EdgeInsets.zero, // Entfernt zusätzlichen Abstand - icon: Icon(Icons.bookmark_border_outlined), - color: Colors.white, // Icon-Farbe - iconSize: 16, // Größe des Icons - onPressed: () { - // Aktion beim Drücken des Buttons - }, - ), - + Positioned( + // Bookmark Button + left: 320, + top: 12, + child: Container( + width: 32, + height: 32, + decoration: BoxDecoration( + color: Color.fromARGB( + 196, 171, 170, 170), // Hintergrundfarbe des Buttons + shape: BoxShape.circle, // Runde Form + ), + child: IconButton( + padding: EdgeInsets.zero, // Entfernt zusätzlichen Abstand + icon: Icon(Icons.bookmark_border_outlined), + color: Colors.white, // Icon-Farbe + iconSize: 16, // Größe des Icons + onPressed: () { + // Aktion beim Drücken des Buttons + }, + ), ), - ), - - Positioned( //Location + ), + Positioned( + //Location left: 10, top: 14, child: SizedBox( @@ -245,40 +283,42 @@ class EventCard2Section extends StatelessWidget { ), ), ), - Positioned( //Title + Positioned( + //Title left: 92, top: 14, child: Text( title, style: TextStyle( - color: Color(0xFF0A0A0A), - fontSize: 18, - fontFamily: 'Inter', - fontWeight: FontWeight.w400, - height: 0, - ), - + color: Color(0xFF0A0A0A), + fontSize: 18, + fontFamily: 'Inter', + fontWeight: FontWeight.w400, + height: 0, + ), ), ), - Positioned(//Description + Positioned( + //Description left: 10, top: 90, child: SizedBox( //width: 196, //height: 15, child: Text( - shortenText(description,30), - style: TextStyle( - color: Color(0xFF0A0A0A), - fontSize: 12, - fontFamily: 'Inter', - fontWeight: FontWeight.w400, - height: 0, - ), + shortenText(description, 30), + style: TextStyle( + color: Color(0xFF0A0A0A), + fontSize: 12, + fontFamily: 'Inter', + fontWeight: FontWeight.w400, + height: 0, + ), ), ), ), - Positioned( //Start time + Positioned( + //Start time left: 10, top: 70, child: SizedBox( @@ -296,7 +336,8 @@ class EventCard2Section extends StatelessWidget { ), ), ])))), - Positioned( //Text Beginn + Positioned( + //Text Beginn left: 10, top: 45, child: SizedBox( @@ -326,8 +367,6 @@ class EventCard2Section extends StatelessWidget { } } - - class GesundheitWellnes extends StatelessWidget { @override Widget build(BuildContext context) { @@ -346,10 +385,12 @@ class GesundheitWellnes extends StatelessWidget { height: 130, decoration: ShapeDecoration( image: DecorationImage( - image: NetworkImage("https://via.placeholder.com/167x130"), + image: + NetworkImage("https://via.placeholder.com/167x130"), fit: BoxFit.cover, ), - shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(8)), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(8)), shadows: [ BoxShadow( color: Color(0xFFF9AB15), @@ -407,7 +448,6 @@ class GesundheitWellnes extends StatelessWidget { } } - class TagSlider extends StatelessWidget { @override Widget build(BuildContext context) { @@ -431,7 +471,8 @@ class TagSlider extends StatelessWidget { children: [ Container( width: 145, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -459,7 +500,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 143, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -487,7 +529,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 102, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -515,7 +558,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 180, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -543,7 +587,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 86, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -571,7 +616,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 187, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -599,7 +645,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 78, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -627,7 +674,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 123, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -655,7 +703,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 78, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -683,7 +732,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 256, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -711,7 +761,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 110, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -739,7 +790,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 84, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -767,7 +819,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 91, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -795,7 +848,8 @@ class TagSlider extends StatelessWidget { ), Container( width: 79, - padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 8), + padding: const EdgeInsets.symmetric( + horizontal: 24, vertical: 8), clipBehavior: Clip.antiAlias, decoration: ShapeDecoration( shape: RoundedRectangleBorder( @@ -832,7 +886,6 @@ class TagSlider extends StatelessWidget { } } - class MusikHeader extends StatelessWidget { @override Widget build(BuildContext context) { @@ -847,7 +900,9 @@ class MusikHeader extends StatelessWidget { crossAxisAlignment: CrossAxisAlignment.center, children: [ Transform( - transform: Matrix4.identity()..translate(0.0, 0.0)..rotateZ(-1.57), + transform: Matrix4.identity() + ..translate(0.0, 0.0) + ..rotateZ(-1.57), child: Container( width: 32, height: 32, @@ -857,9 +912,7 @@ class MusikHeader extends StatelessWidget { mainAxisSize: MainAxisSize.min, mainAxisAlignment: MainAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start, - children: [ - - ], + children: [], ), ), ), @@ -917,4 +970,4 @@ class MusikHeader extends StatelessWidget { ], ); } -} \ No newline at end of file +}