mirror of
https://github.com/J3vb/OwnCord.git
synced 2026-09-03 03:50:00 +03:00
Complete Tauri v2 client implementation migrated from WPF/.NET 8: - Rust backend: WS proxy with TLS cert bypass for self-signed servers, settings storage, system tray, global hotkeys - TypeScript frontend: login/register, chat messaging, channel sidebar, member list, voice channel UI, settings overlay with log viewer, server profiles, quick switcher, emoji picker, file uploads - 21 test suites (364 tests) covering stores, services, and components - Security: bounded WS channel, wss:// URL validation, TLS signature verification, profile import validation, token redaction, HTTPS-only HTTP scope Also updates CLAUDE.md to correct API path rule (/api/v1/) and adds Tauri client CI workflow.
30 lines
936 B
Rust
30 lines
936 B
Rust
mod commands;
|
|
mod hotkeys;
|
|
mod tray;
|
|
mod ws_proxy;
|
|
|
|
#[cfg_attr(mobile, tauri::mobile_entry_point)]
|
|
pub fn run() {
|
|
tauri::Builder::default()
|
|
.plugin(tauri_plugin_store::Builder::new().build())
|
|
.plugin(tauri_plugin_global_shortcut::Builder::new().build())
|
|
.plugin(tauri_plugin_notification::init())
|
|
.plugin(tauri_plugin_http::init())
|
|
.manage(ws_proxy::WsState::new())
|
|
.invoke_handler(tauri::generate_handler![
|
|
commands::get_settings,
|
|
commands::save_settings,
|
|
commands::store_cert_fingerprint,
|
|
commands::get_cert_fingerprint,
|
|
ws_proxy::ws_connect,
|
|
ws_proxy::ws_send,
|
|
ws_proxy::ws_disconnect,
|
|
])
|
|
.setup(|app| {
|
|
tray::create_tray(app.handle())?;
|
|
Ok(())
|
|
})
|
|
.run(tauri::generate_context!())
|
|
.expect("error while running tauri application");
|
|
}
|