From 49ce2a13aa4c4a9a720c93abb4d962d56c123a00 Mon Sep 17 00:00:00 2001 From: AnshumaliSuri Date: Wed, 4 Oct 2023 16:21:30 +0530 Subject: [PATCH 01/13] fix syntax error in firebase_db.dart --- ios/Podfile | 44 ++++++++++++++++++++++++++++++++++++++++++++ macos/Podfile | 43 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 87 insertions(+) create mode 100644 ios/Podfile create mode 100644 macos/Podfile diff --git a/ios/Podfile b/ios/Podfile new file mode 100644 index 0000000..fdcc671 --- /dev/null +++ b/ios/Podfile @@ -0,0 +1,44 @@ +# Uncomment this line to define a global platform for your project +# platform :ios, '11.0' + +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. +ENV['COCOAPODS_DISABLE_STATS'] = 'true' + +project 'Runner', { + 'Debug' => :debug, + 'Profile' => :release, + 'Release' => :release, +} + +def flutter_root + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) + unless File.exist?(generated_xcode_build_settings_path) + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" + end + + File.foreach(generated_xcode_build_settings_path) do |line| + matches = line.match(/FLUTTER_ROOT\=(.*)/) + return matches[1].strip if matches + end + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" +end + +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) + +flutter_ios_podfile_setup + +target 'Runner' do + use_frameworks! + use_modular_headers! + + flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) + target 'RunnerTests' do + inherit! :search_paths + end +end + +post_install do |installer| + installer.pods_project.targets.each do |target| + flutter_additional_ios_build_settings(target) + end +end diff --git a/macos/Podfile b/macos/Podfile new file mode 100644 index 0000000..c795730 --- /dev/null +++ b/macos/Podfile @@ -0,0 +1,43 @@ +platform :osx, '10.14' + +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. +ENV['COCOAPODS_DISABLE_STATS'] = 'true' + +project 'Runner', { + 'Debug' => :debug, + 'Profile' => :release, + 'Release' => :release, +} + +def flutter_root + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__) + unless File.exist?(generated_xcode_build_settings_path) + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first" + end + + File.foreach(generated_xcode_build_settings_path) do |line| + matches = line.match(/FLUTTER_ROOT\=(.*)/) + return matches[1].strip if matches + end + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\"" +end + +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) + +flutter_macos_podfile_setup + +target 'Runner' do + use_frameworks! + use_modular_headers! + + flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__)) + target 'RunnerTests' do + inherit! :search_paths + end +end + +post_install do |installer| + installer.pods_project.targets.each do |target| + flutter_additional_macos_build_settings(target) + end +end From abcec21376c520481bdce9cc8ba822f374045df1 Mon Sep 17 00:00:00 2001 From: AnshumaliSuri Date: Thu, 5 Oct 2023 09:08:14 +0530 Subject: [PATCH 02/13] Rectified errors throughout the project and also upgraded the dependancies in the project --- android/build.gradle | 4 +- ios/Flutter/Debug.xcconfig | 1 + ios/Flutter/Release.xcconfig | 1 + lib/individual/donation_page.dart | 51 ++-- lib/individual/health.dart | 29 +- lib/individual/spend_time.dart | 151 +++++----- lib/individual/user_chats_menu.dart | 13 +- lib/organization/org_chat_screen.dart | 92 +++--- lib/organization/org_chats_menu.dart | 9 +- lib/shared/services/firebase_database.dart | 13 +- linux/flutter/generated_plugin_registrant.cc | 4 + linux/flutter/generated_plugins.cmake | 1 + macos/Flutter/Flutter-Debug.xcconfig | 1 + macos/Flutter/Flutter-Release.xcconfig | 1 + macos/Flutter/GeneratedPluginRegistrant.swift | 6 +- pubspec.lock | 265 ++++++++++++------ pubspec.yaml | 20 +- .../flutter/generated_plugin_registrant.cc | 9 + windows/flutter/generated_plugins.cmake | 3 + 19 files changed, 391 insertions(+), 283 deletions(-) diff --git a/android/build.gradle b/android/build.gradle index d0f2b7f..ffe90b1 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -1,5 +1,5 @@ buildscript { - ext.kotlin_version = '1.6.10' + ext.kotlin_version = '1.9.10' repositories { google() mavenCentral() @@ -28,6 +28,6 @@ subprojects { project.evaluationDependsOn(':app') } -task clean(type: Delete) { +tasks.register("clean", Delete) { delete rootProject.buildDir } diff --git a/ios/Flutter/Debug.xcconfig b/ios/Flutter/Debug.xcconfig index 592ceee..ec97fc6 100644 --- a/ios/Flutter/Debug.xcconfig +++ b/ios/Flutter/Debug.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" #include "Generated.xcconfig" diff --git a/ios/Flutter/Release.xcconfig b/ios/Flutter/Release.xcconfig index 592ceee..c4855bf 100644 --- a/ios/Flutter/Release.xcconfig +++ b/ios/Flutter/Release.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" #include "Generated.xcconfig" diff --git a/lib/individual/donation_page.dart b/lib/individual/donation_page.dart index 2ca364a..1c3c8c9 100644 --- a/lib/individual/donation_page.dart +++ b/lib/individual/donation_page.dart @@ -1,3 +1,5 @@ +// ignore_for_file: use_build_context_synchronously + import 'package:cura/shared/widgets/gradient_background.dart'; import 'package:flutter/material.dart'; @@ -43,6 +45,33 @@ class _DonationPageState extends State { @override Widget build(BuildContext context) { + List organizationAddress = [ + 'India', + 'United States', + 'America', + 'Washington', + 'Paris', + 'Jakarta', + 'Australia', + 'Lorem Ipsum' + ]; + + List newAddSuggestions = organizationAddress + .map((orgAdd) => SearchFieldListItem(orgAdd, item: orgName)) + .toList(); + + List organizationSuggestions = [ + 'Organisation 1', + 'Organisation 2', + 'Organisation 3', + 'Organisation 4', + 'Organisation 5', + 'Organisation 6', + ]; + + List newSuggestions = organizationSuggestions + .map((orgName) => SearchFieldListItem(orgName, item: orgName)) + .toList(); return ScreenUtilInit( designSize: const Size(428, 926), builder: (context, child) => Scaffold( @@ -178,14 +207,7 @@ class _DonationPageState extends State { padding: EdgeInsets.fromLTRB(30.w, 0, 30.w, 0), child: SearchField( hint: " Enter organisation's name", - suggestions: const [ - 'Organisation 1', - 'Organisation 2', - 'Organisation 3', - 'Organisation 4', - 'Organisation 5', - 'Organisation 6', - ], + suggestions: newSuggestions, searchInputDecoration: InputDecoration( enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -230,16 +252,7 @@ class _DonationPageState extends State { padding: EdgeInsets.fromLTRB(30.w, 0, 30.w, 0), child: SearchField( hint: "Enter Organisation's Address", - suggestions: const [ - 'India', - 'United States', - 'America', - 'Washington', - 'Paris', - 'Jakarta', - 'Australia', - 'Lorem Ipsum' - ], + suggestions: newAddSuggestions, searchInputDecoration: InputDecoration( enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -359,7 +372,7 @@ class _DonationPageState extends State { BorderRadiusDirectional.circular(10), color: Colors.white, ), - padding: EdgeInsets.all(15), + padding: const EdgeInsets.all(15), width: MediaQuery.of(context).size.width * 0.7, height: 350, diff --git a/lib/individual/health.dart b/lib/individual/health.dart index 914f5fb..e74bc07 100644 --- a/lib/individual/health.dart +++ b/lib/individual/health.dart @@ -27,6 +27,18 @@ class _HealthPageState extends State { CollectionReference user = FirebaseFirestore.instance.collection('user'); @override Widget build(BuildContext context) { + List organizationSuggestions = [ + 'Organisation 1', + 'Organisation 2', + 'Organisation 3', + 'Organisation 4', + 'Organisation 5', + 'Organisation 6', + ]; + + List newSuggestions = organizationSuggestions + .map((orgName) => SearchFieldListItem(orgName, item: orgName)) + .toList(); return ScreenUtilInit( designSize: const Size(428, 926), builder: (context, child) => Scaffold( @@ -108,14 +120,7 @@ class _HealthPageState extends State { EdgeInsets.fromLTRB(15.w, 0, 15.w, 0), child: SearchField( hint: "Enter Organization's name", - suggestions: const [ - 'organization 1', - 'organization 2', - 'organization 3', - 'organization 4', - 'organization 5', - 'organization 6', - ], + suggestions: newSuggestions, searchInputDecoration: InputDecoration( // ignore: prefer_const_constructors contentPadding: EdgeInsets.only( @@ -203,7 +208,9 @@ class _HealthPageState extends State { lastDate: DateTime(2101)); if (pickeddate != null) { setState(() { - _date.text = DateFormat('yyyy-mm-dd').format(pickeddate); + _date.text = + DateFormat('yyyy-mm-dd') + .format(pickeddate); }); } }, @@ -425,9 +432,7 @@ class _HealthPageState extends State { )), ), ); - } - ) - ; + }); }, child: Text( "submit", diff --git a/lib/individual/spend_time.dart b/lib/individual/spend_time.dart index c404d8f..357b168 100644 --- a/lib/individual/spend_time.dart +++ b/lib/individual/spend_time.dart @@ -22,7 +22,7 @@ class _SpendTimeState extends State { TextEditingController orgName = TextEditingController(); FirestoreDatabase fd = FirestoreDatabase(); - List organisationNames = []; + List> organisationNames = []; CollectionReference spend = FirebaseFirestore.instance.collection('spend'); @@ -237,8 +237,8 @@ class _SpendTimeState extends State { backgroundColor: const Color(0xFF729CA3), ), onPressed: (() - // async - { + // async + { // await spend.add({ // 'organizationname': orgName.text, // date: date.text, @@ -265,89 +265,70 @@ class _SpendTimeState extends State { // ); showDialog( - context: context, - builder: (context) { - return Center( - child: Material( - type: - MaterialType.transparency, - child: Container( - decoration: BoxDecoration( - borderRadius: - BorderRadiusDirectional - .circular(10), - color: Colors.white, - ), - padding: - EdgeInsets.all(15), - width: - MediaQuery.of(context) - .size - .width * - 0.7, - height: 350, - child: Column( - crossAxisAlignment: - CrossAxisAlignment - .center, - children: [ - ClipRRect( - borderRadius: - BorderRadius - .circular( - 5), - child: Image.asset( - 'assets/main_assets/Completed.png', - width: 200, - height: 200, - ), - ), - // ignore: prefer_const_constructors - SizedBox(height: 10), - - // ignore: prefer_const_constructors - Text( - 'Thank You !!', - style: const TextStyle( - fontSize: 25, - color: Color - .fromARGB( - 255, - 137, - 184, - 189), - fontWeight: - FontWeight - .bold), - ), - // ignore: prefer_const_constructors - SizedBox( - height: 10, - ), - // ignore: prefer_const_constructors - Text( - 'Thank You for giving your precious time', - style: const TextStyle( - fontSize: 20, - color: Color - .fromARGB( - 255, - 0, - 10, - 11), - fontWeight: - FontWeight - .bold), - textAlign: TextAlign - .center, - ), - ], - )), + context: context, + builder: (context) { + return Center( + child: Material( + type: MaterialType.transparency, + child: Container( + decoration: BoxDecoration( + borderRadius: + BorderRadiusDirectional + .circular(10), + color: Colors.white, + ), + padding: EdgeInsets.all(15), + width: MediaQuery.of(context) + .size + .width * + 0.7, + height: 350, + child: Column( + crossAxisAlignment: + CrossAxisAlignment.center, + children: [ + ClipRRect( + borderRadius: + BorderRadius.circular(5), + child: Image.asset( + 'assets/main_assets/Completed.png', + width: 200, + height: 200, ), - ); - } - ) - ; + ), + // ignore: prefer_const_constructors + SizedBox(height: 10), + + // ignore: prefer_const_constructors + Text( + 'Thank You !!', + style: const TextStyle( + fontSize: 25, + color: Color.fromARGB( + 255, 137, 184, 189), + fontWeight: + FontWeight.bold), + ), + // ignore: prefer_const_constructors + SizedBox( + height: 10, + ), + // ignore: prefer_const_constructors + Text( + 'Thank You for giving your precious time', + style: const TextStyle( + fontSize: 20, + color: Color.fromARGB( + 255, 0, 10, 11), + fontWeight: + FontWeight.bold), + textAlign: TextAlign.center, + ), + ], + )), + ), + ); + }); }), child: const Text( 'Submit', diff --git a/lib/individual/user_chats_menu.dart b/lib/individual/user_chats_menu.dart index a1c0f27..d7d2177 100644 --- a/lib/individual/user_chats_menu.dart +++ b/lib/individual/user_chats_menu.dart @@ -3,7 +3,7 @@ import 'package:cura/shared/widgets/navigation-bar.dart'; import 'package:flutter/material.dart'; import 'package:cura/individual/home_page_individual.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -import '../shared/widgets/gradient_background.dart'; +import '../shared/widgets/gradient_background.dart' as shared; import 'package:cura/shared/services/stringScreenArguments.dart'; class UserChatsScreen extends StatefulWidget { @@ -66,7 +66,7 @@ class _UserChatsScreenState extends State { designSize: const Size(428, 926), builder: (context, child) => Stack( children: [ - const UniDirectionalBackground(), + const shared.UniDirectionalBackground(), SafeArea( child: Column( crossAxisAlignment: CrossAxisAlignment.center, @@ -89,7 +89,8 @@ class _UserChatsScreenState extends State { minLines: null, expands: true, decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 10.h), + contentPadding: EdgeInsets.symmetric( + horizontal: 20.w, vertical: 10.h), border: InputBorder.none, suffixIcon: IconButton( onPressed: () {}, @@ -171,7 +172,8 @@ class _ContactTileState extends State { }, onTap: () { Navigator.of(context).pushNamed(ChatScreen.routeName, - arguments: StringScreenArguments(nameProvided: widget.orgName, imgUrl: widget.imgUrl)); + arguments: StringScreenArguments( + nameProvided: widget.orgName, imgUrl: widget.imgUrl)); }, child: Container( height: 65.h, @@ -194,7 +196,8 @@ class _ContactTileState extends State { backgroundColor: Colors.transparent, child: Image( image: widget.imgUrl == '' - ? const AssetImage("assets/startup_assets/create_account_assets/profile_primary.png") + ? const AssetImage( + "assets/startup_assets/create_account_assets/profile_primary.png") : AssetImage(widget.imgUrl), ), ), diff --git a/lib/organization/org_chat_screen.dart b/lib/organization/org_chat_screen.dart index a5f8695..65fd03b 100644 --- a/lib/organization/org_chat_screen.dart +++ b/lib/organization/org_chat_screen.dart @@ -1,32 +1,13 @@ -import 'package:firebase_core/firebase_core.dart'; import 'package:cloud_firestore/cloud_firestore.dart'; +import 'package:cura/shared/widgets/gradient_background.dart'; import 'package:flutter/material.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -void main() async { - WidgetsFlutterBinding.ensureInitialized(); - await Firebase.initializeApp(); - runApp(MyApp()); -} - -class MyApp extends StatelessWidget { - @override - Widget build(BuildContext context) { - return MaterialApp( - title: 'Flutter Firebase Chat', - theme: ThemeData( - primarySwatch: Colors.blue, - visualDensity: VisualDensity.adaptivePlatformDensity, - ), - home: OrgChatScreen(userName: 'John Doe', imgUrl: ''), - ); - } -} - class OrgChatScreen extends StatefulWidget { static const String routeName = '/OrgChatScreen'; final String userName, imgUrl; - const OrgChatScreen({Key? key, required this.userName, required this.imgUrl}) : super(key: key); + const OrgChatScreen({Key? key, required this.userName, required this.imgUrl}) + : super(key: key); @override State createState() => _OrgChatScreenState(); @@ -34,7 +15,8 @@ class OrgChatScreen extends StatefulWidget { class _OrgChatScreenState extends State { final TextEditingController messageController = TextEditingController(); - final CollectionReference messagesCollection = FirebaseFirestore.instance.collection('messages'); + final CollectionReference messagesCollection = + FirebaseFirestore.instance.collection('messages'); final List months = [ "January", @@ -75,7 +57,8 @@ class _OrgChatScreenState extends State { ), Expanded( child: Container( - padding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), + padding: + EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.only( @@ -90,11 +73,13 @@ class _OrgChatScreenState extends State { return Text('Error: ${snapshot.error}'); } - if (snapshot.connectionState == ConnectionState.waiting) { + if (snapshot.connectionState == + ConnectionState.waiting) { return CircularProgressIndicator(); } - final List documents = snapshot.data!.docs; + final List documents = + snapshot.data!.docs; return ListView.builder( physics: const BouncingScrollPhysics(), @@ -105,7 +90,8 @@ class _OrgChatScreenState extends State { bool showDate = false; if (index == 0) { return DateMsgTile(convDate: document['date']); - } else if (index != documents.length - 1 && currentDate != documents[index + 1]['date']) { + } else if (index != documents.length - 1 && + currentDate != documents[index + 1]['date']) { showDate = true; return MessageWidget( isMe: document['isMe'], @@ -122,6 +108,7 @@ class _OrgChatScreenState extends State { time: document['time'], showDate: showDate, orgImgUrl: widget.imgUrl, + nextDate: '', ); }, ); @@ -145,7 +132,10 @@ class _OrgChatScreenState extends State { children: [ Transform.rotate( angle: 45.0 * 3.14159 / 180, - child: IconButton(onPressed: () {}, iconSize: 28.h, icon: const Icon(Icons.attach_file)), + child: IconButton( + onPressed: () {}, + iconSize: 28.h, + icon: const Icon(Icons.attach_file)), ), Expanded( child: TextField( @@ -168,10 +158,17 @@ class _OrgChatScreenState extends State { ), ), ), - IconButton(onPressed: () {}, iconSize: 28.h, icon: const Icon(Icons.add_photo_alternate)), - IconButton(onPressed: () {}, iconSize: 28.h, icon: const Icon(Icons.mic)), IconButton( - onPressed: () => sendMessage(messageController.text), + onPressed: () {}, + iconSize: 28.h, + icon: const Icon(Icons.add_photo_alternate)), + IconButton( + onPressed: () {}, + iconSize: 28.h, + icon: const Icon(Icons.mic)), + IconButton( + onPressed: () => + sendMessage(messageController.text), iconSize: 28.h, icon: const Icon(Icons.send), ), @@ -204,7 +201,8 @@ class _OrgChatScreenState extends State { radius: 30.w, child: Image( image: widget.imgUrl == "" - ? const AssetImage('assets/startup_assets/create_account_assets/profile_primary.png') + ? const AssetImage( + 'assets/startup_assets/create_account_assets/profile_primary.png') : AssetImage(widget.imgUrl), ), ), @@ -252,27 +250,6 @@ class _OrgChatScreenState extends State { } } -class UniDirectionalBackground extends StatelessWidget { - const UniDirectionalBackground({Key? key}) : super(key: key); - - @override - Widget build(BuildContext context) { - return Container( - height: 220.h, - decoration: const BoxDecoration( - gradient: LinearGradient( - colors: [ - Color(0xFF8E9EAB), - Color(0xFFeef2f3), - ], - begin: Alignment.topCenter, - end: Alignment.bottomCenter, - ), - ), - ); - } -} - class MessageWidget extends StatelessWidget { final bool isMe; final String msg, time; @@ -293,7 +270,8 @@ class MessageWidget extends StatelessWidget { @override Widget build(BuildContext context) { return Column( - crossAxisAlignment: isMe ? CrossAxisAlignment.end : CrossAxisAlignment.start, + crossAxisAlignment: + isMe ? CrossAxisAlignment.end : CrossAxisAlignment.start, children: [ if (showDate) Padding( @@ -301,7 +279,8 @@ class MessageWidget extends StatelessWidget { child: DateMsgTile(convDate: nextDate), ), Row( - mainAxisAlignment: isMe ? MainAxisAlignment.end : MainAxisAlignment.start, + mainAxisAlignment: + isMe ? MainAxisAlignment.end : MainAxisAlignment.start, children: [ if (!isMe) CircleAvatar( @@ -309,7 +288,8 @@ class MessageWidget extends StatelessWidget { radius: 22.w, child: Image( image: orgImgUrl == "" - ? AssetImage('assets/startup_assets/create_account_assets/profile_primary.png') + ? AssetImage( + 'assets/startup_assets/create_account_assets/profile_primary.png') : AssetImage(orgImgUrl), ), ), diff --git a/lib/organization/org_chats_menu.dart b/lib/organization/org_chats_menu.dart index 2cd7b12..22036b7 100644 --- a/lib/organization/org_chats_menu.dart +++ b/lib/organization/org_chats_menu.dart @@ -85,7 +85,8 @@ class _OrgChatsScreenState extends State { minLines: null, expands: true, decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 10.h), + contentPadding: EdgeInsets.symmetric( + horizontal: 20.w, vertical: 10.h), border: InputBorder.none, suffixIcon: IconButton( onPressed: () {}, @@ -167,7 +168,8 @@ class _ContactTileState extends State { }, onTap: () { Navigator.of(context).pushNamed(OrgChatScreen.routeName, - arguments: StringScreenArguments(nameProvided: widget.orgName, imgUrl: widget.imgUrl)); + arguments: StringScreenArguments( + nameProvided: widget.orgName, imgUrl: widget.imgUrl)); }, child: Container( height: 65.h, @@ -190,7 +192,8 @@ class _ContactTileState extends State { backgroundColor: Colors.transparent, child: Image( image: widget.imgUrl == '' - ? const AssetImage("assets/startup_assets/create_account_assets/profile_primary.png") + ? const AssetImage( + "assets/startup_assets/create_account_assets/profile_primary.png") : AssetImage(widget.imgUrl), ), ), diff --git a/lib/shared/services/firebase_database.dart b/lib/shared/services/firebase_database.dart index 7d1a5f7..e3db1fa 100644 --- a/lib/shared/services/firebase_database.dart +++ b/lib/shared/services/firebase_database.dart @@ -101,16 +101,14 @@ class FirestoreDatabase { .set(volunteerData); } - Future addPost(List images,String postText) async{ + Future addPost(List images, String postText) async { try { final currentUserUid = _auth.getCurrentUser()!.uid; Map data = await getIndividualProfileData(currentUserUid); List imagesUrl = []; for (final imgFile in images) { - imagesUrl.add( - await Storage().postFile(imgFile, - 'postImages/${data['individualEmail']}${imgFile.hashCode}') - ); + imagesUrl.add(await Storage().postFile(imgFile, + 'postImages/${data['individualEmail']}${imgFile.hashCode}')); } Map postData = { @@ -123,9 +121,7 @@ class FirestoreDatabase { }; await _db.collection('posts/').add(postData); - } - catch(e) - { + } catch (e) { print(e); return; } @@ -134,7 +130,6 @@ class FirestoreDatabase { Stream getPostData() { return _db.collection('posts/').snapshots(); } -} Future spendtime(Map spendData) async { String? uid; diff --git a/linux/flutter/generated_plugin_registrant.cc b/linux/flutter/generated_plugin_registrant.cc index e71a16d..64a0ece 100644 --- a/linux/flutter/generated_plugin_registrant.cc +++ b/linux/flutter/generated_plugin_registrant.cc @@ -6,6 +6,10 @@ #include "generated_plugin_registrant.h" +#include void fl_register_plugins(FlPluginRegistry* registry) { + g_autoptr(FlPluginRegistrar) file_selector_linux_registrar = + fl_plugin_registry_get_registrar_for_plugin(registry, "FileSelectorPlugin"); + file_selector_plugin_register_with_registrar(file_selector_linux_registrar); } diff --git a/linux/flutter/generated_plugins.cmake b/linux/flutter/generated_plugins.cmake index 2e1de87..2db3c22 100644 --- a/linux/flutter/generated_plugins.cmake +++ b/linux/flutter/generated_plugins.cmake @@ -3,6 +3,7 @@ # list(APPEND FLUTTER_PLUGIN_LIST + file_selector_linux ) list(APPEND FLUTTER_FFI_PLUGIN_LIST diff --git a/macos/Flutter/Flutter-Debug.xcconfig b/macos/Flutter/Flutter-Debug.xcconfig index c2efd0b..4b81f9b 100644 --- a/macos/Flutter/Flutter-Debug.xcconfig +++ b/macos/Flutter/Flutter-Debug.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" #include "ephemeral/Flutter-Generated.xcconfig" diff --git a/macos/Flutter/Flutter-Release.xcconfig b/macos/Flutter/Flutter-Release.xcconfig index c2efd0b..5caa9d1 100644 --- a/macos/Flutter/Flutter-Release.xcconfig +++ b/macos/Flutter/Flutter-Release.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" #include "ephemeral/Flutter-Generated.xcconfig" diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift index b7c04fa..4b433bf 100644 --- a/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -6,16 +6,20 @@ import FlutterMacOS import Foundation import cloud_firestore +import file_selector_macos import firebase_auth import firebase_core +import firebase_messaging import firebase_storage -import sqflite import path_provider_foundation +import sqflite func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { FLTFirebaseFirestorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseFirestorePlugin")) + FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin")) FLTFirebaseAuthPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseAuthPlugin")) FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin")) + FLTFirebaseMessagingPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseMessagingPlugin")) FLTFirebaseStoragePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseStoragePlugin")) PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) SqflitePlugin.register(with: registry.registrar(forPlugin: "SqflitePlugin")) diff --git a/pubspec.lock b/pubspec.lock index ddaecb1..86abee4 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -5,10 +5,10 @@ packages: dependency: transitive description: name: _flutterfire_internals - sha256: "2f428053492f92303e42c9afa8e3a78ad1886760e7b594e2b5a6b6ee47376360" + sha256: d84d98f1992976775f83083523a34c5d22fea191eec3abb2bd09537fb623c2e0 url: "https://pub.dev" source: hosted - version: "1.0.2" + version: "1.3.7" anim_search_bar: dependency: "direct main" description: @@ -37,10 +37,10 @@ packages: dependency: transitive description: name: async - sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 + sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" url: "https://pub.dev" source: hosted - version: "2.10.0" + version: "2.11.0" boolean_selector: dependency: transitive description: @@ -48,26 +48,29 @@ packages: sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.1.1" cached_network_image: dependency: "direct main" description: name: cached_network_image - url: "https://pub.dartlang.org" + sha256: fd3d0dc1d451f9a252b32d95d3f0c3c487bc41a75eba2e6097cb0b9c71491b15 + url: "https://pub.dev" source: hosted version: "3.2.3" cached_network_image_platform_interface: dependency: transitive description: name: cached_network_image_platform_interface - url: "https://pub.dartlang.org" + sha256: bb2b8403b4ccdc60ef5f25c70dead1f3d32d24b9d6117cfc087f496b178594a7 + url: "https://pub.dev" source: hosted version: "2.0.0" cached_network_image_web: dependency: transitive description: name: cached_network_image_web - url: "https://pub.dartlang.org" + sha256: b8eb814ebfcb4dea049680f8c1ffb2df399e4d03bf7a352c775e26fa06e02fa0 + url: "https://pub.dev" source: hosted version: "1.0.2" carousel_slider: @@ -82,10 +85,10 @@ packages: dependency: transitive description: name: characters - sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c + sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" url: "https://pub.dev" source: hosted - version: "1.2.1" + version: "1.3.0" checked_yaml: dependency: transitive description: @@ -114,34 +117,34 @@ packages: dependency: "direct main" description: name: cloud_firestore - sha256: "9194bf1845ee073bea64ec94e72c9dcf5d15f755e96496d8ccfee9def38b666f" + sha256: "1179ae4c69e2ea18179d844d70fc6ed2f082a2bbeb7fa62d35a2a24e2992bd4d" url: "https://pub.dev" source: hosted - version: "3.5.1" + version: "4.9.3" cloud_firestore_platform_interface: dependency: transitive description: name: cloud_firestore_platform_interface - sha256: d023142c18c28b2610c23c196e829c96976569cc2aa2f8e45328ae8a64c428d1 + sha256: acdcf0743bbdd0e6b342f3d2033e15d260a2c6f9434dd34b008b8f1c35e62b23 url: "https://pub.dev" source: hosted - version: "5.7.7" + version: "5.16.2" cloud_firestore_web: dependency: transitive description: name: cloud_firestore_web - sha256: "3d7d4fa8c1dc5a1f7cb33985ae0ab9924d33d76d4959fe26aed84b7d282887e3" + sha256: "321bb0732c8d782a49aede96805e59609e05cf98b6c34370faa04103f46a4a3a" url: "https://pub.dev" source: hosted - version: "2.8.10" + version: "3.7.2" collection: dependency: transitive description: name: collection - sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 + sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 url: "https://pub.dev" source: hosted - version: "1.17.0" + version: "1.17.2" convert: dependency: transitive description: @@ -214,78 +217,134 @@ packages: url: "https://pub.dev" source: hosted version: "5.2.6" + file_selector_linux: + dependency: transitive + description: + name: file_selector_linux + sha256: "045d372bf19b02aeb69cacf8b4009555fb5f6f0b7ad8016e5f46dd1387ddd492" + url: "https://pub.dev" + source: hosted + version: "0.9.2+1" + file_selector_macos: + dependency: transitive + description: + name: file_selector_macos + sha256: b15c3da8bd4908b9918111fa486903f5808e388b8d1c559949f584725a6594d6 + url: "https://pub.dev" + source: hosted + version: "0.9.3+3" + file_selector_platform_interface: + dependency: transitive + description: + name: file_selector_platform_interface + sha256: "0aa47a725c346825a2bd396343ce63ac00bda6eff2fbc43eabe99737dede8262" + url: "https://pub.dev" + source: hosted + version: "2.6.1" + file_selector_windows: + dependency: transitive + description: + name: file_selector_windows + sha256: d3547240c20cabf205c7c7f01a50ecdbc413755814d6677f3cb366f04abcead0 + url: "https://pub.dev" + source: hosted + version: "0.9.3+1" firebase_auth: dependency: "direct main" description: name: firebase_auth - sha256: ca3034d35d6ca894487ec80aa1162a135fef7c5d0abef8154789cbeea3a6deaf + sha256: "95c74884ff25eafcbbbcd5506b738e68ee98ff54d09522a6092a2fb95d02ee7a" url: "https://pub.dev" source: hosted - version: "3.11.2" + version: "4.10.1" firebase_auth_platform_interface: dependency: transitive description: name: firebase_auth_platform_interface - sha256: ab20ecbc411726e139250a49fa03fe1ae0105fd990c5330b2a148ec08dfb140b + sha256: "05d2636673e145d2b5eccc452c009808af4c15e8b402f34bb8fec63f2c76e86b" url: "https://pub.dev" source: hosted - version: "6.10.1" + version: "6.19.1" firebase_auth_web: dependency: transitive description: name: firebase_auth_web - sha256: bbe4f4fffcc378ca05c3d8ff33853be86dd27d0fafc85a953acaf5190531b6f9 + sha256: "4b8374da5d8969f99453ebd65074c1d379fe781bb3680fa7f65a4d3ac4ec87b3" url: "https://pub.dev" source: hosted - version: "4.6.1" + version: "5.8.2" firebase_core: dependency: "direct main" description: name: firebase_core - sha256: "4f1d7c13a909e82ff026679c9b8493cdeb35a9c76bc46c42bf9e2240c9e57e80" + sha256: "95580fa07c8ca3072a2bb1fecd792616a33f8683477d25b7d29d3a6a399e6ece" url: "https://pub.dev" source: hosted - version: "1.24.0" + version: "2.17.0" firebase_core_platform_interface: dependency: "direct main" description: name: firebase_core_platform_interface - sha256: b51257a8b4388565cd66062d727d3e60067b5f5cc3390eb0ecd20b8f97741bdb + sha256: b63e3be6c96ef5c33bdec1aab23c91eb00696f6452f0519401d640938c94cba2 url: "https://pub.dev" source: hosted - version: "4.5.1" + version: "4.8.0" firebase_core_web: dependency: transitive description: name: firebase_core_web - sha256: "839f1b48032a61962792cea1225fae030d4f27163867f181d6d2072dd40acbee" + sha256: e8c408923cd3a25bd342c576a114f2126769cd1a57106a4edeaa67ea4a84e962 + url: "https://pub.dev" + source: hosted + version: "2.8.0" + firebase_messaging: + dependency: "direct main" + description: + name: firebase_messaging + sha256: "67f9d7c87457e71ad78ee81e332f232b8a24f7d5e338f8c958fa7d6e9e0e3636" + url: "https://pub.dev" + source: hosted + version: "14.6.9" + firebase_messaging_platform_interface: + dependency: transitive + description: + name: firebase_messaging_platform_interface + sha256: "8c7ced3201886ad7ba37f344c1468ccfc08abb3023922e0e5a016eaf38abb96c" + url: "https://pub.dev" + source: hosted + version: "4.5.8" + firebase_messaging_web: + dependency: transitive + description: + name: firebase_messaging_web + sha256: b601322bdb44e2fefe4cc7b85ef0dbb7a2479d4a7653a51340821cf8d60696b5 url: "https://pub.dev" source: hosted - version: "1.7.3" + version: "3.5.8" firebase_storage: dependency: "direct main" description: name: firebase_storage - sha256: "1fe46462c9632db0f62db5b9f1abcb8d4232a6d3e7098d745f5790b71dedc822" + sha256: "4ceb092cd14c3bce0dc8cd4046754cd1e5e5c1977155e286b512b3f84fe1c03e" url: "https://pub.dev" source: hosted - version: "10.3.11" + version: "11.2.8" firebase_storage_platform_interface: dependency: transitive description: name: firebase_storage_platform_interface - sha256: a4a1bed8764baf9b6d377d9870ebb2c65e13a38bc813cfaaf0ac2a37d422bcdd + sha256: "88f8b8bb7181eef125536297f11b28171f59d2f53a59610e3966c2e38be3de4c" url: "https://pub.dev" source: hosted - version: "4.1.19" + version: "4.4.7" firebase_storage_web: dependency: transitive description: name: firebase_storage_web - sha256: "791516c9170ab6643282807913cf89ebb950d66206eb92ed154a847438047587" + sha256: bd05589cf17a8d5e2a90bdffcdab434c97e27bc37ca0056bfa90accf0366a7b0 url: "https://pub.dev" source: hosted - version: "3.3.9" + version: "3.6.8" flutter: dependency: "direct main" description: flutter @@ -295,31 +354,34 @@ packages: dependency: transitive description: name: flutter_blurhash - url: "https://pub.dartlang.org" + sha256: "05001537bd3fac7644fa6558b09ec8c0a3f2eba78c0765f88912882b1331a5c6" + url: "https://pub.dev" source: hosted version: "0.7.0" flutter_cache_manager: dependency: transitive description: name: flutter_cache_manager - url: "https://pub.dartlang.org" + sha256: "32cd900555219333326a2d0653aaaf8671264c29befa65bbd9856d204a4c9fb3" + url: "https://pub.dev" source: hosted version: "3.3.0" flutter_image_compress: dependency: transitive description: name: flutter_image_compress - url: "https://pub.dartlang.org" + sha256: "37f1b26399098e5f97b74c1483f534855e7dff68ead6ddaccf747029fb03f29f" + url: "https://pub.dev" source: hosted version: "1.1.3" flutter_launcher_icons: dependency: "direct dev" description: name: flutter_launcher_icons - sha256: a9de6706cd844668beac27c0aed5910fa0534832b3c2cad61a5fd977fce82a5d + sha256: ce0e501cfc258907842238e4ca605e74b7fd1cdf04b3b43e86c43f3e40a1592c url: "https://pub.dev" source: hosted - version: "0.10.0" + version: "0.11.0" flutter_lints: dependency: "direct dev" description: @@ -382,50 +444,74 @@ packages: dependency: "direct main" description: name: image_picker - sha256: "64b21d9f0e065f9ab0e4dde458076226c97382cc0c6949144cb874c62bf8e9f8" + sha256: "7d7f2768df2a8b0a3cefa5ef4f84636121987d403130e70b17ef7e2cf650ba84" url: "https://pub.dev" source: hosted - version: "0.8.7" + version: "1.0.4" image_picker_android: dependency: transitive description: name: image_picker_android - sha256: b81db5f5ed8a69d54d5f0932c2af8120e8c0518a037d8beee494eec671da4d4c + sha256: "0c7b83bbe2980c8a8e36e974f055e11e51675784e13a4762889feed0f3937ff2" url: "https://pub.dev" source: hosted - version: "0.8.6+5" + version: "0.8.8+1" image_picker_for_web: dependency: transitive description: name: image_picker_for_web - sha256: "98f50d6b9f294c8ba35e25cc0d13b04bfddd25dbc8d32fa9d566a6572f2c081c" + sha256: "50bc9ae6a77eea3a8b11af5eb6c661eeb858fdd2f734c2a4fd17086922347ef7" url: "https://pub.dev" source: hosted - version: "2.1.12" + version: "3.0.1" image_picker_ios: dependency: transitive description: name: image_picker_ios - sha256: "50e882fe0a06bf0c8f7f5bce78d30975f279213293afc9471dc35f05617c50ff" + sha256: c5538cacefacac733c724be7484377923b476216ad1ead35a0d2eadcdc0fc497 url: "https://pub.dev" source: hosted - version: "0.8.7+1" + version: "0.8.8+2" + image_picker_linux: + dependency: transitive + description: + name: image_picker_linux + sha256: "4ed1d9bb36f7cd60aa6e6cd479779cc56a4cb4e4de8f49d487b1aaad831300fa" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" + image_picker_macos: + dependency: transitive + description: + name: image_picker_macos + sha256: "3f5ad1e8112a9a6111c46d0b57a7be2286a9a07fc6e1976fdf5be2bd31d4ff62" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" image_picker_platform_interface: dependency: transitive description: name: image_picker_platform_interface - sha256: "1991219d9dbc42a99aff77e663af8ca51ced592cd6685c9485e3458302d3d4f8" + sha256: ed9b00e63977c93b0d2d2b343685bed9c324534ba5abafbb3dfbd6a780b1b514 url: "https://pub.dev" source: hosted - version: "2.6.3" + version: "2.9.1" + image_picker_windows: + dependency: transitive + description: + name: image_picker_windows + sha256: "6ad07afc4eb1bc25f3a01084d28520496c4a3bb0cb13685435838167c9dcedeb" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" intl: dependency: "direct main" description: name: intl - sha256: "910f85bce16fb5c6f614e117efa303e85a1731bb0081edf3604a2ae6e9a3cc91" + sha256: "3bc132a9dbce73a7e4a21a17d06e1878839ffbf975568bc875c60537824b0c4d" url: "https://pub.dev" source: hosted - version: "0.17.0" + version: "0.18.1" js: dependency: transitive description: @@ -454,26 +540,26 @@ packages: dependency: transitive description: name: matcher - sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" + sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" url: "https://pub.dev" source: hosted - version: "0.12.13" + version: "0.12.16" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 + sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" url: "https://pub.dev" source: hosted - version: "0.2.0" + version: "0.5.0" meta: dependency: transitive description: name: meta - sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" + sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" url: "https://pub.dev" source: hosted - version: "1.8.0" + version: "1.9.1" mime: dependency: transitive description: @@ -481,29 +567,31 @@ packages: sha256: e4ff8e8564c03f255408decd16e7899da1733852a9110a58fe6d1b817684a63e url: "https://pub.dev" source: hosted - version: "1.0.2" + version: "1.0.4" octo_image: dependency: transitive description: name: octo_image - url: "https://pub.dartlang.org" + sha256: "107f3ed1330006a3bea63615e81cf637433f5135a52466c7caa0e7152bca9143" + url: "https://pub.dev" source: hosted version: "1.0.2" optimized_cached_image: dependency: "direct main" description: name: optimized_cached_image - url: "https://pub.dartlang.org" + sha256: "9761aee196cdea172c5643245416c08bfcc8b94f35464af8c7462e2bab7c0b7f" + url: "https://pub.dev" source: hosted version: "3.0.1" path: dependency: transitive description: name: path - sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b + sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" url: "https://pub.dev" source: hosted - version: "1.8.2" + version: "1.8.3" path_provider: dependency: transitive description: @@ -548,7 +636,7 @@ packages: dependency: transitive description: name: path_provider_windows - sha256: f53720498d5a543f9607db4b0e997c4b5438884de25b0f73098cc2671a51b130 + sha256: bcabbe399d4042b8ee687e17548d5d3f527255253b4a639f5f8d2094a9c2b45c url: "https://pub.dev" source: hosted version: "2.1.3" @@ -556,7 +644,8 @@ packages: dependency: transitive description: name: pedantic - url: "https://pub.dartlang.org" + sha256: "67fc27ed9639506c856c840ccce7594d0bdcd91bc8d53d6e52359449a1d50602" + url: "https://pub.dev" source: hosted version: "1.11.1" petitparser: @@ -603,17 +692,18 @@ packages: dependency: transitive description: name: rxdart - url: "https://pub.dartlang.org" + sha256: "0c7c0cedd93788d996e33041ffecda924cc54389199cde4e6a34b440f50044cb" + url: "https://pub.dev" source: hosted version: "0.27.7" searchfield: dependency: "direct main" description: name: searchfield - sha256: d6346f68da4db0da6bd4c8ad1bae7fda572b0363a665cb52b07e4bb09ef1e003 + sha256: ea1eccae9f6d07dbbfef0bf341dd93b22df453b939461c5473a0be6186f2d720 url: "https://pub.dev" source: hosted - version: "0.5.6" + version: "0.8.4" share: dependency: "direct main" description: @@ -647,29 +737,32 @@ packages: dependency: transitive description: name: source_span - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 + sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" url: "https://pub.dev" source: hosted - version: "1.9.0" + version: "1.10.0" sprintf: dependency: transitive description: name: sprintf - url: "https://pub.dartlang.org" + sha256: ec76d38910b6f1c854ce1353c62d37e7ef82b53dc5ab048c25400d35970776d1 + url: "https://pub.dev" source: hosted version: "6.0.2" sqflite: dependency: transitive description: name: sqflite - url: "https://pub.dartlang.org" + sha256: "2b1697c7b78576fdc722c358f16f62171bd56e92dc13422d9e44be3fc446c276" + url: "https://pub.dev" source: hosted version: "2.2.2" sqflite_common: dependency: transitive description: name: sqflite_common - url: "https://pub.dartlang.org" + sha256: "0c21a187d645aa65da5be6997c0c713eed61e049158870ae2de157e6897067ab" + url: "https://pub.dev" source: hosted version: "2.4.0+2" stack_trace: @@ -695,12 +788,13 @@ packages: sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" url: "https://pub.dev" source: hosted - version: "1.1.1" + version: "1.2.0" synchronized: dependency: transitive description: name: synchronized - url: "https://pub.dartlang.org" + sha256: "7b530acd9cb7c71b0019a1e7fa22c4105e675557a4400b6a401c71c5e0ade1ac" + url: "https://pub.dev" source: hosted version: "3.0.0+3" term_glyph: @@ -715,10 +809,10 @@ packages: dependency: transitive description: name: test_api - sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 + sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" url: "https://pub.dev" source: hosted - version: "0.4.16" + version: "0.6.0" typed_data: dependency: transitive description: @@ -731,7 +825,8 @@ packages: dependency: transitive description: name: uuid - url: "https://pub.dartlang.org" + sha256: "648e103079f7c64a36dc7d39369cabb358d377078a051d6ae2ad3aa539519313" + url: "https://pub.dev" source: hosted version: "3.0.7" vector_math: @@ -742,6 +837,14 @@ packages: url: "https://pub.dev" source: hosted version: "2.1.4" + web: + dependency: transitive + description: + name: web + sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 + url: "https://pub.dev" + source: hosted + version: "0.1.4-beta" win32: dependency: transitive description: @@ -775,5 +878,5 @@ packages: source: hosted version: "3.1.1" sdks: - dart: ">=2.18.0 <3.0.0" - flutter: ">=3.3.0" + dart: ">=3.1.0-185.0.dev <4.0.0" + flutter: ">=3.7.0" diff --git a/pubspec.yaml b/pubspec.yaml index 9e38372..c35bef8 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -29,26 +29,26 @@ environment: dependencies: anim_search_bar: ^2.0.2 carousel_slider: ^4.1.1 - cloud_firestore: ^3.4.4 + cloud_firestore: ^4.9.3 cupertino_icons: ^1.0.2 file_picker: ^5.0.1 - firebase_auth: ^3.6.2 - firebase_core: ^1.21.1 - firebase_storage: ^10.3.5 + firebase_auth: ^4.10.1 + firebase_core: ^2.17.0 + firebase_storage: ^11.2.8 flutter: sdk: flutter flutter_screenutil: ^5.5.3+2 - image_picker: ^0.8.5+3 - searchfield: ^0.5.3 + image_picker: ^1.0.4 + searchfield: ^0.8.4 smooth_page_indicator: ^1.0.0+2 - intl: ^0.17.0 + intl: ^0.18.1 favorite_button: ^0.0.4 share: ^2.0.4 social_share: ^2.2.1 cached_network_image: ^3.2.3 optimized_cached_image: ^3.0.1 - firebase_core_platform_interface: 4.5.1 - firebase_messaging: ^13.0.4 + firebase_core_platform_interface: ^4.8.0 + firebase_messaging: ^14.6.9 @@ -59,7 +59,7 @@ dev_dependencies: # activated in the `analysis_options.yaml` file located at the root of your # package. See that file for information about deactivating specific lint # rules and activating additional ones. - flutter_launcher_icons: "^0.10.0" + flutter_launcher_icons: ^0.11.0 flutter_lints: ^2.0.0 flutter_test: sdk: flutter diff --git a/windows/flutter/generated_plugin_registrant.cc b/windows/flutter/generated_plugin_registrant.cc index 8b6d468..5861e0f 100644 --- a/windows/flutter/generated_plugin_registrant.cc +++ b/windows/flutter/generated_plugin_registrant.cc @@ -6,6 +6,15 @@ #include "generated_plugin_registrant.h" +#include +#include +#include void RegisterPlugins(flutter::PluginRegistry* registry) { + FileSelectorWindowsRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FileSelectorWindows")); + FirebaseAuthPluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseAuthPluginCApi")); + FirebaseCorePluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseCorePluginCApi")); } diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake index b93c4c3..ce851e9 100644 --- a/windows/flutter/generated_plugins.cmake +++ b/windows/flutter/generated_plugins.cmake @@ -3,6 +3,9 @@ # list(APPEND FLUTTER_PLUGIN_LIST + file_selector_windows + firebase_auth + firebase_core ) list(APPEND FLUTTER_FFI_PLUGIN_LIST From e0b6cc4878d7b14524f5f603f1566e32d0137aec Mon Sep 17 00:00:00 2001 From: AnshumaliSuri Date: Thu, 5 Oct 2023 09:37:37 +0530 Subject: [PATCH 03/13] Remove redundant declaration of uniBack --- lib/individual/user_chat_screen.dart | 55 +++++++++++++--------------- lib/individual/user_chats_menu.dart | 4 +- 2 files changed, 27 insertions(+), 32 deletions(-) diff --git a/lib/individual/user_chat_screen.dart b/lib/individual/user_chat_screen.dart index 0a0f10b..d6d1716 100644 --- a/lib/individual/user_chat_screen.dart +++ b/lib/individual/user_chat_screen.dart @@ -6,7 +6,8 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; class ChatScreen extends StatefulWidget { static const String routeName = '/ChatScreen'; final String orgName, imgUrl; - const ChatScreen({Key? key, required this.orgName, required this.imgUrl}) : super(key: key); + const ChatScreen({Key? key, required this.orgName, required this.imgUrl}) + : super(key: key); @override State createState() => _ChatScreenState(); @@ -37,8 +38,11 @@ class _ChatScreenState extends State { } Future loadMessages() async { - final querySnapshot = await FirebaseFirestore.instance.collection('messages').get(); - msgList = querySnapshot.docs.map((doc) => doc.data() as Map).toList(); + final querySnapshot = + await FirebaseFirestore.instance.collection('messages').get(); + msgList = querySnapshot.docs + .map((doc) => doc.data() as Map) + .toList(); setState(() {}); } @@ -66,7 +70,8 @@ class _ChatScreenState extends State { ), Expanded( child: Container( - padding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), + padding: + EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.only( @@ -84,7 +89,8 @@ class _ChatScreenState extends State { return DateMsgTile( convDate: msgList[0]['date'], ); - } else if (index != msgList.length - 1 && currentDate != msgList[index + 1]['date']) { + } else if (index != msgList.length - 1 && + currentDate != msgList[index + 1]['date']) { showDate = true; return MessageWidget( isMe: msgList[index]['isMe'], @@ -166,11 +172,16 @@ class _ChatScreenState extends State { String meridian = hour < 11 ? "am" : "pm"; hour = hour % 11; hour = hour == 0 ? 12 : hour - 1; - String timeInHours = hour < 10 ? "0$hour" : hour.toString(); + String timeInHours = + hour < 10 ? "0$hour" : hour.toString(); int minutes = time.minute; - String minute = minutes < 10 ? "0$minutes" : minutes.toString(); + String minute = minutes < 10 + ? "0$minutes" + : minutes.toString(); String month = months[time.month - 1]; - await FirebaseFirestore.instance.collection('messages').add({ + await FirebaseFirestore.instance + .collection('messages') + .add({ 'msg': messageController.text.trim(), 'isMe': true, 'time': "$timeInHours:$minute $meridian", @@ -212,7 +223,8 @@ class _ChatScreenState extends State { radius: 30.w, child: Image( image: widget.imgUrl == "" - ? const AssetImage('assets/startup_assets/create_account_assets/profile_primary.png') + ? const AssetImage( + 'assets/startup_assets/create_account_assets/profile_primary.png') : AssetImage(widget.imgUrl), ), ), @@ -286,7 +298,8 @@ class MessageWidget extends StatelessWidget { @override Widget build(BuildContext context) { return Column( - crossAxisAlignment: isMe ? CrossAxisAlignment.end : CrossAxisAlignment.start, + crossAxisAlignment: + isMe ? CrossAxisAlignment.end : CrossAxisAlignment.start, children: [ if (showDate) DateMsgTile( @@ -327,29 +340,11 @@ class MessageWidget extends StatelessWidget { } } -class UniDirectionalBackground extends StatelessWidget { - const UniDirectionalBackground({Key? key}) : super(key: key); - - @override - Widget build(BuildContext context) { - return GradientBackground( - gradientColor: const LinearGradient( - colors: [ - Color(0xFF92B7C0), - Color(0xFFA8CEBF), - Color(0xFFCCE7BA), - ], - begin: Alignment.topCenter, - end: Alignment.bottomCenter, - ), - ); - } -} - class GradientBackground extends StatelessWidget { final Gradient gradientColor; - const GradientBackground({Key? key, required this.gradientColor}) : super(key: key); + const GradientBackground({Key? key, required this.gradientColor}) + : super(key: key); @override Widget build(BuildContext context) { diff --git a/lib/individual/user_chats_menu.dart b/lib/individual/user_chats_menu.dart index d7d2177..0421534 100644 --- a/lib/individual/user_chats_menu.dart +++ b/lib/individual/user_chats_menu.dart @@ -3,7 +3,7 @@ import 'package:cura/shared/widgets/navigation-bar.dart'; import 'package:flutter/material.dart'; import 'package:cura/individual/home_page_individual.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -import '../shared/widgets/gradient_background.dart' as shared; +import '../shared/widgets/gradient_background.dart'; import 'package:cura/shared/services/stringScreenArguments.dart'; class UserChatsScreen extends StatefulWidget { @@ -66,7 +66,7 @@ class _UserChatsScreenState extends State { designSize: const Size(428, 926), builder: (context, child) => Stack( children: [ - const shared.UniDirectionalBackground(), + const UniDirectionalBackground(), SafeArea( child: Column( crossAxisAlignment: CrossAxisAlignment.center, From 8f0ffda2105cffe7c82bfc41fa5f84283230e326 Mon Sep 17 00:00:00 2001 From: ShubhamTiwari55 Date: Mon, 9 Oct 2023 17:23:17 +0530 Subject: [PATCH 04/13] Donation page Ui enchanced --- lib/individual/donation_page.dart | 3 +- pubspec.lock | 46 +++++++++++++------------------ 2 files changed, 21 insertions(+), 28 deletions(-) diff --git a/lib/individual/donation_page.dart b/lib/individual/donation_page.dart index 1c3c8c9..aa73161 100644 --- a/lib/individual/donation_page.dart +++ b/lib/individual/donation_page.dart @@ -137,7 +137,7 @@ class _DonationPageState extends State { ), borderRadius: BorderRadius.circular(30)), width: double.infinity, - height: 200.sp, + height: 360.sp, child: SingleChildScrollView( physics: const BouncingScrollPhysics(), scrollDirection: Axis.vertical, @@ -424,6 +424,7 @@ class _DonationPageState extends State { child: Text( "Continue", style: TextStyle( + color: Colors.white, fontSize: 20.sp, fontWeight: FontWeight.w700), diff --git a/pubspec.lock b/pubspec.lock index 86abee4..88b8966 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -37,10 +37,10 @@ packages: dependency: transitive description: name: async - sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" + sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 url: "https://pub.dev" source: hosted - version: "2.11.0" + version: "2.10.0" boolean_selector: dependency: transitive description: @@ -85,10 +85,10 @@ packages: dependency: transitive description: name: characters - sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" + sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c url: "https://pub.dev" source: hosted - version: "1.3.0" + version: "1.2.1" checked_yaml: dependency: transitive description: @@ -141,10 +141,10 @@ packages: dependency: transitive description: name: collection - sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 + sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 url: "https://pub.dev" source: hosted - version: "1.17.2" + version: "1.17.0" convert: dependency: transitive description: @@ -540,26 +540,26 @@ packages: dependency: transitive description: name: matcher - sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" + sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" url: "https://pub.dev" source: hosted - version: "0.12.16" + version: "0.12.13" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" + sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 url: "https://pub.dev" source: hosted - version: "0.5.0" + version: "0.2.0" meta: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.8.0" mime: dependency: transitive description: @@ -588,10 +588,10 @@ packages: dependency: transitive description: name: path - sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" + sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b url: "https://pub.dev" source: hosted - version: "1.8.3" + version: "1.8.2" path_provider: dependency: transitive description: @@ -737,10 +737,10 @@ packages: dependency: transitive description: name: source_span - sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" + sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 url: "https://pub.dev" source: hosted - version: "1.10.0" + version: "1.9.1" sprintf: dependency: transitive description: @@ -809,10 +809,10 @@ packages: dependency: transitive description: name: test_api - sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" + sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 url: "https://pub.dev" source: hosted - version: "0.6.0" + version: "0.4.16" typed_data: dependency: transitive description: @@ -837,14 +837,6 @@ packages: url: "https://pub.dev" source: hosted version: "2.1.4" - web: - dependency: transitive - description: - name: web - sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 - url: "https://pub.dev" - source: hosted - version: "0.1.4-beta" win32: dependency: transitive description: @@ -878,5 +870,5 @@ packages: source: hosted version: "3.1.1" sdks: - dart: ">=3.1.0-185.0.dev <4.0.0" + dart: ">=2.19.0 <3.0.0" flutter: ">=3.7.0" From a4d8f07fffa119e6ee878e930edf84040aafdcc0 Mon Sep 17 00:00:00 2001 From: ShubhamTiwari55 Date: Mon, 9 Oct 2023 17:56:17 +0530 Subject: [PATCH 05/13] Search box UI/UX enhanced --- lib/individual/home_page_individual.dart | 88 +++++++++++++----------- 1 file changed, 47 insertions(+), 41 deletions(-) diff --git a/lib/individual/home_page_individual.dart b/lib/individual/home_page_individual.dart index 3614bb5..28e03d8 100644 --- a/lib/individual/home_page_individual.dart +++ b/lib/individual/home_page_individual.dart @@ -9,7 +9,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter/material.dart'; import '../shared/services/firebase_authentication.dart'; -//This is a temporary Home Screen, to be used for testing purposes +// This is a temporary Home Screen, to be used for testing purposes class HomePageIndividual extends StatefulWidget { static const String routeName = '/HomePageIndividual'; const HomePageIndividual({Key? key}) : super(key: key); @@ -51,7 +51,7 @@ class _HomePageIndividualState extends State { TextEditingController searchController = TextEditingController(); return ScreenUtilInit( - designSize: const Size(428, 926), + designSize: const Size(428, 900), builder: (context, child) => Scaffold( bottomNavigationBar: const CustomNavigationBar(currentIndex: 0), extendBodyBehindAppBar: true, @@ -65,17 +65,18 @@ class _HomePageIndividualState extends State { children: [ Image( image: const AssetImage("assets/Mobile life-amico 2.png"), - height: 300.h, + height: 280.h, width: double.infinity, ), Padding( - padding: EdgeInsets.symmetric(horizontal: 8.w), + padding: EdgeInsets.symmetric(horizontal: 5.w), child: Container( - height: 45.h, + height: 50.h, decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(30.r), - boxShadow: const [BoxShadow(blurRadius: 5.0, offset: Offset(0, 3), color: Colors.grey)]), + color: Colors.white, + borderRadius: BorderRadius.circular(30.r), + boxShadow: const [BoxShadow(blurRadius: 5.0, offset: Offset(0, 2), color: Colors.grey)], + ), child: TextField( controller: searchController, keyboardType: TextInputType.text, @@ -83,8 +84,9 @@ class _HomePageIndividualState extends State { minLines: null, expands: true, decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 10.h), + contentPadding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 15.h), // Adjust vertical padding border: InputBorder.none, + hintText: 'Search here...', // Add the hintText here suffixIcon: IconButton( onPressed: () {}, icon: const Icon( @@ -95,7 +97,7 @@ class _HomePageIndividualState extends State { ), style: TextStyle( color: Colors.black, - fontSize: 10.sp, + fontSize: 18.sp, // Increase the font size here (adjust as needed) fontWeight: FontWeight.w400, ), ), @@ -105,20 +107,22 @@ class _HomePageIndividualState extends State { height: 30.h, ), Expanded( - child: ListView.separated( - physics: const BouncingScrollPhysics(), - itemCount: imgUrls.length, - itemBuilder: ((context, index) { - return HomePageContent( - imgUrl: imgUrls[index], - heading: headings[index], - subHeading: subHeadings[index], - index: index, - widget: navRoutes[index], - isOdd: index % 2 == 0, - ); - }), - separatorBuilder: ((context, index) => SizedBox(height: 23.h)))) + child: ListView.separated( + physics: const BouncingScrollPhysics(), + itemCount: imgUrls.length, + itemBuilder: ((context, index) { + return HomePageContent( + imgUrl: imgUrls[index], + heading: headings[index], + subHeading: subHeadings[index], + index: index, + widget: navRoutes[index], + isOdd: index % 2 == 0, + ); + }), + separatorBuilder: ((context, index) => SizedBox(height: 23.h)), + ), + ), ], ), ), @@ -135,15 +139,15 @@ class HomePageContent extends StatelessWidget { final bool isOdd; final String widget; - const HomePageContent( - {Key? key, - required this.imgUrl, - required this.heading, - required this.subHeading, - required this.index, - required this.widget, - required this.isOdd}) - : super(key: key); + const HomePageContent({ + Key? key, + required this.imgUrl, + required this.heading, + required this.subHeading, + required this.index, + required this.widget, + required this.isOdd, + }) : super(key: key); @override Widget build(BuildContext context) { @@ -155,9 +159,10 @@ class HomePageContent extends StatelessWidget { height: 200.h, width: double.infinity, decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(25.r), - boxShadow: const [BoxShadow(blurRadius: 5, color: Colors.grey, offset: Offset(0, 3))]), + color: Colors.white, + borderRadius: BorderRadius.circular(25.r), + boxShadow: const [BoxShadow(blurRadius: 5, color: Colors.grey, offset: Offset(0, 3))], + ), child: Padding( padding: EdgeInsets.symmetric(horizontal: 10.w, vertical: 20.h), child: Row( @@ -176,7 +181,7 @@ class HomePageContent extends StatelessWidget { child: isOdd ? ImagePart(imgUrl: imgUrl, index: index) : TextPart(heading: heading, subHeading: subHeading), - ) + ), ], ), ), @@ -200,9 +205,10 @@ class ImagePart extends StatelessWidget { Widget build(BuildContext context) { return Container( decoration: BoxDecoration( - color: const Color(0xFFC7E2E4), - borderRadius: BorderRadius.circular(25.r), - boxShadow: const [BoxShadow(color: Color(0x55000000), offset: Offset(0, 2), blurRadius: 2.0)]), + color: const Color(0xFFC7E2E4), + borderRadius: BorderRadius.circular(25.r), + boxShadow: const [BoxShadow(color: Color(0x55000000), offset: Offset(0, 2), blurRadius: 2.0)], + ), child: Center( child: Image( image: AssetImage(imgUrl), @@ -236,7 +242,7 @@ class TextPart extends StatelessWidget { Text( subHeading, style: TextStyle(fontSize: 18.sp, color: const Color.fromRGBO(0, 0, 0, 0.58), fontWeight: FontWeight.w700), - ) + ), ], ); } From 74efc1068ba19b2453c8ff68c303cdf1538bb902 Mon Sep 17 00:00:00 2001 From: ShubhamTiwari55 Date: Mon, 9 Oct 2023 18:07:17 +0530 Subject: [PATCH 06/13] Search UI enhanced --- lib/individual/home_page_individual.dart | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/individual/home_page_individual.dart b/lib/individual/home_page_individual.dart index 28e03d8..f06577d 100644 --- a/lib/individual/home_page_individual.dart +++ b/lib/individual/home_page_individual.dart @@ -51,7 +51,7 @@ class _HomePageIndividualState extends State { TextEditingController searchController = TextEditingController(); return ScreenUtilInit( - designSize: const Size(428, 900), + designSize: const Size(428, 926), builder: (context, child) => Scaffold( bottomNavigationBar: const CustomNavigationBar(currentIndex: 0), extendBodyBehindAppBar: true, @@ -65,7 +65,7 @@ class _HomePageIndividualState extends State { children: [ Image( image: const AssetImage("assets/Mobile life-amico 2.png"), - height: 280.h, + height: 300.h, width: double.infinity, ), Padding( @@ -96,8 +96,8 @@ class _HomePageIndividualState extends State { ), ), style: TextStyle( - color: Colors.black, - fontSize: 18.sp, // Increase the font size here (adjust as needed) + color: Colors.blueGrey, + fontSize: 20.sp, // Increase the font size here (adjust as needed) fontWeight: FontWeight.w400, ), ), From 2efa2d87485746df81c3954c354d1c3bf9780bf7 Mon Sep 17 00:00:00 2001 From: ShubhamTiwari55 Date: Fri, 13 Oct 2023 11:12:07 +0530 Subject: [PATCH 07/13] Post feed page UI enhanced --- lib/organization/postfeed.dart | 30 +++++++++++++++++++++--------- 1 file changed, 21 insertions(+), 9 deletions(-) diff --git a/lib/organization/postfeed.dart b/lib/organization/postfeed.dart index 64ef14b..2323952 100644 --- a/lib/organization/postfeed.dart +++ b/lib/organization/postfeed.dart @@ -32,7 +32,7 @@ class _postfeedState extends State { textAlign: TextAlign.center, style: TextStyle( color: Colors.black, - fontSize: 25.w, + fontSize: 23.w, fontWeight: FontWeight.w500), softWrap: true, ), @@ -51,7 +51,7 @@ class _postfeedState extends State { padding: const EdgeInsets.symmetric(horizontal: 30.0), icon: const Icon( Icons.add_circle, - size: 45.0, + size: 36.0, color: Colors.white70, ), onPressed: () { @@ -127,7 +127,7 @@ class PostWidget extends StatelessWidget { return Column( children: [ Padding( - padding: EdgeInsets.symmetric(horizontal: 30.w), + padding: EdgeInsets.symmetric(horizontal: 30.w, vertical: 10), child: Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ @@ -137,8 +137,8 @@ class PostWidget extends StatelessWidget { image:CachedNetworkImageProvider(postData['userImgUrl'] != '' ? postData['userImgUrl'] : 'https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460__340.png',), - height: 45.h, - width: 45.w), + height: 43.h, + width: 40.w,), SizedBox( width: 10.w, ), @@ -171,19 +171,31 @@ class PostWidget extends StatelessWidget { SizedBox( height: 10.h, ), - postData["imagesUrl"].isEmpty?const SizedBox():Image(width:372.w,height:372.w,fit:BoxFit.cover,image:CachedNetworkImageProvider(postData["imagesUrl"][0])), + postData["imagesUrl"].isEmpty + ? SizedBox() + : ClipRRect( + borderRadius: BorderRadius.circular(10.0), // Adjust the radius as per your requirement + child: Image( + width: 360.w, + height: 360.w, + fit: BoxFit.cover, + image: CachedNetworkImageProvider(postData["imagesUrl"][0]), + ), + ), + Container( height: 50.h, - width: 372.w, + width: 360.w, decoration: BoxDecoration( color: Colors.white, + borderRadius: BorderRadius.circular(10), border: Border.all( color: Color(0xFF6CAFB4), )), child: Row(mainAxisAlignment: MainAxisAlignment.center, children: [ FavoriteButton( - iconSize: 60.r, + iconSize: 40, valueChanged: (_) {}, ), SizedBox( @@ -202,7 +214,7 @@ class PostWidget extends StatelessWidget { ]), ), SizedBox( - height: 5.h, + height: 10.h, ), Text( postData['postText'], From 3cc5b3216603a83ed66b5fdbb3512c55d9162e24 Mon Sep 17 00:00:00 2001 From: ShubhamTiwari55 Date: Sun, 15 Oct 2023 10:59:41 +0530 Subject: [PATCH 08/13] added required changes to post feed page --- lib/organization/postfeed.dart | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/lib/organization/postfeed.dart b/lib/organization/postfeed.dart index 2323952..6044f96 100644 --- a/lib/organization/postfeed.dart +++ b/lib/organization/postfeed.dart @@ -26,6 +26,7 @@ class _postfeedState extends State { builder: (context, child) => Scaffold( appBar: AppBar( centerTitle: true, + elevation: 0, backgroundColor: const Color(0xFF6CAFB4), title: Text( "Posts Feed", @@ -133,12 +134,17 @@ class PostWidget extends StatelessWidget { children: [ Row( children: [ - Image( - image:CachedNetworkImageProvider(postData['userImgUrl'] != '' - ? postData['userImgUrl'] - : 'https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460__340.png',), - height: 43.h, - width: 40.w,), + Padding( + padding: const EdgeInsets.all(5.0), + child: CircleAvatar( + radius: 25.w, // Adjust the radius as per your requirement + backgroundImage: CachedNetworkImageProvider( + postData['userImgUrl'] != '' + ? postData['userImgUrl'] + : 'https://cdn.pixabay.com/photo/2015/10/05/22/37/blank-profile-picture-973460__340.png', + ), + ), + ), SizedBox( width: 10.w, ), @@ -174,7 +180,10 @@ class PostWidget extends StatelessWidget { postData["imagesUrl"].isEmpty ? SizedBox() : ClipRRect( - borderRadius: BorderRadius.circular(10.0), // Adjust the radius as per your requirement + borderRadius: BorderRadius.only( + topLeft: Radius.circular(10.0), + topRight: Radius.circular(10.0), + ),// Adjust the radius as per your requirement child: Image( width: 360.w, height: 360.w, @@ -188,7 +197,10 @@ class PostWidget extends StatelessWidget { width: 360.w, decoration: BoxDecoration( color: Colors.white, - borderRadius: BorderRadius.circular(10), + borderRadius: BorderRadius.only( + bottomLeft: Radius.circular(10.0), + bottomRight: Radius.circular(10.0), + ), border: Border.all( color: Color(0xFF6CAFB4), )), From b9648c5f86f51f13946167955d640b66fdd064c4 Mon Sep 17 00:00:00 2001 From: Jayraj Date: Sat, 21 Oct 2023 11:03:57 +0530 Subject: [PATCH 09/13] Fixed the pixel overflow in the Post Feed Card on the HomeScreen --- android/build.gradle | 4 +- lib/individual/donation_page.dart | 56 ++- lib/individual/health.dart | 35 +- lib/individual/home_page_individual.dart | 82 ++-- lib/individual/spend_time.dart | 153 +++---- lib/individual/user_chats_menu.dart | 1 - lib/main.dart | 1 - lib/organization/org_chat_screen.dart | 94 ++--- lib/shared/services/firebase_database.dart | 15 +- linux/flutter/generated_plugin_registrant.cc | 4 + linux/flutter/generated_plugins.cmake | 1 + macos/Flutter/GeneratedPluginRegistrant.swift | 6 +- pubspec.lock | 389 +++++++++++------- pubspec.yaml | 24 +- .../flutter/generated_plugin_registrant.cc | 12 + windows/flutter/generated_plugins.cmake | 4 + 16 files changed, 499 insertions(+), 382 deletions(-) diff --git a/android/build.gradle b/android/build.gradle index d0f2b7f..ffe90b1 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -1,5 +1,5 @@ buildscript { - ext.kotlin_version = '1.6.10' + ext.kotlin_version = '1.9.10' repositories { google() mavenCentral() @@ -28,6 +28,6 @@ subprojects { project.evaluationDependsOn(':app') } -task clean(type: Delete) { +tasks.register("clean", Delete) { delete rootProject.buildDir } diff --git a/lib/individual/donation_page.dart b/lib/individual/donation_page.dart index 2ca364a..0c584d7 100644 --- a/lib/individual/donation_page.dart +++ b/lib/individual/donation_page.dart @@ -1,3 +1,5 @@ +// ignore_for_file: use_build_context_synchronously + import 'package:cura/shared/widgets/gradient_background.dart'; import 'package:flutter/material.dart'; @@ -43,6 +45,33 @@ class _DonationPageState extends State { @override Widget build(BuildContext context) { + List organizationAddress = [ + 'India', + 'United States', + 'America', + 'Washington', + 'Paris', + 'Jakarta', + 'Australia', + 'Lorem Ipsum' + ]; + + List newAddSuggestions = organizationAddress + .map((orgAdd) => SearchFieldListItem(orgAdd, item: orgName)) + .toList(); + + List organizationSuggestions = [ + 'Organisation 1', + 'Organisation 2', + 'Organisation 3', + 'Organisation 4', + 'Organisation 5', + 'Organisation 6', + ]; + + List newSuggestions = organizationSuggestions + .map((orgName) => SearchFieldListItem(orgName, item: orgName)) + .toList(); return ScreenUtilInit( designSize: const Size(428, 926), builder: (context, child) => Scaffold( @@ -108,7 +137,7 @@ class _DonationPageState extends State { ), borderRadius: BorderRadius.circular(30)), width: double.infinity, - height: 200.sp, + height: 360.sp, child: SingleChildScrollView( physics: const BouncingScrollPhysics(), scrollDirection: Axis.vertical, @@ -178,14 +207,7 @@ class _DonationPageState extends State { padding: EdgeInsets.fromLTRB(30.w, 0, 30.w, 0), child: SearchField( hint: " Enter organisation's name", - suggestions: const [ - 'Organisation 1', - 'Organisation 2', - 'Organisation 3', - 'Organisation 4', - 'Organisation 5', - 'Organisation 6', - ], + suggestions: newSuggestions, searchInputDecoration: InputDecoration( enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -230,16 +252,7 @@ class _DonationPageState extends State { padding: EdgeInsets.fromLTRB(30.w, 0, 30.w, 0), child: SearchField( hint: "Enter Organisation's Address", - suggestions: const [ - 'India', - 'United States', - 'America', - 'Washington', - 'Paris', - 'Jakarta', - 'Australia', - 'Lorem Ipsum' - ], + suggestions: newAddSuggestions, searchInputDecoration: InputDecoration( enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -359,7 +372,7 @@ class _DonationPageState extends State { BorderRadiusDirectional.circular(10), color: Colors.white, ), - padding: EdgeInsets.all(15), + padding: const EdgeInsets.all(15), width: MediaQuery.of(context).size.width * 0.7, height: 350, @@ -411,6 +424,7 @@ class _DonationPageState extends State { child: Text( "Continue", style: TextStyle( + color: Colors.white, fontSize: 20.sp, fontWeight: FontWeight.w700), @@ -427,4 +441,4 @@ class _DonationPageState extends State { ), ); } -} +} \ No newline at end of file diff --git a/lib/individual/health.dart b/lib/individual/health.dart index 914f5fb..79e8d3b 100644 --- a/lib/individual/health.dart +++ b/lib/individual/health.dart @@ -1,11 +1,9 @@ import 'package:cloud_firestore/cloud_firestore.dart'; -import 'package:cura/shared/services/firebase_database.dart'; -import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/material.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:intl/intl.dart'; import 'package:searchfield/searchfield.dart'; -import 'package:cura/shared/widgets/navigation-bar.dart'; + class HealthPage extends StatefulWidget { static const String routeName = '/HealthPage'; @@ -27,6 +25,18 @@ class _HealthPageState extends State { CollectionReference user = FirebaseFirestore.instance.collection('user'); @override Widget build(BuildContext context) { + List organizationSuggestions = [ + 'Organisation 1', + 'Organisation 2', + 'Organisation 3', + 'Organisation 4', + 'Organisation 5', + 'Organisation 6', + ]; + + List newSuggestions = organizationSuggestions + .map((orgName) => SearchFieldListItem(orgName, item: orgName)) + .toList(); return ScreenUtilInit( designSize: const Size(428, 926), builder: (context, child) => Scaffold( @@ -108,14 +118,7 @@ class _HealthPageState extends State { EdgeInsets.fromLTRB(15.w, 0, 15.w, 0), child: SearchField( hint: "Enter Organization's name", - suggestions: const [ - 'organization 1', - 'organization 2', - 'organization 3', - 'organization 4', - 'organization 5', - 'organization 6', - ], + suggestions: newSuggestions, searchInputDecoration: InputDecoration( // ignore: prefer_const_constructors contentPadding: EdgeInsets.only( @@ -203,7 +206,9 @@ class _HealthPageState extends State { lastDate: DateTime(2101)); if (pickeddate != null) { setState(() { - _date.text = DateFormat('yyyy-mm-dd').format(pickeddate); + _date.text = + DateFormat('yyyy-mm-dd') + .format(pickeddate); }); } }, @@ -425,9 +430,7 @@ class _HealthPageState extends State { )), ), ); - } - ) - ; + }); }, child: Text( "submit", @@ -448,4 +451,4 @@ class _HealthPageState extends State { ), )))); } -} +} \ No newline at end of file diff --git a/lib/individual/home_page_individual.dart b/lib/individual/home_page_individual.dart index 3614bb5..4a7951f 100644 --- a/lib/individual/home_page_individual.dart +++ b/lib/individual/home_page_individual.dart @@ -29,7 +29,13 @@ class _HomePageIndividualState extends State { "assets/Social share-bro 1.png" ]; - List headings = ["Adopt", "Health", "Donate", "Spend Time", "Posts Feed"]; + List headings = [ + "Adopt", + "Health", + "Donate", + "Spend Time", + "Posts Feed" + ]; List subHeadings = [ "Adopt an old person or a child", @@ -73,9 +79,16 @@ class _HomePageIndividualState extends State { child: Container( height: 45.h, decoration: BoxDecoration( - color: Colors.white, - borderRadius: BorderRadius.circular(30.r), - boxShadow: const [BoxShadow(blurRadius: 5.0, offset: Offset(0, 3), color: Colors.grey)]), + color: Colors.white, + borderRadius: BorderRadius.circular(30.r), + boxShadow: const [ + BoxShadow( + blurRadius: 5.0, + offset: Offset(0, 3), + color: Colors.grey, + ) + ], + ), child: TextField( controller: searchController, keyboardType: TextInputType.text, @@ -83,7 +96,8 @@ class _HomePageIndividualState extends State { minLines: null, expands: true, decoration: InputDecoration( - contentPadding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 10.h), + contentPadding: EdgeInsets.symmetric( + horizontal: 20.w, vertical: 10.h), border: InputBorder.none, suffixIcon: IconButton( onPressed: () {}, @@ -105,20 +119,23 @@ class _HomePageIndividualState extends State { height: 30.h, ), Expanded( - child: ListView.separated( - physics: const BouncingScrollPhysics(), - itemCount: imgUrls.length, - itemBuilder: ((context, index) { - return HomePageContent( - imgUrl: imgUrls[index], - heading: headings[index], - subHeading: subHeadings[index], - index: index, - widget: navRoutes[index], - isOdd: index % 2 == 0, - ); - }), - separatorBuilder: ((context, index) => SizedBox(height: 23.h)))) + child: ListView.separated( + physics: const BouncingScrollPhysics(), + itemCount: imgUrls.length, + itemBuilder: ((context, index) { + return HomePageContent( + imgUrl: imgUrls[index], + heading: headings[index], + subHeading: subHeadings[index], + index: index, + widget: navRoutes[index], + isOdd: index % 2 == 0, + ); + }), + separatorBuilder: ((context, index) => + SizedBox(height: 23.h)), + ), + ), ], ), ), @@ -157,7 +174,10 @@ class HomePageContent extends StatelessWidget { decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.circular(25.r), - boxShadow: const [BoxShadow(blurRadius: 5, color: Colors.grey, offset: Offset(0, 3))]), + boxShadow: const [ + BoxShadow( + blurRadius: 5, color: Colors.grey, offset: Offset(0, 3)) + ]), child: Padding( padding: EdgeInsets.symmetric(horizontal: 10.w, vertical: 20.h), child: Row( @@ -202,7 +222,10 @@ class ImagePart extends StatelessWidget { decoration: BoxDecoration( color: const Color(0xFFC7E2E4), borderRadius: BorderRadius.circular(25.r), - boxShadow: const [BoxShadow(color: Color(0x55000000), offset: Offset(0, 2), blurRadius: 2.0)]), + boxShadow: const [ + BoxShadow( + color: Color(0x55000000), offset: Offset(0, 2), blurRadius: 2.0) + ]), child: Center( child: Image( image: AssetImage(imgUrl), @@ -227,15 +250,26 @@ class TextPart extends StatelessWidget { Widget build(BuildContext context) { return Column( crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.end, + mainAxisAlignment: MainAxisAlignment.start, children: [ Text( heading, - style: TextStyle(fontSize: 32.sp, fontWeight: FontWeight.w700, color: const Color(0xFF92B7C0)), + style: TextStyle( + fontSize: 28.sp, + fontWeight: FontWeight.w700, + color: const Color(0xFF92B7C0), + ), + ), + const SizedBox( + height: 8, ), Text( subHeading, - style: TextStyle(fontSize: 18.sp, color: const Color.fromRGBO(0, 0, 0, 0.58), fontWeight: FontWeight.w700), + style: TextStyle( + fontSize: 14.sp, + color: const Color.fromRGBO(0, 0, 0, 0.58), + fontWeight: FontWeight.w700, + ), ) ], ); diff --git a/lib/individual/spend_time.dart b/lib/individual/spend_time.dart index c404d8f..fae439c 100644 --- a/lib/individual/spend_time.dart +++ b/lib/individual/spend_time.dart @@ -22,7 +22,7 @@ class _SpendTimeState extends State { TextEditingController orgName = TextEditingController(); FirestoreDatabase fd = FirestoreDatabase(); - List organisationNames = []; + List> organisationNames = []; CollectionReference spend = FirebaseFirestore.instance.collection('spend'); @@ -237,8 +237,8 @@ class _SpendTimeState extends State { backgroundColor: const Color(0xFF729CA3), ), onPressed: (() - // async - { + // async + { // await spend.add({ // 'organizationname': orgName.text, // date: date.text, @@ -265,89 +265,70 @@ class _SpendTimeState extends State { // ); showDialog( - context: context, - builder: (context) { - return Center( - child: Material( - type: - MaterialType.transparency, - child: Container( - decoration: BoxDecoration( - borderRadius: - BorderRadiusDirectional - .circular(10), - color: Colors.white, - ), - padding: - EdgeInsets.all(15), - width: - MediaQuery.of(context) - .size - .width * - 0.7, - height: 350, - child: Column( - crossAxisAlignment: - CrossAxisAlignment - .center, - children: [ - ClipRRect( - borderRadius: - BorderRadius - .circular( - 5), - child: Image.asset( - 'assets/main_assets/Completed.png', - width: 200, - height: 200, - ), - ), - // ignore: prefer_const_constructors - SizedBox(height: 10), - - // ignore: prefer_const_constructors - Text( - 'Thank You !!', - style: const TextStyle( - fontSize: 25, - color: Color - .fromARGB( - 255, - 137, - 184, - 189), - fontWeight: - FontWeight - .bold), - ), - // ignore: prefer_const_constructors - SizedBox( - height: 10, - ), - // ignore: prefer_const_constructors - Text( - 'Thank You for giving your precious time', - style: const TextStyle( - fontSize: 20, - color: Color - .fromARGB( - 255, - 0, - 10, - 11), - fontWeight: - FontWeight - .bold), - textAlign: TextAlign - .center, - ), - ], - )), + context: context, + builder: (context) { + return Center( + child: Material( + type: MaterialType.transparency, + child: Container( + decoration: BoxDecoration( + borderRadius: + BorderRadiusDirectional + .circular(10), + color: Colors.white, + ), + padding: EdgeInsets.all(15), + width: MediaQuery.of(context) + .size + .width * + 0.7, + height: 350, + child: Column( + crossAxisAlignment: + CrossAxisAlignment.center, + children: [ + ClipRRect( + borderRadius: + BorderRadius.circular(5), + child: Image.asset( + 'assets/main_assets/Completed.png', + width: 200, + height: 200, ), - ); - } - ) - ; + ), + // ignore: prefer_const_constructors + SizedBox(height: 10), + + // ignore: prefer_const_constructors + Text( + 'Thank You !!', + style: const TextStyle( + fontSize: 25, + color: Color.fromARGB( + 255, 137, 184, 189), + fontWeight: + FontWeight.bold), + ), + // ignore: prefer_const_constructors + SizedBox( + height: 10, + ), + // ignore: prefer_const_constructors + Text( + 'Thank You for giving your precious time', + style: const TextStyle( + fontSize: 20, + color: Color.fromARGB( + 255, 0, 10, 11), + fontWeight: + FontWeight.bold), + textAlign: TextAlign.center, + ), + ], + )), + ), + ); + }); }), child: const Text( 'Submit', @@ -370,4 +351,4 @@ class _SpendTimeState extends State { bottomNavigationBar: const CustomNavigationBar(currentIndex: 0), ); } -} +} \ No newline at end of file diff --git a/lib/individual/user_chats_menu.dart b/lib/individual/user_chats_menu.dart index a1c0f27..130aa27 100644 --- a/lib/individual/user_chats_menu.dart +++ b/lib/individual/user_chats_menu.dart @@ -3,7 +3,6 @@ import 'package:cura/shared/widgets/navigation-bar.dart'; import 'package:flutter/material.dart'; import 'package:cura/individual/home_page_individual.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -import '../shared/widgets/gradient_background.dart'; import 'package:cura/shared/services/stringScreenArguments.dart'; class UserChatsScreen extends StatefulWidget { diff --git a/lib/main.dart b/lib/main.dart index f3d6c42..148da81 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,5 +1,4 @@ import 'package:cura/individual/home_page_individual.dart'; -import 'package:cura/organization/postfeed.dart'; import 'package:cura/startup_screens/preview_page.dart'; import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/material.dart'; diff --git a/lib/organization/org_chat_screen.dart b/lib/organization/org_chat_screen.dart index a5f8695..7b814ff 100644 --- a/lib/organization/org_chat_screen.dart +++ b/lib/organization/org_chat_screen.dart @@ -1,32 +1,13 @@ -import 'package:firebase_core/firebase_core.dart'; import 'package:cloud_firestore/cloud_firestore.dart'; +import 'package:cura/shared/widgets/gradient_background.dart'; import 'package:flutter/material.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -void main() async { - WidgetsFlutterBinding.ensureInitialized(); - await Firebase.initializeApp(); - runApp(MyApp()); -} - -class MyApp extends StatelessWidget { - @override - Widget build(BuildContext context) { - return MaterialApp( - title: 'Flutter Firebase Chat', - theme: ThemeData( - primarySwatch: Colors.blue, - visualDensity: VisualDensity.adaptivePlatformDensity, - ), - home: OrgChatScreen(userName: 'John Doe', imgUrl: ''), - ); - } -} - class OrgChatScreen extends StatefulWidget { static const String routeName = '/OrgChatScreen'; final String userName, imgUrl; - const OrgChatScreen({Key? key, required this.userName, required this.imgUrl}) : super(key: key); + const OrgChatScreen({Key? key, required this.userName, required this.imgUrl}) + : super(key: key); @override State createState() => _OrgChatScreenState(); @@ -34,7 +15,8 @@ class OrgChatScreen extends StatefulWidget { class _OrgChatScreenState extends State { final TextEditingController messageController = TextEditingController(); - final CollectionReference messagesCollection = FirebaseFirestore.instance.collection('messages'); + final CollectionReference messagesCollection = + FirebaseFirestore.instance.collection('messages'); final List months = [ "January", @@ -75,7 +57,8 @@ class _OrgChatScreenState extends State { ), Expanded( child: Container( - padding: EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), + padding: + EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), decoration: BoxDecoration( color: Colors.white, borderRadius: BorderRadius.only( @@ -90,11 +73,13 @@ class _OrgChatScreenState extends State { return Text('Error: ${snapshot.error}'); } - if (snapshot.connectionState == ConnectionState.waiting) { + if (snapshot.connectionState == + ConnectionState.waiting) { return CircularProgressIndicator(); } - final List documents = snapshot.data!.docs; + final List documents = + snapshot.data!.docs; return ListView.builder( physics: const BouncingScrollPhysics(), @@ -105,7 +90,8 @@ class _OrgChatScreenState extends State { bool showDate = false; if (index == 0) { return DateMsgTile(convDate: document['date']); - } else if (index != documents.length - 1 && currentDate != documents[index + 1]['date']) { + } else if (index != documents.length - 1 && + currentDate != documents[index + 1]['date']) { showDate = true; return MessageWidget( isMe: document['isMe'], @@ -122,6 +108,7 @@ class _OrgChatScreenState extends State { time: document['time'], showDate: showDate, orgImgUrl: widget.imgUrl, + nextDate: '', ); }, ); @@ -145,7 +132,10 @@ class _OrgChatScreenState extends State { children: [ Transform.rotate( angle: 45.0 * 3.14159 / 180, - child: IconButton(onPressed: () {}, iconSize: 28.h, icon: const Icon(Icons.attach_file)), + child: IconButton( + onPressed: () {}, + iconSize: 28.h, + icon: const Icon(Icons.attach_file)), ), Expanded( child: TextField( @@ -168,10 +158,17 @@ class _OrgChatScreenState extends State { ), ), ), - IconButton(onPressed: () {}, iconSize: 28.h, icon: const Icon(Icons.add_photo_alternate)), - IconButton(onPressed: () {}, iconSize: 28.h, icon: const Icon(Icons.mic)), IconButton( - onPressed: () => sendMessage(messageController.text), + onPressed: () {}, + iconSize: 28.h, + icon: const Icon(Icons.add_photo_alternate)), + IconButton( + onPressed: () {}, + iconSize: 28.h, + icon: const Icon(Icons.mic)), + IconButton( + onPressed: () => + sendMessage(messageController.text), iconSize: 28.h, icon: const Icon(Icons.send), ), @@ -204,7 +201,8 @@ class _OrgChatScreenState extends State { radius: 30.w, child: Image( image: widget.imgUrl == "" - ? const AssetImage('assets/startup_assets/create_account_assets/profile_primary.png') + ? const AssetImage( + 'assets/startup_assets/create_account_assets/profile_primary.png') : AssetImage(widget.imgUrl), ), ), @@ -252,27 +250,6 @@ class _OrgChatScreenState extends State { } } -class UniDirectionalBackground extends StatelessWidget { - const UniDirectionalBackground({Key? key}) : super(key: key); - - @override - Widget build(BuildContext context) { - return Container( - height: 220.h, - decoration: const BoxDecoration( - gradient: LinearGradient( - colors: [ - Color(0xFF8E9EAB), - Color(0xFFeef2f3), - ], - begin: Alignment.topCenter, - end: Alignment.bottomCenter, - ), - ), - ); - } -} - class MessageWidget extends StatelessWidget { final bool isMe; final String msg, time; @@ -293,7 +270,8 @@ class MessageWidget extends StatelessWidget { @override Widget build(BuildContext context) { return Column( - crossAxisAlignment: isMe ? CrossAxisAlignment.end : CrossAxisAlignment.start, + crossAxisAlignment: + isMe ? CrossAxisAlignment.end : CrossAxisAlignment.start, children: [ if (showDate) Padding( @@ -301,7 +279,8 @@ class MessageWidget extends StatelessWidget { child: DateMsgTile(convDate: nextDate), ), Row( - mainAxisAlignment: isMe ? MainAxisAlignment.end : MainAxisAlignment.start, + mainAxisAlignment: + isMe ? MainAxisAlignment.end : MainAxisAlignment.start, children: [ if (!isMe) CircleAvatar( @@ -309,7 +288,8 @@ class MessageWidget extends StatelessWidget { radius: 22.w, child: Image( image: orgImgUrl == "" - ? AssetImage('assets/startup_assets/create_account_assets/profile_primary.png') + ? AssetImage( + 'assets/startup_assets/create_account_assets/profile_primary.png') : AssetImage(orgImgUrl), ), ), @@ -386,4 +366,4 @@ class DateMsgTile extends StatelessWidget { ), ); } -} +} \ No newline at end of file diff --git a/lib/shared/services/firebase_database.dart b/lib/shared/services/firebase_database.dart index 7d1a5f7..e74f29a 100644 --- a/lib/shared/services/firebase_database.dart +++ b/lib/shared/services/firebase_database.dart @@ -101,16 +101,14 @@ class FirestoreDatabase { .set(volunteerData); } - Future addPost(List images,String postText) async{ + Future addPost(List images, String postText) async { try { final currentUserUid = _auth.getCurrentUser()!.uid; Map data = await getIndividualProfileData(currentUserUid); List imagesUrl = []; for (final imgFile in images) { - imagesUrl.add( - await Storage().postFile(imgFile, - 'postImages/${data['individualEmail']}${imgFile.hashCode}') - ); + imagesUrl.add(await Storage().postFile(imgFile, + 'postImages/${data['individualEmail']}${imgFile.hashCode}')); } Map postData = { @@ -123,9 +121,7 @@ class FirestoreDatabase { }; await _db.collection('posts/').add(postData); - } - catch(e) - { + } catch (e) { print(e); return; } @@ -134,7 +130,6 @@ class FirestoreDatabase { Stream getPostData() { return _db.collection('posts/').snapshots(); } -} Future spendtime(Map spendData) async { String? uid; @@ -150,4 +145,4 @@ class FirestoreDatabase { .doc(uid) .set(spendData); } -} +} \ No newline at end of file diff --git a/linux/flutter/generated_plugin_registrant.cc b/linux/flutter/generated_plugin_registrant.cc index e71a16d..64a0ece 100644 --- a/linux/flutter/generated_plugin_registrant.cc +++ b/linux/flutter/generated_plugin_registrant.cc @@ -6,6 +6,10 @@ #include "generated_plugin_registrant.h" +#include void fl_register_plugins(FlPluginRegistry* registry) { + g_autoptr(FlPluginRegistrar) file_selector_linux_registrar = + fl_plugin_registry_get_registrar_for_plugin(registry, "FileSelectorPlugin"); + file_selector_plugin_register_with_registrar(file_selector_linux_registrar); } diff --git a/linux/flutter/generated_plugins.cmake b/linux/flutter/generated_plugins.cmake index 2e1de87..2db3c22 100644 --- a/linux/flutter/generated_plugins.cmake +++ b/linux/flutter/generated_plugins.cmake @@ -3,6 +3,7 @@ # list(APPEND FLUTTER_PLUGIN_LIST + file_selector_linux ) list(APPEND FLUTTER_FFI_PLUGIN_LIST diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift index b7c04fa..4b433bf 100644 --- a/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -6,16 +6,20 @@ import FlutterMacOS import Foundation import cloud_firestore +import file_selector_macos import firebase_auth import firebase_core +import firebase_messaging import firebase_storage -import sqflite import path_provider_foundation +import sqflite func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { FLTFirebaseFirestorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseFirestorePlugin")) + FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin")) FLTFirebaseAuthPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseAuthPlugin")) FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin")) + FLTFirebaseMessagingPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseMessagingPlugin")) FLTFirebaseStoragePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseStoragePlugin")) PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) SqflitePlugin.register(with: registry.registrar(forPlugin: "SqflitePlugin")) diff --git a/pubspec.lock b/pubspec.lock index ddaecb1..112432c 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -5,10 +5,10 @@ packages: dependency: transitive description: name: _flutterfire_internals - sha256: "2f428053492f92303e42c9afa8e3a78ad1886760e7b594e2b5a6b6ee47376360" + sha256: "76c15c4167f820b74abcd8c6fc5e393e1ed5e1207a34e9b22953603e03b3ba6a" url: "https://pub.dev" source: hosted - version: "1.0.2" + version: "1.3.9" anim_search_bar: dependency: "direct main" description: @@ -21,26 +21,26 @@ packages: dependency: transitive description: name: archive - sha256: d6347d54a2d8028e0437e3c099f66fdb8ae02c4720c1e7534c9f24c10351f85d + sha256: "7e0d52067d05f2e0324268097ba723b71cb41ac8a6a2b24d1edf9c536b987b03" url: "https://pub.dev" source: hosted - version: "3.3.6" + version: "3.4.6" args: dependency: transitive description: name: args - sha256: "4cab82a83ffef80b262ddedf47a0a8e56ee6fbf7fe21e6e768b02792034dd440" + sha256: eef6c46b622e0494a36c5a12d10d77fb4e855501a91c1b9ef9339326e58f0596 url: "https://pub.dev" source: hosted - version: "2.4.0" + version: "2.4.2" async: dependency: transitive description: name: async - sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 + sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" url: "https://pub.dev" source: hosted - version: "2.10.0" + version: "2.11.0" boolean_selector: dependency: transitive description: @@ -48,26 +48,29 @@ packages: sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.1.1" cached_network_image: dependency: "direct main" description: name: cached_network_image - url: "https://pub.dartlang.org" + sha256: fd3d0dc1d451f9a252b32d95d3f0c3c487bc41a75eba2e6097cb0b9c71491b15 + url: "https://pub.dev" source: hosted version: "3.2.3" cached_network_image_platform_interface: dependency: transitive description: name: cached_network_image_platform_interface - url: "https://pub.dartlang.org" + sha256: bb2b8403b4ccdc60ef5f25c70dead1f3d32d24b9d6117cfc087f496b178594a7 + url: "https://pub.dev" source: hosted version: "2.0.0" cached_network_image_web: dependency: transitive description: name: cached_network_image_web - url: "https://pub.dartlang.org" + sha256: b8eb814ebfcb4dea049680f8c1ffb2df399e4d03bf7a352c775e26fa06e02fa0 + url: "https://pub.dev" source: hosted version: "1.0.2" carousel_slider: @@ -82,18 +85,18 @@ packages: dependency: transitive description: name: characters - sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c + sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" url: "https://pub.dev" source: hosted - version: "1.2.1" + version: "1.3.0" checked_yaml: dependency: transitive description: name: checked_yaml - sha256: "3d1505d91afa809d177efd4eed5bb0eb65805097a1463abdd2add076effae311" + sha256: feb6bed21949061731a7a75fc5d2aa727cf160b91af9a3e464c5e3a32e28b5ff url: "https://pub.dev" source: hosted - version: "2.0.2" + version: "2.0.3" cli_util: dependency: transitive description: @@ -114,34 +117,34 @@ packages: dependency: "direct main" description: name: cloud_firestore - sha256: "9194bf1845ee073bea64ec94e72c9dcf5d15f755e96496d8ccfee9def38b666f" + sha256: "019da47850fe2c86266a4b86e82e0d00dcb5bf0718f26fc70bf9df275ee16537" url: "https://pub.dev" source: hosted - version: "3.5.1" + version: "4.11.0" cloud_firestore_platform_interface: dependency: transitive description: name: cloud_firestore_platform_interface - sha256: d023142c18c28b2610c23c196e829c96976569cc2aa2f8e45328ae8a64c428d1 + sha256: "7e08cd322ff98ddfdb6ab8a89b24f895c473992d674bfd3b36865037879baa3f" url: "https://pub.dev" source: hosted - version: "5.7.7" + version: "6.0.1" cloud_firestore_web: dependency: transitive description: name: cloud_firestore_web - sha256: "3d7d4fa8c1dc5a1f7cb33985ae0ab9924d33d76d4959fe26aed84b7d282887e3" + sha256: bd2183128b67d66a6e672c50e47bc70393418f3bd669aad8ac321e88f027b2b5 url: "https://pub.dev" source: hosted - version: "2.8.10" + version: "3.8.1" collection: dependency: transitive description: name: collection - sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 + sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c" url: "https://pub.dev" source: hosted - version: "1.17.0" + version: "1.17.1" convert: dependency: transitive description: @@ -154,26 +157,26 @@ packages: dependency: transitive description: name: cross_file - sha256: "0b0036e8cccbfbe0555fd83c1d31a6f30b77a96b598b35a5d36dd41f718695e9" + sha256: "445db18de832dba8d851e287aff8ccf169bed30d2e94243cb54c7d2f1ed2142c" url: "https://pub.dev" source: hosted - version: "0.3.3+4" + version: "0.3.3+6" crypto: dependency: transitive description: name: crypto - sha256: aa274aa7774f8964e4f4f38cc994db7b6158dd36e9187aaceaddc994b35c6c67 + sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab url: "https://pub.dev" source: hosted - version: "3.0.2" + version: "3.0.3" cupertino_icons: dependency: "direct main" description: name: cupertino_icons - sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be + sha256: d57953e10f9f8327ce64a508a355f0b1ec902193f66288e8cb5070e7c47eeb2d url: "https://pub.dev" source: hosted - version: "1.0.5" + version: "1.0.6" fake_async: dependency: transitive description: @@ -194,10 +197,10 @@ packages: dependency: transitive description: name: ffi - sha256: a38574032c5f1dd06c4aee541789906c12ccaab8ba01446e800d9c5b79c4a978 + sha256: "7bf0adc28a23d395f19f3f1eb21dd7cfd1dd9f8e1c50051c069122e6853bc878" url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "2.1.0" file: dependency: transitive description: @@ -210,82 +213,138 @@ packages: dependency: "direct main" description: name: file_picker - sha256: d8e9ca7e5d1983365c277f12c21b4362df6cf659c99af146ad4d04eb33033013 + sha256: "903dd4ba13eae7cef64acc480e91bf54c3ddd23b5b90b639c170f3911e489620" + url: "https://pub.dev" + source: hosted + version: "6.0.0" + file_selector_linux: + dependency: transitive + description: + name: file_selector_linux + sha256: "045d372bf19b02aeb69cacf8b4009555fb5f6f0b7ad8016e5f46dd1387ddd492" + url: "https://pub.dev" + source: hosted + version: "0.9.2+1" + file_selector_macos: + dependency: transitive + description: + name: file_selector_macos + sha256: b15c3da8bd4908b9918111fa486903f5808e388b8d1c559949f584725a6594d6 + url: "https://pub.dev" + source: hosted + version: "0.9.3+3" + file_selector_platform_interface: + dependency: transitive + description: + name: file_selector_platform_interface + sha256: "0aa47a725c346825a2bd396343ce63ac00bda6eff2fbc43eabe99737dede8262" url: "https://pub.dev" source: hosted - version: "5.2.6" + version: "2.6.1" + file_selector_windows: + dependency: transitive + description: + name: file_selector_windows + sha256: d3547240c20cabf205c7c7f01a50ecdbc413755814d6677f3cb366f04abcead0 + url: "https://pub.dev" + source: hosted + version: "0.9.3+1" firebase_auth: dependency: "direct main" description: name: firebase_auth - sha256: ca3034d35d6ca894487ec80aa1162a135fef7c5d0abef8154789cbeea3a6deaf + sha256: "46129e2733336ac77377174c3ca33a68cca2cd5848504aad63028aeb92afb7b2" url: "https://pub.dev" source: hosted - version: "3.11.2" + version: "4.11.1" firebase_auth_platform_interface: dependency: transitive description: name: firebase_auth_platform_interface - sha256: ab20ecbc411726e139250a49fa03fe1ae0105fd990c5330b2a148ec08dfb140b + sha256: b89936896b2cc02496b97e486793fd4bcf8c51beb99d6a7223c0eea2352d404e url: "https://pub.dev" source: hosted - version: "6.10.1" + version: "7.0.1" firebase_auth_web: dependency: transitive description: name: firebase_auth_web - sha256: bbe4f4fffcc378ca05c3d8ff33853be86dd27d0fafc85a953acaf5190531b6f9 + sha256: "88b7655c9394d723e121fd53f115d876c32260b8c8b499bdc3108341044a8306" url: "https://pub.dev" source: hosted - version: "4.6.1" + version: "5.8.4" firebase_core: dependency: "direct main" description: name: firebase_core - sha256: "4f1d7c13a909e82ff026679c9b8493cdeb35a9c76bc46c42bf9e2240c9e57e80" + sha256: "57bba167105d2315d243a4524939406df688f38a5b6d7a4159382bbbe43cdd00" url: "https://pub.dev" source: hosted - version: "1.24.0" + version: "2.19.0" firebase_core_platform_interface: dependency: "direct main" description: name: firebase_core_platform_interface - sha256: b51257a8b4388565cd66062d727d3e60067b5f5cc3390eb0ecd20b8f97741bdb + sha256: c437ae5d17e6b5cc7981cf6fd458a5db4d12979905f9aafd1fea930428a9fe63 url: "https://pub.dev" source: hosted - version: "4.5.1" + version: "5.0.0" firebase_core_web: dependency: transitive description: name: firebase_core_web - sha256: "839f1b48032a61962792cea1225fae030d4f27163867f181d6d2072dd40acbee" + sha256: "0631a2ec971dbc540275e2fa00c3a8a2676f0a7adbc3c197d6fba569db689d97" + url: "https://pub.dev" + source: hosted + version: "2.8.1" + firebase_messaging: + dependency: "direct main" + description: + name: firebase_messaging + sha256: "01320eab9b3f91a6351d873923190a965e5155db942187aa600f85f78b9de501" + url: "https://pub.dev" + source: hosted + version: "14.7.1" + firebase_messaging_platform_interface: + dependency: transitive + description: + name: firebase_messaging_platform_interface + sha256: "952df577e7fb3a4550483f86bb568f19ce5da2a91f1597eeefdca0607de82562" + url: "https://pub.dev" + source: hosted + version: "4.5.10" + firebase_messaging_web: + dependency: transitive + description: + name: firebase_messaging_web + sha256: dcc901226c33b4819992c4add900ed5dae79b0db70097a795d7932c85b18cda1 url: "https://pub.dev" source: hosted - version: "1.7.3" + version: "3.5.10" firebase_storage: dependency: "direct main" description: name: firebase_storage - sha256: "1fe46462c9632db0f62db5b9f1abcb8d4232a6d3e7098d745f5790b71dedc822" + sha256: c23dfab4fbdafd014b579e2bcc5b23ca69457d9b8625a64dffb669d098cff6fe url: "https://pub.dev" source: hosted - version: "10.3.11" + version: "11.3.1" firebase_storage_platform_interface: dependency: transitive description: name: firebase_storage_platform_interface - sha256: a4a1bed8764baf9b6d377d9870ebb2c65e13a38bc813cfaaf0ac2a37d422bcdd + sha256: "8650ba68840122f0c7e8a1a529d16580a5d00a614653d7167d7cd044c67fa245" url: "https://pub.dev" source: hosted - version: "4.1.19" + version: "4.4.9" firebase_storage_web: dependency: transitive description: name: firebase_storage_web - sha256: "791516c9170ab6643282807913cf89ebb950d66206eb92ed154a847438047587" + sha256: "93ac56b2a9722a94e0d752a4aa2dd5ec8c4ceeb8ff07121bb6580198dbede199" url: "https://pub.dev" source: hosted - version: "3.3.9" + version: "3.6.10" flutter: dependency: "direct main" description: flutter @@ -295,55 +354,58 @@ packages: dependency: transitive description: name: flutter_blurhash - url: "https://pub.dartlang.org" + sha256: "05001537bd3fac7644fa6558b09ec8c0a3f2eba78c0765f88912882b1331a5c6" + url: "https://pub.dev" source: hosted version: "0.7.0" flutter_cache_manager: dependency: transitive description: name: flutter_cache_manager - url: "https://pub.dartlang.org" + sha256: "8207f27539deb83732fdda03e259349046a39a4c767269285f449ade355d54ba" + url: "https://pub.dev" source: hosted - version: "3.3.0" + version: "3.3.1" flutter_image_compress: dependency: transitive description: name: flutter_image_compress - url: "https://pub.dartlang.org" + sha256: "37f1b26399098e5f97b74c1483f534855e7dff68ead6ddaccf747029fb03f29f" + url: "https://pub.dev" source: hosted version: "1.1.3" flutter_launcher_icons: dependency: "direct dev" description: name: flutter_launcher_icons - sha256: a9de6706cd844668beac27c0aed5910fa0534832b3c2cad61a5fd977fce82a5d + sha256: ce0e501cfc258907842238e4ca605e74b7fd1cdf04b3b43e86c43f3e40a1592c url: "https://pub.dev" source: hosted - version: "0.10.0" + version: "0.11.0" flutter_lints: dependency: "direct dev" description: name: flutter_lints - sha256: aeb0b80a8b3709709c9cc496cdc027c5b3216796bc0af0ce1007eaf24464fd4c + sha256: ad76540d21c066228ee3f9d1dad64a9f7e46530e8bb7c85011a88bc1fd874bc5 url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "3.0.0" flutter_plugin_android_lifecycle: dependency: transitive description: name: flutter_plugin_android_lifecycle - sha256: c224ac897bed083dabf11f238dd11a239809b446740be0c2044608c50029ffdf + sha256: f185ac890306b5779ecbd611f52502d8d4d63d27703ef73161ca0407e815f02c url: "https://pub.dev" source: hosted - version: "2.0.9" + version: "2.0.16" flutter_screenutil: dependency: "direct main" description: name: flutter_screenutil - sha256: "0a122936b450324cbdfd51be0819cc6fcebb093eb65585e9cd92263f7a1a8a39" + sha256: "8cf100b8e4973dc570b6415a2090b0bfaa8756ad333db46939efc3e774ee100d" url: "https://pub.dev" source: hosted - version: "5.7.0" + version: "5.9.0" flutter_test: dependency: "direct dev" description: flutter @@ -358,10 +420,10 @@ packages: dependency: transitive description: name: http - sha256: "6aa2946395183537c8b880962d935877325d6a09a2867c3970c05c0fed6ac482" + sha256: "5895291c13fa8a3bd82e76d5627f69e0d85ca6a30dcac95c4ea19a5d555879c2" url: "https://pub.dev" source: hosted - version: "0.13.5" + version: "0.13.6" http_parser: dependency: transitive description: @@ -382,82 +444,106 @@ packages: dependency: "direct main" description: name: image_picker - sha256: "64b21d9f0e065f9ab0e4dde458076226c97382cc0c6949144cb874c62bf8e9f8" + sha256: "7d7f2768df2a8b0a3cefa5ef4f84636121987d403130e70b17ef7e2cf650ba84" url: "https://pub.dev" source: hosted - version: "0.8.7" + version: "1.0.4" image_picker_android: dependency: transitive description: name: image_picker_android - sha256: b81db5f5ed8a69d54d5f0932c2af8120e8c0518a037d8beee494eec671da4d4c + sha256: "0c7b83bbe2980c8a8e36e974f055e11e51675784e13a4762889feed0f3937ff2" url: "https://pub.dev" source: hosted - version: "0.8.6+5" + version: "0.8.8+1" image_picker_for_web: dependency: transitive description: name: image_picker_for_web - sha256: "98f50d6b9f294c8ba35e25cc0d13b04bfddd25dbc8d32fa9d566a6572f2c081c" + sha256: "50bc9ae6a77eea3a8b11af5eb6c661eeb858fdd2f734c2a4fd17086922347ef7" url: "https://pub.dev" source: hosted - version: "2.1.12" + version: "3.0.1" image_picker_ios: dependency: transitive description: name: image_picker_ios - sha256: "50e882fe0a06bf0c8f7f5bce78d30975f279213293afc9471dc35f05617c50ff" + sha256: c5538cacefacac733c724be7484377923b476216ad1ead35a0d2eadcdc0fc497 + url: "https://pub.dev" + source: hosted + version: "0.8.8+2" + image_picker_linux: + dependency: transitive + description: + name: image_picker_linux + sha256: "4ed1d9bb36f7cd60aa6e6cd479779cc56a4cb4e4de8f49d487b1aaad831300fa" url: "https://pub.dev" source: hosted - version: "0.8.7+1" + version: "0.2.1+1" + image_picker_macos: + dependency: transitive + description: + name: image_picker_macos + sha256: "3f5ad1e8112a9a6111c46d0b57a7be2286a9a07fc6e1976fdf5be2bd31d4ff62" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" image_picker_platform_interface: dependency: transitive description: name: image_picker_platform_interface - sha256: "1991219d9dbc42a99aff77e663af8ca51ced592cd6685c9485e3458302d3d4f8" + sha256: ed9b00e63977c93b0d2d2b343685bed9c324534ba5abafbb3dfbd6a780b1b514 + url: "https://pub.dev" + source: hosted + version: "2.9.1" + image_picker_windows: + dependency: transitive + description: + name: image_picker_windows + sha256: "6ad07afc4eb1bc25f3a01084d28520496c4a3bb0cb13685435838167c9dcedeb" url: "https://pub.dev" source: hosted - version: "2.6.3" + version: "0.2.1+1" intl: dependency: "direct main" description: name: intl - sha256: "910f85bce16fb5c6f614e117efa303e85a1731bb0081edf3604a2ae6e9a3cc91" + sha256: "3bc132a9dbce73a7e4a21a17d06e1878839ffbf975568bc875c60537824b0c4d" url: "https://pub.dev" source: hosted - version: "0.17.0" + version: "0.18.1" js: dependency: transitive description: name: js - sha256: "5528c2f391ededb7775ec1daa69e65a2d61276f7552de2b5f7b8d34ee9fd4ab7" + sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3 url: "https://pub.dev" source: hosted - version: "0.6.5" + version: "0.6.7" json_annotation: dependency: transitive description: name: json_annotation - sha256: c33da08e136c3df0190bd5bbe51ae1df4a7d96e7954d1d7249fea2968a72d317 + sha256: b10a7b2ff83d83c777edba3c6a0f97045ddadd56c944e1a23a3fdf43a1bf4467 url: "https://pub.dev" source: hosted - version: "4.8.0" + version: "4.8.1" lints: dependency: transitive description: name: lints - sha256: "5e4a9cd06d447758280a8ac2405101e0e2094d2a1dbdd3756aec3fe7775ba593" + sha256: cbf8d4b858bb0134ef3ef87841abdf8d63bfc255c266b7bf6b39daa1085c4290 url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "3.0.0" matcher: dependency: transitive description: name: matcher - sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" + sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb" url: "https://pub.dev" source: hosted - version: "0.12.13" + version: "0.12.15" material_color_utilities: dependency: transitive description: @@ -470,10 +556,10 @@ packages: dependency: transitive description: name: meta - sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" + sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" url: "https://pub.dev" source: hosted - version: "1.8.0" + version: "1.9.1" mime: dependency: transitive description: @@ -481,139 +567,135 @@ packages: sha256: e4ff8e8564c03f255408decd16e7899da1733852a9110a58fe6d1b817684a63e url: "https://pub.dev" source: hosted - version: "1.0.2" + version: "1.0.4" octo_image: dependency: transitive description: name: octo_image - url: "https://pub.dartlang.org" + sha256: "107f3ed1330006a3bea63615e81cf637433f5135a52466c7caa0e7152bca9143" + url: "https://pub.dev" source: hosted version: "1.0.2" optimized_cached_image: dependency: "direct main" description: name: optimized_cached_image - url: "https://pub.dartlang.org" + sha256: "9761aee196cdea172c5643245416c08bfcc8b94f35464af8c7462e2bab7c0b7f" + url: "https://pub.dev" source: hosted version: "3.0.1" path: dependency: transitive description: name: path - sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b + sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" url: "https://pub.dev" source: hosted - version: "1.8.2" + version: "1.8.3" path_provider: dependency: transitive description: name: path_provider - sha256: "04890b994ee89bfa80bf3080bfec40d5a92c5c7a785ebb02c13084a099d2b6f9" + sha256: a1aa8aaa2542a6bc57e381f132af822420216c80d4781f7aa085ca3229208aaa url: "https://pub.dev" source: hosted - version: "2.0.13" + version: "2.1.1" path_provider_android: dependency: transitive description: name: path_provider_android - sha256: "019f18c9c10ae370b08dce1f3e3b73bc9f58e7f087bb5e921f06529438ac0ae7" + sha256: "6b8b19bd80da4f11ce91b2d1fb931f3006911477cec227cce23d3253d80df3f1" url: "https://pub.dev" source: hosted - version: "2.0.24" + version: "2.2.0" path_provider_foundation: dependency: transitive description: name: path_provider_foundation - sha256: "12eee51abdf4d34c590f043f45073adbb45514a108bd9db4491547a2fd891059" + sha256: "19314d595120f82aca0ba62787d58dde2cc6b5df7d2f0daf72489e38d1b57f2d" url: "https://pub.dev" source: hosted - version: "2.2.0" + version: "2.3.1" path_provider_linux: dependency: transitive description: name: path_provider_linux - sha256: "2ae08f2216225427e64ad224a24354221c2c7907e448e6e0e8b57b1eb9f10ad1" + sha256: f7a1fe3a634fe7734c8d3f2766ad746ae2a2884abe22e241a8b301bf5cac3279 url: "https://pub.dev" source: hosted - version: "2.1.10" + version: "2.2.1" path_provider_platform_interface: dependency: transitive description: name: path_provider_platform_interface - sha256: "57585299a729335f1298b43245842678cb9f43a6310351b18fb577d6e33165ec" + sha256: "94b1e0dd80970c1ce43d5d4e050a9918fce4f4a775e6142424c30a29a363265c" url: "https://pub.dev" source: hosted - version: "2.0.6" + version: "2.1.1" path_provider_windows: dependency: transitive description: name: path_provider_windows - sha256: f53720498d5a543f9607db4b0e997c4b5438884de25b0f73098cc2671a51b130 + sha256: "8bc9f22eee8690981c22aa7fc602f5c85b497a6fb2ceb35ee5a5e5ed85ad8170" url: "https://pub.dev" source: hosted - version: "2.1.3" + version: "2.2.1" pedantic: dependency: transitive description: name: pedantic - url: "https://pub.dartlang.org" + sha256: "67fc27ed9639506c856c840ccce7594d0bdcd91bc8d53d6e52359449a1d50602" + url: "https://pub.dev" source: hosted version: "1.11.1" petitparser: dependency: transitive description: name: petitparser - sha256: "49392a45ced973e8d94a85fdb21293fbb40ba805fc49f2965101ae748a3683b4" + sha256: cb3798bef7fc021ac45b308f4b51208a152792445cce0448c9a4ba5879dd8750 url: "https://pub.dev" source: hosted - version: "5.1.0" + version: "5.4.0" platform: dependency: transitive description: name: platform - sha256: "4a451831508d7d6ca779f7ac6e212b4023dd5a7d08a27a63da33756410e32b76" + sha256: "0a279f0707af40c890e80b1e9df8bb761694c074ba7e1d4ab1bc4b728e200b59" url: "https://pub.dev" source: hosted - version: "3.1.0" + version: "3.1.3" plugin_platform_interface: dependency: transitive description: name: plugin_platform_interface - sha256: "6a2128648c854906c53fa8e33986fc0247a1116122f9534dd20e3ab9e16a32bc" + sha256: da3fdfeccc4d4ff2da8f8c556704c08f912542c5fb3cf2233ed75372384a034d url: "https://pub.dev" source: hosted - version: "2.1.4" + version: "2.1.6" pointycastle: dependency: transitive description: name: pointycastle - sha256: "57b6b78df14175658f09c5dfcfc51a46ad9561a3504fe679913dab404d0cc0f2" + sha256: "7c1e5f0d23c9016c5bbd8b1473d0d3fb3fc851b876046039509e18e0c7485f2c" url: "https://pub.dev" source: hosted - version: "3.7.0" - process: - dependency: transitive - description: - name: process - sha256: "53fd8db9cec1d37b0574e12f07520d582019cb6c44abf5479a01505099a34a09" - url: "https://pub.dev" - source: hosted - version: "4.2.4" + version: "3.7.3" rxdart: dependency: transitive description: name: rxdart - url: "https://pub.dartlang.org" + sha256: "0c7c0cedd93788d996e33041ffecda924cc54389199cde4e6a34b440f50044cb" + url: "https://pub.dev" source: hosted version: "0.27.7" searchfield: dependency: "direct main" description: name: searchfield - sha256: d6346f68da4db0da6bd4c8ad1bae7fda572b0363a665cb52b07e4bb09ef1e003 + sha256: f087957e607a13add3c15e23ac7f9f63110c4e7a2964df81b1448e353e83b9b2 url: "https://pub.dev" source: hosted - version: "0.5.6" + version: "0.8.6" share: dependency: "direct main" description: @@ -631,10 +713,10 @@ packages: dependency: "direct main" description: name: smooth_page_indicator - sha256: "8c301bc686892306cd41672c1880167f140c16be305d5ede8201fefd9fcda829" + sha256: "725bc638d5e79df0c84658e1291449996943f93bacbc2cec49963dbbab48d8ae" url: "https://pub.dev" source: hosted - version: "1.0.1" + version: "1.1.0" social_share: dependency: "direct main" description: @@ -650,28 +732,31 @@ packages: sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 url: "https://pub.dev" source: hosted - version: "1.9.0" + version: "1.9.1" sprintf: dependency: transitive description: name: sprintf - url: "https://pub.dartlang.org" + sha256: ec76d38910b6f1c854ce1353c62d37e7ef82b53dc5ab048c25400d35970776d1 + url: "https://pub.dev" source: hosted version: "6.0.2" sqflite: dependency: transitive description: name: sqflite - url: "https://pub.dartlang.org" + sha256: "591f1602816e9c31377d5f008c2d9ef7b8aca8941c3f89cc5fd9d84da0c38a9a" + url: "https://pub.dev" source: hosted - version: "2.2.2" + version: "2.3.0" sqflite_common: dependency: transitive description: name: sqflite_common - url: "https://pub.dartlang.org" + sha256: "1b92f368f44b0dee2425bb861cfa17b6f6cf3961f762ff6f941d20b33355660a" + url: "https://pub.dev" source: hosted - version: "2.4.0+2" + version: "2.5.0" stack_trace: dependency: transitive description: @@ -695,14 +780,15 @@ packages: sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" url: "https://pub.dev" source: hosted - version: "1.1.1" + version: "1.2.0" synchronized: dependency: transitive description: name: synchronized - url: "https://pub.dartlang.org" + sha256: "5fcbd27688af6082f5abd611af56ee575342c30e87541d0245f7ff99faa02c60" + url: "https://pub.dev" source: hosted - version: "3.0.0+3" + version: "3.1.0" term_glyph: dependency: transitive description: @@ -715,23 +801,24 @@ packages: dependency: transitive description: name: test_api - sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 + sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb url: "https://pub.dev" source: hosted - version: "0.4.16" + version: "0.5.1" typed_data: dependency: transitive description: name: typed_data - sha256: "26f87ade979c47a150c9eaab93ccd2bebe70a27dc0b4b29517f2904f04eb11a5" + sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c url: "https://pub.dev" source: hosted - version: "1.3.1" + version: "1.3.2" uuid: dependency: transitive description: name: uuid - url: "https://pub.dartlang.org" + sha256: "648e103079f7c64a36dc7d39369cabb358d377078a051d6ae2ad3aa539519313" + url: "https://pub.dev" source: hosted version: "3.0.7" vector_math: @@ -746,34 +833,34 @@ packages: dependency: transitive description: name: win32 - sha256: c9ebe7ee4ab0c2194e65d3a07d8c54c5d00bb001b76081c4a04cdb8448b59e46 + sha256: "350a11abd2d1d97e0cc7a28a81b781c08002aa2864d9e3f192ca0ffa18b06ed3" url: "https://pub.dev" source: hosted - version: "3.1.3" + version: "5.0.9" xdg_directories: dependency: transitive description: name: xdg_directories - sha256: ee1505df1426458f7f60aac270645098d318a8b4766d85fde75f76f2e21807d1 + sha256: "589ada45ba9e39405c198fe34eb0f607cddb2108527e658136120892beac46d2" url: "https://pub.dev" source: hosted - version: "1.0.0" + version: "1.0.3" xml: dependency: transitive description: name: xml - sha256: "979ee37d622dec6365e2efa4d906c37470995871fe9ae080d967e192d88286b5" + sha256: "5bc72e1e45e941d825fd7468b9b4cc3b9327942649aeb6fc5cdbf135f0a86e84" url: "https://pub.dev" source: hosted - version: "6.2.2" + version: "6.3.0" yaml: dependency: transitive description: name: yaml - sha256: "23812a9b125b48d4007117254bca50abb6c712352927eece9e155207b1db2370" + sha256: "75769501ea3489fca56601ff33454fe45507ea3bfb014161abc3b43ae25989d5" url: "https://pub.dev" source: hosted - version: "3.1.1" + version: "3.1.2" sdks: - dart: ">=2.18.0 <3.0.0" - flutter: ">=3.3.0" + dart: ">=3.0.0 <4.0.0" + flutter: ">=3.10.0" diff --git a/pubspec.yaml b/pubspec.yaml index 9e38372..860c5da 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -29,26 +29,26 @@ environment: dependencies: anim_search_bar: ^2.0.2 carousel_slider: ^4.1.1 - cloud_firestore: ^3.4.4 + cloud_firestore: ^4.11.0 cupertino_icons: ^1.0.2 - file_picker: ^5.0.1 - firebase_auth: ^3.6.2 - firebase_core: ^1.21.1 - firebase_storage: ^10.3.5 + file_picker: ^6.0.0 + firebase_auth: ^4.11.1 + firebase_core: ^2.19.0 + firebase_storage: ^11.3.1 flutter: sdk: flutter flutter_screenutil: ^5.5.3+2 - image_picker: ^0.8.5+3 - searchfield: ^0.5.3 + image_picker: ^1.0.4 + searchfield: ^0.8.6 smooth_page_indicator: ^1.0.0+2 - intl: ^0.17.0 + intl: ^0.18.1 favorite_button: ^0.0.4 share: ^2.0.4 social_share: ^2.2.1 cached_network_image: ^3.2.3 optimized_cached_image: ^3.0.1 - firebase_core_platform_interface: 4.5.1 - firebase_messaging: ^13.0.4 + firebase_core_platform_interface: ^5.0.0 + firebase_messaging: ^14.7.1 @@ -59,8 +59,8 @@ dev_dependencies: # activated in the `analysis_options.yaml` file located at the root of your # package. See that file for information about deactivating specific lint # rules and activating additional ones. - flutter_launcher_icons: "^0.10.0" - flutter_lints: ^2.0.0 + flutter_launcher_icons: ^0.11.0 + flutter_lints: ^3.0.0 flutter_test: sdk: flutter diff --git a/windows/flutter/generated_plugin_registrant.cc b/windows/flutter/generated_plugin_registrant.cc index 8b6d468..4a46c81 100644 --- a/windows/flutter/generated_plugin_registrant.cc +++ b/windows/flutter/generated_plugin_registrant.cc @@ -6,6 +6,18 @@ #include "generated_plugin_registrant.h" +#include +#include +#include +#include void RegisterPlugins(flutter::PluginRegistry* registry) { + CloudFirestorePluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("CloudFirestorePluginCApi")); + FileSelectorWindowsRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FileSelectorWindows")); + FirebaseAuthPluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseAuthPluginCApi")); + FirebaseCorePluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseCorePluginCApi")); } diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake index b93c4c3..e0beee3 100644 --- a/windows/flutter/generated_plugins.cmake +++ b/windows/flutter/generated_plugins.cmake @@ -3,6 +3,10 @@ # list(APPEND FLUTTER_PLUGIN_LIST + cloud_firestore + file_selector_windows + firebase_auth + firebase_core ) list(APPEND FLUTTER_FFI_PLUGIN_LIST From 0a18e7e7e6b716158b30328982864a265d506a4a Mon Sep 17 00:00:00 2001 From: Jayraj Date: Sat, 21 Oct 2023 21:00:11 +0530 Subject: [PATCH 10/13] Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen --- lib/individual/donor_details.dart | 52 +++--- lib/individual/health.dart | 198 ++++++++++++----------- lib/individual/home_page_individual.dart | 6 + lib/individual/user_chat_screen.dart | 48 +++++- 4 files changed, 175 insertions(+), 129 deletions(-) diff --git a/lib/individual/donor_details.dart b/lib/individual/donor_details.dart index 150347e..78b1987 100644 --- a/lib/individual/donor_details.dart +++ b/lib/individual/donor_details.dart @@ -14,18 +14,18 @@ class DonorPage extends StatelessWidget { children: [ IconButton( onPressed: () {}, - icon: Icon( + icon:const Icon( Icons.arrow_back_ios_new, size: 15.0, - )), - Text( + ),), + const Text( "Donor Detail", style: TextStyle( fontSize: 22.0, fontWeight: FontWeight.w700, ), ), - SizedBox( + const SizedBox( width: 48.0, ), ], @@ -34,15 +34,15 @@ class DonorPage extends StatelessWidget { radius: 50.0, child: Image.asset("assets/Heart.png"), ), - SizedBox(height: 10.0), - Text( + const SizedBox(height: 10.0), + const Text( "Shazeb", style:TextStyle( fontSize: 24.0, fontWeight: FontWeight.w700, ), ), - Text( + const Text( "Last Connected 1 month ago", style:TextStyle( color: Color(0xFF777474), @@ -53,29 +53,29 @@ class DonorPage extends StatelessWidget { Expanded( child: Container( decoration: BoxDecoration( - color:Color(0xFFE0EEEF), + color:const Color(0xFFE0EEEF), borderRadius: BorderRadius.circular(10.0), ), - padding:EdgeInsets.all(10.0), - margin:EdgeInsets.all(10.0), - child: Text("+1 879 944-4489",textAlign: TextAlign.center,), + padding:const EdgeInsets.all(10.0), + margin:const EdgeInsets.all(10.0), + child:const Text("+1 879 944-4489",textAlign: TextAlign.center,), ), ), Expanded( child: Container( decoration: BoxDecoration( - color:Color(0xFFE0EEEF), + color:const Color(0xFFE0EEEF), borderRadius: BorderRadius.circular(10.0), ), - padding:EdgeInsets.all(10.0), - margin:EdgeInsets.all(10.0), - child: Text("shazeb12@gmail.com",textAlign: TextAlign.center,), + padding:const EdgeInsets.all(10.0), + margin:const EdgeInsets.all(10.0), + child: const Text("shazeb12@gmail.com",textAlign: TextAlign.center,), ), ), ], ), - SizedBox(height: 10.0), - Text( + const SizedBox(height: 10.0), + const Text( "Personal Information", style:TextStyle( fontSize: 20.0, @@ -85,10 +85,10 @@ class DonorPage extends StatelessWidget { Expanded( flex:3, child: Container( - padding: EdgeInsets.symmetric(horizontal: 10.0,vertical: 15.0), - margin: EdgeInsets.all(10.0), + padding:const EdgeInsets.symmetric(horizontal: 10.0,vertical: 15.0), + margin: const EdgeInsets.all(10.0), decoration: BoxDecoration( - color: Color(0xFFE0EEEF), + color: const Color(0xFFE0EEEF), borderRadius: BorderRadius.circular(15.0), ), child: Column(children: [ @@ -103,7 +103,7 @@ class DonorPage extends StatelessWidget { ), ), ), - Text( + const Text( "Administrative Details", style:TextStyle( fontSize: 20.0, @@ -112,10 +112,10 @@ class DonorPage extends StatelessWidget { ), Expanded( child: Container( - padding: EdgeInsets.symmetric(horizontal: 10.0,vertical: 15.0), - margin: EdgeInsets.all(10.0), + padding:const EdgeInsets.symmetric(horizontal: 10.0,vertical: 15.0), + margin: const EdgeInsets.all(10.0), decoration: BoxDecoration( - color: Color(0xFFE0EEEF), + color:const Color(0xFFE0EEEF), borderRadius: BorderRadius.circular(15.0), ), child: Column(children: [ @@ -149,7 +149,7 @@ class TwoTexts extends StatelessWidget { Expanded( child: Text( heading, - style: TextStyle( + style:const TextStyle( fontSize: 14.0, fontWeight: FontWeight.w700, ), @@ -159,7 +159,7 @@ class TwoTexts extends StatelessWidget { child: Text( text, textAlign: TextAlign.end, - style: TextStyle( + style:const TextStyle( fontSize: 14.0, fontWeight: FontWeight.w400, ), diff --git a/lib/individual/health.dart b/lib/individual/health.dart index 79e8d3b..47218c5 100644 --- a/lib/individual/health.dart +++ b/lib/individual/health.dart @@ -4,7 +4,6 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:intl/intl.dart'; import 'package:searchfield/searchfield.dart'; - class HealthPage extends StatefulWidget { static const String routeName = '/HealthPage'; const HealthPage({Key? key}) : super(key: key); @@ -14,9 +13,9 @@ class HealthPage extends StatefulWidget { } class _HealthPageState extends State { - TimeOfDay _timeOfDay = TimeOfDay(hour: 10, minute: 30); + TimeOfDay _timeOfDay = const TimeOfDay(hour: 10, minute: 30); - TextEditingController _date = TextEditingController(); + final TextEditingController _date = TextEditingController(); final controllerorganizationname = TextEditingController(); @@ -38,25 +37,26 @@ class _HealthPageState extends State { .map((orgName) => SearchFieldListItem(orgName, item: orgName)) .toList(); return ScreenUtilInit( - designSize: const Size(428, 926), - builder: (context, child) => Scaffold( - body: SafeArea( - child: SizedBox( - width: double.infinity, - child: Container( - decoration: const BoxDecoration( - gradient: LinearGradient( - colors: [ - Color(0xFF6CAFB4), - Colors.white, - Colors.white, - Color(0xFF6CAFB4), - ], - begin: Alignment.topCenter, - end: Alignment.bottomCenter, - tileMode: TileMode.clamp, - )), - child: Stack(children: [ + designSize: const Size(428, 926), + builder: (context, child) => Scaffold( + body: SafeArea( + child: SizedBox( + width: double.infinity, + child: Container( + decoration: const BoxDecoration( + gradient: LinearGradient( + colors: [ + Color(0xFF6CAFB4), + Colors.white, + Colors.white, + Color(0xFF6CAFB4), + ], + begin: Alignment.topCenter, + end: Alignment.bottomCenter, + tileMode: TileMode.clamp, + )), + child: Stack( + children: [ Container( padding: EdgeInsets.all(0.5.sp), // height: 100.h, @@ -100,7 +100,7 @@ class _HealthPageState extends State { height: 400.h, width: 330.w, decoration: BoxDecoration( - color: Color.fromARGB(255, 215, 246, 248), + color: const Color.fromARGB(255, 215, 246, 248), borderRadius: BorderRadius.circular(10.r), ), child: Column( @@ -357,77 +357,79 @@ class _HealthPageState extends State { type: MaterialType.transparency, child: Container( - decoration: BoxDecoration( - borderRadius: - BorderRadiusDirectional - .circular(10), - color: Colors.white, - ), - padding: - EdgeInsets.all(15), - width: - MediaQuery.of(context) - .size - .width * - 0.7, - height: 350, - child: Column( - crossAxisAlignment: - CrossAxisAlignment - .center, - children: [ - ClipRRect( - borderRadius: - BorderRadius - .circular( - 5), - child: Image.asset( - 'assets/main_assets/Completed.png', - width: 200, - height: 200, - ), + decoration: BoxDecoration( + borderRadius: + BorderRadiusDirectional + .circular(10), + color: Colors.white, + ), + padding: + const EdgeInsets.all( + 15), + width: + MediaQuery.of(context) + .size + .width * + 0.7, + height: 350, + child: Column( + crossAxisAlignment: + CrossAxisAlignment + .center, + children: [ + ClipRRect( + borderRadius: + BorderRadius + .circular(5), + child: Image.asset( + 'assets/main_assets/Completed.png', + width: 200, + height: 200, ), - // ignore: prefer_const_constructors - SizedBox(height: 10), + ), + // ignore: prefer_const_constructors + SizedBox(height: 10), - // ignore: prefer_const_constructors - Text( - 'Thank You !!', - style: const TextStyle( - fontSize: 25, - color: Color - .fromARGB( - 255, - 137, - 184, - 189), - fontWeight: - FontWeight - .bold), - ), - // ignore: prefer_const_constructors - SizedBox( - height: 10, - ), - // ignore: prefer_const_constructors - Text( - 'Thank You for free health checkup', - style: const TextStyle( - fontSize: 20, - color: Color - .fromARGB( - 255, - 0, - 10, - 11), - fontWeight: - FontWeight - .bold), - textAlign: TextAlign - .center, + // ignore: prefer_const_constructors + Text( + 'Thank You !!', + style: + const TextStyle( + fontSize: 25, + color: + Color.fromARGB( + 255, + 137, + 184, + 189), + fontWeight: + FontWeight.bold, ), - ], - )), + ), + // ignore: prefer_const_constructors + SizedBox( + height: 10, + ), + // ignore: prefer_const_constructors + Text( + 'Thank You for free health checkup', + style: const TextStyle( + fontSize: 20, + color: Color + .fromARGB( + 255, + 0, + 10, + 11), + fontWeight: + FontWeight + .bold), + textAlign: + TextAlign.center, + ), + ], + ), + ), ), ); }); @@ -443,12 +445,16 @@ class _HealthPageState extends State { ], ) ]), - ) + ), ], ), - ) - ]), + ), + ], ), - )))); + ), + ), + ), + ), + ); } -} \ No newline at end of file +} diff --git a/lib/individual/home_page_individual.dart b/lib/individual/home_page_individual.dart index cc710c1..3620262 100644 --- a/lib/individual/home_page_individual.dart +++ b/lib/individual/home_page_individual.dart @@ -84,6 +84,7 @@ class _HomePageIndividualState extends State { boxShadow: const [BoxShadow(blurRadius: 5.0, offset: Offset(0, 2), color: Colors.grey)], ), child: TextField( + controller: searchController, keyboardType: TextInputType.text, maxLines: null, @@ -102,8 +103,13 @@ class _HomePageIndividualState extends State { ), ), style: TextStyle( +<<<<<<< HEAD color: Colors.blueGrey, fontSize: 20.sp, // Increase the font size here (adjust as needed) +======= + color: Colors.black, + fontSize: 18.sp, +>>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) fontWeight: FontWeight.w400, ), ), diff --git a/lib/individual/user_chat_screen.dart b/lib/individual/user_chat_screen.dart index d6d1716..9d8c15d 100644 --- a/lib/individual/user_chat_screen.dart +++ b/lib/individual/user_chat_screen.dart @@ -1,5 +1,4 @@ import 'package:cloud_firestore/cloud_firestore.dart'; -import 'package:cura/shared/widgets/gradient_background.dart'; import 'package:flutter/material.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; @@ -56,6 +55,7 @@ class _ChatScreenState extends State { Widget build(BuildContext context) { bool isKeyboardActive = MediaQuery.of(context).viewInsets.bottom != 0; return Scaffold( + resizeToAvoidBottomInset: false, body: ScreenUtilInit( designSize: const Size(428, 926), @@ -71,9 +71,12 @@ class _ChatScreenState extends State { Expanded( child: Container( padding: +<<<<<<< HEAD EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), +======= + EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h,), +>>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) decoration: BoxDecoration( - color: Colors.white, borderRadius: BorderRadius.only( topLeft: Radius.circular(10.r), topRight: Radius.circular(10.r), @@ -117,8 +120,8 @@ class _ChatScreenState extends State { ), Center( child: Container( - height: 80.h, - width: 400.w, + height: 70.h, + width: 420.w, decoration: BoxDecoration( color: const Color(0xFF92B7C0), borderRadius: BorderRadius.circular(40.r), @@ -306,14 +309,23 @@ class MessageWidget extends StatelessWidget { convDate: nextDate!, ), Container( - width: 260.w, + // width: 260.w, padding: EdgeInsets.symmetric(vertical: 10.h, horizontal: 15.w), decoration: BoxDecoration( color: isMe ? const Color(0xFFC2E8DC) : const Color(0xFFE8E8E8), - borderRadius: BorderRadius.circular(10.r), + borderRadius: isMe ? const BorderRadius.only( + topLeft: Radius.circular(25.0), + bottomLeft: Radius.circular(25.0), + bottomRight: Radius.circular(25.0), + ) + : const BorderRadius.only( + topRight: Radius.circular(25.0), + bottomLeft: Radius.circular(25.0), + bottomRight: Radius.circular(25.0), + ), ), child: Column( - crossAxisAlignment: CrossAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.end, children: [ Text( msg, @@ -340,6 +352,28 @@ class MessageWidget extends StatelessWidget { } } +<<<<<<< HEAD +======= +class UniDirectionalBackground extends StatelessWidget { + const UniDirectionalBackground({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return const GradientBackground( + gradientColor: LinearGradient( + colors: [ + Color(0xFF92B7C0), + Color(0xFFA8CEBF), + Color(0xFFCCE7BA), + ], + begin: Alignment.topCenter, + end: Alignment.bottomCenter, + ), + ); + } +} + +>>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) class GradientBackground extends StatelessWidget { final Gradient gradientColor; From 576531a036a0e4dbe8cbdfc95c1be5d61747458f Mon Sep 17 00:00:00 2001 From: Jayraj Date: Sat, 21 Oct 2023 21:05:31 +0530 Subject: [PATCH 11/13] resolved some issue --- lib/individual/user_chat_screen.dart | 7 ------- 1 file changed, 7 deletions(-) diff --git a/lib/individual/user_chat_screen.dart b/lib/individual/user_chat_screen.dart index 9d8c15d..66b1218 100644 --- a/lib/individual/user_chat_screen.dart +++ b/lib/individual/user_chat_screen.dart @@ -71,11 +71,7 @@ class _ChatScreenState extends State { Expanded( child: Container( padding: -<<<<<<< HEAD - EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), -======= EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h,), ->>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) decoration: BoxDecoration( borderRadius: BorderRadius.only( topLeft: Radius.circular(10.r), @@ -352,8 +348,6 @@ class MessageWidget extends StatelessWidget { } } -<<<<<<< HEAD -======= class UniDirectionalBackground extends StatelessWidget { const UniDirectionalBackground({Key? key}) : super(key: key); @@ -373,7 +367,6 @@ class UniDirectionalBackground extends StatelessWidget { } } ->>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) class GradientBackground extends StatelessWidget { final Gradient gradientColor; From 3f72b596c87faf49c689e264d08e080bd85e06f9 Mon Sep 17 00:00:00 2001 From: Jayraj Date: Sat, 21 Oct 2023 23:21:33 +0530 Subject: [PATCH 12/13] Revert "resolved some issue" This reverts commit 576531a036a0e4dbe8cbdfc95c1be5d61747458f. Want to revert this commit --- lib/individual/user_chat_screen.dart | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/individual/user_chat_screen.dart b/lib/individual/user_chat_screen.dart index 66b1218..9d8c15d 100644 --- a/lib/individual/user_chat_screen.dart +++ b/lib/individual/user_chat_screen.dart @@ -71,7 +71,11 @@ class _ChatScreenState extends State { Expanded( child: Container( padding: +<<<<<<< HEAD + EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), +======= EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h,), +>>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) decoration: BoxDecoration( borderRadius: BorderRadius.only( topLeft: Radius.circular(10.r), @@ -348,6 +352,8 @@ class MessageWidget extends StatelessWidget { } } +<<<<<<< HEAD +======= class UniDirectionalBackground extends StatelessWidget { const UniDirectionalBackground({Key? key}) : super(key: key); @@ -367,6 +373,7 @@ class UniDirectionalBackground extends StatelessWidget { } } +>>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) class GradientBackground extends StatelessWidget { final Gradient gradientColor; From 0270ddcfe64db34d80dc12ef70cc529eba1435ee Mon Sep 17 00:00:00 2001 From: Jayraj Date: Sat, 21 Oct 2023 23:30:51 +0530 Subject: [PATCH 13/13] revert the commit --- lib/individual/user_chat_screen.dart | 7 ------- 1 file changed, 7 deletions(-) diff --git a/lib/individual/user_chat_screen.dart b/lib/individual/user_chat_screen.dart index 9d8c15d..d36d0d8 100644 --- a/lib/individual/user_chat_screen.dart +++ b/lib/individual/user_chat_screen.dart @@ -71,11 +71,7 @@ class _ChatScreenState extends State { Expanded( child: Container( padding: -<<<<<<< HEAD EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h), -======= - EdgeInsets.symmetric(horizontal: 20.w, vertical: 5.h,), ->>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) decoration: BoxDecoration( borderRadius: BorderRadius.only( topLeft: Radius.circular(10.r), @@ -352,8 +348,6 @@ class MessageWidget extends StatelessWidget { } } -<<<<<<< HEAD -======= class UniDirectionalBackground extends StatelessWidget { const UniDirectionalBackground({Key? key}) : super(key: key); @@ -373,7 +367,6 @@ class UniDirectionalBackground extends StatelessWidget { } } ->>>>>>> 219bfa7 (Made changes to he UI of the Chat Bubble and Background Color of User Chat Screen) class GradientBackground extends StatelessWidget { final Gradient gradientColor;