chore: bump version

This commit is contained in:
Michel de Graaf
2025-11-12 02:03:17 +01:00
parent 5816d9b632
commit e87853c66a
7 changed files with 39 additions and 15 deletions
+1 -4
View File
@@ -11,10 +11,7 @@ use models::FileDownloadState;
use soulseek_rs::{Client, ClientSettings, PeerAddress};
use std::{
env,
sync::{
atomic::AtomicBool,
Arc,
},
sync::{atomic::AtomicBool, Arc},
time::Duration,
};
use ui::{show_multi_download_progress, FileSelector};
+25 -4
View File
@@ -5,7 +5,10 @@ use ratatui::{
crossterm::event::{self, poll, Event, KeyCode, KeyEvent, KeyEventKind},
layout::{Alignment, Constraint, Layout},
style::{Color, Style},
widgets::{Block, Borders, Cell, Paragraph, Row, StatefulWidget, Table, TableState, Wrap},
widgets::{
Block, Borders, Cell, Paragraph, Row, StatefulWidget, Table,
TableState, Wrap,
},
DefaultTerminal, Frame,
};
use soulseek_rs::Client;
@@ -461,11 +464,29 @@ impl FileSelector {
if let Some(info_area) = info_area {
let (info_text, title, color) = if self.is_searching {
(format!("Search: {}", self.search_query), "Filter", Color::Yellow)
(
format!("Search: {}", self.search_query),
"Filter",
Color::Yellow,
)
} else if !self.search_query.is_empty() {
(format!("Current filter: {} (press / to modify, c to clear)", self.search_query), "Filter", Color::Cyan)
(
format!(
"Current filter: {} (press / to modify, c to clear)",
self.search_query
),
"Filter",
Color::Cyan,
)
} else {
(format!("{} file(s) selected for download", self.selected_indices.len()), "Selection", Color::Green)
(
format!(
"{} file(s) selected for download",
self.selected_indices.len()
),
"Selection",
Color::Green,
)
};
let info_widget = Paragraph::new(info_text)
@@ -1,11 +1,15 @@
use crate::models::FileDownloadState;
use crate::ui::{format_bytes_progress, format_speed, header_style, highlight_style};
use crate::ui::{
format_bytes_progress, format_speed, header_style, highlight_style,
};
use color_eyre::Result;
use ratatui::{
crossterm::event::{self, poll, Event, KeyCode, KeyEvent, KeyEventKind},
layout::{Constraint, Layout},
style::{Color, Style},
widgets::{Block, Borders, Cell, Paragraph, Row, StatefulWidget, Table, TableState},
widgets::{
Block, Borders, Cell, Paragraph, Row, StatefulWidget, Table, TableState,
},
DefaultTerminal, Frame,
};
use soulseek_rs::DownloadStatus;
+3 -1
View File
@@ -14,6 +14,8 @@ pub fn format_speed(speed_bytes_per_sec: f64) -> String {
format!("{:.1} MB/s", mb)
}
pub fn get_bitrate(attribs: &std::collections::HashMap<u32, u32>) -> Option<u32> {
pub fn get_bitrate(
attribs: &std::collections::HashMap<u32, u32>,
) -> Option<u32> {
attribs.get(&0).copied()
}