feat(cli): implement stable 2-row footer layout with responsive collision handling

This commit introduces a new, more stable footer architecture that addresses
several long-standing UX issues:
- Stabilizes the layout by anchoring mode indicators and context summaries
- Protects safety indicators (YOLO/Plan) from being hidden by notifications
- Decouples ambient tips/wit from real system status to prevent confusion
- Implements intelligent collision detection for narrow terminal windows
- Keeps input visible but disabled during tool approval pauses
- Enhances visual consistency with unified status colors and hook icons
This commit is contained in:
Keith Guerin
2026-02-28 01:30:40 -08:00
parent 703759cfae
commit f451f747f4
13 changed files with 1231 additions and 217 deletions

View File

@@ -11,7 +11,7 @@ import type { LoadingPhrasesMode } from '../../config/settings.js';
export const PHRASE_CHANGE_INTERVAL_MS = 15000;
export const INTERACTIVE_SHELL_WAITING_PHRASE =
'Interactive shell awaiting input... press tab to focus shell';
'! Shell awaiting input (Tab to focus)';
/**
* Custom hook to manage cycling through loading phrases.
@@ -74,12 +74,12 @@ export const usePhraseCycler = (
phraseList = wittyPhrases;
break;
case 'all':
// Show a tip on the first request after startup, then continue with 1/6 chance
// Show a tip on the first request after startup, then continue with 1/2 chance
if (!hasShownFirstRequestTipRef.current) {
phraseList = INFORMATIVE_TIPS;
hasShownFirstRequestTipRef.current = true;
} else {
const showTip = Math.random() < 1 / 6;
const showTip = Math.random() < 1 / 2;
phraseList = showTip ? INFORMATIVE_TIPS : wittyPhrases;
}
break;