How can i add a compose loading indicator top of the form where user can't interact with other elements (such as form fields) when progress indicator is showing.
@Composable
fun CenteredCircularProgressIndicator() {
Box(
modifier = Modifier
.fillMaxSize()
.padding(50.dp),
) {
CircularProgressIndicator(
color = colors.primary,
modifier = Modifier
.wrapContentSize()
.align(Alignment.Center)
)
}
}
how can i achieve same like frame-layout in compose ?
In Xml world
<FrameLayout
android:id="@+id/progressBarContainer"
android:layout_height="match_parent"
android:layout_width="match_parent"
android:clickable="true" >
<ProgressBar
android:id="@+id/progressBar"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:layout_gravity="center" />
</FrameLayout>