diff --git a/assets/Events.png b/assets/Events.png new file mode 100644 index 0000000..a3ac6e6 Binary files /dev/null and b/assets/Events.png differ diff --git a/assets/Family.png b/assets/Family.png new file mode 100644 index 0000000..5639f0b Binary files /dev/null and b/assets/Family.png differ diff --git a/assets/Home.png b/assets/Home.png new file mode 100644 index 0000000..f3c262c Binary files /dev/null and b/assets/Home.png differ diff --git a/assets/HouseCup.png b/assets/HouseCup.png new file mode 100644 index 0000000..5767b77 Binary files /dev/null and b/assets/HouseCup.png differ diff --git a/assets/Vault.png b/assets/Vault.png new file mode 100644 index 0000000..6c3a4ca Binary files /dev/null and b/assets/Vault.png differ diff --git a/assets/connect.png b/assets/connect.png new file mode 100644 index 0000000..f6946d6 Binary files /dev/null and b/assets/connect.png differ diff --git a/assets/discover.png b/assets/discover.png new file mode 100644 index 0000000..40561ac Binary files /dev/null and b/assets/discover.png differ diff --git a/assets/event.png b/assets/event.png new file mode 100644 index 0000000..c0c860f Binary files /dev/null and b/assets/event.png differ diff --git a/assets/experience.png b/assets/experience.png new file mode 100644 index 0000000..efc0460 Binary files /dev/null and b/assets/experience.png differ diff --git a/assets/osmoze.png b/assets/osmoze.png new file mode 100644 index 0000000..0dd66b6 Binary files /dev/null and b/assets/osmoze.png differ diff --git a/lib/screen/Events.dart b/lib/screen/Events.dart new file mode 100644 index 0000000..d027b7a --- /dev/null +++ b/lib/screen/Events.dart @@ -0,0 +1,168 @@ +import 'dart:convert'; +import 'dart:io'; +import 'dart:math'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_dotenv/flutter_dotenv.dart'; +import 'package:google_fonts/google_fonts.dart'; +import 'package:shared_preferences/shared_preferences.dart'; +import 'package:sochem/models/notification_model.dart'; +import 'package:sochem/utils/constants.dart'; +import 'package:sochem/utils/dialog.dart'; +import 'package:sochem/utils/endpoints.dart'; +import 'package:sochem/widgets/bar.dart'; +import 'package:sochem/widgets/carousel.dart'; +import 'package:sochem/widgets/gridcards.dart'; +import 'package:http/http.dart' as http; + +class EventsScreen extends StatefulWidget { + @override + _EventsScreenState createState() => _EventsScreenState(); +} + +class _EventsScreenState extends State { + bool newNotifExist = false; + String userName = ''; + String initials = ''; + bool loggedIn = false; + String token = ""; + late SharedPreferences prefs; + + Future fetchNotifs() async { + var response = await http.get( + Uri.parse(Endpoints.notif), + headers: {HttpHeaders.authorizationHeader: token}, + ); + List notifs = []; + if (response.statusCode == 200) { + var peopleJson = json.decode(response.body); + for (var peoplesJson in peopleJson) { + notifs.add(Notifications.fromJson(peoplesJson)); + } + } + if (notifs.isNotEmpty) { + int newId = int.parse(notifs.last.id); + int oldId = 0; + if (prefs.containsKey(lastNotifId)) { + oldId = prefs.getInt(lastNotifId)!; + } else { + prefs.setInt(lastNotifId, 0); + } + newNotifExist = oldId < newId; + } + } + + void refreshAfterNotificationScreen() { + setState(() { + newNotifExist = false; + }); + } + + @override + void initState() { + _initialising(); + super.initState(); + } + + void _initialising() async { + prefs = await SharedPreferences.getInstance(); + loggedIn = prefs.getBool(isLoggedIn)!; + if (loggedIn) { + token = prefs.getString(DjangoToken)!; + userName = prefs.getString(UserName)!; + var temp = ""; + for (var y in userName.split(' ')) { + if (y[0] == '4') + break; + else + temp += y + ' '; + } + userName = temp; + await fetchNotifs(); + } else { + token = dotenv.get(GuestToken); + userName = "Guest"; + } + setState(() { + initials = userName.substring(0, 1).toUpperCase(); + }); + } + + @override + Widget build(BuildContext context) { + Size screensize = MediaQuery.of(context).size; + return Scaffold( + backgroundColor: Color.fromARGB(1, 0, 2, 20), + body: Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Row( + children: [ + Container( + width: screensize.width * 0.4, + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Text( + "Hey " + initials, + style: GoogleFonts.montserrat( + textStyle: TextStyle( + fontSize: 23, + fontWeight: FontWeight.w500, + color: Colors.white, + ), + ), + ), + ), + ) + ], + ), + Row(children: [ + Stack( + children: [ + IconButton( + alignment: Alignment.centerRight, + onPressed: () => loggedIn + ? Navigator.pushNamed(context, NotifRoute) + .then((value) => + refreshAfterNotificationScreen()) + : signinDialog(context), + icon: Icon( + CupertinoIcons.bell, + size: 30.0, + color: Colors.white, + ), + ), + if (newNotifExist) + Positioned( + right: 10, + top: 7, + child: CircleAvatar( + backgroundColor: Colors.red, + maxRadius: 6, + minRadius: 6, + ), + ), + ], + ),] + ), + ]), + Container( + height: 180, + child: Text("hi") + ), + Container( + child: Column( + children: [ + Divider( + color: Color.fromRGBO(42, 107, 255, 1), + thickness: 0.5, + ), + HomeScreenBar() + ], + ), + ) + ])); + } +} diff --git a/lib/screen/home_screen.dart b/lib/screen/home_screen.dart index 0a4898f..51a9ba7 100644 --- a/lib/screen/home_screen.dart +++ b/lib/screen/home_screen.dart @@ -10,6 +10,7 @@ import 'package:sochem/models/notification_model.dart'; import 'package:sochem/utils/constants.dart'; import 'package:sochem/utils/dialog.dart'; import 'package:sochem/utils/endpoints.dart'; +import 'package:sochem/widgets/bar.dart'; import 'package:sochem/widgets/carousel.dart'; import 'package:sochem/widgets/gridcards.dart'; import 'package:http/http.dart' as http; @@ -91,28 +92,14 @@ class _HomeScreenState extends State { Widget build(BuildContext context) { Size screensize = MediaQuery.of(context).size; return Scaffold( - backgroundColor: kBackgroundColor, + backgroundColor: Color.fromARGB(1, 0, 2, 20), body: Column( children: [ Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.only( - bottomLeft: Radius.circular(30.0), - bottomRight: Radius.circular(30.0), - ), - color: kPrimaryColor, - boxShadow: [ - BoxShadow( - color: Colors.black54, - offset: const Offset(1.0, 1.0), //Offset - blurRadius: 30.0, - spreadRadius: 1.0, - ), - ], - ), height: screensize.height * 0.3, child: SafeArea( child: Column( + crossAxisAlignment: CrossAxisAlignment.start, children: [ Padding( padding: EdgeInsets.fromLTRB( @@ -126,44 +113,18 @@ class _HomeScreenState extends State { children: [ Row( children: [ - Padding( - padding: const EdgeInsets.only(right: 7.0), - child: GestureDetector( - onTap: () => loggedIn - ? Navigator.pushNamed(context, ProfileRoute) - : signinDialog(context), - child: CircleAvatar( - backgroundColor: Colors.primaries[Random() - .nextInt(Colors.primaries.length)], - radius: 25, - child: Padding( - padding: const EdgeInsets.all(8.0), - child: loggedIn - ? Text( - initials, - style: TextStyle( - fontWeight: FontWeight.bold, - color: Colors.white, - fontSize: 25, - ), - ) - : Icon( - Icons.account_circle_outlined, - size: 35, - ), - ), - ), - ), - ), Container( width: screensize.width * 0.4, - child: Text( - userName, - style: GoogleFonts.montserrat( - textStyle: TextStyle( - fontSize: 15, - fontWeight: FontWeight.w300, - color: Colors.white, + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Text( + "Hey " + initials, + style: GoogleFonts.montserrat( + textStyle: TextStyle( + fontSize: 23, + fontWeight: FontWeight.w500, + color: Colors.white, + ), ), ), ), @@ -198,68 +159,101 @@ class _HomeScreenState extends State { ), ], ), - IconButton( - alignment: Alignment.centerRight, - onPressed: () => - Navigator.pushNamed(context, InfoRoute), - icon: Icon( - CupertinoIcons.info_circle, - size: 30.0, - color: Colors.white, - ), - ), + // IconButton( + // alignment: Alignment.centerRight, + // onPressed: () => + // Navigator.pushNamed(context, InfoRoute), + // icon: Icon( + // CupertinoIcons.info_circle, + // size: 30.0, + // color: Colors.white, + // ), + // ), ]), ], ), ), - Container( - alignment: Alignment.centerLeft, - child: Padding( - padding: EdgeInsets.only( - left: 25.0, - top: screensize.height * 0.01, - ), - child: Text( - "Society Of", - textAlign: TextAlign.left, - style: GoogleFonts.raleway( - textStyle: TextStyle( - fontSize: screensize.width * 0.087, - fontWeight: FontWeight.w600, - color: Colors.white, - // letterSpacing: 1.2, - ), - ), - ), - ), + Divider( + color: Color.fromRGBO(42, 107, 255, 1), + thickness: 0.4, + ), + Padding( + padding: const EdgeInsets.fromLTRB(8, 2, 8, 2), + child: Text("Upcoming", + style: TextStyle( + color: Color.fromRGBO(83, 141, 255, 1), + fontSize: 18, + fontWeight: FontWeight.w500,)), ), Container( - alignment: Alignment.centerLeft, - child: Padding( - padding: EdgeInsets.only(left: 25.0), - child: Text( - "Chemical Engineers", - textAlign: TextAlign.left, - style: GoogleFonts.raleway( - textStyle: TextStyle( - fontSize: screensize.width * 0.082, - fontWeight: FontWeight.w600, - color: Colors.white, - // letterSpacing: 1.2, - ), - ), - ), + height: 70, + child: ListView( + ), - ), + ) + // Container( + // alignment: Alignment.centerLeft, + // child: Padding( + // padding: EdgeInsets.only( + // left: 25.0, + // top: screensize.height * 0.01, + // ), + // child: Text( + // "Society Of", + // textAlign: TextAlign.left, + // style: GoogleFonts.raleway( + // textStyle: TextStyle( + // fontSize: screensize.width * 0.087, + // fontWeight: FontWeight.w600, + // color: Colors.white, + // // letterSpacing: 1.2, + // ), + // ), + // ), + // ), + // ), + // Container( + // alignment: Alignment.centerLeft, + // child: Padding( + // padding: EdgeInsets.only(left: 25.0), + // child: Text( + // "Chemical Engineers", + // textAlign: TextAlign.left, + // style: GoogleFonts.raleway( + // textStyle: TextStyle( + // fontSize: screensize.width * 0.082, + // fontWeight: FontWeight.w600, + // color: Colors.white, + // // letterSpacing: 1.2, + // ), + // ), + // ), + // ), + // ), ], ), ), ), + Divider( + color: Color.fromRGBO(211, 226, 255, 1), + thickness: 0.065, + ), Container( - height: screensize.height * 0.52, + height: screensize.height * 0.5, child: HomeScreenGrid(), ), - HomeScreenCarousel(), + Container( + child: Column( + children: [ + Divider( + color: Color.fromRGBO(42, 107, 255, 1), + thickness: 0.5, + ), + HomeScreenBar() + ], + ), + ) + //HomeScreenCarousel(), ], ), ); diff --git a/lib/screen/onboarding_screen.dart b/lib/screen/onboarding_screen.dart index 846d9e3..c75ce11 100644 --- a/lib/screen/onboarding_screen.dart +++ b/lib/screen/onboarding_screen.dart @@ -4,9 +4,10 @@ import 'package:sochem/utils/constants.dart'; import 'package:sochem/utils/onboarding_styles.dart'; List onboardingColor = [ - Color(0xFF7bc05b), - Color(0xFFffb61d), - Color(0xFF767bff), + Color.fromARGB(255, 57, 122, 235), + Color.fromARGB(255, 57, 122, 235), + Color.fromARGB(255, 57, 122, 235) + ]; class OnboardingScreen extends StatefulWidget { @@ -32,10 +33,10 @@ class _OnboardingScreenState extends State { duration: Duration(milliseconds: 150), margin: EdgeInsets.symmetric(horizontal: 8.0), height: 8.0, - width: isActive ? 24.0 : 16.0, + width: isActive ? 40.0 : 16.0, decoration: BoxDecoration( - color: isActive ? onboardingColor[_currentPage] : Color(0xFF7B51D3), - borderRadius: BorderRadius.all(Radius.circular(12)), + color: isActive ? Color.fromARGB(255, 57, 122, 235) : Colors.white, + borderRadius: isActive?BorderRadius.all(Radius.circular(400)):BorderRadius.all(Radius.circular(3)), ), ); } @@ -44,9 +45,12 @@ class _OnboardingScreenState extends State { Widget build(BuildContext context) { Size screenSize = MediaQuery.of(context).size; return Scaffold( - backgroundColor: Colors.white, + //backgroundColor: Color.fromARGB(255, 49, 74, 201), body: Container( - decoration: BoxDecoration(), + decoration: BoxDecoration(gradient: LinearGradient( + begin: Alignment.topLeft, + end: Alignment.bottomRight, + colors: [Color.fromARGB(255, 22, 38, 114),Color.fromARGB(255, 10, 16, 49)])), child: SafeArea( child: Column( crossAxisAlignment: CrossAxisAlignment.stretch, @@ -66,7 +70,7 @@ class _OnboardingScreenState extends State { child: Text( 'Skip', style: TextStyle( - color: onboardingColor[_currentPage], + color: Colors.white, fontSize: 20.0, ), ), @@ -86,25 +90,25 @@ class _OnboardingScreenState extends State { children: [ onboardingPage( screenSize: screenSize, - image: 'assets/search.png', - title: 'Discover!\nA new door of possibilities', + image: 'assets/discover.png', + title: 'Discover', desc: - 'Having trouble getting resources?\nYou will find it all here. From Books to Roadmaps, be it helping with your Core Subjects or Preparation for others. \nWe got you all covered!', + 'A one-stop-shop for\neverything atomic! From books to\nroadmaps and professors...', ), onboardingPage( screenSize: screenSize, - image: 'assets/Technology.png', - title: 'Connect!\nWith our Society', + image: 'assets/connect.png', + title: 'Connect', desc: - 'Find your Group, Colleagues or \neven Connect with our Alumni?\n An eezy peezy way to do it all', + 'An eezy-peezy way to find\nyour colleagues or even connect\nand network with our Alumni...', ), onboardingPage( screenSize: screenSize, - image: 'assets/Food.png', + image: 'assets/experience.png', title: - 'Experience!\nUpdated and delivered at your Fingertips', + 'Experience', desc: - 'Updates about Events and Activites now within your comfort and reach', + 'Get updated about all the\n events and activities now within\nyour comfort & reach!', ), ], ), @@ -113,41 +117,41 @@ class _OnboardingScreenState extends State { mainAxisAlignment: MainAxisAlignment.center, children: _buildPageIndicator(), ), - Visibility( - visible: _currentPage != _numPages - 1, - child: Expanded( - child: Align( - alignment: FractionalOffset.bottomRight, - child: TextButton( - onPressed: () { - _pageController.nextPage( - duration: Duration(milliseconds: 500), - curve: Curves.ease, - ); - }, - child: Row( - mainAxisAlignment: MainAxisAlignment.center, - mainAxisSize: MainAxisSize.min, - children: [ - Text( - 'Next', - style: TextStyle( - color: onboardingColor[_currentPage], - fontSize: 22.0, - ), - ), - SizedBox(width: 10.0), - Icon( - Icons.arrow_forward, - color: Colors.white, - size: 30.0, - ), - ], - ), - ), - ), - ), - ), + // Visibility( + // visible: _currentPage != _numPages - 1, + // child: Expanded( + // child: Align( + // alignment: FractionalOffset.bottomRight, + // child: TextButton( + // onPressed: () { + // _pageController.nextPage( + // duration: Duration(milliseconds: 500), + // curve: Curves.ease, + // ); + // }, + // child: Row( + // mainAxisAlignment: MainAxisAlignment.center, + // mainAxisSize: MainAxisSize.min, + // children: [ + // Text( + // 'Next', + // style: TextStyle( + // color: onboardingColor[_currentPage], + // fontSize: 22.0, + // ), + // ), + // SizedBox(width: 10.0), + // Icon( + // Icons.arrow_forward, + // color: Colors.white, + // size: 30.0, + // ), + // ], + // ), + // ), + // ), + // ), + // ), SizedBox(height: 10.0) ], ), @@ -156,9 +160,14 @@ class _OnboardingScreenState extends State { bottomSheet: Visibility( visible: _currentPage == _numPages - 1, child: Container( - height: 60.0, - width: double.infinity, - color: Colors.white, + decoration: BoxDecoration(gradient: LinearGradient( + begin: Alignment.topLeft, + end: Alignment.bottomRight, + colors: [Color.fromARGB(255, 13, 23, 70),Color.fromARGB(255, 9, 18, 61)])), + height: 60.0, + width: double.infinity, + + child: GestureDetector( onTap: () async { var prefs = await SharedPreferences.getInstance(); @@ -166,16 +175,22 @@ class _OnboardingScreenState extends State { Navigator.pushReplacementNamed(context, LoginRoute); }, child: Center( - child: Padding( - padding: EdgeInsets.symmetric(vertical: 10.0), - child: Text( - 'Get started', - style: TextStyle( - color: Color(0xFF5B16D0), - fontSize: 20.0, - fontWeight: FontWeight.bold, - ), - ), + child: Container( + height: 40, + width: 300, + decoration: BoxDecoration( + color: Color.fromARGB(255, 57, 122, 235), + borderRadius: BorderRadius.all(Radius.circular(20)),), + child:Center( + child: Text( + 'Explore', + style: TextStyle( + color: Colors.black, + fontSize: 20.0, + fontWeight: FontWeight.bold, + ), + ), + ), ), ), ), @@ -202,11 +217,18 @@ class onboardingPage extends StatelessWidget { @override Widget build(BuildContext context) { return Padding( - padding: EdgeInsets.all(10.0), + padding: EdgeInsets.fromLTRB(10.0,0.0,10.0,0.0), child: SingleChildScrollView( child: Column( crossAxisAlignment: CrossAxisAlignment.center, - children: [ + children: [ SizedBox(height: screenSize.height * 0.05), + Center( + child: Text( + title, + textAlign: TextAlign.center, + style:TextStyle(color: Colors.white, fontWeight: FontWeight.w900, fontSize: 28, fontStyle: FontStyle.normal), + ), + ), Center( child: Image( image: AssetImage( @@ -216,19 +238,10 @@ class onboardingPage extends StatelessWidget { width: 300, ), ), - SizedBox(height: screenSize.height * 0.01), - Center( - child: Text( - title, - textAlign: TextAlign.center, - style: kTitleStyle, - ), - ), - SizedBox(height: screenSize.height * 0.05), Text( - desc, + '\n'+desc, textAlign: TextAlign.center, - style: kSubtitleStyle, + style:TextStyle(fontSize: 18,color:Color.fromARGB(255, 57, 122, 235)), ), ], ), diff --git a/lib/utils/constants.dart b/lib/utils/constants.dart index db67866..0532e00 100644 --- a/lib/utils/constants.dart +++ b/lib/utils/constants.dart @@ -19,6 +19,13 @@ const String Slideimg3 = "assets/slider/img3.png"; const String GoogleIcon = "assets/google_logo.png"; const String WaitingIcon = "assets/waiting.png"; const String ProfileBackground = "assets/profile_background.jpeg"; +const String OsmozeIcon = "assets/osmoze.png"; +const String FamilyIcon = "assets/Family.png"; +const String HouseCupIcon = "assets/HouseCup.png"; +const String EventsIcon = "assets/Events.png"; +const String eventIcon = "assets/event.png"; +const String HomeIcon = "assets/Home.png"; +const String VaultIcon = "assets/Vault.png"; // Colors Used -> const kPrimaryColor = Color(0xFF3449c0); @@ -47,6 +54,7 @@ const String HomeRoute = '/home'; const String OnboardingRoute = '/onboarding'; const String ForumRoute = '/forum'; const String InfoRoute = '/info'; +const String EventsRoute = '/Events'; // Shared Prefs & Environment variables -> const String AppVersion = 'app_version'; diff --git a/lib/widgets/bar.dart b/lib/widgets/bar.dart new file mode 100644 index 0000000..4aa3b49 --- /dev/null +++ b/lib/widgets/bar.dart @@ -0,0 +1,124 @@ +import 'package:flutter/material.dart'; +import 'package:google_fonts/google_fonts.dart'; +import 'package:shared_preferences/shared_preferences.dart'; +import 'package:sochem/utils/constants.dart'; + +import '../utils/dialog.dart'; + +class HomeScreenBar extends StatefulWidget { + @override + State createState() => _HomeScreenBarState(); +} + +class _HomeScreenBarState extends State { + bool loggedIn = false; + @override + void initState() { + super.initState(); + _initialising(); + } + + void _initialising() async { + final prefs = await SharedPreferences.getInstance(); + setState(() { + loggedIn = prefs.getBool(isLoggedIn)!; + }); + } + + @override + Widget build(BuildContext context) { + return Column( + children: [ + Divider( + color: Color.fromRGBO(42, 107, 255, 1), + thickness: 0.3, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + BarCard( + image: HomeIcon, + title: "Home", + route: HomeRoute, + allowed: true, + ), + BarCard( + image: eventIcon, + title: "Events", + route: EventsRoute, + allowed: true, + ), + BarCard( + image: VaultIcon, + title: "Vault", + route: CloudRoute, + allowed: loggedIn, + ), + BarCard( + image: EventsIcon, + title: "You", + route: ProfileRoute, + allowed: loggedIn, + ), + ], + ), + ], + ); + } +} + +class BarCard extends StatelessWidget { + const BarCard({ + required this.image, + required this.title, + required this.route, + required this.allowed, + }); + final String image; + final String title; + final String route; + final bool allowed; + @override + Widget build(BuildContext context) { + final currentRouteName = ModalRoute.of(context)?.settings.name; + Size size = MediaQuery.of(context).size; + return GestureDetector( + onTap: () => + allowed ? Navigator.pushNamed(context, route) : signinDialog(context), + child: Container( + height: 41, + width: 40, + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Center( + child: Image.asset( + image, + color: (currentRouteName == route) + ? Color.fromRGBO(83, 141, 255, 1) + : Colors.white, + width: 30.0, + height: 24.0, + ), + ), + SizedBox( + height: 4, + ), + Text( + title, + style: GoogleFonts.montserrat( + textStyle: TextStyle( + fontSize: 10, + fontWeight: FontWeight.w500, + color: (currentRouteName == route) + ? Color.fromRGBO(83, 141, 255, 1) + : Colors.white, + ), + ), + ), + ], + ), + ), + ); + } +} diff --git a/lib/widgets/gridcards.dart b/lib/widgets/gridcards.dart index bfe2e6c..3fee887 100644 --- a/lib/widgets/gridcards.dart +++ b/lib/widgets/gridcards.dart @@ -31,53 +31,60 @@ class _HomeScreenGridState extends State { return Column( mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ + // Row( + // mainAxisAlignment: MainAxisAlignment.spaceEvenly, + // children: [ + // SingleCard( + // image: FeedIcon, + // title: "Feed", + // route: FeedRoute, + // allowed: true, + // ), + // SingleCard( + // image: CloudIcon, + // title: "Cloud", + // route: CloudRoute, + // allowed: loggedIn, + // ), + // SingleCard( + // image: ProfileIcon, + // title: "Profile", + // route: ProfileRoute, + // allowed: loggedIn, + // ), + // ], + // ), Row( mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ SingleCard( - image: FeedIcon, - title: "Feed", - route: FeedRoute, - allowed: true, + image: OsmozeIcon, + title: "Osmoze", + route: ForumRoute, + allowed: loggedIn, ), SingleCard( - image: CloudIcon, - title: "Cloud", + image: EventsIcon, + title: "Events", route: CloudRoute, allowed: loggedIn, ), ], ), + Text(" "), Row( mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ SingleCard( - image: ForumIcon, - title: "Forum", - route: ForumRoute, - allowed: loggedIn, - ), - SingleCard( - image: GroupIcon, - title: "Groups", - route: GroupRoute, + image: FamilyIcon, + title: "Family", + route: PeopleRoute, allowed: true, ), - ], - ), - Row( - mainAxisAlignment: MainAxisAlignment.spaceEvenly, - children: [ - SingleCard( - image: ProfileIcon, - title: "Profile", - route: ProfileRoute, - allowed: loggedIn, - ), SingleCard( - image: PeopleIcon, - title: "People", - route: PeopleRoute, + image: HouseCupIcon, + title: "House Cup", + route: GroupRoute, allowed: true, ), ], @@ -105,18 +112,17 @@ class SingleCard extends StatelessWidget { onTap: () => allowed ? Navigator.pushNamed(context, route) : signinDialog(context), child: Container( - height: size.height * 0.15, + height: size.height * 0.23, width: size.width * 0.40, decoration: BoxDecoration( - borderRadius: BorderRadius.circular(25), - color: cardImageColor, - boxShadow: [ - BoxShadow( - color: Colors.black45, - offset: const Offset(1.0, 1.0), //Offset - blurRadius: 5.0, - ), - ], + color: Color.fromRGBO(31, 36, 54, 1), + borderRadius: BorderRadius.circular(15), + // boxShadow: [ + // BoxShadow( + // offset: const Offset(1.0, 1.0), //Offset + // blurRadius: 5.0, + // ), + // ], ), child: Column( mainAxisAlignment: MainAxisAlignment.spaceEvenly, @@ -124,18 +130,17 @@ class SingleCard extends StatelessWidget { Center( child: Image.asset( image, - width: 45.0, - height: 45.0, - color: Colors.white70, + width: 170.0, + height: 120.0, ), ), Text( title, style: GoogleFonts.montserrat( textStyle: TextStyle( - fontSize: 25, + fontSize: 18, fontWeight: FontWeight.w500, - color: Colors.white, + color: Color.fromRGBO(149, 204, 255, 1), ), ), ), diff --git a/pubspec.lock b/pubspec.lock index 0d19bd4..640143d 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -14,14 +14,14 @@ packages: name: args url: "https://pub.dartlang.org" source: hosted - version: "2.3.2" + version: "2.3.1" async: dependency: transitive description: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.9.0" + version: "2.8.2" boolean_selector: dependency: transitive description: @@ -35,21 +35,21 @@ packages: name: cached_network_image url: "https://pub.dartlang.org" source: hosted - version: "3.2.3" + version: "3.2.1" cached_network_image_platform_interface: dependency: transitive description: name: cached_network_image_platform_interface url: "https://pub.dartlang.org" source: hosted - version: "2.0.0" + version: "1.0.0" cached_network_image_web: dependency: transitive description: name: cached_network_image_web url: "https://pub.dartlang.org" source: hosted - version: "1.0.2" + version: "1.0.1" carousel_slider: dependency: "direct main" description: @@ -63,7 +63,14 @@ packages: name: characters url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.2.0" + charcode: + dependency: transitive + description: + name: charcode + url: "https://pub.dartlang.org" + source: hosted + version: "1.3.1" chewie: dependency: transitive description: @@ -84,7 +91,7 @@ packages: name: clock url: "https://pub.dartlang.org" source: hosted - version: "1.1.1" + version: "1.1.0" collection: dependency: transitive description: @@ -98,7 +105,7 @@ packages: name: convert url: "https://pub.dartlang.org" source: hosted - version: "3.1.1" + version: "3.1.0" crypto: dependency: transitive description: @@ -126,7 +133,7 @@ packages: name: fake_async url: "https://pub.dartlang.org" source: hosted - version: "1.3.1" + version: "1.3.0" ffi: dependency: transitive description: @@ -281,21 +288,21 @@ packages: name: matcher url: "https://pub.dartlang.org" source: hosted - version: "0.12.12" + version: "0.12.11" material_color_utilities: dependency: transitive description: name: material_color_utilities url: "https://pub.dartlang.org" source: hosted - version: "0.1.5" + version: "0.1.4" meta: dependency: transitive description: name: meta url: "https://pub.dartlang.org" source: hosted - version: "1.8.0" + version: "1.7.0" nested: dependency: transitive description: @@ -323,7 +330,7 @@ packages: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.8.2" + version: "1.8.1" path_drawing: dependency: transitive description: @@ -400,7 +407,7 @@ packages: name: petitparser url: "https://pub.dartlang.org" source: hosted - version: "5.1.0" + version: "5.0.0" platform: dependency: transitive description: @@ -517,21 +524,21 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.9.0" + version: "1.8.2" sqflite: dependency: transitive description: name: sqflite url: "https://pub.dartlang.org" source: hosted - version: "2.2.3" + version: "2.0.3+1" sqflite_common: dependency: transitive description: name: sqflite_common url: "https://pub.dartlang.org" source: hosted - version: "2.4.1" + version: "2.4.0" stack_trace: dependency: transitive description: @@ -552,28 +559,28 @@ packages: name: string_scanner url: "https://pub.dartlang.org" source: hosted - version: "1.1.1" + version: "1.1.0" synchronized: dependency: transitive description: name: synchronized url: "https://pub.dartlang.org" source: hosted - version: "3.0.1" + version: "3.0.0+3" term_glyph: dependency: transitive description: name: term_glyph url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.2.0" test_api: dependency: transitive description: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.12" + version: "0.4.9" tuple: dependency: transitive description: @@ -785,5 +792,5 @@ packages: source: hosted version: "3.1.1" sdks: - dart: ">=2.18.0 <3.0.0" - flutter: ">=3.3.0" + dart: ">=2.17.0 <3.0.0" + flutter: ">=3.0.0"