aboutsummaryrefslogtreecommitdiff
path: root/server/src
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2025-02-05 23:42:13 +0100
committermetamuffin <metamuffin@disroot.org>2025-02-05 23:42:13 +0100
commit8fd96b46e73a0e7f984305e487e383a471dfcf88 (patch)
treef14544a25e15da93a0cf752fbc7baa1228d75088 /server/src
parentdf36a85b54fd427cc0914320d29aa4f005e5aff7 (diff)
downloadjellything-8fd96b46e73a0e7f984305e487e383a471dfcf88.tar
jellything-8fd96b46e73a0e7f984305e487e383a471dfcf88.tar.bz2
jellything-8fd96b46e73a0e7f984305e487e383a471dfcf88.tar.zst
widecards and season views
Diffstat (limited to 'server/src')
-rw-r--r--server/src/routes/ui/account/session/guard.rs1
-rw-r--r--server/src/routes/ui/node.rs5
-rw-r--r--server/src/routes/ui/style.rs4
3 files changed, 5 insertions, 5 deletions
diff --git a/server/src/routes/ui/account/session/guard.rs b/server/src/routes/ui/account/session/guard.rs
index 208e45a..295c2d4 100644
--- a/server/src/routes/ui/account/session/guard.rs
+++ b/server/src/routes/ui/account/session/guard.rs
@@ -41,6 +41,7 @@ impl Session {
#[cfg(feature = "bypass-auth")]
{
+ parse_jellyfin_auth("a"); // unused warning is annoying
username = "admin".to_string();
}
diff --git a/server/src/routes/ui/node.rs b/server/src/routes/ui/node.rs
index f8b448f..75893a8 100644
--- a/server/src/routes/ui/node.rs
+++ b/server/src/routes/ui/node.rs
@@ -119,9 +119,8 @@ markup::define! {
}
}
NodeCardWide<'a>(node: &'a Node, udata: &'a NodeUserData) {
- @let cls = format!("node card widecard poster {}", aspect_class(node.kind));
- div[class=cls] {
- .poster {
+ div[class="node card widecard poster"] {
+ div[class=&format!("poster {}", aspect_class(node.kind))] {
a[href=uri!(r_library_node(&node.slug))] {
img[src=uri!(r_item_poster(&node.slug, Some(1024))), loading="lazy"];
}
diff --git a/server/src/routes/ui/style.rs b/server/src/routes/ui/style.rs
index a719b67..c935c8a 100644
--- a/server/src/routes/ui/style.rs
+++ b/server/src/routes/ui/style.rs
@@ -12,7 +12,7 @@ use rocket::{
macro_rules! concat_files {
([$base: expr], $($files:literal),*) => {{
- #[cfg(debug_assertions)]
+ #[cfg(any(debug_assertions, feature = "hot-css"))]
{
use std::{fs::read_to_string, path::PathBuf, str::FromStr};
[ $($files),* ]
@@ -28,7 +28,7 @@ macro_rules! concat_files {
.collect::<Vec<_>>()
.join("\n")
}
- #[cfg(not(debug_assertions))]
+ #[cfg(not(any(debug_assertions, feature = "hot-css")))]
concat!($(include_str!(concat!($base, "/", $files))),*).to_string()
}};
}