mazaya banner changes

master
Aamir Muhammad 3 months ago
parent dcbf7b386a
commit 56b18c493a

@ -0,0 +1,17 @@
<svg width="90" height="47" viewBox="0 0 90 47" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M14.6637 23.3332H6.12992C4.29216 23.3332 3.22754 22.3002 3.22754 20.584V12.585H5.6329V19.3679C5.6329 20.5007 5.92436 21.102 7.69463 21.102H14.6668V23.3347L14.6637 23.3332Z" fill="#5D5E5E"/>
<path d="M15.7284 26.0988H13.5991V24.1653H15.7284V26.0988ZM19.1293 20.1166C19.1293 20.9993 18.8716 21.7331 18.373 22.3166C17.8054 22.9998 17.0154 23.3332 16.0198 23.3332H13.9765V21.1005H15.5044C16.3113 21.1005 16.7239 20.5498 16.7239 19.4677V15.7837H19.1293V20.1166ZM18.9744 26.0988H16.8283V24.1653H18.9744V26.0988Z" fill="#5D5E5E"/>
<path d="M23.2848 23.3332H20.8794V12.5835H23.2848V23.3332Z" fill="#5D5E5E"/>
<path d="M32.285 23.3335H29.6219C29.2261 25.1673 27.6813 26.0827 24.9492 26.0827V24.1998C26.5293 24.1998 27.3193 23.4659 27.3193 21.9998V15.7839H29.7415V21.1008H32.2834V23.3335H32.285ZM29.5881 14.5172H27.4589V12.6001H29.5881V14.5172Z" fill="#5D5E5E"/>
<path d="M41.868 20.9665C41.868 23.1992 40.3217 24.7666 37.9179 24.7666C36.4575 24.7666 35.3592 24.2828 34.655 23.3332H31.564V21.1005H33.9509C33.9509 18.7174 35.3592 17.2007 37.832 17.2007C40.3049 17.2007 41.868 18.6832 41.868 20.9665ZM39.4811 21.0499C39.4811 19.7326 38.9657 19.0672 37.9532 19.0672H37.7814C36.9055 19.0672 36.3041 19.8502 36.3041 20.9501C36.3041 22.0501 36.8886 22.8673 37.9179 22.8673C38.8629 22.8673 39.4811 22.1335 39.4811 21.0514V21.0499Z" fill="#5D5E5E"/>
<path d="M79.3108 4.83447H54.3276C50.4719 4.83447 47.3462 7.86731 47.3462 11.6085V35.8498C47.3462 39.591 50.4719 42.6238 54.3276 42.6238H79.3108C83.1665 42.6238 86.2921 39.591 86.2921 35.8498V11.6085C86.2921 7.86731 83.1665 4.83447 79.3108 4.83447Z" fill="#ED1C2B"/>
<path d="M81.526 29.9599L81.5045 37.6687L71.1253 37.6419C70.1972 37.6419 69.5575 36.7473 69.5145 35.3794C69.5161 33.233 68.858 31.1209 67.5586 29.3824C65.1119 26.1077 61.6603 23.485 57.1748 21.5337C56.0672 21.0529 54.8645 20.8073 53.6527 20.8117C52.697 20.7522 52.0542 19.6939 52.0542 18.3662L52.0573 10.6812L62.2908 10.6782C63.2158 10.6782 63.9491 11.6026 63.992 12.9675C63.9905 14.4575 64.4108 15.9251 65.2453 17.1754C68.0403 21.3699 71.6146 24.7309 76.3885 26.8147C77.4946 27.297 78.6988 27.5367 79.9122 27.5441C80.8679 27.6036 81.526 28.6322 81.526 29.9599Z" fill="white"/>
<path d="M64.0242 28.7545C64.015 28.8631 64.0104 28.9733 64.0104 29.0864L64.0012 34.4211V35.3425C63.9537 36.7104 63.1867 37.6585 62.2632 37.6585L54.5332 37.6273C53.5146 37.6273 52.068 37.6362 52.068 37.6362L52.0542 29.8961C52.0542 28.5714 52.6985 27.5176 53.6573 27.4565L56.5274 27.461H57.6273H62.5884C63.2557 27.461 63.8233 28.0028 64.0258 28.7545H64.0242Z" fill="white"/>
<path d="M81.5779 8.74026L81.5641 18.3826C81.5641 19.7103 80.9444 20.8013 79.9887 20.8594L77.0832 20.852L76.106 20.849C76.0385 20.8371 75.9695 20.8326 75.9005 20.8326H70.9486C70.2936 20.8326 69.7337 20.3102 69.522 19.5793C69.5358 19.4602 69.5465 19.3367 69.5496 19.2102V13.0241C69.5925 11.6517 70.3626 10.6842 71.283 10.6842L78.3534 10.6902C80.4918 10.5815 81.5748 8.73877 81.5748 8.73877L81.5779 8.74026Z" fill="white"/>
<path d="M9.65051 32.5902C9.62289 31.8728 9.59528 31.005 9.59528 30.1387H9.56767C9.37591 30.8993 9.12126 31.7492 8.88349 32.4488L8.13488 34.7768H7.04879L6.39223 32.4667C6.19127 31.7671 5.98111 30.9172 5.83537 30.1387H5.81696C5.78015 30.9439 5.75254 31.8653 5.70651 32.6081L5.5976 34.8735H4.31055L4.70326 28.9077H6.55483L7.15617 30.8993C7.34793 31.5899 7.53968 32.3342 7.67621 33.0323H7.70382C7.87717 32.3416 8.08733 31.5542 8.28829 30.8904L8.94485 28.9077H10.7596L11.0971 34.8735H9.73794L9.64744 32.5902H9.65051Z" fill="#5D5E5E"/>
<path d="M13.7557 33.3433L13.3185 34.875H11.8765L13.7557 28.9092H15.5796L17.4864 34.875H15.9907L15.5167 33.3433H13.7557ZM15.3158 32.3342L14.9323 31.069C14.8233 30.7147 14.7129 30.2726 14.6224 29.9184H14.604C14.5119 30.2726 14.4214 30.7236 14.3217 31.069L13.9566 32.3342H15.3158Z" fill="#5D5E5E"/>
<path d="M18.8135 34.1486L21.814 30.0583V30.0226H18.8135V28.9077H23.6641V29.6862L20.7295 33.7229V33.7586H23.7116V34.8735H18.8135V34.1471V34.1486Z" fill="#5D5E5E"/>
<path d="M26.9051 33.3433L26.4679 34.875H25.0259L26.9051 28.9092H28.729L30.6358 34.875H29.1401L28.6661 33.3433H26.9051ZM28.4652 32.3342L28.0817 31.069C27.9712 30.7147 27.8623 30.2726 27.7718 29.9184H27.7534C27.6613 30.2726 27.5708 30.7236 27.4711 31.069L27.106 32.3342H28.4652Z" fill="#5D5E5E"/>
<path d="M32.1961 34.875V32.4324L30.2524 28.9092H31.8402L32.4691 30.3441C32.6609 30.7772 32.7882 31.0972 32.9431 31.4857H32.9615C33.0981 31.1136 33.2438 30.7683 33.4263 30.3441L34.0461 28.9092H35.6062L33.5813 32.3877V34.875H32.1945H32.1961Z" fill="#5D5E5E"/>
<path d="M37.0496 33.3433L36.6124 34.875H35.1704L37.0496 28.9092H38.8736L40.7804 34.875H39.2847L38.8107 33.3433H37.0496ZM38.6097 32.3342L38.2262 31.069C38.1157 30.7147 38.0068 30.2726 37.9163 29.9184H37.8979C37.8059 30.2726 37.7154 30.7236 37.6157 31.069L37.2506 32.3342H38.6097Z" fill="#5D5E5E"/>
</svg>

After

Width:  |  Height:  |  Size: 4.8 KiB

@ -615,5 +615,9 @@
"searchByUserName": "البحث بواسطة اسم المستخدم",
"shareScreen": "مشاركة الشاشة",
"start":"يبدأ",
"about":"عن"
"about":"عن",
"explore": "يستكشف",
"mazaya": "مازيا",
"benefits": "فوائد",
"mazayaDesc": "اكتشف الخصومات والعروض الخاصة المتاحة للموظفين"
}

@ -613,5 +613,10 @@
"bonusQty": "Bonus Qty.",
"balQty": "Bal. Qty.",
"start":"Start",
"about":"About"
"about":"About",
"explore": "Explore",
"mazaya": "MAZAYA",
"benefits": "Benefits",
"mazayaDesc": "Discover special Discounts and offers available to Employees"
}

@ -1,6 +1,6 @@
// DO NOT EDIT. This is code generated via package:easy_localization/generate.dart
// ignore_for_file: prefer_single_quotes, avoid_renaming_method_parameters
// ignore_for_file: prefer_single_quotes, avoid_renaming_method_parameters, constant_identifier_names
import 'dart:ui';
@ -14,7 +14,7 @@ class CodegenLoader extends AssetLoader{
return Future.value(mapLocales[locale.toString()]);
}
static const Map<String,dynamic> ar_SA = {
static const Map<String,dynamic> _ar_SA = {
"mohemm": "Mohemm",
"english": "English",
"arabic": "عربي",
@ -116,6 +116,7 @@ class CodegenLoader extends AssetLoader{
"reject": "يرفض",
"approve": "يوافق",
"cancel": "إلغاء",
"generate": "يولد",
"requestedItems": "العناصر المطلوبة",
"request": "طلب",
"myRequest": "طلبي",
@ -560,10 +561,9 @@ class CodegenLoader extends AssetLoader{
"missingDocuments": "مستندات مفقودة",
"uploadedDocuments": "المستندات التي تم تحميلها",
"addAtLeastOneAttachment": "الرجاء إضافة مرفق واحد على الأقل.",
"open": "يفتح",
"youCannotJoinTheMarathon": "لا يمكنك الانضمام إلى الماراثون لأنك تجاوزت الحد الزمني",
"pleaseClickButtonToJoinMarathon": "الرجاء الضغط على الزر أدناه للانضمام إلى الماراثون",
"generate": "يولد",
"youCannotJoinTheMarathon": "لا يمكنك الانضمام إلى الماراثون لأنك تجاوزت الحد الزمني",
"open": "يفتح",
"paymentRequest": "طلب الدفع",
"paymentDetails": "تفاصيل الدفع",
"requestNo": "رقم الطلب",
@ -628,9 +628,13 @@ class CodegenLoader extends AssetLoader{
"searchByUserName": "البحث بواسطة اسم المستخدم",
"shareScreen": "مشاركة الشاشة",
"start": "يبدأ",
"about":"عن"
"about": "عن",
"explore": "يستكشف",
"mazaya": "مازيا",
"benefits": "فوائد",
"mazayaDesc": "اكتشف الخصومات والعروض الخاصة المتاحة للموظفين"
};
static const Map<String,dynamic> en_US = {
static const Map<String,dynamic> _en_US = {
"mohemm": "Mohemm",
"english": "English",
"arabic": "عربي",
@ -725,6 +729,7 @@ static const Map<String,dynamic> en_US = {
"whatsapp": "Whatsapp",
"reject": "Reject",
"approve": "Approve",
"generate": "Generate",
"cancel": "Cancel",
"requestedItems": "Requested Items",
"request": "Request",
@ -1197,7 +1202,6 @@ static const Map<String,dynamic> en_US = {
"pleaseClickButtonToJoinMarathon": "Press the button below to join the Marathon.",
"youCannotJoinTheMarathon": "You cannot join the Marathon because you have exceeded the time limit.",
"requesterOperatingUnit": "Requester Operating Unit",
"generate": "Generate",
"paymentRequest": "Pay Request",
"paymentDetails": "Payment Details",
"requestNo": "Request No",
@ -1244,7 +1248,11 @@ static const Map<String,dynamic> en_US = {
"bonusQty": "Bonus Qty.",
"balQty": "Bal. Qty.",
"start": "Start",
"about":"About"
"about": "About",
"explore": "Explore",
"mazaya": "MAZAYA",
"benefits": "Benefits",
"mazayaDesc": "Discover special Discounts and offers available to Employees"
};
static const Map<String, Map<String,dynamic>> mapLocales = {"ar_SA": ar_SA, "en_US": en_US};
static const Map<String, Map<String,dynamic>> mapLocales = {"ar_SA": _ar_SA, "en_US": _en_US};
}

@ -1,5 +1,7 @@
// DO NOT EDIT. This is code generated via package:easy_localization/generate.dart
// ignore_for_file: constant_identifier_names
abstract class LocaleKeys {
static const mohemm = 'mohemm';
static const english = 'english';
@ -101,6 +103,7 @@ abstract class LocaleKeys {
static const reject = 'reject';
static const approve = 'approve';
static const cancel = 'cancel';
static const generate = 'generate';
static const requestedItems = 'requestedItems';
static const request = 'request';
static const myRequest = 'myRequest';
@ -530,10 +533,9 @@ abstract class LocaleKeys {
static const missingDocuments = 'missingDocuments';
static const uploadedDocuments = 'uploadedDocuments';
static const addAtLeastOneAttachment = 'addAtLeastOneAttachment';
static const open = 'open';
static const youCannotJoinTheMarathon = 'youCannotJoinTheMarathon';
static const pleaseClickButtonToJoinMarathon = 'pleaseClickButtonToJoinMarathon';
static const generate = 'generate';
static const youCannotJoinTheMarathon = 'youCannotJoinTheMarathon';
static const open = 'open';
static const paymentRequest = 'paymentRequest';
static const paymentDetails = 'paymentDetails';
static const requestNo = 'requestNo';
@ -599,4 +601,9 @@ abstract class LocaleKeys {
static const shareScreen = 'shareScreen';
static const start = 'start';
static const about = 'about';
static const explore = 'explore';
static const mazaya = 'mazaya';
static const benefits = 'benefits';
static const mazayaDesc = 'mazayaDesc';
}

@ -415,15 +415,14 @@ class _DashboardScreenState extends State<DashboardScreen> with WidgetsBindingOb
),
),
9.width,
Expanded(
child: MenusWidget(),
),
Expanded(child: MenusWidget()),
],
),
],
).paddingOnly(left: 21, right: 21, top: 7, bottom: 21),
eventActivityWidget(context),
Consumer<DashboardProviderModel>(builder: (BuildContext context, DashboardProviderModel model, Widget? child) {
Consumer<DashboardProviderModel>(
builder: (BuildContext context, DashboardProviderModel model, Widget? child) {
if (!model.isOffersLoading && model.getOffersList.isEmpty) {
return const SizedBox();
}
@ -431,100 +430,212 @@ class _DashboardScreenState extends State<DashboardScreen> with WidgetsBindingOb
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
crossAxisAlignment: CrossAxisAlignment.center,
Directionality(
textDirection: AppState().isArabic(context) ? ui.TextDirection.rtl : ui.TextDirection.ltr,
child: Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(20),
gradient: const LinearGradient(colors: [Color(0xFF91C481), Color(0xFF7CCED7)], begin: Alignment.centerLeft, end: Alignment.centerRight),
),
child: Padding(
padding: const EdgeInsets.all(3.0), // This creates the border width
child: Container(
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(17), // Slightly less than outer radius
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Expanded(
flex: 4,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
children: [
LocaleKeys.offers.tr().toText12(),
Row(
children: [
LocaleKeys.discounts.tr().toText24(isBold: true),
6.width,
Container(
padding: const EdgeInsets.only(left: 8, right: 8),
decoration: BoxDecoration(
color: MyColors.yellowColor,
borderRadius: BorderRadius.circular(10),
),
child: LocaleKeys.newString.tr().toText10(isBold: true)),
],
Expanded(
flex: 2,
child: RichText(
text:
AppState().isArabic(context)
? const TextSpan(
children: [
TextSpan(
text: 'اطلع على مميزات',
style: TextStyle(fontSize: 16, letterSpacing: -0.2, fontWeight: FontWeight.w700, height: 24 / 16, color: Color(0xFF5D5E5E)),
),
],
TextSpan(
text: ' مزايا',
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.w700,
letterSpacing: -0.2,
height: 24 / 16,
color: Color(0xFFED1C2B), // Use your MAZAYA red color here if defined, e.g. MyColors.mazayaRed
),
),
LocaleKeys.viewAllOffers.tr().toText12(isUnderLine: true).onPress(() {
Navigator.pushNamed(context, AppRoutes.offersAndDiscounts);
})
],
).paddingOnly(left: 21, right: 21),
Consumer<DashboardProviderModel>(
builder: (BuildContext context, DashboardProviderModel model, Widget? child) {
return SizedBox(
height: 103 + 33,
child: ListView.separated(
shrinkWrap: true,
physics: const BouncingScrollPhysics(),
padding: const EdgeInsets.only(left: 21, right: 21, top: 13),
scrollDirection: Axis.horizontal,
itemBuilder: (BuildContext cxt, int index) {
return model.isOffersLoading
? const OffersShimmerWidget()
: InkWell(
onTap: () {
navigateToDetails(data.getOffersList[index]);
},
child: SizedBox(
width: 73,
child: Column(
crossAxisAlignment: CrossAxisAlignment.center,
)
: TextSpan(
children: [
Container(
width: 73,
height: 73,
decoration: BoxDecoration(
color: Colors.white,
borderRadius: const BorderRadius.all(
Radius.circular(100),
TextSpan(
text: LocaleKeys.explore.tr() + ' ',
style: const TextStyle(fontSize: 16, letterSpacing: -0.2, fontWeight: FontWeight.w700, height: 24 / 16, color: Color(0xFF5D5E5E)),
),
border: Border.all(color: MyColors.lightGreyE3Color, width: 1),
TextSpan(
text: LocaleKeys.mazaya.tr(),
style: const TextStyle(
fontSize: 16,
fontWeight: FontWeight.w700,
letterSpacing: -0.2,
height: 24 / 16,
color: Color(0xFFED1C2B), // Use your MAZAYA red color here if defined, e.g. MyColors.mazayaRed
),
child: ClipRRect(
borderRadius: const BorderRadius.all(
Radius.circular(50),
),
child: Hero(
tag: "ItemImage" + data.getOffersList[index].offersDiscountId.toString()!,
transitionOnUserGestures: true,
child: Image.network(
data.getOffersList[index].logo ?? "",
fit: BoxFit.contain,
TextSpan(
text: ' ' + LocaleKeys.benefits.tr(),
style: const TextStyle(fontSize: 16, letterSpacing: -0.2, fontWeight: FontWeight.w700, height: 24 / 16, color: Color(0xFF5D5E5E)),
),
],
),
),
),
4.height,
const Expanded(flex: 1, child: SizedBox()),
],
),
const SizedBox(height: 8),
LocaleKeys.mazayaDesc.tr().toText11(color: const Color(0xFF5D5E5E)),
],
),
),
Expanded(
child: AppState().isArabic(context)
? data.getOffersList[index].titleAr!.toText12(isCenter: true, maxLine: 1)
: data.getOffersList[index].titleEn!.toText12(isCenter: true, maxLine: 1),
flex: 2,
child: Column(
crossAxisAlignment: CrossAxisAlignment.end,
mainAxisAlignment: MainAxisAlignment.end,
children: [
SvgPicture.asset("assets/icons/mazaya_brand.svg", width: 90, height: 47),
const SizedBox(height: 28),
LocaleKeys.viewAllOffers.tr().toText12(isUnderLine: true, color: const Color(0xFF3B3D4A)).onPress(() {
Navigator.pushNamed(context, AppRoutes.offersAndDiscounts);
}),
],
),
),
],
).paddingOnly(left: 21, right: 21, top: 14, bottom: 14),
),
),
);
},
separatorBuilder: (BuildContext cxt, int index) => 8.width,
itemCount: 9),
);
},
).paddingOnly(left: 21, right: 21, top: 0, bottom: 21),
),
// Container(
// height: 121,
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(12),
// border: Border.all(width: 3, color: Colors.red),
// ),
// child: Padding(padding: const EdgeInsets.all(4.0), child: Container(decoration: BoxDecoration(borderRadius: BorderRadius.circular(12), color: Colors.white))),
// ).paddingOnly(left: 21, right: 21, bottom: 21),
// Row(
// crossAxisAlignment: CrossAxisAlignment.center,
// children: [
// Expanded(
// child: Column(
// crossAxisAlignment: CrossAxisAlignment.start,
// mainAxisSize: MainAxisSize.min,
// children: [
// LocaleKeys.offers.tr().toText12(),
// Row(
// children: [
// LocaleKeys.discounts.tr().toText24(isBold: true),
// 6.width,
// Container(
// padding: const EdgeInsets.only(left: 8, right: 8),
// decoration: BoxDecoration(
// color: MyColors.yellowColor,
// borderRadius: BorderRadius.circular(10),
// ),
// child: LocaleKeys.newString.tr().toText10(isBold: true)),
// ],
// ),
// ],
// ),
// ),
// LocaleKeys.viewAllOffers.tr().toText12(isUnderLine: true).onPress(() {
// Navigator.pushNamed(context, AppRoutes.offersAndDiscounts);
// })
// ],
// ).paddingOnly(left: 21, right: 21),
// Consumer<DashboardProviderModel>(
// builder: (BuildContext context, DashboardProviderModel model, Widget? child) {
// return SizedBox(
// height: 103 + 33,
// child: ListView.separated(
// shrinkWrap: true,
// physics: const BouncingScrollPhysics(),
// padding: const EdgeInsets.only(left: 21, right: 21, top: 13),
// scrollDirection: Axis.horizontal,
// itemBuilder: (BuildContext cxt, int index) {
// return model.isOffersLoading
// ? const OffersShimmerWidget()
// : InkWell(
// onTap: () {
// navigateToDetails(data.getOffersList[index]);
// },
// child: SizedBox(
// width: 73,
// child: Column(
// crossAxisAlignment: CrossAxisAlignment.center,
// children: [
// Container(
// width: 73,
// height: 73,
// decoration: BoxDecoration(
// color: Colors.white,
// borderRadius: const BorderRadius.all(
// Radius.circular(100),
// ),
// border: Border.all(color: MyColors.lightGreyE3Color, width: 1),
// ),
// child: ClipRRect(
// borderRadius: const BorderRadius.all(
// Radius.circular(50),
// ),
// child: Hero(
// tag: "ItemImage" + data.getOffersList[index].offersDiscountId.toString()!,
// transitionOnUserGestures: true,
// child: Image.network(
// data.getOffersList[index].logo ?? "",
// fit: BoxFit.contain,
// ),
// ),
// ),
// ),
// 4.height,
// Expanded(
// child: AppState().isArabic(context)
// ? data.getOffersList[index].titleAr!.toText12(isCenter: true, maxLine: 1)
// : data.getOffersList[index].titleEn!.toText12(isCenter: true, maxLine: 1),
// ),
// ],
// ),
// ),
// );
// },
// separatorBuilder: (BuildContext cxt, int index) => 8.width,
// itemCount: 9),
// );
// },
// ),
],
);
}),
},
),
Container(
width: double.infinity,
padding: const EdgeInsets.only(top: 31),

@ -39,7 +39,7 @@ class _OffersAndDiscountsHomeState extends State<OffersAndDiscountsHome> {
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.white,
appBar: AppBarWidget(context, title: LocaleKeys.offerAndDiscounts.tr(), showHomeButton: true),
appBar: AppBarWidget(context, title: LocaleKeys.offerAndDiscounts.tr(), showHomeButton: true, showLogo: true, logoPath: "assets/icons/mazaya_brand.svg"),
body: SingleChildScrollView(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,

@ -1,18 +1,23 @@
import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';
import 'package:mohem_flutter_app/classes/colors.dart';
import 'package:mohem_flutter_app/config/routes.dart';
import 'package:mohem_flutter_app/extensions/int_extensions.dart';
import 'package:mohem_flutter_app/extensions/string_extensions.dart';
import 'package:mohem_flutter_app/extensions/widget_extensions.dart';
AppBar AppBarWidget(BuildContext context,
{required String title,
AppBar AppBarWidget(
BuildContext context, {
required String title,
bool showHomeButton = true,
bool showLogo = false,
String? logoPath,
bool showWorkListSettingButton = false,
bool showMemberButton = false,
List<Widget>? actions,
void Function()? onHomeTapped,
void Function()? onBackTapped}) {
void Function()? onBackTapped,
}) {
return AppBar(
leadingWidth: 0,
@ -26,8 +31,10 @@ AppBar AppBarWidget(BuildContext context,
}, context),
child: const Icon(Icons.arrow_back_ios, color: MyColors.darkIconColor),
),
if (showLogo) 4.width,
if (showLogo) SvgPicture.asset(logoPath!),
4.width,
title.toText24(color: MyColors.darkTextColor, isBold: true).expanded,
if (!showLogo)title.toText24(color: MyColors.darkTextColor, isBold: true).expanded,
],
),
centerTitle: false,
@ -55,7 +62,7 @@ AppBar AppBarWidget(BuildContext context,
},
icon: const Icon(Icons.people, color: MyColors.textMixColor),
),
...actions ?? []
...actions ?? [],
],
);
}

Loading…
Cancel
Save