FlipCard

fun FlipCard(front: @Composable BoxScope.() -> Unit, back: @Composable BoxScope.() -> Unit, modifier: Modifier = Modifier, flipped: Boolean? = null, onFlippedChange: (Boolean) -> Unit? = null, axis: FlipAxis = FlipAxis.HORIZONTAL, animationSpec: AnimationSpec<Float> = tween(MaterialTheme.kmpMotion.deliberateMillis), enabled: Boolean = true, shape: Shape = MaterialTheme.shapes.large, containerColor: Color = MaterialTheme.colorScheme.surfaceVariant, frontLabel: String? = null, backLabel: String? = null, flipLabel: String? = null)

A two-sided card that turns in 3D between front and back, for flash cards and reveals. Size it with modifier; both faces fill it.

Pass flipped to control it, or leave it null and the card keeps its own state (saved across recreation). Either way a tap requests the other face through onFlippedChange. The face turned away leaves composition and keyboard traversal; its saveable state is restored when shown again. The back is never mirrored. frontLabel and backLabel are announced as the state, and flipLabel names the tap action.