Last active
November 10, 2021 01:02
-
-
Save victorbrndls/60f0fa5f7d9d3a808f4c2a4b914ff27e 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
data class Elevations(val card: Dp = 0.dp, val default: Dp = 0.dp) | |
val LocalElevations = compositionLocalOf { Elevations() } // Create composition with default value | |
val elevations = Elevations(card = 4.dp, default = 2.dp) // Provide different value here | |
CompositionLocalProvider(LocalElevations provides elevations) { ... } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment