diff --git a/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatus.kt b/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatus.kt index 4b3d54fd..85024c7b 100644 --- a/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatus.kt +++ b/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatus.kt @@ -10,6 +10,7 @@ import androidx.compose.foundation.shape.RoundedCornerShape import androidx.compose.material.icons.Icons import androidx.compose.material.icons.automirrored.filled.DirectionsRun import androidx.compose.material.icons.automirrored.filled.HelpOutline +import androidx.compose.material.icons.filled.Block import androidx.compose.material.icons.filled.Bolt import androidx.compose.material.icons.filled.Cancel import androidx.compose.material.icons.filled.CheckCircle @@ -17,6 +18,7 @@ import androidx.compose.material.icons.filled.Error import androidx.compose.material.icons.filled.FrontHand import androidx.compose.material.icons.filled.PauseCircle import androidx.compose.material.icons.filled.Schedule +import androidx.compose.material.icons.filled.SkipNext import androidx.compose.material3.Icon import androidx.compose.material3.Text import androidx.compose.runtime.Composable @@ -48,6 +50,8 @@ enum class RunState(val label: String) { Failed("failed"), Canceled("canceled"), Interrupted("interrupted"), + Blocked("blocked"), + Skipped("skipped"), Active("active"), Unknown("unknown"), } @@ -67,6 +71,8 @@ fun runStateOf(status: String): RunState = when (status.trim().lowercase()) { "failed", "error" -> RunState.Failed "canceled", "cancelled" -> RunState.Canceled "interrupted" -> RunState.Interrupted + "blocked" -> RunState.Blocked + "skipped" -> RunState.Skipped else -> RunState.Unknown } @@ -86,6 +92,8 @@ fun runStateIcon(state: RunState): ImageVector = when (state) { RunState.Failed -> Icons.Default.Error RunState.Canceled -> Icons.Default.Cancel RunState.Interrupted -> Icons.Default.PauseCircle + RunState.Blocked -> Icons.Default.Block + RunState.Skipped -> Icons.Default.SkipNext RunState.Active -> Icons.Default.Bolt RunState.Unknown -> Icons.AutoMirrored.Filled.HelpOutline } diff --git a/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatusPalette.kt b/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatusPalette.kt index 67f449d6..f660c374 100644 --- a/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatusPalette.kt +++ b/android/app/src/main/java/net/awan/pipelines/ui/components/RunStatusPalette.kt @@ -60,12 +60,12 @@ internal object RunStatusPalette { Entry(Color(0xFF9AA6A2), "neutral grey: waiting, clearly not the in-progress blue") /** - * Parked on a person: violet, distinct from the in-progress blue, the queued - * grey and the amber operator-stop, so a run needing a decision is unmistakable. + * Parked on a person (a human decision): distinct from the in-progress blue, the + * queued grey and the amber operator-stop, so a run needing a decision is + * unmistakable. Blocked and skipped are stage outcomes rather than run states: + * a stage that could not proceed is orange, and one deliberately not run is a + * quiet grey-blue - neither is a failure. */ - private val Waiting = - Entry(Color(0xFFC0A3F5), "violet: parked for the operator's decision; not running, not a stop") - /** Blocked: a stage that could not proceed — a warm amber/orange, never failure red. */ private val Blocked = Entry(Color(0xFFF0A35E), "orange: a blocked stage could not proceed; not the failure red") @@ -90,7 +90,6 @@ internal object RunStatusPalette { RunState.Interrupted -> Interrupted RunState.Canceled -> Canceled RunState.Queued -> Queued - RunState.Waiting -> Waiting RunState.Blocked -> Blocked RunState.Skipped -> Skipped RunState.Unknown -> Unknown