diff --git a/crates/g3-cli/src/tui.rs b/crates/g3-cli/src/tui.rs index c1202c7..cf9629a 100644 --- a/crates/g3-cli/src/tui.rs +++ b/crates/g3-cli/src/tui.rs @@ -42,7 +42,7 @@ impl SimpleOutput { pub fn print_context(&self, used: u32, total: u32, percentage: f32) { let bar_width = 10; let filled_width = ((percentage / 100.0) * bar_width as f32) as usize; - let empty_width = bar_width - filled_width; + let empty_width = bar_width.saturating_sub(filled_width); let filled_chars = "●".repeat(filled_width); let empty_chars = "○".repeat(empty_width);