Cards
Installation
caveui components are copy-paste Jetpack Compose built entirely on Material 3 — there's no caveui dependency to add. Make sure Material 3 is on your classpath (it ships with the Compose BOM), then copy the Usage snippet below into your project.
kotlin
// build.gradle.kts (module)
dependencies {
implementation(platform("androidx.compose:compose-bom:2025.06.00"))
implementation("androidx.compose.material3:material3")
}Usage
kotlin
@Composable
fun VerifiedPopCard() {
var shown by remember { mutableStateOf(false) }
LaunchedEffect(Unit) { shown = true }
val scale by animateFloatAsState(
if (shown) 1f else 0f,
spring(Spring.DampingRatioMediumBouncy),
label = "pop"
)
ElevatedCard(
modifier = Modifier.width(260.dp),
shape = RoundedCornerShape(20.dp)
) {
Column(
Modifier.padding(20.dp).fillMaxWidth(),
horizontalAlignment = Alignment.CenterHorizontally
) {
Box(
Modifier.size(64.dp).clip(CircleShape)
.background(MaterialTheme.colorScheme.primary),
contentAlignment = Alignment.Center
) { Text("EM") }
Spacer(Modifier.height(10.dp))
Row(verticalAlignment = Alignment.CenterVertically) {
Text(
"Ella Marsh",
style = MaterialTheme.typography.titleMedium
)
Spacer(Modifier.width(4.dp))
Icon(
Icons.Default.Verified,
contentDescription = "Verified",
tint = MaterialTheme.colorScheme.primary,
modifier = Modifier.size(20.dp).scale(scale)
)
}
Text(
"Creator · 1.2M followers",
style = MaterialTheme.typography.bodySmall,
color = MaterialTheme.colorScheme.onSurfaceVariant
)
}
}
}