Merge pull request #868 from SimonMarquis/patch-4

Handle topic clicks from all destinations
pull/921/head
Milosz Moczkowski 1 year ago committed by GitHub
commit 851ca6388e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -49,8 +49,7 @@ fun NiaNavHost(
startDestination = startDestination,
modifier = modifier,
) {
// TODO: handle topic clicks from each top level destination
forYouScreen(onTopicClick = {})
forYouScreen(onTopicClick = navController::navigateToTopic)
bookmarksScreen(
onTopicClick = navController::navigateToTopic,
onShowSnackbar = onShowSnackbar,
@ -61,13 +60,11 @@ fun NiaNavHost(
onTopicClick = navController::navigateToTopic,
)
interestsGraph(
onTopicClick = { topicId ->
navController.navigateToTopic(topicId)
},
onTopicClick = navController::navigateToTopic,
nestedGraphs = {
topicScreen(
onBackClick = navController::popBackStack,
onTopicClick = {},
onTopicClick = navController::navigateToTopic,
)
},
)

Loading…
Cancel
Save