From dd056d4fbaf0ae3f4a6908309158debf4806d5eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mert=20Ayd=C4=B1n?= Date: Thu, 21 Dec 2023 23:22:59 +0300 Subject: [PATCH 1/2] [Profile] Fix Profile page appbar bug #109 --- mobile/lib/routes/profile/profile_route.dart | 5 ++++- .../lib/routes/story_detail/widget/story_detail_app_bar.dart | 2 +- mobile/lib/util/router.dart | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/mobile/lib/routes/profile/profile_route.dart b/mobile/lib/routes/profile/profile_route.dart index 0a7c8fc..adc0ff4 100644 --- a/mobile/lib/routes/profile/profile_route.dart +++ b/mobile/lib/routes/profile/profile_route.dart @@ -107,6 +107,7 @@ class ProfileDetailsState extends State { child: CustomScrollView( slivers: [ SliverAppBar( + automaticallyImplyLeading: false, expandedHeight: 220, floating: false, pinned: true, @@ -152,7 +153,9 @@ class ProfileDetailsState extends State { if (!snapshot.hasData || snapshot.data!.isEmpty) { return const Text('No stories found.'); } - return _buildStoryList(snapshot.data!, context); + return _buildStoryList( + snapshot.data! + snapshot.data! + snapshot.data!, + context); }, ), ], diff --git a/mobile/lib/routes/story_detail/widget/story_detail_app_bar.dart b/mobile/lib/routes/story_detail/widget/story_detail_app_bar.dart index edaf635..4d65dbf 100644 --- a/mobile/lib/routes/story_detail/widget/story_detail_app_bar.dart +++ b/mobile/lib/routes/story_detail/widget/story_detail_app_bar.dart @@ -11,7 +11,7 @@ class StoryDetailAppBar { Navigator.pop(context, shouldRefreshStories); }, child: const Icon( - Icons.chevron_left, + Icons.arrow_back, color: Colors.black, ), ), diff --git a/mobile/lib/util/router.dart b/mobile/lib/util/router.dart index 6cf30c4..51b41b0 100644 --- a/mobile/lib/util/router.dart +++ b/mobile/lib/util/router.dart @@ -119,7 +119,7 @@ extension AppRouteExtension on AppRoute { )); case AppRoute.profile: - Navigator.pushReplacement( + Navigator.push( context, // ignore: always_specify_types MaterialPageRoute( From 853038254f04b0ba522df6d8e71a871c64cd22bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mert=20Ayd=C4=B1n?= Date: Thu, 21 Dec 2023 23:24:39 +0300 Subject: [PATCH 2/2] [Profile] Fix Profile page appbar bug #109 --- mobile/lib/routes/profile/profile_route.dart | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/mobile/lib/routes/profile/profile_route.dart b/mobile/lib/routes/profile/profile_route.dart index adc0ff4..0ee7771 100644 --- a/mobile/lib/routes/profile/profile_route.dart +++ b/mobile/lib/routes/profile/profile_route.dart @@ -153,9 +153,7 @@ class ProfileDetailsState extends State { if (!snapshot.hasData || snapshot.data!.isEmpty) { return const Text('No stories found.'); } - return _buildStoryList( - snapshot.data! + snapshot.data! + snapshot.data!, - context); + return _buildStoryList(snapshot.data!, context); }, ), ],