diff --git a/src/pages/chat/chat_room.rs b/src/pages/chat/chat_room.rs deleted file mode 100644 index 541754e..0000000 --- a/src/pages/chat/chat_room.rs +++ /dev/null @@ -1,21 +0,0 @@ -use dioxus::prelude::*; - -use crate::{components::organisms::chat::ActiveRoom, hooks::use_messages::use_messages}; - -#[inline_props] -pub fn ChatRoom(cx: Scope, name: String) -> Element { - let _ = &name; - let messages = use_messages(cx); - - use_coroutine(cx, |_: UnboundedReceiver| { - to_owned![messages]; - - async move { - messages.reset(); - } - }); - - render! { - ActiveRoom {} - } -} diff --git a/src/pages/chat/mod.rs b/src/pages/chat/mod.rs index 387fb02..82c134e 100644 --- a/src/pages/chat/mod.rs +++ b/src/pages/chat/mod.rs @@ -1,4 +1,3 @@ pub mod chat; pub mod chat_list; -pub mod chat_room; pub mod room; diff --git a/src/pages/route.rs b/src/pages/route.rs index fe76073..67957cc 100644 --- a/src/pages/route.rs +++ b/src/pages/route.rs @@ -4,7 +4,7 @@ use dioxus_router::prelude::*; use super::{page_not_found::PageNotFound, profile::profile::Profile, profile::verify::Verify}; use crate::{ - pages::chat::chat::Chat, pages::chat::chat_list::ChatList, pages::chat::chat_room::ChatRoom, + pages::chat::chat::Chat, pages::chat::chat_list::ChatList, pages::chat::room::group::RoomGroup, pages::chat::room::new::RoomNew, }; @@ -23,8 +23,6 @@ pub enum Route { #[layout(Chat)] #[route("/list")] ChatList {}, - #[route("/chat/:name")] - ChatRoom {name: String}, #[end_layout] #[route("/room")] RoomNew {},