diff --git a/packages/cli/src/ui/components/SettingsDialog.tsx b/packages/cli/src/ui/components/SettingsDialog.tsx index 55e46632d1..3789a3c027 100644 --- a/packages/cli/src/ui/components/SettingsDialog.tsx +++ b/packages/cli/src/ui/components/SettingsDialog.tsx @@ -951,12 +951,10 @@ export function SettingsDialog({ const afterCursor = cpSlice(editBuffer, editCursorPos + 1); displayValue = beforeCursor + chalk.inverse(atCursor) + afterCursor; - } else if ( - cursorVisible && - editCursorPos >= cpLen(editBuffer) - ) { + } else if (editCursorPos >= cpLen(editBuffer)) { // Cursor is at the end - show inverted space - displayValue = editBuffer + chalk.inverse(' '); + displayValue = + editBuffer + (cursorVisible ? chalk.inverse(' ') : ' '); } else { // Cursor not visible displayValue = editBuffer;