新增关注和粉丝列表

- 新增关注和粉丝列表页面
- 新增关注和粉丝列表ViewModel
- 更新UserService以支持获取关注和粉丝列表

- 更新RiderProAPI以支持获取关注和粉丝列表
- 更新Profile页面以支持跳转到关注和粉丝列表页面
- 更新Navi以支持关注和粉丝列表页面导航
- 更新UserInformationFollowers和UserInformationFollowing以支持跳转到关注和粉丝列表页面
- 更新MyProfileViewModel
以支持更新用户资料横幅
This commit is contained in:
2024-09-06 01:55:12 +08:00
parent 37dcd19227
commit e936f9cb77
12 changed files with 412 additions and 46 deletions

View File

@@ -27,11 +27,12 @@ import androidx.navigation.navArgument
import com.aiosman.riderpro.LocalAnimatedContentScope
import com.aiosman.riderpro.LocalNavController
import com.aiosman.riderpro.LocalSharedTransitionScope
import com.aiosman.riderpro.ui.account.AccountEditScreen
import com.aiosman.riderpro.ui.account.AccountEditScreen2
import com.aiosman.riderpro.ui.comment.CommentsScreen
import com.aiosman.riderpro.ui.favourite.FavouriteScreen
import com.aiosman.riderpro.ui.follower.FollowerScreen
import com.aiosman.riderpro.ui.follower.FollowerListScreen
import com.aiosman.riderpro.ui.follower.FollowerNotificationScreen
import com.aiosman.riderpro.ui.follower.FollowingListScreen
import com.aiosman.riderpro.ui.gallery.OfficialGalleryScreen
import com.aiosman.riderpro.ui.gallery.OfficialPhotographerScreen
import com.aiosman.riderpro.ui.gallery.ProfileTimelineScreen
@@ -77,6 +78,8 @@ sealed class NavigationRoute(
data object FavouritesScreen : NavigationRoute("FavouritesScreen")
data object NewPostImageGrid : NavigationRoute("NewPostImageGrid")
data object Search : NavigationRoute("Search")
data object FollowerList : NavigationRoute("FollowerList/{id}")
data object FollowingList : NavigationRoute("FollowingList/{id}")
}
@@ -158,7 +161,7 @@ fun NavigationController(
LikeScreen()
}
composable(route = NavigationRoute.Followers.route) {
FollowerScreen()
FollowerNotificationScreen()
}
composable(
route = NavigationRoute.NewPost.route,
@@ -228,6 +231,27 @@ fun NavigationController(
SearchScreen()
}
}
composable(
route = NavigationRoute.FollowerList.route,
arguments = listOf(navArgument("id") { type = NavType.IntType })
) {
CompositionLocalProvider(
LocalAnimatedContentScope provides this,
) {
FollowerListScreen(it.arguments?.getInt("id")!!)
}
}
composable(
route = NavigationRoute.FollowingList.route,
arguments = listOf(navArgument("id") { type = NavType.IntType })
) {
CompositionLocalProvider(
LocalAnimatedContentScope provides this,
) {
FollowingListScreen(it.arguments?.getInt("id")!!)
}
}
}