增加智能体头像裁剪页面
- 新增 `AgentImageCropScreen.kt` 用于智能体头像的裁剪和预览。 - 调整导航逻辑,添加智能体时跳转到新的 `AgentImageCrop` 路由。 - 原有的 `ImageCropScreen` 专门用于处理个人资料头像的裁剪。 - `AddAgentViewModel` 中移除 `isFromAddAgent` 标志,通过不同的导航路由区分头像裁剪来源。
This commit is contained in:
@@ -35,6 +35,7 @@ import com.aiosman.ravenow.ui.account.AccountSetting
|
||||
import com.aiosman.ravenow.ui.account.RemoveAccountScreen
|
||||
import com.aiosman.ravenow.ui.account.ResetPasswordScreen
|
||||
import com.aiosman.ravenow.ui.agent.AddAgentScreen
|
||||
import com.aiosman.ravenow.ui.agent.AgentImageCropScreen
|
||||
import com.aiosman.ravenow.ui.group.CreateGroupChatScreen
|
||||
import com.aiosman.ravenow.ui.chat.ChatAiScreen
|
||||
import com.aiosman.ravenow.ui.chat.ChatScreen
|
||||
@@ -103,6 +104,7 @@ sealed class NavigationRoute(
|
||||
data object ChatGroup : NavigationRoute("ChatGroup/{id}/{name}/{avatar}")
|
||||
data object CommentNoticeScreen : NavigationRoute("CommentNoticeScreen")
|
||||
data object ImageCrop : NavigationRoute("ImageCrop")
|
||||
data object AgentImageCrop : NavigationRoute("AgentImageCrop")
|
||||
data object AccountSetting : NavigationRoute("AccountSetting")
|
||||
data object AboutScreen : NavigationRoute("AboutScreen")
|
||||
data object AddAgent : NavigationRoute("AddAgent")
|
||||
@@ -449,6 +451,13 @@ fun NavigationController(
|
||||
ImageCropScreen()
|
||||
}
|
||||
}
|
||||
composable(route = NavigationRoute.AgentImageCrop.route) {
|
||||
CompositionLocalProvider(
|
||||
LocalAnimatedContentScope provides this,
|
||||
) {
|
||||
AgentImageCropScreen()
|
||||
}
|
||||
}
|
||||
composable(route = NavigationRoute.AccountSetting.route) {
|
||||
CompositionLocalProvider(
|
||||
LocalAnimatedContentScope provides this,
|
||||
|
||||
Reference in New Issue
Block a user