we successfully compiled and wen from auth state to login state and auth state

This commit is contained in:
filipriec
2025-04-13 17:47:00 +02:00
parent 1dd5f685a6
commit 3d0a9f2082
14 changed files with 120 additions and 114 deletions

View File

@@ -2,7 +2,7 @@
use crate::config::binds::config::Config;
use crate::services::grpc_client::GrpcClient;
use crate::state::pages::{auth::{AuthState, RegisterState}};
use crate::state::pages::{auth::{LoginState, RegisterState}};
use crate::state::canvas_state::CanvasState;
use crate::state::pages::form::FormState;
use crate::functions::modes::edit::{auth_e, form_e};
@@ -14,7 +14,7 @@ pub async fn handle_edit_event(
key: KeyEvent,
config: &Config,
form_state: &mut FormState,
auth_state: &mut AuthState,
login_state: &mut LoginState,
register_state: &mut RegisterState,
ideal_cursor_column: &mut usize,
command_message: &mut String,
@@ -44,7 +44,7 @@ pub async fn handle_edit_event(
let message = if app_state.ui.show_login {
auth_e::execute_common_action(
action,
auth_state, // Concrete AuthState
login_state,
grpc_client,
current_position,
total_count
@@ -99,7 +99,7 @@ pub async fn handle_edit_event(
auth_e::execute_edit_action(
action,
key,
auth_state,
login_state,
ideal_cursor_column,
grpc_client,
current_position,
@@ -143,7 +143,7 @@ pub async fn handle_edit_event(
auth_e::execute_edit_action(
"insert_char",
key,
auth_state,
login_state,
ideal_cursor_column,
grpc_client,
current_position,