Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(compose): migrate to compose: media #919

Merged
merged 9 commits into from
Dec 29, 2024
11 changes: 9 additions & 2 deletions app/phone/src/main/java/dev/jdtech/jellyfin/NavigationRoot.kt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import androidx.navigation.compose.composable
import androidx.navigation.compose.currentBackStackEntryAsState
import androidx.navigation.navigation
import dev.jdtech.jellyfin.presentation.film.HomeScreen
import dev.jdtech.jellyfin.presentation.film.MediaScreen
import dev.jdtech.jellyfin.presentation.setup.addserver.AddServerScreen
import dev.jdtech.jellyfin.presentation.setup.login.LoginScreen
import dev.jdtech.jellyfin.presentation.setup.servers.ServersScreen
Expand Down Expand Up @@ -52,17 +53,20 @@ data object FilmGraphRoute
@Serializable
data object HomeRoute

@Serializable
data object MediaRoute

data class TabBarItem(
val title: String,
@DrawableRes val icon: Int,
val route: Any,
)

val homeTab = TabBarItem(title = "Home", icon = CoreR.drawable.ic_home, route = HomeRoute)
// val mediaTab = TabBarItem(title = "Media", icon = CoreR.drawable.ic_library, route = Unit)
val mediaTab = TabBarItem(title = "Media", icon = CoreR.drawable.ic_library, route = MediaRoute)
// val downloadsTab = TabBarItem(title = "Downloads", icon = CoreR.drawable.ic_download, route = Unit)

val tabBarItems = listOf(homeTab)
val tabBarItems = listOf(homeTab, mediaTab)

@Composable
fun NavigationRoot(
Expand Down Expand Up @@ -211,6 +215,9 @@ fun NavigationRoot(
composable<HomeRoute> {
HomeScreen()
}
composable<MediaRoute> {
MediaScreen()
}
}
}
}
Expand Down

This file was deleted.

164 changes: 0 additions & 164 deletions app/phone/src/main/java/dev/jdtech/jellyfin/fragments/MediaFragment.kt

This file was deleted.

Loading