From af2bf1314e85c900a08a2b24a5f0600890648ef3 Mon Sep 17 00:00:00 2001 From: Aamir Muhammad Date: Mon, 21 Jul 2025 16:11:52 +0300 Subject: [PATCH] saved login fixes & design changes. --- lib/pages/landing/landing_page.dart | 4 ++-- lib/pages/login/saved_login.dart | 2 +- lib/widgets/others/app_scaffold_widget.dart | 20 ++++++++++++-------- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/lib/pages/landing/landing_page.dart b/lib/pages/landing/landing_page.dart index a64bb5ec..1702a098 100644 --- a/lib/pages/landing/landing_page.dart +++ b/lib/pages/landing/landing_page.dart @@ -376,7 +376,7 @@ class _LandingPageState extends State with WidgetsBindingObserver { sharedPref.remove(REGISTER_DATA_FOR_LOGIIN); if (data != null) { SelectDeviceIMEIRES savedData = SelectDeviceIMEIRES.fromJson(data); - Navigator.of(context).pushReplacement( + Navigator.of(context).push( MaterialPageRoute( builder: (BuildContext context) => SavedLogin(savedData), ), @@ -391,7 +391,7 @@ class _LandingPageState extends State with WidgetsBindingObserver { if (value != null) { SelectDeviceIMEIRES savedData = SelectDeviceIMEIRES.fromJson(data); setUserValues(value); - Navigator.of(context).pushReplacement( + Navigator.of(context).push( MaterialPageRoute( builder: (BuildContext context) => SavedLogin(savedData), ), diff --git a/lib/pages/login/saved_login.dart b/lib/pages/login/saved_login.dart index d63ca405..2c906795 100644 --- a/lib/pages/login/saved_login.dart +++ b/lib/pages/login/saved_login.dart @@ -66,7 +66,7 @@ class _SavedLogin extends State { appBarTitle: TranslationBase.of(context).register, isShowDecPage: false, isShowAppBar: true, - isshowBackButton: false, + isshowBackButton: true, showNewAppBar: true, backgroundColor: Color(0xffF8F8F8), showNewAppBarTitle: false, diff --git a/lib/widgets/others/app_scaffold_widget.dart b/lib/widgets/others/app_scaffold_widget.dart index f84c2d84..9f5dbeff 100644 --- a/lib/widgets/others/app_scaffold_widget.dart +++ b/lib/widgets/others/app_scaffold_widget.dart @@ -395,11 +395,15 @@ class NewAppBarWidget extends StatelessWidget implements PreferredSizeWidget { backgroundColor: showTitle ? Colors.white : Colors.transparent, // backgroundColor: Colors.red, // automaticallyImplyLeading: false, - leading: isShowBackButton + leading: isShowBackButton && showSavedLoginBar ? ArrowBack( onTap: onTap, - ) - : null, + ).withHorizontalPadding(24) + : isShowBackButton + ? ArrowBack( + onTap: onTap, + ) + : null, // centerTitle: showCenterLogo, titleSpacing: -8, // centerTitle: showSavedLoginBar, @@ -408,11 +412,11 @@ class NewAppBarWidget extends StatelessWidget implements PreferredSizeWidget { crossAxisAlignment: CrossAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.start, children: [ - SvgPicture.asset( - 'assets/images/svg/card_user.svg', - height: 32, - width: 32, - ).withHorizontalPadding(24), + // SvgPicture.asset( + // 'assets/images/svg/card_user.svg', + // height: 32, + // width: 32, + // ).withHorizontalPadding(24), if (showCenterLogo) Expanded(child: SvgPicture.asset('assets/images/svg/habiblogo.svg', height: 32, width: 32)), if (showDropDown! && isShowLanguageChanger) Directionality(