dexto 1.3.0 → 1.5.0
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/README.md +87 -22
- package/dist/agents/agent-registry.json +9 -0
- package/dist/agents/agent-template.yml +2 -2
- package/dist/agents/coding-agent/coding-agent.yml +27 -16
- package/dist/agents/database-agent/database-agent.yml +2 -2
- package/dist/agents/default-agent.yml +9 -7
- package/dist/agents/github-agent/github-agent.yml +2 -2
- package/dist/agents/product-name-researcher/product-name-researcher.yml +2 -2
- package/dist/agents/talk2pdf-agent/talk2pdf-agent.yml +2 -2
- package/dist/analytics/events.d.ts +13 -6
- package/dist/analytics/events.d.ts.map +1 -1
- package/dist/analytics/index.d.ts +1 -1
- package/dist/analytics/index.d.ts.map +1 -1
- package/dist/analytics/index.js +6 -2
- package/dist/api/server-hono.d.ts.map +1 -1
- package/dist/api/server-hono.js +65 -9
- package/dist/cli/cli-subscriber.d.ts +4 -0
- package/dist/cli/cli-subscriber.d.ts.map +1 -1
- package/dist/cli/cli-subscriber.js +47 -3
- package/dist/cli/commands/create-app.d.ts +16 -14
- package/dist/cli/commands/create-app.d.ts.map +1 -1
- package/dist/cli/commands/create-app.js +626 -102
- package/dist/cli/commands/create-image.d.ts +7 -0
- package/dist/cli/commands/create-image.d.ts.map +1 -0
- package/dist/cli/commands/create-image.js +201 -0
- package/dist/cli/commands/helpers/formatters.d.ts.map +1 -1
- package/dist/cli/commands/helpers/formatters.js +9 -8
- package/dist/cli/commands/index.d.ts +2 -1
- package/dist/cli/commands/index.d.ts.map +1 -1
- package/dist/cli/commands/index.js +2 -1
- package/dist/cli/commands/init-app.js +7 -7
- package/dist/cli/commands/install.d.ts +0 -3
- package/dist/cli/commands/install.d.ts.map +1 -1
- package/dist/cli/commands/install.js +19 -70
- package/dist/cli/commands/interactive-commands/command-parser.d.ts +17 -14
- package/dist/cli/commands/interactive-commands/command-parser.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/command-parser.js +7 -22
- package/dist/cli/commands/interactive-commands/commands.d.ts +4 -4
- package/dist/cli/commands/interactive-commands/commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/commands.js +34 -42
- package/dist/cli/commands/interactive-commands/documentation-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/documentation-commands.js +4 -7
- package/dist/cli/commands/interactive-commands/general-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/general-commands.js +159 -117
- package/dist/cli/commands/interactive-commands/mcp/index.d.ts +9 -3
- package/dist/cli/commands/interactive-commands/mcp/index.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/mcp/index.js +18 -3
- package/dist/cli/commands/interactive-commands/model/index.d.ts +8 -6
- package/dist/cli/commands/interactive-commands/model/index.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/model/index.js +18 -6
- package/dist/cli/commands/interactive-commands/prompt-commands.d.ts +3 -2
- package/dist/cli/commands/interactive-commands/prompt-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/prompt-commands.js +77 -60
- package/dist/cli/commands/interactive-commands/session/index.d.ts +7 -12
- package/dist/cli/commands/interactive-commands/session/index.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/session/index.js +7 -14
- package/dist/cli/commands/interactive-commands/session/session-commands.d.ts +10 -24
- package/dist/cli/commands/interactive-commands/session/session-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/session/session-commands.js +16 -371
- package/dist/cli/commands/interactive-commands/system/system-commands.d.ts +1 -0
- package/dist/cli/commands/interactive-commands/system/system-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/system/system-commands.js +106 -77
- package/dist/cli/commands/interactive-commands/tool-commands.d.ts +1 -1
- package/dist/cli/commands/interactive-commands/tool-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/tool-commands.js +5 -62
- package/dist/cli/commands/interactive-commands/utils/command-output.d.ts +13 -17
- package/dist/cli/commands/interactive-commands/utils/command-output.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/utils/command-output.js +18 -37
- package/dist/cli/commands/list-agents.d.ts +2 -2
- package/dist/cli/commands/list-agents.d.ts.map +1 -1
- package/dist/cli/commands/list-agents.js +38 -34
- package/dist/cli/commands/session-commands.js +16 -16
- package/dist/cli/commands/setup.d.ts +13 -5
- package/dist/cli/commands/setup.d.ts.map +1 -1
- package/dist/cli/commands/setup.js +860 -65
- package/dist/cli/commands/uninstall.d.ts.map +1 -1
- package/dist/cli/commands/uninstall.js +4 -6
- package/dist/cli/commands/which.d.ts.map +1 -1
- package/dist/cli/commands/which.js +18 -4
- package/dist/cli/ink-cli/InkCLIRefactored.d.ts +9 -22
- package/dist/cli/ink-cli/InkCLIRefactored.d.ts.map +1 -1
- package/dist/cli/ink-cli/InkCLIRefactored.js +50 -133
- package/dist/cli/ink-cli/components/ApprovalPrompt.d.ts +26 -3
- package/dist/cli/ink-cli/components/ApprovalPrompt.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/ApprovalPrompt.js +182 -45
- package/dist/cli/ink-cli/components/CustomInput.js +1 -1
- package/dist/cli/ink-cli/components/EditableMultiLineInput.js +4 -4
- package/dist/cli/ink-cli/components/ElicitationForm.d.ts +22 -0
- package/dist/cli/ink-cli/components/ElicitationForm.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/ElicitationForm.js +358 -0
- package/dist/cli/ink-cli/components/ErrorBoundary.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/ErrorBoundary.js +1 -1
- package/dist/cli/ink-cli/components/Footer.d.ts +16 -0
- package/dist/cli/ink-cli/components/Footer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/Footer.js +27 -0
- package/dist/cli/ink-cli/components/HistorySearchBar.d.ts +17 -0
- package/dist/cli/ink-cli/components/HistorySearchBar.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/HistorySearchBar.js +8 -0
- package/dist/cli/ink-cli/components/MultiLineInput.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/MultiLineInput.js +3 -3
- package/dist/cli/ink-cli/components/ResourceAutocomplete.d.ts +15 -2
- package/dist/cli/ink-cli/components/ResourceAutocomplete.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/ResourceAutocomplete.js +126 -82
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.d.ts +15 -2
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.js +228 -122
- package/dist/cli/ink-cli/components/StatusBar.d.ts +15 -2
- package/dist/cli/ink-cli/components/StatusBar.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/StatusBar.js +50 -10
- package/dist/cli/ink-cli/components/TextBufferInput.d.ts +52 -0
- package/dist/cli/ink-cli/components/TextBufferInput.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/TextBufferInput.js +471 -0
- package/dist/cli/ink-cli/components/base/BaseAutocomplete.js +4 -4
- package/dist/cli/ink-cli/components/base/BaseSelector.d.ts +11 -1
- package/dist/cli/ink-cli/components/base/BaseSelector.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/base/BaseSelector.js +90 -49
- package/dist/cli/ink-cli/components/chat/Footer.js +1 -1
- package/dist/cli/ink-cli/components/chat/Header.d.ts +1 -0
- package/dist/cli/ink-cli/components/chat/Header.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/chat/Header.js +6 -3
- package/dist/cli/ink-cli/components/chat/MessageItem.d.ts +3 -0
- package/dist/cli/ink-cli/components/chat/MessageItem.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/chat/MessageItem.js +95 -9
- package/dist/cli/ink-cli/components/chat/MessageList.js +1 -1
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.d.ts +16 -0
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.js +27 -0
- package/dist/cli/ink-cli/components/chat/ToolIcon.d.ts +5 -3
- package/dist/cli/ink-cli/components/chat/ToolIcon.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/chat/ToolIcon.js +21 -7
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.js +6 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.js +15 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.js +9 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.js +37 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.js +9 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.js +6 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.js +29 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.d.ts +45 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.js +38 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.js +6 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.d.ts +13 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.js +12 -0
- package/dist/cli/ink-cli/components/input/InputArea.d.ts +36 -8
- package/dist/cli/ink-cli/components/input/InputArea.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/input/InputArea.js +3 -3
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.d.ts +25 -0
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.js +166 -0
- package/dist/cli/ink-cli/components/modes/StaticCLI.d.ts +27 -0
- package/dist/cli/ink-cli/components/modes/StaticCLI.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/modes/StaticCLI.js +95 -0
- package/dist/cli/ink-cli/components/modes/index.d.ts +10 -0
- package/dist/cli/ink-cli/components/modes/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/modes/index.js +9 -0
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.d.ts +26 -0
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.js +92 -0
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.js +286 -0
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.js +59 -0
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.js +59 -0
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.d.ts +26 -0
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.js +73 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.d.ts +21 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.js +51 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.js +215 -0
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.js +74 -0
- package/dist/cli/ink-cli/components/overlays/McpSelector.d.ts +21 -0
- package/dist/cli/ink-cli/components/overlays/McpSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpSelector.js +52 -0
- package/dist/cli/ink-cli/components/overlays/McpServerActions.d.ts +28 -0
- package/dist/cli/ink-cli/components/overlays/McpServerActions.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpServerActions.js +84 -0
- package/dist/cli/ink-cli/components/overlays/McpServerList.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/McpServerList.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpServerList.js +109 -0
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.d.ts +15 -8
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.js +400 -23
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.js +52 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.js +166 -0
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.d.ts +27 -0
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.js +119 -0
- package/dist/cli/ink-cli/components/overlays/PromptList.d.ts +33 -0
- package/dist/cli/ink-cli/components/overlays/PromptList.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptList.js +144 -0
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.d.ts +23 -0
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.js +189 -0
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.d.ts +7 -2
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.js +19 -5
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.d.ts +21 -0
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.js +42 -0
- package/dist/cli/ink-cli/components/overlays/StreamSelector.d.ts +20 -0
- package/dist/cli/ink-cli/components/overlays/StreamSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/StreamSelector.js +58 -0
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.d.ts +25 -0
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.js +400 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.d.ts +25 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.js +609 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.d.ts +15 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.js +14 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.d.ts +33 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.js +419 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.d.ts +25 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.js +29 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.d.ts +17 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.js +11 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.d.ts +20 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.js +10 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.d.ts +30 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.js +13 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.d.ts +8 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.js +7 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.d.ts +79 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.js +38 -0
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.d.ts +21 -0
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.js +65 -0
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.d.ts +28 -0
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.js +66 -0
- package/dist/cli/ink-cli/components/renderers/FileRenderer.d.ts +19 -0
- package/dist/cli/ink-cli/components/renderers/FileRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/FileRenderer.js +26 -0
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.d.ts +21 -0
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.js +26 -0
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.d.ts +20 -0
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.js +12 -0
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.d.ts +21 -0
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.js +25 -0
- package/dist/cli/ink-cli/components/renderers/diff-shared.d.ts +61 -0
- package/dist/cli/ink-cli/components/renderers/diff-shared.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/diff-shared.js +158 -0
- package/dist/cli/ink-cli/components/renderers/index.d.ts +28 -0
- package/dist/cli/ink-cli/components/renderers/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/index.js +36 -0
- package/dist/cli/ink-cli/components/shared/MarkdownText.d.ts +38 -0
- package/dist/cli/ink-cli/components/shared/MarkdownText.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/shared/MarkdownText.js +362 -0
- package/dist/cli/ink-cli/components/shared/VirtualizedList.d.ts +44 -0
- package/dist/cli/ink-cli/components/shared/VirtualizedList.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/shared/VirtualizedList.js +300 -0
- package/dist/cli/ink-cli/components/shared/text-buffer.d.ts +185 -0
- package/dist/cli/ink-cli/components/shared/text-buffer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/shared/text-buffer.js +1338 -0
- package/dist/cli/ink-cli/constants/processingPhrases.d.ts +10 -0
- package/dist/cli/ink-cli/constants/processingPhrases.d.ts.map +1 -0
- package/dist/cli/ink-cli/constants/processingPhrases.js +64 -0
- package/dist/cli/ink-cli/constants/tips.d.ts +15 -0
- package/dist/cli/ink-cli/constants/tips.d.ts.map +1 -0
- package/dist/cli/ink-cli/constants/tips.js +53 -0
- package/dist/cli/ink-cli/containers/InputContainer.d.ts +42 -8
- package/dist/cli/ink-cli/containers/InputContainer.d.ts.map +1 -1
- package/dist/cli/ink-cli/containers/InputContainer.js +513 -85
- package/dist/cli/ink-cli/containers/OverlayContainer.d.ts +23 -5
- package/dist/cli/ink-cli/containers/OverlayContainer.d.ts.map +1 -1
- package/dist/cli/ink-cli/containers/OverlayContainer.js +1214 -132
- package/dist/cli/ink-cli/containers/index.d.ts +1 -1
- package/dist/cli/ink-cli/containers/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/contexts/KeypressContext.d.ts +36 -0
- package/dist/cli/ink-cli/contexts/KeypressContext.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/KeypressContext.js +461 -0
- package/dist/cli/ink-cli/contexts/MouseContext.d.ts +27 -0
- package/dist/cli/ink-cli/contexts/MouseContext.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/MouseContext.js +102 -0
- package/dist/cli/ink-cli/contexts/ScrollProvider.d.ts +33 -0
- package/dist/cli/ink-cli/contexts/ScrollProvider.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/ScrollProvider.js +170 -0
- package/dist/cli/ink-cli/contexts/index.d.ts +7 -0
- package/dist/cli/ink-cli/contexts/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/index.js +6 -0
- package/dist/cli/ink-cli/hooks/index.d.ts +5 -0
- package/dist/cli/ink-cli/hooks/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/hooks/index.js +6 -1
- package/dist/cli/ink-cli/hooks/useAgentEvents.d.ts +26 -9
- package/dist/cli/ink-cli/hooks/useAgentEvents.d.ts.map +1 -1
- package/dist/cli/ink-cli/hooks/useAgentEvents.js +90 -198
- package/dist/cli/ink-cli/hooks/useBatchedScroll.d.ts +14 -0
- package/dist/cli/ink-cli/hooks/useBatchedScroll.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useBatchedScroll.js +25 -0
- package/dist/cli/ink-cli/hooks/useCLIState.d.ts +50 -0
- package/dist/cli/ink-cli/hooks/useCLIState.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useCLIState.js +190 -0
- package/dist/cli/ink-cli/hooks/useElapsedTime.d.ts +24 -0
- package/dist/cli/ink-cli/hooks/useElapsedTime.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useElapsedTime.js +69 -0
- package/dist/cli/ink-cli/hooks/useHistorySearch.d.ts +61 -0
- package/dist/cli/ink-cli/hooks/useHistorySearch.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useHistorySearch.js +210 -0
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.d.ts +136 -0
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.js +663 -0
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.d.ts.map +1 -1
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.js +7 -26
- package/dist/cli/ink-cli/hooks/useKeypress.d.ts +18 -0
- package/dist/cli/ink-cli/hooks/useKeypress.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useKeypress.js +26 -0
- package/dist/cli/ink-cli/hooks/usePhraseCycler.d.ts +30 -0
- package/dist/cli/ink-cli/hooks/usePhraseCycler.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/usePhraseCycler.js +68 -0
- package/dist/cli/ink-cli/hooks/useStreaming.d.ts +19 -0
- package/dist/cli/ink-cli/hooks/useStreaming.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useStreaming.js +26 -0
- package/dist/cli/ink-cli/hooks/useTerminalSize.d.ts +14 -0
- package/dist/cli/ink-cli/hooks/useTerminalSize.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useTerminalSize.js +31 -0
- package/dist/cli/ink-cli/hooks/useTokenCounter.d.ts +42 -0
- package/dist/cli/ink-cli/hooks/useTokenCounter.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useTokenCounter.js +96 -0
- package/dist/cli/ink-cli/services/CommandService.d.ts +32 -1
- package/dist/cli/ink-cli/services/CommandService.d.ts.map +1 -1
- package/dist/cli/ink-cli/services/CommandService.js +36 -5
- package/dist/cli/ink-cli/services/InputService.d.ts +1 -5
- package/dist/cli/ink-cli/services/InputService.d.ts.map +1 -1
- package/dist/cli/ink-cli/services/InputService.js +1 -8
- package/dist/cli/ink-cli/services/index.d.ts +2 -1
- package/dist/cli/ink-cli/services/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/services/index.js +2 -1
- package/dist/cli/ink-cli/services/processStream.d.ts +69 -0
- package/dist/cli/ink-cli/services/processStream.d.ts.map +1 -0
- package/dist/cli/ink-cli/services/processStream.js +742 -0
- package/dist/cli/ink-cli/state/actions.d.ts +30 -60
- package/dist/cli/ink-cli/state/actions.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/actions.js +3 -0
- package/dist/cli/ink-cli/state/index.d.ts +5 -3
- package/dist/cli/ink-cli/state/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/index.js +4 -3
- package/dist/cli/ink-cli/state/initialState.d.ts +4 -3
- package/dist/cli/ink-cli/state/initialState.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/initialState.js +20 -4
- package/dist/cli/ink-cli/state/reducer.d.ts +3 -0
- package/dist/cli/ink-cli/state/reducer.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/reducer.js +62 -168
- package/dist/cli/ink-cli/state/streaming-state.d.ts +27 -0
- package/dist/cli/ink-cli/state/streaming-state.d.ts.map +1 -0
- package/dist/cli/ink-cli/state/streaming-state.js +39 -0
- package/dist/cli/ink-cli/state/types.d.ts +223 -6
- package/dist/cli/ink-cli/state/types.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/bracketedPaste.d.ts +22 -0
- package/dist/cli/ink-cli/utils/bracketedPaste.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/bracketedPaste.js +27 -0
- package/dist/cli/ink-cli/utils/clipboardUtils.d.ts +49 -0
- package/dist/cli/ink-cli/utils/clipboardUtils.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/clipboardUtils.js +356 -0
- package/dist/cli/ink-cli/utils/commandOverlays.d.ts +33 -0
- package/dist/cli/ink-cli/utils/commandOverlays.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/commandOverlays.js +78 -0
- package/dist/cli/ink-cli/utils/debugLog.d.ts +38 -0
- package/dist/cli/ink-cli/utils/debugLog.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/debugLog.js +66 -0
- package/dist/cli/ink-cli/utils/index.d.ts +2 -1
- package/dist/cli/ink-cli/utils/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/index.js +3 -1
- package/dist/cli/ink-cli/utils/input.d.ts +25 -0
- package/dist/cli/ink-cli/utils/input.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/input.js +56 -0
- package/dist/cli/ink-cli/utils/inputParsing.d.ts +0 -9
- package/dist/cli/ink-cli/utils/inputParsing.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/inputParsing.js +0 -27
- package/dist/cli/ink-cli/utils/messageFormatting.d.ts +59 -3
- package/dist/cli/ink-cli/utils/messageFormatting.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/messageFormatting.js +348 -20
- package/dist/cli/ink-cli/utils/mouse.d.ts +61 -0
- package/dist/cli/ink-cli/utils/mouse.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/mouse.js +209 -0
- package/dist/cli/ink-cli/utils/streamSplitter.d.ts +44 -0
- package/dist/cli/ink-cli/utils/streamSplitter.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/streamSplitter.js +154 -0
- package/dist/cli/ink-cli/utils/textUtils.d.ts +63 -0
- package/dist/cli/ink-cli/utils/textUtils.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/textUtils.js +248 -0
- package/dist/cli/ink-cli/utils/toolUtils.d.ts +9 -0
- package/dist/cli/ink-cli/utils/toolUtils.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/toolUtils.js +15 -0
- package/dist/cli/utils/api-key-setup.d.ts +54 -4
- package/dist/cli/utils/api-key-setup.d.ts.map +1 -1
- package/dist/cli/utils/api-key-setup.js +433 -107
- package/dist/cli/utils/api-key-verification.d.ts +17 -0
- package/dist/cli/utils/api-key-verification.d.ts.map +1 -0
- package/dist/cli/utils/api-key-verification.js +211 -0
- package/dist/cli/utils/config-validation.d.ts +22 -2
- package/dist/cli/utils/config-validation.d.ts.map +1 -1
- package/dist/cli/utils/config-validation.js +354 -25
- package/dist/cli/utils/local-model-setup.d.ts +46 -0
- package/dist/cli/utils/local-model-setup.d.ts.map +1 -0
- package/dist/cli/utils/local-model-setup.js +662 -0
- package/dist/cli/utils/options.d.ts.map +1 -1
- package/dist/cli/utils/options.js +1 -3
- package/dist/cli/utils/prompt-helpers.d.ts +47 -0
- package/dist/cli/utils/prompt-helpers.d.ts.map +1 -0
- package/dist/cli/utils/prompt-helpers.js +66 -0
- package/dist/cli/utils/provider-setup.d.ts +66 -8
- package/dist/cli/utils/provider-setup.d.ts.map +1 -1
- package/dist/cli/utils/provider-setup.js +324 -84
- package/dist/cli/utils/scaffolding-utils.d.ts +76 -0
- package/dist/cli/utils/scaffolding-utils.d.ts.map +1 -0
- package/dist/cli/utils/scaffolding-utils.js +246 -0
- package/dist/cli/utils/setup-utils.d.ts +16 -0
- package/dist/cli/utils/setup-utils.d.ts.map +1 -1
- package/dist/cli/utils/setup-utils.js +72 -21
- package/dist/cli/utils/template-engine.d.ts +65 -0
- package/dist/cli/utils/template-engine.d.ts.map +1 -0
- package/dist/cli/utils/template-engine.js +1089 -0
- package/dist/config/cli-overrides.d.ts +45 -2
- package/dist/config/cli-overrides.d.ts.map +1 -1
- package/dist/config/cli-overrides.js +107 -10
- package/dist/index.js +379 -99
- package/dist/utils/agent-helpers.d.ts +95 -0
- package/dist/utils/agent-helpers.d.ts.map +1 -0
- package/dist/utils/agent-helpers.js +117 -0
- package/dist/webui/assets/index-8j-KMkX1.js +2054 -0
- package/dist/webui/assets/index-c_AX24V4.css +1 -0
- package/dist/webui/assets/{tanstack-DgxBONJY.js → tanstack-Br79RQ-n.js} +1 -1
- package/dist/webui/index.html +4 -10
- package/dist/webui/logos/aws-color.svg +1 -0
- package/dist/webui/logos/dexto/dexto_logo.svg +1 -1
- package/dist/webui/logos/dexto/dexto_logo_light.svg +6 -6
- package/dist/webui/logos/glama.svg +7 -0
- package/dist/webui/logos/litellm.svg +7 -0
- package/dist/webui/logos/openrouter.svg +1 -0
- package/package.json +18 -15
- package/dist/cli/commands/interactive-commands/index.d.ts +0 -63
- package/dist/cli/commands/interactive-commands/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/index.js +0 -73
- package/dist/cli/commands/interactive-commands/mcp/mcp-add-utils.d.ts +0 -34
- package/dist/cli/commands/interactive-commands/mcp/mcp-add-utils.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/mcp/mcp-add-utils.js +0 -178
- package/dist/cli/commands/interactive-commands/mcp/mcp-commands.d.ts +0 -9
- package/dist/cli/commands/interactive-commands/mcp/mcp-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/mcp/mcp-commands.js +0 -325
- package/dist/cli/commands/interactive-commands/model/model-commands.d.ts +0 -21
- package/dist/cli/commands/interactive-commands/model/model-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/model/model-commands.js +0 -190
- package/dist/cli/ink-cli/components/MultiLineTextInput.d.ts +0 -26
- package/dist/cli/ink-cli/components/MultiLineTextInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/MultiLineTextInput.js +0 -220
- package/dist/discord/bot.d.ts +0 -4
- package/dist/discord/bot.d.ts.map +0 -1
- package/dist/discord/bot.js +0 -193
- package/dist/telegram/bot.d.ts +0 -5
- package/dist/telegram/bot.d.ts.map +0 -1
- package/dist/telegram/bot.js +0 -251
- package/dist/webui/assets/index-DKq5Xng1.js +0 -687
- package/dist/webui/assets/index-D_0_GBu5.css +0 -1
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* SearchOverlay Component
|
|
4
|
+
* Interactive search overlay with real-time results and navigation
|
|
5
|
+
*/
|
|
6
|
+
import { useState, useEffect, useRef, forwardRef, useImperativeHandle, useCallback, } from 'react';
|
|
7
|
+
import { Box, Text } from 'ink';
|
|
8
|
+
const MAX_VISIBLE_RESULTS = 6;
|
|
9
|
+
const SEARCH_DEBOUNCE_MS = 300;
|
|
10
|
+
/**
|
|
11
|
+
* Interactive search overlay - search messages across sessions
|
|
12
|
+
*/
|
|
13
|
+
const SearchOverlay = forwardRef(function SearchOverlay({ isVisible, onClose, onSelectResult, agent }, ref) {
|
|
14
|
+
const [state, setState] = useState({
|
|
15
|
+
query: '',
|
|
16
|
+
results: [],
|
|
17
|
+
isLoading: false,
|
|
18
|
+
selectedIndex: 0,
|
|
19
|
+
total: 0,
|
|
20
|
+
hasMore: false,
|
|
21
|
+
error: null,
|
|
22
|
+
});
|
|
23
|
+
const searchTimeoutRef = useRef(null);
|
|
24
|
+
const scrollOffset = useRef(0);
|
|
25
|
+
// Monotonic counter to prevent out-of-order async responses from overwriting newer results
|
|
26
|
+
const searchSeqRef = useRef(0);
|
|
27
|
+
// Reset state when becoming visible
|
|
28
|
+
useEffect(() => {
|
|
29
|
+
if (isVisible) {
|
|
30
|
+
setState({
|
|
31
|
+
query: '',
|
|
32
|
+
results: [],
|
|
33
|
+
isLoading: false,
|
|
34
|
+
selectedIndex: 0,
|
|
35
|
+
total: 0,
|
|
36
|
+
hasMore: false,
|
|
37
|
+
error: null,
|
|
38
|
+
});
|
|
39
|
+
scrollOffset.current = 0;
|
|
40
|
+
}
|
|
41
|
+
}, [isVisible]);
|
|
42
|
+
// Debounced search
|
|
43
|
+
const performSearch = useCallback(async (query) => {
|
|
44
|
+
// Increment sequence to track this request
|
|
45
|
+
const seq = ++searchSeqRef.current;
|
|
46
|
+
if (!query.trim()) {
|
|
47
|
+
setState((prev) => ({
|
|
48
|
+
...prev,
|
|
49
|
+
results: [],
|
|
50
|
+
total: 0,
|
|
51
|
+
hasMore: false,
|
|
52
|
+
isLoading: false,
|
|
53
|
+
error: null,
|
|
54
|
+
}));
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
setState((prev) => ({ ...prev, isLoading: true, error: null }));
|
|
58
|
+
try {
|
|
59
|
+
const response = await agent.searchMessages(query, { limit: 20 });
|
|
60
|
+
// Only apply results if this is still the latest request
|
|
61
|
+
if (seq !== searchSeqRef.current)
|
|
62
|
+
return;
|
|
63
|
+
setState((prev) => ({
|
|
64
|
+
...prev,
|
|
65
|
+
results: response.results,
|
|
66
|
+
total: response.total,
|
|
67
|
+
hasMore: response.hasMore,
|
|
68
|
+
isLoading: false,
|
|
69
|
+
selectedIndex: 0,
|
|
70
|
+
}));
|
|
71
|
+
scrollOffset.current = 0;
|
|
72
|
+
}
|
|
73
|
+
catch (error) {
|
|
74
|
+
// Only apply error if this is still the latest request
|
|
75
|
+
if (seq !== searchSeqRef.current)
|
|
76
|
+
return;
|
|
77
|
+
setState((prev) => ({
|
|
78
|
+
...prev,
|
|
79
|
+
results: [],
|
|
80
|
+
total: 0,
|
|
81
|
+
hasMore: false,
|
|
82
|
+
isLoading: false,
|
|
83
|
+
error: error instanceof Error ? error.message : 'Search failed',
|
|
84
|
+
}));
|
|
85
|
+
}
|
|
86
|
+
}, [agent]);
|
|
87
|
+
// Handle input changes with debounce
|
|
88
|
+
const updateQuery = useCallback((newQuery) => {
|
|
89
|
+
setState((prev) => ({ ...prev, query: newQuery }));
|
|
90
|
+
// Clear existing timeout
|
|
91
|
+
if (searchTimeoutRef.current) {
|
|
92
|
+
clearTimeout(searchTimeoutRef.current);
|
|
93
|
+
}
|
|
94
|
+
// Debounce search
|
|
95
|
+
searchTimeoutRef.current = setTimeout(() => {
|
|
96
|
+
void performSearch(newQuery);
|
|
97
|
+
}, SEARCH_DEBOUNCE_MS);
|
|
98
|
+
}, [performSearch]);
|
|
99
|
+
// Cleanup timeout on unmount
|
|
100
|
+
useEffect(() => {
|
|
101
|
+
return () => {
|
|
102
|
+
if (searchTimeoutRef.current) {
|
|
103
|
+
clearTimeout(searchTimeoutRef.current);
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
}, []);
|
|
107
|
+
// Handle keyboard input
|
|
108
|
+
useImperativeHandle(ref, () => ({
|
|
109
|
+
handleInput: (input, key) => {
|
|
110
|
+
if (!isVisible)
|
|
111
|
+
return false;
|
|
112
|
+
// Escape to close
|
|
113
|
+
if (key.escape) {
|
|
114
|
+
onClose();
|
|
115
|
+
return true;
|
|
116
|
+
}
|
|
117
|
+
// Enter to select result
|
|
118
|
+
if (key.return && state.results.length > 0) {
|
|
119
|
+
const selectedResult = state.results[state.selectedIndex];
|
|
120
|
+
if (selectedResult && onSelectResult) {
|
|
121
|
+
onSelectResult(selectedResult);
|
|
122
|
+
}
|
|
123
|
+
onClose();
|
|
124
|
+
return true;
|
|
125
|
+
}
|
|
126
|
+
// Arrow up
|
|
127
|
+
if (key.upArrow) {
|
|
128
|
+
setState((prev) => {
|
|
129
|
+
const newIndex = Math.max(0, prev.selectedIndex - 1);
|
|
130
|
+
// Adjust scroll offset if needed
|
|
131
|
+
if (newIndex < scrollOffset.current) {
|
|
132
|
+
scrollOffset.current = newIndex;
|
|
133
|
+
}
|
|
134
|
+
return { ...prev, selectedIndex: newIndex };
|
|
135
|
+
});
|
|
136
|
+
return true;
|
|
137
|
+
}
|
|
138
|
+
// Arrow down
|
|
139
|
+
if (key.downArrow) {
|
|
140
|
+
setState((prev) => {
|
|
141
|
+
const newIndex = Math.min(prev.results.length - 1, prev.selectedIndex + 1);
|
|
142
|
+
// Adjust scroll offset if needed
|
|
143
|
+
if (newIndex >= scrollOffset.current + MAX_VISIBLE_RESULTS) {
|
|
144
|
+
scrollOffset.current = newIndex - MAX_VISIBLE_RESULTS + 1;
|
|
145
|
+
}
|
|
146
|
+
return { ...prev, selectedIndex: newIndex };
|
|
147
|
+
});
|
|
148
|
+
return true;
|
|
149
|
+
}
|
|
150
|
+
// Backspace
|
|
151
|
+
if (key.backspace || key.delete) {
|
|
152
|
+
updateQuery(state.query.slice(0, -1));
|
|
153
|
+
return true;
|
|
154
|
+
}
|
|
155
|
+
// Regular character input
|
|
156
|
+
if (input && !key.ctrl && !key.meta) {
|
|
157
|
+
updateQuery(state.query + input);
|
|
158
|
+
return true;
|
|
159
|
+
}
|
|
160
|
+
return false;
|
|
161
|
+
},
|
|
162
|
+
}), [isVisible, onClose, onSelectResult, state, updateQuery]);
|
|
163
|
+
if (!isVisible)
|
|
164
|
+
return null;
|
|
165
|
+
// Calculate visible results window
|
|
166
|
+
const visibleResults = state.results.slice(scrollOffset.current, scrollOffset.current + MAX_VISIBLE_RESULTS);
|
|
167
|
+
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: "cyan", paddingX: 1, children: [_jsxs(Box, { marginBottom: 1, children: [_jsx(Text, { bold: true, color: "cyan", children: "Search Messages" }), state.total > 0 && (_jsxs(Text, { color: "gray", children: [' ', "(", state.total, " result", state.total !== 1 ? 's' : '', ")"] }))] }), _jsxs(Box, { children: [_jsx(Text, { color: "cyan", children: "> " }), _jsx(Text, { children: state.query }), _jsx(Text, { color: "cyan", children: "_" })] }), state.isLoading && (_jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "yellowBright", children: "Searching..." }) })), state.error && (_jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "red", children: state.error }) })), !state.isLoading && state.results.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [visibleResults.map((result, idx) => {
|
|
168
|
+
const actualIndex = scrollOffset.current + idx;
|
|
169
|
+
const isSelected = actualIndex === state.selectedIndex;
|
|
170
|
+
const roleColor = result.message.role === 'user'
|
|
171
|
+
? 'blue'
|
|
172
|
+
: result.message.role === 'assistant'
|
|
173
|
+
? 'green'
|
|
174
|
+
: 'yellowBright';
|
|
175
|
+
return (_jsxs(Box, { flexDirection: "column", paddingLeft: isSelected ? 0 : 2, children: [_jsxs(Box, { children: [isSelected && (_jsx(Text, { color: "cyan", bold: true, children: '> ' })), _jsx(Text, { color: "gray", children: result.sessionId.slice(0, 8) }), _jsx(Text, { children: " " }), _jsxs(Text, { color: roleColor, bold: isSelected, children: ["[", result.message.role, "]"] })] }), _jsx(Box, { paddingLeft: isSelected ? 2 : 0, children: _jsxs(Text, { color: isSelected ? 'white' : 'gray', children: [' ', truncateContext(result.context, 60)] }) })] }, `${result.sessionId}-${result.messageIndex}`));
|
|
176
|
+
}), state.results.length > MAX_VISIBLE_RESULTS && (_jsx(Box, { marginTop: 1, children: _jsxs(Text, { color: "gray", children: ["Showing ", scrollOffset.current + 1, "-", Math.min(scrollOffset.current + MAX_VISIBLE_RESULTS, state.results.length), ' ', "of ", state.results.length, state.hasMore ? '+' : ''] }) }))] })), !state.isLoading && state.query && state.results.length === 0 && !state.error && (_jsx(Box, { marginTop: 1, children: _jsxs(Text, { color: "gray", children: ["No results found for \"", state.query, "\""] }) })), _jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "gray", children: "\u2191\u2193 navigate \u2022 Enter select \u2022 Esc close" }) })] }));
|
|
177
|
+
});
|
|
178
|
+
/**
|
|
179
|
+
* Truncate context text for display
|
|
180
|
+
*/
|
|
181
|
+
function truncateContext(context, maxLength) {
|
|
182
|
+
// Clean up whitespace
|
|
183
|
+
const cleaned = context.replace(/\s+/g, ' ').trim();
|
|
184
|
+
if (cleaned.length <= maxLength) {
|
|
185
|
+
return cleaned;
|
|
186
|
+
}
|
|
187
|
+
return cleaned.slice(0, maxLength - 3) + '...';
|
|
188
|
+
}
|
|
189
|
+
export default SearchOverlay;
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
* Now a thin wrapper around BaseSelector
|
|
4
4
|
* Eliminates ~200 lines of code by using base component
|
|
5
5
|
*/
|
|
6
|
+
import React from 'react';
|
|
7
|
+
import type { Key } from '../../hooks/useInputOrchestrator.js';
|
|
6
8
|
import type { DextoAgent } from '@dexto/core';
|
|
7
9
|
interface SessionSelectorProps {
|
|
8
10
|
isVisible: boolean;
|
|
@@ -11,11 +13,14 @@ interface SessionSelectorProps {
|
|
|
11
13
|
agent: DextoAgent;
|
|
12
14
|
currentSessionId?: string | undefined;
|
|
13
15
|
}
|
|
16
|
+
export interface SessionSelectorHandle {
|
|
17
|
+
handleInput: (input: string, key: Key) => boolean;
|
|
18
|
+
}
|
|
14
19
|
/**
|
|
15
20
|
* Session selector - now a thin wrapper around BaseSelector
|
|
16
21
|
* Provides data fetching and formatting only
|
|
17
22
|
* Uses explicit currentSessionId prop (WebUI pattern) instead of getCurrentSessionId
|
|
18
23
|
*/
|
|
19
|
-
|
|
20
|
-
export
|
|
24
|
+
declare const SessionSelector: React.ForwardRefExoticComponent<SessionSelectorProps & React.RefAttributes<SessionSelectorHandle>>;
|
|
25
|
+
export default SessionSelector;
|
|
21
26
|
//# sourceMappingURL=SessionSelectorRefactored.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SessionSelectorRefactored.d.ts","sourceRoot":"","sources":["../../../../../src/cli/ink-cli/components/overlays/SessionSelectorRefactored.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;
|
|
1
|
+
{"version":3,"file":"SessionSelectorRefactored.d.ts","sourceRoot":"","sources":["../../../../../src/cli/ink-cli/components/overlays/SessionSelectorRefactored.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAuE,MAAM,OAAO,CAAC;AAE5F,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAmB,MAAM,aAAa,CAAC;AAI/D,UAAU,oBAAoB;IAC1B,SAAS,EAAE,OAAO,CAAC;IACnB,eAAe,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7C,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,EAAE,UAAU,CAAC;IAClB,gBAAgB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACzC;AAED,MAAM,WAAW,qBAAqB;IAClC,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,KAAK,OAAO,CAAC;CACrD;AAQD;;;;GAIG;AACH,QAAA,MAAM,eAAe,oGA+JpB,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
4
4
|
* Now a thin wrapper around BaseSelector
|
|
5
5
|
* Eliminates ~200 lines of code by using base component
|
|
6
6
|
*/
|
|
7
|
-
import { useState, useEffect } from 'react';
|
|
7
|
+
import { useState, useEffect, forwardRef, useRef, useImperativeHandle } from 'react';
|
|
8
8
|
import { Text } from 'ink';
|
|
9
9
|
import { logger } from '@dexto/core';
|
|
10
10
|
import { BaseSelector } from '../base/BaseSelector.js';
|
|
@@ -13,7 +13,14 @@ import { BaseSelector } from '../base/BaseSelector.js';
|
|
|
13
13
|
* Provides data fetching and formatting only
|
|
14
14
|
* Uses explicit currentSessionId prop (WebUI pattern) instead of getCurrentSessionId
|
|
15
15
|
*/
|
|
16
|
-
|
|
16
|
+
const SessionSelector = forwardRef(function SessionSelector({ isVisible, onSelectSession, onClose, agent, currentSessionId }, ref) {
|
|
17
|
+
const baseSelectorRef = useRef(null);
|
|
18
|
+
// Forward handleInput to BaseSelector
|
|
19
|
+
useImperativeHandle(ref, () => ({
|
|
20
|
+
handleInput: (input, key) => {
|
|
21
|
+
return baseSelectorRef.current?.handleInput(input, key) ?? false;
|
|
22
|
+
},
|
|
23
|
+
}), []);
|
|
17
24
|
const [sessions, setSessions] = useState([]);
|
|
18
25
|
const [isLoading, setIsLoading] = useState(false);
|
|
19
26
|
const [selectedIndex, setSelectedIndex] = useState(0);
|
|
@@ -77,10 +84,16 @@ export default function SessionSelector({ isVisible, onSelectSession, onClose, a
|
|
|
77
84
|
// Format session for display
|
|
78
85
|
const formatSession = (session) => {
|
|
79
86
|
const parts = [];
|
|
87
|
+
// Add title if available, otherwise use "Session" as fallback
|
|
80
88
|
if (session.metadata?.title) {
|
|
81
89
|
parts.push(session.metadata.title);
|
|
82
90
|
}
|
|
91
|
+
else {
|
|
92
|
+
parts.push('Session');
|
|
93
|
+
}
|
|
94
|
+
// Always show short ID
|
|
83
95
|
parts.push(session.id.slice(0, 8));
|
|
96
|
+
// Show last activity time if available
|
|
84
97
|
if (session.metadata?.lastActivity) {
|
|
85
98
|
const now = Date.now();
|
|
86
99
|
const diff = now - session.metadata.lastActivity;
|
|
@@ -103,10 +116,11 @@ export default function SessionSelector({ isVisible, onSelectSession, onClose, a
|
|
|
103
116
|
return parts.join(' • ');
|
|
104
117
|
};
|
|
105
118
|
// Format session item for display
|
|
106
|
-
const formatItem = (session, isSelected) => (_jsxs(_Fragment, { children: [_jsx(Text, { color: isSelected ? '
|
|
119
|
+
const formatItem = (session, isSelected) => (_jsxs(_Fragment, { children: [_jsx(Text, { color: isSelected ? 'cyan' : 'gray', bold: isSelected, children: formatSession(session) }), session.isCurrent && (_jsxs(Text, { color: isSelected ? 'cyan' : 'gray', bold: isSelected, children: [' ', "\u2190 Current"] }))] }));
|
|
107
120
|
// Handle selection
|
|
108
121
|
const handleSelect = (session) => {
|
|
109
122
|
onSelectSession(session.id);
|
|
110
123
|
};
|
|
111
|
-
return (_jsx(BaseSelector, { items: sessions, isVisible: isVisible, isLoading: isLoading, selectedIndex: selectedIndex, onSelectIndex: setSelectedIndex, onSelect: handleSelect, onClose: onClose, formatItem: formatItem, title: "Select Session", borderColor: "cyan", loadingMessage: "Loading sessions...", emptyMessage: "No sessions found" }));
|
|
112
|
-
}
|
|
124
|
+
return (_jsx(BaseSelector, { ref: baseSelectorRef, items: sessions, isVisible: isVisible, isLoading: isLoading, selectedIndex: selectedIndex, onSelectIndex: setSelectedIndex, onSelect: handleSelect, onClose: onClose, formatItem: formatItem, title: "Select Session", borderColor: "cyan", loadingMessage: "Loading sessions...", emptyMessage: "No sessions found" }));
|
|
125
|
+
});
|
|
126
|
+
export default SessionSelector;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SessionSubcommandSelector Component
|
|
3
|
+
* Shows session management options (list, history, delete, switch)
|
|
4
|
+
*/
|
|
5
|
+
import React from 'react';
|
|
6
|
+
import type { Key } from '../../hooks/useInputOrchestrator.js';
|
|
7
|
+
export type SessionAction = 'list' | 'history' | 'delete' | 'switch';
|
|
8
|
+
interface SessionSubcommandSelectorProps {
|
|
9
|
+
isVisible: boolean;
|
|
10
|
+
onSelect: (action: SessionAction) => void;
|
|
11
|
+
onClose: () => void;
|
|
12
|
+
}
|
|
13
|
+
export interface SessionSubcommandSelectorHandle {
|
|
14
|
+
handleInput: (input: string, key: Key) => boolean;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Session subcommand selector - shows session management options
|
|
18
|
+
*/
|
|
19
|
+
declare const SessionSubcommandSelector: React.ForwardRefExoticComponent<SessionSubcommandSelectorProps & React.RefAttributes<SessionSubcommandSelectorHandle>>;
|
|
20
|
+
export default SessionSubcommandSelector;
|
|
21
|
+
//# sourceMappingURL=SessionSubcommandSelector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SessionSubcommandSelector.d.ts","sourceRoot":"","sources":["../../../../../src/cli/ink-cli/components/overlays/SessionSubcommandSelector.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAuE,MAAM,OAAO,CAAC;AAE5F,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAC;AAG/D,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAErE,UAAU,8BAA8B;IACpC,SAAS,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,CAAC,MAAM,EAAE,aAAa,KAAK,IAAI,CAAC;IAC1C,OAAO,EAAE,MAAM,IAAI,CAAC;CACvB;AAED,MAAM,WAAW,+BAA+B;IAC5C,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,KAAK,OAAO,CAAC;CACrD;AAgBD;;GAEG;AACH,QAAA,MAAM,yBAAyB,wHA2D7B,CAAC;AAEH,eAAe,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { jsxs as _jsxs, jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* SessionSubcommandSelector Component
|
|
4
|
+
* Shows session management options (list, history, delete, switch)
|
|
5
|
+
*/
|
|
6
|
+
import { useState, useEffect, forwardRef, useRef, useImperativeHandle } from 'react';
|
|
7
|
+
import { Text } from 'ink';
|
|
8
|
+
import { BaseSelector } from '../base/BaseSelector.js';
|
|
9
|
+
const SESSION_OPTIONS = [
|
|
10
|
+
{ action: 'list', label: 'list', description: 'List all sessions', icon: '📋' },
|
|
11
|
+
{ action: 'switch', label: 'switch', description: 'Switch to another session', icon: '🔄' },
|
|
12
|
+
{ action: 'history', label: 'history', description: 'Show session history', icon: '📜' },
|
|
13
|
+
{ action: 'delete', label: 'delete', description: 'Delete a session', icon: '🗑️' },
|
|
14
|
+
];
|
|
15
|
+
/**
|
|
16
|
+
* Session subcommand selector - shows session management options
|
|
17
|
+
*/
|
|
18
|
+
const SessionSubcommandSelector = forwardRef(function SessionSubcommandSelector({ isVisible, onSelect, onClose }, ref) {
|
|
19
|
+
const baseSelectorRef = useRef(null);
|
|
20
|
+
// Forward handleInput to BaseSelector
|
|
21
|
+
useImperativeHandle(ref, () => ({
|
|
22
|
+
handleInput: (input, key) => {
|
|
23
|
+
return baseSelectorRef.current?.handleInput(input, key) ?? false;
|
|
24
|
+
},
|
|
25
|
+
}), []);
|
|
26
|
+
const [options] = useState(SESSION_OPTIONS);
|
|
27
|
+
const [selectedIndex, setSelectedIndex] = useState(0);
|
|
28
|
+
// Reset selection when becoming visible
|
|
29
|
+
useEffect(() => {
|
|
30
|
+
if (isVisible) {
|
|
31
|
+
setSelectedIndex(0);
|
|
32
|
+
}
|
|
33
|
+
}, [isVisible]);
|
|
34
|
+
// Format option for display
|
|
35
|
+
const formatItem = (option, isSelected) => (_jsxs(_Fragment, { children: [_jsxs(Text, { children: [option.icon, " "] }), _jsx(Text, { color: isSelected ? 'cyan' : 'gray', bold: isSelected, children: option.label }), _jsxs(Text, { color: isSelected ? 'white' : 'gray', children: [" - ", option.description] })] }));
|
|
36
|
+
// Handle selection
|
|
37
|
+
const handleSelect = (option) => {
|
|
38
|
+
onSelect(option.action);
|
|
39
|
+
};
|
|
40
|
+
return (_jsx(BaseSelector, { ref: baseSelectorRef, items: options, isVisible: isVisible, isLoading: false, selectedIndex: selectedIndex, onSelectIndex: setSelectedIndex, onSelect: handleSelect, onClose: onClose, formatItem: formatItem, title: "Session Management", borderColor: "blue", emptyMessage: "No options available" }));
|
|
41
|
+
});
|
|
42
|
+
export default SessionSubcommandSelector;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* StreamSelector Component
|
|
3
|
+
* Interactive selector for toggling streaming mode
|
|
4
|
+
*/
|
|
5
|
+
import React from 'react';
|
|
6
|
+
import type { Key } from '../../hooks/useInputOrchestrator.js';
|
|
7
|
+
interface StreamSelectorProps {
|
|
8
|
+
isVisible: boolean;
|
|
9
|
+
onSelect: (enabled: boolean) => void;
|
|
10
|
+
onClose: () => void;
|
|
11
|
+
}
|
|
12
|
+
export interface StreamSelectorHandle {
|
|
13
|
+
handleInput: (input: string, key: Key) => boolean;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Stream selector - toggle streaming on/off
|
|
17
|
+
*/
|
|
18
|
+
declare const StreamSelector: React.ForwardRefExoticComponent<StreamSelectorProps & React.RefAttributes<StreamSelectorHandle>>;
|
|
19
|
+
export default StreamSelector;
|
|
20
|
+
//# sourceMappingURL=StreamSelector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StreamSelector.d.ts","sourceRoot":"","sources":["../../../../../src/cli/ink-cli/components/overlays/StreamSelector.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAuE,MAAM,OAAO,CAAC;AAE5F,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAC;AAI/D,UAAU,mBAAmB;IACzB,SAAS,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IACrC,OAAO,EAAE,MAAM,IAAI,CAAC;CACvB;AAED,MAAM,WAAW,oBAAoB;IACjC,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,KAAK,OAAO,CAAC;CACrD;AAUD;;GAEG;AACH,QAAA,MAAM,cAAc,kGAuFnB,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { jsxs as _jsxs, jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* StreamSelector Component
|
|
4
|
+
* Interactive selector for toggling streaming mode
|
|
5
|
+
*/
|
|
6
|
+
import { useState, useEffect, forwardRef, useRef, useImperativeHandle } from 'react';
|
|
7
|
+
import { Text } from 'ink';
|
|
8
|
+
import { BaseSelector } from '../base/BaseSelector.js';
|
|
9
|
+
import { isStreamingEnabled, setStreamingEnabled } from '../../state/streaming-state.js';
|
|
10
|
+
/**
|
|
11
|
+
* Stream selector - toggle streaming on/off
|
|
12
|
+
*/
|
|
13
|
+
const StreamSelector = forwardRef(function StreamSelector({ isVisible, onSelect, onClose }, ref) {
|
|
14
|
+
const baseSelectorRef = useRef(null);
|
|
15
|
+
// Forward handleInput to BaseSelector
|
|
16
|
+
useImperativeHandle(ref, () => ({
|
|
17
|
+
handleInput: (input, key) => {
|
|
18
|
+
return baseSelectorRef.current?.handleInput(input, key) ?? false;
|
|
19
|
+
},
|
|
20
|
+
}), []);
|
|
21
|
+
const [options, setOptions] = useState([]);
|
|
22
|
+
const [selectedIndex, setSelectedIndex] = useState(0);
|
|
23
|
+
// Build options list with current indicator
|
|
24
|
+
useEffect(() => {
|
|
25
|
+
if (!isVisible)
|
|
26
|
+
return;
|
|
27
|
+
const currentEnabled = isStreamingEnabled();
|
|
28
|
+
const optionList = [
|
|
29
|
+
{
|
|
30
|
+
id: 'enabled',
|
|
31
|
+
label: 'Enabled (Experimental)',
|
|
32
|
+
description: 'Show responses as they are generated',
|
|
33
|
+
icon: '▶️',
|
|
34
|
+
isCurrent: currentEnabled,
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
id: 'disabled',
|
|
38
|
+
label: 'Disabled',
|
|
39
|
+
description: 'Show complete response when finished (default)',
|
|
40
|
+
icon: '⏸️',
|
|
41
|
+
isCurrent: !currentEnabled,
|
|
42
|
+
},
|
|
43
|
+
];
|
|
44
|
+
setOptions(optionList);
|
|
45
|
+
// Set initial selection to current state
|
|
46
|
+
setSelectedIndex(currentEnabled ? 0 : 1);
|
|
47
|
+
}, [isVisible]);
|
|
48
|
+
// Format option item for display
|
|
49
|
+
const formatItem = (option, isSelected) => (_jsxs(_Fragment, { children: [_jsxs(Text, { children: [option.icon, " "] }), _jsx(Text, { color: isSelected ? 'cyan' : 'gray', bold: isSelected, children: option.label }), _jsxs(Text, { color: isSelected ? 'white' : 'gray', children: [" - ", option.description] }), option.isCurrent && (_jsxs(Text, { color: "green", bold: true, children: [' ', "\u2713"] }))] }));
|
|
50
|
+
// Handle selection
|
|
51
|
+
const handleSelect = (option) => {
|
|
52
|
+
const enabled = option.id === 'enabled';
|
|
53
|
+
setStreamingEnabled(enabled);
|
|
54
|
+
onSelect(enabled);
|
|
55
|
+
};
|
|
56
|
+
return (_jsx(BaseSelector, { ref: baseSelectorRef, items: options, isVisible: isVisible, isLoading: false, selectedIndex: selectedIndex, onSelectIndex: setSelectedIndex, onSelect: handleSelect, onClose: onClose, formatItem: formatItem, title: "Streaming Mode", borderColor: "cyan", emptyMessage: "No options available" }));
|
|
57
|
+
});
|
|
58
|
+
export default StreamSelector;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ToolBrowser Component
|
|
3
|
+
* Interactive browser for exploring available tools
|
|
4
|
+
* Features:
|
|
5
|
+
* - Search/filter tools by name
|
|
6
|
+
* - View tool details (description, schema)
|
|
7
|
+
* - Shows source (MCP server or Internal)
|
|
8
|
+
*/
|
|
9
|
+
import React from 'react';
|
|
10
|
+
import type { Key } from '../../hooks/useInputOrchestrator.js';
|
|
11
|
+
import type { DextoAgent } from '@dexto/core';
|
|
12
|
+
interface ToolBrowserProps {
|
|
13
|
+
isVisible: boolean;
|
|
14
|
+
onClose: () => void;
|
|
15
|
+
agent: DextoAgent;
|
|
16
|
+
}
|
|
17
|
+
export interface ToolBrowserHandle {
|
|
18
|
+
handleInput: (input: string, key: Key) => boolean;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Tool browser with search and detail views
|
|
22
|
+
*/
|
|
23
|
+
declare const ToolBrowser: React.ForwardRefExoticComponent<ToolBrowserProps & React.RefAttributes<ToolBrowserHandle>>;
|
|
24
|
+
export default ToolBrowser;
|
|
25
|
+
//# sourceMappingURL=ToolBrowser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolBrowser.d.ts","sourceRoot":"","sources":["../../../../../src/cli/ink-cli/components/overlays/ToolBrowser.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAON,MAAM,OAAO,CAAC;AAEf,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAI9C,UAAU,gBAAgB;IACtB,SAAS,EAAE,OAAO,CAAC;IACnB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,EAAE,UAAU,CAAC;CACrB;AAED,MAAM,WAAW,iBAAiB;IAC9B,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,KAAK,OAAO,CAAC;CACrD;AAeD;;GAEG;AACH,QAAA,MAAM,WAAW,4FAoWf,CAAC;AAyQH,eAAe,WAAW,CAAC"}
|