still not working autocomplete

This commit is contained in:
filipriec
2025-04-12 00:13:28 +02:00
parent 6b16068706
commit 6d6df7ca5c
2 changed files with 2 additions and 5 deletions

View File

@@ -309,13 +309,13 @@ pub async fn execute_edit_action<S: CanvasState + Any + Send>(
let max_index = register_state.role_suggestions.len().saturating_sub(1);
let current_index = register_state.selected_suggestion_index.unwrap_or(0);
register_state.selected_suggestion_index = Some(if current_index >= max_index { 0 } else { current_index + 1 });
Ok("Suggestion changed".to_string())
Ok("Suggestion changed down".to_string())
}
"suggestion_up" if register_state.show_role_suggestions => {
let max_index = register_state.role_suggestions.len().saturating_sub(1);
let current_index = register_state.selected_suggestion_index.unwrap_or(0);
register_state.selected_suggestion_index = Some(if current_index == 0 { max_index } else { current_index.saturating_sub(1) });
Ok("Suggestion changed".to_string())
Ok("Suggestion changed up".to_string())
}
"select_suggestion" if register_state.show_role_suggestions => {
if let Some(selected_index) = register_state.selected_suggestion_index {