ContentVisibility

fun ContentVisibility(hidden: Boolean, modifier: Modifier = Modifier, content: @Composable () -> Unit)

A composable that can hide its content without removing it from the layout.

Note: Visibility must be treated similarly to Android View's invisible because it needs to receive the loading state from Await placed as a child. (If AnimatedVisibility's visible=false, the content isn't called while it's hidden, so Await won't function)

Parameters

hidden

Whether the content should be hidden.

modifier

The modifier to be applied to the layout.

content

The content of the ContentVisibility.