diff --git a/assets/images/png/livecare_service.png b/assets/images/png/livecare_service.png new file mode 100644 index 0000000..d900403 Binary files /dev/null and b/assets/images/png/livecare_service.png differ diff --git a/assets/images/svg/add_icon.svg b/assets/images/svg/add_icon.svg new file mode 100644 index 0000000..f89b62a --- /dev/null +++ b/assets/images/svg/add_icon.svg @@ -0,0 +1,3 @@ + + + diff --git a/assets/images/svg/contact_icon.svg b/assets/images/svg/contact_icon.svg new file mode 100644 index 0000000..695ab03 --- /dev/null +++ b/assets/images/svg/contact_icon.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/assets/images/svg/emergency_services_icon.svg b/assets/images/svg/emergency_services_icon.svg new file mode 100644 index 0000000..e6dabad --- /dev/null +++ b/assets/images/svg/emergency_services_icon.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/assets/images/svg/health_calculators_icon.svg b/assets/images/svg/health_calculators_icon.svg new file mode 100644 index 0000000..b3a8913 --- /dev/null +++ b/assets/images/svg/health_calculators_icon.svg @@ -0,0 +1,3 @@ + + + diff --git a/assets/images/svg/home_calendar_icon.svg b/assets/images/svg/home_calendar_icon.svg new file mode 100644 index 0000000..8701a13 --- /dev/null +++ b/assets/images/svg/home_calendar_icon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/assets/images/svg/indoor_nav_icon.svg b/assets/images/svg/indoor_nav_icon.svg new file mode 100644 index 0000000..566a7e0 --- /dev/null +++ b/assets/images/svg/indoor_nav_icon.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/assets/images/svg/insurance_update.svg b/assets/images/svg/insurance_update.svg new file mode 100644 index 0000000..49a3e29 --- /dev/null +++ b/assets/images/svg/insurance_update.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/assets/images/svg/lab_result_icon.svg b/assets/images/svg/lab_result_icon.svg new file mode 100644 index 0000000..245048d --- /dev/null +++ b/assets/images/svg/lab_result_icon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/assets/images/svg/livecare_icon.svg b/assets/images/svg/livecare_icon.svg new file mode 100644 index 0000000..553f1a5 --- /dev/null +++ b/assets/images/svg/livecare_icon.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/assets/images/svg/my_prescription_icon.svg b/assets/images/svg/my_prescription_icon.svg new file mode 100644 index 0000000..4c9eaa4 --- /dev/null +++ b/assets/images/svg/my_prescription_icon.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/assets/images/svg/search_doctor_icon.svg b/assets/images/svg/search_doctor_icon.svg new file mode 100644 index 0000000..d19aed7 --- /dev/null +++ b/assets/images/svg/search_doctor_icon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/assets/langs/ar-SA.json b/assets/langs/ar-SA.json index 8ff2eb4..0a7ad1b 100644 --- a/assets/langs/ar-SA.json +++ b/assets/langs/ar-SA.json @@ -776,5 +776,6 @@ "validPassportNumber": "يرجى إدخال رقم جواز سفر صالح", "continuePlan": "متابعة خطة العلاج؟", "aboutApp": "حول التطبيق", - "dontHaveAccount": "ليس لديك حساب؟" + "dontHaveAccount": "ليس لديك حساب؟", + "loginOrRegister": "تسجيل الدخول أو التسجيل" } \ No newline at end of file diff --git a/assets/langs/en-US.json b/assets/langs/en-US.json index 423c67b..4c2c5c0 100644 --- a/assets/langs/en-US.json +++ b/assets/langs/en-US.json @@ -772,5 +772,6 @@ "aboutApp": "About the app", "aboutPoints": "Online Appointment Booking & rescheduling, Insurance approval status, Find A doctor, Ask your doctor, Medical prescriptions, Lab results, Hospitals contact numbers, Doctor profiles, Hospitals locations, Pharmacies Locations, Hospital's Virtual Tour, Official Social Media, Vaccines Schedule, Health Calculators, Other Services", "termsConditions": "These Online Services Terms of Use (Service Terms) govern certain online services provided by Dr Sulaiman Al Habib Medical Services Group Company (HMG, we, us, our)...", - "dontHaveAccount": "Don't have an account?" + "dontHaveAccount": "Don't have an account?", + "loginOrRegister": "Login or Register" } \ No newline at end of file diff --git a/ios/Podfile.lock b/ios/Podfile.lock index e5a28a8..5249fe5 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -3,7 +3,6 @@ PODS: - Flutter - connectivity_plus (0.0.1): - Flutter - - CryptoSwift (1.8.4) - device_calendar (0.0.1): - Flutter - device_info_plus (0.0.1): @@ -42,20 +41,11 @@ PODS: - file_picker (0.0.1): - DKImagePickerController/PhotoGallery - Flutter - - Firebase/Analytics (11.15.0): - - Firebase/Core - - Firebase/Core (11.15.0): - - Firebase/CoreOnly - - FirebaseAnalytics (~> 11.15.0) - Firebase/CoreOnly (11.15.0): - FirebaseCore (~> 11.15.0) - Firebase/Messaging (11.15.0): - Firebase/CoreOnly - FirebaseMessaging (~> 11.15.0) - - firebase_analytics (11.6.0): - - Firebase/Analytics (= 11.15.0) - - firebase_core - - Flutter - firebase_core (3.15.2): - Firebase/CoreOnly (= 11.15.0) - Flutter @@ -63,24 +53,6 @@ PODS: - Firebase/Messaging (= 11.15.0) - firebase_core - Flutter - - FirebaseAnalytics (11.15.0): - - FirebaseAnalytics/Default (= 11.15.0) - - FirebaseCore (~> 11.15.0) - - FirebaseInstallations (~> 11.0) - - GoogleUtilities/AppDelegateSwizzler (~> 8.1) - - GoogleUtilities/MethodSwizzler (~> 8.1) - - GoogleUtilities/Network (~> 8.1) - - "GoogleUtilities/NSData+zlib (~> 8.1)" - - nanopb (~> 3.30910.0) - - FirebaseAnalytics/Default (11.15.0): - - FirebaseCore (~> 11.15.0) - - FirebaseInstallations (~> 11.0) - - GoogleAppMeasurement/Default (= 11.15.0) - - GoogleUtilities/AppDelegateSwizzler (~> 8.1) - - GoogleUtilities/MethodSwizzler (~> 8.1) - - GoogleUtilities/Network (~> 8.1) - - "GoogleUtilities/NSData+zlib (~> 8.1)" - - nanopb (~> 3.30910.0) - FirebaseCore (11.15.0): - FirebaseCoreInternal (~> 11.15.0) - GoogleUtilities/Environment (~> 8.1) @@ -103,9 +75,6 @@ PODS: - nanopb (~> 3.30910.0) - FLAnimatedImage (1.0.17) - Flutter (1.0.0) - - flutter_callkit_incoming (0.0.1): - - CryptoSwift - - Flutter - flutter_inappwebview_ios (0.0.1): - Flutter - flutter_inappwebview_ios/Core (= 0.0.1) @@ -277,7 +246,6 @@ DEPENDENCIES: - firebase_messaging (from `.symlinks/plugins/firebase_messaging/ios`) - FLAnimatedImage - Flutter (from `Flutter`) - - flutter_callkit_incoming (from `.symlinks/plugins/flutter_callkit_incoming/ios`) - flutter_inappwebview_ios (from `.symlinks/plugins/flutter_inappwebview_ios/ios`) - flutter_ios_voip_kit_karmm (from `.symlinks/plugins/flutter_ios_voip_kit_karmm/ios`) - flutter_local_notifications (from `.symlinks/plugins/flutter_local_notifications/ios`) @@ -302,7 +270,6 @@ DEPENDENCIES: SPEC REPOS: trunk: - - CryptoSwift - DKImagePickerController - DKPhotoGallery - Firebase @@ -356,8 +323,6 @@ EXTERNAL SOURCES: :path: ".symlinks/plugins/firebase_messaging/ios" Flutter: :path: Flutter - flutter_callkit_incoming: - :path: ".symlinks/plugins/flutter_callkit_incoming/ios" flutter_inappwebview_ios: :path: ".symlinks/plugins/flutter_inappwebview_ios/ios" flutter_ios_voip_kit_karmm: @@ -400,24 +365,20 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: audio_session: 19e9480dbdd4e5f6c4543826b2e8b0e4ab6145fe connectivity_plus: 2a701ffec2c0ae28a48cf7540e279787e77c447d - CryptoSwift: e64e11850ede528a02a0f3e768cec8e9d92ecb90 device_calendar: 9cb33f88a02e19652ec7b8b122ca778f751b1f7b device_info_plus: bf2e3232933866d73fe290f2942f2156cdd10342 DKImagePickerController: 946cec48c7873164274ecc4624d19e3da4c1ef3c DKPhotoGallery: b3834fecb755ee09a593d7c9e389d8b5d6deed60 file_picker: b159e0c068aef54932bb15dc9fd1571818edaf49 Firebase: d99ac19b909cd2c548339c2241ecd0d1599ab02e - firebase_analytics: bf93e20703c95030404d6ddbb1adf05bf5c3885b firebase_core: 99a37263b3c27536063a7b601d9e2a49400a433c firebase_messaging: bf6697c61f31c7cc0f654131212ff04c0115c2c7 - FirebaseAnalytics: 6433dfd311ba78084fc93bdfc145e8cb75740eae FirebaseCore: efb3893e5b94f32b86e331e3bd6dadf18b66568e FirebaseCoreInternal: 9afa45b1159304c963da48addb78275ef701c6b4 FirebaseInstallations: 317270fec08a5d418fdbc8429282238cab3ac843 FirebaseMessaging: 3b26e2cee503815e01c3701236b020aa9b576f09 FLAnimatedImage: bbf914596368867157cc71b38a8ec834b3eeb32b - Flutter: cabc95a1d2626b1b06e7179b784ebcf0c0cde467 - flutter_callkit_incoming: 417dd1b46541cdd5d855ad795ccbe97d1c18155e + Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7 flutter_inappwebview_ios: 6f63631e2c62a7c350263b13fa5427aedefe81d4 flutter_ios_voip_kit_karmm: 7ea37381a8841c92d186edf1f4604df5cc437579 flutter_local_notifications: ff50f8405aaa0ccdc7dcfb9022ca192e8ad9688f @@ -426,8 +387,6 @@ SPEC CHECKSUMS: geolocator_apple: 66b711889fd333205763b83c9dcf0a57a28c7afd Google-Maps-iOS-Utils: 66d6de12be1ce6d3742a54661e7a79cb317a9321 google_maps_flutter_ios: e31555a04d1986ab130f2b9f24b6cdc861acc6d3 - GoogleAdsOnDeviceConversion: 2be6297a4f048459e0ae17fad9bfd2844e10cf64 - GoogleAppMeasurement: 700dce7541804bec33db590a5c496b663fbe2539 GoogleDataTransport: aae35b7ea0c09004c3797d53c8c41f66f219d6a7 GoogleMaps: 8939898920281c649150e0af74aa291c60f2e77d GoogleUtilities: 00c88b9a86066ef77f0da2fab05f65d7768ed8e1 @@ -464,4 +423,4 @@ SPEC CHECKSUMS: PODFILE CHECKSUM: 5df9d8aa8f2c105eacd5ad7a310503d93c68c86b -COCOAPODS: 1.16.2 +COCOAPODS: 1.15.2 diff --git a/lib/core/app_assets.dart b/lib/core/app_assets.dart index d56bc78..bfc1229 100644 --- a/lib/core/app_assets.dart +++ b/lib/core/app_assets.dart @@ -42,12 +42,22 @@ class AppAssets { static const String birthday_cake = '$svgBasePath/birthday-cake.svg'; static const String password_validation = '$svgBasePath/password-validation.svg'; static const String cloud_logo = '$svgBasePath/cloud_logo.svg'; - - - + static const String contact_icon = '$svgBasePath/contact_icon.svg'; + static const String emergency_services_icon = '$svgBasePath/emergency_services_icon.svg'; + static const String indoor_nav_icon = '$svgBasePath/indoor_nav_icon.svg'; + static const String search_doctor_icon = '$svgBasePath/search_doctor_icon.svg'; + static const String health_calculators_icon = '$svgBasePath/health_calculators_icon.svg'; + static const String lab_result_icon = '$svgBasePath/lab_result_icon.svg'; + static const String my_prescription_icon = '$svgBasePath/my_prescription_icon.svg'; + static const String insurance_update_icon = '$svgBasePath/insurance_update.svg'; + static const String home_calendar_icon = '$svgBasePath/home_calendar_icon.svg'; + static const String add_icon = '$svgBasePath/add_icon.svg'; + static const String livecare_icon = '$svgBasePath/livecare_icon.svg'; // PNGS // static const String hmg_logo = '$pngBasePath/hmg_logo.png'; + static const String livecare_service = '$pngBasePath/livecare_service.png'; + } class AppAnimations { diff --git a/lib/core/app_state.dart b/lib/core/app_state.dart index 71fb6a9..e58ba20 100644 --- a/lib/core/app_state.dart +++ b/lib/core/app_state.dart @@ -13,6 +13,8 @@ class AppState { //Tokens bool isAuthenticated = false; + bool isAuthenticated = true; + set setIsAuthenticated(v) => isAuthenticated = v; set setAppAuthToken(v) => appAuthToken = v; diff --git a/lib/core/utils/push-notification-handler.dart b/lib/core/utils/push-notification-handler.dart index 0cd3be7..d71bdcf 100644 --- a/lib/core/utils/push-notification-handler.dart +++ b/lib/core/utils/push-notification-handler.dart @@ -9,7 +9,7 @@ import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; -import 'package:flutter_callkit_incoming/flutter_callkit_incoming.dart'; +// import 'package:flutter_callkit_incoming/flutter_callkit_incoming.dart'; import 'package:flutter_local_notifications/flutter_local_notifications.dart'; import 'package:hmg_patient_app_new/core/utils/LocalNotification.dart'; @@ -319,7 +319,7 @@ class PushNotificationHandler { int sdkInt = androidInfo.version.sdkInt ?? 0; if (sdkInt >= 33) { - await FlutterCallkitIncoming.requestFullIntentPermission(); + // await FlutterCallkitIncoming.requestFullIntentPermission(); } } } diff --git a/lib/extensions/string_extensions.dart b/lib/extensions/string_extensions.dart index 2e74d25..b9d4ba8 100644 --- a/lib/extensions/string_extensions.dart +++ b/lib/extensions/string_extensions.dart @@ -26,7 +26,7 @@ extension EmailValidator on String { fontStyle: fontStyle ?? FontStyle.normal, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, - letterSpacing: 0.64, + letterSpacing: -0.4, ), ); @@ -39,7 +39,7 @@ extension EmailValidator on String { fontStyle: fontStyle ?? FontStyle.normal, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, - letterSpacing: 0.64, + letterSpacing: -0.4, decoration: isUnderLine ? TextDecoration.underline : null, decorationColor: color ?? AppColors.blackColor), ); @@ -53,7 +53,7 @@ extension EmailValidator on String { fontSize: 11.fSize, fontWeight: weight ?? (isBold ? FontWeight.bold : FontWeight.normal), color: color ?? AppColors.blackColor, - letterSpacing: letterSpacing, + letterSpacing: -0.4, decoration: isUnderLine ? TextDecoration.underline : null, ), ); @@ -66,7 +66,7 @@ extension EmailValidator on String { fontSize: 12.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, - letterSpacing: 0.64, + letterSpacing: -0.4, decorationColor: isUnderLine ? AppColors.blackColor : null, decoration: isUnderLine ? TextDecoration.underline : null, ), @@ -81,7 +81,7 @@ extension EmailValidator on String { fontSize: 12.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, - letterSpacing: 0.64, + letterSpacing: -0.4, decoration: isUnderLine ? TextDecoration.underline : null, ), ); @@ -129,7 +129,7 @@ extension EmailValidator on String { fontSize: 13.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, - letterSpacing: 0.64, + letterSpacing: -0.4, decoration: isUnderLine ? TextDecoration.underline : null), ); @@ -140,7 +140,7 @@ extension EmailValidator on String { style: TextStyle( color: color ?? AppColors.blackColor, fontSize: 14.fSize, - letterSpacing: 0.64, + letterSpacing: -0.4, fontWeight: weight ?? (isBold ? FontWeight.bold : FontWeight.normal), decoration: isUnderLine ? TextDecoration.underline : null), ); @@ -152,7 +152,7 @@ extension EmailValidator on String { style: TextStyle( color: color ?? AppColors.blackColor, fontSize: 15.fSize, - letterSpacing: 0.64, + letterSpacing: -0.4, fontWeight: weight ?? (isBold ? FontWeight.bold : FontWeight.normal), decoration: isUnderLine ? TextDecoration.underline : null), ); @@ -172,7 +172,7 @@ extension EmailValidator on String { style: TextStyle( color: color ?? AppColors.blackColor, fontSize: 16.fSize, - letterSpacing: 0.64, + letterSpacing: -0.4, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, decoration: isUnderLine ? TextDecoration.underline : null, ), @@ -181,53 +181,53 @@ extension EmailValidator on String { Widget toText17({Color? color, bool isBold = false, bool isCenter = false}) => Text( this, textAlign: isCenter ? TextAlign.center : null, - style: TextStyle(color: color ?? AppColors.blackColor, fontSize: 17.fSize, letterSpacing: 0.64, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), + style: TextStyle(color: color ?? AppColors.blackColor, fontSize: 17.fSize, letterSpacing: -0.4, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), ); Widget toText18({Color? color, bool isBold = false, bool isCenter = false, int? maxlines}) => Text( maxLines: maxlines, textAlign: isCenter ? TextAlign.center : null, this, - style: TextStyle(fontSize: 18.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, letterSpacing: 0.64), + style: TextStyle(fontSize: 18.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, letterSpacing: -0.4), ); Widget toText19({Color? color, bool isBold = false}) => Text( this, - style: TextStyle(fontSize: 19.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, letterSpacing: 0.64), + style: TextStyle(fontSize: 19.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, letterSpacing: -0.4), ); Widget toText20({Color? color, bool isBold = false}) => Text( this, - style: TextStyle(fontSize: 20.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, letterSpacing: 0.64), + style: TextStyle(fontSize: 20.fSize, fontWeight: isBold ? FontWeight.bold : FontWeight.normal, color: color ?? AppColors.blackColor, letterSpacing: -0.4), ); Widget toText21({Color? color, bool isBold = false, FontWeight? weight, int? maxlines}) => Text( this, maxLines: maxlines, - style: TextStyle(color: color ?? AppColors.blackColor, fontSize: 21.fSize, letterSpacing: 0.64, fontWeight: weight ?? (isBold ? FontWeight.bold : FontWeight.normal)), + style: TextStyle(color: color ?? AppColors.blackColor, fontSize: 21.fSize, letterSpacing: -0.4, fontWeight: weight ?? (isBold ? FontWeight.bold : FontWeight.normal)), ); Widget toText22({Color? color, bool isBold = false, bool isCenter = false}) => Text( this, textAlign: isCenter ? TextAlign.center : null, - style: TextStyle(height: 1, color: color ?? AppColors.blackColor, fontSize: 22.fSize, letterSpacing: 0.64, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), + style: TextStyle(height: 1, color: color ?? AppColors.blackColor, fontSize: 22.fSize, letterSpacing: -0.4, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), ); Widget toText24({Color? color, bool isBold = false, bool isCenter = false}) => Text( this, textAlign: isCenter ? TextAlign.center : null, - style: TextStyle(height: 23 / 24, color: color ?? AppColors.blackColor, fontSize: 24.fSize, letterSpacing: 0.64, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), + style: TextStyle(height: 23 / 24, color: color ?? AppColors.blackColor, fontSize: 24.fSize, letterSpacing: -0.4, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), ); Widget toText32({Color? color, bool isBold = false, bool isCenter = false}) => Text( this, textAlign: isCenter ? TextAlign.center : null, - style: TextStyle(height: 32 / 32, color: color ?? AppColors.blackColor, fontSize: 32.fSize, letterSpacing: 0.64, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), + style: TextStyle(height: 32 / 32, color: color ?? AppColors.blackColor, fontSize: 32.fSize, letterSpacing: -0.4, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), ); Widget toText44({Color? color, bool isBold = false}) => Text( this, - style: TextStyle(height: 32 / 32, color: color ?? AppColors.blackColor, fontSize: 44.fSize, letterSpacing: 0.64, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), + style: TextStyle(height: 32 / 32, color: color ?? AppColors.blackColor, fontSize: 44.fSize, letterSpacing: -0.4, fontWeight: isBold ? FontWeight.bold : FontWeight.normal), ); Widget toSectionHeading({String upperHeading = "", String lowerHeading = ""}) { diff --git a/lib/generated/locale_keys.g.dart b/lib/generated/locale_keys.g.dart index b2d7492..6ef6804 100644 --- a/lib/generated/locale_keys.g.dart +++ b/lib/generated/locale_keys.g.dart @@ -775,5 +775,6 @@ abstract class LocaleKeys { static const continuePlan = 'continuePlan'; static const aboutApp = 'aboutApp'; static const dontHaveAccount = 'dontHaveAccount'; + static const loginOrRegister = 'loginOrRegister'; } diff --git a/lib/main.dart b/lib/main.dart index 446f8da..7b2e93c 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -8,6 +8,8 @@ import 'package:flutter/services.dart'; import 'package:hmg_patient_app_new/core/app_state.dart'; import 'package:hmg_patient_app_new/core/dependencies.dart'; import 'package:hmg_patient_app_new/features/authentication/authentication_view_model.dart'; +import 'package:hmg_patient_app_new/providers/authentication_view_model.dart'; +import 'package:hmg_patient_app_new/providers/bottom_navigation_provider.dart'; import 'package:hmg_patient_app_new/routes/app_routes.dart'; import 'package:hmg_patient_app_new/services/logger_service.dart'; import 'package:hmg_patient_app_new/theme/app_theme.dart'; @@ -55,6 +57,9 @@ void main() async { path: 'assets/langs', fallbackLocale: Locale('en', 'US'), child: MultiProvider(providers: [ + ChangeNotifierProvider( + create: (_) => BottomNavigationProvider(), + ), ChangeNotifierProvider( create: (_) => AuthenticationViewModel(authenticationRepo: getIt(), appState: getIt()), ), @@ -82,7 +87,7 @@ class MyApp extends StatelessWidget { return MediaQuery( data: MediaQuery.of(context).copyWith( textScaler: TextScaler.linear(1.0), - ), //set desired text scale factor here + ), child: mchild!); }, showSemanticsDebugger: false, diff --git a/lib/presentation/authentication/login.dart b/lib/presentation/authentication/login.dart index 2699a91..fb88ba1 100644 --- a/lib/presentation/authentication/login.dart +++ b/lib/presentation/authentication/login.dart @@ -6,22 +6,35 @@ import 'package:hmg_patient_app_new/core/app_assets.dart'; import 'package:hmg_patient_app_new/core/utils/utils.dart'; import 'package:hmg_patient_app_new/extensions/string_extensions.dart'; import 'package:hmg_patient_app_new/extensions/widget_extensions.dart'; -import 'package:hmg_patient_app_new/features/authentication/authentication_view_model.dart'; import 'package:hmg_patient_app_new/generated/locale_keys.g.dart'; import 'package:hmg_patient_app_new/theme/colors.dart'; import 'package:hmg_patient_app_new/widgets/appbar/app_bar_widget.dart'; import 'package:hmg_patient_app_new/widgets/buttons/custom_button.dart'; import 'package:hmg_patient_app_new/widgets/input_widget.dart'; -import 'package:sizer/sizer.dart'; +import 'package:sizer/sizer.dart'; // Import sizer -class LoginScreen extends StatelessWidget { - const LoginScreen({super.key}); +class LoginScreen extends StatefulWidget { + @override + _LoginScreen createState() => _LoginScreen(); +} + +class _LoginScreen extends State { + @override + void initState() { + super.initState(); + } + + @override + void dispose() { + super.dispose(); + } @override Widget build(BuildContext context) { return Sizer(// Wrap with Sizer builder: (context, orientation, deviceType) { return Scaffold( + backgroundColor: AppColors.bgScaffoldColor, appBar: CustomAppBar( onBackPressed: () { }, @@ -43,16 +56,17 @@ class LoginScreen extends StatelessWidget { children: [ Utils.showLottie(context: context, assetPath: AppAnimations.login, width: 45.w, height: 22.h, repeat: true, fit: BoxFit.cover), SizedBox(height: 19.h), // Adjusted to sizer unit - Text( - LocaleKeys.welcomeToDrSulaiman.tr(), - style: context.dynamicTextStyle( - fontSize: 22.sp, - fontWeight: FontWeight.w600, - color: AppColors.textColor, - letterSpacing: -0.4, - height: 40 / 28, - ), - ), + LocaleKeys.welcomeToDrSulaiman.tr().toText22(isBold: true, color: AppColors.textColor), + // Text( + // LocaleKeys.welcomeToDrSulaiman.tr(), + // style: context.dynamicTextStyle( + // fontSize: 22, + // fontWeight: FontWeight.w600, + // color: AppColors.textColor, + // letterSpacing: -0.4, + // height: 40 / 28, + // ), + // ), SizedBox(height: 4.h), // Adjusted to sizer unit (approx 32px) TextInputWidget( labelText: "${LocaleKeys.nationalId.tr()} / ${LocaleKeys.fileNo.tr()}", diff --git a/lib/presentation/home/data/landing_page_data.dart b/lib/presentation/home/data/landing_page_data.dart new file mode 100644 index 0000000..af43b9f --- /dev/null +++ b/lib/presentation/home/data/landing_page_data.dart @@ -0,0 +1,165 @@ +import 'dart:ui'; + +import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/core/app_assets.dart'; +import 'package:hmg_patient_app_new/presentation/home/data/service_card_data.dart'; +import 'package:hmg_patient_app_new/theme/colors.dart'; + +class LandingPageData { + static List getNotLoggedInServiceCardsList = [ + ServiceCardData( + icon: AppAssets.emergency_services_icon, + title: "Emergency", + subtitle: "Services", + backgroundColor: AppColors.primaryRedColor, + iconColor: AppColors.whiteColor, + textColor: AppColors.whiteColor, + isBold: true, + ), + ServiceCardData( + icon: AppAssets.indoor_nav_icon, + title: "Indoor", + subtitle: "Navigation", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.search_doctor_icon, + title: "Search", + subtitle: "Doctor", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.health_calculators_icon, + title: "Health", + subtitle: "Calculators", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.health_calculators_icon, + title: "Health", + subtitle: "Converters", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.health_calculators_icon, + title: "Parking", + subtitle: "Guide", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ]; + + static List getLoggedInServiceCardsList = [ + ServiceCardData( + icon: AppAssets.emergency_services_icon, + title: "Emergency", + subtitle: "Services", + backgroundColor: AppColors.primaryRedColor, + iconColor: AppColors.whiteColor, + textColor: AppColors.whiteColor, + isBold: true, + ), + ServiceCardData( + icon: AppAssets.lab_result_icon, + title: "My Lab", + subtitle: "Results", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.my_prescription_icon, + title: "My", + subtitle: "Prescriptions", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.insurance_update_icon, + title: "Insurance", + subtitle: "Update", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.insurance_update_icon, + title: "My", + subtitle: "Doctors", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.insurance_update_icon, + title: "My Sick", + subtitle: "Leaves", + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ]; + + static List getServiceCardsList = [ + ServiceCardData( + icon: AppAssets.livecare_service, + title: "LiveCare", + subtitle: "Explore our app, View our services and offers", + largeCardIcon: AppAssets.livecare_icon, + backgroundColor: Colors.transparent, + iconColor: Colors.transparent, + textColor: Colors.transparent, + isBold: true, + ), + ServiceCardData( + icon: AppAssets.lab_result_icon, + title: "Dermatology", + subtitle: "Explore our app, View our services and offers", + largeCardIcon: AppAssets.livecare_icon, + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.my_prescription_icon, + title: "Home Health Care", + subtitle: "Explore our app, View our services and offers", + largeCardIcon: AppAssets.livecare_icon, + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ServiceCardData( + icon: AppAssets.insurance_update_icon, + title: "Pharmacy", + subtitle: "Explore our app, View our services and offers", + largeCardIcon: AppAssets.livecare_icon, + backgroundColor: AppColors.whiteColor, + iconColor: AppColors.blackColor, + textColor: AppColors.blackColor, + isBold: false, + ), + ]; +} diff --git a/lib/presentation/home/data/service_card_data.dart b/lib/presentation/home/data/service_card_data.dart new file mode 100644 index 0000000..856a15e --- /dev/null +++ b/lib/presentation/home/data/service_card_data.dart @@ -0,0 +1,25 @@ +import 'dart:ui'; + +import 'package:hmg_patient_app_new/theme/colors.dart'; + +class ServiceCardData { + final String icon; + final String title; + final String subtitle; + final Color iconColor; + final Color textColor; + final Color backgroundColor; + final bool isBold; + final String largeCardIcon; + + ServiceCardData({ + this.icon = "", + this.title = "", + this.subtitle = "", + this.largeCardIcon = "", + this.backgroundColor = AppColors.whiteColor, + this.iconColor = AppColors.blackColor, + this.textColor = AppColors.blackColor, + this.isBold = false, + }); +} diff --git a/lib/presentation/home/landing_page.dart b/lib/presentation/home/landing_page.dart index d371213..0397056 100644 --- a/lib/presentation/home/landing_page.dart +++ b/lib/presentation/home/landing_page.dart @@ -1,8 +1,24 @@ +import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; +import 'package:flutter_staggered_animations/flutter_staggered_animations.dart'; +import 'package:hmg_patient_app_new/core/app_state.dart'; +import 'package:hmg_patient_app_new/core/utils/size_utils.dart'; +import 'package:hmg_patient_app_new/extensions/int_extensions.dart'; import 'package:hmg_patient_app_new/extensions/string_extensions.dart'; -import 'package:hmg_patient_app_new/features/authentication/authentication_view_model.dart'; +import 'package:hmg_patient_app_new/extensions/widget_extensions.dart'; +import 'package:hmg_patient_app_new/generated/locale_keys.g.dart'; +import 'package:hmg_patient_app_new/presentation/home/data/landing_page_data.dart'; +import 'package:hmg_patient_app_new/presentation/home/widgets/large_service_card.dart'; +import 'package:hmg_patient_app_new/presentation/home/widgets/small_service_card.dart'; +import 'package:hmg_patient_app_new/providers/authentication_view_model.dart'; +import 'package:hmg_patient_app_new/providers/bottom_navigation_provider.dart'; +import 'package:hmg_patient_app_new/theme/colors.dart'; import 'package:provider/provider.dart'; +import '../../core/app_assets.dart'; +import '../../core/utils/utils.dart'; +import '../../widgets/buttons/custom_button.dart'; + class LandingPage extends StatefulWidget { const LandingPage({super.key}); @@ -11,25 +27,265 @@ class LandingPage extends StatefulWidget { } class _LandingPageState extends State { + late AuthenticationViewModel authenticationViewModel; @override Widget build(BuildContext context) { - AuthenticationViewModel authenticationViewModel = context.read();; - - return Scaffold( - body: Column( - children: [ - InkWell( - onTap: () { - authenticationViewModel.selectDeviceImei(); - }, - child: Padding( - padding: const EdgeInsets.all(64.0), - child: "Login".toText18(color: Colors.black), + return Consumer(builder: (context, navigationProvider, child) { + return Scaffold( + backgroundColor: AppColors.bgScaffoldColor, + body: Padding( + padding: EdgeInsets.all(24.h), + child: SingleChildScrollView( + child: Column( + children: [ + Padding( + padding: EdgeInsets.only(top: 50.0), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + CustomButton( + text: LocaleKeys.loginOrRegister.tr(context: context), + onPressed: () { + Navigator.of(context).pushReplacement( + MaterialPageRoute(builder: (BuildContext context) => LandingPage()), + ); + }, + backgroundColor: Color(0xffFEE9EA), + borderColor: Color(0xffFEE9EA), + textColor: Color(0xffED1C2B), + fontSize: 16, + fontWeight: FontWeight.w500, + borderRadius: 12, + padding: EdgeInsets.fromLTRB(10, 0, 10, 0), + height: 50, + ), + Utils.buildSvgWithAssets( + icon: AppAssets.contact_icon, + width: 24, + height: 24, + ), + ], + ), + ), + SizedBox(height: 16.h), + AppState().isAuthenticated + ? Column( + children: [ + Container( + width: double.infinity, + decoration: RoundedRectangleBorder().toSmoothCornerDecoration( + color: AppColors.whiteColor, + borderRadius: 24, + ), + child: Padding( + padding: EdgeInsets.all(12.h), + child: Container( + child: Column( + children: [ + Utils.buildSvgWithAssets(icon: AppAssets.home_calendar_icon, width: 32.h, height: 32.h), + SizedBox(height: 12.h), + "You do not have any upcoming appointment. Please book an appointment".toText12(isCenter: true), + SizedBox(height: 12.h), + CustomButton( + text: LocaleKeys.bookAppo.tr(context: context), + onPressed: () { + Navigator.of(context).pushReplacement( + MaterialPageRoute(builder: (BuildContext context) => LandingPage()), + ); + }, + backgroundColor: Color(0xffFEE9EA), + borderColor: Color(0xffFEE9EA), + textColor: Color(0xffED1C2B), + fontSize: 14, + fontWeight: FontWeight.w500, + borderRadius: 12, + padding: EdgeInsets.fromLTRB(10, 0, 10, 0), + height: 40, + icon: AppAssets.add_icon, + iconColor: AppColors.primaryRedColor, + ), + ], + ), + ), + ), + ), + SizedBox(height: 12.h), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + "Quick Links".toText14(isBold: true), + Row( + children: [ + "View medical file".toText12(color: AppColors.primaryRedColor), + SizedBox(width: 2.h), + Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 10.h), + ], + ), + ], + ), + SizedBox(height: 12.h), + Container( + height: 127.h, + decoration: RoundedRectangleBorder().toSmoothCornerDecoration( + color: AppColors.whiteColor, + borderRadius: 24, + ), + child: Padding( + padding: EdgeInsets.all(16.h), + child: Column( + children: [ + Expanded( + child: ListView.separated( + scrollDirection: Axis.horizontal, + itemCount: LandingPageData.getLoggedInServiceCardsList.length, + shrinkWrap: true, + padding: const EdgeInsets.only(left: 0, right: 8), + itemBuilder: (context, index) { + return AnimationConfiguration.staggeredList( + position: index, + duration: const Duration(milliseconds: 1000), + child: SlideAnimation( + horizontalOffset: 100.0, + child: FadeInAnimation( + child: SmallServiceCard( + icon: LandingPageData.getLoggedInServiceCardsList[index].icon, + title: LandingPageData.getLoggedInServiceCardsList[index].title, + subtitle: LandingPageData.getLoggedInServiceCardsList[index].subtitle, + iconColor: LandingPageData.getLoggedInServiceCardsList[index].iconColor, + textColor: LandingPageData.getLoggedInServiceCardsList[index].textColor, + backgroundColor: LandingPageData.getLoggedInServiceCardsList[index].backgroundColor, + isBold: LandingPageData.getLoggedInServiceCardsList[index].isBold, + ), + ), + ), + ); + }, + separatorBuilder: (BuildContext cxt, int index) => 0.width, + ), + ), + ], + ), + ), + ) + ], + ) + : Container( + height: 127.h, + decoration: RoundedRectangleBorder().toSmoothCornerDecoration( + color: AppColors.whiteColor, + borderRadius: 24, + ), + child: Padding( + padding: EdgeInsets.all(16.h), + child: Column( + children: [ + Expanded( + child: ListView.separated( + scrollDirection: Axis.horizontal, + itemCount: LandingPageData.getNotLoggedInServiceCardsList.length, + shrinkWrap: true, + padding: const EdgeInsets.only(left: 0, right: 8), + itemBuilder: (context, index) { + return AnimationConfiguration.staggeredList( + position: index, + duration: const Duration(milliseconds: 1000), + child: SlideAnimation( + horizontalOffset: 100.0, + child: FadeInAnimation( + child: SmallServiceCard( + icon: LandingPageData.getNotLoggedInServiceCardsList[index].icon, + title: LandingPageData.getNotLoggedInServiceCardsList[index].title, + subtitle: LandingPageData.getNotLoggedInServiceCardsList[index].subtitle, + iconColor: LandingPageData.getNotLoggedInServiceCardsList[index].iconColor, + textColor: LandingPageData.getNotLoggedInServiceCardsList[index].textColor, + backgroundColor: LandingPageData.getNotLoggedInServiceCardsList[index].backgroundColor, + isBold: LandingPageData.getNotLoggedInServiceCardsList[index].isBold, + ), + ), + ), + ); + }, + separatorBuilder: (BuildContext cxt, int index) => 0.width, + ), + ), + ], + ), + ), + ), + SizedBox(height: 16.h), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + "Services".toText14(isBold: true), + Row( + children: [ + "View all services".toText12(color: AppColors.primaryRedColor), + SizedBox(width: 2.h), + Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 10.h), + ], + ), + ], + ), + SizedBox(height: 16.h), + SizedBox( + height: 325.h, + child: Column( + children: [ + Expanded( + child: ListView.separated( + scrollDirection: Axis.horizontal, + itemCount: LandingPageData.getServiceCardsList.length, + shrinkWrap: true, + padding: const EdgeInsets.only(left: 0, right: 8), + itemBuilder: (context, index) { + return AnimationConfiguration.staggeredList( + position: index, + duration: const Duration(milliseconds: 1000), + child: SlideAnimation( + horizontalOffset: 100.0, + child: FadeInAnimation( + child: LargeServiceCard( + image: LandingPageData.getServiceCardsList[index].icon, + title: LandingPageData.getServiceCardsList[index].title, + subtitle: LandingPageData.getServiceCardsList[index].subtitle, + icon: LandingPageData.getServiceCardsList[index].largeCardIcon, + ), + ), + ), + ); + }, + separatorBuilder: (BuildContext cxt, int index) => 0.width, + ), + ), + ], + ), + ), + SizedBox(height: 16.h), + AppState().isAuthenticated + ? Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + "My Balance".toText14(isBold: true), + Row( + children: [ + "View all services".toText12(color: AppColors.primaryRedColor), + SizedBox(width: 2.h), + Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 10.h), + ], + ), + ], + ), + ], + ) + : SizedBox(), + ], ), ), - ], - ), - ); + ), + ); + }); } } diff --git a/lib/presentation/home/widgets/large_service_card.dart b/lib/presentation/home/widgets/large_service_card.dart new file mode 100644 index 0000000..8318798 --- /dev/null +++ b/lib/presentation/home/widgets/large_service_card.dart @@ -0,0 +1,77 @@ +import 'package:easy_localization/easy_localization.dart'; +import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/core/app_assets.dart'; +import 'package:hmg_patient_app_new/core/utils/size_utils.dart'; +import 'package:hmg_patient_app_new/extensions/string_extensions.dart'; +import 'package:hmg_patient_app_new/extensions/widget_extensions.dart'; +import 'package:hmg_patient_app_new/generated/locale_keys.g.dart'; +import 'package:hmg_patient_app_new/widgets/buttons/custom_button.dart'; + +import '../../../core/utils/utils.dart'; +import '../../../theme/colors.dart'; + +class LargeServiceCard extends StatelessWidget { + final String image; + final String icon; + final String title; + final String subtitle; + + LargeServiceCard({ + super.key, + this.image = "", + this.icon = "", + this.title = "", + this.subtitle = "", + }); + + @override + Widget build(BuildContext context) { + return Padding( + padding: EdgeInsets.symmetric(horizontal: 3.h), + child: Container( + decoration: RoundedRectangleBorder().toSmoothCornerDecoration( + color: Colors.transparent, + borderRadius: 16, + ), + child: Padding( + padding: EdgeInsets.symmetric(horizontal: 8.h), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Image.asset(AppAssets.livecare_service, width: 220.h, height: 220.h, fit: BoxFit.contain), + SizedBox(height: 3.h), + Row( + children: [ + Utils.buildSvgWithAssets(icon: icon, width: 24.h, height: 24.h), + title.toText14(color: AppColors.blackColor, isBold: true), + ], + ), + SizedBox(width: 220.h, child: subtitle.toText11(color: AppColors.blackColor)), + SizedBox(height: 6.h), + SizedBox( + width: 220.h, + child: CustomButton( + text: LocaleKeys.bookNow.tr(context: context), + onPressed: () { + // Navigator.of(context).pushReplacement( + // MaterialPageRoute(builder: (BuildContext context) => LandingPage()), + // ); + }, + backgroundColor: AppColors.borderOnlyColor, + borderColor: AppColors.borderOnlyColor, + textColor: AppColors.whiteColor, + fontSize: 14, + fontWeight: FontWeight.bold, + borderRadius: 12, + padding: EdgeInsets.fromLTRB(10, 0, 10, 0), + height: 40.h, + ), + ), + ], + ), + ), + ), + ); + } +} diff --git a/lib/presentation/home/widgets/small_service_card.dart b/lib/presentation/home/widgets/small_service_card.dart new file mode 100644 index 0000000..a138db6 --- /dev/null +++ b/lib/presentation/home/widgets/small_service_card.dart @@ -0,0 +1,53 @@ +import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/core/utils/size_utils.dart'; +import 'package:hmg_patient_app_new/extensions/string_extensions.dart'; +import 'package:hmg_patient_app_new/extensions/widget_extensions.dart'; + +import '../../../core/utils/utils.dart'; +import '../../../theme/colors.dart'; + +class SmallServiceCard extends StatelessWidget { + final String icon; + final String title; + final String subtitle; + final Color iconColor; + final Color textColor; + final Color backgroundColor; + final bool isBold; + + SmallServiceCard({ + super.key, + this.icon = "", + this.title = "", + this.subtitle = "", + this.backgroundColor = AppColors.whiteColor, + this.iconColor = AppColors.blackColor, + this.textColor = AppColors.blackColor, + this.isBold = false, + }); + + @override + Widget build(BuildContext context) { + return Padding( + padding: EdgeInsets.symmetric(horizontal: 3.h), + child: Container( + decoration: RoundedRectangleBorder().toSmoothCornerDecoration( + color: backgroundColor, + borderRadius: 16, + ), + child: Padding( + padding: EdgeInsets.all(12.0), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Utils.buildSvgWithAssets(icon: icon, iconColor: iconColor, width: 32.h, height: 32.h), + SizedBox(height: 6.h), + title.toText11(color: textColor, isBold: isBold, isCenter: true), + subtitle.toText11(color: textColor, isBold: isBold, isCenter: true), + ], + ), + ), + ), + ); + } +} diff --git a/lib/presentation/medical_file/medical_file_page.dart b/lib/presentation/medical_file/medical_file_page.dart new file mode 100644 index 0000000..dff7f75 --- /dev/null +++ b/lib/presentation/medical_file/medical_file_page.dart @@ -0,0 +1,23 @@ +import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/theme/colors.dart'; + +class MedicalFilePage extends StatelessWidget { + const MedicalFilePage({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bgScaffoldColor, + appBar: AppBar( + title: const Text('Appointments'), + backgroundColor: AppColors.bgScaffoldColor, + ), + body: const Center( + child: Text( + 'Appointments Page', + style: TextStyle(fontSize: 24), + ), + ), + ); + } +} \ No newline at end of file diff --git a/lib/presentation/services/services_page.dart b/lib/presentation/services/services_page.dart new file mode 100644 index 0000000..24a259b --- /dev/null +++ b/lib/presentation/services/services_page.dart @@ -0,0 +1,23 @@ +import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/theme/colors.dart'; + +class ServicesPage extends StatelessWidget { + const ServicesPage({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bgScaffoldColor, + appBar: AppBar( + title: const Text('Appointments'), + backgroundColor: AppColors.bgScaffoldColor, + ), + body: const Center( + child: Text( + 'Appointments Page', + style: TextStyle(fontSize: 24), + ), + ), + ); + } +} \ No newline at end of file diff --git a/lib/presentation/todo/todo_page.dart b/lib/presentation/todo/todo_page.dart new file mode 100644 index 0000000..65b762f --- /dev/null +++ b/lib/presentation/todo/todo_page.dart @@ -0,0 +1,23 @@ +import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/theme/colors.dart'; + +class ToDoPage extends StatelessWidget { + const ToDoPage({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: AppColors.bgScaffoldColor, + appBar: AppBar( + title: const Text('Appointments'), + backgroundColor: AppColors.bgScaffoldColor, + ), + body: const Center( + child: Text( + 'Appointments Page', + style: TextStyle(fontSize: 24), + ), + ), + ); + } +} \ No newline at end of file diff --git a/lib/providers/bottom_navigation_provider.dart b/lib/providers/bottom_navigation_provider.dart new file mode 100644 index 0000000..58a0d4e --- /dev/null +++ b/lib/providers/bottom_navigation_provider.dart @@ -0,0 +1,12 @@ +import 'package:flutter/material.dart'; + +class BottomNavigationProvider extends ChangeNotifier { + int _currentIndex = 0; + + int get currentIndex => _currentIndex; + + void setIndex(int index) { + _currentIndex = index; + notifyListeners(); + } +} \ No newline at end of file diff --git a/lib/theme/colors.dart b/lib/theme/colors.dart index a537412..09e2a38 100644 --- a/lib/theme/colors.dart +++ b/lib/theme/colors.dart @@ -21,6 +21,7 @@ class AppColors { // New UI Colors static const whiteColor = Color(0xFFffffff); + static const Color bgScaffoldColor = Color(0xffF8F8F8); static const Color primaryRedColor = Color(0xFFED1C2B); static const Color primaryRedBorderColor = Color(0xFFED1C2B); static const Color secondaryLightRedColor = Color(0xFFFEE9EA); diff --git a/lib/widgets/buttons/custom_button.dart b/lib/widgets/buttons/custom_button.dart index 7d50d09..e08189a 100644 --- a/lib/widgets/buttons/custom_button.dart +++ b/lib/widgets/buttons/custom_button.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:hmg_patient_app_new/core/app_export.dart'; import 'package:hmg_patient_app_new/core/utils/utils.dart'; import 'package:hmg_patient_app_new/extensions/string_extensions.dart'; import 'package:hmg_patient_app_new/extensions/widget_extensions.dart'; @@ -18,6 +19,7 @@ class CustomButton extends StatelessWidget { final FontWeight fontWeight; final bool isDisabled; final Color iconColor; + final double height; CustomButton({ Key? key, @@ -35,6 +37,7 @@ class CustomButton extends StatelessWidget { this.isDisabled = false, this.icon, this.iconColor = Colors.white, + this.height = 56, }) : super(key: key); @override @@ -42,7 +45,7 @@ class CustomButton extends StatelessWidget { return GestureDetector( onTap: isDisabled ? null : onPressed, child: Container( - height: 56, + height: height, decoration: RoundedRectangleBorder().toSmoothCornerDecoration( color: isDisabled ? Colors.transparent : backgroundColor, borderRadius: borderRadius, @@ -64,8 +67,9 @@ class CustomButton extends StatelessWidget { Text( text, style: context.dynamicTextStyle( - fontSize: fontSize, + fontSize: fontSize.fSize, color: isDisabled ? textColor.withOpacity(0.5) : textColor, + letterSpacing: -0.4, fontWeight: fontWeight, ), ), diff --git a/pubspec.lock b/pubspec.lock index 0695fc8..c503e1b 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -399,15 +399,6 @@ packages: url: "https://pub.dev" source: hosted version: "3.4.1" - flutter_callkit_incoming: - dependency: "direct main" - description: - path: "." - ref: dev - resolved-ref: "4b5aa9798a77eaba1c1726c314c5de74cd37ad6d" - url: "https://github.com/hiennguyen92/flutter_callkit_incoming.git" - source: git - version: "2.5.8" flutter_hooks: dependency: transitive description: @@ -549,6 +540,14 @@ packages: url: "https://pub.dev" source: hosted version: "4.0.1" + flutter_staggered_animations: + dependency: "direct main" + description: + name: flutter_staggered_animations + sha256: "81d3c816c9bb0dca9e8a5d5454610e21ffb068aedb2bde49d2f8d04f75538351" + url: "https://pub.dev" + source: hosted + version: "1.1.1" flutter_svg: dependency: "direct main" description: diff --git a/pubspec.yaml b/pubspec.yaml index 6c79c92..4c2b81f 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -33,10 +33,10 @@ dependencies: provider: ^6.1.5+1 get_it: ^8.2.0 just_audio: ^0.10.4 - flutter_callkit_incoming: - git: - url: https://github.com/hiennguyen92/flutter_callkit_incoming.git - ref: dev +# flutter_callkit_incoming: +# git: +# url: https://github.com/hiennguyen92/flutter_callkit_incoming.git +# ref: dev url_launcher: ^6.3.2 logger: ^2.6.1 lottie: ^3.3.1 @@ -66,6 +66,7 @@ dependencies: firebase_analytics: ^11.5.1 web: any + flutter_staggered_animations: ^1.1.1 smooth_corner: ^1.1.1 dev_dependencies: @@ -89,32 +90,32 @@ flutter: fonts: - family: Poppins fonts: - - asset: assets/fonts/poppins/Poppins-Black.ttf - weight: 900 - - asset: assets/fonts/poppins/Poppins-ExtraBold.ttf - weight: 800 - - asset: assets/fonts/poppins/Poppins-Bold.ttf - weight: 700 +# - asset: assets/fonts/poppins/Poppins-Black.ttf +# weight: 900 +# - asset: assets/fonts/poppins/Poppins-ExtraBold.ttf +# weight: 800 +# - asset: assets/fonts/poppins/Poppins-Bold.ttf +# weight: 700 - asset: assets/fonts/poppins/Poppins-SemiBold.ttf weight: 600 - - asset: assets/fonts/poppins/Poppins-Medium.ttf - weight: 500 +# - asset: assets/fonts/poppins/Poppins-Medium.ttf +# weight: 500 - asset: assets/fonts/poppins/Poppins-Regular.ttf weight: 400 - - asset: assets/fonts/poppins/Poppins-Light.ttf - weight: 300 - - asset: assets/fonts/poppins/Poppins-ExtraLight.ttf - weight: 200 - - asset: assets/fonts/poppins/Poppins-Thin.ttf - weight: 100 +# - asset: assets/fonts/poppins/Poppins-Light.ttf +# weight: 300 +# - asset: assets/fonts/poppins/Poppins-ExtraLight.ttf +# weight: 200 +# - asset: assets/fonts/poppins/Poppins-Thin.ttf +# weight: 100 - family: GESSTwo fonts: - asset: assets/fonts/gess_two/GE_SS_Two_Bold.otf weight: 600 - - asset: assets/fonts/gess_two/GE_SS_Two_Medium.otf - weight: 500 +# - asset: assets/fonts/gess_two/GE_SS_Two_Medium.otf +# weight: 500 - asset: assets/fonts/gess_two/GE_SS_Two_Light.otf weight: 400