Skip to content

Commit b693650

Browse files
committed
fix(account): use pushNamed instead of goNamed for navigation
- Replace goNamed with pushNamed in followed contents pages - Update navigation method in appearance settings page - This change allows users to navigate back to the previous page when pressing the back button
1 parent de8d740 commit b693650

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

lib/account/view/followed_contents/countries/followed_countries_list_page.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class FollowedCountriesListPage extends StatelessWidget {
2727
icon: const Icon(Icons.add_circle_outline),
2828
tooltip: l10n.addCountriesTooltip,
2929
onPressed: () {
30-
context.goNamed(Routes.addCountryToFollowName);
30+
context.pushNamed(Routes.addCountryToFollowName);
3131
},
3232
),
3333
],

lib/account/view/followed_contents/sources/followed_sources_list_page.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class FollowedSourcesListPage extends StatelessWidget {
2727
icon: const Icon(Icons.add_circle_outline),
2828
tooltip: l10n.addSourcesTooltip,
2929
onPressed: () {
30-
context.goNamed(Routes.addSourceToFollowName);
30+
context.pushNamed(Routes.addSourceToFollowName);
3131
},
3232
),
3333
],

lib/account/view/followed_contents/topics/followed_topics_list_page.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class FollowedTopicsListPage extends StatelessWidget {
2727
icon: const Icon(Icons.add_circle_outline),
2828
tooltip: l10n.addTopicsTooltip,
2929
onPressed: () {
30-
context.goNamed(Routes.addTopicToFollowName);
30+
context.pushNamed(Routes.addTopicToFollowName);
3131
},
3232
),
3333
],

lib/settings/view/appearance_settings_page.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class AppearanceSettingsPage extends StatelessWidget {
3737
title: Text(l10n.settingsAppearanceThemeSubPageTitle),
3838
trailing: const Icon(Icons.chevron_right),
3939
onTap: () {
40-
context.goNamed(Routes.settingsAppearanceThemeName);
40+
context.pushNamed(Routes.settingsAppearanceThemeName);
4141
},
4242
),
4343
const Divider(indent: AppSpacing.lg, endIndent: AppSpacing.lg),
@@ -46,7 +46,7 @@ class AppearanceSettingsPage extends StatelessWidget {
4646
title: Text(l10n.settingsAppearanceFontSubPageTitle),
4747
trailing: const Icon(Icons.chevron_right),
4848
onTap: () {
49-
context.goNamed(Routes.settingsAppearanceFontName);
49+
context.pushNamed(Routes.settingsAppearanceFontName);
5050
},
5151
),
5252
],

0 commit comments

Comments
 (0)