mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-13 23:01:09 -07:00
feat(ui): use Tab to switch focus between shell and input (#14332)
This commit is contained in:
@@ -15,12 +15,14 @@ export interface UseAutoAcceptIndicatorArgs {
|
||||
config: Config;
|
||||
addItem?: (item: HistoryItemWithoutId, timestamp: number) => void;
|
||||
onApprovalModeChange?: (mode: ApprovalMode) => void;
|
||||
isActive?: boolean;
|
||||
}
|
||||
|
||||
export function useAutoAcceptIndicator({
|
||||
config,
|
||||
addItem,
|
||||
onApprovalModeChange,
|
||||
isActive = true,
|
||||
}: UseAutoAcceptIndicatorArgs): ApprovalMode {
|
||||
const currentConfigValue = config.getApprovalMode();
|
||||
const [showAutoAcceptIndicator, setShowAutoAcceptIndicator] =
|
||||
@@ -82,7 +84,7 @@ export function useAutoAcceptIndicator({
|
||||
}
|
||||
}
|
||||
},
|
||||
{ isActive: true },
|
||||
{ isActive },
|
||||
);
|
||||
|
||||
return showAutoAcceptIndicator;
|
||||
|
||||
@@ -12,7 +12,7 @@ import { useInactivityTimer } from './useInactivityTimer.js';
|
||||
|
||||
export const PHRASE_CHANGE_INTERVAL_MS = 15000;
|
||||
export const INTERACTIVE_SHELL_WAITING_PHRASE =
|
||||
'Interactive shell awaiting input... press Ctrl+f to focus shell';
|
||||
'Interactive shell awaiting input... press tab to focus shell';
|
||||
|
||||
/**
|
||||
* Custom hook to manage cycling through loading phrases.
|
||||
|
||||
Reference in New Issue
Block a user