This commit is contained in:
Mikhail Kilin
2026-02-13 19:52:53 +03:00
parent 6d08300daa
commit 6639dc876c
38 changed files with 961 additions and 123 deletions

View File

@@ -9,7 +9,7 @@ mod state;
pub mod methods;
pub use chat_filter::{ChatFilter, ChatFilterCriteria};
pub use chat_state::ChatState;
pub use chat_state::{ChatState, InputMode};
pub use state::AppScreen;
pub use methods::*;
@@ -60,6 +60,8 @@ pub struct App<T: TdClientTrait = TdClient> {
pub td_client: T,
/// Состояние чата - type-safe state machine (новое!)
pub chat_state: ChatState,
/// Vim-like input mode: Normal (navigation) / Insert (text input)
pub input_mode: InputMode,
// Auth state (приватные, доступ через геттеры)
phone_input: String,
code_input: String,
@@ -144,6 +146,7 @@ impl<T: TdClientTrait> App<T> {
screen: AppScreen::Loading,
td_client,
chat_state: ChatState::Normal,
input_mode: InputMode::Normal,
phone_input: String::new(),
code_input: String::new(),
password_input: String::new(),