diff --git a/lib/screens/live_care/live_care_patient_screen.dart b/lib/screens/live_care/live_care_patient_screen.dart index d3217a95..a434a212 100644 --- a/lib/screens/live_care/live_care_patient_screen.dart +++ b/lib/screens/live_care/live_care_patient_screen.dart @@ -7,6 +7,7 @@ import 'package:doctor_app_flutter/core/viewModel/LiveCarePatientViewModel.dart' import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart'; import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/screens/base/base_view.dart'; +import 'package:doctor_app_flutter/screens/patients/patient_search/patient_search_header.dart'; import 'package:doctor_app_flutter/util/NotificationPermissionUtils.dart'; import 'package:doctor_app_flutter/util/translations_delegate_base.dart'; import 'package:doctor_app_flutter/widgets/patients/patient_card/PatientCard.dart'; @@ -60,7 +61,10 @@ class _LiveCarePatientScreenState extends State { }, builder: (_, model, w) => AppScaffold( baseViewModel: model, - isShowAppBar: false, + isShowAppBar: true, + appBar: PatientSearchHeader( + title: "LiveCare Patients", + ), body: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ @@ -69,25 +73,7 @@ class _LiveCarePatientScreenState extends State { decoration: BoxDecoration( color: Colors.white, ), - child: Container( - padding: EdgeInsets.only(left: 10, right: 10, bottom: 10), - margin: EdgeInsets.only(top: 50), - child: Row(children: [ - IconButton( - icon: Icon(Icons.arrow_back_ios), - color: Colors.black, //Colors.black, - onPressed: () => Navigator.pop(context), - ), - Expanded( - child: AppText( - "LiveCare Patients", - fontSize: SizeConfig.textMultiplier * 2.8, - fontWeight: FontWeight.bold, - color: Color(0xFF2B353E), - ), - ), - ]), - ), + child: Container(), ), SizedBox( height: 20, diff --git a/lib/screens/patients/insurance_approval_screen_patient.dart b/lib/screens/patients/insurance_approval_screen_patient.dart index ca018916..0ad4abd0 100644 --- a/lib/screens/patients/insurance_approval_screen_patient.dart +++ b/lib/screens/patients/insurance_approval_screen_patient.dart @@ -100,11 +100,11 @@ class _InsuranceApprovalScreenNewState doctorName: model .insuranceApprovalInPatient[index] .doctorName, - branch: model + approvalNo: model .insuranceApprovalInPatient[index] .approvalNo .toString(), - isPrescriptions: true, + isInsurance: true, approvalStatus: model .insuranceApprovalInPatient[index] .approvalStatusDescption ?? @@ -149,33 +149,10 @@ class _InsuranceApprovalScreenNewState child: model.insuranceApproval.length != 0 ? Column( children: [ - Padding( - padding: const EdgeInsets.all(8.0), - child: Column( - children: [ - Row( - children: [ - AppText( - TranslationBase.of(context) - .insurance22, - fontSize: 15.0, - fontWeight: FontWeight.w600, - fontFamily: 'Poppins', - ), - ], - ), - Row( - children: [ - AppText( - TranslationBase.of(context) - .approvals22, - fontSize: 30.0, - fontWeight: FontWeight.w700, - ), - ], - ), - ], - ), + ServiceTitle( + title: TranslationBase.of(context).insurance22, + subTitle: + TranslationBase.of(context).approvals22, ), ...List.generate( model.insuranceApproval.length, @@ -213,10 +190,10 @@ class _InsuranceApprovalScreenNewState .insuranceApproval[index].clinicName, doctorName: model .insuranceApproval[index].doctorName, - branch: model + approvalNo: model .insuranceApproval[index].approvalNo .toString(), - isPrescriptions: true, + isInsurance: true, approvalStatus: model .insuranceApproval[index] .approvalStatusDescption ?? diff --git a/lib/screens/patients/insurance_approvals_details.dart b/lib/screens/patients/insurance_approvals_details.dart index 0945df37..e81a843a 100644 --- a/lib/screens/patients/insurance_approvals_details.dart +++ b/lib/screens/patients/insurance_approvals_details.dart @@ -5,9 +5,11 @@ import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/screens/base/base_view.dart'; import 'package:doctor_app_flutter/util/date-utils.dart'; import 'package:doctor_app_flutter/util/translations_delegate_base.dart'; +import 'package:doctor_app_flutter/widgets/patients/patient_service_title.dart'; import 'package:doctor_app_flutter/widgets/patients/profile/patient-profile-app-bar.dart'; import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart'; import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart'; +import 'package:doctor_app_flutter/widgets/shared/user-guid/CusomRow.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; @@ -54,38 +56,16 @@ class _InsuranceApprovalsDetailsState extends State { AppScaffold( isShowAppBar: true, baseViewModel: model, - appBar: PatientProfileAppBar( - patient), + appBar: PatientProfileAppBar(patient), body: patient.admissionNo != null ? SingleChildScrollView( child: Container( child: Column( + crossAxisAlignment: CrossAxisAlignment.start, children: [ - Padding( - padding: const EdgeInsets.all(8.0), - child: Column( - children: [ - Row( - children: [ - AppText( - TranslationBase.of(context).insurance22, - fontSize: 15.0, - fontWeight: FontWeight.w600, - fontFamily: 'Poppins', - ), - ], - ), - Row( - children: [ - AppText( - TranslationBase.of(context).approvals22, - fontSize: 30.0, - fontWeight: FontWeight.w700, - ), - ], - ), - ], - ), + ServiceTitle( + title: TranslationBase.of(context).insurance22, + subTitle: TranslationBase.of(context).approvals22, ), Container( margin: EdgeInsets.all(10), @@ -128,6 +108,11 @@ class _InsuranceApprovalsDetailsState extends State { ? Color(0xff359846) : Color(0xffD02127) : Color(0xffD02127), + letterSpacing: -0.4, + fontWeight: FontWeight.w600, + fontSize: SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.7, ), ], ), @@ -139,9 +124,10 @@ class _InsuranceApprovalsDetailsState extends State { indexInsurance] .doctorName .toUpperCase(), - color: Colors.black, - fontSize: 18, - fontWeight: FontWeight.bold, + color: Color(0xff2E303A), + fontSize: 16, + letterSpacing: -0.64, + fontWeight: FontWeight.w600, ) ], ), @@ -153,8 +139,14 @@ class _InsuranceApprovalsDetailsState extends State { Column( children: [ Container( - height: 85.0, - width: 85.0, + height: MediaQuery.of(context) + .size + .height * + 0.065, + width: MediaQuery.of(context) + .size + .height * + 0.065, child: CircleAvatar( radius: SizeConfig .imageSizeMultiplier * @@ -192,112 +184,55 @@ class _InsuranceApprovalsDetailsState extends State { SizedBox( height: 25.0, ), - Row( - children: [ - AppText( - TranslationBase.of( - context) - .clinic + - ": ", - color: Colors.grey[500], - fontSize: 14, - ), - Expanded( - child: AppText( - model - .insuranceApprovalInPatient[ - indexInsurance] - .clinicName, - fontSize: 14, - ), - ) - ], + CustomRow( + label: TranslationBase.of( + context) + .clinic + + ": ", + value: model + .insuranceApprovalInPatient[ + indexInsurance] + .clinicName, ), - Row( - children: [ - AppText( - TranslationBase.of( - context) - .approvalNo + - ": ", - color: Colors.grey[500], - fontSize: 14, - ), - AppText( - model - .insuranceApprovalInPatient[ - indexInsurance] - .approvalNo - .toString(), - fontSize: 14, - ) - ], - ), - Row( - children: [ - AppText( - 'Unused Count:', - color: Colors.grey[500], - fontSize: 14, - ), - AppText( - model - .insuranceApprovalInPatient[ - indexInsurance] - .unUsedCount - .toString(), - fontSize: 14, - ) - ], - ), - Row( - children: [ - AppText( - TranslationBase.of( - context) - .companyName + - ": ", - color: Colors.grey[500], - ), - AppText('Sample') - ], - ), - Row( - children: [ - AppText( - TranslationBase.of( - context) - .receiptOn + - ": ", - color: Colors.grey[500], - ), - Expanded( - child: AppText( - '${AppDateUtils.getDayMonthYearDateFormatted(AppDateUtils.getDateTimeFromServerFormat(model.insuranceApprovalInPatient[indexInsurance].receiptOn), isArabic: projectViewModel.isArabic)}', - color: Colors.black, - fontWeight: - FontWeight.w600, - ), - ), - ], + CustomRow( + label: TranslationBase.of( + context) + .approvalNo + + ": ", + value: model + .insuranceApprovalInPatient[ + indexInsurance] + .approvalNo + .toString(), ), - Row( - children: [ - AppText( - TranslationBase.of( - context) - .expiryDate + - ": ", - color: Colors.grey[500], - ), - AppText( - '${AppDateUtils.getDayMonthYearDateFormatted(AppDateUtils.getDateTimeFromServerFormat(model.insuranceApprovalInPatient[indexInsurance].expiryDate), isArabic: projectViewModel.isArabic)}', - color: Colors.black, - fontWeight: - FontWeight.w600, - ), - ], + CustomRow( + label: 'Unused Count:', + value: model + .insuranceApprovalInPatient[ + indexInsurance] + .unUsedCount + .toString(), ), + CustomRow( + label: TranslationBase.of( + context) + .companyName + + ": ", + value: 'Sample'), + CustomRow( + label: TranslationBase.of( + context) + .receiptOn + + ": ", + value: + '${AppDateUtils.getDayMonthYearDateFormatted(AppDateUtils.getDateTimeFromServerFormat(model.insuranceApprovalInPatient[indexInsurance].receiptOn ?? ""), isArabic: projectViewModel.isArabic)}'), + CustomRow( + label: TranslationBase.of( + context) + .expiryDate + + ": ", + value: + '${AppDateUtils.getDayMonthYearDateFormatted(AppDateUtils.getDateTimeFromServerFormat(model.insuranceApprovalInPatient[indexInsurance].expiryDate ?? ""), isArabic: projectViewModel.isArabic)}'), ], ), ), @@ -320,21 +255,36 @@ class _InsuranceApprovalsDetailsState extends State { child: AppText( TranslationBase.of(context) .procedure, - fontWeight: FontWeight.w700, + fontWeight: FontWeight.w600, + color: Color(0xff2E303A), + letterSpacing: -0.48, + fontSize: SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.9, ), ), Expanded( child: AppText( TranslationBase.of(context) .status, - fontWeight: FontWeight.w700, + fontWeight: FontWeight.w600, + color: Color(0xff2E303A), + letterSpacing: -0.48, + fontSize: SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.9, ), ), Expanded( child: AppText( TranslationBase.of(context) .usageStatus, - fontWeight: FontWeight.w700, + fontWeight: FontWeight.w600, + color: Color(0xff2E303A), + letterSpacing: -0.48, + fontSize: SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.9, ), ) ], @@ -374,7 +324,18 @@ class _InsuranceApprovalsDetailsState extends State { "", textAlign: TextAlign - .start, + .center, + fontSize: + SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.7, + letterSpacing: + -0.4, + color: Color( + 0xff575757), + fontWeight: + FontWeight + .w500, ), ), ), @@ -391,6 +352,17 @@ class _InsuranceApprovalsDetailsState extends State { textAlign: TextAlign .center, + fontSize: + SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.7, + letterSpacing: + -0.4, + color: Color( + 0xff575757), + fontWeight: + FontWeight + .w500, ), ), ), @@ -407,6 +379,17 @@ class _InsuranceApprovalsDetailsState extends State { textAlign: TextAlign .center, + fontSize: + SizeConfig + .getTextMultiplierBasedOnWidth() * + 2.7, + letterSpacing: + -0.4, + color: Color( + 0xff575757), + fontWeight: + FontWeight + .w500, ), ), ), diff --git a/lib/widgets/patients/profile/patient-profile-app-bar.dart b/lib/widgets/patients/profile/patient-profile-app-bar.dart index 1bd9c50d..974d3590 100644 --- a/lib/widgets/patients/profile/patient-profile-app-bar.dart +++ b/lib/widgets/patients/profile/patient-profile-app-bar.dart @@ -138,7 +138,9 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget { width: SizeConfig.getTextMultiplierBasedOnWidth() * 20, height: SizeConfig.getTextMultiplierBasedOnWidth() * 20, child: Image.asset( - gender == 1 ? 'assets/images/male_avatar.png' : 'assets/images/female_avatar.png', + gender == 1 + ? 'assets/images/male_avatar.png' + : 'assets/images/female_avatar.png', fit: BoxFit.cover, ), ), @@ -175,7 +177,10 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget { 3.5, ), patient.startTime != null - ? AppText(patient.startTime != null ? patient.startTime : '', + ? AppText( + patient.startTime != null + ? patient.startTime + : '', fontWeight: FontWeight.w700, fontSize: SizeConfig .getTextMultiplierBasedOnWidth() * @@ -303,7 +308,9 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget { width: 30, height: 30, margin: EdgeInsets.only( - left: projectViewModel.isArabic ? 10 : 85, right: projectViewModel.isArabic ? 85 : 10, top: 5), + left: projectViewModel.isArabic ? 10 : 85, + right: projectViewModel.isArabic ? 85 : 10, + top: 5), decoration: BoxDecoration( shape: BoxShape.rectangle, border: Border( @@ -350,7 +357,7 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget { ), if (invoiceNO != null && !isPrescriptions) HeaderRow( - label: 'Invoice: ', + label: 'Invoice: ', value: invoiceNO ?? "", ), if (branch != null) @@ -380,8 +387,8 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget { : 'Prescriptions Date ', value: '${AppDateUtils.getDayMonthYearDateFormatted(appointmentDate, isArabic: projectViewModel.isArabic)}', - ), - ]), + ), + ]), ), ), ], diff --git a/lib/widgets/shared/app_drawer_widget.dart b/lib/widgets/shared/app_drawer_widget.dart index c645913b..4444cf0a 100644 --- a/lib/widgets/shared/app_drawer_widget.dart +++ b/lib/widgets/shared/app_drawer_widget.dart @@ -88,8 +88,11 @@ class _AppDrawerState extends State { padding: EdgeInsets.only(top: 8.0), child: AppText( TranslationBase.of(context).dr + - authenticationViewModel - .doctorProfile?.doctorName, + capitalizeOnlyFirstLater( + authenticationViewModel + .doctorProfile.doctorName + .replaceAll("DR.", "") + .toLowerCase()), fontWeight: FontWeight.w700, color: Color(0xFF2E303A), fontFamily: 'Poppins', @@ -257,3 +260,9 @@ class _AppDrawerState extends State { Navigator.of(context).pushNamed(routeName); } } + +String capitalizeOnlyFirstLater(String text) { + if (text.trim().isEmpty) return ""; + + return "${text[0].toUpperCase()}${text.substring(1)}"; +} diff --git a/lib/widgets/shared/doctor_card_insurance.dart b/lib/widgets/shared/doctor_card_insurance.dart index 5615015e..abb8efcc 100644 --- a/lib/widgets/shared/doctor_card_insurance.dart +++ b/lib/widgets/shared/doctor_card_insurance.dart @@ -1,7 +1,9 @@ +import 'package:doctor_app_flutter/config/size_config.dart'; import 'package:doctor_app_flutter/core/viewModel/project_view_model.dart'; import 'package:doctor_app_flutter/util/translations_delegate_base.dart'; import 'package:doctor_app_flutter/widgets/patients/profile/large_avatar.dart'; import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart'; +import 'package:doctor_app_flutter/widgets/shared/user-guid/CusomRow.dart'; import 'package:eva_icons_flutter/eva_icons_flutter.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; @@ -9,13 +11,13 @@ import 'package:provider/provider.dart'; class DoctorCardInsurance extends StatelessWidget { final String doctorName; - final String branch; + final String approvalNo; final DateTime appointmentDate; final String profileUrl; final String invoiceNO; final String orderNo; final Function onTap; - final bool isPrescriptions; + final bool isInsurance; final String clinic; final String approvalStatus; final String patientOut; @@ -23,13 +25,13 @@ class DoctorCardInsurance extends StatelessWidget { DoctorCardInsurance( {this.doctorName, - this.branch, + this.approvalNo, this.profileUrl, this.invoiceNO, this.onTap, this.appointmentDate, this.orderNo, - this.isPrescriptions = false, + this.isInsurance = false, this.clinic, this.approvalStatus, this.patientOut, @@ -59,7 +61,8 @@ class DoctorCardInsurance extends StatelessWidget { topLeft: Radius.circular(10), bottomLeft: Radius.circular(10), ), - color: approvalStatus == "Approved" || approvalStatus == "تمت الموافقة" + color: approvalStatus == "Approved" || + approvalStatus == "تمت الموافقة" ? Color(0xff359846) : Color(0xffD02127), ), @@ -67,7 +70,8 @@ class DoctorCardInsurance extends StatelessWidget { Expanded( child: Container( padding: EdgeInsets.only( - left: projectViewModel.isArabic ? 0 : 15, right: projectViewModel.isArabic ? 15 : 0), + left: projectViewModel.isArabic ? 0 : 15, + right: projectViewModel.isArabic ? 15 : 0), child: InkWell( onTap: onTap, child: Column( @@ -78,22 +82,32 @@ class DoctorCardInsurance extends StatelessWidget { children: [ AppText( "$approvalStatus", - color: approvalStatus == "Approved" || approvalStatus == "تمت الموافقة" + color: approvalStatus == "Approved" || + approvalStatus == "تمت الموافقة" ? Color(0xff359846) : Color(0xffD02127), + letterSpacing: -0.4, + fontSize: + SizeConfig.getTextMultiplierBasedOnWidth() * + 2.7, ), Container( decoration: BoxDecoration( borderRadius: BorderRadius.all( - Radius.circular(25.0), + Radius.circular(20.0), ), color: Color(0xff2E303A)), child: Padding( - padding: const EdgeInsets.all(12.0), + padding: const EdgeInsets.symmetric( + vertical: 6.5, horizontal: 11.5), child: AppText( '$patientOut'.replaceAll(" ", ""), color: Colors.white, - fontSize: 13.0, + fontSize: + SizeConfig.getTextMultiplierBasedOnWidth() * + 2.7, + letterSpacing: -0.4, + fontWeight: FontWeight.w600, ), ), ) @@ -104,7 +118,9 @@ class DoctorCardInsurance extends StatelessWidget { Expanded( child: AppText( doctorName, - bold: true, + fontSize: 16.0, + letterSpacing: -0.64, + fontWeight: FontWeight.w600, )), ], ), @@ -123,86 +139,54 @@ class DoctorCardInsurance extends StatelessWidget { flex: 4, child: Container( margin: EdgeInsets.all(10), - child: Column(crossAxisAlignment: CrossAxisAlignment.start, children: [ - if (orderNo != null && !isPrescriptions) - Row( - children: [ - AppText( - 'order No:', - color: Colors.grey[500], + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + if (orderNo != null && !isInsurance) + CustomRow( + label: 'Invoice:', + value: invoiceNO, ), - AppText( - orderNo ?? '', - ) - ], - ), - if (invoiceNO != null && !isPrescriptions) - Row( - children: [ - AppText( - 'Invoice:', - color: Colors.grey[500], + if (invoiceNO != null && !isInsurance) + CustomRow( + label: 'Invoice:', + value: invoiceNO, ), - AppText( - invoiceNO, - ) - ], - ), - if (isPrescriptions) - Row( - children: [ - AppText( - TranslationBase.of(context).clinic + ": ", - color: Colors.grey[500], - fontSize: 14, - //fontWeight: FontWeight.w600, - //color: Colors.grey[500], + if (isInsurance) + CustomRow( + label: + TranslationBase.of(context).clinic + + ": ", + value: clinic, ), - Expanded( - child: AppText( - clinic, - //fontWeight: FontWeight.w700, - fontSize: 14.0, - ), - ) - ], - ), - if (branch2 != null) - Row( - children: [ - AppText( - TranslationBase.of(context).branch + ": ", - fontSize: 14, - color: Colors.grey[500], + if (branch2 != null) + CustomRow( + label: + TranslationBase.of(context).branch + + ": ", + value: branch2, ), - AppText( - branch2, - fontSize: 14.0, - ) - ], - ), - Row( - children: [ - AppText( - TranslationBase.of(context).approvalNo + ": ", - fontSize: 14, - color: Colors.grey[500], - //color: Colors.grey[500], - ), - AppText( - branch, - fontSize: 14.0, - ) - ], - ), - ]), + if (approvalNo != null) + CustomRow( + label: TranslationBase.of(context) + .approvalNo + + ": ", + value: approvalNo, + ), + ]), ), ), - Padding( - padding: const EdgeInsets.symmetric(horizontal: 15.0), - child: Icon( - EvaIcons.eye, - ), + Column( + children: [ + Padding( + padding: const EdgeInsets.symmetric( + horizontal: 15.0), + child: Icon( + EvaIcons.eye, + color: Color(0xff2E303A), + ), + ), + ], ) ], ), diff --git a/lib/widgets/shared/text_fields/app-textfield-custom.dart b/lib/widgets/shared/text_fields/app-textfield-custom.dart index 2a77eb2d..769cd4f8 100644 --- a/lib/widgets/shared/text_fields/app-textfield-custom.dart +++ b/lib/widgets/shared/text_fields/app-textfield-custom.dart @@ -96,7 +96,7 @@ class _AppTextFieldCustomState extends State { Container( height: widget.height != 0 && widget.maxLines == 1 ? widget.height + 8 - : null, + : MediaQuery.of(context).size.height * 0.098, decoration: widget.hasBorder ? TextFieldsUtils.containerBorderDecoration( Color(0Xffffffff), @@ -106,7 +106,7 @@ class _AppTextFieldCustomState extends State { ) : null, padding: - EdgeInsets.only(top: 4.0, bottom: 4.0, left: 8.0, right: 8.0), + EdgeInsets.only(top: 4.0, bottom: 0.0, left: 8.0, right: 8.0), child: InkWell( onTap: widget.onClick ?? null, child: Row( @@ -123,28 +123,29 @@ class _AppTextFieldCustomState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.center, children: [ - if ((widget.controller != null && - widget.controller.text != "") || - widget.dropDownText != null) - AppText( - widget.hintText, - // marginTop: widget.hasHintmargin ? 0 : 30, - color: Color(0xFF2E303A), - fontSize: widget.isPrscription == false - ? 11.0 - // SizeConfig.getHeightMultiplier() * - // (SizeConfig.isWidthLarge ? 1.1 : 1.3) - : 0, - fontWeight: FontWeight.w500, - letterSpacing: -0.44, - fontFamily: 'Poppins', - ), + // if ((widget.controller != null && + // widget.controller.text != "") || + // widget.dropDownText != null) + AppText( + widget.hintText, + // marginTop: widget.hasHintmargin ? 0 : 30, + color: Color(0xFF2E303A), + fontSize: widget.isPrscription == false + ? 11.0 + // SizeConfig.getHeightMultiplier() * + // (SizeConfig.isWidthLarge ? 1.1 : 1.3) + : 0, + fontWeight: FontWeight.w600, + letterSpacing: -0.44, + fontFamily: 'Poppins', + ), widget.dropDownText == null ? Container( height: widget.height != 0 && widget.maxLines == 1 ? widget.height - 22 - : null, + : MediaQuery.of(context).size.height * + 0.045, child: TextFormField( textAlign: projectViewModel.isArabic ? TextAlign.right diff --git a/lib/widgets/shared/text_fields/text_fields_utils.dart b/lib/widgets/shared/text_fields/text_fields_utils.dart index 8ca24a68..23ae13a8 100644 --- a/lib/widgets/shared/text_fields/text_fields_utils.dart +++ b/lib/widgets/shared/text_fields/text_fields_utils.dart @@ -45,7 +45,7 @@ class TextFieldsUtils { borderSide: BorderSide(color: Color(0xFFCCCCCC), width: 2.0), borderRadius: BorderRadius.circular(8), ),*/ - hintText: selectedText != null ? selectedText : hintText ?? "", + hintText: selectedText != null ? selectedText : "" ?? "", suffixIcon: Icon( suffixIcon ?? null, color: Colors.grey.shade600, diff --git a/lib/widgets/shared/user-guid/CusomRow.dart b/lib/widgets/shared/user-guid/CusomRow.dart index 0c364474..21875e4d 100644 --- a/lib/widgets/shared/user-guid/CusomRow.dart +++ b/lib/widgets/shared/user-guid/CusomRow.dart @@ -7,7 +7,11 @@ class CustomRow extends StatelessWidget { const CustomRow({ Key key, this.label, - this.value, this.labelSize, this.valueSize, this.width, this.isCopyable= true, + this.value, + this.labelSize, + this.valueSize, + this.width, + this.isCopyable = true, }) : super(key: key); final String label; @@ -24,7 +28,8 @@ class CustomRow extends StatelessWidget { children: [ AppText( label, - fontSize: labelSize??SizeConfig.getTextMultiplierBasedOnWidth() * 2.7, + fontSize: + labelSize ?? SizeConfig.getTextMultiplierBasedOnWidth() * 2.7, color: Color(0xFF575757), fontWeight: FontWeight.w600, letterSpacing: -0.4, @@ -32,15 +37,18 @@ class CustomRow extends StatelessWidget { SizedBox( width: 1, ), - AppText( - value, - fontSize: valueSize??SizeConfig.getTextMultiplierBasedOnWidth() * 2.9, - color: Color(0xFF2B353E), - fontWeight: FontWeight.w700, - letterSpacing: -0.48, - isCopyable: isCopyable, + Expanded( + child: AppText( + value, + fontSize: + valueSize ?? SizeConfig.getTextMultiplierBasedOnWidth() * 2.9, + color: Color(0xFF2B353E), + fontWeight: FontWeight.w700, + letterSpacing: -0.48, + isCopyable: isCopyable, + ), ), ], ); } -} \ No newline at end of file +}