From 4a4ae89b1b069f609f016dfcecf2f8f7c333be33 Mon Sep 17 00:00:00 2001 From: JMARyA Date: Sat, 14 Dec 2024 00:24:10 +0100 Subject: [PATCH] ui --- src/library/mod.rs | 3 +- src/main.rs | 4 +- src/pages/components.rs | 130 ++++++++++++++++++++++++++++++++++++---- src/pages/index.rs | 60 ++++++++++++++++--- src/pages/mod.rs | 10 ++++ src/pages/watch.rs | 53 ++++++++++++++++ 6 files changed, 238 insertions(+), 22 deletions(-) create mode 100644 src/pages/watch.rs diff --git a/src/library/mod.rs b/src/library/mod.rs index 59dc468..c67473f 100644 --- a/src/library/mod.rs +++ b/src/library/mod.rs @@ -1,5 +1,6 @@ use std::path::Path; use std::path::PathBuf; +use std::str::FromStr; use walkdir::WalkDir; use func::is_video_file; @@ -96,7 +97,7 @@ impl Library { pub async fn get_video_by_id(&self, id: &str) -> Option