fix(tui): replace standalone compacting label with animated working label

This commit is contained in:
donglovejava
2026-05-28 11:28:05 +08:00
committed by Hunter Bown
parent 5c7209af83
commit 9ef5a6d782
+3 -10
View File
@@ -88,15 +88,8 @@ pub(crate) fn render_footer(f: &mut Frame, area: Rect, app: &mut App) {
let mut label = active_subagent_status_label(app)
.or_else(|| active_tool_status_label(app))
.unwrap_or_else(|| {
// Show a more specific label when the model is still loading
// or compacting, not just a generic "working…".
let base = if app.is_loading {
crate::tui::widgets::footer_working_label(dot_frame, app.ui_locale)
} else if app.is_compacting {
"compacting".to_string()
} else {
crate::tui::widgets::footer_working_label(dot_frame, app.ui_locale)
};
// Show the working label during active turns (loading, compacting, etc.).
let base = crate::tui::widgets::footer_working_label(dot_frame, app.ui_locale);
if elapsed_secs > 0 {
format!("{base} ({elapsed_secs}s)")
} else {
@@ -896,4 +889,4 @@ pub(crate) fn format_context_budget(used: i64, max: u32) -> String {
#[cfg(test)]
pub(crate) fn spans_width(spans: &[Span<'_>]) -> usize {
spans.iter().map(|span| span.content.width()).sum()
}
}