From e3967a994847e9aa1b6e7e171176ae7a0a761cc5 Mon Sep 17 00:00:00 2001 From: "Dhanji R. Prasanna" Date: Sat, 17 Jan 2026 05:00:12 +0530 Subject: [PATCH] refactor: remove animation from context thinning display Simplify print_context_thinning to just print the message directly. The message already contains proper ANSI formatting from context_window.rs. Removes the flash animation and 'Context optimized successfully' footer. --- crates/g3-cli/src/ui_writer_impl.rs | 30 ++--------------------------- 1 file changed, 2 insertions(+), 28 deletions(-) diff --git a/crates/g3-cli/src/ui_writer_impl.rs b/crates/g3-cli/src/ui_writer_impl.rs index 48ff3b9..6db13b3 100644 --- a/crates/g3-cli/src/ui_writer_impl.rs +++ b/crates/g3-cli/src/ui_writer_impl.rs @@ -247,34 +247,8 @@ impl UiWriter for ConsoleUiWriter { } fn print_context_thinning(&self, message: &str) { - // Animated highlight for context thinning - // Use bright cyan/green with a quick flash animation - - // Flash animation: print with bright background, then normal - let frames = vec![ - "\x1b[1;97;46m", // Frame 1: Bold white on cyan background - "\x1b[1;97;42m", // Frame 2: Bold white on green background - "\x1b[1;96;40m", // Frame 3: Bold cyan on black background - ]; - - println!(); - - // Quick flash animation - for frame in &frames { - print!("\r{} ✨ {} ✨\x1b[0m\x1b[K", frame, message); - let _ = io::stdout().flush(); - std::thread::sleep(std::time::Duration::from_millis(80)); - } - - // Final display with bright cyan and sparkle emojis - print!("\r\x1b[1;96m✨ {} ✨\x1b[0m\x1b[K", message); - println!(); - - // Add a subtle "success" indicator line - println!("\x1b[2;36m └─ Context optimized successfully\x1b[0m"); - println!(); - - let _ = io::stdout().flush(); + // Simple status line output - message already contains ANSI formatting + println!("{}", message); } fn print_tool_header(&self, tool_name: &str, _tool_args: Option<&serde_json::Value>) {