KwikImageCard

fun KwikImageCard(modifier: Modifier = Modifier, containerColor: Color = MaterialTheme.colorScheme.surface, shape: Shape = MaterialTheme.shapes.medium, image: Any, imageHeight: Int = 2, title: String? = null, elevation: CardElevation = CardDefaults.cardElevation(defaultElevation = 2.dp), onClick: () -> Unit = {}, content: @Composable () -> Unit = {})

A card component with an image and a title

Parameters

modifier

Modifier

image

Any image to be displayed. Can be a URL or a resource ID. Note that it'll fill the whole card

imageHeight

A value between 1 and 5 (inclusive). Determines the image height relative to the card height. Each step increases by 20%, so: 1 = 20%, 2 = 40%, 3 = 60%, 4 = 80%, 5 = 100%.

title

String title of the card

onClick

() -> Unit called when card is clicked

content

@Composable () -> Unit content of the card