TrailingImageCard is a component used to group related information into a single digestible unit, featuring a trailing image.
TrailingImageCardSample
@Sampled
@Composable
fun TrailingImageCardSample() {
TrailingImageCard(
image = { Image(MyImage, "Localized description") },
title = { Text("Title") },
subtitle = { Text("Subtitle") },
) {
Text("This is a card with a trailing image.")
}
}
// -------------------------------------------------------------------------------------------------
// Previews
// -------------------------------------------------------------------------------------------------
@Sampled
@Composable
fun NonFocusableCardWithButtonGroupSample() {
Column(verticalArrangement = Arrangement.spacedBy(GlimmerTheme.componentSpacingValues.large)) {
Card(focusable = false) { Text("This is a non-focusable card with a button group") }
ButtonGroup(modifier = Modifier.fillMaxWidth()) {
Button(onClick = {}) { Text("Button 1") }
Button(onClick = {}) { Text("Button 2") }
Button(onClick = {}) { Text("Button 3") }
}
}
}
// -------------------------------------------------------------------------------------------------
// ActionCard samples
// -------------------------------------------------------------------------------------------------