Is there an easy / simple way to add some delay to...
# compose
t
Is there an easy / simple way to add some delay to:
Copy code
val animatedColor by animateColorAsState(
  if (isPlaying) Color.Transparent else MaterialTheme.colorScheme.surface,
)
t
val animatedColor by animateColorAsState( if (isPlaying) Color.Transparent else MaterialTheme.colorScheme.surface, animationSpec = tween( durationMillis = 2000, delayMillis = 1000, easing = LinearOutSlowInEasing ) )
t
Thanks that's what I ended up doing but the default animation is spring and it does not have the delay so I need to change the others to match too. Was wondering if there was some more generic way.