|
|
@ -55,7 +55,7 @@ fun NiaLoadingWheel(
|
|
|
|
contentDesc: String,
|
|
|
|
contentDesc: String,
|
|
|
|
modifier: Modifier = Modifier,
|
|
|
|
modifier: Modifier = Modifier,
|
|
|
|
) {
|
|
|
|
) {
|
|
|
|
val infiniteTransition = rememberInfiniteTransition()
|
|
|
|
val infiniteTransition = rememberInfiniteTransition(label = "wheel transition")
|
|
|
|
|
|
|
|
|
|
|
|
// Specifies the float animation for slowly drawing out the lines on entering
|
|
|
|
// Specifies the float animation for slowly drawing out the lines on entering
|
|
|
|
val startValue = if (LocalInspectionMode.current) 0F else 1F
|
|
|
|
val startValue = if (LocalInspectionMode.current) 0F else 1F
|
|
|
@ -82,6 +82,7 @@ fun NiaLoadingWheel(
|
|
|
|
animationSpec = infiniteRepeatable(
|
|
|
|
animationSpec = infiniteRepeatable(
|
|
|
|
animation = tween(durationMillis = ROTATION_TIME, easing = LinearEasing),
|
|
|
|
animation = tween(durationMillis = ROTATION_TIME, easing = LinearEasing),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|
|
|
|
label = "wheel rotation animation",
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
// Specifies the color animation for the base-to-progress line color change
|
|
|
|
// Specifies the color animation for the base-to-progress line color change
|
|
|
@ -100,6 +101,7 @@ fun NiaLoadingWheel(
|
|
|
|
repeatMode = RepeatMode.Restart,
|
|
|
|
repeatMode = RepeatMode.Restart,
|
|
|
|
initialStartOffset = StartOffset(ROTATION_TIME / NUM_OF_LINES / 2 * index),
|
|
|
|
initialStartOffset = StartOffset(ROTATION_TIME / NUM_OF_LINES / 2 * index),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|
|
|
|
label = "wheel color animation",
|
|
|
|
)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|