diff --git a/feature/discover/build.gradle.kts b/android/feature/discover/build.gradle.kts similarity index 100% rename from feature/discover/build.gradle.kts rename to android/feature/discover/build.gradle.kts diff --git a/feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverPreviewParameterProvider.kt b/android/feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverPreviewParameterProvider.kt similarity index 100% rename from feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverPreviewParameterProvider.kt rename to android/feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverPreviewParameterProvider.kt diff --git a/feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverScreen.kt b/android/feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverScreen.kt similarity index 100% rename from feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverScreen.kt rename to android/feature/discover/src/main/java/com/thomaskioko/tvmaniac/discover/DiscoverScreen.kt diff --git a/feature/library/.gitignore b/android/feature/library/.gitignore similarity index 100% rename from feature/library/.gitignore rename to android/feature/library/.gitignore diff --git a/feature/library/build.gradle.kts b/android/feature/library/build.gradle.kts similarity index 100% rename from feature/library/build.gradle.kts rename to android/feature/library/build.gradle.kts diff --git a/feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryPreviewParameterProvider.kt b/android/feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryPreviewParameterProvider.kt similarity index 100% rename from feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryPreviewParameterProvider.kt rename to android/feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryPreviewParameterProvider.kt diff --git a/feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryScreen.kt b/android/feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryScreen.kt similarity index 100% rename from feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryScreen.kt rename to android/feature/library/src/main/kotlin/com/thomaskioko/tvmaniac/library/LibraryScreen.kt diff --git a/feature/more-shows/.gitignore b/android/feature/more-shows/.gitignore similarity index 100% rename from feature/more-shows/.gitignore rename to android/feature/more-shows/.gitignore diff --git a/feature/more-shows/build.gradle.kts b/android/feature/more-shows/build.gradle.kts similarity index 100% rename from feature/more-shows/build.gradle.kts rename to android/feature/more-shows/build.gradle.kts diff --git a/feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsPreviewParameterProvider.kt b/android/feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsPreviewParameterProvider.kt similarity index 100% rename from feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsPreviewParameterProvider.kt rename to android/feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsPreviewParameterProvider.kt diff --git a/feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsScreen.kt b/android/feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsScreen.kt similarity index 100% rename from feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsScreen.kt rename to android/feature/more-shows/src/main/kotlin/com/thomaskioko/tvmaniac/feature/moreshows/MoreShowsScreen.kt diff --git a/feature/search/.gitignore b/android/feature/search/.gitignore similarity index 100% rename from feature/search/.gitignore rename to android/feature/search/.gitignore diff --git a/feature/search/build.gradle.kts b/android/feature/search/build.gradle.kts similarity index 100% rename from feature/search/build.gradle.kts rename to android/feature/search/build.gradle.kts diff --git a/feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchBar.kt b/android/feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchBar.kt similarity index 100% rename from feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchBar.kt rename to android/feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchBar.kt diff --git a/feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchScreen.kt b/android/feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchScreen.kt similarity index 100% rename from feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchScreen.kt rename to android/feature/search/src/main/kotlin/com/thomaskioko/tvmaniac/search/SearchScreen.kt diff --git a/feature/season-details/build.gradle.kts b/android/feature/season-details/build.gradle.kts similarity index 100% rename from feature/season-details/build.gradle.kts rename to android/feature/season-details/build.gradle.kts diff --git a/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonDetailsScreen.kt b/android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonDetailsScreen.kt similarity index 100% rename from feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonDetailsScreen.kt rename to android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonDetailsScreen.kt diff --git a/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonPreviewParameterProvider.kt b/android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonPreviewParameterProvider.kt similarity index 100% rename from feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonPreviewParameterProvider.kt rename to android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/SeasonPreviewParameterProvider.kt diff --git a/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/CollapsableContent.kt b/android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/CollapsableContent.kt similarity index 100% rename from feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/CollapsableContent.kt rename to android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/CollapsableContent.kt diff --git a/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/EpisodeItem.kt b/android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/EpisodeItem.kt similarity index 100% rename from feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/EpisodeItem.kt rename to android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/EpisodeItem.kt diff --git a/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/ShowLinearProgressIndicator.kt b/android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/ShowLinearProgressIndicator.kt similarity index 100% rename from feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/ShowLinearProgressIndicator.kt rename to android/feature/season-details/src/main/java/com/thomaskioko/tvmaniac/seasondetails/components/ShowLinearProgressIndicator.kt diff --git a/feature/settings/.gitignore b/android/feature/settings/.gitignore similarity index 100% rename from feature/settings/.gitignore rename to android/feature/settings/.gitignore diff --git a/feature/settings/build.gradle.kts b/android/feature/settings/build.gradle.kts similarity index 100% rename from feature/settings/build.gradle.kts rename to android/feature/settings/build.gradle.kts diff --git a/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsExtensions.kt b/android/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsExtensions.kt similarity index 100% rename from feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsExtensions.kt rename to android/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsExtensions.kt diff --git a/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsPreviewParameterProvider.kt b/android/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsPreviewParameterProvider.kt similarity index 100% rename from feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsPreviewParameterProvider.kt rename to android/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsPreviewParameterProvider.kt diff --git a/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsScreen.kt b/android/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsScreen.kt similarity index 100% rename from feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsScreen.kt rename to android/feature/settings/src/main/kotlin/com/thomaskioko/tvmaniac/settings/SettingsScreen.kt diff --git a/feature/show-details/.gitignore b/android/feature/show-details/.gitignore similarity index 100% rename from feature/show-details/.gitignore rename to android/feature/show-details/.gitignore diff --git a/feature/show-details/build.gradle.kts b/android/feature/show-details/build.gradle.kts similarity index 100% rename from feature/show-details/build.gradle.kts rename to android/feature/show-details/build.gradle.kts diff --git a/feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/DetailPreviewParameterProvider.kt b/android/feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/DetailPreviewParameterProvider.kt similarity index 100% rename from feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/DetailPreviewParameterProvider.kt rename to android/feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/DetailPreviewParameterProvider.kt diff --git a/feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/ShowDetailScreen.kt b/android/feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/ShowDetailScreen.kt similarity index 100% rename from feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/ShowDetailScreen.kt rename to android/feature/show-details/src/main/kotlin/com/thomaskioko/showdetails/ShowDetailScreen.kt diff --git a/feature/trailers/build.gradle.kts b/android/feature/trailers/build.gradle.kts similarity index 100% rename from feature/trailers/build.gradle.kts rename to android/feature/trailers/build.gradle.kts diff --git a/feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailerPreviewParameterProvider.kt b/android/feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailerPreviewParameterProvider.kt similarity index 100% rename from feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailerPreviewParameterProvider.kt rename to android/feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailerPreviewParameterProvider.kt diff --git a/feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailersScreen.kt b/android/feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailersScreen.kt similarity index 100% rename from feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailersScreen.kt rename to android/feature/trailers/src/main/kotlin/com/thomaskioko/tvmaniac/videoplayer/TrailersScreen.kt diff --git a/data/featuredshows/implementation/src/commonMain/kotlin/com/thomaskioko/tvmaniac/data/featuredshows/implementation/FeaturedShowsStore.kt b/data/featuredshows/implementation/src/commonMain/kotlin/com/thomaskioko/tvmaniac/data/featuredshows/implementation/FeaturedShowsStore.kt index 853a873de..bf89edf59 100644 --- a/data/featuredshows/implementation/src/commonMain/kotlin/com/thomaskioko/tvmaniac/data/featuredshows/implementation/FeaturedShowsStore.kt +++ b/data/featuredshows/implementation/src/commonMain/kotlin/com/thomaskioko/tvmaniac/data/featuredshows/implementation/FeaturedShowsStore.kt @@ -45,14 +45,17 @@ class FeaturedShowsStore( reader = { _: String -> featuredShowsDao.observeFeaturedShows() .map { shows -> - shows.map { show -> - ShowEntity( - id = show.id.id, - title = show.name, - posterPath = show.poster_path, - inLibrary = show.in_library == 1L, - ) - } + shows + .shuffled() + .take(FEATURED_SHOWS_COUNT) + .map { show -> + ShowEntity( + id = show.id.id, + title = show.name, + posterPath = show.poster_path, + inLibrary = show.in_library == 1L, + ) + } } }, writer = { _, shows -> diff --git a/navigation/build.gradle.kts b/navigation/build.gradle.kts index 0a5698a4e..1ccfbc255 100644 --- a/navigation/build.gradle.kts +++ b/navigation/build.gradle.kts @@ -10,14 +10,14 @@ kotlin { implementation(projects.android.designsystem) implementation(projects.android.resources) - implementation(projects.feature.discover) - implementation(projects.feature.library) - implementation(projects.feature.moreShows) - implementation(projects.feature.search) - implementation(projects.feature.seasonDetails) - implementation(projects.feature.settings) - implementation(projects.feature.showDetails) - implementation(projects.feature.trailers) + implementation(projects.android.feature.discover) + implementation(projects.android.feature.library) + implementation(projects.android.feature.moreShows) + implementation(projects.android.feature.search) + implementation(projects.android.feature.seasonDetails) + implementation(projects.android.feature.settings) + implementation(projects.android.feature.showDetails) + implementation(projects.android.feature.trailers) implementation(libs.androidx.compose.material.icons) implementation(libs.androidx.compose.material3) diff --git a/settings.gradle.kts b/settings.gradle.kts index c83b3b4fe..550918023 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -23,6 +23,14 @@ rootProject.name = "tv-maniac" include( ":android:app", ":android:designsystem", + ":android:feature:discover", + ":android:feature:library", + ":android:feature:more-shows", + ":android:feature:search", + ":android:feature:season-details", + ":android:feature:settings", + ":android:feature:show-details", + ":android:feature:trailers", ":android:resources", ":core:database", ":core:datastore:api", @@ -76,14 +84,6 @@ include( ":data:upcomingshows:implementation", ":data:watchproviders:api", ":data:watchproviders:implementation", - ":feature:discover", - ":feature:library", - ":feature:more-shows", - ":feature:search", - ":feature:season-details", - ":feature:settings", - ":feature:show-details", - ":feature:trailers", ":navigation", ":presentation:discover", ":presentation:library",