Image Functionality & Discounts & Offers

pull/319/head
Aamir Muhammad 4 weeks ago
parent 2b53cce0aa
commit 4a384efd2d

@ -25,6 +25,8 @@ class AppState {
_loadProfileImageFromCache();
}
bool isEnabledOffersAndDiscountsCarousel = false;
double userLat = 0.0;
set setUserLat(v) => userLat = v;

@ -406,34 +406,32 @@ class _LandingPageState extends State<LandingPage> {
: SizedBox.shrink(),
// Offers And Discounts Carousel - Auto-scrolling from right to left
// appState.isAuthenticated
// ?
// Column(
// children: [
// SizedBox(height: 12.h),
// Row(
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
// children: [
// ("${LocaleKeys.offers.tr(context: context)} & ${LocaleKeys.discount.tr(context: context)}").toText16(isBold: true),
// Row(
// children: [
// LocaleKeys.viewAll.tr(context: context).toText14(color: AppColors.primaryRedColor, isBold: true),
// SizedBox(width: 2.h),
// Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 14.h),
// ],
// ),
// ],
// ).paddingSymmetrical(24.h, 0.h).onPress(() {
// Navigator.of(context).push(CustomPageRoute(page: OffersAndDiscountsPage()));
// }),
// SizedBox(height: 16.h),
// OffersAndDiscountsCarousel().paddingSymmetrical(24.h, 0.h),
// SizedBox(height: 18.h),
// ],
// )
// : SizedBox.shrink(),
appState.isAuthenticated && appState.isEnabledOffersAndDiscountsCarousel
? Column(
children: [
SizedBox(height: 12.h),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
("${LocaleKeys.offers.tr(context: context)} & ${LocaleKeys.discount.tr(context: context)}").toText16(isBold: true),
Row(
children: [
LocaleKeys.viewAll.tr(context: context).toText14(color: AppColors.primaryRedColor, isBold: true),
SizedBox(width: 2.h),
Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 14.h),
],
),
],
).paddingSymmetrical(24.h, 0.h).onPress(() {
Navigator.of(context).push(CustomPageRoute(page: OffersAndDiscountsPage()));
}),
SizedBox(height: 16.h),
OffersAndDiscountsCarousel().paddingSymmetrical(24.h, 0.h),
SizedBox(height: 18.h),
],
)
: SizedBox.shrink(),
// ,
appState.isAuthenticated
? Column(
children: [

Loading…
Cancel
Save