diff options
| author | metamuffin <metamuffin@disroot.org> | 2025-11-18 12:08:34 +0100 |
|---|---|---|
| committer | metamuffin <metamuffin@disroot.org> | 2025-11-18 12:08:34 +0100 |
| commit | bac47e456085ea153ae6ae1b1e28e41868693c9c (patch) | |
| tree | 062c157d66faa3935c1175433732d30c07d1cd5b /ui/src/props.rs | |
| parent | f3af9263b0472bcef3207906ce0e4d1d4aa3595b (diff) | |
| download | jellything-bac47e456085ea153ae6ae1b1e28e41868693c9c.tar jellything-bac47e456085ea153ae6ae1b1e28e41868693c9c.tar.bz2 jellything-bac47e456085ea153ae6ae1b1e28e41868693c9c.tar.zst | |
start reworking model
Diffstat (limited to 'ui/src/props.rs')
| -rw-r--r-- | ui/src/props.rs | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/ui/src/props.rs b/ui/src/props.rs index fbeddca..64713ea 100644 --- a/ui/src/props.rs +++ b/ui/src/props.rs @@ -8,7 +8,7 @@ use crate::{ locale::{Language, tr, trs}, }; use jellycommon::{ - Node, Rating, Visibility, + Node, RatingType, Visibility, chrono::DateTime, user::{NodeUserData, WatchedState}, }; @@ -38,14 +38,14 @@ markup::define! { // } @for (kind, value) in &node.ratings { @match kind { - Rating::YoutubeLikes => {p.likes{ @format_count(*value as usize) " Likes" }} - Rating::YoutubeViews => {p{ @format_count(*value as usize) " Views" }} - Rating::YoutubeFollowers => {p{ @format_count(*value as usize) " Subscribers" }} - Rating::RottenTomatoes => {p.rating{ @value " Tomatoes" }} - Rating::Metacritic if *full => {p{ "Metacritic Score: " @value }} - Rating::Imdb => {p.rating{ "IMDb " @value }} - Rating::Tmdb => {p.rating{ "TMDB " @value }} - Rating::Trakt if *full => {p.rating{ "Trakt " @value }} + RatingType::YoutubeLikes => {p.likes{ @format_count(*value as usize) " Likes" }} + RatingType::YoutubeViews => {p{ @format_count(*value as usize) " Views" }} + RatingType::YoutubeFollowers => {p{ @format_count(*value as usize) " Subscribers" }} + RatingType::RottenTomatoes => {p.rating{ @value " Tomatoes" }} + RatingType::Metacritic if *full => {p{ "Metacritic Score: " @value }} + RatingType::Imdb => {p.rating{ "IMDb " @value }} + RatingType::Tmdb => {p.rating{ "TMDB " @value }} + RatingType::Trakt if *full => {p.rating{ "Trakt " @value }} _ => {} } } |