snow-ai 0.4.16 → 0.4.17

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 (351) hide show
  1. package/bundle/cli.mjs +477445 -0
  2. package/bundle/sql-wasm.wasm +0 -0
  3. package/package.json +31 -26
  4. package/dist/agents/codebaseIndexAgent.d.ts +0 -102
  5. package/dist/agents/codebaseIndexAgent.js +0 -641
  6. package/dist/agents/codebaseReviewAgent.d.ts +0 -61
  7. package/dist/agents/codebaseReviewAgent.js +0 -301
  8. package/dist/agents/compactAgent.d.ts +0 -55
  9. package/dist/agents/compactAgent.js +0 -306
  10. package/dist/agents/promptOptimizeAgent.d.ts +0 -54
  11. package/dist/agents/promptOptimizeAgent.js +0 -268
  12. package/dist/agents/reviewAgent.d.ts +0 -50
  13. package/dist/agents/reviewAgent.js +0 -265
  14. package/dist/agents/summaryAgent.d.ts +0 -57
  15. package/dist/agents/summaryAgent.js +0 -260
  16. package/dist/api/anthropic.d.ts +0 -44
  17. package/dist/api/anthropic.js +0 -598
  18. package/dist/api/chat.d.ts +0 -73
  19. package/dist/api/chat.js +0 -386
  20. package/dist/api/embedding.d.ts +0 -34
  21. package/dist/api/embedding.js +0 -80
  22. package/dist/api/gemini.d.ts +0 -31
  23. package/dist/api/gemini.js +0 -445
  24. package/dist/api/models.d.ts +0 -15
  25. package/dist/api/models.js +0 -139
  26. package/dist/api/responses.d.ts +0 -38
  27. package/dist/api/responses.js +0 -515
  28. package/dist/api/systemPrompt.d.ts +0 -4
  29. package/dist/api/systemPrompt.js +0 -408
  30. package/dist/api/types.d.ts +0 -53
  31. package/dist/api/types.js +0 -4
  32. package/dist/app.d.ts +0 -8
  33. package/dist/app.js +0 -112
  34. package/dist/cli.d.ts +0 -2
  35. package/dist/cli.js +0 -199
  36. package/dist/hooks/useAgentPicker.d.ts +0 -14
  37. package/dist/hooks/useAgentPicker.js +0 -119
  38. package/dist/hooks/useClipboard.d.ts +0 -4
  39. package/dist/hooks/useClipboard.js +0 -175
  40. package/dist/hooks/useCommandHandler.d.ts +0 -35
  41. package/dist/hooks/useCommandHandler.js +0 -346
  42. package/dist/hooks/useCommandPanel.d.ts +0 -17
  43. package/dist/hooks/useCommandPanel.js +0 -114
  44. package/dist/hooks/useConversation.d.ts +0 -49
  45. package/dist/hooks/useConversation.js +0 -1052
  46. package/dist/hooks/useFilePicker.d.ts +0 -18
  47. package/dist/hooks/useFilePicker.js +0 -224
  48. package/dist/hooks/useGlobalExit.d.ts +0 -5
  49. package/dist/hooks/useGlobalExit.js +0 -34
  50. package/dist/hooks/useGlobalNavigation.d.ts +0 -6
  51. package/dist/hooks/useGlobalNavigation.js +0 -17
  52. package/dist/hooks/useHistoryNavigation.d.ts +0 -35
  53. package/dist/hooks/useHistoryNavigation.js +0 -133
  54. package/dist/hooks/useInputBuffer.d.ts +0 -6
  55. package/dist/hooks/useInputBuffer.js +0 -45
  56. package/dist/hooks/useKeyboardInput.d.ts +0 -80
  57. package/dist/hooks/useKeyboardInput.js +0 -608
  58. package/dist/hooks/useSessionManagement.d.ts +0 -10
  59. package/dist/hooks/useSessionManagement.js +0 -43
  60. package/dist/hooks/useSessionSave.d.ts +0 -8
  61. package/dist/hooks/useSessionSave.js +0 -63
  62. package/dist/hooks/useSnapshotState.d.ts +0 -26
  63. package/dist/hooks/useSnapshotState.js +0 -28
  64. package/dist/hooks/useStreamingState.d.ts +0 -33
  65. package/dist/hooks/useStreamingState.js +0 -105
  66. package/dist/hooks/useTerminalFocus.d.ts +0 -28
  67. package/dist/hooks/useTerminalFocus.js +0 -87
  68. package/dist/hooks/useTerminalSize.d.ts +0 -4
  69. package/dist/hooks/useTerminalSize.js +0 -20
  70. package/dist/hooks/useTodoPicker.d.ts +0 -16
  71. package/dist/hooks/useTodoPicker.js +0 -94
  72. package/dist/hooks/useToolConfirmation.d.ts +0 -19
  73. package/dist/hooks/useToolConfirmation.js +0 -61
  74. package/dist/hooks/useVSCodeState.d.ts +0 -8
  75. package/dist/hooks/useVSCodeState.js +0 -81
  76. package/dist/i18n/I18nContext.d.ts +0 -14
  77. package/dist/i18n/I18nContext.js +0 -24
  78. package/dist/i18n/index.d.ts +0 -3
  79. package/dist/i18n/index.js +0 -2
  80. package/dist/i18n/lang/en.d.ts +0 -2
  81. package/dist/i18n/lang/en.js +0 -502
  82. package/dist/i18n/lang/es.d.ts +0 -2
  83. package/dist/i18n/lang/es.js +0 -502
  84. package/dist/i18n/lang/ja.d.ts +0 -2
  85. package/dist/i18n/lang/ja.js +0 -502
  86. package/dist/i18n/lang/ko.d.ts +0 -2
  87. package/dist/i18n/lang/ko.js +0 -502
  88. package/dist/i18n/lang/zh-TW.d.ts +0 -2
  89. package/dist/i18n/lang/zh-TW.js +0 -502
  90. package/dist/i18n/lang/zh.d.ts +0 -2
  91. package/dist/i18n/lang/zh.js +0 -502
  92. package/dist/i18n/translations.d.ts +0 -2
  93. package/dist/i18n/translations.js +0 -14
  94. package/dist/i18n/types.d.ts +0 -478
  95. package/dist/i18n/types.js +0 -1
  96. package/dist/mcp/aceCodeSearch.d.ts +0 -247
  97. package/dist/mcp/aceCodeSearch.js +0 -1058
  98. package/dist/mcp/bash.d.ts +0 -50
  99. package/dist/mcp/bash.js +0 -153
  100. package/dist/mcp/codebaseSearch.d.ts +0 -44
  101. package/dist/mcp/codebaseSearch.js +0 -275
  102. package/dist/mcp/filesystem.d.ts +0 -392
  103. package/dist/mcp/filesystem.js +0 -1445
  104. package/dist/mcp/ideDiagnostics.d.ts +0 -36
  105. package/dist/mcp/ideDiagnostics.js +0 -90
  106. package/dist/mcp/notebook.d.ts +0 -10
  107. package/dist/mcp/notebook.js +0 -367
  108. package/dist/mcp/subagent.d.ts +0 -37
  109. package/dist/mcp/subagent.js +0 -113
  110. package/dist/mcp/todo.d.ts +0 -46
  111. package/dist/mcp/todo.js +0 -511
  112. package/dist/mcp/types/aceCodeSearch.types.d.ts +0 -92
  113. package/dist/mcp/types/aceCodeSearch.types.js +0 -4
  114. package/dist/mcp/types/bash.types.d.ts +0 -13
  115. package/dist/mcp/types/bash.types.js +0 -4
  116. package/dist/mcp/types/filesystem.types.d.ts +0 -210
  117. package/dist/mcp/types/filesystem.types.js +0 -27
  118. package/dist/mcp/types/todo.types.d.ts +0 -27
  119. package/dist/mcp/types/todo.types.js +0 -4
  120. package/dist/mcp/types/websearch.types.d.ts +0 -30
  121. package/dist/mcp/types/websearch.types.js +0 -4
  122. package/dist/mcp/utils/aceCodeSearch/filesystem.utils.d.ts +0 -34
  123. package/dist/mcp/utils/aceCodeSearch/filesystem.utils.js +0 -146
  124. package/dist/mcp/utils/aceCodeSearch/language.utils.d.ts +0 -14
  125. package/dist/mcp/utils/aceCodeSearch/language.utils.js +0 -418
  126. package/dist/mcp/utils/aceCodeSearch/search.utils.d.ts +0 -31
  127. package/dist/mcp/utils/aceCodeSearch/search.utils.js +0 -136
  128. package/dist/mcp/utils/aceCodeSearch/symbol.utils.d.ts +0 -20
  129. package/dist/mcp/utils/aceCodeSearch/symbol.utils.js +0 -141
  130. package/dist/mcp/utils/bash/security.utils.d.ts +0 -20
  131. package/dist/mcp/utils/bash/security.utils.js +0 -34
  132. package/dist/mcp/utils/filesystem/batch-operations.utils.d.ts +0 -39
  133. package/dist/mcp/utils/filesystem/batch-operations.utils.js +0 -182
  134. package/dist/mcp/utils/filesystem/code-analysis.utils.d.ts +0 -18
  135. package/dist/mcp/utils/filesystem/code-analysis.utils.js +0 -165
  136. package/dist/mcp/utils/filesystem/match-finder.utils.d.ts +0 -16
  137. package/dist/mcp/utils/filesystem/match-finder.utils.js +0 -85
  138. package/dist/mcp/utils/filesystem/office-parser.utils.d.ts +0 -43
  139. package/dist/mcp/utils/filesystem/office-parser.utils.js +0 -163
  140. package/dist/mcp/utils/filesystem/path-fixer.utils.d.ts +0 -7
  141. package/dist/mcp/utils/filesystem/path-fixer.utils.js +0 -60
  142. package/dist/mcp/utils/filesystem/similarity.utils.d.ts +0 -22
  143. package/dist/mcp/utils/filesystem/similarity.utils.js +0 -75
  144. package/dist/mcp/utils/todo/date.utils.d.ts +0 -9
  145. package/dist/mcp/utils/todo/date.utils.js +0 -14
  146. package/dist/mcp/utils/websearch/browser.utils.d.ts +0 -8
  147. package/dist/mcp/utils/websearch/browser.utils.js +0 -58
  148. package/dist/mcp/utils/websearch/text.utils.d.ts +0 -16
  149. package/dist/mcp/utils/websearch/text.utils.js +0 -39
  150. package/dist/mcp/websearch.d.ts +0 -88
  151. package/dist/mcp/websearch.js +0 -375
  152. package/dist/test/logger-test.d.ts +0 -1
  153. package/dist/test/logger-test.js +0 -7
  154. package/dist/types/index.d.ts +0 -15
  155. package/dist/types/index.js +0 -1
  156. package/dist/ui/components/AgentPickerPanel.d.ts +0 -10
  157. package/dist/ui/components/AgentPickerPanel.js +0 -74
  158. package/dist/ui/components/ChatInput.d.ts +0 -46
  159. package/dist/ui/components/ChatInput.js +0 -384
  160. package/dist/ui/components/CommandPanel.d.ts +0 -15
  161. package/dist/ui/components/CommandPanel.js +0 -80
  162. package/dist/ui/components/DiffViewer.d.ts +0 -11
  163. package/dist/ui/components/DiffViewer.js +0 -178
  164. package/dist/ui/components/FileList.d.ts +0 -15
  165. package/dist/ui/components/FileList.js +0 -360
  166. package/dist/ui/components/FileRollbackConfirmation.d.ts +0 -8
  167. package/dist/ui/components/FileRollbackConfirmation.js +0 -108
  168. package/dist/ui/components/HelpPanel.d.ts +0 -2
  169. package/dist/ui/components/HelpPanel.js +0 -67
  170. package/dist/ui/components/MCPInfoPanel.d.ts +0 -2
  171. package/dist/ui/components/MCPInfoPanel.js +0 -108
  172. package/dist/ui/components/MCPInfoScreen.d.ts +0 -7
  173. package/dist/ui/components/MCPInfoScreen.js +0 -115
  174. package/dist/ui/components/MarkdownRenderer.d.ts +0 -6
  175. package/dist/ui/components/MarkdownRenderer.js +0 -70
  176. package/dist/ui/components/Menu.d.ts +0 -17
  177. package/dist/ui/components/Menu.js +0 -88
  178. package/dist/ui/components/MessageList.d.ts +0 -56
  179. package/dist/ui/components/MessageList.js +0 -97
  180. package/dist/ui/components/PendingMessages.d.ts +0 -13
  181. package/dist/ui/components/PendingMessages.js +0 -29
  182. package/dist/ui/components/PendingToolCalls.d.ts +0 -11
  183. package/dist/ui/components/PendingToolCalls.js +0 -35
  184. package/dist/ui/components/ScrollableSelectInput.d.ts +0 -29
  185. package/dist/ui/components/ScrollableSelectInput.js +0 -157
  186. package/dist/ui/components/SessionListPanel.d.ts +0 -7
  187. package/dist/ui/components/SessionListPanel.js +0 -175
  188. package/dist/ui/components/SessionListScreen.d.ts +0 -7
  189. package/dist/ui/components/SessionListScreen.js +0 -217
  190. package/dist/ui/components/SessionListScreenWrapper.d.ts +0 -7
  191. package/dist/ui/components/SessionListScreenWrapper.js +0 -14
  192. package/dist/ui/components/ShimmerText.d.ts +0 -9
  193. package/dist/ui/components/ShimmerText.js +0 -30
  194. package/dist/ui/components/TodoPickerPanel.d.ts +0 -14
  195. package/dist/ui/components/TodoPickerPanel.js +0 -119
  196. package/dist/ui/components/TodoTree.d.ts +0 -15
  197. package/dist/ui/components/TodoTree.js +0 -60
  198. package/dist/ui/components/ToolConfirmation.d.ts +0 -21
  199. package/dist/ui/components/ToolConfirmation.js +0 -204
  200. package/dist/ui/components/ToolResultPreview.d.ts +0 -13
  201. package/dist/ui/components/ToolResultPreview.js +0 -337
  202. package/dist/ui/components/UsagePanel.d.ts +0 -2
  203. package/dist/ui/components/UsagePanel.js +0 -394
  204. package/dist/ui/contexts/ThemeContext.d.ts +0 -13
  205. package/dist/ui/contexts/ThemeContext.js +0 -28
  206. package/dist/ui/pages/ChatScreen.d.ts +0 -6
  207. package/dist/ui/pages/ChatScreen.js +0 -1519
  208. package/dist/ui/pages/CodeBaseConfigScreen.d.ts +0 -8
  209. package/dist/ui/pages/CodeBaseConfigScreen.js +0 -350
  210. package/dist/ui/pages/ConfigScreen.d.ts +0 -8
  211. package/dist/ui/pages/ConfigScreen.js +0 -1101
  212. package/dist/ui/pages/CustomHeadersScreen.d.ts +0 -6
  213. package/dist/ui/pages/CustomHeadersScreen.js +0 -502
  214. package/dist/ui/pages/HeadlessModeScreen.d.ts +0 -7
  215. package/dist/ui/pages/HeadlessModeScreen.js +0 -381
  216. package/dist/ui/pages/LanguageSettingsScreen.d.ts +0 -7
  217. package/dist/ui/pages/LanguageSettingsScreen.js +0 -91
  218. package/dist/ui/pages/MCPConfigScreen.d.ts +0 -6
  219. package/dist/ui/pages/MCPConfigScreen.js +0 -55
  220. package/dist/ui/pages/ProxyConfigScreen.d.ts +0 -8
  221. package/dist/ui/pages/ProxyConfigScreen.js +0 -149
  222. package/dist/ui/pages/SensitiveCommandConfigScreen.d.ts +0 -7
  223. package/dist/ui/pages/SensitiveCommandConfigScreen.js +0 -271
  224. package/dist/ui/pages/SubAgentConfigScreen.d.ts +0 -9
  225. package/dist/ui/pages/SubAgentConfigScreen.js +0 -435
  226. package/dist/ui/pages/SubAgentListScreen.d.ts +0 -9
  227. package/dist/ui/pages/SubAgentListScreen.js +0 -131
  228. package/dist/ui/pages/SystemPromptConfigScreen.d.ts +0 -6
  229. package/dist/ui/pages/SystemPromptConfigScreen.js +0 -326
  230. package/dist/ui/pages/ThemeSettingsScreen.d.ts +0 -7
  231. package/dist/ui/pages/ThemeSettingsScreen.js +0 -106
  232. package/dist/ui/pages/WelcomeScreen.d.ts +0 -7
  233. package/dist/ui/pages/WelcomeScreen.js +0 -217
  234. package/dist/ui/themes/index.d.ts +0 -23
  235. package/dist/ui/themes/index.js +0 -140
  236. package/dist/utils/apiConfig.d.ts +0 -126
  237. package/dist/utils/apiConfig.js +0 -423
  238. package/dist/utils/autoCompress.d.ts +0 -15
  239. package/dist/utils/autoCompress.js +0 -24
  240. package/dist/utils/chatExporter.d.ts +0 -9
  241. package/dist/utils/chatExporter.js +0 -118
  242. package/dist/utils/checkpointManager.d.ts +0 -74
  243. package/dist/utils/checkpointManager.js +0 -181
  244. package/dist/utils/codebaseConfig.d.ts +0 -16
  245. package/dist/utils/codebaseConfig.js +0 -67
  246. package/dist/utils/codebaseDatabase.d.ts +0 -102
  247. package/dist/utils/codebaseDatabase.js +0 -333
  248. package/dist/utils/codebaseSearchEvents.d.ts +0 -16
  249. package/dist/utils/codebaseSearchEvents.js +0 -13
  250. package/dist/utils/commandExecutor.d.ts +0 -13
  251. package/dist/utils/commandExecutor.js +0 -26
  252. package/dist/utils/commands/agent.d.ts +0 -2
  253. package/dist/utils/commands/agent.js +0 -12
  254. package/dist/utils/commands/clear.d.ts +0 -2
  255. package/dist/utils/commands/clear.js +0 -12
  256. package/dist/utils/commands/compact.d.ts +0 -2
  257. package/dist/utils/commands/compact.js +0 -12
  258. package/dist/utils/commands/export.d.ts +0 -2
  259. package/dist/utils/commands/export.js +0 -12
  260. package/dist/utils/commands/help.d.ts +0 -2
  261. package/dist/utils/commands/help.js +0 -11
  262. package/dist/utils/commands/home.d.ts +0 -2
  263. package/dist/utils/commands/home.js +0 -34
  264. package/dist/utils/commands/ide.d.ts +0 -2
  265. package/dist/utils/commands/ide.js +0 -32
  266. package/dist/utils/commands/init.d.ts +0 -2
  267. package/dist/utils/commands/init.js +0 -93
  268. package/dist/utils/commands/mcp.d.ts +0 -2
  269. package/dist/utils/commands/mcp.js +0 -12
  270. package/dist/utils/commands/resume.d.ts +0 -2
  271. package/dist/utils/commands/resume.js +0 -12
  272. package/dist/utils/commands/review.d.ts +0 -2
  273. package/dist/utils/commands/review.js +0 -81
  274. package/dist/utils/commands/role.d.ts +0 -2
  275. package/dist/utils/commands/role.js +0 -37
  276. package/dist/utils/commands/todoPicker.d.ts +0 -2
  277. package/dist/utils/commands/todoPicker.js +0 -12
  278. package/dist/utils/commands/usage.d.ts +0 -2
  279. package/dist/utils/commands/usage.js +0 -12
  280. package/dist/utils/commands/yolo.d.ts +0 -2
  281. package/dist/utils/commands/yolo.js +0 -12
  282. package/dist/utils/configManager.d.ts +0 -45
  283. package/dist/utils/configManager.js +0 -303
  284. package/dist/utils/contextCompressor.d.ts +0 -16
  285. package/dist/utils/contextCompressor.js +0 -334
  286. package/dist/utils/devMode.d.ts +0 -13
  287. package/dist/utils/devMode.js +0 -54
  288. package/dist/utils/escapeHandler.d.ts +0 -79
  289. package/dist/utils/escapeHandler.js +0 -153
  290. package/dist/utils/fileDialog.d.ts +0 -9
  291. package/dist/utils/fileDialog.js +0 -74
  292. package/dist/utils/fileUtils.d.ts +0 -40
  293. package/dist/utils/fileUtils.js +0 -185
  294. package/dist/utils/historyManager.d.ts +0 -45
  295. package/dist/utils/historyManager.js +0 -159
  296. package/dist/utils/incrementalSnapshot.d.ts +0 -109
  297. package/dist/utils/incrementalSnapshot.js +0 -383
  298. package/dist/utils/index.d.ts +0 -11
  299. package/dist/utils/index.js +0 -18
  300. package/dist/utils/languageConfig.d.ts +0 -21
  301. package/dist/utils/languageConfig.js +0 -61
  302. package/dist/utils/logger.d.ts +0 -37
  303. package/dist/utils/logger.js +0 -122
  304. package/dist/utils/mcpToolsManager.d.ts +0 -52
  305. package/dist/utils/mcpToolsManager.js +0 -878
  306. package/dist/utils/messageFormatter.d.ts +0 -12
  307. package/dist/utils/messageFormatter.js +0 -115
  308. package/dist/utils/notebookManager.d.ts +0 -59
  309. package/dist/utils/notebookManager.js +0 -213
  310. package/dist/utils/patch-highlight.d.ts +0 -5
  311. package/dist/utils/patch-highlight.js +0 -23
  312. package/dist/utils/processManager.d.ts +0 -27
  313. package/dist/utils/processManager.js +0 -75
  314. package/dist/utils/proxyUtils.d.ts +0 -15
  315. package/dist/utils/proxyUtils.js +0 -50
  316. package/dist/utils/resourceMonitor.d.ts +0 -65
  317. package/dist/utils/resourceMonitor.js +0 -175
  318. package/dist/utils/retryUtils.d.ts +0 -49
  319. package/dist/utils/retryUtils.js +0 -303
  320. package/dist/utils/sensitiveCommandManager.d.ts +0 -53
  321. package/dist/utils/sensitiveCommandManager.js +0 -308
  322. package/dist/utils/sessionConverter.d.ts +0 -7
  323. package/dist/utils/sessionConverter.js +0 -306
  324. package/dist/utils/sessionManager.d.ts +0 -53
  325. package/dist/utils/sessionManager.js +0 -371
  326. package/dist/utils/subAgentConfig.d.ts +0 -50
  327. package/dist/utils/subAgentConfig.js +0 -221
  328. package/dist/utils/subAgentExecutor.d.ts +0 -40
  329. package/dist/utils/subAgentExecutor.js +0 -434
  330. package/dist/utils/terminal.d.ts +0 -5
  331. package/dist/utils/terminal.js +0 -13
  332. package/dist/utils/textBuffer.d.ts +0 -99
  333. package/dist/utils/textBuffer.js +0 -547
  334. package/dist/utils/textUtils.d.ts +0 -37
  335. package/dist/utils/textUtils.js +0 -102
  336. package/dist/utils/themeConfig.d.ts +0 -21
  337. package/dist/utils/themeConfig.js +0 -61
  338. package/dist/utils/todoPreprocessor.d.ts +0 -5
  339. package/dist/utils/todoPreprocessor.js +0 -18
  340. package/dist/utils/todoScanner.d.ts +0 -8
  341. package/dist/utils/todoScanner.js +0 -148
  342. package/dist/utils/toolDisplayConfig.d.ts +0 -16
  343. package/dist/utils/toolDisplayConfig.js +0 -47
  344. package/dist/utils/toolExecutor.d.ts +0 -37
  345. package/dist/utils/toolExecutor.js +0 -224
  346. package/dist/utils/usageLogger.d.ts +0 -11
  347. package/dist/utils/usageLogger.js +0 -114
  348. package/dist/utils/vscodeConnection.d.ts +0 -76
  349. package/dist/utils/vscodeConnection.js +0 -430
  350. package/dist/utils/workspaceSnapshot.d.ts +0 -63
  351. package/dist/utils/workspaceSnapshot.js +0 -300
@@ -1,384 +0,0 @@
1
- import React, { useCallback, useEffect, useRef, useMemo, lazy, Suspense } from 'react';
2
- import { Box, Text } from 'ink';
3
- import { cpSlice } from '../../utils/textUtils.js';
4
- // Lazy load panel components to reduce initial bundle size
5
- const CommandPanel = lazy(() => import('./CommandPanel.js'));
6
- const FileList = lazy(() => import('./FileList.js'));
7
- const AgentPickerPanel = lazy(() => import('./AgentPickerPanel.js'));
8
- const TodoPickerPanel = lazy(() => import('./TodoPickerPanel.js'));
9
- import { useInputBuffer } from '../../hooks/useInputBuffer.js';
10
- import { useCommandPanel } from '../../hooks/useCommandPanel.js';
11
- import { useFilePicker } from '../../hooks/useFilePicker.js';
12
- import { useHistoryNavigation } from '../../hooks/useHistoryNavigation.js';
13
- import { useClipboard } from '../../hooks/useClipboard.js';
14
- import { useKeyboardInput } from '../../hooks/useKeyboardInput.js';
15
- import { useTerminalSize } from '../../hooks/useTerminalSize.js';
16
- import { useTerminalFocus } from '../../hooks/useTerminalFocus.js';
17
- import { useAgentPicker } from '../../hooks/useAgentPicker.js';
18
- import { useTodoPicker } from '../../hooks/useTodoPicker.js';
19
- import { useI18n } from '../../i18n/index.js';
20
- import { useTheme } from '../contexts/ThemeContext.js';
21
- /**
22
- * Calculate context usage percentage
23
- * This is the same logic used in ChatInput to display usage
24
- */
25
- export function calculateContextPercentage(contextUsage) {
26
- // Determine which caching system is being used
27
- const isAnthropic = (contextUsage.cacheCreationTokens || 0) > 0 ||
28
- (contextUsage.cacheReadTokens || 0) > 0;
29
- // For Anthropic: Total = inputTokens + cacheCreationTokens + cacheReadTokens
30
- // For OpenAI: Total = inputTokens (cachedTokens are already included in inputTokens)
31
- const totalInputTokens = isAnthropic
32
- ? contextUsage.inputTokens +
33
- (contextUsage.cacheCreationTokens || 0) +
34
- (contextUsage.cacheReadTokens || 0)
35
- : contextUsage.inputTokens;
36
- return Math.min(100, (totalInputTokens / contextUsage.maxContextTokens) * 100);
37
- }
38
- export default function ChatInput({ onSubmit, onCommand, placeholder = 'Type your message...', disabled = false, isProcessing = false, chatHistory = [], onHistorySelect, yoloMode = false, contextUsage, initialContent = null, onContextPercentageChange, }) {
39
- // Use i18n hook for translations
40
- const { t } = useI18n();
41
- const { theme } = useTheme();
42
- // Use terminal size hook to listen for resize events
43
- const { columns: terminalWidth } = useTerminalSize();
44
- const prevTerminalWidthRef = useRef(terminalWidth);
45
- // Use terminal focus hook to detect focus state
46
- const { hasFocus, ensureFocus } = useTerminalFocus();
47
- // Recalculate viewport dimensions to ensure proper resizing
48
- const uiOverhead = 8;
49
- const viewportWidth = Math.max(40, terminalWidth - uiOverhead);
50
- const viewport = useMemo(() => ({
51
- width: viewportWidth,
52
- height: 1,
53
- }), [viewportWidth]); // Memoize viewport to prevent unnecessary re-renders
54
- // Use input buffer hook
55
- const { buffer, triggerUpdate, forceUpdate } = useInputBuffer(viewport);
56
- // Use command panel hook
57
- const { showCommands, setShowCommands, commandSelectedIndex, setCommandSelectedIndex, getFilteredCommands, updateCommandPanelState, isProcessing: commandPanelIsProcessing, } = useCommandPanel(buffer, isProcessing);
58
- // Use file picker hook
59
- const { showFilePicker, setShowFilePicker, fileSelectedIndex, setFileSelectedIndex, fileQuery, setFileQuery, atSymbolPosition, setAtSymbolPosition, filteredFileCount, searchMode, updateFilePickerState, handleFileSelect, handleFilteredCountChange, fileListRef, } = useFilePicker(buffer, triggerUpdate);
60
- // Use history navigation hook
61
- const { showHistoryMenu, setShowHistoryMenu, historySelectedIndex, setHistorySelectedIndex, escapeKeyCount, setEscapeKeyCount, escapeKeyTimer, getUserMessages, handleHistorySelect, currentHistoryIndex, navigateHistoryUp, navigateHistoryDown, resetHistoryNavigation, saveToHistory, } = useHistoryNavigation(buffer, triggerUpdate, chatHistory, onHistorySelect);
62
- // Use agent picker hook
63
- const { showAgentPicker, setShowAgentPicker, agentSelectedIndex, setAgentSelectedIndex, updateAgentPickerState, getFilteredAgents, handleAgentSelect, } = useAgentPicker(buffer, triggerUpdate);
64
- // Use todo picker hook
65
- const { showTodoPicker, setShowTodoPicker, todoSelectedIndex, setTodoSelectedIndex, todos, selectedTodos, toggleTodoSelection, confirmTodoSelection, isLoading: todoIsLoading, searchQuery: todoSearchQuery, setSearchQuery: setTodoSearchQuery, totalTodoCount, } = useTodoPicker(buffer, triggerUpdate, process.cwd());
66
- // Use clipboard hook
67
- const { pasteFromClipboard } = useClipboard(buffer, updateCommandPanelState, updateFilePickerState, triggerUpdate);
68
- // Use keyboard input hook
69
- useKeyboardInput({
70
- buffer,
71
- disabled,
72
- triggerUpdate,
73
- forceUpdate,
74
- showCommands,
75
- setShowCommands,
76
- commandSelectedIndex,
77
- setCommandSelectedIndex,
78
- getFilteredCommands,
79
- updateCommandPanelState,
80
- onCommand,
81
- showFilePicker,
82
- setShowFilePicker,
83
- fileSelectedIndex,
84
- setFileSelectedIndex,
85
- fileQuery,
86
- setFileQuery,
87
- atSymbolPosition,
88
- setAtSymbolPosition,
89
- filteredFileCount,
90
- updateFilePickerState,
91
- handleFileSelect,
92
- fileListRef,
93
- showHistoryMenu,
94
- setShowHistoryMenu,
95
- historySelectedIndex,
96
- setHistorySelectedIndex,
97
- escapeKeyCount,
98
- setEscapeKeyCount,
99
- escapeKeyTimer,
100
- getUserMessages,
101
- handleHistorySelect,
102
- currentHistoryIndex,
103
- navigateHistoryUp,
104
- navigateHistoryDown,
105
- resetHistoryNavigation,
106
- saveToHistory,
107
- pasteFromClipboard,
108
- onSubmit,
109
- ensureFocus,
110
- showAgentPicker,
111
- setShowAgentPicker,
112
- agentSelectedIndex,
113
- setAgentSelectedIndex,
114
- updateAgentPickerState,
115
- getFilteredAgents,
116
- handleAgentSelect,
117
- showTodoPicker,
118
- setShowTodoPicker,
119
- todoSelectedIndex,
120
- setTodoSelectedIndex,
121
- todos,
122
- selectedTodos,
123
- toggleTodoSelection,
124
- confirmTodoSelection,
125
- todoSearchQuery,
126
- setTodoSearchQuery,
127
- });
128
- // Set initial content when provided (e.g., when rolling back to first message)
129
- useEffect(() => {
130
- if (initialContent) {
131
- // Always do full restore to avoid duplicate placeholders
132
- buffer.setText('');
133
- const text = initialContent.text;
134
- const images = initialContent.images || [];
135
- if (images.length === 0) {
136
- // No images, just set the text
137
- if (text) {
138
- buffer.insert(text);
139
- }
140
- }
141
- else {
142
- // Split text by image placeholders and reconstruct with actual images
143
- // Placeholder format: [image #N]
144
- const imagePlaceholderPattern = /\[image #\d+\]/g;
145
- const parts = text.split(imagePlaceholderPattern);
146
- // Interleave text parts with images
147
- for (let i = 0; i < parts.length; i++) {
148
- // Insert text part
149
- const part = parts[i];
150
- if (part) {
151
- buffer.insert(part);
152
- }
153
- // Insert image after this text part (if exists)
154
- if (i < images.length) {
155
- const img = images[i];
156
- if (img) {
157
- // Extract base64 data from data URL if present
158
- let base64Data = img.data;
159
- if (base64Data.startsWith('data:')) {
160
- const base64Index = base64Data.indexOf('base64,');
161
- if (base64Index !== -1) {
162
- base64Data = base64Data.substring(base64Index + 7);
163
- }
164
- }
165
- buffer.insertImage(base64Data, img.mimeType);
166
- }
167
- }
168
- }
169
- }
170
- triggerUpdate();
171
- }
172
- // Only run when initialContent changes
173
- // eslint-disable-next-line react-hooks/exhaustive-deps
174
- }, [initialContent]);
175
- // Force full re-render when file picker visibility changes to prevent artifacts
176
- useEffect(() => {
177
- // Use a small delay to ensure the component tree has updated
178
- const timer = setTimeout(() => {
179
- forceUpdate();
180
- }, 10);
181
- return () => clearTimeout(timer);
182
- }, [showFilePicker, forceUpdate]);
183
- // Handle terminal width changes with debounce (like gemini-cli)
184
- useEffect(() => {
185
- // Skip on initial mount
186
- if (prevTerminalWidthRef.current === terminalWidth) {
187
- prevTerminalWidthRef.current = terminalWidth;
188
- return;
189
- }
190
- prevTerminalWidthRef.current = terminalWidth;
191
- // Debounce the re-render to avoid flickering during resize
192
- const timer = setTimeout(() => {
193
- forceUpdate();
194
- }, 100);
195
- return () => clearTimeout(timer);
196
- }, [terminalWidth, forceUpdate]);
197
- // Notify parent of context percentage changes
198
- const lastPercentageRef = useRef(0);
199
- useEffect(() => {
200
- if (contextUsage && onContextPercentageChange) {
201
- const percentage = calculateContextPercentage(contextUsage);
202
- // Only call callback if percentage has actually changed
203
- if (percentage !== lastPercentageRef.current) {
204
- lastPercentageRef.current = percentage;
205
- onContextPercentageChange(percentage);
206
- }
207
- }
208
- }, [contextUsage, onContextPercentageChange]);
209
- // Render cursor based on focus state
210
- const renderCursor = useCallback((char) => {
211
- if (hasFocus) {
212
- // Focused: solid block cursor (use inverted colors)
213
- return (React.createElement(Text, { backgroundColor: theme.colors.menuNormal, color: theme.colors.background }, char));
214
- }
215
- else {
216
- // Unfocused: no cursor, just render the character normally
217
- return React.createElement(Text, null, char);
218
- }
219
- }, [hasFocus, theme]);
220
- // Render content with cursor (treat all text including placeholders as plain text)
221
- const renderContent = () => {
222
- if (buffer.text.length > 0) {
223
- // Use visual lines for proper wrapping and multi-line support
224
- const visualLines = buffer.viewportVisualLines;
225
- const [cursorRow, cursorCol] = buffer.visualCursor;
226
- const renderedLines = [];
227
- for (let i = 0; i < visualLines.length; i++) {
228
- const line = visualLines[i] || '';
229
- if (i === cursorRow) {
230
- // This line contains the cursor
231
- const beforeCursor = cpSlice(line, 0, cursorCol);
232
- const atCursor = cpSlice(line, cursorCol, cursorCol + 1) || ' ';
233
- const afterCursor = cpSlice(line, cursorCol + 1);
234
- renderedLines.push(React.createElement(Box, { key: i, flexDirection: "row" },
235
- React.createElement(Text, null, beforeCursor),
236
- renderCursor(atCursor),
237
- React.createElement(Text, null, afterCursor)));
238
- }
239
- else {
240
- // No cursor in this line
241
- renderedLines.push(React.createElement(Text, { key: i }, line || ' '));
242
- }
243
- }
244
- return React.createElement(Box, { flexDirection: "column" }, renderedLines);
245
- }
246
- else {
247
- return (React.createElement(React.Fragment, null,
248
- renderCursor(' '),
249
- React.createElement(Text, { color: theme.colors.menuSecondary, dimColor: true }, disabled ? t.chatScreen.waitingForResponse : placeholder)));
250
- }
251
- };
252
- return (React.createElement(Box, { flexDirection: "column", paddingX: 1, width: terminalWidth },
253
- showHistoryMenu && (React.createElement(Box, { flexDirection: "column", marginBottom: 1, width: terminalWidth - 2 },
254
- React.createElement(Box, { flexDirection: "column" }, (() => {
255
- const userMessages = getUserMessages();
256
- const maxVisibleItems = 5; // Number of message items to show (reduced for small terminals)
257
- // Calculate scroll window to keep selected index visible
258
- let startIndex = 0;
259
- if (userMessages.length > maxVisibleItems) {
260
- // Keep selected item in the middle of the view when possible
261
- startIndex = Math.max(0, historySelectedIndex - Math.floor(maxVisibleItems / 2));
262
- // Adjust if we're near the end
263
- startIndex = Math.min(startIndex, userMessages.length - maxVisibleItems);
264
- }
265
- const endIndex = Math.min(userMessages.length, startIndex + maxVisibleItems);
266
- const visibleMessages = userMessages.slice(startIndex, endIndex);
267
- const hasMoreAbove = startIndex > 0;
268
- const hasMoreBelow = endIndex < userMessages.length;
269
- return (React.createElement(React.Fragment, null,
270
- React.createElement(Box, { height: 1 }, hasMoreAbove ? (React.createElement(Text, { color: theme.colors.menuSecondary, dimColor: true }, t.chatScreen.moreAbove.replace('{count}', startIndex.toString()))) : (React.createElement(Text, null, " "))),
271
- visibleMessages.map((message, displayIndex) => {
272
- const actualIndex = startIndex + displayIndex;
273
- // Ensure single line by removing all newlines and control characters
274
- const singleLineLabel = message.label
275
- .replace(/[\r\n\t\v\f\u0000-\u001F\u007F-\u009F]+/g, ' ')
276
- .replace(/\s+/g, ' ')
277
- .trim();
278
- // Calculate available width for the message
279
- const prefixWidth = 3; // "❯ " or " "
280
- const maxLabelWidth = terminalWidth - 4 - prefixWidth;
281
- const truncatedLabel = singleLineLabel.length > maxLabelWidth
282
- ? singleLineLabel.slice(0, maxLabelWidth - 3) + '...'
283
- : singleLineLabel;
284
- return (React.createElement(Box, { key: message.value, height: 1 },
285
- React.createElement(Text, { color: actualIndex === historySelectedIndex
286
- ? theme.colors.menuSelected
287
- : theme.colors.menuNormal, bold: true, wrap: "truncate" },
288
- actualIndex === historySelectedIndex ? '❯ ' : ' ',
289
- truncatedLabel)));
290
- }),
291
- React.createElement(Box, { height: 1 }, hasMoreBelow ? (React.createElement(Text, { color: theme.colors.menuSecondary, dimColor: true }, t.chatScreen.moreBelow.replace('{count}', (userMessages.length - endIndex).toString()))) : (React.createElement(Text, null, " ")))));
292
- })()),
293
- React.createElement(Box, { marginBottom: 1 },
294
- React.createElement(Text, { color: theme.colors.menuInfo, dimColor: true }, t.chatScreen.historyNavigateHint)))),
295
- !showHistoryMenu && (React.createElement(React.Fragment, null,
296
- React.createElement(Box, { flexDirection: "column", width: terminalWidth - 2 },
297
- React.createElement(Text, { color: theme.colors.menuSecondary }, '─'.repeat(terminalWidth - 2)),
298
- React.createElement(Box, { flexDirection: "row" },
299
- React.createElement(Text, { color: theme.colors.menuInfo, bold: true },
300
- "\u276F",
301
- ' '),
302
- React.createElement(Box, { flexGrow: 1 }, renderContent())),
303
- React.createElement(Text, { color: theme.colors.menuSecondary }, '─'.repeat(terminalWidth - 2))),
304
- (showCommands && getFilteredCommands().length > 0) ||
305
- showFilePicker ? (React.createElement(Box, { marginTop: 1 },
306
- React.createElement(Text, null, showCommands && getFilteredCommands().length > 0
307
- ? t.chatScreen.typeToFilterCommands
308
- : showFilePicker
309
- ? searchMode === 'content'
310
- ? t.chatScreen.contentSearchHint
311
- : t.chatScreen.fileSearchHint
312
- : ''))) : null,
313
- React.createElement(Suspense, { fallback: null },
314
- React.createElement(CommandPanel, { commands: getFilteredCommands(), selectedIndex: commandSelectedIndex, query: buffer.getFullText().slice(1), visible: showCommands, isProcessing: commandPanelIsProcessing })),
315
- React.createElement(Box, null,
316
- React.createElement(Suspense, { fallback: null },
317
- React.createElement(FileList, { ref: fileListRef, query: fileQuery, selectedIndex: fileSelectedIndex, visible: showFilePicker, maxItems: 10, rootPath: process.cwd(), onFilteredCountChange: handleFilteredCountChange, searchMode: searchMode }))),
318
- React.createElement(Suspense, { fallback: null },
319
- React.createElement(AgentPickerPanel, { agents: getFilteredAgents(), selectedIndex: agentSelectedIndex, visible: showAgentPicker, maxHeight: 5 })),
320
- React.createElement(Suspense, { fallback: null },
321
- React.createElement(TodoPickerPanel, { todos: todos, selectedIndex: todoSelectedIndex, selectedTodos: selectedTodos, visible: showTodoPicker, maxHeight: 5, isLoading: todoIsLoading, searchQuery: todoSearchQuery, totalCount: totalTodoCount })),
322
- yoloMode && (React.createElement(Box, { marginTop: 1 },
323
- React.createElement(Text, { color: theme.colors.warning, dimColor: true }, t.chatScreen.yoloModeActive))),
324
- contextUsage && (React.createElement(Box, { marginTop: 1 },
325
- React.createElement(Text, { color: theme.colors.menuSecondary, dimColor: true }, (() => {
326
- // Determine which caching system is being used
327
- const isAnthropic = (contextUsage.cacheCreationTokens || 0) > 0 ||
328
- (contextUsage.cacheReadTokens || 0) > 0;
329
- const isOpenAI = (contextUsage.cachedTokens || 0) > 0;
330
- // Use the exported function for consistent calculation
331
- const percentage = calculateContextPercentage(contextUsage);
332
- // Calculate total tokens for display
333
- const totalInputTokens = isAnthropic
334
- ? contextUsage.inputTokens +
335
- (contextUsage.cacheCreationTokens || 0) +
336
- (contextUsage.cacheReadTokens || 0)
337
- : contextUsage.inputTokens;
338
- let color;
339
- if (percentage < 50)
340
- color = theme.colors.success;
341
- else if (percentage < 75)
342
- color = theme.colors.warning;
343
- else if (percentage < 90)
344
- color = theme.colors.warning;
345
- else
346
- color = theme.colors.error;
347
- const formatNumber = (num) => {
348
- if (num >= 1000)
349
- return `${(num / 1000).toFixed(1)}k`;
350
- return num.toString();
351
- };
352
- const hasCacheMetrics = isAnthropic || isOpenAI;
353
- return (React.createElement(React.Fragment, null,
354
- React.createElement(Text, { color: color },
355
- percentage.toFixed(1),
356
- "%"),
357
- React.createElement(Text, null, " \u00B7 "),
358
- React.createElement(Text, { color: color }, formatNumber(totalInputTokens)),
359
- React.createElement(Text, null, t.chatScreen.tokens),
360
- hasCacheMetrics && (React.createElement(React.Fragment, null,
361
- React.createElement(Text, null, " \u00B7 "),
362
- isAnthropic && (React.createElement(React.Fragment, null,
363
- (contextUsage.cacheReadTokens || 0) > 0 && (React.createElement(React.Fragment, null,
364
- React.createElement(Text, { color: theme.colors.menuInfo },
365
- "\u21AF",
366
- ' ',
367
- formatNumber(contextUsage.cacheReadTokens || 0),
368
- ' ',
369
- t.chatScreen.cached))),
370
- (contextUsage.cacheCreationTokens || 0) > 0 && (React.createElement(React.Fragment, null,
371
- (contextUsage.cacheReadTokens || 0) > 0 && (React.createElement(Text, null, " \u00B7 ")),
372
- React.createElement(Text, { color: theme.colors.warning },
373
- "\u25C6",
374
- ' ',
375
- formatNumber(contextUsage.cacheCreationTokens || 0),
376
- ' ',
377
- t.chatScreen.newCache))))),
378
- isOpenAI && (React.createElement(Text, { color: theme.colors.menuInfo },
379
- "\u21AF ",
380
- formatNumber(contextUsage.cachedTokens || 0),
381
- ' ',
382
- t.chatScreen.cached))))));
383
- })())))))));
384
- }
@@ -1,15 +0,0 @@
1
- import React from 'react';
2
- interface Command {
3
- name: string;
4
- description: string;
5
- }
6
- interface Props {
7
- commands: Command[];
8
- selectedIndex: number;
9
- query: string;
10
- visible: boolean;
11
- maxHeight?: number;
12
- isProcessing?: boolean;
13
- }
14
- declare const CommandPanel: React.MemoExoticComponent<({ commands, selectedIndex, visible, maxHeight, isProcessing, }: Props) => React.JSX.Element | null>;
15
- export default CommandPanel;
@@ -1,80 +0,0 @@
1
- import React, { memo, useMemo } from 'react';
2
- import { Box, Text } from 'ink';
3
- import { Alert } from '@inkjs/ui';
4
- import { useI18n } from '../../i18n/index.js';
5
- import { useTheme } from '../contexts/ThemeContext.js';
6
- const CommandPanel = memo(({ commands, selectedIndex, visible, maxHeight, isProcessing = false, }) => {
7
- const { t } = useI18n();
8
- const { theme } = useTheme();
9
- // Fixed maximum display items to prevent rendering issues
10
- const MAX_DISPLAY_ITEMS = 5;
11
- const effectiveMaxItems = maxHeight
12
- ? Math.min(maxHeight, MAX_DISPLAY_ITEMS)
13
- : MAX_DISPLAY_ITEMS;
14
- // Limit displayed commands
15
- const displayedCommands = useMemo(() => {
16
- if (commands.length <= effectiveMaxItems) {
17
- return commands;
18
- }
19
- // Show commands around the selected index
20
- const halfWindow = Math.floor(effectiveMaxItems / 2);
21
- let startIndex = Math.max(0, selectedIndex - halfWindow);
22
- let endIndex = Math.min(commands.length, startIndex + effectiveMaxItems);
23
- // Adjust if we're near the end
24
- if (endIndex - startIndex < effectiveMaxItems) {
25
- startIndex = Math.max(0, endIndex - effectiveMaxItems);
26
- }
27
- return commands.slice(startIndex, endIndex);
28
- }, [commands, selectedIndex, effectiveMaxItems]);
29
- // Calculate actual selected index in the displayed subset
30
- const displayedSelectedIndex = useMemo(() => {
31
- return displayedCommands.findIndex(cmd => {
32
- const originalIndex = commands.indexOf(cmd);
33
- return originalIndex === selectedIndex;
34
- });
35
- }, [displayedCommands, commands, selectedIndex]);
36
- // Don't show panel if not visible
37
- if (!visible) {
38
- return null;
39
- }
40
- // Show processing message if conversation is in progress
41
- if (isProcessing) {
42
- return (React.createElement(Box, { flexDirection: "column" },
43
- React.createElement(Box, { width: "100%" },
44
- React.createElement(Box, { flexDirection: "column", width: "100%" },
45
- React.createElement(Box, null,
46
- React.createElement(Text, { color: theme.colors.warning, bold: true }, t.commandPanel.title)),
47
- React.createElement(Box, { marginTop: 1 },
48
- React.createElement(Alert, { variant: "info" }, t.commandPanel.processingMessage))))));
49
- }
50
- // Don't show panel if no commands found
51
- if (commands.length === 0) {
52
- return null;
53
- }
54
- return (React.createElement(Box, { flexDirection: "column" },
55
- React.createElement(Box, { width: "100%" },
56
- React.createElement(Box, { flexDirection: "column", width: "100%" },
57
- React.createElement(Box, null,
58
- React.createElement(Text, { color: theme.colors.warning, bold: true },
59
- t.commandPanel.availableCommands,
60
- ' ',
61
- commands.length > effectiveMaxItems &&
62
- `(${selectedIndex + 1}/${commands.length})`)),
63
- displayedCommands.map((command, index) => (React.createElement(Box, { key: command.name, flexDirection: "column", width: "100%" },
64
- React.createElement(Text, { color: index === displayedSelectedIndex ? theme.colors.success : theme.colors.menuSecondary, bold: true },
65
- index === displayedSelectedIndex ? '❯ ' : ' ',
66
- "/",
67
- command.name),
68
- React.createElement(Box, { marginLeft: 3 },
69
- React.createElement(Text, { color: index === displayedSelectedIndex ? theme.colors.success : theme.colors.menuSecondary, dimColor: true },
70
- "\u2514\u2500 ",
71
- command.description))))),
72
- commands.length > effectiveMaxItems && (React.createElement(Box, { marginTop: 1 },
73
- React.createElement(Text, { color: theme.colors.menuSecondary, dimColor: true },
74
- t.commandPanel.scrollHint,
75
- " \u00B7",
76
- ' ',
77
- t.commandPanel.moreHidden.replace('{count}', (commands.length - effectiveMaxItems).toString()))))))));
78
- });
79
- CommandPanel.displayName = 'CommandPanel';
80
- export default CommandPanel;
@@ -1,11 +0,0 @@
1
- import React from 'react';
2
- interface Props {
3
- oldContent?: string;
4
- newContent: string;
5
- filename?: string;
6
- completeOldContent?: string;
7
- completeNewContent?: string;
8
- startLineNumber?: number;
9
- }
10
- export default function DiffViewer({ oldContent, newContent, filename, completeOldContent, completeNewContent, startLineNumber, }: Props): React.JSX.Element | null;
11
- export {};