From 43a65eba6539af410a6136a6a41fe19eddc810e2 Mon Sep 17 00:00:00 2001 From: Aaron Fenyes Date: Thu, 28 Aug 2025 09:42:56 +0200 Subject: [PATCH] Nudge from initial step of failed realization --- app-proto/src/components/display.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app-proto/src/components/display.rs b/app-proto/src/components/display.rs index c4803dc..98be85e 100644 --- a/app-proto/src/components/display.rs +++ b/app-proto/src/components/display.rs @@ -597,16 +597,16 @@ pub fn Display() -> View { |status| status.is_ok() ); let step_val = state.assembly.step.with_untracked(|step| step.value); + let on_init_step = step_val.is_some_and(|n| n == 0.0); let on_last_step = step_val.is_some_and( |n| state.assembly.descent_history.with_untracked( |history| n as usize + 1 == history.config.len().max(1) ) ); - if - state.selection.with(|sel| sel.len() == 1) - && realization_successful - && on_last_step - { + let on_manipulable_step = + !realization_successful && on_init_step + || realization_successful && on_last_step; + if on_manipulable_step && state.selection.with(|sel| sel.len() == 1) { let sel = state.selection.with( |sel| sel.into_iter().next().unwrap().clone() );