fix: reset overlay state to None after workflow actions
This commit is contained in:
@@ -448,6 +448,9 @@ pub fn apply_action(state: &mut AppStateRest, action: Action) {
|
||||
crate::dto::chat::message::Role::System,
|
||||
format!("✓ {}", message),
|
||||
));
|
||||
if state.misc.overlay == Overlay::Workflow {
|
||||
state.misc.overlay = Overlay::None;
|
||||
}
|
||||
state.dirty = true;
|
||||
} else if kind == "workflow_error" {
|
||||
state.push_toast(Toast {
|
||||
@@ -460,6 +463,9 @@ pub fn apply_action(state: &mut AppStateRest, action: Action) {
|
||||
crate::dto::chat::message::Role::System,
|
||||
format!("✗ {}", message),
|
||||
));
|
||||
if state.misc.overlay == Overlay::Workflow {
|
||||
state.misc.overlay = Overlay::None;
|
||||
}
|
||||
state.dirty = true;
|
||||
} else {
|
||||
state.push_toast(Toast::new(ToastKind::Info, message));
|
||||
|
||||
Reference in New Issue
Block a user