mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-05-12 21:03:05 -07:00
complete
This commit is contained in:
@@ -385,7 +385,7 @@ describe('Composer', () => {
|
|||||||
|
|
||||||
const { lastFrame } = renderComposer(uiState);
|
const { lastFrame } = renderComposer(uiState);
|
||||||
|
|
||||||
expect(lastFrame()).toContain('Press Esc again to rewind');
|
expect(lastFrame()).toContain('Clearing input is now Ctrl + C');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -1898,16 +1898,7 @@ describe('InputPrompt', () => {
|
|||||||
props.onEscapePromptChange = onEscapePromptChange;
|
props.onEscapePromptChange = onEscapePromptChange;
|
||||||
props.buffer.setText('some text');
|
props.buffer.setText('some text');
|
||||||
|
|
||||||
const { stdin, unmount } = renderWithProviders(
|
const { unmount } = renderWithProviders(<InputPrompt {...props} />);
|
||||||
<InputPrompt {...props} />,
|
|
||||||
);
|
|
||||||
|
|
||||||
await act(async () => {
|
|
||||||
stdin.write('\x1B\x1B');
|
|
||||||
vi.advanceTimersByTime(100);
|
|
||||||
|
|
||||||
expect(props.onSubmit).toHaveBeenCalledWith('/rewind');
|
|
||||||
});
|
|
||||||
unmount();
|
unmount();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -506,9 +506,7 @@ export const InputPrompt: React.FC<InputPromptProps> = ({
|
|||||||
resetEscapeState();
|
resetEscapeState();
|
||||||
}, 500);
|
}, 500);
|
||||||
} else {
|
} else {
|
||||||
// Second ESC triggers rewind
|
|
||||||
resetEscapeState();
|
resetEscapeState();
|
||||||
onSubmit('/rewind');
|
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -877,7 +875,6 @@ export const InputPrompt: React.FC<InputPromptProps> = ({
|
|||||||
kittyProtocol.enabled,
|
kittyProtocol.enabled,
|
||||||
tryLoadQueuedMessages,
|
tryLoadQueuedMessages,
|
||||||
setBannerVisible,
|
setBannerVisible,
|
||||||
onSubmit,
|
|
||||||
activePtyId,
|
activePtyId,
|
||||||
setEmbeddedShellFocused,
|
setEmbeddedShellFocused,
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -45,7 +45,9 @@ export const StatusDisplay: React.FC<StatusDisplayProps> = ({
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (uiState.showEscapePrompt) {
|
if (uiState.showEscapePrompt) {
|
||||||
return <Text color={theme.text.secondary}>Press Esc again to rewind.</Text>;
|
return (
|
||||||
|
<Text color={theme.text.secondary}>Clearing input is now Ctrl + C</Text>
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (uiState.queueErrorMessage) {
|
if (uiState.queueErrorMessage) {
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ exports[`StatusDisplay > renders ContextSummaryDisplay by default 1`] = `"Mock C
|
|||||||
|
|
||||||
exports[`StatusDisplay > renders Ctrl+D prompt 1`] = `"Press Ctrl+D again to exit."`;
|
exports[`StatusDisplay > renders Ctrl+D prompt 1`] = `"Press Ctrl+D again to exit."`;
|
||||||
|
|
||||||
exports[`StatusDisplay > renders Escape prompt 1`] = `"Press Esc again to rewind."`;
|
exports[`StatusDisplay > renders Escape prompt 1`] = `"Clearing input is now Ctrl + C"`;
|
||||||
|
|
||||||
exports[`StatusDisplay > renders HookStatusDisplay when hooks are active 1`] = `"Mock Hook Status Display"`;
|
exports[`StatusDisplay > renders HookStatusDisplay when hooks are active 1`] = `"Mock Hook Status Display"`;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user