KProgressIndicator - farimarwat/KrossUi GitHub Wiki

🔽 KProgressIndicator Component Documentation

A multiplatform (Android + iOS) circular progress indicator for showing loading states.


🔹 Overview

Element Type Description
KProgressIndicator Composable Circular loading spinner for showing ongoing tasks.

🧩 KProgressIndicator

Definition:
Displays a platform-adaptive circular spinner indicating that a task is in progress. Commonly used for loading screens or long-running operations.

Parameters

Parameter Type Default Description
size Double KProgressIndicatorDefaults.DefaultSize Diameter of the indicator (in dp).
color Color KProgressIndicatorDefaults.colors().color Color of the spinner.

🎨 KProgressIndicatorColors

Defines the color configuration for the progress indicator.

Property Type Description
color Color Color used to draw the spinner.

⚙️ KProgressIndicatorDefaults

Provides default values and configuration for KProgressIndicator.

colors(...)

Parameter Type Default Value Description
color Color PlatformColors.systemBlue Color for the progress indicator.

Returns a KProgressIndicatorColors instance with the provided or default value.

DefaultSize

Property Type Value
DefaultSize Double 36.0

Specifies the default diameter of the progress indicator in dp.


✅ Usage Example

KProgressIndicator(
    size = 50.0
)

🔹 Note:

  • size defines the width and height of the circular progress indicator in dp.
  • This component shows an indeterminate spinner that works consistently on both Android and iOS.