diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0d5ac631..37605376 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -13,13 +13,13 @@ jobs: - name: Checkout uses: actions/checkout@v3 - - name: Setup JDK 18 + - name: Setup JDK 17 uses: actions/setup-java@v1 with: - java-version: 18 + java-version: 17 - name: Build uses: gradle/gradle-build-action@v2 with: - gradle-version: 7.6 + gradle-version: 8.1.1 arguments: build diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 85f3cfd4..d48fdb2e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -20,10 +20,10 @@ jobs: - name: Checkout uses: actions/checkout@v3 - - name: Setup JDK 18 + - name: Setup JDK 17 uses: actions/setup-java@v1 with: - java-version: 18 + java-version: 17 - name: Cache uses: actions/cache@v3 @@ -36,7 +36,7 @@ jobs: - name: Build uses: gradle/gradle-build-action@v2 with: - gradle-version: 7.6 + gradle-version: 8.1.1 arguments: build - name: Run unit tests diff --git a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/AnimatedNavHostEngine.kt b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/AnimatedNavHostEngine.kt index 54ec0c0b..f5a1b2a9 100644 --- a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/AnimatedNavHostEngine.kt +++ b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/AnimatedNavHostEngine.kt @@ -294,11 +294,11 @@ internal class AnimatedNavHostEngine( } } - private fun DestinationEnterTransition.toAccompanist(): (AnimatedContentScope.() -> EnterTransition) { + private fun DestinationEnterTransition.toAccompanist(): (AnimatedContentTransitionScope.() -> EnterTransition) { return { enter() } } - private fun DestinationExitTransition.toAccompanist(): (AnimatedContentScope.() -> ExitTransition) { + private fun DestinationExitTransition.toAccompanist(): (AnimatedContentTransitionScope.() -> ExitTransition) { return { exit() } } } \ No newline at end of file diff --git a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DefaultAnimationParams.kt b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DefaultAnimationParams.kt index 338ecc1d..9de47017 100644 --- a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DefaultAnimationParams.kt +++ b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DefaultAnimationParams.kt @@ -3,7 +3,6 @@ package com.ramcosta.composedestinations.animations.defaults import androidx.compose.animation.* import androidx.compose.animation.core.tween -@ExperimentalAnimationApi interface NavGraphDefaultAnimationParams { val enterTransition: DestinationEnterTransition? val exitTransition: DestinationExitTransition? @@ -19,7 +18,6 @@ interface NavGraphDefaultAnimationParams { * * @see [com.google.accompanist.navigation.animation.AnimatedNavHost] for a parameters explanation */ -@ExperimentalAnimationApi class RootNavGraphDefaultAnimations( override val enterTransition: DestinationEnterTransition = DestinationEnterTransition { EnterTransition.None }, override val exitTransition: DestinationExitTransition = DestinationExitTransition { ExitTransition.None }, @@ -43,7 +41,6 @@ class RootNavGraphDefaultAnimations( * * @see [com.google.accompanist.navigation.animation.navigation] for a parameters explanation */ -@ExperimentalAnimationApi class NestedNavGraphDefaultAnimations( override val enterTransition: DestinationEnterTransition? = null, override val exitTransition: DestinationExitTransition? = null, diff --git a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DestinationTransitions.kt b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DestinationTransitions.kt index 73478005..cf737583 100644 --- a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DestinationTransitions.kt +++ b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/defaults/DestinationTransitions.kt @@ -4,11 +4,9 @@ import androidx.compose.animation.* import androidx.navigation.NavBackStackEntry fun interface DestinationEnterTransition { - @ExperimentalAnimationApi - fun AnimatedContentScope.enter() : EnterTransition + fun AnimatedContentTransitionScope.enter() : EnterTransition } fun interface DestinationExitTransition { - @ExperimentalAnimationApi - fun AnimatedContentScope.exit() : ExitTransition + fun AnimatedContentTransitionScope.exit() : ExitTransition } diff --git a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/manualcomposablecalls/ManualComposableCallsBuilder.kt b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/manualcomposablecalls/ManualComposableCallsBuilder.kt index 7f0bd1a0..ecf6fa8c 100644 --- a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/manualcomposablecalls/ManualComposableCallsBuilder.kt +++ b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/animations/manualcomposablecalls/ManualComposableCallsBuilder.kt @@ -70,7 +70,6 @@ fun ManualComposableCallsBuilder.bottomSheetComposable( ) } -@ExperimentalAnimationApi private fun ManualComposableCallsBuilder.validateAnimated( destination: DestinationSpec<*> ) { diff --git a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/spec/AnimationsCoreDestinationStyle.kt b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/spec/AnimationsCoreDestinationStyle.kt index 9b52a366..281df74b 100644 --- a/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/spec/AnimationsCoreDestinationStyle.kt +++ b/compose-destinations-animations/src/main/java/com/ramcosta/composedestinations/spec/AnimationsCoreDestinationStyle.kt @@ -35,7 +35,6 @@ object DestinationStyleBottomSheet : DestinationStyle * You will need to create an object which implements this interface * and use its KClass in [com.ramcosta.composedestinations.annotation.Destination.style] */ -@ExperimentalAnimationApi interface DestinationStyleAnimated : DestinationStyle { fun AnimatedContentTransitionScope.enterTransition(): EnterTransition? { diff --git a/compose-destinations-wear/src/main/java/com/ramcosta/composedestinations/wear/WearNavHostEngine.kt b/compose-destinations-wear/src/main/java/com/ramcosta/composedestinations/wear/WearNavHostEngine.kt index 357409b4..e2f2606d 100644 --- a/compose-destinations-wear/src/main/java/com/ramcosta/composedestinations/wear/WearNavHostEngine.kt +++ b/compose-destinations-wear/src/main/java/com/ramcosta/composedestinations/wear/WearNavHostEngine.kt @@ -67,7 +67,7 @@ internal class WearNavHostEngine( with(defaultNavHostEngine) { navigation(navGraph, builder) } } - @OptIn(ExperimentalAnimationApi::class, InternalDestinationsApi::class) + @OptIn(InternalDestinationsApi::class) override fun NavGraphBuilder.composable( destination: DestinationSpec, navController: NavHostController, diff --git a/compose-destinations/src/main/java/com/ramcosta/composedestinations/DefaultNavHostEngine.kt b/compose-destinations/src/main/java/com/ramcosta/composedestinations/DefaultNavHostEngine.kt index e073c052..780f03e6 100644 --- a/compose-destinations/src/main/java/com/ramcosta/composedestinations/DefaultNavHostEngine.kt +++ b/compose-destinations/src/main/java/com/ramcosta/composedestinations/DefaultNavHostEngine.kt @@ -65,7 +65,7 @@ internal class DefaultNavHostEngine : NavHostEngine { ) } - @OptIn(ExperimentalAnimationApi::class, InternalDestinationsApi::class) + @OptIn(InternalDestinationsApi::class) override fun NavGraphBuilder.composable( destination: DestinationSpec, navController: NavHostController, diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 725b36c0..fcc5c4f2 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -6,11 +6,11 @@ targetSdk = "33" kotlin = "1.8.21" dependencyCheckPluginVersion = "0.46.0" -gradlePluginVersion = "8.0.1" +gradlePluginVersion = "8.0.2" mavenPublishPluginVersion = "0.25.2" composeViewModel = "2.6.1" -activityCompose = "1.7.1" +activityCompose = "1.7.2" material = "1.9.0" lifecycleRuntimeKtx = "2.6.1" @@ -19,11 +19,11 @@ ksp = "1.8.21-1.0.11" junit = "4.13.2" -compose = "1.5.0-alpha04" -composeMaterial = "1.5.0-alpha04" +compose = "1.5.0-beta01" +composeMaterial = "1.5.0-beta01" composeCompiler = "1.4.7" -composeNavigation = "2.6.0-rc01" -accompanist = "0.31.2-alpha" +composeNavigation = "2.6.0-rc02" +accompanist = "0.31.3-beta" ktxSerialization = "1.5.1" mockk = "1.13.5" diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 562c2382..a931a299 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ #Mon Aug 23 16:48:14 WEST 2021 distributionBase=GRADLE_USER_HOME -distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip distributionPath=wrapper/dists zipStorePath=wrapper/dists zipStoreBase=GRADLE_USER_HOME diff --git a/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/greeting/GreetingTransitions.kt b/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/greeting/GreetingTransitions.kt index 8d7572ce..7858422f 100644 --- a/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/greeting/GreetingTransitions.kt +++ b/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/greeting/GreetingTransitions.kt @@ -8,7 +8,6 @@ import com.ramcosta.samples.playground.ui.screens.appDestination import com.ramcosta.samples.playground.ui.screens.destinations.ProfileScreenDestination import com.ramcosta.samples.playground.ui.screens.destinations.SettingsScreenDestination -@OptIn(ExperimentalAnimationApi::class) object GreetingTransitions : DestinationStyleAnimated { override fun AnimatedContentTransitionScope.enterTransition(): EnterTransition? { diff --git a/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/profile/ProfileTransitions.kt b/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/profile/ProfileTransitions.kt index 5999ab45..6b59cfbf 100644 --- a/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/profile/ProfileTransitions.kt +++ b/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/profile/ProfileTransitions.kt @@ -7,7 +7,6 @@ import com.ramcosta.composedestinations.spec.DestinationStyleAnimated import com.ramcosta.samples.playground.ui.screens.appDestination import com.ramcosta.samples.playground.ui.screens.destinations.GreetingScreenDestination -@OptIn(ExperimentalAnimationApi::class) object ProfileTransitions : DestinationStyleAnimated { override fun AnimatedContentTransitionScope.enterTransition(): EnterTransition? { diff --git a/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/styles/SettingsTransitions.kt b/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/styles/SettingsTransitions.kt index 0ddc4a30..c995362a 100644 --- a/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/styles/SettingsTransitions.kt +++ b/playground/src/main/java/com/ramcosta/samples/playground/ui/screens/styles/SettingsTransitions.kt @@ -7,7 +7,6 @@ import com.ramcosta.samples.playground.ui.screens.destinations.GreetingScreenDes import com.ramcosta.composedestinations.spec.DestinationStyleAnimated import com.ramcosta.samples.playground.ui.screens.appDestination -@OptIn(ExperimentalAnimationApi::class) object SettingsTransitions : DestinationStyleAnimated { override fun AnimatedContentTransitionScope.enterTransition(): EnterTransition? { diff --git a/sample/src/main/java/com/ramcosta/destinations/sample/ui/composables/TitleConfirmDialog.kt b/sample/src/main/java/com/ramcosta/destinations/sample/ui/composables/TitleConfirmDialog.kt index 85b4293a..22cbb91f 100644 --- a/sample/src/main/java/com/ramcosta/destinations/sample/ui/composables/TitleConfirmDialog.kt +++ b/sample/src/main/java/com/ramcosta/destinations/sample/ui/composables/TitleConfirmDialog.kt @@ -12,13 +12,15 @@ import androidx.compose.runtime.Composable import androidx.compose.runtime.LaunchedEffect import androidx.compose.runtime.remember import androidx.compose.ui.Alignment +import androidx.compose.ui.ExperimentalComposeUiApi import androidx.compose.ui.Modifier import androidx.compose.ui.focus.FocusRequester import androidx.compose.ui.focus.focusRequester -import androidx.compose.ui.platform.LocalTextInputService +import androidx.compose.ui.platform.LocalSoftwareKeyboardController import androidx.compose.ui.unit.dp import kotlinx.coroutines.delay +@OptIn(ExperimentalComposeUiApi::class) @Composable fun TitleConfirmDialog( type: String, @@ -27,7 +29,7 @@ fun TitleConfirmDialog( onConfirm: () -> Unit, ) { val focusRequester = remember { FocusRequester() } - val inputService = LocalTextInputService.current + val inputService = LocalSoftwareKeyboardController.current Column( modifier = Modifier .background(MaterialTheme.colors.surface) @@ -53,7 +55,7 @@ fun TitleConfirmDialog( LaunchedEffect(Unit) { delay(300) - inputService?.showSoftwareKeyboard() + inputService?.show() focusRequester.requestFocus() } } \ No newline at end of file