From 6e4a9e2d51cd645dae0d735b37a152d4363ac711 Mon Sep 17 00:00:00 2001 From: spinline Date: Thu, 5 Feb 2026 18:49:51 +0300 Subject: [PATCH] fix: resolve frontend build errors and warnings --- Cargo.lock | 1 + frontend/Cargo.toml | 1 + frontend/src/components/torrent/table.rs | 2 +- shared/src/lib.rs | 2 +- 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 448fd1f..4fb80b3 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -695,6 +695,7 @@ dependencies = [ "console_log", "futures", "gloo-net 0.5.0", + "js-sys", "leptos", "leptos_router", "log", diff --git a/frontend/Cargo.toml b/frontend/Cargo.toml index 63b3726..36b3ddd 100644 --- a/frontend/Cargo.toml +++ b/frontend/Cargo.toml @@ -40,3 +40,4 @@ web-sys = { version = "0.3", features = [ ] } shared = { path = "../shared" } tailwind_fuse = "0.3.2" +js-sys = "0.3.85" diff --git a/frontend/src/components/torrent/table.rs b/frontend/src/components/torrent/table.rs index 6bbcd12..6e50987 100644 --- a/frontend/src/components/torrent/table.rs +++ b/frontend/src/components/torrent/table.rs @@ -384,7 +384,7 @@ pub fn TorrentTable() -> impl IntoView { shared::TorrentStatus::Error => "badge-error badge-soft", _ => "badge-ghost" }; - let t_hash = t.hash.clone(); + let _t_hash = t.hash.clone(); let t_hash_click = t.hash.clone(); let (timer_id, set_timer_id) = create_signal(Option::::None); diff --git a/shared/src/lib.rs b/shared/src/lib.rs index 522f093..400f820 100644 --- a/shared/src/lib.rs +++ b/shared/src/lib.rs @@ -39,7 +39,7 @@ pub enum AppEvent { Notification(SystemNotification), } -#[derive(Debug, Serialize, Deserialize, Clone, ToSchema)] +#[derive(Debug, Serialize, Deserialize, Clone, ToSchema, PartialEq, Eq)] pub struct SystemNotification { pub level: NotificationLevel, pub message: String,