diff --git a/assets/images/online_payment_icon.png b/assets/images/online_payment_icon.png new file mode 100644 index 00000000..a6e0150a Binary files /dev/null and b/assets/images/online_payment_icon.png differ diff --git a/assets/images/search_medicine_icon.png b/assets/images/search_medicine_icon.png new file mode 100644 index 00000000..349620a5 Binary files /dev/null and b/assets/images/search_medicine_icon.png differ diff --git a/assets/images/vital_sign_icon.png b/assets/images/vital_sign_icon.png new file mode 100644 index 00000000..fbd0908b Binary files /dev/null and b/assets/images/vital_sign_icon.png differ diff --git a/lib/pages/landing/home_page.dart b/lib/pages/landing/home_page.dart index e8542edc..550eae30 100644 --- a/lib/pages/landing/home_page.dart +++ b/lib/pages/landing/home_page.dart @@ -83,7 +83,7 @@ class _HomePageState extends State { ], ), ), - Container(width: double.infinity, height: MediaQuery.of(context).size.height * 0.12), + Container(width: double.infinity, height: 125), ], ), Positioned( @@ -93,7 +93,7 @@ class _HomePageState extends State { child: (!model.isLogin && projectViewModel.user == null) ? Container( width: double.infinity, - height: MediaQuery.of(context).size.height * 0.17, + height: 180, decoration: BoxDecoration( color: Theme.of(context).primaryColor, shape: BoxShape.rectangle, @@ -166,7 +166,7 @@ class _HomePageState extends State { ) : Container( width: double.infinity, - height: MediaQuery.of(context).size.height * 0.17, + height: projectViewModel.isArabic?180: 150, decoration: BoxDecoration( color: Theme.of(context).primaryColor, shape: BoxShape.rectangle, @@ -184,7 +184,7 @@ class _HomePageState extends State { child: Container( margin: EdgeInsets.all(5), child: Column( - mainAxisAlignment: MainAxisAlignment.spaceBetween, + // mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Row( children: [ @@ -289,7 +289,8 @@ class _HomePageState extends State { Expanded( child: Row( mainAxisAlignment: MainAxisAlignment.start, - crossAxisAlignment: CrossAxisAlignment.center, children: [ + crossAxisAlignment: CrossAxisAlignment.center, + children: [ Image.asset( 'assets/images/test-weight.png', width: 30, @@ -357,130 +358,144 @@ class _HomePageState extends State { child: Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ - DashboardItem( - onTap: () { - Navigator.push( - context, - FadePage( - page: VitalSignDetailsScreen(), - ), - ); - }, - child: Center( - child: Padding( - padding: const EdgeInsets.all(15.0), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - Container( - width: 50, - height: 50, + Expanded( + child: DashboardItem( + onTap: () { + Navigator.push( + context, + FadePage( + page: VitalSignDetailsScreen(), + ), + ); + }, + child: Center( + child: Padding( + padding: const EdgeInsets.all(15.0), + child: Column( + children: [ + SizedBox(height: 15,), + + Container( + width: 60, decoration: BoxDecoration( - color: Colors.white, - shape: BoxShape.rectangle, - borderRadius: BorderRadius.circular(12) + color: Colors.white, + shape: BoxShape.rectangle, + borderRadius: BorderRadius.circular(12) ), - child: Center(child: Icon(DQIcons.vital_sign_icon,size: 40,color: Theme.of(context).primaryColor,)), - ), - - Texts( - TranslationBase.of(context) - .vitalSigns, - textAlign: TextAlign.center, - color: Colors.white, - fontWeight: FontWeight.w700, - fontSize: SizeConfig.textMultiplier * 1.5, - ) - ], + child: Center(child: Image.asset('assets/images/vital_sign_icon.png', + width: 80, + height: 50, + fit: BoxFit.contain,)), + ), + SizedBox(height: 20,), + Texts( + TranslationBase.of(context) + .vitalSigns, + textAlign: TextAlign.center, + color: Colors.white, + fontWeight: FontWeight.w700, + fontSize: projectViewModel.isArabic? SizeConfig.textMultiplier * 1.5 :SizeConfig.textMultiplier * 1.7, + ) + ], + ), ), ), + margin: 4, + height: 170, + imageName: 'home_healthcare_service_bg.png', + opacity: 1.0, ), - height: MediaQuery.of(context).size.width * 0.35, - imageName: 'home_healthcare_service_bg.png', - opacity: 1.0, ), - DashboardItem( - onTap: () { - Navigator.push( - context, - FadePage( - page: MedicineSearch(), - ), - ); - }, - opacity: 1.0, - child: Center( - child: Padding( - padding: const EdgeInsets.all(15.0), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, - children: [ - Container( - width: 50, - height: 50, - decoration: BoxDecoration( - color: Colors.white, - shape: BoxShape.rectangle, - borderRadius: BorderRadius.circular(12) + Expanded( + child: DashboardItem( + onTap: () { + Navigator.push( + context, + FadePage( + page: MedicineSearch(), + ), + ); + }, + opacity: 1.0, + child: Center( + child: Padding( + padding: const EdgeInsets.all(15.0), + child: Column( + children: [ + SizedBox(height: 15,), + Container( + width: 50, + decoration: BoxDecoration( + color: Colors.white, + shape: BoxShape.rectangle, + borderRadius: BorderRadius.circular(12) + ), + child: Center(child: Image.asset('assets/images/search_medicine_icon.png', + width: 50, + height: 50, + fit: BoxFit.contain,)), ), - child: Center(child: Icon(DQIcons.search_medicine_icon,size: 40,color: Theme.of(context).primaryColor,),), - ), - - Texts( - TranslationBase.of(context).searchMedicine, - textAlign: TextAlign.center, - color: Colors.white, - fontWeight: FontWeight.w700, - fontSize: SizeConfig.textMultiplier * 1.5, - ) - ], + SizedBox(height: 20,), + Texts( + TranslationBase.of(context).searchMedicine, + textAlign: TextAlign.center, + color: Colors.white, + fontWeight: FontWeight.w700, + fontSize: projectViewModel.isArabic? SizeConfig.textMultiplier * 1.5 :SizeConfig.textMultiplier * 1.7, + ) + ], + ), ), ), + margin: 4, + height: 170, + imageName: 'al-habib_onlne_pharmacy_bg.png', ), - height: MediaQuery.of(context).size.width * 0.35, - imageName: 'al-habib_onlne_pharmacy_bg.png', ), - DashboardItem(opacity: 1.0, - onTap: (){ - Navigator.push( - context, - FadePage( - page: PaymentService(), - ), - ); - }, - child: Center( - child: Padding( - padding: const EdgeInsets.all(15.0), - child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, - - children: [ - Container( - // width: 50, - // height: 50, - decoration: BoxDecoration( - color: Colors.white, - shape: BoxShape.rectangle, - borderRadius: BorderRadius.circular(12) + Expanded( + child: DashboardItem(opacity: 1.0, + onTap: (){ + Navigator.push( + context, + FadePage( + page: PaymentService(), + ), + ); + }, + child: Center( + child: Padding( + padding: const EdgeInsets.all(15.0), + child: Column( + children: [ + SizedBox(height: 15,), + Container( + decoration: BoxDecoration( + color: Colors.white, + shape: BoxShape.rectangle, + borderRadius: BorderRadius.circular(12) + ), + child: Center(child: Image.asset('assets/images/online_payment_icon.png', + width: 80, + height: 50, + fit: BoxFit.contain,)), ), - child: Center(child: Icon(DQIcons.online_payment_icon,size: 40,color: Theme.of(context).primaryColor,)), - ), + SizedBox(height: 15,), - Texts( - TranslationBase.of(context).onlinePaymentService, - textAlign: TextAlign.center, - color: Colors.white, - fontWeight: FontWeight.w700, - fontSize: SizeConfig.textMultiplier * 1.7, - ) - ], + Texts( + TranslationBase.of(context).onlinePaymentService, + textAlign: TextAlign.center, + color: Colors.white, + fontWeight: FontWeight.w700, + fontSize: projectViewModel.isArabic? SizeConfig.textMultiplier * 1.5 :SizeConfig.textMultiplier * 1.7, + ) + ], + ), ), ), + margin: 4, + height: 170, + imageName: 'online_payments_bg.png', ), - height: MediaQuery.of(context).size.width * 0.35, - //color: HexColor("#747C80"), - imageName: 'online_payments_bg.png', ), ], ), @@ -724,7 +739,7 @@ class DashboardItem extends StatelessWidget { this.width, this.height, this.color, - this.opacity = 1.0,this.icon}) + this.opacity = 1.0,this.icon,this.margin=0}) : super(key: key); final bool hasBorder; final String imageName; @@ -734,6 +749,7 @@ class DashboardItem extends StatelessWidget { final double height; final Color color; final double opacity; + final double margin; final Widget icon; @override @@ -766,6 +782,7 @@ class DashboardItem extends StatelessWidget { ) : icon, ), + margin: EdgeInsets.all(margin), child: Center( child: child, ), diff --git a/lib/pages/medical/medical_profile_page.dart b/lib/pages/medical/medical_profile_page.dart index 228bd1b6..d9054cb9 100644 --- a/lib/pages/medical/medical_profile_page.dart +++ b/lib/pages/medical/medical_profile_page.dart @@ -96,7 +96,7 @@ class _MedicalProfilePageState extends State { children: [ Container( width: double.infinity, - height: 30, + height: 55, ), Row( children: [ @@ -500,14 +500,14 @@ class _MedicalProfilePageState extends State { ), if (model.user != null) Positioned( - top: 175, + top: 185, left: 20, right: 20, child: Container( width: double.infinity, - height: 70, + height: 80, decoration: BoxDecoration( - color: Colors.grey[600], + color: Theme.of(context).primaryColor, shape: BoxShape.rectangle, border: Border.all( color: Colors.transparent, width: 0.5), @@ -519,6 +519,7 @@ class _MedicalProfilePageState extends State { fit: BoxFit.cover)), child: Column( crossAxisAlignment: CrossAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.spaceAround, children: [ SizedBox( height: 8, @@ -529,9 +530,7 @@ class _MedicalProfilePageState extends State { model.user.lastName, color: Colors.white, ), - SizedBox( - height: 8, - ), + Texts( '${model.user.patientID}', color: Colors.white, diff --git a/lib/widgets/data_display/medical/time_line_widget.dart b/lib/widgets/data_display/medical/time_line_widget.dart index bbbbfeb2..5623cf56 100644 --- a/lib/widgets/data_display/medical/time_line_widget.dart +++ b/lib/widgets/data_display/medical/time_line_widget.dart @@ -31,7 +31,7 @@ class TimeLineWidget extends StatelessWidget { ), if (isUp) Positioned( - top: 20, + top: 15, child: Container( margin: EdgeInsets.only(left: 2, right: 2), child: Column( @@ -90,7 +90,7 @@ class TimeLineWidget extends StatelessWidget { ) else Positioned( - top: 70, + top: 65, child: Container( margin: EdgeInsets.only(left: 2, right: 2), child: Column(