dexto 1.6.1 → 1.6.3
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.
- package/dist/analytics/wrapper.js +1 -1
- package/dist/cli/auth/dexto-api-key.d.ts +34 -0
- package/dist/cli/auth/dexto-api-key.d.ts.map +1 -0
- package/dist/cli/auth/dexto-api-key.js +161 -0
- package/dist/cli/auth/index.d.ts +2 -1
- package/dist/cli/auth/index.d.ts.map +1 -1
- package/dist/cli/auth/index.js +2 -1
- package/dist/cli/auth/oauth.d.ts +10 -0
- package/dist/cli/auth/oauth.d.ts.map +1 -1
- package/dist/cli/auth/oauth.js +142 -39
- package/dist/cli/auth/service.d.ts +1 -0
- package/dist/cli/auth/service.d.ts.map +1 -1
- package/dist/cli/auth/service.js +1 -0
- package/dist/cli/commands/auth/login.d.ts.map +1 -1
- package/dist/cli/commands/auth/login.js +40 -105
- package/dist/cli/commands/setup.d.ts.map +1 -1
- package/dist/cli/commands/setup.js +157 -120
- package/dist/cli/utils/config-validation.js +3 -3
- package/dist/cli/utils/options.d.ts.map +1 -1
- package/dist/cli/utils/options.js +6 -0
- package/dist/cli/utils/scaffolding-utils.d.ts.map +1 -1
- package/dist/cli/utils/scaffolding-utils.js +38 -4
- package/dist/index-main.js +78 -11
- package/dist/index.js +12 -0
- package/dist/web.d.ts.map +1 -1
- package/dist/web.js +18 -11
- package/dist/webui/assets/index-d6c-yJNn.js +2059 -0
- package/dist/webui/assets/index-yKdFLN1k.css +1 -0
- package/dist/webui/assets/react-vendor-l0sNRNKZ.js +1 -0
- package/dist/webui/assets/tanstack-BjCuxfF-.js +41 -0
- package/dist/webui/index.html +3 -4
- package/package.json +13 -23
- package/dist/cli/assets/sounds/SOURCES.md +0 -35
- package/dist/cli/assets/sounds/boot.wav +0 -0
- package/dist/cli/assets/sounds/chime.wav +0 -0
- package/dist/cli/assets/sounds/coin.wav +0 -0
- package/dist/cli/assets/sounds/confirm.wav +0 -0
- package/dist/cli/assets/sounds/levelup.wav +0 -0
- package/dist/cli/assets/sounds/ping.wav +0 -0
- package/dist/cli/assets/sounds/powerup.wav +0 -0
- package/dist/cli/assets/sounds/startup.wav +0 -0
- package/dist/cli/assets/sounds/success.wav +0 -0
- package/dist/cli/assets/sounds/treasure.wav +0 -0
- package/dist/cli/assets/sounds/win.wav +0 -0
- package/dist/cli/commands/interactive-commands/auth/index.d.ts +0 -12
- package/dist/cli/commands/interactive-commands/auth/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/auth/index.js +0 -20
- package/dist/cli/commands/interactive-commands/command-parser.d.ts +0 -56
- package/dist/cli/commands/interactive-commands/command-parser.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/command-parser.js +0 -173
- package/dist/cli/commands/interactive-commands/commands.d.ts +0 -52
- package/dist/cli/commands/interactive-commands/commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/commands.js +0 -142
- package/dist/cli/commands/interactive-commands/documentation-commands.d.ts +0 -15
- package/dist/cli/commands/interactive-commands/documentation-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/documentation-commands.js +0 -39
- package/dist/cli/commands/interactive-commands/exit-handler.d.ts +0 -12
- package/dist/cli/commands/interactive-commands/exit-handler.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/exit-handler.js +0 -20
- package/dist/cli/commands/interactive-commands/exit-stats.d.ts +0 -24
- package/dist/cli/commands/interactive-commands/exit-stats.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/exit-stats.js +0 -17
- package/dist/cli/commands/interactive-commands/export/index.d.ts +0 -13
- package/dist/cli/commands/interactive-commands/export/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/export/index.js +0 -21
- package/dist/cli/commands/interactive-commands/general-commands.d.ts +0 -22
- package/dist/cli/commands/interactive-commands/general-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/general-commands.js +0 -508
- package/dist/cli/commands/interactive-commands/mcp/index.d.ts +0 -13
- package/dist/cli/commands/interactive-commands/mcp/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/mcp/index.js +0 -18
- package/dist/cli/commands/interactive-commands/model/index.d.ts +0 -13
- package/dist/cli/commands/interactive-commands/model/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/model/index.js +0 -19
- package/dist/cli/commands/interactive-commands/plugin/index.d.ts +0 -13
- package/dist/cli/commands/interactive-commands/plugin/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/plugin/index.js +0 -18
- package/dist/cli/commands/interactive-commands/prompt-commands.d.ts +0 -25
- package/dist/cli/commands/interactive-commands/prompt-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/prompt-commands.js +0 -284
- package/dist/cli/commands/interactive-commands/session/index.d.ts +0 -16
- package/dist/cli/commands/interactive-commands/session/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/session/index.js +0 -15
- package/dist/cli/commands/interactive-commands/session/session-commands.d.ts +0 -32
- package/dist/cli/commands/interactive-commands/session/session-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/session/session-commands.js +0 -65
- package/dist/cli/commands/interactive-commands/system/index.d.ts +0 -13
- package/dist/cli/commands/interactive-commands/system/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/system/index.js +0 -12
- package/dist/cli/commands/interactive-commands/system/system-commands.d.ts +0 -6
- package/dist/cli/commands/interactive-commands/system/system-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/system/system-commands.js +0 -188
- package/dist/cli/commands/interactive-commands/tool-commands.d.ts +0 -15
- package/dist/cli/commands/interactive-commands/tool-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/tool-commands.js +0 -24
- package/dist/cli/commands/interactive-commands/utils/arg-parser.d.ts +0 -57
- package/dist/cli/commands/interactive-commands/utils/arg-parser.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/utils/arg-parser.js +0 -81
- package/dist/cli/commands/interactive-commands/utils/command-output.d.ts +0 -40
- package/dist/cli/commands/interactive-commands/utils/command-output.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/utils/command-output.js +0 -56
- package/dist/cli/commands/interactive-commands/utils/format-output.d.ts +0 -14
- package/dist/cli/commands/interactive-commands/utils/format-output.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/utils/format-output.js +0 -18
- package/dist/cli/ink-cli/InkCLIRefactored.d.ts +0 -52
- package/dist/cli/ink-cli/InkCLIRefactored.d.ts.map +0 -1
- package/dist/cli/ink-cli/InkCLIRefactored.js +0 -231
- package/dist/cli/ink-cli/components/ApprovalPrompt.d.ts +0 -44
- package/dist/cli/ink-cli/components/ApprovalPrompt.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/ApprovalPrompt.js +0 -323
- package/dist/cli/ink-cli/components/BackgroundTasksPanel.d.ts +0 -18
- package/dist/cli/ink-cli/components/BackgroundTasksPanel.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/BackgroundTasksPanel.js +0 -48
- package/dist/cli/ink-cli/components/CustomInput.d.ts +0 -17
- package/dist/cli/ink-cli/components/CustomInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/CustomInput.js +0 -51
- package/dist/cli/ink-cli/components/CustomTextInput.d.ts +0 -16
- package/dist/cli/ink-cli/components/CustomTextInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/CustomTextInput.js +0 -36
- package/dist/cli/ink-cli/components/EditableMultiLineInput.d.ts +0 -19
- package/dist/cli/ink-cli/components/EditableMultiLineInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/EditableMultiLineInput.js +0 -120
- package/dist/cli/ink-cli/components/ElicitationForm.d.ts +0 -24
- package/dist/cli/ink-cli/components/ElicitationForm.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/ElicitationForm.js +0 -592
- package/dist/cli/ink-cli/components/ErrorBoundary.d.ts +0 -20
- package/dist/cli/ink-cli/components/ErrorBoundary.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/ErrorBoundary.js +0 -29
- package/dist/cli/ink-cli/components/Footer.d.ts +0 -22
- package/dist/cli/ink-cli/components/Footer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/Footer.js +0 -76
- package/dist/cli/ink-cli/components/HistorySearchBar.d.ts +0 -17
- package/dist/cli/ink-cli/components/HistorySearchBar.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/HistorySearchBar.js +0 -8
- package/dist/cli/ink-cli/components/MultiLineInput.d.ts +0 -12
- package/dist/cli/ink-cli/components/MultiLineInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/MultiLineInput.js +0 -27
- package/dist/cli/ink-cli/components/ResourceAutocomplete.d.ts +0 -26
- package/dist/cli/ink-cli/components/ResourceAutocomplete.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/ResourceAutocomplete.js +0 -385
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.d.ts +0 -28
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.js +0 -412
- package/dist/cli/ink-cli/components/StatusBar.d.ts +0 -41
- package/dist/cli/ink-cli/components/StatusBar.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/StatusBar.js +0 -116
- package/dist/cli/ink-cli/components/TextBufferInput.d.ts +0 -52
- package/dist/cli/ink-cli/components/TextBufferInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/TextBufferInput.js +0 -490
- package/dist/cli/ink-cli/components/TodoPanel.d.ts +0 -26
- package/dist/cli/ink-cli/components/TodoPanel.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/TodoPanel.js +0 -62
- package/dist/cli/ink-cli/components/base/BaseAutocomplete.d.ts +0 -29
- package/dist/cli/ink-cli/components/base/BaseAutocomplete.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/base/BaseAutocomplete.js +0 -98
- package/dist/cli/ink-cli/components/base/BaseSelector.d.ts +0 -37
- package/dist/cli/ink-cli/components/base/BaseSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/base/BaseSelector.js +0 -128
- package/dist/cli/ink-cli/components/base/index.d.ts +0 -6
- package/dist/cli/ink-cli/components/base/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/base/index.js +0 -5
- package/dist/cli/ink-cli/components/chat/ChatView.d.ts +0 -19
- package/dist/cli/ink-cli/components/chat/ChatView.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/ChatView.js +0 -11
- package/dist/cli/ink-cli/components/chat/Footer.d.ts +0 -9
- package/dist/cli/ink-cli/components/chat/Footer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/Footer.js +0 -8
- package/dist/cli/ink-cli/components/chat/Header.d.ts +0 -18
- package/dist/cli/ink-cli/components/chat/Header.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/Header.js +0 -16
- package/dist/cli/ink-cli/components/chat/MessageItem.d.ts +0 -21
- package/dist/cli/ink-cli/components/chat/MessageItem.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/MessageItem.js +0 -182
- package/dist/cli/ink-cli/components/chat/MessageList.d.ts +0 -16
- package/dist/cli/ink-cli/components/chat/MessageList.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/MessageList.js +0 -20
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.d.ts +0 -16
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.js +0 -27
- package/dist/cli/ink-cli/components/chat/ToolIcon.d.ts +0 -18
- package/dist/cli/ink-cli/components/chat/ToolIcon.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/ToolIcon.js +0 -36
- package/dist/cli/ink-cli/components/chat/index.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/index.js +0 -9
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.js +0 -6
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.js +0 -15
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.js +0 -9
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.js +0 -37
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.js +0 -9
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.js +0 -6
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.js +0 -29
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.d.ts +0 -45
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.js +0 -38
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.d.ts +0 -10
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.js +0 -6
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.d.ts +0 -13
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.js +0 -12
- package/dist/cli/ink-cli/components/input/InputArea.d.ts +0 -46
- package/dist/cli/ink-cli/components/input/InputArea.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/input/InputArea.js +0 -6
- package/dist/cli/ink-cli/components/input/index.d.ts +0 -5
- package/dist/cli/ink-cli/components/input/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/input/index.js +0 -4
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.d.ts +0 -27
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.js +0 -182
- package/dist/cli/ink-cli/components/modes/StaticCLI.d.ts +0 -29
- package/dist/cli/ink-cli/components/modes/StaticCLI.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/modes/StaticCLI.js +0 -114
- package/dist/cli/ink-cli/components/modes/index.d.ts +0 -10
- package/dist/cli/ink-cli/components/modes/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/modes/index.js +0 -9
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.d.ts +0 -26
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.js +0 -92
- package/dist/cli/ink-cli/components/overlays/CommandOutputOverlay.d.ts +0 -13
- package/dist/cli/ink-cli/components/overlays/CommandOutputOverlay.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/CommandOutputOverlay.js +0 -60
- package/dist/cli/ink-cli/components/overlays/ContextStatsOverlay.d.ts +0 -26
- package/dist/cli/ink-cli/components/overlays/ContextStatsOverlay.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/ContextStatsOverlay.js +0 -241
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.d.ts +0 -29
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.js +0 -301
- package/dist/cli/ink-cli/components/overlays/ExportWizard.d.ts +0 -22
- package/dist/cli/ink-cli/components/overlays/ExportWizard.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/ExportWizard.js +0 -308
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.d.ts +0 -23
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.js +0 -70
- package/dist/cli/ink-cli/components/overlays/MarketplaceAddPrompt.d.ts +0 -20
- package/dist/cli/ink-cli/components/overlays/MarketplaceAddPrompt.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/MarketplaceAddPrompt.js +0 -81
- package/dist/cli/ink-cli/components/overlays/MarketplaceBrowser.d.ts +0 -31
- package/dist/cli/ink-cli/components/overlays/MarketplaceBrowser.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/MarketplaceBrowser.js +0 -297
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.d.ts +0 -22
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.js +0 -59
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.d.ts +0 -26
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.js +0 -73
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.js +0 -51
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.d.ts +0 -29
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.js +0 -215
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.d.ts +0 -22
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.js +0 -80
- package/dist/cli/ink-cli/components/overlays/McpSelector.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/McpSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpSelector.js +0 -52
- package/dist/cli/ink-cli/components/overlays/McpServerActions.d.ts +0 -28
- package/dist/cli/ink-cli/components/overlays/McpServerActions.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpServerActions.js +0 -93
- package/dist/cli/ink-cli/components/overlays/McpServerList.d.ts +0 -29
- package/dist/cli/ink-cli/components/overlays/McpServerList.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/McpServerList.js +0 -116
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.d.ts +0 -28
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.js +0 -743
- package/dist/cli/ink-cli/components/overlays/PluginActions.d.ts +0 -27
- package/dist/cli/ink-cli/components/overlays/PluginActions.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PluginActions.js +0 -66
- package/dist/cli/ink-cli/components/overlays/PluginList.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/PluginList.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PluginList.js +0 -70
- package/dist/cli/ink-cli/components/overlays/PluginManager.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/PluginManager.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PluginManager.js +0 -63
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.d.ts +0 -22
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.js +0 -52
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.d.ts +0 -29
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.js +0 -166
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.d.ts +0 -27
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.js +0 -119
- package/dist/cli/ink-cli/components/overlays/PromptList.d.ts +0 -33
- package/dist/cli/ink-cli/components/overlays/PromptList.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/PromptList.js +0 -143
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.d.ts +0 -23
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.js +0 -189
- package/dist/cli/ink-cli/components/overlays/SessionRenameOverlay.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/SessionRenameOverlay.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/SessionRenameOverlay.js +0 -63
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.d.ts +0 -26
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.js +0 -126
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.js +0 -42
- package/dist/cli/ink-cli/components/overlays/SoundsSelector.d.ts +0 -21
- package/dist/cli/ink-cli/components/overlays/SoundsSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/SoundsSelector.js +0 -566
- package/dist/cli/ink-cli/components/overlays/StreamSelector.d.ts +0 -20
- package/dist/cli/ink-cli/components/overlays/StreamSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/StreamSelector.js +0 -58
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.d.ts +0 -26
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.js +0 -697
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.d.ts +0 -25
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.js +0 -604
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.d.ts +0 -15
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.js +0 -14
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.d.ts +0 -42
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.js +0 -547
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.d.ts +0 -25
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.js +0 -29
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.d.ts +0 -17
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.js +0 -11
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.d.ts +0 -20
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.js +0 -10
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.d.ts +0 -30
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.js +0 -13
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.d.ts +0 -8
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.js +0 -7
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.d.ts +0 -85
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.js +0 -38
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.d.ts +0 -21
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.js +0 -65
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.d.ts +0 -30
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.js +0 -67
- package/dist/cli/ink-cli/components/renderers/FileRenderer.d.ts +0 -21
- package/dist/cli/ink-cli/components/renderers/FileRenderer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/FileRenderer.js +0 -37
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.d.ts +0 -21
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.js +0 -26
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.d.ts +0 -20
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.js +0 -26
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.d.ts +0 -21
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.js +0 -15
- package/dist/cli/ink-cli/components/renderers/diff-shared.d.ts +0 -61
- package/dist/cli/ink-cli/components/renderers/diff-shared.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/diff-shared.js +0 -158
- package/dist/cli/ink-cli/components/renderers/index.d.ts +0 -28
- package/dist/cli/ink-cli/components/renderers/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/renderers/index.js +0 -36
- package/dist/cli/ink-cli/components/shared/FocusOverlayFrame.d.ts +0 -7
- package/dist/cli/ink-cli/components/shared/FocusOverlayFrame.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/shared/FocusOverlayFrame.js +0 -8
- package/dist/cli/ink-cli/components/shared/HintBar.d.ts +0 -6
- package/dist/cli/ink-cli/components/shared/HintBar.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/shared/HintBar.js +0 -6
- package/dist/cli/ink-cli/components/shared/MarkdownText.d.ts +0 -38
- package/dist/cli/ink-cli/components/shared/MarkdownText.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/shared/MarkdownText.js +0 -389
- package/dist/cli/ink-cli/components/shared/VirtualizedList.d.ts +0 -44
- package/dist/cli/ink-cli/components/shared/VirtualizedList.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/shared/VirtualizedList.js +0 -300
- package/dist/cli/ink-cli/components/shared/text-buffer.d.ts +0 -185
- package/dist/cli/ink-cli/components/shared/text-buffer.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/shared/text-buffer.js +0 -1338
- package/dist/cli/ink-cli/constants/processingPhrases.d.ts +0 -10
- package/dist/cli/ink-cli/constants/processingPhrases.d.ts.map +0 -1
- package/dist/cli/ink-cli/constants/processingPhrases.js +0 -92
- package/dist/cli/ink-cli/constants/spinnerFrames.d.ts +0 -2
- package/dist/cli/ink-cli/constants/spinnerFrames.d.ts.map +0 -1
- package/dist/cli/ink-cli/constants/spinnerFrames.js +0 -1
- package/dist/cli/ink-cli/constants/tips.d.ts +0 -15
- package/dist/cli/ink-cli/constants/tips.d.ts.map +0 -1
- package/dist/cli/ink-cli/constants/tips.js +0 -58
- package/dist/cli/ink-cli/containers/InputContainer.d.ts +0 -62
- package/dist/cli/ink-cli/containers/InputContainer.d.ts.map +0 -1
- package/dist/cli/ink-cli/containers/InputContainer.js +0 -643
- package/dist/cli/ink-cli/containers/OverlayContainer.d.ts +0 -42
- package/dist/cli/ink-cli/containers/OverlayContainer.d.ts.map +0 -1
- package/dist/cli/ink-cli/containers/OverlayContainer.js +0 -1840
- package/dist/cli/ink-cli/containers/index.d.ts +0 -6
- package/dist/cli/ink-cli/containers/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/containers/index.js +0 -5
- package/dist/cli/ink-cli/contexts/KeypressContext.d.ts +0 -36
- package/dist/cli/ink-cli/contexts/KeypressContext.d.ts.map +0 -1
- package/dist/cli/ink-cli/contexts/KeypressContext.js +0 -461
- package/dist/cli/ink-cli/contexts/MouseContext.d.ts +0 -27
- package/dist/cli/ink-cli/contexts/MouseContext.d.ts.map +0 -1
- package/dist/cli/ink-cli/contexts/MouseContext.js +0 -102
- package/dist/cli/ink-cli/contexts/ScrollProvider.d.ts +0 -33
- package/dist/cli/ink-cli/contexts/ScrollProvider.d.ts.map +0 -1
- package/dist/cli/ink-cli/contexts/ScrollProvider.js +0 -170
- package/dist/cli/ink-cli/contexts/SoundContext.d.ts +0 -23
- package/dist/cli/ink-cli/contexts/SoundContext.d.ts.map +0 -1
- package/dist/cli/ink-cli/contexts/SoundContext.js +0 -22
- package/dist/cli/ink-cli/contexts/index.d.ts +0 -8
- package/dist/cli/ink-cli/contexts/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/contexts/index.js +0 -7
- package/dist/cli/ink-cli/hooks/index.d.ts +0 -12
- package/dist/cli/ink-cli/hooks/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/index.js +0 -14
- package/dist/cli/ink-cli/hooks/useAgentEvents.d.ts +0 -49
- package/dist/cli/ink-cli/hooks/useAgentEvents.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useAgentEvents.js +0 -369
- package/dist/cli/ink-cli/hooks/useAnimationTick.d.ts +0 -11
- package/dist/cli/ink-cli/hooks/useAnimationTick.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useAnimationTick.js +0 -54
- package/dist/cli/ink-cli/hooks/useBatchedScroll.d.ts +0 -14
- package/dist/cli/ink-cli/hooks/useBatchedScroll.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useBatchedScroll.js +0 -25
- package/dist/cli/ink-cli/hooks/useCLIState.d.ts +0 -52
- package/dist/cli/ink-cli/hooks/useCLIState.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useCLIState.js +0 -224
- package/dist/cli/ink-cli/hooks/useElapsedTime.d.ts +0 -24
- package/dist/cli/ink-cli/hooks/useElapsedTime.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useElapsedTime.js +0 -69
- package/dist/cli/ink-cli/hooks/useGitBranch.d.ts +0 -13
- package/dist/cli/ink-cli/hooks/useGitBranch.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useGitBranch.js +0 -35
- package/dist/cli/ink-cli/hooks/useHistorySearch.d.ts +0 -61
- package/dist/cli/ink-cli/hooks/useHistorySearch.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useHistorySearch.js +0 -210
- package/dist/cli/ink-cli/hooks/useInputHistory.d.ts +0 -18
- package/dist/cli/ink-cli/hooks/useInputHistory.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useInputHistory.js +0 -26
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.d.ts +0 -136
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.js +0 -715
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.d.ts +0 -21
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.js +0 -80
- package/dist/cli/ink-cli/hooks/useKeypress.d.ts +0 -18
- package/dist/cli/ink-cli/hooks/useKeypress.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useKeypress.js +0 -26
- package/dist/cli/ink-cli/hooks/usePhraseCycler.d.ts +0 -30
- package/dist/cli/ink-cli/hooks/usePhraseCycler.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/usePhraseCycler.js +0 -68
- package/dist/cli/ink-cli/hooks/useStreaming.d.ts +0 -19
- package/dist/cli/ink-cli/hooks/useStreaming.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useStreaming.js +0 -26
- package/dist/cli/ink-cli/hooks/useTerminalSize.d.ts +0 -14
- package/dist/cli/ink-cli/hooks/useTerminalSize.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useTerminalSize.js +0 -31
- package/dist/cli/ink-cli/hooks/useTokenCounter.d.ts +0 -46
- package/dist/cli/ink-cli/hooks/useTokenCounter.d.ts.map +0 -1
- package/dist/cli/ink-cli/hooks/useTokenCounter.js +0 -122
- package/dist/cli/ink-cli/services/CommandService.d.ts +0 -58
- package/dist/cli/ink-cli/services/CommandService.d.ts.map +0 -1
- package/dist/cli/ink-cli/services/CommandService.js +0 -64
- package/dist/cli/ink-cli/services/InputService.d.ts +0 -40
- package/dist/cli/ink-cli/services/InputService.d.ts.map +0 -1
- package/dist/cli/ink-cli/services/InputService.js +0 -87
- package/dist/cli/ink-cli/services/MessageService.d.ts +0 -35
- package/dist/cli/ink-cli/services/MessageService.d.ts.map +0 -1
- package/dist/cli/ink-cli/services/MessageService.js +0 -49
- package/dist/cli/ink-cli/services/index.d.ts +0 -8
- package/dist/cli/ink-cli/services/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/services/index.js +0 -7
- package/dist/cli/ink-cli/services/processStream.d.ts +0 -75
- package/dist/cli/ink-cli/services/processStream.d.ts.map +0 -1
- package/dist/cli/ink-cli/services/processStream.js +0 -951
- package/dist/cli/ink-cli/state/actions.d.ts +0 -124
- package/dist/cli/ink-cli/state/actions.d.ts.map +0 -1
- package/dist/cli/ink-cli/state/actions.js +0 -8
- package/dist/cli/ink-cli/state/index.d.ts +0 -10
- package/dist/cli/ink-cli/state/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/state/index.js +0 -8
- package/dist/cli/ink-cli/state/initialState.d.ts +0 -12
- package/dist/cli/ink-cli/state/initialState.d.ts.map +0 -1
- package/dist/cli/ink-cli/state/initialState.js +0 -58
- package/dist/cli/ink-cli/state/reducer.d.ts +0 -15
- package/dist/cli/ink-cli/state/reducer.d.ts.map +0 -1
- package/dist/cli/ink-cli/state/reducer.js +0 -341
- package/dist/cli/ink-cli/state/streaming-state.d.ts +0 -27
- package/dist/cli/ink-cli/state/streaming-state.d.ts.map +0 -1
- package/dist/cli/ink-cli/state/streaming-state.js +0 -39
- package/dist/cli/ink-cli/state/types.d.ts +0 -378
- package/dist/cli/ink-cli/state/types.d.ts.map +0 -1
- package/dist/cli/ink-cli/state/types.js +0 -5
- package/dist/cli/ink-cli/utils/bracketedPaste.d.ts +0 -22
- package/dist/cli/ink-cli/utils/bracketedPaste.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/bracketedPaste.js +0 -27
- package/dist/cli/ink-cli/utils/clipboardUtils.d.ts +0 -49
- package/dist/cli/ink-cli/utils/clipboardUtils.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/clipboardUtils.js +0 -356
- package/dist/cli/ink-cli/utils/commandOverlays.d.ts +0 -33
- package/dist/cli/ink-cli/utils/commandOverlays.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/commandOverlays.js +0 -85
- package/dist/cli/ink-cli/utils/debugLog.d.ts +0 -38
- package/dist/cli/ink-cli/utils/debugLog.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/debugLog.js +0 -66
- package/dist/cli/ink-cli/utils/elicitationSchema.d.ts +0 -11
- package/dist/cli/ink-cli/utils/elicitationSchema.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/elicitationSchema.js +0 -80
- package/dist/cli/ink-cli/utils/idGenerator.d.ts +0 -10
- package/dist/cli/ink-cli/utils/idGenerator.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/idGenerator.js +0 -12
- package/dist/cli/ink-cli/utils/index.d.ts +0 -9
- package/dist/cli/ink-cli/utils/index.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/index.js +0 -13
- package/dist/cli/ink-cli/utils/input.d.ts +0 -25
- package/dist/cli/ink-cli/utils/input.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/input.js +0 -56
- package/dist/cli/ink-cli/utils/inputParsing.d.ts +0 -31
- package/dist/cli/ink-cli/utils/inputParsing.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/inputParsing.js +0 -70
- package/dist/cli/ink-cli/utils/llm-provider-display.d.ts +0 -3
- package/dist/cli/ink-cli/utils/llm-provider-display.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/llm-provider-display.js +0 -22
- package/dist/cli/ink-cli/utils/messageFormatting.d.ts +0 -125
- package/dist/cli/ink-cli/utils/messageFormatting.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/messageFormatting.js +0 -485
- package/dist/cli/ink-cli/utils/mouse.d.ts +0 -61
- package/dist/cli/ink-cli/utils/mouse.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/mouse.js +0 -209
- package/dist/cli/ink-cli/utils/overlayPresentation.d.ts +0 -19
- package/dist/cli/ink-cli/utils/overlayPresentation.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/overlayPresentation.js +0 -33
- package/dist/cli/ink-cli/utils/overlaySizing.d.ts +0 -19
- package/dist/cli/ink-cli/utils/overlaySizing.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/overlaySizing.js +0 -11
- package/dist/cli/ink-cli/utils/soundNotification.d.ts +0 -77
- package/dist/cli/ink-cli/utils/soundNotification.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/soundNotification.js +0 -226
- package/dist/cli/ink-cli/utils/streamSplitter.d.ts +0 -44
- package/dist/cli/ink-cli/utils/streamSplitter.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/streamSplitter.js +0 -154
- package/dist/cli/ink-cli/utils/textUtils.d.ts +0 -63
- package/dist/cli/ink-cli/utils/textUtils.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/textUtils.js +0 -248
- package/dist/cli/ink-cli/utils/toolUtils.d.ts +0 -20
- package/dist/cli/ink-cli/utils/toolUtils.d.ts.map +0 -1
- package/dist/cli/ink-cli/utils/toolUtils.js +0 -25
- package/dist/webui/assets/index-C9JXwpvo.css +0 -1
- package/dist/webui/assets/index-CKhumsZA.js +0 -2059
- package/dist/webui/assets/react-vendor-gH-7aFTg.js +0 -17
- package/dist/webui/assets/tanstack-Br79RQ-n.js +0 -25
|
@@ -1,323 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef, useState, useImperativeHandle, useRef, useEffect, useMemo, } from 'react';
|
|
3
|
-
import { Box, Text } from 'ink';
|
|
4
|
-
import { ElicitationForm } from './ElicitationForm.js';
|
|
5
|
-
import { DiffPreview, CreateFilePreview } from './renderers/index.js';
|
|
6
|
-
import { isEditWriteTool } from '../utils/toolUtils.js';
|
|
7
|
-
import { formatPathForDisplay, formatToolHeader } from '../utils/messageFormatting.js';
|
|
8
|
-
/**
|
|
9
|
-
* Compact approval prompt component that displays above the input area
|
|
10
|
-
* Shows options based on approval type:
|
|
11
|
-
* - Tool confirmation: Yes, Yes (Session), No
|
|
12
|
-
* - Tool with patterns: Yes (once), pattern options, Yes (session), No
|
|
13
|
-
* - Elicitation: Form with input fields
|
|
14
|
-
*/
|
|
15
|
-
export const ApprovalPrompt = forwardRef(({ approval, onApprove, onDeny, onCancel }, ref) => {
|
|
16
|
-
const isCommandConfirmation = approval.type === 'command_confirmation';
|
|
17
|
-
const isElicitation = approval.type === 'elicitation';
|
|
18
|
-
const isDirectoryAccess = approval.type === 'directory_access';
|
|
19
|
-
const directoryAccess = approval.metadata.directoryAccess;
|
|
20
|
-
const hasToolDirectoryAccess = approval.type === 'tool_confirmation' &&
|
|
21
|
-
directoryAccess !== undefined &&
|
|
22
|
-
typeof directoryAccess === 'object' &&
|
|
23
|
-
directoryAccess !== null;
|
|
24
|
-
const directoryAccessParentDir = hasToolDirectoryAccess && typeof directoryAccess.parentDir === 'string'
|
|
25
|
-
? directoryAccess.parentDir
|
|
26
|
-
: null;
|
|
27
|
-
// Extract tool metadata
|
|
28
|
-
const toolName = approval.metadata.toolName;
|
|
29
|
-
const toolArgs = approval.metadata.args || {};
|
|
30
|
-
const callDescriptionRaw = typeof approval.metadata.description === 'string'
|
|
31
|
-
? approval.metadata.description
|
|
32
|
-
: undefined;
|
|
33
|
-
const callDescription = useMemo(() => {
|
|
34
|
-
if (!callDescriptionRaw)
|
|
35
|
-
return null;
|
|
36
|
-
const singleLine = callDescriptionRaw.replace(/\s+/g, ' ').trim();
|
|
37
|
-
if (!singleLine)
|
|
38
|
-
return null;
|
|
39
|
-
const maxLength = 120;
|
|
40
|
-
if (singleLine.length <= maxLength)
|
|
41
|
-
return singleLine;
|
|
42
|
-
return `${singleLine.slice(0, Math.max(0, maxLength - 1))}…`;
|
|
43
|
-
}, [callDescriptionRaw]);
|
|
44
|
-
// Check if this is a plan_review tool (shows custom approval options)
|
|
45
|
-
const isPlanReview = toolName === 'plan_review';
|
|
46
|
-
// Extract suggested patterns for tools that support pattern-based approvals
|
|
47
|
-
const suggestedPatterns = approval.metadata.suggestedPatterns ?? [];
|
|
48
|
-
const hasSuggestedPatterns = suggestedPatterns.length > 0;
|
|
49
|
-
// Check if this is an edit/write file tool
|
|
50
|
-
const isEditOrWriteTool = isEditWriteTool(toolName);
|
|
51
|
-
// Format tool header using shared utility (same format as tool messages)
|
|
52
|
-
const presentationSnapshot = useMemo(() => {
|
|
53
|
-
const raw = approval.metadata
|
|
54
|
-
.presentationSnapshot;
|
|
55
|
-
if (typeof raw !== 'object' || raw === null) {
|
|
56
|
-
return undefined;
|
|
57
|
-
}
|
|
58
|
-
if (raw.version !== 1) {
|
|
59
|
-
return undefined;
|
|
60
|
-
}
|
|
61
|
-
return raw;
|
|
62
|
-
}, [approval.metadata]);
|
|
63
|
-
const formattedTool = useMemo(() => {
|
|
64
|
-
if (!toolName)
|
|
65
|
-
return null;
|
|
66
|
-
return formatToolHeader({
|
|
67
|
-
toolName,
|
|
68
|
-
args: toolArgs,
|
|
69
|
-
...(presentationSnapshot !== undefined && { presentationSnapshot }),
|
|
70
|
-
});
|
|
71
|
-
}, [toolName, toolArgs, presentationSnapshot]);
|
|
72
|
-
const [selectedIndex, setSelectedIndex] = useState(0);
|
|
73
|
-
// State for plan review feedback input
|
|
74
|
-
const [showFeedbackInput, setShowFeedbackInput] = useState(false);
|
|
75
|
-
const [feedbackText, setFeedbackText] = useState('');
|
|
76
|
-
// Ref for elicitation form
|
|
77
|
-
const elicitationFormRef = useRef(null);
|
|
78
|
-
// Use ref to avoid stale closure issues in handleInput
|
|
79
|
-
const selectedIndexRef = useRef(0);
|
|
80
|
-
// Build the list of options based on approval type
|
|
81
|
-
const options = [];
|
|
82
|
-
if (isPlanReview) {
|
|
83
|
-
// Plan review - show plan-specific options (2 options + feedback input)
|
|
84
|
-
options.push({ id: 'plan-approve', label: 'Approve' });
|
|
85
|
-
options.push({ id: 'plan-approve-accept-edits', label: 'Approve + Accept All Edits' });
|
|
86
|
-
// Third "option" is the feedback input (handled specially in render)
|
|
87
|
-
}
|
|
88
|
-
else if (hasToolDirectoryAccess) {
|
|
89
|
-
// Tool approval that includes directory access - offer session-scoped dir allow
|
|
90
|
-
const dirLabel = directoryAccessParentDir
|
|
91
|
-
? ` ${formatPathForDisplay(directoryAccessParentDir)}`
|
|
92
|
-
: '';
|
|
93
|
-
options.push({ id: 'yes', label: 'Yes (once)' });
|
|
94
|
-
options.push({ id: 'yes-directory-session', label: `Yes, allow${dirLabel} (session)` });
|
|
95
|
-
options.push({ id: 'no', label: 'No' });
|
|
96
|
-
}
|
|
97
|
-
else if (hasSuggestedPatterns) {
|
|
98
|
-
// Tool with pattern suggestions
|
|
99
|
-
options.push({ id: 'yes', label: 'Yes (once)' });
|
|
100
|
-
suggestedPatterns.forEach((pattern, i) => {
|
|
101
|
-
options.push({
|
|
102
|
-
id: `pattern-${i}`,
|
|
103
|
-
label: `Yes, allow "${pattern}"`,
|
|
104
|
-
});
|
|
105
|
-
});
|
|
106
|
-
options.push({ id: 'yes-session', label: 'Yes, allow this tool (session)' });
|
|
107
|
-
options.push({ id: 'no', label: 'No' });
|
|
108
|
-
}
|
|
109
|
-
else if (isCommandConfirmation) {
|
|
110
|
-
// Command confirmation (no session option)
|
|
111
|
-
options.push({ id: 'yes', label: 'Yes' });
|
|
112
|
-
options.push({ id: 'no', label: 'No' });
|
|
113
|
-
}
|
|
114
|
-
else if (isDirectoryAccess) {
|
|
115
|
-
// Directory access - offer session-scoped access
|
|
116
|
-
const parentDir = approval.metadata.parentDir;
|
|
117
|
-
const dirLabel = parentDir ? ` ${formatPathForDisplay(parentDir)}` : '';
|
|
118
|
-
options.push({ id: 'yes', label: 'Yes (once)' });
|
|
119
|
-
options.push({ id: 'yes-session', label: `Yes, allow${dirLabel} (session)` });
|
|
120
|
-
options.push({ id: 'no', label: 'No' });
|
|
121
|
-
}
|
|
122
|
-
else if (isEditOrWriteTool) {
|
|
123
|
-
// Edit/write file tools - offer "accept all edits" mode instead of session
|
|
124
|
-
options.push({ id: 'yes', label: 'Yes' });
|
|
125
|
-
options.push({ id: 'yes-accept-edits', label: 'Yes, and accept all edits' });
|
|
126
|
-
options.push({ id: 'no', label: 'No' });
|
|
127
|
-
}
|
|
128
|
-
else {
|
|
129
|
-
// Standard tool confirmation
|
|
130
|
-
options.push({ id: 'yes', label: 'Yes' });
|
|
131
|
-
options.push({ id: 'yes-session', label: 'Yes (Session)' });
|
|
132
|
-
options.push({ id: 'no', label: 'No' });
|
|
133
|
-
}
|
|
134
|
-
// Keep ref in sync with state
|
|
135
|
-
useEffect(() => {
|
|
136
|
-
selectedIndexRef.current = selectedIndex;
|
|
137
|
-
}, [selectedIndex]);
|
|
138
|
-
// Helper to get the option at current index
|
|
139
|
-
const getCurrentOption = () => options[selectedIndexRef.current];
|
|
140
|
-
// Expose handleInput method via ref
|
|
141
|
-
useImperativeHandle(ref, () => ({
|
|
142
|
-
handleInput: (input, key) => {
|
|
143
|
-
// For elicitation, delegate to the form
|
|
144
|
-
if (isElicitation && elicitationFormRef.current) {
|
|
145
|
-
return elicitationFormRef.current.handleInput(input, key);
|
|
146
|
-
}
|
|
147
|
-
// For plan review, calculate total options including feedback input
|
|
148
|
-
const totalOptions = isPlanReview ? options.length + 1 : options.length;
|
|
149
|
-
const isFeedbackSelected = isPlanReview && selectedIndexRef.current === options.length;
|
|
150
|
-
// Handle typing when feedback input is selected
|
|
151
|
-
if (isFeedbackSelected) {
|
|
152
|
-
if (key.return) {
|
|
153
|
-
// Submit rejection with feedback
|
|
154
|
-
onDeny(feedbackText || undefined);
|
|
155
|
-
return true;
|
|
156
|
-
}
|
|
157
|
-
else if (key.backspace || key.delete) {
|
|
158
|
-
setFeedbackText((prev) => prev.slice(0, -1));
|
|
159
|
-
return true;
|
|
160
|
-
}
|
|
161
|
-
else if (key.upArrow) {
|
|
162
|
-
// Navigate up from feedback input
|
|
163
|
-
setSelectedIndex(options.length - 1);
|
|
164
|
-
return true;
|
|
165
|
-
}
|
|
166
|
-
else if (key.downArrow) {
|
|
167
|
-
// Wrap to first option
|
|
168
|
-
setSelectedIndex(0);
|
|
169
|
-
return true;
|
|
170
|
-
}
|
|
171
|
-
else if (key.escape) {
|
|
172
|
-
onCancel();
|
|
173
|
-
return true;
|
|
174
|
-
}
|
|
175
|
-
else if (input && !key.ctrl && !key.meta) {
|
|
176
|
-
// Add typed character to feedback
|
|
177
|
-
setFeedbackText((prev) => prev + input);
|
|
178
|
-
return true;
|
|
179
|
-
}
|
|
180
|
-
return true; // Consume all input when feedback is selected
|
|
181
|
-
}
|
|
182
|
-
if (key.upArrow) {
|
|
183
|
-
setSelectedIndex((current) => current === 0 ? totalOptions - 1 : current - 1);
|
|
184
|
-
return true;
|
|
185
|
-
}
|
|
186
|
-
else if (key.downArrow) {
|
|
187
|
-
setSelectedIndex((current) => current === totalOptions - 1 ? 0 : current + 1);
|
|
188
|
-
return true;
|
|
189
|
-
}
|
|
190
|
-
else if (key.return) {
|
|
191
|
-
const option = getCurrentOption();
|
|
192
|
-
if (!option)
|
|
193
|
-
return false;
|
|
194
|
-
// Plan review options
|
|
195
|
-
if (option.id === 'plan-approve') {
|
|
196
|
-
onApprove({});
|
|
197
|
-
}
|
|
198
|
-
else if (option.id === 'plan-approve-accept-edits') {
|
|
199
|
-
onApprove({ enableAcceptEditsMode: true });
|
|
200
|
-
}
|
|
201
|
-
else if (option.id === 'yes') {
|
|
202
|
-
onApprove({});
|
|
203
|
-
}
|
|
204
|
-
else if (option.id === 'yes-session') {
|
|
205
|
-
// For directory access, remember the directory; otherwise remember the tool
|
|
206
|
-
if (isDirectoryAccess) {
|
|
207
|
-
onApprove({ rememberDirectory: true });
|
|
208
|
-
}
|
|
209
|
-
else {
|
|
210
|
-
onApprove({ rememberChoice: true });
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
else if (option.id === 'yes-directory-session') {
|
|
214
|
-
onApprove({ rememberDirectory: true });
|
|
215
|
-
}
|
|
216
|
-
else if (option.id === 'yes-accept-edits') {
|
|
217
|
-
// Approve and enable "accept all edits" mode
|
|
218
|
-
onApprove({ enableAcceptEditsMode: true });
|
|
219
|
-
}
|
|
220
|
-
else if (option.id === 'no') {
|
|
221
|
-
onDeny();
|
|
222
|
-
}
|
|
223
|
-
else if (option.id.startsWith('pattern-')) {
|
|
224
|
-
// Extract pattern index and get the pattern string
|
|
225
|
-
const patternIndex = parseInt(option.id.replace('pattern-', ''), 10);
|
|
226
|
-
const pattern = suggestedPatterns[patternIndex];
|
|
227
|
-
if (pattern) {
|
|
228
|
-
onApprove({ rememberPattern: pattern });
|
|
229
|
-
}
|
|
230
|
-
else {
|
|
231
|
-
onApprove({});
|
|
232
|
-
}
|
|
233
|
-
}
|
|
234
|
-
return true;
|
|
235
|
-
}
|
|
236
|
-
else if (key.shift && key.tab && isEditOrWriteTool) {
|
|
237
|
-
// Shift+Tab on edit/write tool: approve and enable "accept all edits" mode
|
|
238
|
-
onApprove({ enableAcceptEditsMode: true });
|
|
239
|
-
return true;
|
|
240
|
-
}
|
|
241
|
-
else if (key.escape) {
|
|
242
|
-
onCancel();
|
|
243
|
-
return true;
|
|
244
|
-
}
|
|
245
|
-
return false;
|
|
246
|
-
},
|
|
247
|
-
}), [
|
|
248
|
-
isElicitation,
|
|
249
|
-
isEditOrWriteTool,
|
|
250
|
-
isDirectoryAccess,
|
|
251
|
-
hasToolDirectoryAccess,
|
|
252
|
-
isPlanReview,
|
|
253
|
-
options,
|
|
254
|
-
suggestedPatterns,
|
|
255
|
-
onApprove,
|
|
256
|
-
onDeny,
|
|
257
|
-
onCancel,
|
|
258
|
-
feedbackText,
|
|
259
|
-
]);
|
|
260
|
-
// For elicitation, render the form
|
|
261
|
-
if (isElicitation) {
|
|
262
|
-
const metadata = approval.metadata;
|
|
263
|
-
return (_jsx(ElicitationForm, { ref: elicitationFormRef, metadata: metadata, onSubmit: (formData) => onApprove({ formData }), onCancel: onCancel }));
|
|
264
|
-
}
|
|
265
|
-
// Extract information from metadata based on approval type
|
|
266
|
-
const command = approval.metadata.command;
|
|
267
|
-
const displayPreview = approval.metadata.displayPreview;
|
|
268
|
-
// Render preview based on display type
|
|
269
|
-
const renderPreview = () => {
|
|
270
|
-
if (!displayPreview)
|
|
271
|
-
return null;
|
|
272
|
-
switch (displayPreview.type) {
|
|
273
|
-
case 'diff':
|
|
274
|
-
return _jsx(DiffPreview, { data: displayPreview });
|
|
275
|
-
case 'shell':
|
|
276
|
-
// For shell preview, show the command + optional description (no output yet)
|
|
277
|
-
return (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsx(Box, { marginBottom: 0, children: _jsx(Text, { color: "cyan", bold: true, children: displayPreview.title ?? 'Bash' }) }), _jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: "gray", paddingX: 1, children: [displayPreview.command.split('\n').map((line, i) => (_jsxs(Text, { color: "yellowBright", wrap: "wrap", children: [i === 0 ? '$ ' : ' ', line] }, i))), displayPreview.isBackground && (_jsx(Text, { color: "gray", children: "(background)" }))] }), callDescription && (_jsx(Box, { marginTop: 0, children: _jsx(Text, { color: "gray", children: callDescription }) }))] }));
|
|
278
|
-
case 'file':
|
|
279
|
-
// If content is provided, show the full content (create/review flows)
|
|
280
|
-
if (displayPreview.content) {
|
|
281
|
-
return _jsx(CreateFilePreview, { data: displayPreview });
|
|
282
|
-
}
|
|
283
|
-
// Fallback for other file operations
|
|
284
|
-
return (_jsx(Box, { marginBottom: 1, children: _jsxs(Text, { color: "gray", children: [displayPreview.operation === 'read' &&
|
|
285
|
-
`Read ${displayPreview.lineCount ?? 'file'} lines`, displayPreview.operation === 'write' &&
|
|
286
|
-
`Write to ${displayPreview.path}`, displayPreview.operation === 'delete' &&
|
|
287
|
-
`Delete ${displayPreview.path}`] }) }));
|
|
288
|
-
default:
|
|
289
|
-
return null;
|
|
290
|
-
}
|
|
291
|
-
};
|
|
292
|
-
// Extract directory access metadata
|
|
293
|
-
const directoryPath = approval.metadata.path;
|
|
294
|
-
const parentDir = approval.metadata.parentDir;
|
|
295
|
-
const operation = approval.metadata.operation;
|
|
296
|
-
const directoryAccessTitle = !isDirectoryAccess
|
|
297
|
-
? null
|
|
298
|
-
: operation === 'read'
|
|
299
|
-
? 'Read file'
|
|
300
|
-
: operation === 'write'
|
|
301
|
-
? 'Write file'
|
|
302
|
-
: operation === 'edit'
|
|
303
|
-
? 'Edit file'
|
|
304
|
-
: 'Directory access';
|
|
305
|
-
const directoryAccessToolHeader = !isDirectoryAccess || !toolName
|
|
306
|
-
? null
|
|
307
|
-
: formatToolHeader({
|
|
308
|
-
toolName,
|
|
309
|
-
args: (directoryPath ?? parentDir) ? { path: directoryPath ?? parentDir } : {},
|
|
310
|
-
...(presentationSnapshot !== undefined && { presentationSnapshot }),
|
|
311
|
-
}).header;
|
|
312
|
-
const showHeaderBlock = isDirectoryAccess || isCommandConfirmation || !displayPreview;
|
|
313
|
-
return (_jsxs(Box, { paddingX: 0, paddingY: 0, flexDirection: "column", children: [showHeaderBlock && (_jsx(Box, { flexDirection: "column", marginBottom: 0, children: isDirectoryAccess ? (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 0, children: _jsx(Text, { color: "cyan", bold: true, children: directoryAccessTitle ?? 'Directory access' }) }), directoryAccessToolHeader && (_jsx(Box, { marginBottom: 0, children: _jsx(Text, { wrap: "wrap", children: directoryAccessToolHeader }) }))] })) : isCommandConfirmation ? (_jsxs(_Fragment, { children: [_jsx(Box, { flexDirection: "row", children: _jsxs(Text, { color: "yellowBright", bold: true, children: ["Confirm command:", ' '] }) }), command && (_jsx(Box, { flexDirection: "column", marginTop: 0, children: _jsx(Box, { flexDirection: "column", borderStyle: "round", borderColor: "gray", paddingX: 1, children: command.split('\n').map((line, i) => (_jsx(Text, { color: "red", wrap: "wrap", children: line }, i))) }) }))] })) : (_jsxs(_Fragment, { children: [_jsxs(Box, { flexDirection: "row", children: [_jsxs(Text, { color: "yellowBright", bold: true, children: ["Confirm:", ' '] }), formattedTool && (_jsx(Text, { color: "cyan", children: formattedTool.header }))] }), callDescription && (_jsxs(Box, { flexDirection: "row", marginTop: 0, children: [_jsx(Text, { color: "gray", children: ' ' }), _jsx(Text, { color: "gray", children: callDescription })] }))] })) })), renderPreview(), _jsxs(Box, { flexDirection: "column", marginTop: 0, children: [options.map((option, index) => {
|
|
314
|
-
const isSelected = index === selectedIndex;
|
|
315
|
-
const isNo = option.id === 'no';
|
|
316
|
-
return (_jsx(Box, { children: isSelected ? (_jsxs(Text, { color: isNo ? 'red' : 'green', bold: true, children: [' ▶ ', option.label] })) : (_jsxs(Text, { color: "gray", children: [' ', option.label] })) }, option.id));
|
|
317
|
-
}), isPlanReview && (_jsx(Box, { children: selectedIndex === options.length ? (
|
|
318
|
-
// Selected - show editable input
|
|
319
|
-
_jsxs(Box, { flexDirection: "row", children: [_jsx(Text, { color: "red", bold: true, children: ' ▶ ' }), feedbackText ? (_jsxs(Text, { color: "white", children: [feedbackText, _jsx(Text, { color: "cyan", children: "\u258B" })] })) : (_jsxs(Text, { color: "gray", children: ["What changes would you like?", _jsx(Text, { color: "cyan", children: "\u258B" })] }))] })) : (
|
|
320
|
-
// Not selected - show placeholder
|
|
321
|
-
_jsxs(Text, { color: "gray", children: [' ', feedbackText || 'What changes would you like?'] })) }))] }), _jsx(Box, { marginTop: 0, children: _jsxs(Text, { color: "gray", children: [' ', "\u2191\u2193 to select \u2022 Enter to confirm \u2022 Esc to cancel"] }) })] }));
|
|
322
|
-
});
|
|
323
|
-
ApprovalPrompt.displayName = 'ApprovalPrompt';
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* BackgroundTasksPanel Component
|
|
3
|
-
*
|
|
4
|
-
* Displays background task status in a compact table.
|
|
5
|
-
*/
|
|
6
|
-
interface BackgroundTaskItem {
|
|
7
|
-
taskId: string;
|
|
8
|
-
status: 'running' | 'completed' | 'failed' | 'cancelled';
|
|
9
|
-
description?: string;
|
|
10
|
-
}
|
|
11
|
-
interface BackgroundTasksPanelProps {
|
|
12
|
-
tasks: BackgroundTaskItem[];
|
|
13
|
-
isExpanded: boolean;
|
|
14
|
-
isProcessing?: boolean;
|
|
15
|
-
}
|
|
16
|
-
export declare function BackgroundTasksPanel({ tasks, isExpanded, isProcessing, }: BackgroundTasksPanelProps): import("react/jsx-runtime").JSX.Element | null;
|
|
17
|
-
export {};
|
|
18
|
-
//# sourceMappingURL=BackgroundTasksPanel.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"BackgroundTasksPanel.d.ts","sourceRoot":"","sources":["../../../../src/cli/ink-cli/components/BackgroundTasksPanel.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH,UAAU,kBAAkB;IACxB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,SAAS,GAAG,WAAW,GAAG,QAAQ,GAAG,WAAW,CAAC;IACzD,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,UAAU,yBAAyB;IAC/B,KAAK,EAAE,kBAAkB,EAAE,CAAC;IAC5B,UAAU,EAAE,OAAO,CAAC;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;CAC1B;AAsBD,wBAAgB,oBAAoB,CAAC,EACjC,KAAK,EACL,UAAU,EACV,YAAoB,GACvB,EAAE,yBAAyB,kDA+E3B"}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Box, Text } from 'ink';
|
|
3
|
-
function padText(value, width) {
|
|
4
|
-
if (value.length >= width)
|
|
5
|
-
return value.slice(0, width - 1) + '…';
|
|
6
|
-
return value.padEnd(width, ' ');
|
|
7
|
-
}
|
|
8
|
-
function formatStatus(status) {
|
|
9
|
-
switch (status) {
|
|
10
|
-
case 'running':
|
|
11
|
-
return 'running';
|
|
12
|
-
case 'completed':
|
|
13
|
-
return 'done';
|
|
14
|
-
case 'failed':
|
|
15
|
-
return 'failed';
|
|
16
|
-
case 'cancelled':
|
|
17
|
-
return 'cancelled';
|
|
18
|
-
default:
|
|
19
|
-
return status;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
export function BackgroundTasksPanel({ tasks, isExpanded, isProcessing = false, }) {
|
|
23
|
-
if (!isExpanded)
|
|
24
|
-
return null;
|
|
25
|
-
const sortedTasks = [...tasks].sort((a, b) => {
|
|
26
|
-
if (a.status === b.status)
|
|
27
|
-
return 0;
|
|
28
|
-
if (a.status === 'running')
|
|
29
|
-
return -1;
|
|
30
|
-
if (b.status === 'running')
|
|
31
|
-
return 1;
|
|
32
|
-
return a.status.localeCompare(b.status);
|
|
33
|
-
});
|
|
34
|
-
const runningCount = tasks.filter((task) => task.status === 'running').length;
|
|
35
|
-
const totalCount = tasks.length;
|
|
36
|
-
const headerText = `🧵 Background Tasks (${runningCount}/${totalCount} running)`;
|
|
37
|
-
if (totalCount === 0) {
|
|
38
|
-
return (_jsxs(Box, { flexDirection: "column", borderStyle: isProcessing ? undefined : 'round', borderColor: "gray", paddingX: 1, marginX: 1, marginBottom: 1, children: [_jsx(Text, { bold: true, color: "cyan", children: headerText }), _jsx(Text, { color: "gray", dimColor: true, children: "No background tasks" })] }));
|
|
39
|
-
}
|
|
40
|
-
const statusWidth = 10;
|
|
41
|
-
const idWidth = 14;
|
|
42
|
-
const descWidth = 48;
|
|
43
|
-
return (_jsxs(Box, { flexDirection: "column", borderStyle: isProcessing ? undefined : 'round', borderColor: "gray", paddingX: 1, marginX: 1, marginBottom: 1, children: [_jsxs(Box, { children: [_jsx(Text, { bold: true, color: "cyan", children: headerText }), _jsxs(Text, { color: "gray", dimColor: true, children: [' ', "\u00B7 ctrl+b to hide bg tasks"] })] }), _jsx(Box, { children: _jsxs(Text, { color: "gray", children: [padText('status', statusWidth), padText('task id', idWidth), padText('description', descWidth)] }) }), sortedTasks.map((task) => {
|
|
44
|
-
const status = formatStatus(task.status);
|
|
45
|
-
const desc = task.description ?? '';
|
|
46
|
-
return (_jsx(Box, { children: _jsxs(Text, { color: task.status === 'running' ? 'yellow' : 'gray', children: [padText(status, statusWidth), padText(task.taskId, idWidth), padText(desc, descWidth)] }) }, task.taskId));
|
|
47
|
-
})] }));
|
|
48
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
interface CustomInputProps {
|
|
2
|
-
value: string;
|
|
3
|
-
onChange: (value: string) => void;
|
|
4
|
-
onSubmit: (value: string) => void;
|
|
5
|
-
placeholder?: string;
|
|
6
|
-
isProcessing?: boolean;
|
|
7
|
-
onWordDelete?: () => void;
|
|
8
|
-
onLineDelete?: () => void;
|
|
9
|
-
onToggleMultiLine?: () => void;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* Custom input component that handles keyboard shortcuts
|
|
13
|
-
* Fully custom implementation without TextInput to properly handle shortcuts
|
|
14
|
-
*/
|
|
15
|
-
export default function CustomInput({ value, onChange, onSubmit, placeholder, isProcessing, onWordDelete, onLineDelete, onToggleMultiLine, }: CustomInputProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
-
export {};
|
|
17
|
-
//# sourceMappingURL=CustomInput.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CustomInput.d.ts","sourceRoot":"","sources":["../../../../src/cli/ink-cli/components/CustomInput.tsx"],"names":[],"mappings":"AAEA,UAAU,gBAAgB;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAC;CAClC;AAED;;;GAGG;AACH,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAChC,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,YAAoB,EACpB,YAAY,EACZ,YAAY,EACZ,iBAAiB,GACpB,EAAE,gBAAgB,2CAoElB"}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { useInput, Text } from 'ink';
|
|
3
|
-
/**
|
|
4
|
-
* Custom input component that handles keyboard shortcuts
|
|
5
|
-
* Fully custom implementation without TextInput to properly handle shortcuts
|
|
6
|
-
*/
|
|
7
|
-
export default function CustomInput({ value, onChange, onSubmit, placeholder, isProcessing = false, onWordDelete, onLineDelete, onToggleMultiLine, }) {
|
|
8
|
-
// Handle all keyboard input directly
|
|
9
|
-
useInput((inputChar, key) => {
|
|
10
|
-
if (isProcessing)
|
|
11
|
-
return;
|
|
12
|
-
// Shift+Enter = toggle multi-line mode
|
|
13
|
-
if (key.return && key.shift) {
|
|
14
|
-
onToggleMultiLine?.();
|
|
15
|
-
return;
|
|
16
|
-
}
|
|
17
|
-
// Enter = submit
|
|
18
|
-
if (key.return) {
|
|
19
|
-
onSubmit(value);
|
|
20
|
-
return;
|
|
21
|
-
}
|
|
22
|
-
// Ctrl+U = line delete (Unix standard, also what Cmd+Backspace becomes)
|
|
23
|
-
if (key.ctrl && inputChar === 'u') {
|
|
24
|
-
onLineDelete?.();
|
|
25
|
-
return;
|
|
26
|
-
}
|
|
27
|
-
// Ctrl+W = word delete (Unix standard, also what Option+Backspace becomes)
|
|
28
|
-
if (key.ctrl && inputChar === 'w') {
|
|
29
|
-
onWordDelete?.();
|
|
30
|
-
return;
|
|
31
|
-
}
|
|
32
|
-
// Regular backspace/delete
|
|
33
|
-
if (key.backspace || key.delete) {
|
|
34
|
-
onChange(value.slice(0, -1));
|
|
35
|
-
return;
|
|
36
|
-
}
|
|
37
|
-
// Regular character input
|
|
38
|
-
if (inputChar && !key.ctrl && !key.meta) {
|
|
39
|
-
onChange(value + inputChar);
|
|
40
|
-
}
|
|
41
|
-
}, { isActive: true });
|
|
42
|
-
// Render with block cursor highlighting the character at cursor position
|
|
43
|
-
if (!value && placeholder) {
|
|
44
|
-
// Empty input - highlight first character of placeholder
|
|
45
|
-
const firstChar = placeholder[0] || ' ';
|
|
46
|
-
const rest = placeholder.slice(1);
|
|
47
|
-
return (_jsxs(Text, { children: [_jsx(Text, { color: "black", backgroundColor: "green", children: firstChar }), _jsx(Text, { color: "gray", children: rest })] }));
|
|
48
|
-
}
|
|
49
|
-
// Has value - highlight character after end (space)
|
|
50
|
-
return (_jsxs(Text, { children: [value, _jsx(Text, { color: "black", backgroundColor: "green", children: ' ' })] }));
|
|
51
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
interface CustomTextInputProps {
|
|
2
|
-
value: string;
|
|
3
|
-
onChange: (value: string) => void;
|
|
4
|
-
onSubmit: (value: string) => void;
|
|
5
|
-
placeholder?: string;
|
|
6
|
-
onWordDelete?: () => void;
|
|
7
|
-
onLineDelete?: () => void;
|
|
8
|
-
onNewline?: () => void;
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* Custom TextInput wrapper that handles keyboard shortcuts
|
|
12
|
-
* before TextInput consumes them
|
|
13
|
-
*/
|
|
14
|
-
export default function CustomTextInput({ value, onChange, onSubmit, placeholder, onWordDelete, onLineDelete, onNewline, }: CustomTextInputProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
-
export {};
|
|
16
|
-
//# sourceMappingURL=CustomTextInput.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CustomTextInput.d.ts","sourceRoot":"","sources":["../../../../src/cli/ink-cli/components/CustomTextInput.tsx"],"names":[],"mappings":"AAIA,UAAU,oBAAoB;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CAC1B;AAED;;;GAGG;AACH,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EACpC,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,YAAY,EACZ,YAAY,EACZ,SAAS,GACZ,EAAE,oBAAoB,2CA0CtB"}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useInput } from 'ink';
|
|
3
|
-
import TextInput from 'ink-text-input';
|
|
4
|
-
/**
|
|
5
|
-
* Custom TextInput wrapper that handles keyboard shortcuts
|
|
6
|
-
* before TextInput consumes them
|
|
7
|
-
*/
|
|
8
|
-
export default function CustomTextInput({ value, onChange, onSubmit, placeholder, onWordDelete, onLineDelete, onNewline, }) {
|
|
9
|
-
// Use useInput to intercept keyboard shortcuts
|
|
10
|
-
// This needs to run with isActive: true to intercept before TextInput
|
|
11
|
-
useInput((inputChar, key) => {
|
|
12
|
-
// Handle Shift+Enter or Ctrl+E to toggle multi-line mode
|
|
13
|
-
// Note: Shift+Enter may not work in all terminals, Ctrl+E is more reliable
|
|
14
|
-
if ((key.return && key.shift) || (key.ctrl && inputChar === 'e')) {
|
|
15
|
-
onNewline?.();
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
// Handle word deletion (Cmd+Delete or Cmd+Backspace on Mac, Ctrl+Delete or Ctrl+Backspace on Windows/Linux)
|
|
19
|
-
// Note: On Mac, Cmd+Backspace is the standard for word deletion
|
|
20
|
-
if ((key.delete || key.backspace) && (key.meta || key.ctrl)) {
|
|
21
|
-
onWordDelete?.();
|
|
22
|
-
return;
|
|
23
|
-
}
|
|
24
|
-
// Handle line deletion (Cmd+Shift+Delete or Ctrl+U)
|
|
25
|
-
if ((key.delete && key.meta && key.shift) || (key.ctrl && inputChar === 'u')) {
|
|
26
|
-
onLineDelete?.();
|
|
27
|
-
return;
|
|
28
|
-
}
|
|
29
|
-
// Handle Ctrl+Shift+Delete as additional word deletion shortcut (Windows/Linux)
|
|
30
|
-
if (key.delete && key.ctrl && key.shift) {
|
|
31
|
-
onWordDelete?.();
|
|
32
|
-
return;
|
|
33
|
-
}
|
|
34
|
-
}, { isActive: true });
|
|
35
|
-
return (_jsx(TextInput, { value: value, onChange: onChange, onSubmit: onSubmit, ...(placeholder ? { placeholder } : {}) }));
|
|
36
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Editable multi-line input component
|
|
3
|
-
* Simple, reliable multi-line editor without complex box layouts
|
|
4
|
-
*/
|
|
5
|
-
interface EditableMultiLineInputProps {
|
|
6
|
-
value: string;
|
|
7
|
-
onChange: (value: string) => void;
|
|
8
|
-
onSubmit: (value: string) => void;
|
|
9
|
-
placeholder?: string;
|
|
10
|
-
isProcessing?: boolean;
|
|
11
|
-
onToggleSingleLine?: () => void;
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* Multi-line input with cursor navigation
|
|
15
|
-
* Uses simple text rendering without nested boxes for reliable terminal display
|
|
16
|
-
*/
|
|
17
|
-
export default function EditableMultiLineInput({ value, onChange, onSubmit, placeholder, isProcessing, onToggleSingleLine, }: EditableMultiLineInputProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
-
export {};
|
|
19
|
-
//# sourceMappingURL=EditableMultiLineInput.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"EditableMultiLineInput.d.ts","sourceRoot":"","sources":["../../../../src/cli/ink-cli/components/EditableMultiLineInput.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,UAAU,2BAA2B;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,kBAAkB,CAAC,EAAE,MAAM,IAAI,CAAC;CACnC;AAED;;;GAGG;AACH,MAAM,CAAC,OAAO,UAAU,sBAAsB,CAAC,EAC3C,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,YAAoB,EACpB,kBAAkB,GACrB,EAAE,2BAA2B,2CAoK7B"}
|