Icons
Iconsanimated
Dual ring
Two concentric arcs counter-rotating at different speeds for a refined busy state.
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 DualRing() {
val t = rememberInfiniteTransition(label = "dual")
val a by t.animateFloat(0f, 360f, infiniteRepeatable(tween(1100, easing = LinearEasing)), label = "a")
val b by t.animateFloat(0f, -360f, infiniteRepeatable(tween(1500, easing = LinearEasing)), label = "b")
val color = MaterialTheme.colorScheme.primary
Canvas(Modifier.size(40.dp)) {
val s = Stroke(2.5.dp.toPx(), cap = StrokeCap.Round)
rotate(a) { drawArc(color, -90f, 110f, false, style = s) }
rotate(b) {
val inset = 5.dp.toPx()
drawArc(color.copy(alpha = 0.6f), 90f, 110f, false, style = s,
topLeft = Offset(inset, inset), size = Size(size.width - inset * 2, size.height - inset * 2))
}
}
}