@vybestack/llxprt-code 0.1.14 → 0.1.16-hotfix1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (238) hide show
  1. package/README.md +90 -2
  2. package/dist/package.json +4 -5
  3. package/dist/src/config/config.d.ts +4 -1
  4. package/dist/src/config/config.js +151 -54
  5. package/dist/src/config/config.js.map +1 -1
  6. package/dist/src/config/extension.d.ts +1 -0
  7. package/dist/src/config/extension.js +4 -0
  8. package/dist/src/config/extension.js.map +1 -1
  9. package/dist/src/config/settings.d.ts +13 -3
  10. package/dist/src/config/settings.js +84 -23
  11. package/dist/src/config/settings.js.map +1 -1
  12. package/dist/src/gemini.d.ts +3 -0
  13. package/dist/src/gemini.js +212 -36
  14. package/dist/src/gemini.js.map +1 -1
  15. package/dist/src/generated/git-commit.d.ts +1 -1
  16. package/dist/src/generated/git-commit.js +1 -1
  17. package/dist/src/generated/git-commit.js.map +1 -1
  18. package/dist/src/integration-tests/GITHUB_ACTIONS_README.md +41 -0
  19. package/dist/src/integration-tests/test-utils.d.ts +68 -0
  20. package/dist/src/integration-tests/test-utils.js +167 -0
  21. package/dist/src/integration-tests/test-utils.js.map +1 -0
  22. package/dist/src/nonInteractiveCli.js +24 -66
  23. package/dist/src/nonInteractiveCli.js.map +1 -1
  24. package/dist/src/providers/IFileSystem.d.ts +42 -0
  25. package/dist/src/providers/IFileSystem.js +46 -0
  26. package/dist/src/providers/IFileSystem.js.map +1 -0
  27. package/dist/src/providers/providerConfigUtils.d.ts +0 -4
  28. package/dist/src/providers/providerConfigUtils.js +21 -52
  29. package/dist/src/providers/providerConfigUtils.js.map +1 -1
  30. package/dist/src/providers/providerManagerInstance.d.ts +6 -1
  31. package/dist/src/providers/providerManagerInstance.js +117 -82
  32. package/dist/src/providers/providerManagerInstance.js.map +1 -1
  33. package/dist/src/services/BuiltinCommandLoader.js +13 -0
  34. package/dist/src/services/BuiltinCommandLoader.js.map +1 -1
  35. package/dist/src/services/CommandService.d.ts +8 -4
  36. package/dist/src/services/CommandService.js +24 -8
  37. package/dist/src/services/CommandService.js.map +1 -1
  38. package/dist/src/services/FileCommandLoader.d.ts +15 -3
  39. package/dist/src/services/FileCommandLoader.js +94 -42
  40. package/dist/src/services/FileCommandLoader.js.map +1 -1
  41. package/dist/src/services/McpPromptLoader.d.ts +25 -0
  42. package/dist/src/services/McpPromptLoader.js +192 -0
  43. package/dist/src/services/McpPromptLoader.js.map +1 -0
  44. package/dist/src/services/prompt-processors/shellProcessor.d.ts +32 -0
  45. package/dist/src/services/prompt-processors/shellProcessor.js +77 -0
  46. package/dist/src/services/prompt-processors/shellProcessor.js.map +1 -0
  47. package/dist/src/services/prompt-processors/types.d.ts +4 -0
  48. package/dist/src/services/prompt-processors/types.js +4 -0
  49. package/dist/src/services/prompt-processors/types.js.map +1 -1
  50. package/dist/src/ui/App.js +325 -195
  51. package/dist/src/ui/App.js.map +1 -1
  52. package/dist/src/ui/commands/aboutCommand.js +2 -5
  53. package/dist/src/ui/commands/aboutCommand.js.map +1 -1
  54. package/dist/src/ui/commands/baseurlCommand.js +54 -9
  55. package/dist/src/ui/commands/baseurlCommand.js.map +1 -1
  56. package/dist/src/ui/commands/chatCommand.js +39 -1
  57. package/dist/src/ui/commands/chatCommand.js.map +1 -1
  58. package/dist/src/ui/commands/diagnosticsCommand.d.ts +10 -0
  59. package/dist/src/ui/commands/diagnosticsCommand.js +122 -0
  60. package/dist/src/ui/commands/diagnosticsCommand.js.map +1 -0
  61. package/dist/src/ui/commands/directoryCommand.d.ts +8 -0
  62. package/dist/src/ui/commands/directoryCommand.js +116 -0
  63. package/dist/src/ui/commands/directoryCommand.js.map +1 -0
  64. package/dist/src/ui/commands/ideCommand.js +101 -105
  65. package/dist/src/ui/commands/ideCommand.js.map +1 -1
  66. package/dist/src/ui/commands/initCommand.d.ts +7 -0
  67. package/dist/src/ui/commands/initCommand.js +108 -0
  68. package/dist/src/ui/commands/initCommand.js.map +1 -0
  69. package/dist/src/ui/commands/keyCommand.js +75 -11
  70. package/dist/src/ui/commands/keyCommand.js.map +1 -1
  71. package/dist/src/ui/commands/keyfileCommand.js +54 -13
  72. package/dist/src/ui/commands/keyfileCommand.js.map +1 -1
  73. package/dist/src/ui/commands/mcpCommand.js +53 -8
  74. package/dist/src/ui/commands/mcpCommand.js.map +1 -1
  75. package/dist/src/ui/commands/memoryCommand.js +2 -1
  76. package/dist/src/ui/commands/memoryCommand.js.map +1 -1
  77. package/dist/src/ui/commands/modelCommand.js +2 -5
  78. package/dist/src/ui/commands/modelCommand.js.map +1 -1
  79. package/dist/src/ui/commands/profileCommand.d.ts +10 -0
  80. package/dist/src/ui/commands/profileCommand.js +592 -0
  81. package/dist/src/ui/commands/profileCommand.js.map +1 -0
  82. package/dist/src/ui/commands/providerCommand.js +46 -3
  83. package/dist/src/ui/commands/providerCommand.js.map +1 -1
  84. package/dist/src/ui/commands/setCommand.d.ts +7 -0
  85. package/dist/src/ui/commands/setCommand.js +431 -0
  86. package/dist/src/ui/commands/setCommand.js.map +1 -0
  87. package/dist/src/ui/commands/setupGithubCommand.d.ts +7 -0
  88. package/dist/src/ui/commands/setupGithubCommand.js +49 -0
  89. package/dist/src/ui/commands/setupGithubCommand.js.map +1 -0
  90. package/dist/src/ui/commands/types.d.ts +23 -4
  91. package/dist/src/ui/commands/types.js +1 -0
  92. package/dist/src/ui/commands/types.js.map +1 -1
  93. package/dist/src/ui/commands/vimCommand.js +0 -7
  94. package/dist/src/ui/commands/vimCommand.js.map +1 -1
  95. package/dist/src/ui/components/ContextSummaryDisplay.d.ts +3 -3
  96. package/dist/src/ui/components/ContextSummaryDisplay.js +8 -8
  97. package/dist/src/ui/components/ContextSummaryDisplay.js.map +1 -1
  98. package/dist/src/ui/components/DebugProfiler.d.ts +6 -0
  99. package/dist/src/ui/components/DebugProfiler.js +26 -0
  100. package/dist/src/ui/components/DebugProfiler.js.map +1 -0
  101. package/dist/src/ui/components/Footer.d.ts +2 -0
  102. package/dist/src/ui/components/Footer.js +5 -4
  103. package/dist/src/ui/components/Footer.js.map +1 -1
  104. package/dist/src/ui/components/Header.js +1 -1
  105. package/dist/src/ui/components/Header.js.map +1 -1
  106. package/dist/src/ui/components/Help.js +2 -2
  107. package/dist/src/ui/components/Help.js.map +1 -1
  108. package/dist/src/ui/components/IDEContextDetailDisplay.d.ts +5 -4
  109. package/dist/src/ui/components/IDEContextDetailDisplay.js +6 -8
  110. package/dist/src/ui/components/IDEContextDetailDisplay.js.map +1 -1
  111. package/dist/src/ui/components/InputPrompt.d.ts +2 -0
  112. package/dist/src/ui/components/InputPrompt.js +128 -13
  113. package/dist/src/ui/components/InputPrompt.js.map +1 -1
  114. package/dist/src/ui/components/LoadProfileDialog.d.ts +13 -0
  115. package/dist/src/ui/components/LoadProfileDialog.js +57 -0
  116. package/dist/src/ui/components/LoadProfileDialog.js.map +1 -0
  117. package/dist/src/ui/components/PrepareLabel.d.ts +15 -0
  118. package/dist/src/ui/components/PrepareLabel.js +16 -0
  119. package/dist/src/ui/components/PrepareLabel.js.map +1 -0
  120. package/dist/src/ui/components/ProviderModelDialog.js +75 -28
  121. package/dist/src/ui/components/ProviderModelDialog.js.map +1 -1
  122. package/dist/src/ui/components/SecureKeyInput.d.ts +15 -0
  123. package/dist/src/ui/components/SecureKeyInput.js +58 -0
  124. package/dist/src/ui/components/SecureKeyInput.js.map +1 -0
  125. package/dist/src/ui/components/ShellConfirmationDialog.d.ts +15 -0
  126. package/dist/src/ui/components/ShellConfirmationDialog.js +45 -0
  127. package/dist/src/ui/components/ShellConfirmationDialog.js.map +1 -0
  128. package/dist/src/ui/components/SuggestionsDisplay.d.ts +1 -0
  129. package/dist/src/ui/components/SuggestionsDisplay.js +3 -3
  130. package/dist/src/ui/components/SuggestionsDisplay.js.map +1 -1
  131. package/dist/src/ui/components/Tips.js +1 -1
  132. package/dist/src/ui/components/Tips.js.map +1 -1
  133. package/dist/src/ui/components/messages/ToolConfirmationMessage.js +15 -4
  134. package/dist/src/ui/components/messages/ToolConfirmationMessage.js.map +1 -1
  135. package/dist/src/ui/components/messages/UserMessage.js +4 -1
  136. package/dist/src/ui/components/messages/UserMessage.js.map +1 -1
  137. package/dist/src/ui/components/shared/text-buffer.d.ts +270 -2
  138. package/dist/src/ui/components/shared/text-buffer.js +410 -70
  139. package/dist/src/ui/components/shared/text-buffer.js.map +1 -1
  140. package/dist/src/ui/components/shared/vim-buffer-actions.d.ts +72 -0
  141. package/dist/src/ui/components/shared/vim-buffer-actions.js +565 -0
  142. package/dist/src/ui/components/shared/vim-buffer-actions.js.map +1 -0
  143. package/dist/src/ui/containers/SessionController.js +14 -15
  144. package/dist/src/ui/containers/SessionController.js.map +1 -1
  145. package/dist/src/ui/contexts/VimModeContext.js +2 -2
  146. package/dist/src/ui/contexts/VimModeContext.js.map +1 -1
  147. package/dist/src/ui/editors/editorSettingsManager.js +2 -0
  148. package/dist/src/ui/editors/editorSettingsManager.js.map +1 -1
  149. package/dist/src/ui/hooks/atCommandProcessor.js +56 -48
  150. package/dist/src/ui/hooks/atCommandProcessor.js.map +1 -1
  151. package/dist/src/ui/hooks/shellCommandProcessor.d.ts +1 -0
  152. package/dist/src/ui/hooks/shellCommandProcessor.js +139 -200
  153. package/dist/src/ui/hooks/shellCommandProcessor.js.map +1 -1
  154. package/dist/src/ui/hooks/slashCommandProcessor.d.ts +7 -3
  155. package/dist/src/ui/hooks/slashCommandProcessor.js +219 -130
  156. package/dist/src/ui/hooks/slashCommandProcessor.js.map +1 -1
  157. package/dist/src/ui/hooks/useAuthCommand.js +9 -0
  158. package/dist/src/ui/hooks/useAuthCommand.js.map +1 -1
  159. package/dist/src/ui/hooks/useCompletion.d.ts +5 -5
  160. package/dist/src/ui/hooks/useCompletion.js +7 -402
  161. package/dist/src/ui/hooks/useCompletion.js.map +1 -1
  162. package/dist/src/ui/hooks/useConsoleMessages.js +53 -37
  163. package/dist/src/ui/hooks/useConsoleMessages.js.map +1 -1
  164. package/dist/src/ui/hooks/useGeminiStream.js +75 -12
  165. package/dist/src/ui/hooks/useGeminiStream.js.map +1 -1
  166. package/dist/src/ui/hooks/useKeypress.js +5 -2
  167. package/dist/src/ui/hooks/useKeypress.js.map +1 -1
  168. package/dist/src/ui/hooks/useLoadProfileDialog.d.ts +27 -0
  169. package/dist/src/ui/hooks/useLoadProfileDialog.js +138 -0
  170. package/dist/src/ui/hooks/useLoadProfileDialog.js.map +1 -0
  171. package/dist/src/ui/hooks/useReactToolScheduler.js +0 -1
  172. package/dist/src/ui/hooks/useReactToolScheduler.js.map +1 -1
  173. package/dist/src/ui/hooks/useReverseSearchCompletion.d.ts +19 -0
  174. package/dist/src/ui/hooks/useReverseSearchCompletion.js +54 -0
  175. package/dist/src/ui/hooks/useReverseSearchCompletion.js.map +1 -0
  176. package/dist/src/ui/hooks/useShellHistory.d.ts +1 -0
  177. package/dist/src/ui/hooks/useShellHistory.js +30 -7
  178. package/dist/src/ui/hooks/useShellHistory.js.map +1 -1
  179. package/dist/src/ui/hooks/useSlashCompletion.d.ts +24 -0
  180. package/dist/src/ui/hooks/useSlashCompletion.js +451 -0
  181. package/dist/src/ui/hooks/useSlashCompletion.js.map +1 -0
  182. package/dist/src/ui/hooks/vim.d.ts +28 -0
  183. package/dist/src/ui/hooks/vim.js +630 -0
  184. package/dist/src/ui/hooks/vim.js.map +1 -0
  185. package/dist/src/ui/reducers/appReducer.d.ts +3 -2
  186. package/dist/src/ui/reducers/appReducer.js +1 -0
  187. package/dist/src/ui/reducers/appReducer.js.map +1 -1
  188. package/dist/src/ui/themes/theme-manager.js +10 -1
  189. package/dist/src/ui/themes/theme-manager.js.map +1 -1
  190. package/dist/src/ui/themes/theme.d.ts +1 -0
  191. package/dist/src/ui/themes/theme.js +19 -4
  192. package/dist/src/ui/themes/theme.js.map +1 -1
  193. package/dist/src/ui/utils/renderLoopDetector.js +3 -3
  194. package/dist/src/ui/utils/renderLoopDetector.js.map +1 -1
  195. package/dist/src/ui/utils/secureInputHandler.d.ts +46 -0
  196. package/dist/src/ui/utils/secureInputHandler.js +128 -0
  197. package/dist/src/ui/utils/secureInputHandler.js.map +1 -0
  198. package/dist/src/ui/utils/textUtils.d.ts +0 -8
  199. package/dist/src/ui/utils/textUtils.js +0 -22
  200. package/dist/src/ui/utils/textUtils.js.map +1 -1
  201. package/dist/src/ui/utils/updateCheck.d.ts +7 -1
  202. package/dist/src/ui/utils/updateCheck.js +59 -25
  203. package/dist/src/ui/utils/updateCheck.js.map +1 -1
  204. package/dist/src/utils/events.d.ts +11 -0
  205. package/dist/src/utils/events.js +13 -0
  206. package/dist/src/utils/events.js.map +1 -0
  207. package/dist/src/utils/gitUtils.d.ts +10 -0
  208. package/dist/src/utils/gitUtils.js +24 -0
  209. package/dist/src/utils/gitUtils.js.map +1 -0
  210. package/dist/src/utils/handleAutoUpdate.d.ts +11 -0
  211. package/dist/src/utils/handleAutoUpdate.js +101 -0
  212. package/dist/src/utils/handleAutoUpdate.js.map +1 -0
  213. package/dist/src/utils/installationInfo.d.ts +23 -0
  214. package/dist/src/utils/installationInfo.js +154 -0
  215. package/dist/src/utils/installationInfo.js.map +1 -0
  216. package/dist/src/utils/sandbox-macos-permissive-closed.sb +6 -0
  217. package/dist/src/utils/sandbox-macos-permissive-open.sb +6 -0
  218. package/dist/src/utils/sandbox-macos-permissive-proxied.sb +6 -0
  219. package/dist/src/utils/sandbox-macos-restrictive-closed.sb +6 -0
  220. package/dist/src/utils/sandbox-macos-restrictive-open.sb +6 -0
  221. package/dist/src/utils/sandbox-macos-restrictive-proxied.sb +6 -0
  222. package/dist/src/utils/sandbox.d.ts +2 -2
  223. package/dist/src/utils/sandbox.js +35 -11
  224. package/dist/src/utils/sandbox.js.map +1 -1
  225. package/dist/src/utils/spawnWrapper.d.ts +7 -0
  226. package/dist/src/utils/spawnWrapper.js +8 -0
  227. package/dist/src/utils/spawnWrapper.js.map +1 -0
  228. package/dist/src/utils/updateEventEmitter.d.ts +11 -0
  229. package/dist/src/utils/updateEventEmitter.js +12 -0
  230. package/dist/src/utils/updateEventEmitter.js.map +1 -0
  231. package/dist/src/validateNonInterActiveAuth.d.ts +2 -1
  232. package/dist/src/validateNonInterActiveAuth.js +31 -5
  233. package/dist/src/validateNonInterActiveAuth.js.map +1 -1
  234. package/dist/tsconfig.tsbuildinfo +1 -1
  235. package/package.json +4 -5
  236. package/dist/src/providers/enhanceConfigWithProviders.d.ts +0 -12
  237. package/dist/src/providers/enhanceConfigWithProviders.js +0 -16
  238. package/dist/src/providers/enhanceConfigWithProviders.js.map +0 -1
@@ -7,5 +7,6 @@ export var CommandKind;
7
7
  (function (CommandKind) {
8
8
  CommandKind["BUILT_IN"] = "built-in";
9
9
  CommandKind["FILE"] = "file";
10
+ CommandKind["MCP_PROMPT"] = "mcp-prompt";
10
11
  })(CommandKind || (CommandKind = {}));
11
12
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/ui/commands/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAsIH,MAAM,CAAN,IAAY,WAGX;AAHD,WAAY,WAAW;IACrB,oCAAqB,CAAA;IACrB,4BAAa,CAAA;AACf,CAAC,EAHW,WAAW,KAAX,WAAW,QAGtB"}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/ui/commands/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AA0JH,MAAM,CAAN,IAAY,WAIX;AAJD,WAAY,WAAW;IACrB,oCAAqB,CAAA;IACrB,4BAAa,CAAA;IACb,wCAAyB,CAAA;AAC3B,CAAC,EAJW,WAAW,KAAX,WAAW,QAItB"}
@@ -9,13 +9,6 @@ export const vimCommand = {
9
9
  description: 'toggle vim mode on/off',
10
10
  kind: CommandKind.BUILT_IN,
11
11
  action: async (context, _args) => {
12
- if (!context.ui.toggleVimEnabled) {
13
- return {
14
- type: 'message',
15
- messageType: 'error',
16
- content: 'Vim mode is not available in this version.',
17
- };
18
- }
19
12
  const newVimState = await context.ui.toggleVimEnabled();
20
13
  const message = newVimState
21
14
  ? 'Entered Vim mode. Run /vim again to exit.'
@@ -1 +1 @@
1
- {"version":3,"file":"vimCommand.js","sourceRoot":"","sources":["../../../../src/ui/commands/vimCommand.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,WAAW,EAAgB,MAAM,YAAY,CAAC;AAEvD,MAAM,CAAC,MAAM,UAAU,GAAiB;IACtC,IAAI,EAAE,KAAK;IACX,WAAW,EAAE,wBAAwB;IACrC,IAAI,EAAE,WAAW,CAAC,QAAQ;IAC1B,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE;QAC/B,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,gBAAgB,EAAE,CAAC;YACjC,OAAO;gBACL,IAAI,EAAE,SAAS;gBACf,WAAW,EAAE,OAAO;gBACpB,OAAO,EAAE,4CAA4C;aACtD,CAAC;QACJ,CAAC;QAED,MAAM,WAAW,GAAG,MAAM,OAAO,CAAC,EAAE,CAAC,gBAAgB,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,WAAW;YACzB,CAAC,CAAC,2CAA2C;YAC7C,CAAC,CAAC,kBAAkB,CAAC;QACvB,OAAO;YACL,IAAI,EAAE,SAAS;YACf,WAAW,EAAE,MAAM;YACnB,OAAO,EAAE,OAAO;SACjB,CAAC;IACJ,CAAC;CACF,CAAC"}
1
+ {"version":3,"file":"vimCommand.js","sourceRoot":"","sources":["../../../../src/ui/commands/vimCommand.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,WAAW,EAAgB,MAAM,YAAY,CAAC;AAEvD,MAAM,CAAC,MAAM,UAAU,GAAiB;IACtC,IAAI,EAAE,KAAK;IACX,WAAW,EAAE,wBAAwB;IACrC,IAAI,EAAE,WAAW,CAAC,QAAQ;IAC1B,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE;QAC/B,MAAM,WAAW,GAAG,MAAM,OAAO,CAAC,EAAE,CAAC,gBAAgB,EAAE,CAAC;QAExD,MAAM,OAAO,GAAG,WAAW;YACzB,CAAC,CAAC,2CAA2C;YAC7C,CAAC,CAAC,kBAAkB,CAAC;QACvB,OAAO;YACL,IAAI,EAAE,SAAS;YACf,WAAW,EAAE,MAAM;YACnB,OAAO,EAAE,OAAO;SACjB,CAAC;IACJ,CAAC;CACF,CAAC"}
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * @license
3
- * Copyright 2025 Google LLC
3
+ * Copyright 2025 Vybestack LLC
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import React from 'react';
7
- import { type OpenFiles, type MCPServerConfig } from '@vybestack/llxprt-code-core';
7
+ import { type IdeContext, type MCPServerConfig } from '@vybestack/llxprt-code-core';
8
8
  interface ContextSummaryDisplayProps {
9
9
  activeFile?: string;
10
10
  llxprtMdFileCount: number;
@@ -15,7 +15,7 @@ interface ContextSummaryDisplayProps {
15
15
  extensionName: string;
16
16
  }>;
17
17
  showToolDescriptions?: boolean;
18
- openFiles?: OpenFiles;
18
+ ideContext?: IdeContext;
19
19
  }
20
20
  export declare const ContextSummaryDisplay: React.FC<ContextSummaryDisplayProps>;
21
21
  export {};
@@ -1,21 +1,21 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { Text } from 'ink';
3
3
  import { Colors } from '../colors.js';
4
- export const ContextSummaryDisplay = ({ activeFile: _activeFile, llxprtMdFileCount, contextFileNames, mcpServers, blockedMcpServers, showToolDescriptions, openFiles, }) => {
4
+ export const ContextSummaryDisplay = ({ activeFile: _activeFile, llxprtMdFileCount, contextFileNames, mcpServers, blockedMcpServers, showToolDescriptions, ideContext, }) => {
5
5
  const mcpServerCount = Object.keys(mcpServers || {}).length;
6
6
  const blockedMcpServerCount = blockedMcpServers?.length || 0;
7
+ const openFileCount = ideContext?.workspaceState?.openFiles?.length ?? 0;
7
8
  if (llxprtMdFileCount === 0 &&
8
9
  mcpServerCount === 0 &&
9
10
  blockedMcpServerCount === 0 &&
10
- (openFiles?.recentOpenFiles?.length ?? 0) === 0) {
11
+ openFileCount === 0) {
11
12
  return _jsx(Text, { children: " " }); // Render an empty space to reserve height
12
13
  }
13
- const recentFilesText = (() => {
14
- const count = openFiles?.recentOpenFiles?.length ?? 0;
15
- if (count === 0) {
14
+ const openFilesText = (() => {
15
+ if (openFileCount === 0) {
16
16
  return '';
17
17
  }
18
- return `${count} recent file${count > 1 ? 's' : ''} (ctrl+e to view)`;
18
+ return `${openFileCount} open file${openFileCount > 1 ? 's' : ''} (ctrl+e to view)`;
19
19
  })();
20
20
  const geminiMdText = (() => {
21
21
  if (llxprtMdFileCount === 0) {
@@ -44,8 +44,8 @@ export const ContextSummaryDisplay = ({ activeFile: _activeFile, llxprtMdFileCou
44
44
  })();
45
45
  let summaryText = 'Using: ';
46
46
  const summaryParts = [];
47
- if (recentFilesText) {
48
- summaryParts.push(recentFilesText);
47
+ if (openFilesText) {
48
+ summaryParts.push(openFilesText);
49
49
  }
50
50
  if (geminiMdText) {
51
51
  summaryParts.push(geminiMdText);
@@ -1 +1 @@
1
- {"version":3,"file":"ContextSummaryDisplay.js","sourceRoot":"","sources":["../../../../src/ui/components/ContextSummaryDisplay.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAC3B,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAgBtC,MAAM,CAAC,MAAM,qBAAqB,GAAyC,CAAC,EAC1E,UAAU,EAAE,WAAW,EACvB,iBAAiB,EACjB,gBAAgB,EAChB,UAAU,EACV,iBAAiB,EACjB,oBAAoB,EACpB,SAAS,GACV,EAAE,EAAE;IACH,MAAM,cAAc,GAAG,MAAM,CAAC,IAAI,CAAC,UAAU,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC;IAC5D,MAAM,qBAAqB,GAAG,iBAAiB,EAAE,MAAM,IAAI,CAAC,CAAC;IAE7D,IACE,iBAAi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,CAAC;QAClB,YAAY,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IACnC,CAAC;IACD,IAAI,YAAY,EAAE,CAAC;QACjB,YAAY,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;IAClC,CAAC;IACD,IAAI,OAAO,EAAE,CAAC;QACZ,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC7B,CAAC;IACD,WAAW,IAAI,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAExC,iDAAiD;IACjD,IAAI,UAAU,IAAI,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACrD,IAAI,oBAAoB,EAAE,CAAC;YACzB,WAAW,IAAI,qBAAqB,CAAC;QACvC,CAAC;aAAM,CAAC;YACN,WAAW,IAAI,mBAAmB,CAAC;QACrC,CAAC;IACH,CAAC;IAED,OAAO,KAAC,IAAI,IAAC,KAAK,EAAE,MAAM,CAAC,IAAI,YAAG,WAAW,GAAQ,CAAC;AACxD,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2025 Google LLC
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ export declare const DebugProfiler: () => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,26 @@
1
+ import { jsxs as _jsxs } from "react/jsx-runtime";
2
+ /**
3
+ * @license
4
+ * Copyright 2025 Google LLC
5
+ * SPDX-License-Identifier: Apache-2.0
6
+ */
7
+ import { Text, useInput } from 'ink';
8
+ import { useEffect, useRef, useState } from 'react';
9
+ import { Colors } from '../colors.js';
10
+ export const DebugProfiler = () => {
11
+ const numRenders = useRef(0);
12
+ const [showNumRenders, setShowNumRenders] = useState(false);
13
+ useEffect(() => {
14
+ numRenders.current++;
15
+ });
16
+ useInput((input, key) => {
17
+ if (key.ctrl && input === 'b') {
18
+ setShowNumRenders((prev) => !prev);
19
+ }
20
+ });
21
+ if (!showNumRenders) {
22
+ return null;
23
+ }
24
+ return (_jsxs(Text, { color: Colors.AccentYellow, children: ["Renders: ", numRenders.current, " "] }));
25
+ };
26
+ //# sourceMappingURL=DebugProfiler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DebugProfiler.js","sourceRoot":"","sources":["../../../../src/ui/components/DebugProfiler.tsx"],"names":[],"mappings":";AAAA;;;;GAIG;AAEH,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACpD,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAEtC,MAAM,CAAC,MAAM,aAAa,GAAG,GAAG,EAAE;IAChC,MAAM,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;IAC7B,MAAM,CAAC,cAAc,EAAE,iBAAiB,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAE5D,SAAS,CAAC,GAAG,EAAE;QACb,UAAU,CAAC,OAAO,EAAE,CAAC;IACvB,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,CAAC,KAAK,EAAE,GAAG,EAAE,EAAE;QACtB,IAAI,GAAG,CAAC,IAAI,IAAI,KAAK,KAAK,GAAG,EAAE,CAAC;YAC9B,iBAAiB,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;QACrC,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,IAAI,CAAC,cAAc,EAAE,CAAC;QACpB,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,CACL,MAAC,IAAI,IAAC,KAAK,EAAE,MAAM,CAAC,YAAY,0BAAY,UAAU,CAAC,OAAO,SAAS,CACxE,CAAC;AACJ,CAAC,CAAC"}
@@ -16,6 +16,8 @@ interface FooterProps {
16
16
  promptTokenCount: number;
17
17
  isPaidMode?: boolean;
18
18
  nightly: boolean;
19
+ vimMode?: string;
20
+ contextLimit?: number;
19
21
  }
20
22
  export declare const Footer: React.FC<FooterProps>;
21
23
  export {};
@@ -1,4 +1,4 @@
1
- import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Box, Text } from 'ink';
3
3
  import { Colors } from '../colors.js';
4
4
  import { shortenPath, tildeifyPath, tokenLimit, } from '@vybestack/llxprt-code-core';
@@ -7,10 +7,11 @@ import process from 'node:process';
7
7
  import Gradient from 'ink-gradient';
8
8
  import { MemoryUsageDisplay } from './MemoryUsageDisplay.js';
9
9
  import { getProviderManager } from '../../providers/providerManagerInstance.js';
10
- export const Footer = ({ model, targetDir, branchName, debugMode, debugMessage, errorCount, showErrorDetails, showMemoryUsage, promptTokenCount, isPaidMode, nightly, }) => {
11
- const limit = tokenLimit(model);
10
+ import { DebugProfiler } from './DebugProfiler.js';
11
+ export const Footer = ({ model, targetDir, branchName, debugMode, debugMessage, errorCount, showErrorDetails, showMemoryUsage, promptTokenCount, isPaidMode, nightly, vimMode, contextLimit, }) => {
12
+ const limit = tokenLimit(model, contextLimit);
12
13
  const percentage = promptTokenCount / limit;
13
- return (_jsxs(Box, { marginTop: 1, justifyContent: "space-between", width: "100%", children: [_jsxs(Box, { children: [nightly ? (_jsx(Gradient, { colors: Colors.GradientColors, children: _jsxs(Text, { children: [shortenPath(tildeifyPath(targetDir), 70), branchName && _jsxs(Text, { children: [" (", branchName, "*)"] })] }) })) : (_jsxs(Text, { color: Colors.LightBlue, children: [shortenPath(tildeifyPath(targetDir), 70), branchName && _jsxs(Text, { color: Colors.Gray, children: [" (", branchName, "*)"] })] })), debugMode && (_jsx(Text, { color: Colors.AccentRed, children: ' ' + (debugMessage || '--debug') }))] }), _jsx(Box, { flexGrow: 1, alignItems: "center", justifyContent: "center", display: "flex", children: process.env.SANDBOX && process.env.SANDBOX !== 'sandbox-exec' ? (_jsx(Text, { color: Colors.AccentGreen, children: process.env.SANDBOX.replace(/^gemini-(?:cli-)?/, '') })) : process.env.SANDBOX === 'sandbox-exec' ? (_jsxs(Text, { color: Colors.AccentYellow, children: ["macOS Seatbelt", ' ', _jsxs(Text, { color: Colors.Gray, children: ["(", process.env.SEATBELT_PROFILE, ")"] })] })) : (_jsxs(Text, { color: Colors.AccentRed, children: ["no sandbox ", _jsx(Text, { color: Colors.Gray, children: "(see /docs)" })] })) }), _jsxs(Box, { alignItems: "center", children: [_jsxs(Text, { color: Colors.AccentBlue, children: [' ', model, ' ', _jsxs(Text, { color: Colors.Gray, children: ["(", Math.max(0, Math.round((1 - percentage) * 100)), "% context left)"] })] }), isPaidMode !== undefined &&
14
+ return (_jsxs(Box, { justifyContent: "space-between", width: "100%", children: [_jsxs(Box, { children: [debugMode && _jsx(DebugProfiler, {}), vimMode && _jsxs(Text, { color: Colors.Gray, children: ["[", vimMode, "] "] }), nightly ? (_jsx(Gradient, { colors: Colors.GradientColors, children: _jsxs(Text, { children: [shortenPath(tildeifyPath(targetDir), 70), branchName && _jsxs(Text, { children: [" (", branchName, "*)"] })] }) })) : (_jsxs(Text, { color: Colors.LightBlue, children: [shortenPath(tildeifyPath(targetDir), 70), branchName && _jsxs(Text, { color: Colors.Gray, children: [" (", branchName, "*)"] })] })), debugMode && (_jsx(Text, { color: Colors.AccentRed, children: ' ' + (debugMessage || '--debug') }))] }), _jsx(Box, { flexGrow: 1, alignItems: "center", justifyContent: "center", display: "flex", children: process.env.SANDBOX && process.env.SANDBOX !== 'sandbox-exec' ? (_jsx(Text, { color: Colors.AccentGreen, children: process.env.SANDBOX.replace(/^gemini-(?:cli-)?/, '') })) : process.env.SANDBOX === 'sandbox-exec' ? (_jsxs(Text, { color: Colors.AccentYellow, children: ["macOS Seatbelt", ' ', _jsxs(Text, { color: Colors.Gray, children: ["(", process.env.SEATBELT_PROFILE, ")"] })] })) : (_jsxs(Text, { color: Colors.AccentRed, children: ["no sandbox ", _jsx(Text, { color: Colors.Gray, children: "(see /docs)" })] })) }), _jsxs(Box, { alignItems: "center", children: [_jsxs(Text, { color: Colors.AccentBlue, children: [' ', model, ' ', _jsxs(Text, { color: Colors.Gray, children: ["(", Math.max(0, Math.round((1 - percentage) * 100)), "% context left)"] })] }), isPaidMode !== undefined &&
14
15
  (() => {
15
16
  const providerManager = getProviderManager();
16
17
  const activeProvider = providerManager?.getActiveProvider?.();
@@ -1 +1 @@
1
- {"version":3,"file":"Footer.js","sourceRoot":"","sources":["../../../../src/ui/components/Footer.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EACL,WAAW,EACX,YAAY,EACZ,UAAU,GACX,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,OAAO,MAAM,cAAc,CAAC;AACnC,OAAO,QAAQ,MAAM,cAAc,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,4CAA4C,CAAC;AAgBhF,MAAM,CAAC,MAAM,MAAM,GAA0B,CAAC,EAC5C,KAAK,EACL,SAAS,EACT,UAAU,EACV,SAAS,EACT,YAAY,EACZ,UAAU,EACV,gBAAgB,EAChB,eAAe,EACf,gBAAgB,EAChB,UAAU,EACV,OAAO,GACR,EAAE,EAAE;IACH,MAAM,KAAK,GAAG,UAAU,CAAC,KAAK,CAAC,CAAC;IAChC,MAAM,UAAU,GAAG,gBAAgB,GAAG,KAAK,CAAC;IAE5C,OAAO,CACL,MAAC,GAAG,IAAC,SAAS,EAAE,CAAC,EAAE,cAAc,EAAC,eAAe,EAAC,KAAK,EAAC,MAAM,aAC5D,MAAC,GAAG,eACD,OAAO,CAAC,CAAC,CAAC,CACT,KAAC,QAAQ,IAAC,MAAM,EAAE,MAAM,CAA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;AACJ,CAAC,CAAC"}
@@ -15,6 +15,6 @@ export const Header = ({ customAsciiArt, terminalWidth, version, nightly, }) =>
15
15
  terminalWidth >= widthOfLongLogo ? longAsciiLogo : shortAsciiLogo;
16
16
  }
17
17
  const artWidth = getAsciiArtWidth(displayTitle);
18
- return (_jsxs(Box, { marginBottom: 1, alignItems: "flex-start", width: artWidth, flexShrink: 0, flexDirection: "column", children: [Colors.GradientColors ? (_jsx(Gradient, { colors: Colors.GradientColors, children: _jsx(Text, { children: displayTitle }) })) : (_jsx(Text, { children: displayTitle })), nightly && (_jsx(Box, { width: "100%", flexDirection: "row", justifyContent: "flex-end", children: _jsx(Gradient, { colors: Colors.GradientColors, children: _jsxs(Text, { children: ["v", version] }) }) }))] }));
18
+ return (_jsxs(Box, { alignItems: "flex-start", width: artWidth, flexShrink: 0, flexDirection: "column", children: [Colors.GradientColors ? (_jsx(Gradient, { colors: Colors.GradientColors, children: _jsx(Text, { children: displayTitle }) })) : (_jsx(Text, { children: displayTitle })), nightly && (_jsx(Box, { width: "100%", flexDirection: "row", justifyContent: "flex-end", children: _jsx(Gradient, { colors: Colors.GradientColors, children: _jsxs(Text, { children: ["v", version] }) }) }))] }));
19
19
  };
20
20
  //# sourceMappingURL=Header.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Header.js","sourceRoot":"","sources":["../../../../src/ui/components/Header.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChC,OAAO,QAAQ,MAAM,cAAc,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AASzD,MAAM,CAAC,MAAM,MAAM,GAA0B,CAAC,EAC5C,cAAc,EACd,aAAa,EACb,OAAO,EACP,OAAO,GACR,EAAE,EAAE;I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B,EAAE,MAAM,uBAAuB,CAAC;AASzD,MAAM,CAAC,MAAM,MAAM,GAA0B,CAAC,EAC5C,cAAc,EACd,aAAa,EACb,OAAO,EACP,OAAO,GACR,EAAE,EAAE;IACH,IAAI,YAAY,CAAC;IACjB,MAAM,eAAe,GAAG,gBAAgB,CAAC,aAAa,CAAC,CAAC;IAExD,IAAI,cAAc,EAAE,CAAC;QACnB,YAAY,GAAG,cAAc,CAAC;IAChC,CAAC;SAAM,CAAC;QACN,YAAY;YACV,aAAa,IAAI,eAAe,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,cAAc,CAAC;IACtE,CAAC;IAED,MAAM,QAAQ,GAAG,gBAAgB,CAAC,YAAY,CAAC,CAAC;IAEhD,OAAO,CACL,MAAC,GAAG,IACF,UAAU,EAAC,YAAY,EACvB,KAAK,EAAE,QAAQ,EACf,UAAU,EAAE,CAAC,EACb,aAAa,EAAC,QAAQ,aAErB,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC,CACvB,KAAC,QAAQ,IAAC,MAAM,EAAE,MAAM,CAAC,cAAc,YACrC,KAAC,IAAI,cAAE,YAAY,GAAQ,GAClB,CACZ,CAAC,CAAC,CAAC,CACF,KAAC,IAAI,cAAE,YAAY,GAAQ,CAC5B,EACA,OAAO,IAAI,CACV,KAAC,GAAG,IAAC,KAAK,EAAC,MAAM,EAAC,aAAa,EAAC,KAAK,EAAC,cAAc,EAAC,UAAU,YAC7D,KAAC,QAAQ,IAAC,MAAM,EAAE,MAAM,CAAC,cAAc,YACrC,MAAC,IAAI,oBAAG,OAAO,IAAQ,GACd,GACP,CACP,IACG,CACP,CAAC;AACJ,CAAC,CAAC"}
@@ -4,7 +4,7 @@ import { Colors } from '../colors.js';
4
4
  export const Help = ({ commands }) => (_jsxs(Box, { flexDirection: "column", marginBottom: 1, borderColor: Colors.Gray, borderStyle: "round", padding: 1, children: [_jsx(Text, { bold: true, color: Colors.Foreground, children: "Basics:" }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Add context" }), ": Use", ' ', _jsx(Text, { bold: true, color: Colors.AccentPurple, children: "@" }), ' ', "to specify files for context (e.g.,", ' ', _jsx(Text, { bold: true, color: Colors.AccentPurple, children: "@src/myFile.ts" }), ") to target specific files or folders."] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Shell mode" }), ": Execute shell commands via", ' ', _jsx(Text, { bold: true, color: Colors.AccentPurple, children: "!" }), ' ', "(e.g.,", ' ', _jsx(Text, { bold: true, color: Colors.AccentPurple, children: "!npm run start" }), ") or use natural language (e.g.", ' ', _jsx(Text, { bold: true, color: Colors.AccentPurple, children: "start server" }), ")."] }), _jsx(Box, { height: 1 }), _jsx(Text, { bold: true, color: Colors.Foreground, children: "Commands:" }), commands
5
5
  .filter((command) => command.description)
6
6
  .map((command) => (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Text, { color: Colors.Foreground, children: [_jsxs(Text, { bold: true, color: Colors.AccentPurple, children: [' ', "/", command.name] }), command.description && ' - ' + command.description] }), command.subCommands &&
7
- command.subCommands.map((subCommand) => (_jsxs(Text, { color: Colors.Foreground, children: [_jsxs(Text, { bold: true, color: Colors.AccentPurple, children: [' ', subCommand.name] }), subCommand.description && ' - ' + subCommand.description] }, subCommand.name)))] }, command.name))), _jsxs(Text, { color: Colors.Foreground, children: [_jsxs(Text, { bold: true, color: Colors.AccentPurple, children: [' ', "!", ' '] }), "- shell command"] }), _jsx(Box, { height: 1 }), _jsx(Text, { bold: true, color: Colors.Foreground, children: "Keyboard Shortcuts:" }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Enter" }), ' ', "- Send message"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: process.platform === 'win32' ? 'Ctrl+Enter' : 'Ctrl+J' }), ' ', process.platform === 'linux'
7
+ command.subCommands.map((subCommand) => (_jsxs(Text, { color: Colors.Foreground, children: [_jsxs(Text, { bold: true, color: Colors.AccentPurple, children: [' ', subCommand.name] }), subCommand.description && ' - ' + subCommand.description] }, subCommand.name)))] }, command.name))), _jsxs(Text, { color: Colors.Foreground, children: [_jsxs(Text, { bold: true, color: Colors.AccentPurple, children: [' ', "!", ' '] }), "- shell command"] }), _jsx(Box, { height: 1 }), _jsx(Text, { bold: true, color: Colors.Foreground, children: "Keyboard Shortcuts:" }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Alt+Left/Right" }), ' ', "- Jump through words in the input"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Ctrl+C" }), ' ', "- Quit application"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: process.platform === 'win32' ? 'Ctrl+Enter' : 'Ctrl+J' }), ' ', process.platform === 'linux'
8
8
  ? '- New line (Alt+Enter works for certain linux distros)'
9
- : '- New line'] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Up/Down" }), ' ', "- Cycle through your prompt history"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Alt+Left/Right" }), ' ', "- Jump through words in the input"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Shift+Tab" }), ' ', "- Toggle auto-accepting edits"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Ctrl+Y" }), ' ', "- Toggle YOLO mode"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Esc" }), ' ', "- Cancel operation"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Ctrl+C" }), ' ', "- Quit application"] })] }));
9
+ : '- New line'] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Ctrl+L" }), ' ', "- Clear the screen"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: process.platform === 'darwin' ? 'Ctrl+X / Meta+Enter' : 'Ctrl+X' }), ' ', "- Open input in external editor"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Ctrl+Y" }), ' ', "- Toggle YOLO mode"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Enter" }), ' ', "- Send message"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Esc" }), ' ', "- Cancel operation"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Shift+Tab" }), ' ', "- Toggle auto-accepting edits"] }), _jsxs(Text, { color: Colors.Foreground, children: [_jsx(Text, { bold: true, color: Colors.AccentPurple, children: "Up/Down" }), ' ', "- Cycle through your prompt history"] }), _jsx(Box, { height: 1 }), _jsxs(Text, { color: Colors.Foreground, children: ["For a full list of shortcuts, see", ' ', _jsx(Text, { bold: true, color: Colors.AccentPurple, children: "docs/keyboard-shortcuts.md" })] })] }));
10
10
  //# sourceMappingURL=Help.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Help.js","sourceRoot":"","sources":["../../../../src/ui/components/Help.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAOtC,MAAM,CAAC,MAAM,IAAI,GAAmB,CAAC,EAAE,QAAQ,EAAE,EAAE,EAAE,CAAC,CACpD,MAAC,GAA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G,0BAEN,EACP,MAAC,IAAI,IAAC,KAAK,EAAE,MAAM,CAAC,UAAU,aAC5B,KAAC,IAAI,IAAC,IAAI,QAAC,KAAK,EAAE,MAAM,CAAC,YAAY,0BAE9B,EAAC,GAAG,qCAEN,EACP,MAAC,IAAI,IAAC,KAAK,EAAE,MAAM,CAAC,UAAU,aAC5B,KAAC,IAAI,IAAC,IAAI,QAAC,KAAK,EAAE,MAAM,CAAC,YAAY,wBAE9B,EAAC,GAAG,2CAEN,EACP,KAAC,GAAG,IAAC,MAAM,EAAE,CAAC,GAAI,EAClB,MAAC,IAAI,IAAC,KAAK,EAAE,MAAM,CAAC,UAAU,kDACM,GAAG,EACrC,KAAC,IAAI,IAAC,IAAI,QAAC,KAAK,EAAE,MAAM,CAAC,YAAY,2CAE9B,IACF,IACH,CACP,CAAC"}
@@ -1,11 +1,12 @@
1
1
  /**
2
2
  * @license
3
- * Copyright 2025 Google LLC
3
+ * Copyright 2025 Vybestack LLC
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
- import { type OpenFiles } from '@vybestack/llxprt-code-core';
6
+ import { type IdeContext } from '@vybestack/llxprt-code-core';
7
7
  interface IDEContextDetailDisplayProps {
8
- openFiles: OpenFiles | undefined;
8
+ ideContext: IdeContext | undefined;
9
+ detectedIdeDisplay: string | undefined;
9
10
  }
10
- export declare function IDEContextDetailDisplay({ openFiles, }: IDEContextDetailDisplayProps): import("react/jsx-runtime").JSX.Element | null;
11
+ export declare function IDEContextDetailDisplay({ ideContext, detectedIdeDisplay, }: IDEContextDetailDisplayProps): import("react/jsx-runtime").JSX.Element | null;
11
12
  export {};
@@ -1,19 +1,17 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
2
2
  /**
3
3
  * @license
4
- * Copyright 2025 Google LLC
4
+ * Copyright 2025 Vybestack LLC
5
5
  * SPDX-License-Identifier: Apache-2.0
6
6
  */
7
7
  import { Box, Text } from 'ink';
8
8
  import { Colors } from '../colors.js';
9
9
  import path from 'node:path';
10
- export function IDEContextDetailDisplay({ openFiles, }) {
11
- if (!openFiles ||
12
- !openFiles.recentOpenFiles ||
13
- openFiles.recentOpenFiles.length === 0) {
10
+ export function IDEContextDetailDisplay({ ideContext, detectedIdeDisplay, }) {
11
+ const openFiles = ideContext?.workspaceState?.openFiles;
12
+ if (!openFiles || openFiles.length === 0) {
14
13
  return null;
15
14
  }
16
- const recentFiles = openFiles.recentOpenFiles || [];
17
- return (_jsxs(Box, { flexDirection: "column", marginTop: 1, borderStyle: "round", borderColor: Colors.AccentCyan, paddingX: 1, children: [_jsx(Text, { color: Colors.AccentCyan, bold: true, children: "IDE Context (ctrl+e to toggle)" }), recentFiles.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsx(Text, { bold: true, children: "Recent files:" }), recentFiles.map((file) => (_jsxs(Text, { children: ["- ", path.basename(file.filePath || ''), file.filePath === openFiles.activeFile ? ' (active)' : ''] }, file.filePath)))] }))] }));
15
+ return (_jsxs(Box, { flexDirection: "column", marginTop: 1, borderStyle: "round", borderColor: Colors.AccentCyan, paddingX: 1, children: [_jsxs(Text, { color: Colors.AccentCyan, bold: true, children: [detectedIdeDisplay ? detectedIdeDisplay : 'IDE', " Context (ctrl+e to toggle)"] }), openFiles.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsx(Text, { bold: true, children: "Open files:" }), openFiles.map((file) => (_jsxs(Text, { children: ["- ", path.basename(file.path), file.isActive ? ' (active)' : ''] }, file.path)))] }))] }));
18
16
  }
19
17
  //# sourceMappingURL=IDEContextDetailDisplay.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"IDEContextDetailDisplay.js","sourceRoot":"","sources":["../../../../src/ui/components/IDEContextDetailDisplay.tsx"],"names":[],"mappings":";AAAA;;;;GAIG;AAEH,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC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AC;AAEhC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,IAAI,MAAM,WAAW,CAAC;AAO7B,MAAM,UAAU,uBAAuB,CAAC,EACtC,UAAU,EACV,kBAAkB,GACW;IAC7B,MAAM,SAAS,GAAG,UAAU,EAAE,cAAc,EAAE,SAAS,CAAC;IACxD,IAAI,CAAC,SAAS,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACzC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,CACL,MAAC,GAAG,IACF,aAAa,EAAC,QAAQ,EACtB,SAAS,EAAE,CAAC,EACZ,WAAW,EAAC,OAAO,EACnB,WAAW,EAAE,MAAM,CAAC,UAAU,EAC9B,QAAQ,EAAE,CAAC,aAEX,MAAC,IAAI,IAAC,KAAK,EAAE,MAAM,CAAC,UAAU,EAAE,IAAI,mBACjC,kBAAkB,CAAC,CAAC,CAAC,kBAAkB,CAAC,CAAC,CAAC,KAAK,mCAE3C,EACN,SAAS,CAAC,MAAM,GAAG,CAAC,IAAI,CACvB,MAAC,GAAG,IAAC,aAAa,EAAC,QAAQ,EAAC,SAAS,EAAE,CAAC,aACtC,KAAC,IAAI,IAAC,IAAI,kCAAmB,EAC5B,SAAS,CAAC,GAAG,CAAC,CAAC,IAAU,EAAE,EAAE,CAAC,CAC7B,MAAC,IAAI,qBACA,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,EAC1B,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,KAFxB,IAAI,CAAC,IAAI,CAGb,CACR,CAAC,IACE,CACP,IACG,CACP,CAAC;AACJ,CAAC"}
@@ -5,6 +5,7 @@
5
5
  */
6
6
  import React from 'react';
7
7
  import { TextBuffer } from './shared/text-buffer.js';
8
+ import { Key } from '../hooks/useKeypress.js';
8
9
  import { CommandContext, SlashCommand } from '../commands/types.js';
9
10
  import { Config } from '@vybestack/llxprt-code-core';
10
11
  export interface InputPromptProps {
@@ -21,5 +22,6 @@ export interface InputPromptProps {
21
22
  suggestionsWidth: number;
22
23
  shellModeActive: boolean;
23
24
  setShellModeActive: (value: boolean) => void;
25
+ vimHandleInput?: (key: Key) => boolean;
24
26
  }
25
27
  export declare const InputPrompt: React.FC<InputPromptProps>;
@@ -4,39 +4,76 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
4
4
  * Copyright 2025 Google LLC
5
5
  * SPDX-License-Identifier: Apache-2.0
6
6
  */
7
- import { useCallback, useEffect, useState } from 'react';
7
+ import { useCallback, useEffect, useState, useMemo } from 'react';
8
8
  import { Box, Text } from 'ink';
9
9
  import { Colors } from '../colors.js';
10
10
  import { SuggestionsDisplay } from './SuggestionsDisplay.js';
11
11
  import { useInputHistory } from '../hooks/useInputHistory.js';
12
+ import { logicalPosToOffset } from './shared/text-buffer.js';
12
13
  import { cpSlice, cpLen } from '../utils/textUtils.js';
13
14
  import chalk from 'chalk';
14
15
  import stringWidth from 'string-width';
15
16
  import { useShellHistory } from '../hooks/useShellHistory.js';
16
- import { useCompletion } from '../hooks/useCompletion.js';
17
+ import { useReverseSearchCompletion } from '../hooks/useReverseSearchCompletion.js';
18
+ import { useSlashCompletion } from '../hooks/useSlashCompletion.js';
17
19
  import { useKeypress } from '../hooks/useKeypress.js';
18
20
  import { clipboardHasImage, saveClipboardImage, cleanupOldClipboardImages, } from '../utils/clipboardUtils.js';
19
21
  import * as path from 'path';
20
- export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, config, slashCommands, commandContext, placeholder = ' Type your message or @path/to/file', focus = true, inputWidth, suggestionsWidth, shellModeActive, setShellModeActive, }) => {
22
+ import { secureInputHandler } from '../utils/secureInputHandler.js';
23
+ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, config, slashCommands, commandContext, placeholder = ' Type your message or @path/to/file', focus = true, inputWidth, suggestionsWidth, shellModeActive, setShellModeActive, vimHandleInput, }) => {
21
24
  const [justNavigatedHistory, setJustNavigatedHistory] = useState(false);
22
25
  const [pasteMessage, setPasteMessage] = useState(null);
23
- const completion = useCompletion(buffer, config.getTargetDir(), slashCommands, commandContext, config);
24
- const resetCompletionState = completion.resetCompletionState;
26
+ const [dirs, setDirs] = useState(config.getWorkspaceContext().getDirectories());
27
+ const dirsChanged = config.getWorkspaceContext().getDirectories();
28
+ useEffect(() => {
29
+ if (dirs.length !== dirsChanged.length) {
30
+ setDirs(dirsChanged);
31
+ }
32
+ }, [dirs.length, dirsChanged]);
33
+ const [reverseSearchActive, setReverseSearchActive] = useState(false);
34
+ const [textBeforeReverseSearch, setTextBeforeReverseSearch] = useState('');
35
+ const [cursorPosition, setCursorPosition] = useState([
36
+ 0, 0,
37
+ ]);
25
38
  const shellHistory = useShellHistory(config.getProjectRoot());
39
+ const historyData = shellHistory.history;
40
+ const completion = useSlashCompletion(buffer, dirs, config.getTargetDir(), slashCommands, commandContext, reverseSearchActive, config);
41
+ const reverseSearchCompletion = useReverseSearchCompletion(buffer, historyData, reverseSearchActive);
42
+ const resetCompletionState = completion.resetCompletionState;
43
+ const resetReverseSearchCompletionState = reverseSearchCompletion.resetCompletionState;
26
44
  const handleSubmitAndClear = useCallback((submittedValue) => {
45
+ // Get the actual value if in secure mode
46
+ const actualValue = secureInputHandler.isInSecureMode()
47
+ ? secureInputHandler.getActualValue()
48
+ : submittedValue;
27
49
  if (shellModeActive) {
28
- shellHistory.addCommandToHistory(submittedValue);
50
+ // Sanitize for history if it's a secure command
51
+ const historyValue = secureInputHandler.sanitizeForHistory(actualValue);
52
+ shellHistory.addCommandToHistory(historyValue);
29
53
  }
30
54
  // Clear the buffer *before* calling onSubmit to prevent potential re-submission
31
55
  // if onSubmit triggers a re-render while the buffer still holds the old value.
32
56
  buffer.setText('');
33
- onSubmit(submittedValue);
57
+ // Reset secure input handler
58
+ secureInputHandler.reset();
59
+ onSubmit(actualValue);
34
60
  resetCompletionState();
35
61
  setPasteMessage(null);
36
- }, [onSubmit, buffer, resetCompletionState, shellModeActive, shellHistory]);
62
+ resetReverseSearchCompletionState();
63
+ }, [
64
+ onSubmit,
65
+ buffer,
66
+ resetCompletionState,
67
+ shellModeActive,
68
+ shellHistory,
69
+ resetReverseSearchCompletionState,
70
+ setPasteMessage,
71
+ ]);
37
72
  const customSetTextAndResetCompletionSignal = useCallback((newText) => {
38
73
  buffer.setText(newText);
39
74
  setJustNavigatedHistory(true);
75
+ // Process through secure handler to update its state
76
+ secureInputHandler.processInput(newText);
40
77
  }, [buffer, setJustNavigatedHistory]);
41
78
  const inputHistory = useInputHistory({
42
79
  userMessages,
@@ -50,6 +87,7 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
50
87
  useEffect(() => {
51
88
  if (justNavigatedHistory) {
52
89
  resetCompletionState();
90
+ resetReverseSearchCompletionState();
53
91
  setJustNavigatedHistory(false);
54
92
  }
55
93
  }, [
@@ -57,6 +95,7 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
57
95
  buffer.text,
58
96
  resetCompletionState,
59
97
  setJustNavigatedHistory,
98
+ resetReverseSearchCompletionState,
60
99
  ]);
61
100
  // Handle clipboard image pasting with Ctrl+V
62
101
  const handleClipboardImage = useCallback(async () => {
@@ -104,6 +143,9 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
104
143
  if (!focus && !key.paste) {
105
144
  return;
106
145
  }
146
+ if (vimHandleInput && vimHandleInput(key)) {
147
+ return;
148
+ }
107
149
  if (key.sequence === '!' &&
108
150
  buffer.text === '' &&
109
151
  !completion.showSuggestions) {
@@ -112,6 +154,14 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
112
154
  return;
113
155
  }
114
156
  if (key.name === 'escape') {
157
+ if (reverseSearchActive) {
158
+ setReverseSearchActive(false);
159
+ reverseSearchCompletion.resetCompletionState();
160
+ buffer.setText(textBeforeReverseSearch);
161
+ const offset = logicalPosToOffset(buffer.lines, cursorPosition[0], cursorPosition[1]);
162
+ buffer.moveToOffset(offset);
163
+ return;
164
+ }
115
165
  if (shellModeActive) {
116
166
  setShellModeActive(false);
117
167
  return;
@@ -121,10 +171,48 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
121
171
  return;
122
172
  }
123
173
  }
174
+ if (shellModeActive && key.ctrl && key.name === 'r') {
175
+ setReverseSearchActive(true);
176
+ setTextBeforeReverseSearch(buffer.text);
177
+ setCursorPosition(buffer.cursor);
178
+ return;
179
+ }
124
180
  if (key.ctrl && key.name === 'l') {
125
181
  onClearScreen();
126
182
  return;
127
183
  }
184
+ if (reverseSearchActive) {
185
+ const { activeSuggestionIndex, navigateUp, navigateDown, showSuggestions, suggestions, } = reverseSearchCompletion;
186
+ if (showSuggestions) {
187
+ if (key.name === 'up') {
188
+ navigateUp();
189
+ return;
190
+ }
191
+ if (key.name === 'down') {
192
+ navigateDown();
193
+ return;
194
+ }
195
+ if (key.name === 'tab') {
196
+ reverseSearchCompletion.handleAutocomplete(activeSuggestionIndex);
197
+ reverseSearchCompletion.resetCompletionState();
198
+ setReverseSearchActive(false);
199
+ return;
200
+ }
201
+ }
202
+ if (key.name === 'return' && !key.ctrl) {
203
+ const textToSubmit = showSuggestions && activeSuggestionIndex > -1
204
+ ? suggestions[activeSuggestionIndex].value
205
+ : buffer.text;
206
+ handleSubmitAndClear(textToSubmit);
207
+ reverseSearchCompletion.resetCompletionState();
208
+ setReverseSearchActive(false);
209
+ return;
210
+ }
211
+ // Prevent up/down from falling through to regular history navigation
212
+ if (key.name === 'up' || key.name === 'down') {
213
+ return;
214
+ }
215
+ }
128
216
  // If the command is a perfect match, pressing enter should execute it.
129
217
  if (completion.isPerfectMatch && key.name === 'return') {
130
218
  handleSubmitAndClear(buffer.text);
@@ -177,7 +265,6 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
177
265
  }
178
266
  }
179
267
  else {
180
- // Shell History Navigation
181
268
  if (key.name === 'up') {
182
269
  const prevCommand = shellHistory.getPreviousCommand();
183
270
  if (prevCommand !== null)
@@ -226,6 +313,7 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
226
313
  if (buffer.text.length > 0) {
227
314
  buffer.setText('');
228
315
  resetCompletionState();
316
+ secureInputHandler.reset();
229
317
  return;
230
318
  }
231
319
  return;
@@ -258,10 +346,16 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
258
346
  }
259
347
  // Insert the paste content at cursor position
260
348
  buffer.insert(key.sequence);
349
+ // Update secure input handler state after paste
350
+ // This ensures the handler knows about the pasted content
351
+ secureInputHandler.processInput(buffer.text);
261
352
  return;
262
353
  }
263
354
  // Fall back to the text buffer's default input handling for all other keys
264
355
  buffer.handleInput(key);
356
+ // Update secure input handler state after any input
357
+ // This ensures the handler always has the current text
358
+ secureInputHandler.processInput(buffer.text);
265
359
  }, [
266
360
  focus,
267
361
  buffer,
@@ -272,19 +366,40 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
272
366
  inputHistory,
273
367
  handleSubmitAndClear,
274
368
  shellHistory,
369
+ reverseSearchCompletion,
275
370
  handleClipboardImage,
276
371
  resetCompletionState,
372
+ vimHandleInput,
373
+ reverseSearchActive,
374
+ textBeforeReverseSearch,
375
+ cursorPosition,
277
376
  ]);
278
377
  useKeypress(handleInput, { isActive: true });
279
- const linesToRender = buffer.viewportVisualLines;
378
+ // Process buffer text through secure input handler
379
+ // This will return masked text if it detects /key command, otherwise returns original text
380
+ const textToDisplay = useMemo(() => secureInputHandler.processInput(buffer.text), [buffer.text]);
381
+ // Calculate visual lines for the display text
382
+ const displayLines = useMemo(() => {
383
+ if (!secureInputHandler.isInSecureMode()) {
384
+ return buffer.viewportVisualLines;
385
+ }
386
+ // In secure mode, simply return the masked text as a single line
387
+ // The issue is that buffer.viewportVisualLines are calculated from buffer.text
388
+ // but we need to display textToDisplay instead
389
+ // For now, let's just return the masked text as a single visual line
390
+ // This works for single-line inputs (which is the common case for API keys)
391
+ return [textToDisplay];
392
+ }, [buffer.viewportVisualLines, textToDisplay]);
393
+ const linesToRender = displayLines;
280
394
  const [cursorVisualRowAbsolute, cursorVisualColAbsolute] = buffer.visualCursor;
281
395
  const scrollVisualRow = buffer.visualScrollRow;
282
- return (_jsxs(_Fragment, { children: [_jsxs(Box, { borderStyle: "round", borderColor: shellModeActive ? Colors.AccentYellow : Colors.AccentBlue, paddingX: 1, children: [_jsx(Text, { color: shellModeActive ? Colors.AccentYellow : Colors.AccentPurple, children: shellModeActive ? '! ' : '> ' }), _jsx(Box, { flexGrow: 1, flexDirection: "column", children: buffer.text.length === 0 && placeholder ? (focus ? (_jsxs(Text, { children: [chalk.inverse(placeholder.slice(0, 1)), _jsx(Text, { color: Colors.Gray, children: placeholder.slice(1) })] })) : (_jsx(Text, { color: Colors.Gray, children: placeholder }))) : (linesToRender.map((lineText, visualIdxInRenderedSet) => {
396
+ return (_jsxs(_Fragment, { children: [_jsxs(Box, { borderStyle: "round", borderColor: shellModeActive ? Colors.AccentYellow : Colors.AccentBlue, paddingX: 1, children: [_jsx(Text, { color: shellModeActive ? Colors.AccentYellow : Colors.AccentPurple, children: shellModeActive ? (reverseSearchActive ? (_jsx(Text, { color: Colors.AccentCyan, children: "(r:) " })) : ('! ')) : ('> ') }), _jsx(Box, { flexGrow: 1, flexDirection: "column", children: textToDisplay.length === 0 && placeholder ? (focus ? (_jsxs(Text, { children: [chalk.inverse(placeholder.slice(0, 1)), _jsx(Text, { color: Colors.Gray, children: placeholder.slice(1) })] })) : (_jsx(Text, { color: Colors.Gray, children: placeholder }))) : (linesToRender.map((lineText, visualIdxInRenderedSet) => {
283
397
  const cursorVisualRow = cursorVisualRowAbsolute - scrollVisualRow;
284
398
  let display = cpSlice(lineText, 0, inputWidth);
285
399
  const currentVisualWidth = stringWidth(display);
286
400
  if (currentVisualWidth < inputWidth) {
287
- display = display + ' '.repeat(inputWidth - currentVisualWidth);
401
+ display =
402
+ display + ' '.repeat(inputWidth - currentVisualWidth);
288
403
  }
289
404
  if (focus && visualIdxInRenderedSet === cursorVisualRow) {
290
405
  const relativeVisualColForHighlight = cursorVisualColAbsolute;
@@ -304,6 +419,6 @@ export const InputPrompt = ({ buffer, onSubmit, userMessages, onClearScreen, con
304
419
  }
305
420
  }
306
421
  return (_jsx(Text, { color: Colors.Foreground, children: display }, `line-${visualIdxInRenderedSet}`));
307
- })) })] }), completion.showSuggestions && (_jsx(Box, { children: _jsx(SuggestionsDisplay, { suggestions: completion.suggestions, activeIndex: completion.activeSuggestionIndex, isLoading: completion.isLoadingSuggestions, width: suggestionsWidth, scrollOffset: completion.visibleStartIndex, userInput: buffer.text }) })), pasteMessage && (_jsx(Box, { marginTop: 1, children: _jsx(Text, { color: Colors.Comment, children: pasteMessage }) }))] }));
422
+ })) })] }), completion.showSuggestions && (_jsx(Box, { children: _jsx(SuggestionsDisplay, { suggestions: completion.suggestions, activeIndex: completion.activeSuggestionIndex, isLoading: completion.isLoadingSuggestions, width: suggestionsWidth, scrollOffset: completion.visibleStartIndex, userInput: textToDisplay }) })), pasteMessage && (_jsx(Box, { marginTop: 1, children: _jsx(Text, { color: Colors.Comment, children: pasteMessage }) })), reverseSearchActive && (_jsx(Box, { children: _jsx(SuggestionsDisplay, { suggestions: reverseSearchCompletion.suggestions, activeIndex: reverseSearchCompletion.activeSuggestionIndex, isLoading: reverseSearchCompletion.isLoadingSuggestions, width: suggestionsWidth, scrollOffset: reverseSearchCompletion.visibleStartIndex, userInput: buffer.text }) }))] }));
308
423
  };
309
424
  //# sourceMappingURL=InputPrompt.js.map