fix: Do not play 'expand' animation when going back between nav stacks
This commit is contained in:
parent
2af2af0900
commit
bcae99765a
|
@ -4,6 +4,7 @@ import androidx.compose.animation.AnimatedContent
|
||||||
import androidx.compose.animation.Crossfade
|
import androidx.compose.animation.Crossfade
|
||||||
import androidx.compose.foundation.background
|
import androidx.compose.foundation.background
|
||||||
import androidx.compose.foundation.layout.Box
|
import androidx.compose.foundation.layout.Box
|
||||||
|
import androidx.compose.foundation.layout.fillMaxSize
|
||||||
import androidx.compose.foundation.layout.fillMaxWidth
|
import androidx.compose.foundation.layout.fillMaxWidth
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material.Text
|
import androidx.compose.material.Text
|
||||||
|
@ -129,6 +130,8 @@ fun NavigationNode(
|
||||||
|
|
||||||
val updatedAnimationScale by rememberUpdatedState(LocalAnimationFactor)
|
val updatedAnimationScale by rememberUpdatedState(LocalAnimationFactor)
|
||||||
AnimatedContent(
|
AnimatedContent(
|
||||||
|
modifier = Modifier
|
||||||
|
.fillMaxSize(),
|
||||||
targetState = foo,
|
targetState = foo,
|
||||||
transitionSpec = {
|
transitionSpec = {
|
||||||
val animationType = getNavAnimation().value
|
val animationType = getNavAnimation().value
|
||||||
|
|
Loading…
Reference in New Issue