Skip to content

Commit

Permalink
Update CustomModifierSnippets.kt
Browse files Browse the repository at this point in the history
  • Loading branch information
bentrengrove authored Nov 23, 2023
1 parent c47a8da commit 955255d
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,7 @@ fun Modifier.clip(shape: Shape) = graphicsLayer(shape = shape, clip = true)
// [END android_compose_custom_modifiers_1]

// [START android_compose_custom_modifiers_2]
fun Modifier.myBackground(color: Color) = this then Modifier
.padding(16.dp)
fun Modifier.myBackground(color: Color) = padding(16.dp)
.clip(RoundedCornerShape(8.dp))
.background(color)
// [END android_compose_custom_modifiers_2]
Expand Down

0 comments on commit 955255d

Please sign in to comment.