Created
February 17, 2021 16:03
-
-
Save Skyyo/ea3fd5c6e7da9c70fd590829cae187d3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val cardBgColor by transition.animateColor({ | |
tween(durationMillis = EXPAND_ANIMATION_DURATION) | |
}) { | |
if (expanded) cardExpandedBackgroundColor else cardCollapsedBackgroundColor | |
} | |
val cardElevation by transition.animateDp({ | |
tween(durationMillis = EXPAND_ANIMATION_DURATION) | |
}) { | |
if (expanded) 24.dp else 4.dp | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment