style: Applied uniform formatting across all new Lidarr files
This commit is contained in:
@@ -31,7 +31,13 @@ impl DrawUi for DeleteArtistUi {
|
||||
let selected_block = app.data.lidarr_data.selected_block.get_active_block();
|
||||
let prompt = format!(
|
||||
"Do you really want to delete the artist: \n{}?",
|
||||
app.data.lidarr_data.artists.current_selection().artist_name.text
|
||||
app
|
||||
.data
|
||||
.lidarr_data
|
||||
.artists
|
||||
.current_selection()
|
||||
.artist_name
|
||||
.text
|
||||
);
|
||||
let checkboxes = vec![
|
||||
Checkbox::new("Delete Artist Files")
|
||||
|
||||
@@ -6,9 +6,9 @@ mod tests {
|
||||
use crate::models::servarr_data::lidarr::lidarr_data::{
|
||||
ActiveLidarrBlock, DELETE_ARTIST_BLOCKS, LIBRARY_BLOCKS,
|
||||
};
|
||||
use crate::ui::DrawUi;
|
||||
use crate::ui::lidarr_ui::library::{LibraryUi, decorate_artist_row_with_style};
|
||||
use crate::ui::styles::ManagarrStyle;
|
||||
use crate::ui::DrawUi;
|
||||
use pretty_assertions::assert_eq;
|
||||
use ratatui::widgets::{Cell, Row};
|
||||
|
||||
@@ -183,9 +183,9 @@ mod tests {
|
||||
};
|
||||
use rstest::rstest;
|
||||
|
||||
use crate::ui::DrawUi;
|
||||
use crate::ui::lidarr_ui::library::LibraryUi;
|
||||
use crate::ui::ui_test_utils::test_utils::{TerminalSize, render_to_string_with_app};
|
||||
use crate::ui::DrawUi;
|
||||
|
||||
#[rstest]
|
||||
fn test_library_ui_renders(
|
||||
|
||||
@@ -84,12 +84,9 @@ fn draw_library(f: &mut Frame<'_>, app: &mut App<'_>, area: Rect) {
|
||||
.statistics
|
||||
.as_ref()
|
||||
.map_or(0, |stats| stats.album_count);
|
||||
let tracks = artist
|
||||
.statistics
|
||||
.as_ref()
|
||||
.map_or(String::new(), |stats| {
|
||||
format!("{}/{}", stats.track_file_count, stats.total_track_count)
|
||||
});
|
||||
let tracks = artist.statistics.as_ref().map_or(String::new(), |stats| {
|
||||
format!("{}/{}", stats.track_file_count, stats.total_track_count)
|
||||
});
|
||||
let tags = artist
|
||||
.tags
|
||||
.iter()
|
||||
|
||||
Reference in New Issue
Block a user