This commit is contained in:
A.K.M. Adib
2026-01-14 12:22:52 -05:00
parent dfb7dc7069
commit 7279903919
5 changed files with 6 additions and 16 deletions
@@ -385,7 +385,7 @@ describe('Composer', () => {
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.buffer.setText('some text');
const { stdin, unmount } = renderWithProviders(
<InputPrompt {...props} />,
);
await act(async () => {
stdin.write('\x1B\x1B');
vi.advanceTimersByTime(100);
expect(props.onSubmit).toHaveBeenCalledWith('/rewind');
});
const { unmount } = renderWithProviders(<InputPrompt {...props} />);
unmount();
});
@@ -506,9 +506,7 @@ export const InputPrompt: React.FC<InputPromptProps> = ({
resetEscapeState();
}, 500);
} else {
// Second ESC triggers rewind
resetEscapeState();
onSubmit('/rewind');
}
return;
}
@@ -877,7 +875,6 @@ export const InputPrompt: React.FC<InputPromptProps> = ({
kittyProtocol.enabled,
tryLoadQueuedMessages,
setBannerVisible,
onSubmit,
activePtyId,
setEmbeddedShellFocused,
],
@@ -45,7 +45,9 @@ export const StatusDisplay: React.FC<StatusDisplayProps> = ({
}
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) {
@@ -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 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"`;