set up navigation

This commit is contained in:
Ida Delphine authored and Aayush Gupta committed 2026-11-09 13:13:35 +08:00
1 parent 1ee2f07454
commit 1ce2e627d6
3 files changed
+12

No files matched your search

@@ -14,6 +14,9 @@ import kotlinx.serialization.Serializable
@Serializable
sealed interface Destination : NavKey {
@Serializable
data object ContentSettings : Destination
@Serializable
data object HistorySettings : Destination
@@ -9,6 +9,7 @@ import androidx.compose.runtime.mutableStateListOf
import co.touchlab.kermit.Logger
import net.newpipe.app.screen.about.AboutScreen
import net.newpipe.app.screen.settings.AppearanceSettingsScreen
import net.newpipe.app.screen.settings.ContentSettingsScreen
import net.newpipe.app.screen.settings.DebugSettingsScreen
import net.newpipe.app.screen.settings.DownloadSettingsScreen
import net.newpipe.app.screen.settings.HistorySettingsScreen
@@ -62,6 +63,10 @@ fun navModule() = module {
navigation<Destination.HistorySettings> {
HistorySettingsScreen()
}
navigation<Destination.ContentSettings> {
ContentSettingsScreen()
}
}
/**
@@ -72,6 +72,10 @@ fun SettingsHomeScreen(
Destination.HistorySettings
)
SettingsCategoryType.CONTENT -> navigator.navigateTo(
Destination.ContentSettings
)
// TODO: wire remaining sub-screens as they are migrated
else -> Unit
}