Skip to content

Commit 59c228e

Browse files
authored
Merge pull request #106 from NanoNish/open-from-following
feat: open user profile from following list
2 parents 2e255cc + 84bbf91 commit 59c228e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

lib/presentation/profile/widgets/following_view.dart

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import '../../../data/constants/strings.dart';
88
import '../../../data/constants/styles.dart';
99
import '../../../utils/snackbar.dart';
1010
import '../../../utils/user_util.dart';
11+
import '../../home/bloc/home_bloc.dart';
1112
import '../bloc/profile_bloc.dart';
1213
import '../components/follow_button.dart';
1314
import '../components/following_button.dart';
@@ -65,6 +66,15 @@ class FollowingView extends StatelessWidget {
6566
final user = state.following![index];
6667
final followNotifier = ValueNotifier(true);
6768
return ListTile(
69+
onTap: () {
70+
context
71+
.read<ProfileBloc>()
72+
.add(FetchDetails(userId: user.id));
73+
74+
context
75+
.read<HomeBloc>()
76+
.add(const BottomNavItemPressed(index: 3));
77+
},
6878
leading: SizedBox(
6979
width: 35.r,
7080
child: CachedNetworkImage(

0 commit comments

Comments
 (0)